Skip to content

TenDRILLL/discord-http-interactions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

discord-http-interactions

NPM Version

A JS library to use Discord without the Bot Gateway using HTTP interactions

Usage:

const {Client} = require("discord-http-interactions");

const client = new Client({
    token: "NDg0NDE5MTI0NDMzNTE4NjAy.eyJtZXNzYWdlIjoiWW91IHRob3VnaHQgSSdkIGxlYXZlIGFuIGFjdHVhbCB0b2tlbiBoZXJlPyBTaGFtZSBvbiB5b3UuIn0=.c29tZXJhbmRvbXNoaXRoZXJl",
    publicKey: "a12b3cd45678901234e5678fg901h2i34j567k89l012mn345o6p78901q23rst4",
    port: 13337,
    endpoint: "/api/interactions"
});

client.on("ready",()=>{
    console.log("READY!");
});

client.on("interaction",(interaction)=>{
    interaction.reply({
        content: "Hi!",
        ephemeral: true
    });
});

client.login();

About

A JS (written in TS) library to use Discord without the Bot Gateway using HTTP interactions.

Resources

Stars

Watchers

Forks