Discord Bot
Real-time notification engine and admin helper for the Skam ecosystem.
Located in apps/discord-bot
Independent Process
The bot runs on its own Node.js/Bun process, completely independent of the Next.js apps. It can be deployed separately so Discord API traffic never affects storefront performance.
Features
Real-time Notifications
Listens to webhooks and Supabase Realtime to broadcast new orders and stock alerts to designated channels.
Admin Slash Commands
Authorized admins can run quick checks like /order [id] or /stats directly from Discord.
Role Synchronization
Planned: sync store membership tiers with Discord server roles automatically.
Error Reporting
System alerts and error logs pushed to a dedicated admin channel for instant visibility.
Required Environment
DISCORD_TOKENBot authentication token from Discord Developer PortalDISCORD_CLIENT_IDApplication client ID for slash command registrationDISCORD_GUILD_IDTarget server ID for development/testingRunning Locally
Terminal
# Ensure .env has DISCORD_TOKEN and DISCORD_CLIENT_ID
pnpm dev:discord