No summary provided.
Constructs a new instance of the
UsersAPI class| Name | Type | Optional | Description |
|---|---|---|---|
| rest | REST | No | None |
Opens a new DM channel with a user
| Name | Type | Optional | Description |
|---|---|---|---|
| userId | Snowflake | No | The id of the user to open a DM channel with |
| options | Pick<RequestData, 'signal'> | Yes | The options for opening the DM |
Edits the current user
| Name | Type | Optional | Description |
|---|---|---|---|
| body | RESTPatchAPICurrentUserJSONBody | No | The new data for the current user |
| options | Pick<RequestData, 'signal'> | Yes | The options for editing the user |
Edits the guild member for the current user
| Name | Type | Optional | Description |
|---|---|---|---|
| guildId | Snowflake | No | The id of the guild |
| body | RESTPatchAPIGuildMemberJSONBody | Yes | The new data for the guild member |
| options | Pick<RequestData, 'reason' | 'signal'> | Yes | The options for editing the guild member |
Fetches a user by their id
| Name | Type | Optional | Description |
|---|---|---|---|
| userId | Snowflake | No | The id of the user to fetch |
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the user |
Gets the current user's active application role connection
| Name | Type | Optional | Description |
|---|---|---|---|
| applicationId | Snowflake | No | The id of the application |
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the role connections |
Gets the current user's connections
| Name | Type | Optional | Description |
|---|---|---|---|
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the user's connections |
Returns the user object of the requester's account
| Name | Type | Optional | Description |
|---|---|---|---|
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the current user |
Fetches the guild member for the current user
| Name | Type | Optional | Description |
|---|---|---|---|
| guildId | Snowflake | No | The id of the guild |
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the guild member |
Returns a list of partial guild objects the current user is a member of
| Name | Type | Optional | Description |
|---|---|---|---|
| query | RESTGetAPICurrentUserGuildsQuery | Yes | The query options for fetching the current user's guilds |
| options | Pick<RequestData, 'signal'> | Yes | The options for fetching the guilds |
Leaves the guild with the given id
| Name | Type | Optional | Description |
|---|---|---|---|
| guildId | Snowflake | No | The id of the guild |
| options | Pick<RequestData, 'signal'> | Yes | The options for leaving the guild |
updateApplicationRoleConnection(applicationId, body, options?):Promise<APIApplicationRoleConnection>
Updates the current user's application role connection
| Name | Type | Optional | Description |
|---|---|---|---|
| applicationId | Snowflake | No | The id of the application |
| body | RESTPutAPICurrentUserApplicationRoleConnectionJSONBody | No | The data for updating the application role connection |
| options | Pick<RequestData, 'signal'> | Yes | The options for updating the application role connection |