feat(slack): add Agent Sessions lifecycle and native stop - #862
Open
bensabic wants to merge 7 commits into
Open
Conversation
- expose thread-scoped abort signals - coordinate cancellation through shared state - support final agent session stream states
- use Agent Sessions APIs under agent_view - handle native stop and title-change events - title new agent conversations automatically
- cover session lifecycle and assistant_view sunset - document native stop and title events - wire abort signals and manifest events in the example
- exclude generated .swc artifacts
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
gr2m
reviewed
Aug 25, 2026
- match the current agent_session_stopped payload - preserve every stopped streaming message timestamp
- remove the undocumented inner stop-event field - keep workspace routing on the outer callback envelope
- accept title events without previous_title - expose previousTitle as optional to handlers
gr2m
approved these changes
Aug 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Migrates Slack's
agent_viewintegration to the Agent Sessions lifecycle while preserving the legacyassistant_viewcompatibility path.agents.sessions.setStatusandagents.sessions.renamesupport for processing, active, suspended, and closed sessions.agent_session_stoppedwithout taking the message lock, clears Slack's processing state, and dispatchesonAgentSessionStopped.thread.signal.agent_session_title_changedand automatically titles new agent conversations from their root message, with a configurable resolver.session_statusthrough native stream completion and supports suspended human-in-the-loop turns.assistant_viewretirement.Configure the Agent messaging experience and optional title resolver:
Pass the thread signal into model generation so Slack's native stop button cancels upstream work as well as message delivery:
React to session lifecycle events:
Leave a stream suspended when the agent needs user input or approval: