Claude-code-plugins configure
Configure Slack channel tokens (bot token + app-level token)
install
source · Clone the upstream repo
git clone https://github.com/jeremylongshore/claude-code-plugins-plus-skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/jeremylongshore/claude-code-plugins-plus-skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/plugins/mcp/slack-channel/skills/configure" ~/.claude/skills/jeremylongshore-claude-code-plugins-configure && rm -rf "$T"
manifest:
plugins/mcp/slack-channel/skills/configure/SKILL.mdtags
source content
/slack-channel:configure
Overview
Configure the Slack channel MCP plugin by providing your Slack bot token and app-level token. Writes credentials to a secure
.env file with owner-only permissions.
Prerequisites
- A Slack app created at api.slack.com/apps with Socket Mode enabled
- A Bot User OAuth Token (
) from OAuth & Permissionsxoxb-... - An App-Level Token (
) from Socket Mode settingsxapp-... - Write access to
~/.claude/channels/slack/
Usage
/slack-channel:configure <xoxb-bot-token> <xapp-app-token>
Instructions
-
Parse the two arguments from
:$ARGUMENTS- First token must start with
(Bot User OAuth Token)xoxb- - Second token must start with
(App-Level Token)xapp-
- First token must start with
-
If either token is missing or has the wrong prefix, show this error and stop:
Error: Two tokens required. - Bot token (starts with xoxb-) from OAuth & Permissions - App token (starts with xapp-) from Socket Mode settings Usage: /slack-channel:configure xoxb-... xapp-... -
Create the state directory if it doesn't exist:
~/.claude/channels/slack/ -
Write the
file at.env
:~/.claude/channels/slack/.envSLACK_BOT_TOKEN=<bot-token> SLACK_APP_TOKEN=<app-token> -
Set file permissions to owner-only:
chmod 600 ~/.claude/channels/slack/.env -
Confirm success:
Slack channel configured. Start Claude with the Slack channel: claude --channels plugin:slack-channel@claude-code-plugins Or for development: claude --dangerously-load-development-channels server:slack
Security
- Never echo the tokens back in the confirmation message
- Never log tokens to stdout or any file other than
.env - Always set 0o600 permissions on the
file.env
Output
On success, displays:
Slack channel configured. Start Claude with the Slack channel: claude --channels plugin:slack-channel@claude-code-plugins
On validation failure, displays the error with correct usage syntax.
Error Handling
| Error | Cause | Resolution |
|---|---|---|
| Missing token argument | Fewer than 2 arguments provided | Show usage with required token prefixes |
| Invalid bot token prefix | First token does not start with | Explain where to find the Bot User OAuth Token |
| Invalid app token prefix | Second token does not start with | Explain where to find the App-Level Token in Socket Mode settings |
| Permission denied | Cannot write to | Check directory permissions and create parent dirs if needed |
Examples
Standard configuration:
/slack-channel:configure xoxb-1234567890-abcdef xapp-1-ABCDEF-ghijkl → Slack channel configured.
Missing token error:
/slack-channel:configure xoxb-1234567890 → Error: Two tokens required. - Bot token (starts with xoxb-) from OAuth & Permissions - App token (starts with xapp-) from Socket Mode settings
Resources
- Slack API: Creating an app — app setup walkthrough
- Slack Socket Mode — how to enable and get app-level tokens
- Access control:
— configure who can message your session/slack-channel:access