一键导入
agent-slack
Use when working with Slack: read/search/send messages, inspect channels/threads/users, add reactions, manage canvases, or mark read.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when working with Slack: read/search/send messages, inspect channels/threads/users, add reactions, manage canvases, or mark read.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Use only when the user explicitly asks or allows delegating implementation to a Codex worker — launch Pi running openai-codex/gpt-5.6-sol (xhigh) as a visible sidecar implementer that this session orchestrates over AMQ. Write exact task specs, dispatch with --kind todo, validate the results yourself, then iterate, resume, respawn, or launch another worker. Never invoke on your own initiative.
Use only when the user explicitly allows or asks for this skill to be invoked to pair with a second agent harness — launch a sidecar, get a second opinion from another agent, have one harness drive another, or review work with another agent over AMQ. Otherwise, never invoke it.
first step of planning
convert structure outline into a detailed implementation plan
Create a Product Requirements Document with inline mockups
generate research questions based on a task, spec, or ticket
| name | agent-slack |
| description | Use when working with Slack: read/search/send messages, inspect channels/threads/users, add reactions, manage canvases, or mark read. |
agent-slackagent-slack is a CLI binary on $PATH. Invoke directly (e.g. agent-slack user list).
When sending or drafting any Slack message on Thierry's behalf, always append the footer on a new final line:
_sent from pi_
For agent-slack message send, include the footer in the <text> argument. For agent-slack message draft, ensure the final editor content includes the footer before sending. This applies to channel posts, DMs, group DMs, thread replies, and messages with attachments.
If agent-slack is not found on $PATH, install it:
curl -fsSL https://raw.githubusercontent.com/stablyai/agent-slack/main/install.sh | sh (recommended)npm i -g agent-slack (requires Node >= 22.5)nix run github:stablyai/agent-slack -- <args> (no install needed, prefix all commands)Claude Code's permission checker has security heuristics that force manual approval prompts. Avoid these patterns to keep commands auto-allowed. See: https://github.com/anthropics/claude-code/issues/34379
# anywhere in the command string. Treated as a comment delimiter even inside quotes. Use bare channel names (general not #general). No # comments in inline scripts — use the Bash tool's description parameter instead.'' (consecutive single quotes) or "" (consecutive double quotes). Triggers "potential obfuscation" check. Avoid Python empty string literals like d.get('key', '') — use d.get('key') instead.| jq for filtering — no python3, no other commands. python3 -c is not in the allow list and triggers prompts. jq with single-quote-only expressions (no " inside) is safe:
agent-slack search ... | python3 -c "..." (not allowed)agent-slack search ... | jq '.a + "x"' (mixed quotes)agent-slack search ... | jq '.a'agent-slack search ... | jq '.messages[] | .ts'|| or && chains. Run multiple agent-slack commands as separate Bash tool calls.>, >>). Process JSON output directly, don't write to files.Authentication is automatic on macOS and Windows (Slack Desktop first, then Chrome/Firefox fallbacks on macOS).
If credentials aren’t available, run one of:
agent-slack auth import-desktop
agent-slack auth test
agent-slack auth import-chrome
agent-slack auth test
agent-slack auth import-firefox
agent-slack auth test
export SLACK_TOKEN="xoxc-..."
export SLACK_COOKIE_D="xoxd-..."
agent-slack auth test
export SLACK_TOKEN="xoxb-..." # or xoxp-...
agent-slack auth test
Check configured workspaces:
agent-slack auth whoami
agent-slack message get "https://workspace.slack.com/archives/C123/p1700000000000000"
agent-slack message list "https://workspace.slack.com/archives/C123/p1700000000000000"
To see what's been posted recently in a channel (channel history):
agent-slack message list "general" --limit 20
agent-slack message list "C0123ABC" --limit 10
agent-slack message list "general" --with-reaction eyes --oldest "1770165109.000000" --limit 20
agent-slack message list "general" --without-reaction dart --oldest "1770165109.000000" --limit 20
This returns the most recent messages in chronological order. Use --limit to control how many (default 25).
When using --with-reaction or --without-reaction, you must also pass --oldest to bound scanning.
message get/list and search auto-download attachments and include file metadata in JSON output (typically under message.files[] / files[]), including name when available and path for the local download. Failed message attachment downloads keep the attachment entry, preserve a local .download-error.txt path, and include message.files[].error for message get/list or messages[].files[].error for search messages|all; search files skips files whose download fails.
Opens a Slack-like rich-text editor in the browser for composing messages with formatting toolbar (bold, italic, strikethrough, links, lists, quotes, code, code blocks). After sending, shows a "View in Slack" link.
agent-slack message draft "general"
agent-slack message draft "general" "initial text
_sent from pi_"
agent-slack message draft "https://workspace.slack.com/archives/C123/p1700000000000000"
If using the browser editor without initial text, add the required _sent from pi_ footer as the final line before sending.
agent-slack message send "https://workspace.slack.com/archives/C123/p1700000000000000" "I can take this.
_sent from pi_"
agent-slack message send "alerts-staging" "here's the report
_sent from pi_" --attach ./report.md
agent-slack message edit "https://workspace.slack.com/archives/C123/p1700000000000000" "I can take this today."
agent-slack message delete "https://workspace.slack.com/archives/C123/p1700000000000000"
agent-slack message send "general" "Here's the plan:
- Step 1: do the thing
- Step 2: verify it worked
- Sub-step: check logs
_sent from pi_"
agent-slack message react add "https://workspace.slack.com/archives/C123/p1700000000000000" "eyes"
agent-slack message react remove "https://workspace.slack.com/archives/C123/p1700000000000000" "eyes"
Channel mode for edit/delete requires --ts:
agent-slack message edit "general" "Updated text" --workspace "myteam" --ts "1770165109.628379"
agent-slack message delete "general" --workspace "myteam" --ts "1770165109.628379"
Attach options for message send:
--attach <path> upload a local file (repeatable)agent-slack channel list
agent-slack channel list --user "@alice" --limit 50
agent-slack channel list --all --limit 100
agent-slack channel new --name "incident-war-room"
agent-slack channel new --name "incident-leads" --private
agent-slack channel invite --channel "incident-war-room" --users "U01AAAA,@alice,bob@example.com"
agent-slack channel invite --channel "incident-war-room" --users "partner@vendor.com" --external
agent-slack channel invite --channel "incident-war-room" --users "partner@vendor.com" --external --allow-external-user-invites
For --external, invite targets must be emails. By default, invitees are external-limited; add
--allow-external-user-invites to allow them to invite other users.
Prefer channel-scoped search for reliability:
agent-slack search all "smoke tests failed" --channel "alerts" --after 2026-01-01 --before 2026-02-01
agent-slack search messages "stably test" --user "@alice" --channel general
agent-slack search files "testing" --content-type snippet --limit 10
If you have multiple workspaces configured and you use a channel name (e.g. general), pass --workspace (or set SLACK_WORKSPACE_URL) to avoid ambiguity:
agent-slack message get "general" --workspace "https://myteam.slack.com" --ts "1770165109.628379"
agent-slack message get "general" --workspace "myteam" --ts "1770165109.628379"
Get the channel ID for a DM or group DM, useful for sending messages to a group of users:
agent-slack user dm-open @alice @bob
agent-slack user dm-open U01AAAA U02BBBB U03CCCC
Mark a channel, DM, or group DM as read up to a given message:
agent-slack channel mark "https://workspace.slack.com/archives/C123/p1700000000000000"
agent-slack channel mark "general" --workspace "myteam" --ts "1770165109.628379"
agent-slack channel mark "D0A04PB2QBW" --workspace "myteam" --ts "1770165109.628379"
To make a specific message appear unread, set --ts to just before it (subtract 0.000001). This moves the read cursor so that message and everything after it appear as new:
agent-slack channel mark "general" --workspace "myteam" --ts "1770165109.628378"
Discover and run Slack workflows bookmarked in channels:
# List workflows in a channel
agent-slack workflow list "#ops"
# Preview trigger metadata (no side effects)
agent-slack workflow preview "Ft123ABC"
# Get workflow definition including form fields and steps
agent-slack workflow get "Ft123ABC"
agent-slack workflow get "Wf456DEF"
# Trip a workflow trigger
agent-slack workflow run "Ft123ABC" --channel "#ops"
agent-slack canvas get "https://workspace.slack.com/docs/T123/F456"
agent-slack user list --workspace "https://workspace.slack.com" --limit 100
agent-slack user get "@alice" --workspace "https://workspace.slack.com"
#channel targeting rules