feat(slack): close platform tools gap for assistants#2887
Conversation
Add 53 new Slack Web API tools so assistants can manage the full message and channel lifecycle, not just read. Covers chat.* (update, delete, ephemeral, permalink, scheduled-message admin, meMessage), conversations.* (info, members, open, create, join/leave, invite, topic/purpose, archive/unarchive, rename, kick, mark), users.* + dnd.* (lookup by email, presence, profile fields, conversations, dnd info/teamInfo), reminders.*, files.* (combined upload flow plus info/list/delete), pins.*, bookmarks.*, usergroups.list + usergroups.users.list, team.info, and canvases.* (create/edit/delete, sections.lookup, access set/delete, channel canvases). Each tool registers in the platformtools registry and contributes its bot/user scopes to the dashboard onboarding manifest so the generated Slack app deep link picks them up.
Use require.Empty for empty-form-value check; replace require.NoError inside httptest handler goroutines with t.Errorf so the linter is happy and a failing assertion doesn't abort the handler goroutine mid-request.
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: b4bb107 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a170035039
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
🚀 Preview Environment (PR #2887)Preview URL: https://pr-2887.dev.getgram.ai
Gram Preview Bot |
- slackManifest: drop user-only `channels:write` from bot scopes; `channels:manage` (already present) is the bot-token equivalent for conversation-management methods, and Slack rejects manifests that put user-only scopes in `oauth_config.scopes.bot`. - tool_set_canvas_access: reject mixed channel_ids + user_ids; canvases.access.set returns invalid_parameters when both target kinds are set. - tool_edit_canvas: accept a single `change` instead of a list; Slack canvases.edit currently processes only one operation per call and silently dropping the tail in a batched call hides the problem from the assistant.
|
Addressed all three Codex review findings in 037fb85:
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 037fb857b4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
- set_canvas_access: drop the `none` access level from the schema hint; Slack rejects it on canvases.access.set, and revocation belongs on remove_canvas_access (canvases.access.delete). - remove_canvas_access: require at least one of channel_ids/user_ids; canvases.access.delete returns invalid_parameters when both are empty, so the previous "all non-owners" wording was a dead path.
|
Round 2 — second batch of Codex findings addressed in 378f002:
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 378f002781
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
files.completeUploadExternal takes a single `channel_id`. The previous description told the model it could pass a comma-separated list, which Slack rejects as an invalid channel. Multi-channel sharing now becomes multiple tool calls.
|
Round 3 — addressed in b4bb107. |
Summary
Closes AGE-2376.
Adds 53 new Slack Web API tools under
server/internal/platformtools/slack/so assistants can manage the full Slack message and channel lifecycle instead of only reading.Coverage by API family:
update,delete,postEphemeral,getPermalink,deleteScheduledMessage,scheduledMessages.list,meMessageinfo,members,open,create,join,leave,invite,setTopic,setPurpose,mark,archive,unarchive,rename,kickusers.lookupByEmail,users.conversations,users.getPresence,users.profile.get,dnd.info,dnd.teamInfoadd,list,complete,delete,info(user-token)getUploadURLExternal+ PUT +completeUploadExternal),info,list,deletepins.add|remove|list,bookmarks.add|edit|remove|list,usergroups.list,usergroups.users.list,team.infocreate,edit,delete,sections.lookup,access.set,access.delete,conversations.canvases.createEach tool registers in the platformtools registry and contributes its bot/user scopes to the dashboard onboarding manifest so the generated Slack app deep link picks them up.
reminders:read|writeare user-only scopes appended toSLACK_USER_SCOPES; everything else lands in the bot-scope superset viaSLACK_TOOL_SCOPES.Out of scope (per the issue):
views.*,workflows.*,triggers.*,admin.*,rtm.*, andassistant.threads.*(optional, deferred until we own a native Slack assistant surface).✻ Clauded...