Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
1c5afec
feat(web-api): add agents.sessions.setStatus and agents.sessions.rename
zimeg Aug 19, 2026
5ac7951
feat(web-api): add codeChannels.* methods
zimeg Aug 19, 2026
c8a8168
feat(web-api): rename Slack Code methods to agents.conversations.* (n…
zimeg Sep 23, 2026
ed5f8d7
refactor(web-api): give agents.conversations.* explicit typed params
zimeg Sep 23, 2026
3f4ed6d
refactor(web-api): order agents.conversations.* before agents.sessions.*
zimeg Sep 23, 2026
c11fbfe
refactor(web-api): move agents.* methods to their alphabetical slot
zimeg Sep 23, 2026
c49a9fe
Merge remote-tracking branch 'origin/main' into clack/code-channels-m…
zimeg Sep 23, 2026
330a565
refactor(web-api): make code channel identifiers required per review
zimeg Sep 23, 2026
f6eccc7
test(web-api): dedupe + order agents.* coverage cases
zimeg Sep 23, 2026
1abafab
Merge remote-tracking branch 'origin/main' into clack/code-channels-m…
zimeg Sep 24, 2026
396a3e5
test(web-api): group agents.* coverage cases with the method list order
zimeg Sep 24, 2026
f653589
test(web-api): use realistic mock data for agents.conversations coverage
zimeg Sep 24, 2026
28fbc3f
test(web-api): put the Ct-prefixed id on removeView's view_id
zimeg Sep 24, 2026
ae81880
refactor(web-api): drop title/status from agents.conversations.setPro…
zimeg Sep 29, 2026
887fad5
fix: remove the deprecated label argument from agents.conversations.s…
zimeg Sep 29, 2026
188f383
Merge branch 'main' into clack/code-channels-methods
zimeg Sep 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
214 changes: 214 additions & 0 deletions slack_sdk/web/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -2029,6 +2029,220 @@ async def admin_workflows_unpublish(
kwargs.update({"workflow_ids": workflow_ids})
return await self.api_call("admin.workflows.unpublish", params=kwargs)

async def agents_conversations_archive(
self,
*,
channel_id: str,
summary_message_ts: Optional[str] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Archive a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.archive
"""
kwargs.update(
{
"channel_id": channel_id,
"summary_message_ts": summary_message_ts,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.archive", json=kwargs)

async def agents_conversations_create(
self,
*,
name: str,
team_id: Optional[str] = None,
session_id: Optional[str] = None,
is_private: Optional[bool] = None,
origin_channel_id: Optional[str] = None,
origin_message_ts: Optional[str] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Create a dedicated code channel for an agent session.

https://docs.slack.dev/reference/methods/agents.conversations.create
"""
kwargs.update(
{
"team_id": team_id,
"session_id": session_id,
"name": name,
"is_private": is_private,
"origin_channel_id": origin_channel_id,
"origin_message_ts": origin_message_ts,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.create", json=kwargs)

async def agents_conversations_getCanvas(
self,
*,
channel: str,
canvas_id: str,
content_format: Optional[str] = None,
include_resolved: Optional[bool] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Fetch a canvas attached to a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.getCanvas
"""
kwargs.update(
{
"channel": channel,
"canvas_id": canvas_id,
"content_format": content_format,
"include_resolved": include_resolved,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.getCanvas", json=kwargs)

async def agents_conversations_listViews(
self,
*,
channel_id: str,
**kwargs,
) -> AsyncSlackResponse:
"""List the views currently attached to a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.listViews
"""
kwargs.update({"channel_id": channel_id})
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.listViews", json=kwargs)

async def agents_conversations_removeView(
self,
*,
channel_id: str,
view_key: Optional[str] = None,
view_id: Optional[str] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Remove a view from a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.removeView
"""
kwargs.update(
{
"channel_id": channel_id,
"view_key": view_key,
"view_id": view_id,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.removeView", json=kwargs)

async def agents_conversations_setCanvasContent(
self,
*,
channel: str,
canvas_id: str,
content: str,
**kwargs,
) -> AsyncSlackResponse:
"""Replace the full markdown content of a plan canvas attached to a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.setCanvasContent
"""
kwargs.update(
{
"channel": channel,
"canvas_id": canvas_id,
"content": content,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.setCanvasContent", json=kwargs)

async def agents_conversations_setCommands(
self,
*,
channel_id: str,
commands: Sequence[Dict],
**kwargs,
) -> AsyncSlackResponse:
"""Register the set of agent-defined slash commands for the calling agent in a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.setCommands
"""
kwargs.update(
{
"commands": commands,
"channel_id": channel_id,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.setCommands", json=kwargs)

async def agents_conversations_setProperties(
self,
*,
channel_id: str,
code_channel: Optional[Dict] = None,
agent_resource: Optional[Dict] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Set properties on a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.setProperties
"""
kwargs.update(
{
"channel_id": channel_id,
"code_channel": code_channel,
"agent_resource": agent_resource,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.setProperties", json=kwargs)

async def agents_conversations_setView(
self,
*,
channel_id: str,
type: Optional[str] = None,
view_key: Optional[str] = None,
content: Optional[str] = None,
blocks: Optional[Sequence[Union[Dict, Block]]] = None,
canvas_id: Optional[str] = None,
access_level: Optional[str] = None,
agent_content_hash: Optional[str] = None,
pr_url: Optional[str] = None,
base_branch: Optional[str] = None,
head_branch: Optional[str] = None,
name: Optional[str] = None,
csp: Optional[Dict] = None,
**kwargs,
) -> AsyncSlackResponse:
"""Create or update a view in a code channel.

https://docs.slack.dev/reference/methods/agents.conversations.setView
"""
kwargs.update(
{
"channel_id": channel_id,
"type": type,
"view_key": view_key,
"content": content,
"blocks": blocks,
"canvas_id": canvas_id,
"access_level": access_level,
"agent_content_hash": agent_content_hash,
"pr_url": pr_url,
"base_branch": base_branch,
"head_branch": head_branch,
"name": name,
"csp": csp,
}
)
kwargs = _remove_none_values(kwargs)
return await self.api_call("agents.conversations.setView", json=kwargs)

async def agents_sessions_rename(
self,
*,
Expand Down
Loading
Loading