1. Run `npm i @points.city/quartz` or `yarn add @points.city/quartz` 2. Setup client and command handler
npm install @points.city/quartz
1. Run npm i @points.city/quartz or yarn add @points.city/quartz
2. Setup client and command handler
Client Example:
``ts
import { Client } from '@points.city/quartz'
import { resolve } from 'path'
const client = new Client({
publicKey: process.env.DISCORD_PUBLIC_KEY!,
token: process.env.DISCORD_TOKEN!,
appID: process.env.DISCORD_APP_ID!,
debug: false
})
client.loadCommands('path to commands')
client.connect(Number(process.env.PORT!))
`
Command Example:
`ts``
client.command({
name: 'ping',
description: 'A command that responds pong',
onRun: async ({ send }) => {
return send({
content: 'Pong!'
})
}
})