Skip to content

Add chat_set_state() for durable typed channel state - #15

Merged
TroyHernandez merged 3 commits into
mainfrom
set-state
Aug 19, 2026
Merged

TroyHernandez merged 3 commits into
mainfrom
set-state

Conversation

@TroyHernandez

Copy link
Copy Markdown
Contributor

A capability-gated setter for channel-scoped metadata: a Matrix state event on the Matrix adapter, an in-memory keyed store on loopback so consumers can round-trip it in tests, and a refusal everywhere else (set_state = FALSE on Slack and IRC). The Matrix method follows the channel_create pattern: injectable .state seam, mx.api::mx_set_state default, errors propagate.

Motivation: a bot marking a room's lifecycle (e.g. a reversed-domain state event a client keys UI off) currently has no path to Matrix state through the contract, and chat_channel_create's own docs argue that gaps like this force consumers below the seam.

Note: the version bump is 0.0.1.22 off main (0.0.1.21); the unmerged slack-lifecycle branch also carries a .22, so whichever merges second rebases its bump.

A capability-gated setter for channel-scoped metadata: a Matrix state
event on the Matrix adapter, an in-memory keyed store on loopback so
consumers can round-trip it in tests, and a refusal everywhere else
(set_state = FALSE on Slack and IRC). The Matrix method follows the
channel_create pattern: injectable .state seam, mx.api::mx_set_state
default, errors propagate.
@TroyHernandez
TroyHernandez merged commit 2614949 into main Aug 19, 2026
2 checks passed
@TroyHernandez
TroyHernandez deleted the set-state branch August 19, 2026 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant