Skip to content

Add extended Slack SDK: pins, bookmarks, scheduled messages, channel management, reminders, and more#84

Merged
devxoul merged 13 commits intomainfrom
feat/slack-extended-api
Mar 22, 2026
Merged

Add extended Slack SDK: pins, bookmarks, scheduled messages, channel management, reminders, and more#84
devxoul merged 13 commits intomainfrom
feat/slack-extended-api

Conversation

@devxoul
Copy link
Owner

@devxoul devxoul commented Mar 21, 2026

Summary

Expands the Slack SDK with 28 new SlackClient methods, 4 new CLI commands, and extends 4 existing commands — covering pins, bookmarks, scheduled messages, channel management, user profiles, reminders, ephemeral messages, permalinks, file deletion, and emoji listing.

New SDK Methods (28)

Category Methods Slack API
Pins pinMessage, unpinMessage, listPins pins.*
Bookmarks addBookmark, editBookmark, removeBookmark, listBookmarks bookmarks.*
Scheduled Messages scheduleMessage, listScheduledMessages, deleteScheduledMessage chat.scheduleMessage, chat.scheduledMessages.list, chat.deleteScheduledMessage
Channel Management createChannel, archiveChannel, setChannelTopic, setChannelPurpose, inviteToChannel, joinChannel, leaveChannel conversations.*
User Enhancements lookupUserByEmail, getUserProfile, setUserProfile users.lookupByEmail, users.profile.*
Message Enhancements postEphemeral, getPermalink chat.postEphemeral, chat.getPermalink
Reminders addReminder, listReminders, completeReminder, deleteReminder reminders.*
Misc deleteFile, listEmoji files.delete, emoji.list

New CLI Commands

  • agent-slack pin add/remove/list
  • agent-slack bookmark add/edit/remove/list
  • agent-slack reminder add/list/complete/delete
  • agent-slack emoji list

Extended CLI Commands

  • agent-slack channel create/archive/set-topic/set-purpose/invite/join/leave
  • agent-slack message schedule/scheduled-list/scheduled-delete/ephemeral/permalink
  • agent-slack user lookup/profile/set-status
  • agent-slack file delete

Resolved Limitations

Removes two previously documented limitations from SKILL.md:

  • No channel management (create/archive) → Now supported
  • No scheduled messages → Now supported

New Types

SlackPin, SlackBookmark, SlackScheduledMessage, SlackReminder, SlackUserProfile

Testing

  • 56 new tests (2 per method: success + error case)
  • All 1305 tests pass
  • Typecheck clean (no new errors)

Summary by cubic

Adds pins, bookmarks, scheduled messages, channel management, reminders, profiles, ephemerals, permalinks, emoji, and file delete to the Slack SDK and agent-slack CLI. Docs updated: SKILL.md, CLI docs (synced --thread and --expiration examples), README, and workflow patterns.

  • New Features

    • SDK: 28 new SlackClient methods for pins, bookmarks, scheduled messages, channel create/archive/topic/purpose/invite/join/leave, user lookup/profile, ephemeral/permalink, reminders, file delete, and emoji list.
    • CLI: New agent-slack commands pin, bookmark, reminder, emoji; extended channel, message, user, and file with matching subcommands.
    • Types: SlackPin, SlackBookmark, SlackScheduledMessage, SlackReminder, SlackUserProfile.
  • Bug Fixes

    • Validate integer timestamps for message schedule, reminder add, and user set-status --expiration; require a field for bookmark edit; sync docs and examples (<user-id> for ephemerals, --thread, --expiration).
    • Paginate scheduled message listing; filter non-message items from pin lists; read scheduled_message_id defensively.

Written for commit 960aebb. Summary will update on new commits.

