diff --git a/src/Client.ts b/src/Client.ts index 3119525c..38988239 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -41,6 +41,8 @@ import { RE_SPOILER, } from "./lib/regex.js"; +export type Tag = "attachments" | "avatars" | "backgrounds" | "icons" | "banners" | "emojis"; + export type Session = { _id: string; token: string; user_id: string } | string; /** @@ -555,9 +557,10 @@ export class Client extends AsyncEventEmitter { * @param tag Tag * @param file File * @param uploadUrl Media server upload route + * @returns File ID */ async uploadFile( - tag: string, + tag: Tag, file: File, uploadUrl?: string, ): Promise {