mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-18 04:23:31 +01:00
loginWithToken documentation
This commit is contained in:
@@ -100,6 +100,19 @@ Logs the client in so it can begin initialising. Use this `after` registering yo
|
|||||||
- **error** - An error if any occurred
|
- **error** - An error if any occurred
|
||||||
- **token** - The token received after logging in, `String`.
|
- **token** - The token received after logging in, `String`.
|
||||||
|
|
||||||
|
loginWithToken(token, email, password, `callback`)
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
Logs the client in, using just a token. The specified email and password are optional - they're only needed when using
|
||||||
|
`updateDetails` which requires them for authentication.
|
||||||
|
|
||||||
|
- **token** - A valid Discord authentication token used to log in, `String`
|
||||||
|
- **email** - (Optional) The e-mail used for later authentication, `String`.
|
||||||
|
- **password** - (Optional) The password used for later authentication, `String`.
|
||||||
|
- **callback** - `function` that takes the following parameters:
|
||||||
|
- **error** - An error if any occurred
|
||||||
|
- **token** - A `String` containing the specified token. This is only used for compatibility with `login`, this token will always be identical to the specified one.
|
||||||
|
|
||||||
logout(`callback`)
|
logout(`callback`)
|
||||||
~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
@@ -669,4 +682,4 @@ Emitted when a user joins a voice channel, supplies a User_ and a VoiceChannel_
|
|||||||
voiceLeave
|
voiceLeave
|
||||||
~~~~~~~~~~
|
~~~~~~~~~~
|
||||||
|
|
||||||
Emitted when a user leaves a voice channel, supplies a User_ and a VoiceChannel_
|
Emitted when a user leaves a voice channel, supplies a User_ and a VoiceChannel_
|
||||||
|
|||||||
Reference in New Issue
Block a user