ISnowflakepublic interface ApplicationInfo extends ISnowflake
JDABot.getApplicationInfo()| Modifier and Type | Method | Description |
|---|---|---|
boolean |
doesBotRequireCodeGrant() |
Whether the bot requires code grant to invite or not.
|
java.lang.String |
getDescription() |
The description of the bot's application.
|
java.lang.String |
getIconId() |
The icon id of the bot's application.
|
java.lang.String |
getIconUrl() |
The icon-url of the bot's application.
|
default java.lang.String |
getInviteUrl(long guildId,
java.util.Collection<Permission> permissions) |
Creates a OAuth invite-link used to invite the bot.
|
default java.lang.String |
getInviteUrl(long guildId,
Permission... permissions) |
Creates a OAuth invite-link used to invite the bot.
|
java.lang.String |
getInviteUrl(java.lang.String guildId,
java.util.Collection<Permission> permissions) |
Creates a OAuth invite-link used to invite the bot.
|
default java.lang.String |
getInviteUrl(java.lang.String guildId,
Permission... permissions) |
Creates a OAuth invite-link used to invite the bot.
|
default java.lang.String |
getInviteUrl(java.util.Collection<Permission> permissions) |
Creates a OAuth invite-link used to invite the bot.
|
default java.lang.String |
getInviteUrl(Permission... permissions) |
Creates a OAuth invite-link used to invite the bot.
|
JDA |
getJDA() |
The
JDA instance of this ApplicationInfo
(the one logged into this application's bot account). |
java.lang.String |
getName() |
The name of the bot's application.
|
User |
getOwner() |
The owner of the bot's application.
|
boolean |
isBotPublic() |
Whether the bot is public or not.
|
getCreationTime, getId, getIdLongboolean doesBotRequireCodeGrant()
This means that additional OAuth2 steps are required to authorize the application to make a bot join a guild
like &response_type=code together with a valid &redirect_uri.
For more information look at the Discord OAuth2 documentation.
java.lang.String getDescription()
String if no description is definedjava.lang.String getIconId()
java.lang.String getIconUrl()
default 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 Collection of Permissions
that should be requested via invite.default 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 - 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 Collection of Permissions
that should be requested via invite.java.lang.NumberFormatException - If the provided id cannot be parsed by Long.parseLong(String)default java.lang.String getInviteUrl(long 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 Collection of Permissions
that should be requested via invite.default 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.NumberFormatException - If the provided id cannot be parsed by Long.parseLong(String)default java.lang.String getInviteUrl(long 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.JDA getJDA()
JDA instance of this ApplicationInfo
(the one logged into this application's bot account).java.lang.String getName()
User getOwner()
boolean isBotPublic()