Azure-docs: When I get access token from /{tenant}/oauth2/v2.0/token, I get "expires_in" as string

Created on 17 May 2020  Â·  3Comments  Â·  Source: MicrosoftDocs/azure-docs

If I use this token endpoint: /{tenant}/oauth2/token
I get "expires_in" as a string: "expires_in": "3599". I'm using my own tenant and app id in this case.

However, if I use this endpoint: /common/oauth2/v2.0/token
I get "expires_in" as an integer: "expires_in": 3599. I'm using the Postman Samples provided in the document in this case.

Why?


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri1 active-directorsvc cxp develosubsvc product-question triaged

All 3 comments

@pablolaurin Thanks for the comment. We are actively investigating and will get back to you soon.

I found my mistake. It works as documented.

I'm using the V1 endpoint in the first case and the V2 endpoint in the second. The documentation for V1 shows examples with expires_in as string. For V2, expires-in is an integer.

phew Thanks for double checking @pablolaurin!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bdcoder2 picture bdcoder2  Â·  3Comments

Favna picture Favna  Â·  3Comments

bityob picture bityob  Â·  3Comments

mrdfuse picture mrdfuse  Â·  3Comments

DeepPuddles picture DeepPuddles  Â·  3Comments