mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-17 19:58:18 +00:00
5f1b82a4e8
* fix(rest/process_request): use DiscordHTTPResponseCodes * refactor: remove RequestManager * refactor: remove RequestManager and use runMethod()
10 lines
309 B
TypeScript
10 lines
309 B
TypeScript
import { rest } from "../../rest/rest.ts";
|
|
import { endpoints } from "../../util/constants.ts";
|
|
|
|
/** Returns an invite for the given code. */
|
|
export async function getInvite(inviteCode: string) {
|
|
const result = await rest.runMethod("get", endpoints.INVITE(inviteCode));
|
|
|
|
return result as InvitePayload;
|
|
}
|