Home > Net >  how to sent request to discord bot API?
how to sent request to discord bot API?

Time:07-07

How do I properly send a discord API request, and where do I get a valid token to do that because my discord bot token did not work there?

async function APIrequest(){
    
    const lib = require('lib')({token: 'which API key?'});
    
    let result = await lib.discord.channels['@0.3.2'].retrieve({
      channel_id: channelid
    });
    
    console.log("result")
    console.log(result)
}

CodePudding user response:

I assume you'll find what you are looking for here: enter image description here

  • Related