Salesforce OAuth 2.0 "authorize" endpoint doesn't return refresh token
Problem:
Salesforce OAuth 2.0 "authorize" (https://login.salesforce.com/services/oauth2/authorize) endpoint doesn't return refresh token
Solution:
References:
http://salesforce.stackexchange.com/questions/7554/oauth-api-doesnt-send-refresh-token-with-custom-redirect-uri
https://help.salesforce.com/apex/HTViewHelpDoc?id=remoteaccess_authenticate.htm&language=en_US
Salesforce OAuth 2.0 "authorize" (https://login.salesforce.com/services/oauth2/authorize) endpoint doesn't return refresh token
Solution:
The refresh token for the user-agent flow is only issued under one of the following circumstances:
- The redirect URL uses a custom protocol.
- The redirect URL is exactly https://login.salesforce.com/services/oauth2/success, or on Sandbox, https://test.salesforce.com/services/oauth2/success.
- The redirect URL uses the http protocol and the host is localhost - e.g.
http://localhost:8080/
References:
http://salesforce.stackexchange.com/questions/7554/oauth-api-doesnt-send-refresh-token-with-custom-redirect-uri
https://help.salesforce.com/apex/HTViewHelpDoc?id=remoteaccess_authenticate.htm&language=en_US
Comments
Post a Comment
Feedback - positive or negative is welcome.