Package com.mrivanplays.jdoa2
Class ApplicationInfo
java.lang.Object
com.mrivanplays.jdoa2.ApplicationInfo
Represents information about the application, driven by this discord api wrapper.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
Represents a builder, for easily creatingApplicationInfo
instance. -
Constructor Summary
ConstructorsConstructorDescriptionApplicationInfo
(ApplicationInfo.Builder builder) ApplicationInfo
(String authCode, String redirectUri, String clientId, String clientSecret) -
Method Summary
Modifier and TypeMethodDescriptionstatic ApplicationInfo.Builder
builder()
Creates a newApplicationInfo.Builder
Returns the auth code.Returns the client id of your application, found in the discord application configuration.Returns the client secret of your application, found in the discord application configuration.Returns the application's URL callback.
-
Constructor Details
-
ApplicationInfo
-
ApplicationInfo
-
-
Method Details
-
builder
Creates a newApplicationInfo.Builder
- Returns:
- builder
-
getAuthCode
Returns the auth code. The auth code is a code, received on url callback, which you have to configure in your discord application config.Example of what you need to specify here:
- Open your discord application config
- Navigate to OAuth2
- Add redirect url and save
- Generate OAuth2 link with the supported scopes: identify, email, guilds
- Returns:
- auth code
-
getRedirectUri
Returns the application's URL callback.- Returns:
- redirect uri
-
getClientId
Returns the client id of your application, found in the discord application configuration.- Returns:
- client id
-
getClientSecret
Returns the client secret of your application, found in the discord application configuration.- Returns:
- client secret
-