Skip to content

Nori Integrations

How to add an AI coding agent to your Discord server that opens pull requests

To add an AI coding agent to your Discord server that opens pull requests, create a Discord bot, paste its token into Nori, a cloud coding agent platform, and add the bot to your server. Mention it in a channel and it opens a thread, runs Claude Code, Codex or another agent on a cloud machine with your GitHub repositories, and replies with the pull request link. Members-only access and admin-only threads are built in.

Add a coding agent to your Discord server with one bot token. Mention the bot, and it opens a thread, works on a cloud machine with your repositories, and replies with a GitHub pull request.

Quick answer

Create an application with a bot in the Discord Developer Portal and copy its bot token. In Nori, open Integrations, then Discord, paste the token and save; Nori turns on the Message Content intent for you. Add the bot to your server from the Bot install card, and connect the Jiro (by Nori) GitHub App to your repositories. Now anyone the bot answers can mention it with a task. It opens a thread named after the request, plans, codes, tests, pushes a branch and replies with a pull request.

How it works

The Discord bot is the front door. The work happens on a Nori session machine: an isolated cloud machine with your repositories cloned, your setup script run, and your org skillset and memories loaded.

  1. Mention. Someone mentions the bot in a server channel with a task.
  2. Thread. The bot creates a thread named from the first words of the message and answers there. Replies in the thread continue the same conversation.
  3. Machine. Nori claims a cloud machine and starts the agent your team picked: Claude Code, Codex, Cursor, Gemini through Antigravity, OpenCode or Pi, on your own subscription or API keys.
  4. Progress. Reactions on your message show progress, and a progress card has a Cancel button.
  5. Pull request. The agent pushes a feature branch through the GitHub App and replies with the pull request link and what it tested.
  6. Follow-ups. Reply in the thread with changes. Send !done when the work is finished, and the machine is released.

Discord threads work like Slack threads. Turns you continue from the web dashboard are mirrored back into the Discord thread, so the whole team sees one history.

Set up the Discord bot with just a bot token

You need only the bot token. The server ID is optional.

  1. Create the bot. In the Discord Developer Portal, create an application, add a bot, and copy the bot token. Discord's getting started guide walks through it.
  2. Paste the token in Nori. An org admin opens Integrations โ†’ Discord, pastes the Bot token and saves. Nori checks the token, turns on the Message Content intent and the app's default install settings, and keeps settings you already chose.
  3. Add the bot to your server. Under Bot install, open Add to server. Nori saves the server as soon as the bot joins. The bot answers in that one server.
  4. Check permissions. Bot install lists any missing permission with a Re-authorize with every permission link.
  5. Connect GitHub. Install the Jiro (by Nori) GitHub App and add the repositories every session should start with under Settings โ†’ Environment.
  6. Choose who the bot answers. Keep it open to the server, or switch to members only (below).

From the CLI, the same connection is nori-sessions integrations set-discord --bot-token <token>.

Discord permissions the bot uses and why.
PermissionUsed to
View Channels, Read Message HistorySee the channel and read the thread it is answering
Send Messages, Send Messages in ThreadsAnswer mentions and post automation results
Create Public Threads, Create Private ThreadsOpen a thread per conversation and admin-only threads
Manage Threads, Manage ChannelsTidy private threads and create the onboarding channel
Add Reactions, Attach FilesShow progress and upload files the agent shares

Members-only access and admin-only threads

Community and open-source servers often have more people than the engineering team. Nori lets admins decide who the bot answers.

  • Open (default): anyone in the Discord server can talk to the bot.
  • Members only: only org members who linked their Discord account. To link, a member chooses Link my Discord account in Nori, mentions the bot with !link <code> within 10 minutes, then confirms the account in Nori. Removing someone from the org ends their Discord access.
  • Admin-only threads: Nori's onboarding conversations open as private threads. Only admins and owners with a confirmed link drive them. Anyone else's message is kept as context and does not run.
  • Elevation on request: in other threads, nobody is treated as an admin. !admin asks an org admin to approve elevated access with a single-use link.

