This PR adds support for the /v3/connect/tokeninfo endpoint.
Usage
There are two methods that are part of the Auth resource that allow you to get information on a token; one for the ID token (idTokenInfo) and one for the access token (accessTokenInfo).
import Nylas, { TokenInfoResponse } from "nylas";
const nylas = new Nylas({
apiKey: 'nylas-api-key',
});
// Get information on an ID token
nylas.auth.idTokenInfo('idToken').then((response) => {
const idTokenInfo: TokenInfoResponse = response.data;
// ...
});
// Get information on an access token
nylas.auth.accessTokenInfo('accessToken').then((response) => {
const accessTokenInfo: TokenInfoResponse = response.data;
// ...
});
License
I confirm that this contribution is made under the terms of the MIT license and that I have the authority necessary to make this contribution on behalf of its copyright owner.
Description
This PR adds support for the /v3/connect/tokeninfo endpoint.
Usage
There are two methods that are part of the
Auth
resource that allow you to get information on a token; one for the ID token (idTokenInfo
) and one for the access token (accessTokenInfo
).License
I confirm that this contribution is made under the terms of the MIT license and that I have the authority necessary to make this contribution on behalf of its copyright owner.