From c24584f408f61e641b8036b95f936d1b2181ac78 Mon Sep 17 00:00:00 2001 From: Elysia <71698422+aiko-chan-ai@users.noreply.github.com> Date: Fri, 14 Feb 2025 23:51:55 +0700 Subject: [PATCH] feat(Application): add terms of service, privacy policy URLs, and verification key --- src/structures/interfaces/Application.js | 30 ++++++++++++++++++++++++ typings/index.d.ts | 3 +++ 2 files changed, 33 insertions(+) diff --git a/src/structures/interfaces/Application.js b/src/structures/interfaces/Application.js index f2ba953..60b2d98 100644 --- a/src/structures/interfaces/Application.js +++ b/src/structures/interfaces/Application.js @@ -61,6 +61,36 @@ class Application extends Base { this.icon ??= null; } + if ('terms_of_service_url' in data) { + /** + * The URL of the application's terms of service + * @type {?string} + */ + this.termsOfServiceURL = data.terms_of_service_url; + } else { + this.termsOfServiceURL ??= null; + } + + if ('privacy_policy_url' in data) { + /** + * The URL of the application's privacy policy + * @type {?string} + */ + this.privacyPolicyURL = data.privacy_policy_url; + } else { + this.privacyPolicyURL ??= null; + } + + if ('verify_key' in data) { + /** + * The hex-encoded key for verification in interactions and the GameSDK's GetTicket + * @type {?string} + */ + this.verifyKey = data.verify_key; + } else { + this.verifyKey ??= null; + } + if ('role_connections_verification_url' in data) { /** * This application's role connection verification entry point URL diff --git a/typings/index.d.ts b/typings/index.d.ts index 319fc3f..1180446 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -338,6 +338,9 @@ export abstract class Application extends Base { public icon: string | null; public id: Snowflake; public name: string | null; + public termsOfServiceURL: string | null; + public privacyPolicyURL: string | null; + public verifyKey: string | null; public roleConnectionsVerificationURL: string | null; public approximateGuildCount: number | null; public botPublic: boolean | null;