Skip to main content
Build intelligent Slack bots that can respond to messages, handle mentions, and execute tasks.

Quick Start

1

Simple Usage

2

With Configuration

Configure signing secrets, Socket Mode, and event handlers — see sections below.

Configuration

Event Handlers

Message Handler

App Mention Handler

Reaction Handler

Rich Responses

With Blocks

Socket Mode (Development)

For local development without exposing a public URL:

Webhook Mode (Production)

For production deployments:

With Tools

Environment Variables

Slack App Setup

  1. Create a Slack App at https://api.slack.com/apps
  2. Enable Socket Mode or configure Event Subscriptions
  3. Add bot scopes: chat:write, app_mentions:read, channels:history
  4. Install to workspace
  5. Copy tokens to environment variables

Best Practices

  1. Use threads - Reply in threads to keep channels clean
  2. Handle errors gracefully - Return friendly error messages
  3. Rate limit - Respect Slack’s rate limits
  4. Log interactions - Track usage for debugging

Agent

Core agent docs

Tools

Adding tools