Slack Notifications
Post updates to Slack with threading support. Create a thread per task, post updates as replies, read replies from the user.
Quick Reference
SCRIPT="${CLAUDE_PLUGIN_ROOT}/scripts/slack.py"
# Create a new thread
python3 "$SCRIPT" thread "Starting: feature X implementation"
# Post update to current thread
python3 "$SCRIPT" update "Completed step 1: database migration"
# Read recent replies from the thread
python3 "$SCRIPT" read # last 10 messages
python3 "$SCRIPT" read 20 # last 20 messages
# Check current thread
python3 "$SCRIPT" status
Workflow
- Task start:
threadwith a descriptive subject - Milestones:
updatewith progress (completed steps, decisions, blockers) - Check for feedback:
readto see if the user replied in the thread - Task end:
updatewith a summary
Setup
Create ~/.claude/slack-notify.json:
{"bot_token": "xoxb-...", "channel": "C..."}
Get these from your Slack app at api.slack.com/apps → OAuth & Permissions (bot token) and channel details (channel ID).
Required bot scopes: chat:write. To read thread replies, add groups:history (private channels) or channels:history (public channels).
Thread State
Active thread stored in ~/.claude/.slack-thread-state.json. Creating a new thread replaces the previous one.