slack
Original:🇺🇸 English
Translated
13 scripts
Slack workspace integration: 7 on-demand scripts (post, read, search, react, upload, channels, users) + Session Bridge (connect any Claude Code session to Slack via background listener + inbox.jsonl). Daemon, soul engine, and memory system live in Claudicle (github.com/tdimino/claudicle).
5installs
Added on
NPX Install
npx skill4agent add tdimino/claude-code-minoan slackTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →Slack Skill
Slack workspace integration with two components:
- Scripts — 7 Python scripts for on-demand Slack operations (bundled here)
- Session Bridge — connect THIS Claude Code session to Slack (background listener + inbox file, no extra API costs)
Daemon & Soul Engine: The Claudicle daemon (unified launcher, soul engine, cognitive pipeline, three-tier memory, Soul Monitor TUI) now lives in its own repo: github.com/tdimino/claudicle. Install Claudicle separately for daemon features.
When to Use This Skill
Scripts (on-demand)
- Posting messages to Slack channels or threads
- Reading channel history or thread replies
- Searching messages or files across the workspace
- Adding or managing reactions on messages
- Uploading files or code snippets
- Listing channels, getting channel info, or joining channels
- Looking up users by name, ID, or email
Session Bridge (recommended)
- Connecting any running Claude Code session to Slack
- Responding to @mentions and DMs with full tool access (this session IS the brain)
- No extra API costs — messages processed in the current session context
- Auto-notification of new messages via UserPromptSubmit hook
- Personality as Claudicle via soul.md instructions (no XML machinery needed)
Prerequisites
All scripts require the environment variable (a Bot User OAuth Token starting with ). Scripts also require ().
SLACK_BOT_TOKENxoxb-requestsuv pip install --system requestsbash
# Verify token is set
echo $SLACK_BOT_TOKENFirst-Time Setup
- Go to api.slack.com/apps -> Create New App -> From Scratch
- Name it "Claude Code" -> select your workspace
- OAuth & Permissions -> Bot Token Scopes -> add all:
app_mentions:read- ,
channels:history,groups:history,im:historympim:history - ,
channels:read,groups:read,im:readim:write chat:write- ,
files:writefiles:read - ,
reactions:writereactions:read search:read- ,
users:readusers:read.email - (optional — enables green presence dot)
users:write
- Settings -> Socket Mode -> toggle ON -> generate an App-Level Token:
- Name:
socket-mode - Scope:
connections:write - Copy the token
xapp-
- Name:
- Event Subscriptions -> toggle ON (no Request URL needed with Socket Mode) -> Subscribe to Bot Events -> add:
- — channel @mentions
app_mention - — direct messages (required for DMs to work)
message.im - — App Home tab rendering
app_home_opened
- App Home -> Show Tabs -> enable "Allow users to send Slash commands and messages from the messages tab"
- Install to Workspace -> approve permissions -> copy Bot User OAuth Token
- Set environment variables (add to shell profile):
bash
export SLACK_BOT_TOKEN=xoxb-... # Bot User OAuth Token export SLACK_APP_TOKEN=xapp-... # App-Level Token (Socket Mode) - Invite the bot to channels:
/invite @Claude Code
After any scope or event subscription change: reinstall the app (Install App -> Reinstall to Workspace) and restart the listener.
Quick Start
bash
# Post a message
python3 ~/.claude/skills/slack/scripts/slack_post.py "#general" "Hello from Claude"
# Read recent messages
python3 ~/.claude/skills/slack/scripts/slack_read.py "#general" -n 10
# Search the workspace
python3 ~/.claude/skills/slack/scripts/slack_search.py "deployment status"
# Connect this session to Slack via Claudicle Session Bridge
# (requires Claudicle installed — see github.com/tdimino/claudicle)
cd ~/.claudicle/daemon && python3 slack_listen.py --bg
python3 ~/.claude/skills/slack/scripts/slack_check.pySession Bridge
Connect any running Claude Code session to Slack. A background listener catches @mentions and DMs -> . This session reads the inbox, processes with full tool access, posts responses back. No extra API costs.
inbox.jsonlRequires Claudicle daemon installed — see github.com/tdimino/claudicle.
bash
# Connect
cd ~/.claudicle/daemon && python3 slack_listen.py --bg
# Check messages
python3 ~/.claude/skills/slack/scripts/slack_check.py
# Respond to thread, remove hourglass, mark handled
python3 ~/.claude/skills/slack/scripts/slack_post.py "C12345" "response" --thread "TS"
python3 ~/.claude/skills/slack/scripts/slack_react.py "C12345" "TS" "hourglass_flowing_sand" --remove
python3 ~/.claude/skills/slack/scripts/slack_check.py --ack 1
# Disconnect
cd ~/.claudicle/daemon && python3 slack_listen.py --stopSoul Formatter (optional): adds Open Souls cognitive step formatting — perception framing, dialogue extraction, monologue logging.
scripts/slack_format.pybash
python3 slack_format.py perception "Tom" "What's the status?" # -> Tom said, "..."
echo "$raw" | python3 slack_format.py extract # -> external dialogue only
echo "$raw" | python3 slack_format.py extract --narrate --log # -> narrated + logged
python3 slack_format.py instructions # -> cognitive step XML formatAutomated Respond: processes all pending messages as Claudicle with full cognitive steps — perception, monologue, dialogue, post, ack — in a single invocation. See .
/slack-respond~/.claude/skills/slack-respond/SKILL.mdFor full installation, architecture, inbox format, auto-notification hook, and troubleshooting, see .
references/session-bridge.mdScript Selection Guide
| Task | Script | Example |
|---|---|---|
| Post a message | | |
| Reply to a thread | | |
| Schedule a message | | |
| Read channel history | | |
| Read thread | | |
| Search messages | | |
| Search files | | |
| Add reaction | | |
| Upload file | | |
| Share code snippet | | |
| List channels | | |
| Join channel | | |
| Find user by email | | |
For full script documentation (all parameters, examples, test suite, common workflows), see .
references/scripts-reference.mdRate Limit Awareness
| Tier | Rate | Key Methods |
|---|---|---|
| Tier 1 | 1/min | |
| Tier 2 | 20/min | |
| Tier 3 | 50/min | |
| Tier 4 | 100+/min | |
| Special | 1/sec/channel | |
All scripts handle rate limits automatically via (local cooldown + retry with ). See for full details.
_slack_utils.pyRetry-Afterreferences/rate-limits.mdTroubleshooting
| Problem | Fix |
|---|---|
| Bot not responding to @mentions | Enable Socket Mode; verify |
| "missing_scope" error | Add the missing scope in OAuth & Permissions -> reinstall app |
| No search results | Invite bot to channels with |
| Rate limited (429) | Scripts auto-retry; reduce batch sizes |
| "Sending messages turned off" | App Home -> enable "Allow users to send Slash commands and messages from the messages tab" |
| No green presence dot | Add |
| App Home tab blank | Subscribe to |
For daemon-specific troubleshooting (soul engine, memory, launcher), see Claudicle docs.
File Structure
scripts/
├── slack_check.py # Session Bridge: read/ack inbox messages
├── slack_inbox_hook.py # Session Bridge: UserPromptSubmit auto-check hook
├── slack_format.py # Soul formatter: perception/extract/instructions (Open Souls paradigm)
├── slack_post.py # Post messages to channels/threads
├── slack_read.py # Read channel history or threads
├── slack_search.py # Search messages or files
├── slack_react.py # Add/remove reactions
├── slack_upload.py # Upload files or snippets
├── slack_channels.py # List/join channels
├── slack_users.py # Look up users
└── _slack_utils.py # Shared auth, rate limiting, API callsReference Index
| Reference | Contents |
|---|---|
| Session Bridge: installation, architecture, inbox format, usage workflow, soul formatter, troubleshooting |
| Unified launcher: installation, architecture, per-channel sessions, SDK integration, data flows, threading model |
| Soul engine cognitive steps, memory tiers, XML format, App Home, Soul Monitor TUI |
| Full documentation for all 7 scripts, test suite, common workflows |
| User model interview, CLAUDE.md generation, export commands |
| Slack API rate limit tiers and handling strategy |
Assets
- — Slack app icon for bot configuration
assets/app-icon.png