function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
SAgentSAgent 

oauth2 flow authorization for communities - redirect not working

Hello everyone,

I'm not a salesforce developer, but I have an external application that has to authenticate users against Salesforce community application using oauth2.

I'm redirecting the user to the authorize url in the format COMMUNITY_url/authorize?
2response_type=code&client_id=your_app_id&redirect_uri=your_redirect_uri, but when the user logs in, it's getting redirected to the communites landing page instead of the url in redirect_uri.

Thanks for your help!
Jose
sindhura (Heptarc)sindhura (Heptarc)
Hi SAgent,
Solution: redirect URI has to have an HTTP or https header to it to get the return token string from the browser, even if you don't want it on https. I wanted to have a custom header so that I can easily deep link to my Android app, but  Chrome browser didn't want to display the new redirect URI in the address bar since it didn't have the "https://" tag.
Thank you
SAgentSAgent
Hi sidhura, I'm using HTTPS and even using oauth Web Server flow or User Agent flow, I still get stucked int he community landing page.