Keys / Discord
DISCORD_BOT_TOKEN
The token your Discord bot calls the Discord API with, sent as Authorization: Bot <token>.
- Expires
- the docs don't say
- API
- none; Developer Portal only
Get it
Create one on discord.com/developers/applications. The steps aren't recorded yet.
Set it
DISCORD_BOT_TOKEN=...
Discord doesn't maintain official SDKs, so none reads it; your app or a community library passes the token in. Or keep it out of .env with keypin: keypin run -- npm run dev
Replace it
- Open your app's Bot page and click Reset Token. Discord shows the new token once.
- Deploy it everywhere that reads
DISCORD_BOT_TOKEN, then restart the bot. - Check that the bot connects with the new token. The docs don't say how long the old one keeps working.
Set rotate_every on the key in keypin.toml and a rotated date on its vault item, and keypin status shows when it's due.