ISnowflakepublic static interface Application.Bot extends ISnowflake
AccountManager.| Modifier and Type | Method | Description |
|---|---|---|
Application |
getApplication() |
The Application for this Bot
|
java.lang.String |
getAvatarId() |
The avatar id of this Bot
|
java.lang.String |
getAvatarUrl() |
The avatar-url of this Bot
|
java.lang.String |
getDiscriminator() |
The discriminator of this Bot
|
java.lang.String |
getInviteUrl(java.lang.String guildId,
java.util.Collection<Permission> permissions) |
Creates a OAuth invite-link used to invite the bot.
|
java.lang.String |
getInviteUrl(java.lang.String guildId,
Permission... permissions) |
Creates a OAuth invite-link used to invite the bot.
|
java.lang.String |
getInviteUrl(java.util.Collection<Permission> permissions) |
Creates a OAuth invite-link used to invite the bot.
|
java.lang.String |
getInviteUrl(Permission... permissions) |
Creates a OAuth invite-link used to invite the bot.
|
java.lang.String |
getName() |
The name of this Bot
|
java.lang.String |
getToken() |
The token used to login to JDA with this Bot
This can be used in JDABuilder.setToken(String) |
RestAction<Application.Bot> |
resetToken() |
Generates a new token for this bot.
|
getCreationTime, getId, getIdLongApplication getApplication()
java.lang.String getAvatarId()
null, if no avatar is setjava.lang.String getAvatarUrl()
null, if no avatar is setjava.lang.String getDiscriminator()
java.lang.String getInviteUrl(java.util.Collection<Permission> permissions)
The link is provided in the following format:
https://discordapp.com/oauth2/authorize?client_id=APPLICATION_ID&scope=bot&permissions=PERMISSIONS
Unnecessary query parameters are stripped.
permissions - Possibly empty List of Permissions
that should be requested via invite.java.lang.String getInviteUrl(Permission... permissions)
The link is provided in the following format:
https://discordapp.com/oauth2/authorize?client_id=APPLICATION_ID&scope=bot&permissions=PERMISSIONS
Unnecessary query parameters are stripped.
permissions - Possibly empty array of Permissions
that should be requested via invite.java.lang.String getInviteUrl(java.lang.String guildId,
java.util.Collection<Permission> permissions)
The link is provided in the following format:
https://discordapp.com/oauth2/authorize?client_id=APPLICATION_ID&scope=bot&permissions=PERMISSIONS&guild_id=GUILD_ID
Unnecessary query parameters are stripped.
guildId - The id of the pre-selected guild.permissions - Possibly empty List of Permissions
that should be requested via invite.java.lang.String getInviteUrl(java.lang.String guildId,
Permission... permissions)
The link is provided in the following format:
https://discordapp.com/oauth2/authorize?client_id=APPLICATION_ID&scope=bot&permissions=PERMISSIONS&guild_id=GUILD_ID
Unnecessary query parameters are stripped.
guildId - The id of the pre-selected guild.permissions - Possibly empty array of Permissions
that should be requested via invite.java.lang.String getName()
java.lang.String getToken()
JDABuilder.setToken(String)@CheckReturnValue RestAction<Application.Bot> resetToken()
Possible ErrorResponses for this
update include the following:
ONLY_BOTS_ALLOWED
RestAction - Type: Application.Bot