Discord
discord.set_application_id
Client
Sets the Discord application-id and reconnects the client
Syntax
local status = discord.set_application_id(id, authenticate = false, force_reauth = false)Parameters
| Type | Name | Description |
|---|---|---|
string | id | Discord application-id to connect with |
bool | authenticate | Determines the authentication state: • When true - authenticates the client with OAuth• When false - connects without authentication |
bool | force_reauth | Determines the re-authentication state: • When true - forces re-authentication even if a cached token exists• When false - uses the cached token if available |
Returns
| Type | Name | Description |
|---|---|---|
bool | status | true on successful execution, or false on failure |
Examples
--Connect with a specific application-id
discord.set_application_id("1461425342722998474")
--Connect with authentication
discord.set_application_id("1461425342722998474", true)
--Connect and force re-authentication
discord.set_application_id("1461425342722998474", true, true)