Skip to content

kient / Token

Class: Token

src/structures/token.ts:11

Response when generating an authorisation token

Properties

PropertyTypeDescriptionDefined in
accessTokenstringThe access tokensrc/structures/token.ts:15
expiresInnumberThe seconds until the access token expiressrc/structures/token.ts:30
refreshToken?stringThe refresh token used to get a new access tokensrc/structures/token.ts:25
scope?stringA string of space seperated scopes available to this tokensrc/structures/token.ts:35
tokenType"Bearer"The type of token presentedsrc/structures/token.ts:20

Accessors

isAppToken

Get Signature

ts
get isAppToken(): boolean

src/structures/token.ts:56

Returns true if the token is an app token type

Returns

boolean


scopes

Get Signature

ts
get scopes(): KientScope[]

src/structures/token.ts:49

An array of scopes available to this token

Returns

KientScope[]

Methods

toJSON()

ts
toJSON(): ExcludeFunctionsAndPrivate<Token>

src/structures/token.ts:60

Returns

ExcludeFunctionsAndPrivate<Token>