-
Add secrets
npx wrangler secret put TOKEN npx wrangler secret put PUBLICKEY
-
Install dependencies
npm i
-
Get your Public Key
- Go to Discord Developer Portal
- Select your bot
- Open General Information from the sidebar
- Copy the Public Key
-
Setup Registrar
- Open
register.js - Replace
"YOUR TOKEN HERE"at line 10 with your token - Replace
"YOUR PUBLIC KEY"at line 12 with your public key - Run:
npm run register
- Open
-
Deploy your project
npx wrangler deploy
-
Copy your deploy URL
-
Set the Interactions Endpoint URL
- Go to Discord Developer Portal
- Select your bot
- Open General Information from the sidebar
- Paste the deploy URL into Interactions Endpoint URL
discordhttps/cloudflare-example
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|