Skip to content

Discord

Usejarvis can be controlled through a Discord bot. Send messages, receive responses, approve actions, and get notifications within Discord.

  1. Go to the Discord Developer Portal
  2. Click New Application and give it a name (e.g., “Usejarvis”)
  3. Navigate to the Bot section
  4. Click Reset Token to generate a bot token, copy it
  5. Under Privileged Gateway Intents, enable Message Content Intent
  1. Navigate to the OAuth2 > URL Generator section
  2. Select the bot scope
  3. Select these permissions:
    • View Channels
    • Send Messages
    • Read Message History
  4. Copy the generated URL and open it in your browser
  5. Select your server and authorize

The adapter sends plain text only, so no other permissions are required.

  1. In Discord, open Settings > Advanced and enable Developer Mode
  2. Right-click your username and select Copy User ID

Open the dashboard and go to SettingsChannelsDiscord. Paste the bot token, add your user ID to allowed users, optionally set the guild (server) ID, enable the channel, and save. Changes apply immediately, no daemon restart needed.

For reference, the setting shape is:

channels:
discord:
enabled: true
bot_token: "MTIz..."
allowed_users: ["123456789012345678"] # Your Discord user ID (string)
guild_id: "987654321098765432" # Optional: restrict to one server

Channel settings live in the settings database; a channels: block in config.yaml is imported once at boot for backward compatibility.

Important: if allowed_users is empty, anyone who can message the bot can use it. Always set at least your own ID.

Usejarvis remembers the last channel it heard from and uses it as the target for notifications and approvals. Message the bot once (DM or server channel) before expecting pushes.

The bot replies to every message it can read from an allowed user, in DMs and in any channel it has access to. There is no mention requirement; an @Usejarvis prefix is just sent to the model as text. Restrict the bot’s channel access in Discord and set allowed_users accordingly.

You: What's the status of the deployment?
Usejarvis: The deployment pipeline completed successfully 5 minutes ago...

Audio attachments (ogg, mp3, wav, m4a) are transcribed via your configured STT provider, and Usejarvis responds as text.

All approval requests are pushed to your connected channels as plain text:

[APPROVAL NEEDED]
Action: run_command (execute_command)
Agent: main
Reason: Clearing the build cache
Reply with:
approve a1b2c3d4
deny a1b2c3d4

Reply in the channel with approve <id> or deny <id> using the short ID from the message.

Usejarvis pushes to Discord: all approval requests, urgent proactive notifications (prefixed [URGENT]), heartbeat messages, workflow results when a flow targets Discord, and awareness suggestions when no dashboard client is connected.

Set guild_id to restrict the bot to a single Discord server. Note that guild_id restricts server messages only: direct messages from allowed users are always accepted regardless of guild_id. allowed_users is the control that covers DMs.

Add multiple user IDs (as strings) to allowed_users. Messages from users not in the list are silently ignored.

  • Message length: Discord limits messages to 2000 characters. Long responses are split across multiple messages.
  • Text only: the Discord adapter sends text. Screenshots and images are not sent as attachments.
  • Rate limits: handled by the Discord client library’s internal request queue.