You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Feature/update application model and add endpoints (#24)
* Refactor Application struct and improve documentation
The Application struct in api/application.go has been thoroughly revised for improved clarity and effectiveness. Changes encompass refining documentation, adjusting optional properties based on their functionality, and introducing new fields including 'guilds', 'redirect_uris', and 'interactions_endpoint_url'
* Add Discord application API endpoints
Two key API endpoints have been added to the application, specifically serving Discord. These comprise fetching the current application and editing the current application. The routes for these endpoints have also been introduced.
Icon*string`json:"icon"`// the icon hash of the app
26
-
Descriptionstring`json:"description"`// the description of the app
27
-
RpcOrigins []string`json:"rpc_origins"`// an array of rpc origin urls, if rpc is enabled
28
-
BotPublicbool`json:"bot_public"`// when false only app owner can join the app's bot to guilds
29
-
BotRequireCodeGrantbool`json:"bot_require_code_grant"`// when true the app's bot will only join upon completion of the full oauth2 code grant flow
30
-
TermsOfServiceURLstring`json:"terms_of_service_url,omitempty"`// the url of the app's terms of service
31
-
PrivacyPolicyURLstring`json:"privacy_policy_url,omitempty"`// the url of the app's privacy policy
32
-
OwnerUser`json:"owner,omitempty"`// partial user object containing info on the owner of the application
33
-
VerifyKeystring`json:"verify_key"`// the hex encoded key for verification in interactions and the GameSDK's GetTicket
34
-
Team*Team`json:"team"`// if the application belongs to a team, this will be a list of the members of that team
35
-
GuildIDSnowflake`json:"guild_id,omitempty"`// if this application is a game sold on Discord, this field will be the guild to which it has been linked
36
-
PrimarySkuIDSnowflake`json:"primary_sku_id"`// if this application is a game sold on Discord, this field will be the id of the "Game SKU" that is created, if exists
37
-
Slugstring`json:"slug,omitempty"`// if this application is a game sold on Discord, this field will be the URL slug that links to the store page
38
-
CoverImagestring`json:"cover_image,omitempty"`// the application's default rich presence invite cover image hash
39
-
FlagsApplicationFlags`json:"flags,omitempty"`// the application's public ApplicationFlags
40
-
Tags []string`json:"tags,omitempty"`// up to 5 tags describing the content and functionality of the application
41
-
InstallParamsInstallParams`json:"install_params,omitempty"`// settings for the application's default in-app authorization link, if enabled
42
-
CustomInstallURLstring`json:"custom_install_url,omitempty"`// the application's default custom authorization link, if enabled
43
-
RoleConnectionsVerificationURLstring`json:"role_connections_verification_url"`// the application's role connection verification entry point, which when configured will render the app as a verification method in the guild role verification configuration
23
+
IDSnowflake`json:"id"`// ID of the app
24
+
Namestring`json:"name"`// Name of the app
25
+
Icon*string`json:"icon"`// Icon hash of the app
26
+
Descriptionstring`json:"description"`// Description of the app
27
+
RpcOrigins []string`json:"rpc_origins,omitempty"`// List of RPC origin URLs, if RPC is enabled
28
+
BotPublicbool`json:"bot_public"`// When false, only the app owner can add the app to guilds
29
+
BotRequireCodeGrantbool`json:"bot_require_code_grant"`// When true, the app's bot will only join upon completion of the full OAuth2 code grant flow
30
+
BotUser`json:"bot,omitempty"`// Partial user object for the bot user associated with the app
31
+
TermsOfServiceURLstring`json:"terms_of_service_url,omitempty"`// URL of the app's Terms of Service
32
+
PrivacyPolicyURLstring`json:"privacy_policy_url,omitempty"`// URL of the app's Privacy Policy
33
+
OwnerUser`json:"owner,omitempty"`// Partial user object for the owner of the app
34
+
VerifyKeystring`json:"verify_key"`// Hex encoded key for verification in interactions and the GameSDK's GetTicket
35
+
Team*Team`json:"team"`// If the app belongs to a team, this will be a list of the members of that team
36
+
GuildIDSnowflake`json:"guild_id,omitempty"`// Guild associated with the app. For example, a developer support server.
37
+
GuildGuild`json:"guild,omitempty"`// Partial object of the associated guild
38
+
PrimarySkuIDSnowflake`json:"primary_sku_id,omitempty"`// If this app is a game sold on Discord, this field will be the id of the "Game SKU" that is created, if exists
39
+
Slugstring`json:"slug,omitempty"`// If this app is a game sold on Discord, this field will be the URL slug that links to the store page
* Discord API Wrapper - A custom wrapper for the Discord REST API developed for a proprietary project.
5
+
*
6
+
* This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7
+
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
8
+
*
9
+
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
10
+
*
11
+
* You should have received a copy of the GNU General Public License along with this program.
0 commit comments