agent-slack 0.4.2 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -7
- package/dist/index.js +620 -49
- package/dist/index.js.map +11 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,15 +4,17 @@ Slack automation CLI for AI agents (TypeScript + Bun).
|
|
|
4
4
|
|
|
5
5
|
Guiding principle:
|
|
6
6
|
|
|
7
|
-
- **
|
|
8
|
-
- **
|
|
7
|
+
- **Token-efficient** — (compact JSON, minimal duplication, and empty/null fields pruned) so LLMs can consume results cheaply.
|
|
8
|
+
- **Zero-config auth** — Auth just works if you have Slack Desktop (with fallbacks available). No Python dependency.
|
|
9
|
+
- **Human-in-the-loop** — When appropriate (not in CI environments), loop humans in. Ex: `message draft`
|
|
10
|
+
<img width="1228" height="741" alt="image" src="https://github.com/user-attachments/assets/92ecbb71-18ca-4516-a874-c83c154b0709" />
|
|
9
11
|
|
|
10
12
|
## Getting started
|
|
11
13
|
|
|
12
14
|
Install via Bun (recommended):
|
|
13
15
|
|
|
14
16
|
```bash
|
|
15
|
-
curl -fsSL https://raw.githubusercontent.com/stablyai/agent-slack/
|
|
17
|
+
curl -fsSL https://raw.githubusercontent.com/stablyai/agent-slack/main/install.sh | sh
|
|
16
18
|
```
|
|
17
19
|
|
|
18
20
|
OR npm global install (requires Node >= 22.5):
|
|
@@ -27,7 +29,7 @@ npm i -g agent-slack
|
|
|
27
29
|
- **Search**: messages + files (with filters)
|
|
28
30
|
- **Artifacts**: auto-download snippets/images/files to local paths for agents
|
|
29
31
|
- **Write**: reply, edit/delete messages, add reactions
|
|
30
|
-
- **Channels**: create channels and invite users by id/handle/email
|
|
32
|
+
- **Channels**: list conversations, create channels, and invite users by id/handle/email
|
|
31
33
|
- **Canvas**: fetch Slack canvases as Markdown
|
|
32
34
|
|
|
33
35
|
## Agent skill
|
|
@@ -42,21 +44,24 @@ npx skills add stablyai/agent-slack
|
|
|
42
44
|
|
|
43
45
|
<details>
|
|
44
46
|
<summary>Manual installation</summary>
|
|
47
|
+
|
|
45
48
|
```bash
|
|
46
49
|
bash ./scripts/install-skill.sh
|
|
47
50
|
```
|
|
51
|
+
|
|
48
52
|
</details>
|
|
49
53
|
|
|
50
54
|
## Command map (high level)
|
|
51
55
|
|
|
52
56
|
```text
|
|
53
57
|
agent-slack
|
|
54
|
-
├── update
|
|
58
|
+
├── update # self-update (detects npm/bun/binary)
|
|
55
59
|
├── auth
|
|
56
60
|
│ ├── whoami
|
|
57
61
|
│ ├── test
|
|
58
62
|
│ ├── import-desktop
|
|
59
63
|
│ ├── import-chrome
|
|
64
|
+
│ ├── import-firefox
|
|
60
65
|
│ └── parse-curl
|
|
61
66
|
├── message
|
|
62
67
|
│ ├── get <target> # fetch 1 message (+ thread meta )
|
|
@@ -69,6 +74,7 @@ agent-slack
|
|
|
69
74
|
│ ├── add <target> <emoji>
|
|
70
75
|
│ └── remove <target> <emoji>
|
|
71
76
|
├── channel
|
|
77
|
+
│ ├── list # list conversations (user-scoped or all)
|
|
72
78
|
│ ├── new # create channel
|
|
73
79
|
│ └── invite # invite users to channel
|
|
74
80
|
├── user
|
|
@@ -92,7 +98,7 @@ Notes:
|
|
|
92
98
|
On macOS, authentication happens automatically:
|
|
93
99
|
|
|
94
100
|
- Default: reads Slack Desktop local data (no need to quit Slack)
|
|
95
|
-
-
|
|
101
|
+
- Fallbacks: if that fails, tries Chrome/Firefox extraction
|
|
96
102
|
|
|
97
103
|
You can also run manual imports:
|
|
98
104
|
|
|
@@ -100,6 +106,7 @@ You can also run manual imports:
|
|
|
100
106
|
agent-slack auth whoami
|
|
101
107
|
agent-slack auth import-desktop
|
|
102
108
|
agent-slack auth import-chrome
|
|
109
|
+
agent-slack auth import-firefox
|
|
103
110
|
agent-slack auth test
|
|
104
111
|
```
|
|
105
112
|
|
|
@@ -208,9 +215,18 @@ agent-slack message edit "#general" "Updated text" --workspace "myteam" --ts "17
|
|
|
208
215
|
agent-slack message delete "#general" --workspace "myteam" --ts "1770165109.628379"
|
|
209
216
|
```
|
|
210
217
|
|
|
211
|
-
###
|
|
218
|
+
### List, create, and invite channels
|
|
212
219
|
|
|
213
220
|
```bash
|
|
221
|
+
# List conversations for current user (users.conversations)
|
|
222
|
+
agent-slack channel list
|
|
223
|
+
|
|
224
|
+
# List conversations for a specific user
|
|
225
|
+
agent-slack channel list --user "@alice" --limit 50
|
|
226
|
+
|
|
227
|
+
# List all workspace conversations (conversations.list)
|
|
228
|
+
agent-slack channel list --all --limit 100
|
|
229
|
+
|
|
214
230
|
# Create a public channel
|
|
215
231
|
agent-slack channel new --name "incident-war-room"
|
|
216
232
|
|
|
@@ -229,6 +245,8 @@ agent-slack channel invite --channel "incident-war-room" --users "partner@vendor
|
|
|
229
245
|
|
|
230
246
|
Notes:
|
|
231
247
|
|
|
248
|
+
- `channel list` returns a single page plus `next_cursor`; use `--cursor` to fetch the next page.
|
|
249
|
+
- `channel list --all` and `channel list --user` are mutually exclusive.
|
|
232
250
|
- `--external` maps to `conversations.inviteShared` and expects email targets.
|
|
233
251
|
- External invites default to restricted mode (`external_limited=true`); add `--allow-external-user-invites` to disable that restriction.
|
|
234
252
|
- External invites require Slack Connect permissions/scopes in your workspace.
|