You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONFIGURATION.md
+57-34Lines changed: 57 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,11 +37,16 @@ The agent also uses an SSH key (`~/.ssh/id_ed25519`) for git push. Setup generat
37
37
38
38
| Variable | Description | How to get it |
39
39
|----------|-------------|---------------|
40
-
|`SLACK_BOT_TOKEN`| Slack bot OAuth token (required for direct Socket Mode; ignored by broker pull mode) | Create a Slack app at [api.slack.com/apps](https://api.slack.com/apps). Under **OAuth & Permissions**, add bot scopes: `app_mentions:read`, `chat:write`, `channels:history`, `channels:read`, `reactions:write`, `im:history`, `im:read`, `im:write`. Install the app to your workspace and copy the **Bot User OAuth Token**. |
41
-
|`SLACK_APP_TOKEN`| Slack app-level token (required for Socket Mode; not used by broker pull mode) | In your Slack app settings → **Basic Information** → **App-Level Tokens**, create a token with `connections:write` scope. |
42
-
|`SLACK_ALLOWED_USERS`| Comma-separated Slack user IDs |**Optional** — if not set, all workspace members can interact. Find your Slack user ID: click your profile → "..." → "Copy member ID". Example: `U01ABCDEF,U02GHIJKL`|
40
+
|`GATEWAY_BOT_TOKEN`|**Preferred** bot OAuth token for Socket Mode (ignored by broker pull mode) | Create a Slack app at [api.slack.com/apps](https://api.slack.com/apps). Under **OAuth & Permissions**, add bot scopes: `app_mentions:read`, `chat:write`, `channels:history`, `channels:read`, `reactions:write`, `im:history`, `im:read`, `im:write`. Install the app to your workspace and copy the **Bot User OAuth Token**. |
41
+
|`SLACK_BOT_TOKEN`| Legacy alias for `GATEWAY_BOT_TOKEN` (still supported) | Same token as above; migrate to `GATEWAY_BOT_TOKEN` over time. |
42
+
|`GATEWAY_APP_TOKEN`|**Preferred** app-level token for Socket Mode | In your Slack app settings → **Basic Information** → **App-Level Tokens**, create a token with `connections:write` scope. |
43
+
|`SLACK_APP_TOKEN`| Legacy alias for `GATEWAY_APP_TOKEN` (still supported) | Same token as above; migrate to `GATEWAY_APP_TOKEN` over time. |
44
+
|`GATEWAY_ALLOWED_USERS`|**Preferred** comma-separated Slack user IDs allowlist |**Optional** — if not set, all workspace members can interact. Find your Slack user ID: click your profile → "..." → "Copy member ID". Example: `U01ABCDEF,U02GHIJKL`|
45
+
|`SLACK_ALLOWED_USERS`| Legacy alias for `GATEWAY_ALLOWED_USERS` (still supported) | Same value as above; migrate to `GATEWAY_ALLOWED_USERS` over time. |
43
46
44
-
If you're using Slack broker mode (`SLACK_BROKER_*` vars), the runtime uses broker pull delivery and does not require Socket Mode callbacks.
47
+
If both alias forms are present, `GATEWAY_*` takes precedence.
48
+
49
+
If you're using broker mode (`GATEWAY_BROKER_*` preferred, `SLACK_BROKER_*` legacy), the runtime uses broker pull delivery and does not require Socket Mode callbacks.
45
50
46
51
If you're using the Slack broker OAuth flow, register this server after install:
47
52
@@ -105,32 +110,50 @@ The integration token only provides read access to pages/databases explicitly sh
105
110
106
111
| Variable | Description | How to get it |
107
112
|----------|-------------|---------------|
108
-
|`SLACK_CHANNEL_ID`| Additional monitored channel | If set, the bridge responds to all messages in this channel (not just @mentions). |
113
+
|`GATEWAY_CHANNEL_ID`|**Preferred** additional monitored channel | If set, the bridge responds to all messages in this channel (not just @mentions). |
114
+
|`SLACK_CHANNEL_ID`| Legacy alias for `GATEWAY_CHANNEL_ID` (still supported) | Same value as above; migrate to `GATEWAY_CHANNEL_ID` over time. |
109
115
110
116
### Slack Broker Registration (optional)
111
117
112
118
Set by `sudo baudbot broker register` when using brokered Slack OAuth flow.
113
119
114
120
| Variable | Description |
115
121
|----------|-------------|
116
-
|`SLACK_BROKER_URL`| Broker base URL |
117
-
|`SLACK_BROKER_WORKSPACE_ID`| Slack workspace/team ID (`T...`) |
118
-
|`SLACK_BROKER_SERVER_PRIVATE_KEY`| Server X25519 private key (base64) |
119
-
|`SLACK_BROKER_SERVER_PUBLIC_KEY`| Server X25519 public key (base64) |
120
-
|`SLACK_BROKER_SERVER_SIGNING_PRIVATE_KEY`| Server Ed25519 private signing key (base64) |
121
-
|`SLACK_BROKER_SERVER_SIGNING_PUBLIC_KEY`| Server Ed25519 public signing key (base64) |
122
-
|`SLACK_BROKER_PUBLIC_KEY`| Broker X25519 public key (base64) |
123
-
|`SLACK_BROKER_SIGNING_PUBLIC_KEY`| Broker Ed25519 public signing key (base64) |
124
-
|`SLACK_BROKER_ACCESS_TOKEN`| Broker-issued bearer token for broker API auth (required for broker pull mode runtime) |
125
-
|`SLACK_BROKER_ACCESS_TOKEN_EXPIRES_AT`| ISO timestamp for broker token expiry (recommended; runtime exits if expired) |
|`SLACK_BROKER_ACCESS_TOKEN_SCOPES`| Legacy alias for `GATEWAY_BROKER_ACCESS_TOKEN_SCOPES`|
127
144
|`GITHUB_IGNORED_USERS`| Optional comma-separated GitHub logins to ignore when forwarding broker GitHub events (`baudbot-agent` is always ignored) |
128
-
|`SLACK_BROKER_POLL_INTERVAL_MS`| Inbox poll interval in milliseconds (default: `3000`) |
129
-
|`SLACK_BROKER_MAX_MESSAGES`| Max leased messages per poll request (default: `10`) |
130
-
|`SLACK_BROKER_WAIT_SECONDS`| Long-poll wait window for `/api/inbox/pull` (default: `20`, set `0` for immediate short-poll, max `25`) |
131
-
|`SLACK_BROKER_DEDUPE_TTL_MS`| Dedupe cache TTL in milliseconds (default: `1200000`) |
145
+
|`GATEWAY_BROKER_POLL_INTERVAL_MS`|**Preferred** inbox poll interval in milliseconds (default: `3000`) |
146
+
|`SLACK_BROKER_POLL_INTERVAL_MS`| Legacy alias for `GATEWAY_BROKER_POLL_INTERVAL_MS`|
147
+
|`GATEWAY_BROKER_MAX_MESSAGES`|**Preferred** max leased messages per poll request (default: `10`) |
148
+
|`SLACK_BROKER_MAX_MESSAGES`| Legacy alias for `GATEWAY_BROKER_MAX_MESSAGES`|
149
+
|`GATEWAY_BROKER_WAIT_SECONDS`|**Preferred** long-poll wait window for `/api/inbox/pull` (default: `20`, set `0` for immediate short-poll, max `25`) |
150
+
|`SLACK_BROKER_WAIT_SECONDS`| Legacy alias for `GATEWAY_BROKER_WAIT_SECONDS`|
151
+
|`GATEWAY_BROKER_DEDUPE_TTL_MS`|**Preferred** dedupe cache TTL in milliseconds (default: `1200000`) |
152
+
|`SLACK_BROKER_DEDUPE_TTL_MS`| Legacy alias for `GATEWAY_BROKER_DEDUPE_TTL_MS`|
132
153
|`BAUDBOT_AGENT_VERSION`| Optional override for broker observability `meta.agent_version` (otherwise read from `~/.pi/agent/baudbot-version.json` when available) |
133
154
155
+
If both alias forms are set, `GATEWAY_BROKER_*` takes precedence.
156
+
134
157
Broker mode also emits best-effort context usage telemetry in inbox pull `meta` by reading `~/.pi/agent/context-usage.json` (written by the `context` extension on session start/turn end/tool results).
0 commit comments