openclaw - 💡(How to fix) Fix Feature Request: Slack threadBindings with spawnAcpSessions support (parity with Discord/Telegram) [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#43756Fetched 2026-04-08 00:17:49
View on GitHub
Comments
1
Participants
2
Timeline
1
Reactions
1
Author
Timeline (top)
commented ×1

Add threadBindings support to the Slack channel plugin, specifically spawnAcpSessions, to enable thread-bound ACP agent sessions in Slack — matching the existing Discord and Telegram implementations.

Root Cause

Slack is widely used for team-based AI workflows. Without thread-bound ACP sessions, Slack users must rely on the main agent relaying results (no live back-and-forth), while Discord users get the full interactive experience. This creates a significant feature gap for Slack-based deployments.

Code Example

{
  "channels": {
    "slack": {
      "threadBindings": {
        "enabled": true,
        "spawnAcpSessions": true,
        "idleHours": 24
      }
    }
  }
}
RAW_BUFFERClick to expand / collapse

Feature Request

Summary

Add threadBindings support to the Slack channel plugin, specifically spawnAcpSessions, to enable thread-bound ACP agent sessions in Slack — matching the existing Discord and Telegram implementations.

Current State

  • Discord: Full threadBindings support with spawnAcpSessions and spawnSubagentSessions flags. Users can spawn coding agents (Codex, OpenCode, Claude Code, etc.) directly in Discord threads with live back-and-forth.
  • Telegram: Same threadBindings schema with ACP spawn support.
  • Slack: Only basic thread config (historyScope, inheritParent, initialHistoryLimit). No threadBindings object, no spawnAcpSessions flag. The SlackAccountSchema in the Slack plugin does not include this.

Desired Behavior

Adding the following to Slack channel config should enable thread-bound ACP sessions:

{
  "channels": {
    "slack": {
      "threadBindings": {
        "enabled": true,
        "spawnAcpSessions": true,
        "idleHours": 24
      }
    }
  }
}

When a user starts a Slack thread and mentions an ACP agent (e.g. "opencode: refactor this function"), OpenClaw should:

  1. Detect the ACP spawn intent
  2. Create a thread-bound ACP session (same as Discord flow)
  3. Route subsequent thread messages to the bound ACP session
  4. Deliver ACP agent responses back into the Slack thread

Why This Matters

Slack is widely used for team-based AI workflows. Without thread-bound ACP sessions, Slack users must rely on the main agent relaying results (no live back-and-forth), while Discord users get the full interactive experience. This creates a significant feature gap for Slack-based deployments.

Technical Notes

  • The session.threadBindings global config already works and can serve as the default
  • The Discord implementation provides a proven reference architecture
  • The Slack plugin already handles thread-scoped sessions (thread.historyScope) — this extends that foundation
  • Schema addition needed in SlackAccountSchema (and SlackConfigSchema via safeExtend)

Environment

  • OpenClaw version: 2026.3.8
  • Slack plugin: Socket Mode
  • ACP backend: acpx v0.1.13

extent analysis

Fix Overview

Add threadBindings (with spawnAcpSessions) to the Slack channel plugin so that a Slack thread can own its own ACP agent session, just like Discord/Telegram.


1. Schema Changes

File: src/plugins/slack/schema.ts (or wherever SlackAccountSchema lives)

import { z } from "zod";
import { safeExtend } from "@/config";

export const SlackThreadBindingsSchema = z.object({
  enabled: z.boolean().default(false),
  spawnAcpSessions: z.boolean().default(false),
  idleHours: z.number().int().min(1).default(24),
});

export const SlackConfigSchema = safeExtend(
  // existing SlackConfigSchema definition …
  {
    thread: z.object({
      historyScope: z.enum(["channel", "thread"]).default("thread"),
      inheritParent: z.boolean().default(true),
      initialHistoryLimit: z.number().int().min(0).default(50),
    }),
    // NEW SECTION
    threadBindings: SlackThreadBindingsSchema.optional(),
  }
);
  • safeExtend merges the new object into the existing schema without breaking older configs.
  • Existing installations keep working because the whole block is optional and defaults are supplied.

2. Load Config in the Slack Plugin

// src/plugins/slack/index.ts
import { SlackConfigSchema } from "./schema";

export class SlackPlugin {
  private cfg: z.infer<typeof SlackConfigSchema>;

  constructor(rawConfig: any) {
    const parsed = SlackConfigSchema.parse(rawConfig);
    this.cfg = parsed;
    // expose for later checks
    this.threadBindings = parsed.threadBindings ?? {
      enabled: false,
      spawnAcpSessions: false,
      idleHours: 24,
    };
  }
}

3. Detect ACP Spawn Intent

Add a small helper that mirrors the Discord implementation:

// src/plugins/slack/intents.ts
export const ACP_SPAWN_REGEX = /^(?:opencode|codex|claude\s+code)[:\s]/i;

export function isAcpSpawn(message: string): boolean {
  return ACP_SPAWN_REGEX.test(message.trim());
}

4. Create a Thread‑Bound ACP Session

In the message‑

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix Feature Request: Slack threadBindings with spawnAcpSessions support (parity with Discord/Telegram) [1 comments, 2 participants]