feat(messages): add --channel flag to send command#126
Merged
Conversation
The channel can now be specified via --channel as an alternative to the positional argument. When --channel is provided, positional args are treated as text. Both forms are equivalent: slck messages send general "Hello" slck messages send --channel general "Hello"
Address review feedback: use strings.Join for positional args when --channel is provided so multiple args aren't silently dropped. Add test for multi-arg case.
rianjs
added a commit
that referenced
this pull request
Mar 23, 2026
Add missing documentation for emoji list, files download, whoami, --channel and --file flags on messages send. Add emoji:read and files:read OAuth scopes to manifest. Update CHANGELOG with entries for recent features (#120, #122, #123, #125, #126, #130). Add integration test sections for emoji, files, identity, and --channel.
3 tasks
rianjs
added a commit
that referenced
this pull request
Mar 23, 2026
## Summary - Add missing README sections for `emoji list`, `files download`, and `whoami` commands - Document `--channel` and `--file` flags on `messages send` - Add `emoji:read` and `files:read` OAuth scopes to app manifest and scopes table - Add `emoji` → `e` alias to aliases table - Update CHANGELOG with entries for #120, #122, #123, #125, #126, #130 - Add integration test sections: Part 8 (Emoji & Files), Part 9 (Identity) - Add `--channel` flag test case to messaging section - Add `emoji:read` and `files:read` to integration test setup scopes table ## Test plan - [x] No code changes — docs only - [ ] Review README for accuracy against actual CLI behavior - [ ] Verify CHANGELOG entries reference correct PR numbers
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.
Summary
Adds
--channelas an optional flag alternative to the positional channel argument onmessages send. Both forms are equivalent:When
--channelis provided, all positional arguments are treated as text. If neither--channelnor a positional channel is provided, the command returns an error.Motivation
The positional-only syntax isn't always intuitive, especially for AI tooling and MCP integrations that naturally reach for
--channel. This makes the interface more flexible without changing existing behavior.Changes
send.go: Addchannelfield tosendOptions, register--channelflag, updateRunEto resolve channel from flag or positional argmessages_test.go: AddTestSendCmd_ChannelFlagandTestSendCmd_NoChannelError