devxoul added 8 commits March 22, 2026 00:27
Pins: pinMessage, unpinMessage, listPins
Bookmarks: addBookmark, editBookmark, removeBookmark, listBookmarks
Scheduled messages: scheduleMessage, listScheduledMessages, deleteScheduledMessage
Channel management: createChannel, archiveChannel, setChannelTopic, setChannelPurpose, inviteToChannel, joinChannel, leaveChannel
User enhancements: lookupUserByEmail, getUserProfile, setUserProfile
Message enhancements: postEphemeral, getPermalink
Reminders: addReminder, listReminders, completeReminder, deleteReminder
Misc: deleteFile, listEmoji
Channel: create, archive, set-topic, set-purpose, invite, join, leave
Message: schedule, scheduled-list, scheduled-delete, ephemeral, permalink
User: lookup, profile, set-status
File: delete
Wire pin, bookmark, reminder, emoji commands into CLI.
Document all new commands in SKILL.md and remove outdated limitations.
Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

12 issues found across 19 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="src/platforms/slack/commands/message.ts">

<violation number="1" location="src/platforms/slack/commands/message.ts:273">
P2: Validate `post-at` before calling `scheduleMessage`; `parseInt` will silently accept malformed timestamps and can schedule at the wrong time.</violation>

<violation number="2" location="src/platforms/slack/commands/message.ts:460">
P2: Update the published Slack CLI reference to include these new `message` subcommands; `docs/content/docs/cli/slack.mdx` is now out of sync with the implementation.</violation>
</file>

<file name="src/platforms/slack/commands/pin.test.ts">

<violation number="1" location="src/platforms/slack/commands/pin.test.ts:31">
P2: This test bypasses `pin.ts` and only asserts that a mock records the same arguments it was called with, so it cannot catch regressions in the pin command behavior.</violation>
</file>

<file name="src/platforms/slack/client.ts">

<violation number="1" location="src/platforms/slack/client.ts:856">
P2: `listPins()` coerces every pin into a message, so non-message pins come back as bogus blank messages.</violation>
</file>

<file name="src/platforms/slack/commands/bookmark.test.ts">

<violation number="1" location="src/platforms/slack/commands/bookmark.test.ts:31">
P2: These “command” tests only exercise mocked `SlackClient` methods, so they don't verify any logic in `bookmark.ts`. Regressions in the actual CLI command wiring can ship unnoticed.</violation>
</file>

<file name="src/platforms/slack/types.ts">

<violation number="1" location="src/platforms/slack/types.ts:161">
P1: Using `id` for scheduled messages hides Slack’s actual identifier field and already causes the list path to read the wrong property, so listed scheduled messages can come back without a usable ID for `scheduled-delete`.</violation>
</file>

<file name="src/platforms/slack/commands/index.ts">

<violation number="1" location="src/platforms/slack/commands/index.ts:3">
P1: Custom agent: **Documentation sync**

Update `docs/content/docs/cli/slack.mdx` to document the newly exported Slack commands and expanded subcommands. `SKILL.md` is in sync, but the public Slack CLI guide still omits these command groups and examples.</violation>
</file>

<file name="src/platforms/slack/commands/user.ts">

<violation number="1" location="src/platforms/slack/commands/user.ts:112">
P1: Custom agent: **Documentation sync**

Update `docs/content/docs/cli/slack.mdx` to document the new `user lookup`, `user profile`, and `user set-status` commands; the platform guide is still missing these added CLI commands.</violation>
</file>

<file name="src/platforms/slack/commands/reminder.test.ts">

<violation number="1" location="src/platforms/slack/commands/reminder.test.ts:28">
P1: Custom agent: **Documentation sync**

The new Slack reminder commands are not fully documented: `skills/agent-slack/SKILL.md` was updated, but `docs/content/docs/cli/slack.mdx` and `README.md` still miss this major Slack feature expansion required by the documentation-sync rule.</violation>
</file>

<file name="src/platforms/slack/commands/channel.ts">

<violation number="1" location="src/platforms/slack/commands/channel.ts:394">
P1: Custom agent: **Documentation sync**

