Namespaces
oauthGrant
Methods and types of the `oauthGrant` namespace (`client.oauthGrant` / `bot.oauthGrant`).
Interfaces
OAuthGrantSummary
One application a user has authorised over OAuth.
A grant is the record of consent: the scopes approved, and the tie binding every token issued under it. Revoking one withdraws the application's access.
Properties
Functions
default()
function default(client): {
listGrants: Promise<OAuthGrantSummary[]>;
revokeGrant: Promise<void>;
};Parameters
| Parameter | Type |
|---|---|
client | default |
Returns
| Name | Type | Description |
|---|---|---|
listGrants() | () => Promise<OAuthGrantSummary[]> | List the applications the caller has authorised, newest first. Expired grants are omitted by the server. |
revokeGrant() | (grantId) => Promise<void> | Withdraw an application's access: the grant and every token issued under it. An access token already in flight stays valid until it expires, so revocation is not instantaneous for a request under way. |