A discord bot written in Golang
Find a file
2023-11-10 19:14:09 -07:00
.github/workflows Add auto deploy 2023-10-17 18:20:22 -03:00
src Update tts.ts 2023-11-10 19:14:09 -07:00
.dockerignore Fly 2023-10-17 14:56:49 -03:00
.gitignore First iteration! 2023-06-04 20:06:16 -06:00
.npmrc PLSPLSPLS 2023-07-21 22:55:20 -06:00
.prettierignore First iteration! 2023-06-04 20:06:16 -06:00
.sapphirerc.json First iteration! 2023-06-04 20:06:16 -06:00
Dockerfile Fly 2023-10-17 14:56:49 -03:00
fly.toml Fix 2023-10-19 00:58:00 -06:00
package.json New super secret beta command 2023-11-09 21:36:29 -07:00
pnpm-lock.yaml New super secret beta command 2023-11-09 21:36:29 -07:00
README.md Removed stability 2023-11-10 18:58:01 -07:00
tsconfig.json I hate that this is needed... sapphire... fix your shit 2023-09-07 00:18:03 -06:00

HimBot

A discord bot written in Typescript.

It's dangerous to go alone! Take this!

  • Install Nodejs 18 or later here (required)
  • The pnpm package manager npm i -g pnpm (recommended)

Structure

Commands and Listeners are all stored in named files within the src/commands and src/listeners directories respectively.

Running Locally

  • Copy .env.example and rename to .env
  • Create a Discord Bot with all gateway permissions enabled
  • Generate a token for this discord bot and paste it in the .env for DISCORD_TOKEN
  • Generate and provide an OpenAPI token and paste it in the .env for OPENAI_API_KEY
  • Run pnpm dev to run locally

Adding the bot to a server

Use the following link (replacing DISCORD_CLIENT_ID with your own bot's client ID of course...) to add your bot: https://discord.com/oauth2/authorize?client_id=DISCORD_CLIENT_ID&scope=bot&permissions=8

Commands

ask

Description

A command that returns the answer to your prompt for OpenAI's GPT 4.0 turbo model.

Usage

/ask prompt:prompt_text

borf

Description

A command that returns a random picture of a dog.

Usage

/borf

dad

Description

A command that returns a random dad joke.

Usage

/dad

fancypic

Description

A command that return an image using DALL.E with "hd" quality.

Usage

/fancypic prompt

pic

Description

A command that return an image using DALL.E with "standard" quality.

Usage

/pic prompt

ping

Description

A command that returns the latency for the bot, and the latency for the Discord API. Useful for bot debugging.

Usage

/ping

quack

Description

A command that returns a random picture of a duck.

Usage

/quack

support

Description

A command that returns a Stripe link that can be used to fund credits for the AI commands.

Usage

/support

wryna

Description

A command that returns "my nickname in highschool" response given your prompt

Usage

/wryna nickname:butts