0.0.5 • Published 4 years ago

easy-discord-join v0.0.5

Weekly downloads
4
License
ISC
Repository
-
Last release
4 years ago

Easy Discord Join


Usage:

var DiscordJoin = require("easy-discord-join")
var JoinClient = new DiscordJoin({
  CLIENT_SECRET: 'client_secret',
  CLIENT_ID: 'client_id',
  SERVER_ID: 'server_id', //server to add users to
  CALLBACK_URL: 'https://yourcallbackurl.com/callbackroute', //callback uri
  TOKEN: 'discord_bot_token'
})

async function addUser(userID, access_token) {
  return await JoinClient.addMember(userID, accecss_token)
}

addUser('0100101010101001', 'kbdaas.92JEHGF') //fake userid and access_token, but who cares?

addMember(userID, access_token) -

  • userID: ID of user adding to server
  • access_token: Access Token for the user (granted from OAuth callback, check example @ line 21 for access_token usage.)

Check the API for more info.

0.0.3

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago