public final class DbxAuthFinish
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static JsonReader<java.lang.String> |
AccessTokenReader |
static JsonReader<java.lang.String> |
BearerTokenTypeReader |
static JsonReader<DbxAuthFinish> |
Reader
For JSON parsing.
|
Constructor and Description |
---|
DbxAuthFinish(java.lang.String accessToken,
java.lang.Long expiresIn,
java.lang.String refreshToken,
java.lang.String userId,
java.lang.String teamId,
java.lang.String accountId,
java.lang.String urlState) |
DbxAuthFinish(java.lang.String accessToken,
java.lang.Long expiresIn,
java.lang.String refreshToken,
java.lang.String userId,
java.lang.String teamId,
java.lang.String accountId,
java.lang.String urlState,
java.lang.String scope) |
DbxAuthFinish(java.lang.String accessToken,
java.lang.String userId,
java.lang.String accountId,
java.lang.String teamId,
java.lang.String urlState)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getAccessToken()
Returns an access token that can be used to make Dropbox API calls.
|
java.lang.String |
getAccountId()
Returns the Dropbox account ID of the user who just approved your app for access to their
Dropbox account.
|
java.lang.Long |
getExpiresAt()
Returns the time when
accessToken expires in millisecond. |
java.lang.String |
getRefreshToken()
Returns an refresh token which can be used to obtain new
accessToken . |
java.lang.String |
getScope()
Return the scopes of current OAuth flow.
|
java.lang.String |
getTeamId()
Returns the Dropbox team ID of the team's user who just approved your app for access to their
Dropbox account.
|
java.lang.String |
getUrlState()
Returns the state data you passed in to
DbxWebAuth.start(java.lang.String) . |
java.lang.String |
getUserId()
Returns the Dropbox user ID of the user who just approved your app for access to their
Dropbox account.
|
public static final JsonReader<DbxAuthFinish> Reader
public static final JsonReader<java.lang.String> BearerTokenTypeReader
public static final JsonReader<java.lang.String> AccessTokenReader
@Deprecated public DbxAuthFinish(java.lang.String accessToken, java.lang.String userId, java.lang.String accountId, java.lang.String teamId, java.lang.String urlState)
accessToken
- OAuth access tokenuserId
- Dropbox user ID of user that approved access to this appurlState
- State data passed in to DbxWebAuth.start(java.lang.String)
or null
if no state
was passedpublic DbxAuthFinish(java.lang.String accessToken, java.lang.Long expiresIn, java.lang.String refreshToken, java.lang.String userId, java.lang.String teamId, java.lang.String accountId, java.lang.String urlState)
accessToken
- OAuth access token.expiresIn
- Duration time of accessToken in second.refreshToken
- A token used to obtain new accessToken.userId
- Dropbox user ID of user that authorized this app.teamId
- Dropbox team ID of team that authorized this app.accountId
- Obfusticated user or team id. Keep it safe.urlState
- State data passed in to DbxWebAuth.start(java.lang.String)
or null
if no state
was passedpublic DbxAuthFinish(java.lang.String accessToken, java.lang.Long expiresIn, java.lang.String refreshToken, java.lang.String userId, java.lang.String teamId, java.lang.String accountId, java.lang.String urlState, java.lang.String scope)
accessToken
- OAuth access token.expiresIn
- Duration time of accessToken in second.refreshToken
- A token used to obtain new accessToken.userId
- Dropbox user ID of user that authorized this app.teamId
- Dropbox team ID of team that authorized this app.accountId
- Obfusticated user or team id. Keep it safe.urlState
- State data passed in to DbxWebAuth.start(java.lang.String)
or null
if no state
was passedscope
- A list of scope returned by Dropbox server. Each scope correspond to a group of
API endpoints. To call one API endpoint you have to obtains the scope first otherwise you
will get HTTP 401.public java.lang.String getAccessToken()
DbxClientV2
constructor.public java.lang.Long getExpiresAt()
accessToken
expires in millisecond. If null then
it won't expire. Pass this in to the DbxClientV2
constructor.public java.lang.String getRefreshToken()
accessToken
. Pass this in to the
DbxClientV2
constructor.public java.lang.String getUserId()
public java.lang.String getAccountId()
public java.lang.String getTeamId()
public java.lang.String getScope()
public java.lang.String getUrlState()
DbxWebAuth.start(java.lang.String)
. If you didn't pass
anything in, or you used DbxWebAuthNoRedirect
, this will be null
.DbxWebAuth.start(java.lang.String)
, or null
if no state was
passed