CodeExchangeResponse

public final class CodeExchangeResponse

Class representation of a Nylas code exchange response

Constructors

Link copied to clipboard
public CodeExchangeResponse CodeExchangeResponse(@Json(name = "access_token") String accessToken, @Json(name = "grant_id") String grantId, @Json(name = "expires_in") Integer expiresIn, @Json(name = "scope") String scope, @Json(name = "email") String email, @Json(name = "refresh_token") String refreshToken, @Json(name = "id_token") String idToken, @Json(name = "token_type") String tokenType)

Properties

Link copied to clipboard
private final String accessToken

Supports exchanging the code for tokens, or refreshing an access token using Auth.refreshAccessToken.

Link copied to clipboard
private final String email

Email address of the grant that is created.

Link copied to clipboard
private final Integer expiresIn

The remaining lifetime of the access token in seconds.

Link copied to clipboard
private final String grantId

Nylas grant ID that is now successfully created.

Link copied to clipboard
private final String idToken

A JWT that contains identity information about the user that is digitally signed by Nylas.

Link copied to clipboard
private final String refreshToken

Only returned if the code was requested using AccessType.OFFLINE.

Link copied to clipboard
private final String scope

List of scopes associated with this token.

Link copied to clipboard
private final String tokenType

Currently always Bearer.

Functions

Link copied to clipboard
public final String getAccessToken()

Supports exchanging the code for tokens, or refreshing an access token using Auth.refreshAccessToken.

Link copied to clipboard
public final String getEmail()

Email address of the grant that is created.

Link copied to clipboard
public final Integer getExpiresIn()

The remaining lifetime of the access token in seconds.

Link copied to clipboard
public final String getGrantId()

Nylas grant ID that is now successfully created.

Link copied to clipboard
public final String getIdToken()

A JWT that contains identity information about the user that is digitally signed by Nylas.

Link copied to clipboard
public final String getRefreshToken()

Only returned if the code was requested using AccessType.OFFLINE.

Link copied to clipboard
public final String getScope()

List of scopes associated with this token.

Link copied to clipboard
public final String getTokenType()

Currently always Bearer.