Skip to content

feat(methods): add agents.conversations method examples - #194

Draft
zimeg wants to merge 18 commits into
mainfrom
clack/code-channels-method-examples
Draft

zimeg wants to merge 18 commits into
mainfrom
clack/code-channels-method-examples

Conversation

@zimeg

@zimeg zimeg commented Aug 18, 2026 •

Copy link
Copy Markdown
Member

Adds example snippets for the Slack Code code-channel Web API methods, under the agents.conversations.* family (methods/src/agents/conversations/):

  • agents.conversations.create — create a dedicated code channel for an agent session
  • agents.conversations.archive — archive a code channel (optionally recording a summary message)
  • agents.conversations.setProperties — set properties on a code channel (context bar items, external resource details)
  • agents.conversations.setView — create or update a view (HTML, diff, Block Kit, or canvas tabs)
  • agents.conversations.setCommands — register the agent's slash commands in a code channel
  • agents.conversations.listViews — list the view tabs attached to a code channel
  • agents.conversations.removeView — remove a view from a code channel
  • agents.conversations.getCanvas — fetch a canvas attached to a code channel
  • agents.conversations.setCanvasContent — replace the full markdown content of a plan canvas

The code_channels manifest feature and code_channels:manage scope are unchanged — only the method names moved. The rename example lives in the sibling agents.sessions examples PR (agents.sessions.rename), so there is no agents.conversations.rename here.

Stacking

Stacks on #201 (agents.sessions method examples) — this PR is based on clack/agents-sessions-method-examples.

Dependency — stays DRAFT

Depends on slackapi/python-slack-sdk#1943 (the agents.conversations.* SDK methods) landing in a published slack_sdk release. The methods typecheck job will fail against the currently-released SDK because these methods aren't in a release yet — that is expected (executable-spec pattern). This PR stays DRAFT until #1943 ships and the pinned slack_sdk version includes the methods.

Explicitly no legacy codeChannels.* method names — per the 2026-09-23 decision, we ship agents.conversations.* only, mirroring the SDK realign in #1943.

🤖 Generated with Claude Code

zimeg and others added 2 commits August 19, 2026 23:05
Add examples for agents.sessions.setStatus and agents.sessions.rename with a
minimal assistant:write manifest and the standard .slack CLI hooks.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Add examples for the codeChannels.* methods with a minimal
code_channels:manage manifest and the standard .slack CLI hooks. Stacked on
the agents.sessions examples.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
@zimeg
zimeg force-pushed the clack/code-channels-method-examples branch from 65fd0d5 to 67d25e0 Compare August 20, 2026 06:06
@zimeg
zimeg changed the base branch from main to clack/agents-sessions-method-examples August 20, 2026 06:08
zimeg and others added 10 commits August 19, 2026 23:32
Match the family-first header convention (### agents, like ### chat) and
tighten the agents.sessions.* method descriptions.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
agents.sessions.setStatus and agents.sessions.rename require the chat:write
bot scope per the method reference, not assistant:write.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Move the agents.sessions method examples from a flat agents_sessions/ dir to
nested agents/sessions/ (path mirrors the agents.sessions.* method family),
updating the README implementation links.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Add the recommended agent_view event subscriptions (agent_session_stopped,
app_home_opened, message.im), the assistant:write scope, and im:history so
message.im events deliver; enable socket mode. Clears the manifest
recommendations and the agent_session_stopped subscription warning.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
…mples' into clack/code-channels-method-examples
…ns.*

Decision (2026-09-23): ship agents.conversations.* only — no legacy
codeChannels.* method names. Renames methods/src/code_channels/ ->
methods/src/agents/conversations/, updates each example's method call
(client.agents_conversations_*), aligns args to the SDK #1943 signatures
(getCanvas/setCanvasContent take channel, not channel_id), drops the
rename example (agents.sessions.rename, covered by #201), and updates the
manifest description + methods/README. The features.code_channels manifest
feature and code_channels:manage scope are unchanged — only method names moved.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@zimeg zimeg changed the title feat(methods): add codeChannels method examples feat(methods): add agents.conversations method examples Sep 23, 2026
Base automatically changed from clack/agents-sessions-method-examples to main September 23, 2026 23:41
zimeg and others added 5 commits September 23, 2026 17:12
…ethod-examples

# Conflicts:
#	methods/README.md
#	methods/src/agents/sessions/agents_sessions_rename.py
#	methods/src/agents/sessions/agents_sessions_set_status.py
#	methods/src/agents/sessions/manifest.json
Match each agents.conversations.* README row to the canonical
one-line description on docs.slack.dev (docs #816), replacing the
embellished summaries with the reference text verbatim.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Align each example's payload with the request example on its
docs.slack.dev reference page (docs #816):
- create: session_id + 'Migrate billing cron to Temporal' name
- archive: summary_message_ts
- setProperties: full 4-item context_bar_items (repo/branch/pr/ci)
- setView: html view with view_key/name/csp
- setCommands: create-pr (argument_hint) + run-tests
- removeView: identify by view_key
- getCanvas: include_resolved
- setCanvasContent: migration-plan content

Duplicates the canonical examples rather than inventing variants.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Set socket_mode_enabled: true so the example app can register agent
slash commands. agents.conversations.setCommands returns no_actions_url
unless the app has either a code_channels.slash_command_url or Socket
Mode; Socket Mode routes command invocations automatically with no
public URL to stand up.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant