Discord
Discord bot settings, connection status, and test payload.
DiscordSettingsController
- Route prefix:
api/settings/discord - Auth: All endpoints require admin role.
| Method | Path | Description | Request | Response |
|---|---|---|---|---|
| GET | / | Current Discord settings (bot token masked) | { enabled, botToken (masked), chatBridgeEnabled, chatBridgeChannelId, eventNotificationsEnabled, eventChannelId, notifyPlayerJoin, notifyPlayerLeave, notifyServerStart, notifyServerStop, notifyBloodMoon, slashCommandsEnabled, serverName, showPlayerCountInStatus } | |
| PUT | / | Update Discord settings | Same shape as GET, with botToken in plaintext | string |
| GET | /status | Bot connection status | { isConnected, botUsername, latencyMs } | |
| POST | /test | Send a test embed to the configured event channel | string |
Notes
- The
botTokenfield is returned masked onGET(to avoid leaking it back to someone inspecting the response). APUTexpects the plaintext token. slashCommandsEnabledtoggles a registration call on bot startup. Discord caches command registration up to an hour, so command changes may take a while to appear.POST /testis a quick way to verify the bot has permissions to post in the event channel without waiting for a real event.
See also: Configuration → Discord Integration for setup walkthrough.