Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(APIApplication): app authorization links and tags #239

Merged
merged 9 commits into from
Mar 29, 2022
20 changes: 19 additions & 1 deletion deno/payloads/v8/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
* Types extracted from https://discord.com/developers/docs/resources/application
*/

import type { Snowflake } from '../../globals.ts';
import type { OAuth2Scopes } from './mod.ts';
import type { Permissions, Snowflake } from '../../globals.ts';
import type { APITeam } from './teams.ts';
import type { APIUser } from './user.ts';

Expand Down Expand Up @@ -91,6 +92,23 @@ export interface APIApplication {
* See https://discord.com/developers/docs/resources/application#application-object-application-flags
*/
flags: ApplicationFlags;
/**
* Up to 5 tags describing the content and functionality of the application
*/
tags?: [string, string?, string?, string?, string?];
/**
* Settings for the application's default in-app authorization link, if enabled
*/
install_params?: APIApplicationInstallParams;
/**
* The application's default custom authorization link, if enabled
*/
custom_install_url?: string;
}

export interface APIApplicationInstallParams {
scopes: OAuth2Scopes[];
permissions: Permissions;
}

/**
Expand Down
20 changes: 19 additions & 1 deletion deno/payloads/v9/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
* Types extracted from https://discord.com/developers/docs/resources/application
*/

import type { Snowflake } from '../../globals.ts';
import type { OAuth2Scopes } from './mod.ts';
import type { Permissions, Snowflake } from '../../globals.ts';
import type { APITeam } from './teams.ts';
import type { APIUser } from './user.ts';

Expand Down Expand Up @@ -91,6 +92,23 @@ export interface APIApplication {
* See https://discord.com/developers/docs/resources/application#application-object-application-flags
*/
flags: ApplicationFlags;
/**
* Up to 5 tags describing the content and functionality of the application
*/
tags?: [string, string?, string?, string?, string?];
/**
* Settings for the application's default in-app authorization link, if enabled
*/
install_params?: APIApplicationInstallParams;
/**
* The application's default custom authorization link, if enabled
*/
custom_install_url?: string;
}

export interface APIApplicationInstallParams {
scopes: OAuth2Scopes[];
permissions: Permissions;
}

/**
Expand Down
20 changes: 19 additions & 1 deletion payloads/v8/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
* Types extracted from https://discord.com/developers/docs/resources/application
*/

import type { Snowflake } from '../../globals';
import type { OAuth2Scopes } from './index';
suneettipirneni marked this conversation as resolved.
Show resolved Hide resolved
import type { Permissions, Snowflake } from '../../globals';
import type { APITeam } from './teams';
import type { APIUser } from './user';

Expand Down Expand Up @@ -91,6 +92,23 @@ export interface APIApplication {
* See https://discord.com/developers/docs/resources/application#application-object-application-flags
*/
flags: ApplicationFlags;
/**
* Up to 5 tags describing the content and functionality of the application
*/
tags?: [string, string?, string?, string?, string?];
/**
* Settings for the application's default in-app authorization link, if enabled
*/
install_params?: APIApplicationInstallParams;
/**
* The application's default custom authorization link, if enabled
*/
custom_install_url?: string;
}

export interface APIApplicationInstallParams {
scopes: OAuth2Scopes[];
permissions: Permissions;
}

/**
Expand Down
20 changes: 19 additions & 1 deletion payloads/v9/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
* Types extracted from https://discord.com/developers/docs/resources/application
*/

import type { Snowflake } from '../../globals';
import type { OAuth2Scopes } from './index';
import type { Permissions, Snowflake } from '../../globals';
import type { APITeam } from './teams';
import type { APIUser } from './user';

Expand Down Expand Up @@ -91,6 +92,23 @@ export interface APIApplication {
* See https://discord.com/developers/docs/resources/application#application-object-application-flags
*/
flags: ApplicationFlags;
/**
* Up to 5 tags describing the content and functionality of the application
*/
tags?: [string, string?, string?, string?, string?];
/**
* Settings for the application's default in-app authorization link, if enabled
*/
install_params?: APIApplicationInstallParams;
/**
* The application's default custom authorization link, if enabled
*/
custom_install_url?: string;
}

export interface APIApplicationInstallParams {
scopes: OAuth2Scopes[];
permissions: Permissions;
}

/**
Expand Down