Hi,
I successfully retrieved Access and Refresh tokens from Azure AD using OAuth Authorization. Now, I am trying to get a new token using the refresh token.
Followed the example here: https://docs.microsoft.com/en-us/azure/active-directory/develop/active-directory-protocols-oauth-code
and I am sending the following in a post to https://login.microsoftonline.com/<client-id>/oauth2/token end point. The client-id is the Application ID of the application that I got the refresh_token for using the authorization end-point.
POST /{tenant}/oauth2/token HTTP/1.1
Host: https://login.microsoftonline.com
Content-Type: application/x-www-form-urlencoded
client_id=6731de76-14a6-49ae-97bc-6eba6914391e &refresh_token=OAAABAAAAiL9Kn2Z27UubvWFPbm0gLWQJVzCTE9UkP3pSx1aXxUjq... &grant_type=refresh_token
&resource=https%3A%2F%2Fservice.contoso.com%2F
&client_secret=JqQX2PNo9bpM0uEihUPzyrh
The response I get is a 404 Not Found. Please let me know what I am missing here.
Thanks!
*This post is locked for comments