Skip to content

Discord bot that delivers news from the game's official website.

License

Notifications You must be signed in to change notification settings

luisfun/discord-bot-hoyo-news

Repository files navigation

⚠️ I think that you need a paid plan for workers to run this program on cloudflare.

🚀 Getting Started

Git Node.js

1. Clone and Install

git clone https://github.com/luisfun/discord-bot-hoyo-news discord-bot-hoyo-news
cd discord-bot-hoyo-news
npm i

2. Set Environment Variables

Create a New Application from Dashboard.

2.1 Set Local

Rename the file example.dev.var and create a .dev.var file.

Enter information in .dev.var, referring to the Official Docs.

2.2 Set Workers

npx wrangler secret put DISCORD_APPLICATION_ID
npx wrangler secret put DISCORD_PUBLIC_KEY
npx wrangler secret put DISCORD_TOKEN

3. Create Database and Tables

npx wrangler d1 create discord-bot-hoyo-news

Update wrangler.toml with what is displayed on success.

npx wrangler d1 execute discord-bot-hoyo-news --file=./schema.sql

4. Register Commands and Deploy

npm run register
npm run deploy

5. Set Endpoint URL

Enter https://discord-bot-hoyo-news.YOUER_DOMAIN.workers.dev in the INTERACTIONS ENDPOINT URL.

📑 Official Docs

Discord Bot

Special Thanks

timelis

About

Discord bot that delivers news from the game's official website.

Topics

Resources

License

Stars

Watchers

Forks