Update `docs/content/docs/cli/slack.mdx` for these new channel-management commands. The Slack CLI reference still documents only `channel list` and `channel info`, so `create`, `archive`, `set-topic`, `set-purpose`, `invite`, `join`, and `leave` are missing from the public docs.</violation>
</file>

<file name="skills/agent-slack/SKILL.md">

<violation number="1" location="skills/agent-slack/SKILL.md:190">
P1: Custom agent: **SKILL.md completeness**

Rule 2 requires `SKILL.md` to list every supported option and accurate outputs, but these new command entries omit real flags like `--thread`, `--type`, `--emoji`, and `--pretty`, and they add no output examples for the new JSON responses.</violation>

<violation number="2" location="skills/agent-slack/SKILL.md:368">
P1: Custom agent: **Documentation sync**

This major Slack feature expansion updates `SKILL.md` but leaves the required public docs out of sync. Update `docs/content/docs/cli/slack.mdx` and `README.md` for Rule 1 compliance.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

9 issues found across 4 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="docs/content/docs/cli/slack.mdx">

<violation number="1" location="docs/content/docs/cli/slack.mdx:86">
P1: Custom agent: **Documentation sync**

Keep the Slack CLI reference in sync with the implemented flags: `message schedule` takes positional `<post-at>`, not `--post-at`. The documented command form is invalid.</violation>

<violation number="2" location="docs/content/docs/cli/slack.mdx:160">
P1: Custom agent: **Documentation sync**

`user profile`/`user set-status` are not synced to `skills/agent-slack/SKILL.md`, and this example uses a non-existent `--text` flag. The implemented command is `user set-status <status-text> [--emoji <emoji>]`, so following the docs will fail.</violation>

<violation number="3" location="docs/content/docs/cli/slack.mdx:160">
P2: The `set-status` example uses an unsupported `--text` flag and the wrong emoji format.</violation>

<violation number="4" location="docs/content/docs/cli/slack.mdx:197">
P2: The `file delete` example includes a `--force` flag that the CLI does not implement.</violation>

<violation number="5" location="docs/content/docs/cli/slack.mdx:301">
P2: The reminder docs claim natural-language times are supported, but the CLI only accepts Unix timestamps.</violation>

<violation number="6" location="docs/content/docs/cli/slack.mdx:304">
P1: Custom agent: **Documentation sync**

The reminder docs advertise unsupported natural-language times and `skills/agent-slack/SKILL.md` still omits the new `complete`/`delete` commands. Keep the Slack docs aligned on the Unix-timestamp-only interface.</violation>
</file>

<file name="skills/agent-slack/SKILL.md">

<violation number="1" location="skills/agent-slack/SKILL.md:274">
P1: Custom agent: **SKILL.md completeness**

Restore `user profile` and `user set-status` in this section. The Slack CLI still ships both subcommands, so ending the User Commands docs at `lookup` leaves `SKILL.md` incomplete for supported `user` commands.</violation>

<violation number="2" location="skills/agent-slack/SKILL.md:404">
P2: This change removes the `reminder complete` and `reminder delete` commands from the Slack skill docs even though both commands are still implemented.</violation>
</file>

<file name="src/platforms/slack/commands/message.ts">

<violation number="1" location="src/platforms/slack/commands/message.ts:272">
P2: Require `post-at` to be an integer Unix timestamp; the new check still accepts decimal values like `1700000000.5`.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 3 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="docs/content/docs/cli/slack.mdx">

<violation number="1" location="docs/content/docs/cli/slack.mdx:86">
P1: Custom agent: **Documentation sync**

This PR adds major Slack features, but the required top-level README.md update is missing. The documentation-sync rule requires major features to update both `docs/content/docs/cli/slack.mdx` and `README.md`.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@devxoul
Copy link
Owner Author

devxoul commented Mar 21, 2026

@cubic-dev-ai re-review please — all 20 comments addressed in commit 28944ef.

@cubic-dev-ai
Copy link

cubic-dev-ai bot commented Mar 21, 2026

