Builds on the v0.8.2 runtime. Four workstreams, all behind the §15 MCP door:
- Group rooms (Phase 1): migration 0026; N-way threads repo with a DM/room
count-guard; chat.send {room} + room.create/invite/leave tools; RoomMessage
-> room.message SSE; /api/claw-chat/rooms* APIs; Observer room badge.
- Per-claw door identity: door caller_agent resolves the X-ZeroClaw-Agent
header (set by the fork) to the specific claw, falling back to roster[0].
- Gated delegation bridge (Phase 3): clawmates__delegate door tool drives a
sibling via the existing /ws/chat ZeroClawDriveExecutor (not A2A); self-deny,
per-workspace hourly budget, audit trail, untrusted-banner result. Native
in-daemon delegation stays off (it would bypass the door).
- A2A tenant ingress (Phase 2): migration 0027 (workspace_a2a + a2a_tokens);
runtime_provision enable_a2a_server/publish_claw; routes/a2a.rs tenant-aware
proxy (per-workspace tokens, injected internal bearer, daemon stays internal,
cards URL-rewritten to the cm-api edge); a2a.invoked taxonomy.
Tests: cm-db room repos, cm-runtime chat tools, door units. sqlx cache updated.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
17 lines
764 B
SQL
17 lines
764 B
SQL
-- Phase 1: N-way group rooms.
|
|
-- The threads/thread_participants/thread_messages schema (0001) is already
|
|
-- N-way; this adds only what rooms need for audit + UX. Existing rows default
|
|
-- to kind='dm' so 1:1 routing is unchanged.
|
|
|
|
ALTER TABLE threads
|
|
ADD COLUMN kind TEXT NOT NULL DEFAULT 'dm'
|
|
CHECK (kind IN ('dm', 'room')),
|
|
ADD COLUMN created_by UUID REFERENCES agents (id);
|
|
|
|
-- Soft-remove participants so message history stays attributable after someone
|
|
-- leaves a room. added_by/joined_at record who pulled a participant in + when.
|
|
ALTER TABLE thread_participants
|
|
ADD COLUMN added_by UUID REFERENCES agents (id),
|
|
ADD COLUMN joined_at TIMESTAMPTZ NOT NULL DEFAULT now(),
|
|
ADD COLUMN active BOOLEAN NOT NULL DEFAULT true;
|