Admins can read the audit trail of links and admin-thread decisions for 90 days. For sign-in through your identity provider, see SSO with SAML, SCIM and OIDC.

Worked example: a bug report in a community server

A 15-engineer developer-tools company runs its community on Discord. A user reports a broken CLI flag in #bugs. The server runs in members-only mode, so a linked engineer starts the agent. Names are illustrative.

#bugs

user_kai  09:41
`acme deploy --dry-run` still uploads the bundle on 2.4.1.
[terminal-screenshot.png]

lena (engineer, linked)  09:44
@Jiro in the acme-cli repo, `acme deploy --dry-run` still uploads
the bundle on 2.4.1 (screenshot attached). Reproduce it, add a
failing test, fix it, and open a PR. Do not merge.
[terminal-screenshot.png]

  Thread: "in the acme-cli repo, acme deploy --dry-run..."

  Jiro  09:45   ๐Ÿ‘€
  Reading the screenshot and the deploy command.

  Jiro  09:53
  Cause: deploy.ts calls upload() before checking opts.dryRun.
  PR opened: acme-cli #1207 "Skip upload on --dry-run"
  - New test: deploy dry run makes no network calls
  - 96 tests pass

  lena  10:02
  Also print the files that would be uploaded.

  Jiro  10:08
  Pushed a follow-up commit with the file list. Tests pass.

  lena  10:20
  !done   ๐Ÿ

The reporter could read the thread and the fix, but only linked members could steer the agent. The pull request went through the repository's normal review.

Commands you can send in a thread

Discord thread commands for a Nori session.
CommandWhat it does
!statusSession state, elapsed time, context usage and errors
!thoughtsA snapshot of the agent's work in progress
!interrupt <prompt>Cancel the current turn and start a new prompt
!urlsLinks to the chat, shell and any app the agent is serving
!skillsets switch <name>Switch the thread to another skillset
!tagonlyOnly answer when mentioned in this thread
!doneEnd the conversation and release the machine

Change the model or agent provider for a conversation from the web dashboard.

Scheduled work that posts to Discord

The same bot posts results from automations. Choose Deliver to โ†’ Chat thread, Post in โ†’ Discord, and a channel ID. Each run opens a thread in that channel, and people reply to keep talking to the agent.

nori-sessions triggers create --name "Nightly CI digest" --type cron \
  --cron-schedule "0 9 * * 1-5" --prompt "Summarize yesterday's CI failures." \
  --client discord --channel-id <channel-id>

Nori's own docs and test gardening automations can post to Discord too; see keeping docs and tests current. For more recipes, read coding agent automation recipes.

Nori Enterprise runs the whole platform on-prem or in your own cloud, with integration services included in the deployment.

Frequently asked questions

How do I add an AI coding agent to our Discord server that opens pull requests?

Create a bot in the Discord Developer Portal, paste its bot token into Nori under Integrations then Discord, and add the bot to your server from the Bot install card. Connect the Jiro (by Nori) GitHub App. Mention the bot with a task and it replies in a thread with a pull request.

What do I need from Discord to connect it?

Only the bot token. Nori checks it, turns on the Message Content intent and the default install settings, and saves your server when the bot joins. The server ID is optional.

Can I stop random server members from running the agent?

Yes. Switch Who the bot answers to Members only. Then only org members who linked and confirmed their Discord account can start or steer sessions.

Which coding agents can the Discord bot run?

Any agent Nori runs: Claude Code, Codex, Cursor, Gemini models through Antigravity, OpenCode and Pi, on your own subscriptions or API keys. Admins set the default, and custom agents can carry their own settings.

Can I use Discord and Slack together?

Yes. Both connect to the same Nori organization, with the same repositories, skillsets and memories. Each automation chooses which client and channel it posts in.

Does the agent merge its own pull requests?

Ask it to open pull requests and not merge, and protect your main branch with a required review. The agent then pushes branches and opens pull requests, and people approve what ships.

Sources

Read on December 4, 2026.