@cubic-dev-ai re-review please — all 20 comments addressed in commit 28944ef.

@devxoul I have started the AI code review. It will take a few minutes to complete.

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

8 issues found across 20 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="docs/content/docs/cli/slack.mdx">

<violation number="1" location="docs/content/docs/cli/slack.mdx:85">
P1: Custom agent: **Documentation sync**

These new Slack workflows were added to the CLI reference, but `skills/agent-slack/references/common-patterns.md` still has no corresponding workflow guidance. The documentation-sync rule requires behavioral/workflow changes in `src/platforms/slack/` to update that file too.</violation>

<violation number="2" location="docs/content/docs/cli/slack.mdx:97">
P2: Document this argument as `<user-id>`; the command forwards it directly to Slack without resolving usernames, so the current placeholder suggests inputs that will fail.</violation>
</file>

<file name="src/platforms/slack/client.test.ts">

<violation number="1" location="src/platforms/slack/client.test.ts:1267">
P1: Custom agent: **Documentation sync**

This major Slack feature expansion updates the Slack docs, but it still misses the required `README.md` update for documentation sync.</violation>
</file>

<file name="skills/agent-slack/SKILL.md">

<violation number="1" location="skills/agent-slack/SKILL.md:190">
P1: Custom agent: **SKILL.md completeness**

Document the supported flags for these new Slack subcommands. The added SKILL.md sections omit many implemented options, including `message schedule --thread`, `bookmark add --type`, and `user set-status --expiration`, so the command reference is incomplete.</violation>
</file>

<file name="src/platforms/slack/client.ts">

<violation number="1" location="src/platforms/slack/client.ts:986">
P2: Handle pagination in `listScheduledMessages`; the current implementation only returns the first page of Slack results.</violation>
</file>

<file name="src/platforms/slack/commands/reminder.ts">

<violation number="1" location="src/platforms/slack/commands/reminder.ts:24">
P2: Validate the `<time>` argument before calling `addReminder`; `parseInt()` currently accepts malformed timestamps and can pass `NaN` through to Slack.</violation>
</file>

<file name="src/platforms/slack/commands/bookmark.ts">

<violation number="1" location="src/platforms/slack/commands/bookmark.ts:53">
P2: Validate that `bookmark edit` receives at least one of `--title`, `--link`, or `--emoji` before calling the API.</violation>
</file>

<file name="src/platforms/slack/commands/user.ts">

<violation number="1" location="src/platforms/slack/commands/user.ts:173">
P2: Validate `--expiration` as an integer before sending it to Slack; `parseInt` currently accepts malformed values and can produce `NaN`.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

…workflow patterns

- Validate time args in reminder add, bookmark edit, user set-status expiration
- Add pagination to listScheduledMessages (cursor loop)
- Add pins, bookmarks, scheduled messages, channel management, reminders to README table
- Add --thread, --type, --expiration flags to SKILL.md examples
- Fix ephemeral docs to use <user-id> instead of <user>
- Add scheduling, channel setup, and reminder workflow patterns to common-patterns.md
Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 issues found across 8 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="skills/agent-slack/SKILL.md">

<violation number="1" location="skills/agent-slack/SKILL.md:192">
P3: Mirror these new Slack CLI examples in `docs/content/docs/cli/slack.mdx` too. Right now the skill and website docs advertise different command invocations for the same features.</violation>

<violation number="2" location="skills/agent-slack/SKILL.md:389">
P1: Custom agent: **Documentation sync**

Rule 1 (Documentation sync): update `docs/content/docs/cli/slack.mdx` alongside these SKILL.md changes. The public Slack CLI docs still omit the new `--thread`/`--expiration` usage and keep stale bookmark syntax, so the docs disagree on how to use these commands.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@devxoul devxoul merged commit c18fca1 into main Mar 22, 2026
3 checks passed
@devxoul devxoul deleted the feat/slack-extended-api branch March 22, 2026 03:19
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