Package Exports
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (acp-discord) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
acp-discord
Discord bot that connects coding agents (Claude Code, Codex, etc.) to Discord channels via the Agent Client Protocol (ACP).
Send a message in Discord, get AI coding assistance back — with tool call visualization, permission prompts, and real-time streaming.
Features
- Slash commands & mentions —
/ask <message>or@bot message - Real-time streaming — agent responses stream into Discord with smart message splitting
- Tool call visualization — see what the agent is doing with emoji status indicators
- Permission UI — Discord buttons for approving/denying agent actions
- Multi-agent support — different channels can use different agents
- Daemon mode — runs in background with auto-start (systemd/launchd)
- Interactive setup — guided
initwizard for first-time configuration
Prerequisites
- Node.js >= 18
- A Discord bot token (create one here)
- An ACP-compatible coding agent installed and working — the
initwizard uses an agent to help generate your config. For example, install Claude Code and verify it runs withclaude --version.
Quick Start
# Run the setup wizard (interactive, agent-driven)
npx acp-discord init
# Start the daemon
npx acp-discord daemon startConfiguration
Config lives at ~/.acp-discord/config.toml:
[discord]
token = "your-discord-bot-token"
[agents.claude]
command = "claude-code"
args = ["--acp"]
cwd = "/path/to/your/project"
idle_timeout = 600 # seconds, optional
[channels.1234567890123456]
agent = "claude"
cwd = "/override/path" # optional, per-channel overrideDiscord Bot Setup
- Go to Discord Developer Portal
- Create a new application → Bot → copy the token
- Enable Message Content Intent under Bot settings
- Invite the bot to your server with
bot+applications.commandsscopes - Copy the channel ID(s) you want the bot to respond in (right-click channel → Copy Channel ID)
Usage
CLI Commands
# Interactive setup wizard
acp-discord init
# Daemon management
acp-discord daemon start # Start in background
acp-discord daemon run # Run in foreground (for service managers)
acp-discord daemon stop # Graceful shutdown
acp-discord daemon status # Check if running
# Auto-start on boot
acp-discord daemon enable # Setup systemd (Linux) / launchd (macOS)
acp-discord daemon disable # Remove auto-startDiscord Commands
| Command | Description |
|---|---|
/ask <message> |
Send a prompt to the coding agent |
@bot <message> |
Mention the bot to send a prompt |
Development
pnpm dev # Run with tsx (auto-reload)
pnpm test # Run tests
pnpm test:watch # Watch modeArchitecture
Discord User
↓ slash command / mention
Discord Bot (discord.js)
↓ channel routing
Session Manager (per-channel sessions)
↓ spawn agent subprocess
ACP Client (JSON-RPC over stdio)
↓ prompt / permissions / tool calls
Agent (claude-code, codex, etc.)
↑
Discord messages, embeds, buttonsLicense
MIT