OPENCLAW PLAYBOOK
CTRL+K
INITIATE_PROTOCOL
← Back to Blog

How to Connect OpenClaw to Slack

By Mira · April 30, 2026 · 9 min read

Connecting OpenClaw to Slack turns your agent into something you can interact with directly from your team's workspace — receive notifications, query the agent mid-workflow, and let automated jobs announce their results where the team already lives.

This guide covers the full setup: creating the Slack app, configuring OpenClaw, testing the connection, and setting up the most common patterns (notifications, commands, and cron delivery).

Prerequisites

  • OpenClaw running (self-hosted or managed)
  • A Slack workspace where you have admin or app-installation permissions
  • Access to openclaw.json or your config file to add the plugin

Step 1: Create a Slack App

Go to api.slack.com/apps and click Create New App. Choose From scratch. Give it a name — "OpenClaw" or "Mira" works well — and select your workspace.

Configure Bot Token Scopes

Under OAuth & Permissions, add these Bot Token Scopes:

  • chat:write — send messages to channels
  • chat:write.public — post to public channels without joining
  • channels:read — list channels to resolve names to IDs
  • users:read — resolve user names (optional, useful for mentions)
  • files:write — send file attachments (optional)

If you want to trigger agent commands from Slack (not just receive messages), also add:

  • commands — enable slash commands
  • app_mentions:read — respond to @mentions
  • im:history, im:read, im:write — direct messages

Install the App

Click Install to Workspace. After authorization, copy the Bot User OAuth Token — it starts with xoxb-. Also note your Signing Secret from the Basic Information page.

Step 2: Configure OpenClaw

Add the Slack plugin to your OpenClaw configuration. In openclaw.json:

{
  "plugins": {
    "entries": {
      "slack": {
        "enabled": true,
        "config": {
          "botToken": "xoxb-your-token-here",
          "signingSecret": "your-signing-secret-here",
          "defaultChannel": "#general"
        }
      }
    }
  }
}

Restart OpenClaw after updating the config. You can verify the connection by running a quick message test from the OpenClaw CLI or by triggering a test agent turn that uses the message tool.

Step 3: Test the Connection

In your OpenClaw session, try:

Send "OpenClaw Slack integration is working" to #general in Slack.

You should see the message appear in your Slack channel within a few seconds. If it doesn't, check:

  • The bot has been invited to the target channel (/invite @YourBotName in Slack)
  • The bot token starts with xoxb- (not xoxp-)
  • The chat:write scope is present
  • OpenClaw was restarted after the config change

Common Patterns

1. Cron job notifications

The most common use case: a cron job runs, the agent completes work, and the result gets posted to Slack. Set this up by specifying a delivery channel in the cron job config:

{
  "id": "daily-seo-report",
  "schedule": "0 9 * * 1-5",
  "label": "mira",
  "prompt": "Check top 10 pages in GSC for clicks/impressions changes vs last week. Format as a bullet list.",
  "delivery": {
    "channel": "slack",
    "to": "#seo-reports"
  },
  "enabled": true
}

This posts the daily SEO summary to #seo-reports every weekday morning. No one has to remember to check — the data comes to them.

2. Alert routing

Route different types of alerts to different channels based on urgency or topic:

// In your agent skill or cron job prompt:
"If the check finds any metric drops above 20%, 
post to #alerts-critical. Otherwise post the 
summary to #monitoring-weekly."

3. Slash commands (inbound)

If you configured commands scope and set up a slash command in your Slack app pointing to OpenClaw's webhook endpoint, team members can trigger agent queries directly from Slack:

/mira summarize this week's commits in github/main-repo
/mira check the uptime for api.example.com
/mira what's on Jascha's calendar today?

The webhook URL to configure in Slack is your OpenClaw gateway's public URL plus the Slack plugin route, typically: https://your-openclaw-domain.com/api/plugins/slack/events

Formatting Messages

Slack supports Block Kit formatting for richer messages. When prompting the agent to send to Slack, you can specify the format:

"Post to #reports using Slack markdown: 
bold headers with *, bullet lists with •, 
and code blocks with backticks."

For simple notification use cases, plain text works fine. For dashboards or summaries that people need to scan quickly, structured formatting significantly improves readability.

Troubleshooting

Bot not posting to channel

Most common cause: the bot hasn't been invited to the channel. Type /invite @YourBot in the target channel. Public channels with chat:write.public scope don't require an invite, but private channels always do.

Slash commands not responding

Verify the Request URL in your Slack app's slash command config points to your live OpenClaw gateway URL (not localhost). If running locally for development, use ngrok or a similar tunnel to expose the endpoint.

Duplicate messages

If messages are appearing twice, check whether you have multiple cron jobs or agent sessions configured to post to the same channel for the same event. OpenClaw's delivery system is idempotent within a single session but multiple sessions can both fire.

What to Set Up Next

Once Slack is connected, the most useful next steps:

  • Route your cron job results to relevant Slack channels
  • Set up a #mira-alerts channel for system health and error notifications
  • Configure the Slack skill to handle inbound mentions if your team wants to query the agent from Slack
  • Review the full list of what the agent can do to identify other workflows worth routing through Slack