Error With Using SafesForce Access Token In Other REST Resource

Im connecting Salesforce to my retool app using the built-in integration.

There is an option at the bottom of the page called "Enable using Salesforce access token in any REST API resource".

If I understand correctly, this allows me to use the access token of this resource in other RestAPI resources using the text: xxxxxxxxxxxxxxx.SALESFORCE_ACCESS_TOKEN

Obviously, I placed this in the request header "authorization: Bearer xxxxxxxxxxxxxxx.SALESFORCE_ACCESS_TOKEN" but it didn't work, and it simply sent it as plain text instead of passing the access token.

Can someone help here?
Or explain this option for me in case Im using it in the wrong way?

Thank you!

Thanks for reaching out, @Infinitybht! Believe it or not, this is actually my first time seeing that feature.

In my own testing, it seems to be working as expected. The one restriction that isn't necessarily obvious is the fact that you can only reference ********.SALESFORCE_ACCESS_TOKEN in the resource configuration itself, not within an app.

It's probably obvious, but your user also needs to be authenticated with Salesforce in order to reference that access token. :sweat_smile: I hope something here is helpful, but let me know if you're still running into issues and I'd be happy to take a closer look.

1 Like