agent-messenger 1.0.0 → 1.2.0
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/.claude/commands/release.md +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/.github/workflows/ci.yml +1 -1
- package/.github/workflows/e2e.yml.disabled +69 -0
- package/CONTRIBUTING.md +2 -2
- package/README.md +18 -15
- package/biome.json +34 -2
- package/bun.lock +63 -0
- package/dist/package.json +8 -4
- package/dist/src/cli.d.ts.map +1 -1
- package/dist/src/cli.js +4 -1
- package/dist/src/cli.js.map +1 -1
- package/dist/src/platforms/discord/cli.js +4 -4
- package/dist/src/platforms/discord/cli.js.map +1 -1
- package/dist/src/platforms/discord/client.d.ts +26 -5
- package/dist/src/platforms/discord/client.d.ts.map +1 -1
- package/dist/src/platforms/discord/client.js +115 -17
- package/dist/src/platforms/discord/client.js.map +1 -1
- package/dist/src/platforms/discord/commands/auth.js +16 -16
- package/dist/src/platforms/discord/commands/auth.js.map +1 -1
- package/dist/src/platforms/discord/commands/channel.js +4 -4
- package/dist/src/platforms/discord/commands/channel.js.map +1 -1
- package/dist/src/platforms/discord/commands/dm.d.ts +9 -0
- package/dist/src/platforms/discord/commands/dm.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/dm.js +68 -0
- package/dist/src/platforms/discord/commands/dm.js.map +1 -0
- package/dist/src/platforms/discord/commands/friend.d.ts +3 -0
- package/dist/src/platforms/discord/commands/friend.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/friend.js +39 -0
- package/dist/src/platforms/discord/commands/friend.js.map +1 -0
- package/dist/src/platforms/discord/commands/index.d.ts +1 -1
- package/dist/src/platforms/discord/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/discord/commands/index.js +1 -1
- package/dist/src/platforms/discord/commands/index.js.map +1 -1
- package/dist/src/platforms/discord/commands/member.d.ts +3 -0
- package/dist/src/platforms/discord/commands/member.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/member.js +47 -0
- package/dist/src/platforms/discord/commands/member.js.map +1 -0
- package/dist/src/platforms/discord/commands/mention.d.ts +8 -0
- package/dist/src/platforms/discord/commands/mention.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/mention.js +47 -0
- package/dist/src/platforms/discord/commands/mention.js.map +1 -0
- package/dist/src/platforms/discord/commands/message.d.ts +13 -0
- package/dist/src/platforms/discord/commands/message.d.ts.map +1 -1
- package/dist/src/platforms/discord/commands/message.js +95 -1
- package/dist/src/platforms/discord/commands/message.js.map +1 -1
- package/dist/src/platforms/discord/commands/note.d.ts +3 -0
- package/dist/src/platforms/discord/commands/note.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/note.js +56 -0
- package/dist/src/platforms/discord/commands/note.js.map +1 -0
- package/dist/src/platforms/discord/commands/profile.d.ts +3 -0
- package/dist/src/platforms/discord/commands/profile.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/profile.js +47 -0
- package/dist/src/platforms/discord/commands/profile.js.map +1 -0
- package/dist/src/platforms/discord/commands/server.d.ts +15 -0
- package/dist/src/platforms/discord/commands/server.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/server.js +102 -0
- package/dist/src/platforms/discord/commands/server.js.map +1 -0
- package/dist/src/platforms/discord/commands/snapshot.js +10 -10
- package/dist/src/platforms/discord/commands/snapshot.js.map +1 -1
- package/dist/src/platforms/discord/commands/thread.d.ts +10 -0
- package/dist/src/platforms/discord/commands/thread.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/thread.js +67 -0
- package/dist/src/platforms/discord/commands/thread.js.map +1 -0
- package/dist/src/platforms/discord/commands/user.d.ts.map +1 -1
- package/dist/src/platforms/discord/commands/user.js +14 -5
- package/dist/src/platforms/discord/commands/user.js.map +1 -1
- package/dist/src/platforms/discord/credential-manager.d.ts +13 -13
- package/dist/src/platforms/discord/credential-manager.d.ts.map +1 -1
- package/dist/src/platforms/discord/credential-manager.js +28 -22
- package/dist/src/platforms/discord/credential-manager.js.map +1 -1
- package/dist/src/platforms/discord/super-properties.d.ts +4 -0
- package/dist/src/platforms/discord/super-properties.d.ts.map +1 -0
- package/dist/src/platforms/discord/super-properties.js +50 -0
- package/dist/src/platforms/discord/super-properties.js.map +1 -0
- package/dist/src/platforms/discord/token-extractor.d.ts +6 -1
- package/dist/src/platforms/discord/token-extractor.d.ts.map +1 -1
- package/dist/src/platforms/discord/token-extractor.js +27 -2
- package/dist/src/platforms/discord/token-extractor.js.map +1 -1
- package/dist/src/platforms/discord/types.d.ts +389 -22
- package/dist/src/platforms/discord/types.d.ts.map +1 -1
- package/dist/src/platforms/discord/types.js +46 -4
- package/dist/src/platforms/discord/types.js.map +1 -1
- package/dist/src/platforms/slack/cli.d.ts.map +1 -1
- package/dist/src/platforms/slack/cli.js +7 -2
- package/dist/src/platforms/slack/cli.js.map +1 -1
- package/dist/src/platforms/slack/client.d.ts +19 -1
- package/dist/src/platforms/slack/client.d.ts.map +1 -1
- package/dist/src/platforms/slack/client.js +134 -0
- package/dist/src/platforms/slack/client.js.map +1 -1
- package/dist/src/platforms/slack/commands/activity.d.ts +3 -0
- package/dist/src/platforms/slack/commands/activity.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/activity.js +40 -0
- package/dist/src/platforms/slack/commands/activity.js.map +1 -0
- package/dist/src/platforms/slack/commands/drafts.d.ts +3 -0
- package/dist/src/platforms/slack/commands/drafts.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/drafts.js +45 -0
- package/dist/src/platforms/slack/commands/drafts.js.map +1 -0
- package/dist/src/platforms/slack/commands/index.d.ts +5 -0
- package/dist/src/platforms/slack/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/slack/commands/index.js +5 -0
- package/dist/src/platforms/slack/commands/index.js.map +1 -1
- package/dist/src/platforms/slack/commands/saved.d.ts +3 -0
- package/dist/src/platforms/slack/commands/saved.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/saved.js +54 -0
- package/dist/src/platforms/slack/commands/saved.js.map +1 -0
- package/dist/src/platforms/slack/commands/sections.d.ts +3 -0
- package/dist/src/platforms/slack/commands/sections.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/sections.js +37 -0
- package/dist/src/platforms/slack/commands/sections.js.map +1 -0
- package/dist/src/platforms/slack/commands/unread.d.ts +12 -0
- package/dist/src/platforms/slack/commands/unread.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/unread.js +89 -0
- package/dist/src/platforms/slack/commands/unread.js.map +1 -0
- package/dist/src/platforms/slack/credential-manager.d.ts.map +1 -1
- package/dist/src/platforms/slack/credential-manager.js +20 -6
- package/dist/src/platforms/slack/credential-manager.js.map +1 -1
- package/dist/src/platforms/slack/token-extractor.d.ts +8 -1
- package/dist/src/platforms/slack/token-extractor.d.ts.map +1 -1
- package/dist/src/platforms/slack/token-extractor.js +83 -11
- package/dist/src/platforms/slack/token-extractor.js.map +1 -1
- package/dist/src/platforms/slack/types.d.ts +52 -0
- package/dist/src/platforms/slack/types.d.ts.map +1 -1
- package/dist/src/platforms/slack/types.js.map +1 -1
- package/dist/src/platforms/teams/cli.d.ts.map +1 -0
- package/dist/{cli.js → src/platforms/teams/cli.js} +11 -10
- package/dist/src/platforms/teams/cli.js.map +1 -0
- package/dist/src/platforms/teams/client.d.ts +32 -0
- package/dist/src/platforms/teams/client.d.ts.map +1 -0
- package/dist/src/platforms/teams/client.js +202 -0
- package/dist/src/platforms/teams/client.js.map +1 -0
- package/dist/src/platforms/teams/commands/auth.d.ts +14 -0
- package/dist/src/platforms/teams/commands/auth.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/auth.js +176 -0
- package/dist/src/platforms/teams/commands/auth.js.map +1 -0
- package/dist/src/platforms/teams/commands/channel.d.ts +13 -0
- package/dist/src/platforms/teams/commands/channel.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/channel.js +97 -0
- package/dist/src/platforms/teams/commands/channel.js.map +1 -0
- package/dist/src/platforms/teams/commands/file.d.ts +12 -0
- package/dist/src/platforms/teams/commands/file.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/file.js +104 -0
- package/dist/src/platforms/teams/commands/file.js.map +1 -0
- package/dist/{commands → src/platforms/teams/commands}/index.d.ts +5 -2
- package/dist/src/platforms/teams/commands/index.d.ts.map +1 -0
- package/dist/{commands → src/platforms/teams/commands}/index.js +5 -2
- package/dist/src/platforms/teams/commands/index.js.map +1 -0
- package/dist/src/platforms/teams/commands/message.d.ts +17 -0
- package/dist/src/platforms/teams/commands/message.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/message.js +133 -0
- package/dist/src/platforms/teams/commands/message.js.map +1 -0
- package/dist/src/platforms/teams/commands/reaction.d.ts +9 -0
- package/dist/src/platforms/teams/commands/reaction.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/reaction.js +68 -0
- package/dist/src/platforms/teams/commands/reaction.js.map +1 -0
- package/dist/src/platforms/teams/commands/snapshot.d.ts +10 -0
- package/dist/src/platforms/teams/commands/snapshot.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/snapshot.js +85 -0
- package/dist/src/platforms/teams/commands/snapshot.js.map +1 -0
- package/dist/src/platforms/teams/commands/team.d.ts +18 -0
- package/dist/src/platforms/teams/commands/team.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/team.js +130 -0
- package/dist/src/platforms/teams/commands/team.js.map +1 -0
- package/dist/src/platforms/teams/commands/user.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/user.js +88 -0
- package/dist/src/platforms/teams/commands/user.js.map +1 -0
- package/dist/src/platforms/teams/credential-manager.d.ts +18 -0
- package/dist/src/platforms/teams/credential-manager.d.ts.map +1 -0
- package/dist/src/platforms/teams/credential-manager.js +81 -0
- package/dist/src/platforms/teams/credential-manager.js.map +1 -0
- package/dist/src/platforms/teams/index.d.ts +4 -0
- package/dist/src/platforms/teams/index.d.ts.map +1 -0
- package/dist/src/platforms/teams/index.js +6 -0
- package/dist/src/platforms/teams/index.js.map +1 -0
- package/dist/src/platforms/teams/token-extractor.d.ts +41 -0
- package/dist/src/platforms/teams/token-extractor.d.ts.map +1 -0
- package/dist/src/platforms/teams/token-extractor.js +360 -0
- package/dist/src/platforms/teams/token-extractor.js.map +1 -0
- package/dist/src/platforms/teams/types.d.ts +209 -0
- package/dist/src/platforms/teams/types.d.ts.map +1 -0
- package/dist/src/platforms/teams/types.js +65 -0
- package/dist/src/platforms/teams/types.js.map +1 -0
- package/dist/src/shared/utils/derived-key-cache.d.ts +20 -0
- package/dist/src/shared/utils/derived-key-cache.d.ts.map +1 -0
- package/dist/src/shared/utils/derived-key-cache.js +52 -0
- package/dist/src/shared/utils/derived-key-cache.js.map +1 -0
- package/docs/README.md +113 -0
- package/docs/biome.json +8 -0
- package/docs/bun.lock +1426 -0
- package/docs/content/docs/agent-skills.mdx +98 -0
- package/docs/content/docs/index.mdx +124 -0
- package/docs/{discord.md → content/docs/integrations/discord.mdx} +46 -21
- package/docs/content/docs/integrations/meta.json +5 -0
- package/docs/{slack.md → content/docs/integrations/slack.mdx} +5 -4
- package/docs/content/docs/integrations/teams.mdx +322 -0
- package/docs/content/docs/meta.json +8 -0
- package/docs/content/docs/quick-start.mdx +103 -0
- package/docs/eslint.config.mjs +30 -0
- package/docs/next.config.ts +10 -0
- package/docs/package.json +42 -0
- package/docs/postcss.config.mjs +7 -0
- package/docs/public/file.svg +1 -0
- package/docs/public/globe.svg +1 -0
- package/docs/public/next.svg +1 -0
- package/docs/public/vercel.svg +1 -0
- package/docs/public/window.svg +1 -0
- package/docs/source.config.ts +11 -0
- package/docs/src/app/api/search/route.ts +4 -0
- package/docs/src/app/docs/[[...slug]]/page.tsx +53 -0
- package/docs/src/app/docs/layout.tsx +21 -0
- package/docs/src/app/globals.css +10 -0
- package/docs/src/app/icon.png +0 -0
- package/docs/src/app/layout.config.tsx +7 -0
- package/docs/src/app/layout.tsx +35 -0
- package/docs/src/app/page.tsx +489 -0
- package/docs/src/lib/source.ts +15 -0
- package/docs/src/mdx-components.tsx +18 -0
- package/docs/tsconfig.json +36 -0
- package/e2e/README.md +256 -0
- package/e2e/config.ts +51 -0
- package/e2e/discord.e2e.test.ts +252 -0
- package/e2e/helpers.ts +107 -0
- package/e2e/slack.e2e.test.ts +309 -0
- package/package.json +8 -4
- package/scripts/postbuild.ts +15 -0
- package/skills/agent-discord/SKILL.md +96 -30
- package/skills/agent-discord/references/authentication.md +27 -27
- package/skills/agent-discord/references/common-patterns.md +15 -15
- package/skills/agent-discord/templates/post-message.sh +6 -6
- package/skills/agent-discord/templates/{guild-summary.sh → server-summary.sh} +20 -20
- package/skills/agent-slack/SKILL.md +53 -0
- package/skills/agent-teams/SKILL.md +292 -0
- package/skills/agent-teams/references/authentication.md +375 -0
- package/skills/agent-teams/references/common-patterns.md +596 -0
- package/skills/agent-teams/templates/monitor-channel.sh +239 -0
- package/skills/agent-teams/templates/post-message.sh +224 -0
- package/skills/agent-teams/templates/team-summary.sh +210 -0
- package/src/cli.ts +4 -0
- package/src/platforms/discord/cli.ts +3 -3
- package/src/platforms/discord/client.test.ts +15 -15
- package/src/platforms/discord/client.ts +163 -17
- package/src/platforms/discord/commands/auth.test.ts +53 -37
- package/src/platforms/discord/commands/auth.ts +16 -16
- package/src/platforms/discord/commands/channel.test.ts +58 -46
- package/src/platforms/discord/commands/channel.ts +4 -4
- package/src/platforms/discord/commands/dm.test.ts +146 -0
- package/src/platforms/discord/commands/dm.ts +85 -0
- package/src/platforms/discord/commands/file.test.ts +40 -53
- package/src/platforms/discord/commands/friend.test.ts +134 -0
- package/src/platforms/discord/commands/friend.ts +45 -0
- package/src/platforms/discord/commands/index.ts +1 -1
- package/src/platforms/discord/commands/member.test.ts +98 -0
- package/src/platforms/discord/commands/member.ts +59 -0
- package/src/platforms/discord/commands/mention.test.ts +129 -0
- package/src/platforms/discord/commands/mention.ts +59 -0
- package/src/platforms/discord/commands/message.test.ts +139 -44
- package/src/platforms/discord/commands/message.ts +134 -1
- package/src/platforms/discord/commands/note.test.ts +84 -0
- package/src/platforms/discord/commands/note.ts +73 -0
- package/src/platforms/discord/commands/profile.test.ts +107 -0
- package/src/platforms/discord/commands/profile.ts +55 -0
- package/src/platforms/discord/commands/reaction.test.ts +54 -42
- package/src/platforms/discord/commands/server.test.ts +137 -0
- package/src/platforms/discord/commands/{guild.ts → server.ts} +31 -31
- package/src/platforms/discord/commands/snapshot.test.ts +1 -1
- package/src/platforms/discord/commands/snapshot.ts +10 -10
- package/src/platforms/discord/commands/thread.test.ts +121 -0
- package/src/platforms/discord/commands/thread.ts +92 -0
- package/src/platforms/discord/commands/user.test.ts +8 -8
- package/src/platforms/discord/commands/user.ts +16 -5
- package/src/platforms/discord/credential-manager.test.ts +137 -136
- package/src/platforms/discord/credential-manager.ts +35 -26
- package/src/platforms/discord/super-properties.ts +55 -0
- package/src/platforms/discord/token-extractor.test.ts +133 -383
- package/src/platforms/discord/token-extractor.ts +37 -3
- package/src/platforms/discord/types.test.ts +8 -8
- package/src/platforms/discord/types.ts +144 -8
- package/{tests → src/platforms/slack}/cli.test.ts +3 -3
- package/src/platforms/slack/cli.ts +10 -0
- package/{tests/slack-client.test.ts → src/platforms/slack/client.test.ts} +1 -1
- package/src/platforms/slack/client.ts +172 -1
- package/src/platforms/slack/commands/activity.test.ts +147 -0
- package/src/platforms/slack/commands/activity.ts +65 -0
- package/{tests → src/platforms/slack}/commands/auth.test.ts +25 -13
- package/{tests → src/platforms/slack}/commands/channel.test.ts +2 -2
- package/src/platforms/slack/commands/drafts.test.ts +136 -0
- package/src/platforms/slack/commands/drafts.ts +62 -0
- package/{tests → src/platforms/slack}/commands/file.test.ts +2 -2
- package/src/platforms/slack/commands/index.ts +5 -0
- package/{tests → src/platforms/slack}/commands/message.test.ts +2 -2
- package/{tests → src/platforms/slack}/commands/reaction.test.ts +1 -1
- package/src/platforms/slack/commands/saved.test.ts +140 -0
- package/src/platforms/slack/commands/saved.ts +71 -0
- package/src/platforms/slack/commands/sections.test.ts +80 -0
- package/src/platforms/slack/commands/sections.ts +50 -0
- package/{tests → src/platforms/slack}/commands/snapshot.test.ts +117 -105
- package/src/platforms/slack/commands/unread.test.ts +139 -0
- package/src/platforms/slack/commands/unread.ts +129 -0
- package/{tests → src/platforms/slack}/commands/user.test.ts +3 -3
- package/{tests → src/platforms/slack}/commands/workspace.test.ts +44 -95
- package/{tests → src/platforms/slack}/credential-manager.test.ts +2 -2
- package/src/platforms/slack/credential-manager.ts +22 -7
- package/src/platforms/slack/token-extractor-node-test.ts +40 -0
- package/src/platforms/slack/token-extractor-node.test.ts +10 -0
- package/src/platforms/slack/token-extractor.ts +93 -12
- package/{tests → src/platforms/slack}/types.test.ts +1 -1
- package/src/platforms/slack/types.ts +58 -0
- package/src/platforms/teams/cli.ts +36 -0
- package/src/platforms/teams/client.test.ts +500 -0
- package/src/platforms/teams/client.ts +365 -0
- package/src/platforms/teams/commands/auth.test.ts +99 -0
- package/src/platforms/teams/commands/auth.ts +232 -0
- package/src/platforms/teams/commands/channel.test.ts +147 -0
- package/src/platforms/teams/commands/channel.ts +129 -0
- package/src/platforms/teams/commands/file.test.ts +88 -0
- package/src/platforms/teams/commands/file.ts +144 -0
- package/src/platforms/teams/commands/index.ts +12 -0
- package/src/platforms/teams/commands/message.test.ts +110 -0
- package/src/platforms/teams/commands/message.ts +188 -0
- package/src/platforms/teams/commands/reaction.test.ts +87 -0
- package/src/platforms/teams/commands/reaction.ts +104 -0
- package/src/platforms/teams/commands/snapshot.test.ts +35 -0
- package/src/platforms/teams/commands/snapshot.ts +115 -0
- package/src/platforms/teams/commands/team.test.ts +157 -0
- package/src/platforms/teams/commands/team.ts +164 -0
- package/src/platforms/teams/commands/user.test.ts +83 -0
- package/src/platforms/teams/commands/user.ts +112 -0
- package/src/platforms/teams/credential-manager.test.ts +178 -0
- package/src/platforms/teams/credential-manager.ts +92 -0
- package/src/platforms/teams/index.ts +5 -0
- package/src/platforms/teams/token-extractor.test.ts +429 -0
- package/src/platforms/teams/token-extractor.ts +490 -0
- package/src/platforms/teams/types.test.ts +226 -0
- package/src/platforms/teams/types.ts +140 -0
- package/src/shared/utils/derived-key-cache.test.ts +136 -0
- package/src/shared/utils/derived-key-cache.ts +63 -0
- package/tsconfig.json +1 -1
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js.map +0 -1
- package/dist/commands/auth.d.ts +0 -3
- package/dist/commands/auth.d.ts.map +0 -1
- package/dist/commands/auth.js +0 -140
- package/dist/commands/auth.js.map +0 -1
- package/dist/commands/channel.d.ts +0 -3
- package/dist/commands/channel.d.ts.map +0 -1
- package/dist/commands/channel.js +0 -118
- package/dist/commands/channel.js.map +0 -1
- package/dist/commands/file.d.ts +0 -3
- package/dist/commands/file.d.ts.map +0 -1
- package/dist/commands/file.js +0 -113
- package/dist/commands/file.js.map +0 -1
- package/dist/commands/index.d.ts.map +0 -1
- package/dist/commands/index.js.map +0 -1
- package/dist/commands/message.d.ts +0 -3
- package/dist/commands/message.d.ts.map +0 -1
- package/dist/commands/message.js +0 -214
- package/dist/commands/message.js.map +0 -1
- package/dist/commands/reaction.d.ts +0 -3
- package/dist/commands/reaction.d.ts.map +0 -1
- package/dist/commands/reaction.js +0 -100
- package/dist/commands/reaction.js.map +0 -1
- package/dist/commands/snapshot.d.ts +0 -3
- package/dist/commands/snapshot.d.ts.map +0 -1
- package/dist/commands/snapshot.js +0 -88
- package/dist/commands/snapshot.js.map +0 -1
- package/dist/commands/user.d.ts.map +0 -1
- package/dist/commands/user.js +0 -96
- package/dist/commands/user.js.map +0 -1
- package/dist/commands/workspace.d.ts +0 -3
- package/dist/commands/workspace.d.ts.map +0 -1
- package/dist/commands/workspace.js +0 -89
- package/dist/commands/workspace.js.map +0 -1
- package/dist/lib/credential-manager.d.ts +0 -13
- package/dist/lib/credential-manager.d.ts.map +0 -1
- package/dist/lib/credential-manager.js +0 -58
- package/dist/lib/credential-manager.js.map +0 -1
- package/dist/lib/index.d.ts +0 -3
- package/dist/lib/index.d.ts.map +0 -1
- package/dist/lib/index.js +0 -3
- package/dist/lib/index.js.map +0 -1
- package/dist/lib/ref-manager.d.ts +0 -26
- package/dist/lib/ref-manager.d.ts.map +0 -1
- package/dist/lib/ref-manager.js +0 -92
- package/dist/lib/ref-manager.js.map +0 -1
- package/dist/lib/slack-client.d.ts +0 -37
- package/dist/lib/slack-client.d.ts.map +0 -1
- package/dist/lib/slack-client.js +0 -379
- package/dist/lib/slack-client.js.map +0 -1
- package/dist/lib/token-extractor.d.ts +0 -28
- package/dist/lib/token-extractor.d.ts.map +0 -1
- package/dist/lib/token-extractor.js +0 -401
- package/dist/lib/token-extractor.js.map +0 -1
- package/dist/src/platforms/discord/client.test.d.ts +0 -2
- package/dist/src/platforms/discord/client.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/client.test.js +0 -367
- package/dist/src/platforms/discord/client.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/auth.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/auth.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/auth.test.js +0 -65
- package/dist/src/platforms/discord/commands/auth.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/channel.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/channel.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/channel.test.js +0 -136
- package/dist/src/platforms/discord/commands/channel.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/file.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/file.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/file.test.js +0 -83
- package/dist/src/platforms/discord/commands/file.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/guild.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/guild.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/guild.test.js +0 -100
- package/dist/src/platforms/discord/commands/guild.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/message.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/message.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/message.test.js +0 -91
- package/dist/src/platforms/discord/commands/message.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/reaction.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/reaction.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/reaction.test.js +0 -115
- package/dist/src/platforms/discord/commands/reaction.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/snapshot.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/snapshot.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/snapshot.test.js +0 -25
- package/dist/src/platforms/discord/commands/snapshot.test.js.map +0 -1
- package/dist/src/platforms/discord/commands/user.test.d.ts +0 -2
- package/dist/src/platforms/discord/commands/user.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/commands/user.test.js +0 -103
- package/dist/src/platforms/discord/commands/user.test.js.map +0 -1
- package/dist/src/platforms/discord/credential-manager.test.d.ts +0 -2
- package/dist/src/platforms/discord/credential-manager.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/credential-manager.test.js +0 -136
- package/dist/src/platforms/discord/credential-manager.test.js.map +0 -1
- package/dist/src/platforms/discord/token-extractor.test.d.ts +0 -2
- package/dist/src/platforms/discord/token-extractor.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/token-extractor.test.js +0 -789
- package/dist/src/platforms/discord/token-extractor.test.js.map +0 -1
- package/dist/src/platforms/discord/types.test.d.ts +0 -2
- package/dist/src/platforms/discord/types.test.d.ts.map +0 -1
- package/dist/src/platforms/discord/types.test.js +0 -211
- package/dist/src/platforms/discord/types.test.js.map +0 -1
- package/dist/src/shared/utils/concurrency.test.d.ts +0 -2
- package/dist/src/shared/utils/concurrency.test.d.ts.map +0 -1
- package/dist/src/shared/utils/concurrency.test.js +0 -39
- package/dist/src/shared/utils/concurrency.test.js.map +0 -1
- package/dist/tests/cli.test.d.ts +0 -2
- package/dist/tests/cli.test.d.ts.map +0 -1
- package/dist/tests/cli.test.js +0 -83
- package/dist/tests/cli.test.js.map +0 -1
- package/dist/tests/commands/.test-slack-data/Local Storage/leveldb/CURRENT +0 -1
- package/dist/tests/commands/.test-slack-data/Local Storage/leveldb/LOCK +0 -0
- package/dist/tests/commands/.test-slack-data/Local Storage/leveldb/LOG +0 -3
- package/dist/tests/commands/.test-slack-data/Local Storage/leveldb/LOG.old +0 -1
- package/dist/tests/commands/.test-slack-data/Local Storage/leveldb/MANIFEST-000004 +0 -0
- package/dist/tests/commands/auth.test.d.ts +0 -2
- package/dist/tests/commands/auth.test.d.ts.map +0 -1
- package/dist/tests/commands/auth.test.js +0 -304
- package/dist/tests/commands/auth.test.js.map +0 -1
- package/dist/tests/commands/channel.test.d.ts +0 -2
- package/dist/tests/commands/channel.test.d.ts.map +0 -1
- package/dist/tests/commands/channel.test.js +0 -166
- package/dist/tests/commands/channel.test.js.map +0 -1
- package/dist/tests/commands/file.test.d.ts +0 -2
- package/dist/tests/commands/file.test.d.ts.map +0 -1
- package/dist/tests/commands/file.test.js +0 -175
- package/dist/tests/commands/file.test.js.map +0 -1
- package/dist/tests/commands/message.test.d.ts +0 -2
- package/dist/tests/commands/message.test.d.ts.map +0 -1
- package/dist/tests/commands/message.test.js +0 -293
- package/dist/tests/commands/message.test.js.map +0 -1
- package/dist/tests/commands/reaction.test.d.ts +0 -2
- package/dist/tests/commands/reaction.test.d.ts.map +0 -1
- package/dist/tests/commands/reaction.test.js +0 -84
- package/dist/tests/commands/reaction.test.js.map +0 -1
- package/dist/tests/commands/snapshot.test.d.ts +0 -2
- package/dist/tests/commands/snapshot.test.d.ts.map +0 -1
- package/dist/tests/commands/snapshot.test.js +0 -280
- package/dist/tests/commands/snapshot.test.js.map +0 -1
- package/dist/tests/commands/user.test.d.ts +0 -2
- package/dist/tests/commands/user.test.d.ts.map +0 -1
- package/dist/tests/commands/user.test.js +0 -117
- package/dist/tests/commands/user.test.js.map +0 -1
- package/dist/tests/commands/workspace.test.d.ts +0 -2
- package/dist/tests/commands/workspace.test.d.ts.map +0 -1
- package/dist/tests/commands/workspace.test.js +0 -453
- package/dist/tests/commands/workspace.test.js.map +0 -1
- package/dist/tests/credential-manager.test.d.ts +0 -2
- package/dist/tests/credential-manager.test.d.ts.map +0 -1
- package/dist/tests/credential-manager.test.js +0 -199
- package/dist/tests/credential-manager.test.js.map +0 -1
- package/dist/tests/slack-client.test.d.ts +0 -2
- package/dist/tests/slack-client.test.d.ts.map +0 -1
- package/dist/tests/slack-client.test.js +0 -741
- package/dist/tests/slack-client.test.js.map +0 -1
- package/dist/tests/types.test.d.ts +0 -2
- package/dist/tests/types.test.d.ts.map +0 -1
- package/dist/tests/types.test.js +0 -215
- package/dist/tests/types.test.js.map +0 -1
- package/dist/types/index.d.ts +0 -369
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/index.js +0 -92
- package/dist/types/index.js.map +0 -1
- package/dist/utils/error-handler.d.ts +0 -2
- package/dist/utils/error-handler.d.ts.map +0 -1
- package/dist/utils/error-handler.js +0 -5
- package/dist/utils/error-handler.js.map +0 -1
- package/dist/utils/output.d.ts +0 -2
- package/dist/utils/output.d.ts.map +0 -1
- package/dist/utils/output.js +0 -4
- package/dist/utils/output.js.map +0 -1
- package/src/platforms/discord/commands/guild.test.ts +0 -117
- /package/dist/{cli.d.ts → src/platforms/teams/cli.d.ts} +0 -0
- /package/dist/{commands → src/platforms/teams/commands}/user.d.ts +0 -0
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Agent Skills
|
|
3
|
+
description: Teach your AI agent how to use Agent Messenger CLIs effectively.
|
|
4
|
+
icon: Hexagon
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Agent Skills are instruction files that teach AI coding agents how to use tools effectively. Agent Messenger includes skills for Slack, Discord, and Teams.
|
|
8
|
+
|
|
9
|
+
## What Are Agent Skills?
|
|
10
|
+
|
|
11
|
+
When you give an AI agent access to a CLI tool, it needs to know:
|
|
12
|
+
- What commands are available
|
|
13
|
+
- How to format arguments
|
|
14
|
+
- What output to expect
|
|
15
|
+
- Best practices and common patterns
|
|
16
|
+
|
|
17
|
+
Agent Skills provide this knowledge in a structured format that AI agents can understand.
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
### Skills CLI
|
|
22
|
+
|
|
23
|
+
The fastest way to add Agent Messenger skills to your project:
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
npx skills add devxoul/agent-messenger
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
This adds the skill files to your project's `.skills/` directory.
|
|
30
|
+
|
|
31
|
+
### Claude Code
|
|
32
|
+
|
|
33
|
+
Add Agent Messenger skills to Claude Code:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
# From terminal
|
|
37
|
+
claude plugin marketplace add devxoul/agent-messenger
|
|
38
|
+
claude plugin install agent-messenger
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Or from within Claude Code:
|
|
42
|
+
|
|
43
|
+
```
|
|
44
|
+
/plugin marketplace add devxoul/agent-messenger
|
|
45
|
+
/plugin install agent-messenger
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### OpenCode
|
|
49
|
+
|
|
50
|
+
Add to your `opencode.jsonc`:
|
|
51
|
+
|
|
52
|
+
```jsonc
|
|
53
|
+
{
|
|
54
|
+
"plugins": [
|
|
55
|
+
"agent-messenger@1.1.0"
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## How It Works
|
|
61
|
+
|
|
62
|
+
Once installed, your AI agent can:
|
|
63
|
+
|
|
64
|
+
1. **Understand the CLI** - Know what commands exist and how to use them
|
|
65
|
+
2. **Extract credentials** - Run `agent-slack auth extract` automatically
|
|
66
|
+
3. **Send messages** - Compose and send messages on your behalf
|
|
67
|
+
4. **Read context** - Get workspace snapshots to understand conversations
|
|
68
|
+
5. **React appropriately** - Add reactions, reply in threads, etc.
|
|
69
|
+
|
|
70
|
+
## Example Interaction
|
|
71
|
+
|
|
72
|
+
With Agent Messenger skills installed, you can ask your AI agent:
|
|
73
|
+
|
|
74
|
+
> "Send a message to #general saying the build passed"
|
|
75
|
+
|
|
76
|
+
The agent will:
|
|
77
|
+
1. Check if credentials are configured
|
|
78
|
+
2. Run `agent-slack auth extract` if needed
|
|
79
|
+
3. Execute `agent-slack message send general "The build passed"`
|
|
80
|
+
4. Confirm the message was sent
|
|
81
|
+
|
|
82
|
+
## Skill Contents
|
|
83
|
+
|
|
84
|
+
Each platform skill includes:
|
|
85
|
+
|
|
86
|
+
| Section | Description |
|
|
87
|
+
|---------|-------------|
|
|
88
|
+
| **Authentication** | How to extract and manage tokens |
|
|
89
|
+
| **Commands** | Full command reference with examples |
|
|
90
|
+
| **Output Format** | Expected JSON structure for parsing |
|
|
91
|
+
| **Error Handling** | Common errors and how to recover |
|
|
92
|
+
| **Best Practices** | Tips for reliable agent workflows |
|
|
93
|
+
|
|
94
|
+
## Learn More
|
|
95
|
+
|
|
96
|
+
- [Agent Skills Documentation](https://agentskills.io/)
|
|
97
|
+
- [Skills CLI](https://skills.sh/)
|
|
98
|
+
- [GitHub Repository](https://github.com/devxoul/agent-messenger)
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: What is Agent Messenger?
|
|
3
|
+
description: Give your AI agent the power to read and send messages across Slack, Discord, Teams and more
|
|
4
|
+
icon: Info
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Agent Messenger is a unified, agent-friendly CLI for messaging platforms. It automatically extracts credentials from your desktop apps—no OAuth flows, no API keys, no admin approval needed.
|
|
8
|
+
|
|
9
|
+
## Why Agent Messenger?
|
|
10
|
+
|
|
11
|
+
### For AI Agents
|
|
12
|
+
|
|
13
|
+
AI agents need to communicate with humans through messaging platforms. But integrating with Slack, Discord, or Teams traditionally requires:
|
|
14
|
+
|
|
15
|
+
- **OAuth setup** - Creating apps, getting admin approval, managing tokens
|
|
16
|
+
- **API keys** - Storing secrets, handling rotation, security concerns
|
|
17
|
+
- **Platform-specific code** - Learning different APIs for each platform
|
|
18
|
+
|
|
19
|
+
Agent Messenger eliminates all of this. Your agent can start sending messages in seconds.
|
|
20
|
+
|
|
21
|
+
### For Developers
|
|
22
|
+
|
|
23
|
+
Building AI-powered workflows that interact with messaging platforms shouldn't require a week of OAuth debugging. Agent Messenger provides:
|
|
24
|
+
|
|
25
|
+
- **Zero configuration** - Extract tokens from your existing desktop apps
|
|
26
|
+
- **Unified interface** - Same commands work across all platforms
|
|
27
|
+
- **JSON output** - Perfect for piping into other tools or LLMs
|
|
28
|
+
|
|
29
|
+
## How It Works
|
|
30
|
+
|
|
31
|
+
Agent Messenger reads authentication tokens directly from your installed desktop apps (Slack, Discord, Teams). These apps store session tokens locally, and Agent Messenger safely extracts them.
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
# Extract credentials from Slack desktop app
|
|
35
|
+
agent-slack auth extract
|
|
36
|
+
|
|
37
|
+
# That's it! Now you can send messages
|
|
38
|
+
agent-slack message send general "Hello from my AI agent!"
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
No app creation. No admin approval. No waiting.
|
|
42
|
+
|
|
43
|
+
## Key Features
|
|
44
|
+
|
|
45
|
+
| Feature | Description |
|
|
46
|
+
|---------|-------------|
|
|
47
|
+
| **Auto-extraction** | Pulls tokens from desktop apps automatically |
|
|
48
|
+
| **Multi-platform** | Slack, Discord, and Microsoft Teams |
|
|
49
|
+
| **Multi-workspace** | Switch between workspaces/servers easily |
|
|
50
|
+
| **JSON output** | Machine-readable by default, `--pretty` for humans |
|
|
51
|
+
| **Comprehensive** | Messages, channels, users, reactions, files |
|
|
52
|
+
|
|
53
|
+
## Why Not MCP?
|
|
54
|
+
|
|
55
|
+
The Model Context Protocol (MCP) is a popular way to give AI agents access to external tools. But it has a fundamental problem: **context bloat**.
|
|
56
|
+
|
|
57
|
+
MCP servers expose all their tools at once. When you connect an MCP server with 50 tools, your AI agent's context window fills up with 50 tool descriptions—even if it only needs one.
|
|
58
|
+
|
|
59
|
+
**Agent Skills + CLI is better:**
|
|
60
|
+
|
|
61
|
+
| MCP Approach | Agent Skills Approach |
|
|
62
|
+
|--------------|----------------------|
|
|
63
|
+
| All tools loaded at once | Load only what you need |
|
|
64
|
+
| Bloated context window | Minimal token usage |
|
|
65
|
+
| Agent confused by options | Focused, relevant tools |
|
|
66
|
+
| Static tool definitions | Dynamic skill loading |
|
|
67
|
+
|
|
68
|
+
With Agent Messenger, your AI agent loads the skill it needs, uses the CLI, and moves on. No wasted tokens.
|
|
69
|
+
|
|
70
|
+
## Why Not OAuth?
|
|
71
|
+
|
|
72
|
+
Traditional Slack/Discord/Teams integrations require OAuth:
|
|
73
|
+
|
|
74
|
+
1. Create an app in the platform's developer portal
|
|
75
|
+
2. Configure OAuth scopes and redirect URLs
|
|
76
|
+
3. Submit for workspace admin approval
|
|
77
|
+
4. Wait days (or weeks) for approval
|
|
78
|
+
5. Handle token refresh, storage, and rotation
|
|
79
|
+
|
|
80
|
+
**Agent Messenger skips all of this.**
|
|
81
|
+
|
|
82
|
+
Your desktop apps already have valid session tokens. Agent Messenger extracts them directly, so you can start sending messages immediately.
|
|
83
|
+
|
|
84
|
+
### When OAuth Makes Sense
|
|
85
|
+
|
|
86
|
+
OAuth is better when you need:
|
|
87
|
+
- **Server-side bots** - Running 24/7 without your desktop app
|
|
88
|
+
- **Multi-user applications** - Many users authenticating separately
|
|
89
|
+
- **Granular permissions** - Fine-tuned access control
|
|
90
|
+
|
|
91
|
+
Bot support is on our roadmap for these use cases.
|
|
92
|
+
|
|
93
|
+
## Design Principles
|
|
94
|
+
|
|
95
|
+
### Zero Configuration
|
|
96
|
+
|
|
97
|
+
The best setup is no setup. Agent Messenger should work the moment you install it.
|
|
98
|
+
|
|
99
|
+
### AI-First, Human-Friendly
|
|
100
|
+
|
|
101
|
+
Default output is JSON for machines. Add `--pretty` for humans. Both are first-class citizens.
|
|
102
|
+
|
|
103
|
+
### Unified Interface
|
|
104
|
+
|
|
105
|
+
Learn once, use everywhere. The same commands work across Slack, Discord, and Teams.
|
|
106
|
+
|
|
107
|
+
### Fail Fast, Fail Clear
|
|
108
|
+
|
|
109
|
+
When something goes wrong, tell the user exactly what and how to fix it. No cryptic error codes.
|
|
110
|
+
|
|
111
|
+
### Respect Privacy
|
|
112
|
+
|
|
113
|
+
Tokens stay on your machine. Nothing is sent to external servers. Your credentials are yours.
|
|
114
|
+
|
|
115
|
+
## Next Steps
|
|
116
|
+
|
|
117
|
+
- [Quick Start](/docs/quick-start) - Get running in 30 seconds
|
|
118
|
+
- [Slack](/docs/integrations/slack) - Full Slack command reference
|
|
119
|
+
- [Discord](/docs/integrations/discord) - Full Discord command reference
|
|
120
|
+
- [Teams](/docs/integrations/teams) - Full Teams command reference
|
|
121
|
+
|
|
122
|
+
## Inspiration
|
|
123
|
+
|
|
124
|
+
Agent Messenger is inspired by [agent-browser](https://github.com/vercel-labs/agent-browser) from Vercel Labs, which takes a similar approach to browser automation for AI agents.
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
title: Discord
|
|
3
|
+
description: Complete reference for the agent-discord CLI.
|
|
4
|
+
---
|
|
2
5
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
> **Note**: `agent-discord` is a convenient shortcut for `agent-messenger discord`.
|
|
6
|
+
> **Tip**: `agent-discord` is a shortcut for `agent-messenger discord`.
|
|
6
7
|
|
|
7
8
|
## Quick Start
|
|
8
9
|
|
|
@@ -10,7 +11,7 @@ Detailed documentation for Discord integration in agent-messenger.
|
|
|
10
11
|
# 1. Extract credentials from Discord desktop app (zero-config!)
|
|
11
12
|
agent-discord auth extract
|
|
12
13
|
|
|
13
|
-
# 2. Get
|
|
14
|
+
# 2. Get server snapshot
|
|
14
15
|
agent-discord snapshot
|
|
15
16
|
|
|
16
17
|
# 3. Send a message
|
|
@@ -34,7 +35,7 @@ This command:
|
|
|
34
35
|
- Auto-detects your platform (macOS/Linux/Windows)
|
|
35
36
|
- Extracts Discord user token from the desktop app
|
|
36
37
|
- Validates token against Discord API
|
|
37
|
-
- Discovers ALL joined
|
|
38
|
+
- Discovers ALL joined servers
|
|
38
39
|
- Stores credentials securely in `~/.config/agent-messenger/`
|
|
39
40
|
|
|
40
41
|
### Authentication Commands
|
|
@@ -47,22 +48,22 @@ agent-discord auth status
|
|
|
47
48
|
agent-discord auth logout
|
|
48
49
|
```
|
|
49
50
|
|
|
50
|
-
##
|
|
51
|
+
## Server Management
|
|
51
52
|
|
|
52
|
-
|
|
53
|
+
You must select a server before using most commands.
|
|
53
54
|
|
|
54
55
|
```bash
|
|
55
|
-
# List all
|
|
56
|
-
agent-discord
|
|
56
|
+
# List all servers
|
|
57
|
+
agent-discord server list
|
|
57
58
|
|
|
58
|
-
# Switch to a different
|
|
59
|
-
agent-discord
|
|
59
|
+
# Switch to a different server
|
|
60
|
+
agent-discord server switch <server-id>
|
|
60
61
|
|
|
61
|
-
# Show current
|
|
62
|
-
agent-discord
|
|
62
|
+
# Show current server
|
|
63
|
+
agent-discord server current
|
|
63
64
|
|
|
64
|
-
# Get
|
|
65
|
-
agent-discord
|
|
65
|
+
# Get server info
|
|
66
|
+
agent-discord server info <server-id>
|
|
66
67
|
```
|
|
67
68
|
|
|
68
69
|
## Commands
|
|
@@ -83,12 +84,36 @@ agent-discord message get <channel-id> <message-id>
|
|
|
83
84
|
|
|
84
85
|
# Delete a message
|
|
85
86
|
agent-discord message delete <channel-id> <message-id> --force
|
|
87
|
+
|
|
88
|
+
# Search messages in current server
|
|
89
|
+
agent-discord message search <query>
|
|
90
|
+
agent-discord message search "bug fix"
|
|
91
|
+
|
|
92
|
+
# Search with filters
|
|
93
|
+
agent-discord message search "meeting" --channel 123456789
|
|
94
|
+
agent-discord message search "report" --author 987654321
|
|
95
|
+
agent-discord message search "screenshot" --has image
|
|
96
|
+
|
|
97
|
+
# Search with sorting and pagination
|
|
98
|
+
agent-discord message search "hello" --sort timestamp --sort-dir desc
|
|
99
|
+
agent-discord message search "test" --limit 10 --offset 20
|
|
86
100
|
```
|
|
87
101
|
|
|
102
|
+
**Search Options:**
|
|
103
|
+
- `--channel <id>` - Filter by specific channel
|
|
104
|
+
- `--author <id>` - Filter by specific author
|
|
105
|
+
- `--has <type>` - Filter by attachment type: `file`, `image`, `video`, `embed`, `link`, `sticker`
|
|
106
|
+
- `--sort <type>` - Sort by: `timestamp` (default), `relevance`
|
|
107
|
+
- `--sort-dir <dir>` - Sort direction: `asc`, `desc` (default)
|
|
108
|
+
- `--limit <n>` - Number of results (max 25, default 25)
|
|
109
|
+
- `--offset <n>` - Pagination offset (default 0)
|
|
110
|
+
|
|
111
|
+
> **Note:** Search requires a current server to be set. Use `agent-discord server switch <server-id>` first.
|
|
112
|
+
|
|
88
113
|
### Channel Commands
|
|
89
114
|
|
|
90
115
|
```bash
|
|
91
|
-
# List channels in current
|
|
116
|
+
# List channels in current server
|
|
92
117
|
agent-discord channel list
|
|
93
118
|
|
|
94
119
|
# Get channel info
|
|
@@ -102,7 +127,7 @@ agent-discord channel history 123456789 --limit 100
|
|
|
102
127
|
### User Commands
|
|
103
128
|
|
|
104
129
|
```bash
|
|
105
|
-
# List
|
|
130
|
+
# List server members
|
|
106
131
|
agent-discord user list
|
|
107
132
|
|
|
108
133
|
# Get user info
|
|
@@ -142,7 +167,7 @@ agent-discord file info <channel-id> <file-id>
|
|
|
142
167
|
|
|
143
168
|
### Snapshot Command
|
|
144
169
|
|
|
145
|
-
Get comprehensive
|
|
170
|
+
Get comprehensive server state for AI agents:
|
|
146
171
|
|
|
147
172
|
```bash
|
|
148
173
|
# Full snapshot (channels, members, recent messages)
|
|
@@ -162,14 +187,14 @@ All commands support these options:
|
|
|
162
187
|
|
|
163
188
|
```bash
|
|
164
189
|
--pretty # Pretty-print JSON output (default is compact JSON)
|
|
165
|
-
--
|
|
190
|
+
--server <id> # Use specific server (overrides current server)
|
|
166
191
|
```
|
|
167
192
|
|
|
168
193
|
## Key Differences from Slack
|
|
169
194
|
|
|
170
195
|
| Concept | Slack | Discord |
|
|
171
196
|
|---------|-------|---------|
|
|
172
|
-
| Server | Workspace |
|
|
197
|
+
| Server | Workspace | Server |
|
|
173
198
|
| Channel ID | Alphanumeric (C01234567) | Numeric snowflake (123456789012345678) |
|
|
174
199
|
| Message ID | Timestamp (1234567890.123456) | Numeric snowflake (123456789012345678) |
|
|
175
200
|
| User ID | Alphanumeric (U01234567) | Numeric snowflake (123456789012345678) |
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
title: Slack
|
|
3
|
+
description: Complete reference for the agent-slack CLI.
|
|
4
|
+
---
|
|
2
5
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
> **Note**: `agent-slack` is a convenient shortcut for `agent-messenger slack`.
|
|
6
|
+
> **Tip**: `agent-slack` is a shortcut for `agent-messenger slack`.
|
|
6
7
|
|
|
7
8
|
## Quick Start
|
|
8
9
|
|
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Teams
|
|
3
|
+
description: Complete reference for the agent-teams CLI.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
> **Tip**: `agent-teams` is a shortcut for `agent-messenger teams`.
|
|
7
|
+
|
|
8
|
+
## Quick Start
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
# 1. Extract credentials from Teams desktop app (zero-config!)
|
|
12
|
+
agent-teams auth extract
|
|
13
|
+
|
|
14
|
+
# 2. Get team snapshot
|
|
15
|
+
agent-teams snapshot
|
|
16
|
+
|
|
17
|
+
# 3. Send a message
|
|
18
|
+
agent-teams message send <channel-id> "Hello from AI agent!"
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Authentication
|
|
22
|
+
|
|
23
|
+
### Seamless Token Extraction
|
|
24
|
+
|
|
25
|
+
agent-teams automatically extracts your Microsoft Teams credentials from the desktop app:
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
agent-teams auth extract
|
|
29
|
+
|
|
30
|
+
# Use --debug for troubleshooting
|
|
31
|
+
agent-teams auth extract --debug
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
This command:
|
|
35
|
+
- Auto-detects your platform (macOS/Linux/Windows)
|
|
36
|
+
- Extracts Teams access token from the desktop app
|
|
37
|
+
- Validates token against Teams API
|
|
38
|
+
- Discovers ALL joined teams
|
|
39
|
+
- Stores credentials securely in `~/.config/agent-messenger/`
|
|
40
|
+
|
|
41
|
+
### ⚠️ TOKEN EXPIRY WARNING
|
|
42
|
+
|
|
43
|
+
**Teams tokens expire in 60-90 minutes!** Unlike Slack and Discord tokens which last much longer, Microsoft Teams uses short-lived OAuth tokens.
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
# Check if your token is still valid
|
|
47
|
+
agent-teams auth status
|
|
48
|
+
|
|
49
|
+
# Re-extract when expired (just run extract again)
|
|
50
|
+
agent-teams auth extract
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
**Best practices for AI agents:**
|
|
54
|
+
- Always check `auth status` before operations
|
|
55
|
+
- Re-run `auth extract` if you get 401 errors
|
|
56
|
+
- Consider automating token refresh in long-running workflows
|
|
57
|
+
|
|
58
|
+
### Authentication Commands
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
# Check auth status (shows expiry time!)
|
|
62
|
+
agent-teams auth status
|
|
63
|
+
|
|
64
|
+
# Logout (clear stored credentials)
|
|
65
|
+
agent-teams auth logout
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Supported Teams Versions
|
|
69
|
+
|
|
70
|
+
agent-teams supports both **New Teams** (WebView2-based, com.microsoft.teams2) and **Classic Teams**:
|
|
71
|
+
|
|
72
|
+
| Version | macOS | Windows | Linux |
|
|
73
|
+
|---------|:-----:|:-------:|:-----:|
|
|
74
|
+
| New Teams | ✅ | ✅ | N/A |
|
|
75
|
+
| Classic Teams | ✅ | ✅ | ✅ |
|
|
76
|
+
|
|
77
|
+
### Manual Token Input (Last Resort)
|
|
78
|
+
|
|
79
|
+
If automatic extraction fails, you can manually provide a token:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
agent-teams auth extract --token <your-skype-token>
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
**How to get your token manually:**
|
|
86
|
+
|
|
87
|
+
1. Open Microsoft Teams in your browser (teams.microsoft.com)
|
|
88
|
+
2. Open Developer Tools (F12 or Cmd+Option+I)
|
|
89
|
+
3. Go to **Application** > **Cookies** > `https://teams.microsoft.com`
|
|
90
|
+
4. Find the cookie named `skypetoken_asm`
|
|
91
|
+
5. Copy the **Value** (it's a long string starting with `eyJ...`)
|
|
92
|
+
6. Run: `agent-teams auth extract --token "eyJ..."`
|
|
93
|
+
|
|
94
|
+
> **Note**: Browser tokens also expire in 60-90 minutes. For long-running workflows, you may need to refresh periodically.
|
|
95
|
+
|
|
96
|
+
## Team Management
|
|
97
|
+
|
|
98
|
+
Teams uses "teams" as the top-level organizational unit. You must select a team before using most commands.
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
# List all teams
|
|
102
|
+
agent-teams team list
|
|
103
|
+
|
|
104
|
+
# Switch to a different team
|
|
105
|
+
agent-teams team switch <team-id>
|
|
106
|
+
|
|
107
|
+
# Show current team
|
|
108
|
+
agent-teams team current
|
|
109
|
+
|
|
110
|
+
# Get team info
|
|
111
|
+
agent-teams team info <team-id>
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
## Commands
|
|
115
|
+
|
|
116
|
+
### Message Commands
|
|
117
|
+
|
|
118
|
+
```bash
|
|
119
|
+
# Send a message
|
|
120
|
+
agent-teams message send <channel-id> <content>
|
|
121
|
+
agent-teams message send abc123-def456 "Hello world"
|
|
122
|
+
|
|
123
|
+
# List messages
|
|
124
|
+
agent-teams message list <channel-id>
|
|
125
|
+
agent-teams message list abc123-def456 --limit 50
|
|
126
|
+
|
|
127
|
+
# Get a specific message
|
|
128
|
+
agent-teams message get <channel-id> <message-id>
|
|
129
|
+
|
|
130
|
+
# Delete a message
|
|
131
|
+
agent-teams message delete <channel-id> <message-id> --force
|
|
132
|
+
|
|
133
|
+
# Reply to a message (thread)
|
|
134
|
+
agent-teams message reply <channel-id> <message-id> "Reply content"
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
### Channel Commands
|
|
138
|
+
|
|
139
|
+
```bash
|
|
140
|
+
# List channels in current team
|
|
141
|
+
agent-teams channel list
|
|
142
|
+
|
|
143
|
+
# Get channel info
|
|
144
|
+
agent-teams channel info <channel-id>
|
|
145
|
+
|
|
146
|
+
# Get channel message history
|
|
147
|
+
agent-teams channel history <channel-id>
|
|
148
|
+
agent-teams channel history abc123-def456 --limit 100
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
### User Commands
|
|
152
|
+
|
|
153
|
+
```bash
|
|
154
|
+
# List team members
|
|
155
|
+
agent-teams user list
|
|
156
|
+
|
|
157
|
+
# Get user info
|
|
158
|
+
agent-teams user info <user-id>
|
|
159
|
+
|
|
160
|
+
# Get current authenticated user
|
|
161
|
+
agent-teams user me
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
### Reaction Commands
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
# Add reaction
|
|
168
|
+
agent-teams reaction add <channel-id> <message-id> <emoji>
|
|
169
|
+
agent-teams reaction add abc123-def456 msg789 like
|
|
170
|
+
|
|
171
|
+
# Remove reaction
|
|
172
|
+
agent-teams reaction remove <channel-id> <message-id> <emoji>
|
|
173
|
+
|
|
174
|
+
# List reactions on a message
|
|
175
|
+
agent-teams reaction list <channel-id> <message-id>
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
### File Commands
|
|
179
|
+
|
|
180
|
+
```bash
|
|
181
|
+
# Upload file to channel
|
|
182
|
+
agent-teams file upload <channel-id> <path>
|
|
183
|
+
agent-teams file upload abc123-def456 ./report.pdf
|
|
184
|
+
|
|
185
|
+
# List files in channel
|
|
186
|
+
agent-teams file list <channel-id>
|
|
187
|
+
|
|
188
|
+
# Get file info
|
|
189
|
+
agent-teams file info <channel-id> <file-id>
|
|
190
|
+
|
|
191
|
+
# Download file
|
|
192
|
+
agent-teams file download <file-id> <output-path>
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
### Snapshot Command
|
|
196
|
+
|
|
197
|
+
Get comprehensive team state for AI agents:
|
|
198
|
+
|
|
199
|
+
```bash
|
|
200
|
+
# Full snapshot (channels, members, recent messages)
|
|
201
|
+
agent-teams snapshot
|
|
202
|
+
|
|
203
|
+
# Filtered snapshots
|
|
204
|
+
agent-teams snapshot --channels-only
|
|
205
|
+
agent-teams snapshot --users-only
|
|
206
|
+
|
|
207
|
+
# Limit messages per channel
|
|
208
|
+
agent-teams snapshot --limit 10
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
## Global Options
|
|
212
|
+
|
|
213
|
+
All commands support these options:
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
--pretty # Pretty-print JSON output (default is compact JSON)
|
|
217
|
+
--team <id> # Use specific team (overrides current team)
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
## Key Differences: Teams vs Discord vs Slack
|
|
221
|
+
|
|
222
|
+
| Concept | Slack | Discord | Teams |
|
|
223
|
+
|---------|-------|---------|-------|
|
|
224
|
+
| Server/Workspace | Workspace | Guild | Team |
|
|
225
|
+
| Channel ID format | Alphanumeric (C01234567) | Numeric snowflake | UUID (abc123-def456-...) |
|
|
226
|
+
| Message ID format | Timestamp (1234567890.123456) | Numeric snowflake | UUID |
|
|
227
|
+
| User ID format | Alphanumeric (U01234567) | Numeric snowflake | UUID (Azure AD Object ID) |
|
|
228
|
+
| Token lifetime | Long-lived | Long-lived | **60-90 minutes** |
|
|
229
|
+
| API | Slack Web API | Discord API | Teams Messaging API |
|
|
230
|
+
| Threads | Thread timestamps | Thread channels | Reply chains |
|
|
231
|
+
| Rate limits | Moderate | Moderate | Strict |
|
|
232
|
+
|
|
233
|
+
## Troubleshooting
|
|
234
|
+
|
|
235
|
+
### Token Expired (401 Unauthorized)
|
|
236
|
+
|
|
237
|
+
```bash
|
|
238
|
+
# Teams tokens expire in 60-90 minutes! To refresh:
|
|
239
|
+
# 1. Open Microsoft Teams desktop app
|
|
240
|
+
# 2. Send any message (this refreshes your session cookies)
|
|
241
|
+
# 3. Re-extract:
|
|
242
|
+
agent-teams auth extract
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
### "No teams found"
|
|
246
|
+
|
|
247
|
+
Ensure you're a member of at least one team in the Teams desktop app, then:
|
|
248
|
+
```bash
|
|
249
|
+
agent-teams auth extract --debug
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
### "Channel not found"
|
|
253
|
+
|
|
254
|
+
Teams channel IDs are UUIDs. Make sure you're using the full ID:
|
|
255
|
+
```bash
|
|
256
|
+
# Get channel list to find correct IDs
|
|
257
|
+
agent-teams channel list --pretty
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
### Rate Limiting (429 Too Many Requests)
|
|
261
|
+
|
|
262
|
+
Teams API has strict rate limits. Wait and retry:
|
|
263
|
+
```bash
|
|
264
|
+
# Add delays between operations in scripts
|
|
265
|
+
sleep 2
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
### Desktop App Not Detected
|
|
269
|
+
|
|
270
|
+
Ensure Teams desktop app is:
|
|
271
|
+
1. Installed (not just web version)
|
|
272
|
+
2. Currently running
|
|
273
|
+
3. Signed in to your account
|
|
274
|
+
|
|
275
|
+
```bash
|
|
276
|
+
# Debug extraction
|
|
277
|
+
agent-teams auth extract --debug
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
### Permission Errors
|
|
281
|
+
|
|
282
|
+
Some operations require specific Microsoft 365 permissions. Check with your IT admin if you encounter persistent 403 errors.
|
|
283
|
+
|
|
284
|
+
## AI Agent Integration
|
|
285
|
+
|
|
286
|
+
See `skills/agent-messenger/` directory for:
|
|
287
|
+
- Complete skill documentation
|
|
288
|
+
- Runnable templates
|
|
289
|
+
|
|
290
|
+
### Example: AI Agent Workflow
|
|
291
|
+
|
|
292
|
+
```bash
|
|
293
|
+
#!/bin/bash
|
|
294
|
+
# Example: Daily standup automation
|
|
295
|
+
|
|
296
|
+
# 1. Check auth (re-extract if needed)
|
|
297
|
+
if ! agent-teams auth status | grep -q "valid"; then
|
|
298
|
+
agent-teams auth extract
|
|
299
|
+
fi
|
|
300
|
+
|
|
301
|
+
# 2. Get team context
|
|
302
|
+
agent-teams snapshot --limit 5 > /tmp/teams-context.json
|
|
303
|
+
|
|
304
|
+
# 3. Send standup reminder
|
|
305
|
+
agent-teams message send $STANDUP_CHANNEL "🌅 Good morning! Time for standup."
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
### Token Refresh Pattern for Long-Running Agents
|
|
309
|
+
|
|
310
|
+
```bash
|
|
311
|
+
# Wrapper function for token-aware operations
|
|
312
|
+
teams_cmd() {
|
|
313
|
+
# Check token validity
|
|
314
|
+
if ! agent-teams auth status 2>/dev/null | grep -q "valid"; then
|
|
315
|
+
agent-teams auth extract
|
|
316
|
+
fi
|
|
317
|
+
agent-teams "$@"
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
# Usage
|
|
321
|
+
teams_cmd message send $CHANNEL "Hello!"
|
|
322
|
+
```
|