API POST doesn't seem to be sending from App?

I’m doing a Token Exchange workflow with an API. In the Bubble API editor, everything authenticates and I get expected results (including manually using the code I get from step 2 below).

When I call the plugin in my app, I get a 405 error from the external API. This is the error:

{“statusCode”:405,“body”:{“status”:“ERROR”,“message”:“Wrong method. Should be a POST. Method may change when attemping to use http. Please ensure URL starts with https:// instead.”}}

Here are the steps I’m going through:

  1. Hit an authentication URL. This goes through the expected dialogs and returns the appropriate code in the url and going to my expected redirect_uri.
  2. The redirect_uri goes to a Bubble API workflow that is hitting a POST API call from the plugin (set to action).


    image

This is all supposed to ask the user to authorize access, upon user saying yes, grab a code from the URL, exchange for appropriate tokens, and then save against the user.

Seriously baffled by this. I tried using the simple OAUTH2 User-Agent flow and signup via Social Network and while this doesn’t return any errors in the app, it also doesn’t let me access any data via the External API.

Any help would be greatly appreciated!