From 822956fe788f8eeda5da683189973bd6667cbc96 Mon Sep 17 00:00:00 2001 From: Almeida Date: Wed, 14 Aug 2024 23:58:20 +0100 Subject: [PATCH] feat: add Get Sticker Pack endpoint (#1053) --- deno/rest/v10/mod.ts | 8 ++++++++ deno/rest/v10/sticker.ts | 5 +++++ deno/rest/v9/mod.ts | 8 ++++++++ deno/rest/v9/sticker.ts | 5 +++++ rest/v10/index.ts | 8 ++++++++ rest/v10/sticker.ts | 5 +++++ rest/v9/index.ts | 8 ++++++++ rest/v9/sticker.ts | 5 +++++ 8 files changed, 52 insertions(+) diff --git a/deno/rest/v10/mod.ts b/deno/rest/v10/mod.ts index c92dd726..05842f81 100644 --- a/deno/rest/v10/mod.ts +++ b/deno/rest/v10/mod.ts @@ -856,6 +856,14 @@ export const Routes = { return '/sticker-packs' as const; }, + /** + * Route for: + * - GET `/sticker-packs/{pack.id}` + */ + stickerPack(packId: Snowflake) { + return `/sticker-packs/${packId}` as const; + }, + /** * Route for: * - GET `/sticker-packs` diff --git a/deno/rest/v10/sticker.ts b/deno/rest/v10/sticker.ts index b8e9c615..6069e265 100644 --- a/deno/rest/v10/sticker.ts +++ b/deno/rest/v10/sticker.ts @@ -12,6 +12,11 @@ export interface RESTGetStickerPacksResult { sticker_packs: APIStickerPack[]; } +/** + * https://discord.com/developers/docs/resources/sticker#get-sticker-pack + */ +export type RESTGetAPIStickerPack = APIStickerPack; + /** * https://discord.com/developers/docs/resources/sticker#list-sticker-packs * diff --git a/deno/rest/v9/mod.ts b/deno/rest/v9/mod.ts index 862d9862..deab1427 100644 --- a/deno/rest/v9/mod.ts +++ b/deno/rest/v9/mod.ts @@ -865,6 +865,14 @@ export const Routes = { return '/sticker-packs' as const; }, + /** + * Route for: + * - GET `/sticker-packs/{pack.id}` + */ + stickerPack(packId: Snowflake) { + return `/sticker-packs/${packId}` as const; + }, + /** * Route for: * - GET `/sticker-packs` diff --git a/deno/rest/v9/sticker.ts b/deno/rest/v9/sticker.ts index 6ca28f2d..606ea2e7 100644 --- a/deno/rest/v9/sticker.ts +++ b/deno/rest/v9/sticker.ts @@ -12,6 +12,11 @@ export interface RESTGetStickerPacksResult { sticker_packs: APIStickerPack[]; } +/** + * https://discord.com/developers/docs/resources/sticker#get-sticker-pack + */ +export type RESTGetAPIStickerPack = APIStickerPack; + /** * https://discord.com/developers/docs/resources/sticker#list-sticker-packs * diff --git a/rest/v10/index.ts b/rest/v10/index.ts index 880d747a..80c4b0d0 100644 --- a/rest/v10/index.ts +++ b/rest/v10/index.ts @@ -856,6 +856,14 @@ export const Routes = { return '/sticker-packs' as const; }, + /** + * Route for: + * - GET `/sticker-packs/{pack.id}` + */ + stickerPack(packId: Snowflake) { + return `/sticker-packs/${packId}` as const; + }, + /** * Route for: * - GET `/sticker-packs` diff --git a/rest/v10/sticker.ts b/rest/v10/sticker.ts index 21f3ab00..2479bdba 100644 --- a/rest/v10/sticker.ts +++ b/rest/v10/sticker.ts @@ -12,6 +12,11 @@ export interface RESTGetStickerPacksResult { sticker_packs: APIStickerPack[]; } +/** + * https://discord.com/developers/docs/resources/sticker#get-sticker-pack + */ +export type RESTGetAPIStickerPack = APIStickerPack; + /** * https://discord.com/developers/docs/resources/sticker#list-sticker-packs * diff --git a/rest/v9/index.ts b/rest/v9/index.ts index 8f8a696b..31df4114 100644 --- a/rest/v9/index.ts +++ b/rest/v9/index.ts @@ -865,6 +865,14 @@ export const Routes = { return '/sticker-packs' as const; }, + /** + * Route for: + * - GET `/sticker-packs/{pack.id}` + */ + stickerPack(packId: Snowflake) { + return `/sticker-packs/${packId}` as const; + }, + /** * Route for: * - GET `/sticker-packs` diff --git a/rest/v9/sticker.ts b/rest/v9/sticker.ts index df27abc6..8b20500f 100644 --- a/rest/v9/sticker.ts +++ b/rest/v9/sticker.ts @@ -12,6 +12,11 @@ export interface RESTGetStickerPacksResult { sticker_packs: APIStickerPack[]; } +/** + * https://discord.com/developers/docs/resources/sticker#get-sticker-pack + */ +export type RESTGetAPIStickerPack = APIStickerPack; + /** * https://discord.com/developers/docs/resources/sticker#list-sticker-packs *