Java Perspective Method Issues

I am trying to do some more advanced stuff inside of ignition perspective. In the past (think vision and gateway scripts) I have been able to use quite a few of the functions that Ignition has documented inside of the scripts. (Kinda similar to module development without as much effort.)

My latest endeavor is to try to use the configure binding method that is built in to add some bindings. I think I have a pretty good idea on how to do this but the issue that I have been running into is when I try importing any com.inductiveautomation.perspective library (ie. from com.inductiveautomation.perspective.gateway.api import PerspectiveContext), I get an error saying
Error running window@C/root/Map.onMessageReceived(self, payload): Traceback (most recent call last): File “function:onMessageReceived”, line 6, in onMessageReceived ImportError: No module named perspective

Is there any way that I can import these on either a message handler or custom method in perspective?

I know that nminchin had a similar issue in the link below.