NoCap Bots is two processes: a Next.js dashboard and a relay engine that holds the Discord gateway and voice. Create one Discord application for the Callout bot and one per speaker slot, fill in .env.local, and run npm run bot and npm run dev. Whop billing is optional.
Discord applications#
One bot account can hold one voice channel per server, so you need one application for the Callout bot plus one per speaker slot. In the Discord Developer Portal, create the main application, copy its client id, secret and bot token, and add <your app>/api/auth/callback as an OAuth2 redirect. Then create one more application per speaker slot and copy each bot token.
Environment#
DISCORD_CLIENT_ID=your_application_id
DISCORD_CLIENT_SECRET=your_oauth_secret
DISCORD_BOT_TOKEN=shotcaller_bot_token
RELAY_BOT_TOKENS=speaker_token_1,speaker_token_2
AUTH_SECRET=run_openssl_rand_hex_32
CONTROL_SECRET=run_openssl_rand_hex_32
NEXT_PUBLIC_APP_URL=http://localhost:3000Run it#
npm run bot # relay engine + control API on :8787
npm run dev # dashboard on :3000Billing with Whop#
Optional. Without Whop keys a plan is simply a setting. To charge, create four monthly plans with a 7-day trial in Whop, put their ids and your API key in the environment, point a webhook at /api/billing/webhook, and set BILLING_REQUIRED=1. How plans behave for your users is in billing.