Where would I put an auth token in the API plugin?

I have an API call I’m trying to do which I have working fine in Postman. I find the Bubble API plugin very confusing as it’s hard to know where to put values. With this API call I need to make, there’s a access token saved to Postman which looks similar to those keys when setting up SSL.

When running a call, on the Authorization tab I just select that token from the dropdown.

I’m just not clear where to select that in Bubble. This is OAuth 2.0.

Here’s more from Postman, I have environment variables set:

And then just the token as well as shown:

But just not really sure how to configure this in Bubble, as it’s mainly the token that’s throwing me off.

I see this in Bubble:

But not sure which to pick and then when I do pick one I’m not sure what to fill in. I tried OAuth2 Custom Token but that then wants a Token Endpoint (POST) URL which I’m not sure which one I use, nor where I even put the access token. Appreciate any help!

Most of the time, in Bubble if you need to use oAuth2 and let your users access their own account, you should use User-agent Flow. Normally Postman is using this when you configure oAuth2.
The last screenshot show you the final result of the oAuth2 process. If you want to directly use this (if you can… not sure and most API have an expiration for access token), you should use private key in header. The key will be Authorization and the value will be dynamics365token accesstokenhere

If you can provide url to API Docs, it will be easier to help

Thanks so much, sorry this is for Microsoft Dataverse, formerly Common Data Service, the documentation is here Use the Microsoft Dataverse Web API (Dataverse) - Power Apps | Microsoft Docs

I was just using the token I had for testing, but ultimately my goal is to have Bubble use the Dataverse API to retrieve records, create, etc. As mentioned, getting it working in Postman was fine, but I just have no idea where each value goes in the Bubble API plugin.

Appreciate your help!

Will you only access to your own dynamics instance or want each user access their own?

We have a marketing application on Bubble that I basically just want to have integrated a bit with Dynamics. So for example a repeating group in Bubble that displays Accounts from Dynamics. Or a button in Bubble that when pressed creates an Account in dynamics. Users of Bubble should be able to view and work with the data in Bubble even if they don’t have an account in Dynamics. Let me know if that clarifies. Thanks!

Yes. So you are using only your own dynamics instance from what I understand and will access your account data and this access need to be done even if you are not logged in (when it’s a different user that is logged in).
I think the best option for you is probably to use oAuthcustom token with info from this page.

It may probably look like:


Maybe the oAuth2 password may work too.

In this case, this will probably look like this


and you need to enter your username and password in the correct fields.

Other auth are also possible but will ask you to manually handle each part and store token into DB.

Don’t forget to change scope according to what you need

1 Like

Great thanks, I think this is still way over my head so going to call it on this one but I appreciate the help!

1 Like

@Jici can i ask for a more specific way on how to do it please?

Like what should I put in the empty inputbox?

Im not good at understanding a more complex english sentences so the microsoft documentation is a little bit confusing