Skip to content

Instantly share code, notes, and snippets.

@Slyrith
Created November 21, 2022 01:21
Show Gist options
  • Select an option

  • Save Slyrith/4e1372398ef56772366f159006c1c70f to your computer and use it in GitHub Desktop.

Select an option

Save Slyrith/4e1372398ef56772366f159006c1c70f to your computer and use it in GitHub Desktop.
Aoi.js V5 Setup
const aoijs = require("aoi.js")
const bot = new aoijs.AoiClient({
token: "DISCORD BOT TOKEN",
prefix: "DISCORD BOT PREFIX",
intents: ["GUILDS", "GUILD_MESSAGES"]
})
//Events
bot.onMessage()
bot.onInteractionCreate()
//Status
bot.status({
text: "TEXT",
type: "PLAYING",
})
//Variable
bot.variables({
variable: "value"
})
//Command Example (ping)
bot.command({
name: "ping",
code: `Pong! $pingms`
})
//Ready Event
bot.readyCommand({
channel: "CHANNEL ID",
code: `$log[Ready on $userTag[$clientID]]`
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment