0.0.4 • Published 3 years ago

@discokit/rest v0.0.4

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

@discokit/rest

Work in progress!

Library for interacting with Discord's REST API.

import { DiscordREST, fetchCurrentUser } from "@discokit/rest";

const rest = new DiscordREST({
  auth: { bot: "MY_BOT_TOKEN" },
});

const user = await fetchCurrentUser(rest);

console.log(user);
// {
//   id: '1234567890',
//   username: "Example Bot",
//   discriminator: '1234',
//   avatar: null,
//   bot: true,
//   system: undefined,
//   mfaEnabled: true,
//   banner: null,
//   accentColor: null,
//   locale: 'en-US',
//   verified: true,
//   email: null,
//   flags: 0,
//   premiumType: 0,
//   publicFlags: 0
// }
0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago

0.0.0

3 years ago