- Node.js (https://nodejs.org/en/download)
- Bun (Install instructions https://bun.sh/)
- Postgres (
brew install postgresql)
To save data about users and keys, we must setup postgres
brew services start postgres
psql -U {your username} -d moondb -h localhost
Now get your url, it's how you connect to your db. Save it into /bot/.env. It will be the beginning of the rest of your info
DATABASE_URL=postgresql://svapnil:{your_password}@localhost:5432/moondb
Go to https://discord.com/developers/applications and make a new Application
Create a new app title "Name's Moonbot Dev"
You should then make the profile image of the app a Blackpink member Get Client ID and Client Secret here:
Save these variables here:
# Dev
DISCORD_BOT_TOKEN=
DISCORD_CLIENT_ID=
Select these things to invite OAuth Link in the OAuth tab.
You will have to register /wallet, etc on the bot. Make sure the bot credentials are in the /scripts/sync_commands folder via another .env then run bun i && bun run.ts in sync_commands
bun i
bunx prisma migrate dev
This should basically run through the schema and setup your db.
lol
bun i
npm run dev
Congrats! Now use your dev bot on the dev group chat.