cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Advocate III
Advocate III

Custom Connector Token Refresh?

I've created a cusom connector to Salesforce (the 'Premium' Flow connector doesn't support a couple API features I need). It works fine, but stops working after 4 hours, which is the session timeout setting for our Salesforce org. I need my connector to get a refresh token but I'm not sure how to do it. Has anyone gotten a Flow custom connector access token refresh from Salesforce working?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Hi @manuelstgomes,

 

I'll post this in case it helps anyone else. I finally gave up with my custom connector and just make direct HTTP requests. I post my client_id, client_secret, username, and password (for Salesforce, that's password+token) to their token endpoint. The return contains an access_token that I store in a variable and use in the header of my subsequent API requests. This avoids the token refresh issue I was having and is more flexible (I can make any number of different API calls via HTTP, whereas if I used a custom connector I would have had to define them each as unique actions).

 

 

SalesforceHTTP.png

View solution in original post

3 REPLIES 3
Highlighted
Super User II
Super User II

Hi @Bjorn 


I just stumbled on your request. You've been waiting a while for a reply.

Were you able to solve it? Can you post the solution so that we can all learn from it?

If you still need help, please let me know what changed.

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Cheers
Manuel

Highlighted

Hi @manuelstgomes,

 

I'll post this in case it helps anyone else. I finally gave up with my custom connector and just make direct HTTP requests. I post my client_id, client_secret, username, and password (for Salesforce, that's password+token) to their token endpoint. The return contains an access_token that I store in a variable and use in the header of my subsequent API requests. This avoids the token refresh issue I was having and is more flexible (I can make any number of different API calls via HTTP, whereas if I used a custom connector I would have had to define them each as unique actions).

 

 

SalesforceHTTP.png

View solution in original post

Highlighted

Hi @Bjorn 

 

Thanks for posting the solution. Well done!

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Cheers
Manuel

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Users online (7,315)