agent-messenger 2.4.0 → 2.5.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-plugin/plugin.json +1 -1
- package/.github/workflows/release.yml +0 -12
- package/README.md +3 -3
- package/dist/package.json +1 -1
- package/dist/src/platforms/channeltalk/cli.d.ts.map +1 -1
- package/dist/src/platforms/channeltalk/cli.js +2 -1
- package/dist/src/platforms/channeltalk/cli.js.map +1 -1
- package/dist/src/platforms/channeltalk/commands/index.d.ts +1 -0
- package/dist/src/platforms/channeltalk/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/channeltalk/commands/index.js +1 -0
- package/dist/src/platforms/channeltalk/commands/index.js.map +1 -1
- package/dist/src/platforms/channeltalk/commands/whoami.d.ts +22 -0
- package/dist/src/platforms/channeltalk/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/channeltalk/commands/whoami.js +40 -0
- package/dist/src/platforms/channeltalk/commands/whoami.js.map +1 -0
- package/dist/src/platforms/channeltalkbot/cli.d.ts.map +1 -1
- package/dist/src/platforms/channeltalkbot/cli.js +2 -1
- package/dist/src/platforms/channeltalkbot/cli.js.map +1 -1
- package/dist/src/platforms/channeltalkbot/commands/index.d.ts +1 -0
- package/dist/src/platforms/channeltalkbot/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/channeltalkbot/commands/index.js +1 -0
- package/dist/src/platforms/channeltalkbot/commands/index.js.map +1 -1
- package/dist/src/platforms/channeltalkbot/commands/whoami.d.ts +13 -0
- package/dist/src/platforms/channeltalkbot/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/channeltalkbot/commands/whoami.js +31 -0
- package/dist/src/platforms/channeltalkbot/commands/whoami.js.map +1 -0
- package/dist/src/platforms/discord/cli.d.ts.map +1 -1
- package/dist/src/platforms/discord/cli.js +2 -1
- package/dist/src/platforms/discord/cli.js.map +1 -1
- package/dist/src/platforms/discord/commands/index.d.ts +1 -0
- package/dist/src/platforms/discord/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/discord/commands/index.js +1 -0
- package/dist/src/platforms/discord/commands/index.js.map +1 -1
- package/dist/src/platforms/discord/commands/whoami.d.ts +6 -0
- package/dist/src/platforms/discord/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/discord/commands/whoami.js +33 -0
- package/dist/src/platforms/discord/commands/whoami.js.map +1 -0
- package/dist/src/platforms/discordbot/cli.d.ts.map +1 -1
- package/dist/src/platforms/discordbot/cli.js +2 -1
- package/dist/src/platforms/discordbot/cli.js.map +1 -1
- package/dist/src/platforms/discordbot/commands/index.d.ts +1 -0
- package/dist/src/platforms/discordbot/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/discordbot/commands/index.js +1 -0
- package/dist/src/platforms/discordbot/commands/index.js.map +1 -1
- package/dist/src/platforms/discordbot/commands/whoami.d.ts +14 -0
- package/dist/src/platforms/discordbot/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/discordbot/commands/whoami.js +32 -0
- package/dist/src/platforms/discordbot/commands/whoami.js.map +1 -0
- package/dist/src/platforms/instagram/cli.d.ts.map +1 -1
- package/dist/src/platforms/instagram/cli.js +2 -1
- package/dist/src/platforms/instagram/cli.js.map +1 -1
- package/dist/src/platforms/instagram/client.d.ts +6 -0
- package/dist/src/platforms/instagram/client.d.ts.map +1 -1
- package/dist/src/platforms/instagram/client.js +12 -0
- package/dist/src/platforms/instagram/client.js.map +1 -1
- package/dist/src/platforms/instagram/commands/index.d.ts +1 -0
- package/dist/src/platforms/instagram/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/instagram/commands/index.js +1 -0
- package/dist/src/platforms/instagram/commands/index.js.map +1 -1
- package/dist/src/platforms/instagram/commands/whoami.d.ts +7 -0
- package/dist/src/platforms/instagram/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/instagram/commands/whoami.js +19 -0
- package/dist/src/platforms/instagram/commands/whoami.js.map +1 -0
- package/dist/src/platforms/kakaotalk/cli.js +2 -2
- package/dist/src/platforms/kakaotalk/cli.js.map +1 -1
- package/dist/src/platforms/kakaotalk/client.d.ts.map +1 -1
- package/dist/src/platforms/kakaotalk/client.js +173 -21
- package/dist/src/platforms/kakaotalk/client.js.map +1 -1
- package/dist/src/platforms/kakaotalk/commands/index.d.ts +1 -1
- package/dist/src/platforms/kakaotalk/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/kakaotalk/commands/index.js +1 -1
- package/dist/src/platforms/kakaotalk/commands/index.js.map +1 -1
- package/dist/src/platforms/kakaotalk/commands/whoami.d.ts +3 -0
- package/dist/src/platforms/kakaotalk/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/kakaotalk/commands/{profile.js → whoami.js} +5 -5
- package/dist/src/platforms/kakaotalk/commands/whoami.js.map +1 -0
- package/dist/src/platforms/kakaotalk/protocol/session.d.ts +4 -2
- package/dist/src/platforms/kakaotalk/protocol/session.d.ts.map +1 -1
- package/dist/src/platforms/kakaotalk/protocol/session.js +25 -6
- package/dist/src/platforms/kakaotalk/protocol/session.js.map +1 -1
- package/dist/src/platforms/kakaotalk/protocol/types.d.ts +17 -0
- package/dist/src/platforms/kakaotalk/protocol/types.d.ts.map +1 -1
- package/dist/src/platforms/kakaotalk/protocol/types.js.map +1 -1
- package/dist/src/platforms/kakaotalk/types.d.ts +12 -0
- package/dist/src/platforms/kakaotalk/types.d.ts.map +1 -1
- package/dist/src/platforms/kakaotalk/types.js +6 -0
- package/dist/src/platforms/kakaotalk/types.js.map +1 -1
- package/dist/src/platforms/line/cli.js +2 -2
- package/dist/src/platforms/line/cli.js.map +1 -1
- package/dist/src/platforms/line/commands/auth.d.ts.map +1 -1
- package/dist/src/platforms/line/commands/auth.js +9 -59
- package/dist/src/platforms/line/commands/auth.js.map +1 -1
- package/dist/src/platforms/line/commands/index.d.ts +1 -1
- package/dist/src/platforms/line/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/line/commands/index.js +1 -1
- package/dist/src/platforms/line/commands/index.js.map +1 -1
- package/dist/src/platforms/line/commands/whoami.d.ts +3 -0
- package/dist/src/platforms/line/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/line/commands/{profile.js → whoami.js} +5 -5
- package/dist/src/platforms/line/commands/whoami.js.map +1 -0
- package/dist/src/platforms/slack/cli.d.ts.map +1 -1
- package/dist/src/platforms/slack/cli.js +2 -1
- package/dist/src/platforms/slack/cli.js.map +1 -1
- package/dist/src/platforms/slack/commands/index.d.ts +1 -0
- package/dist/src/platforms/slack/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/slack/commands/index.js +1 -0
- package/dist/src/platforms/slack/commands/index.js.map +1 -1
- package/dist/src/platforms/slack/commands/whoami.d.ts +6 -0
- package/dist/src/platforms/slack/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/slack/commands/whoami.js +39 -0
- package/dist/src/platforms/slack/commands/whoami.js.map +1 -0
- package/dist/src/platforms/slackbot/cli.d.ts.map +1 -1
- package/dist/src/platforms/slackbot/cli.js +2 -1
- package/dist/src/platforms/slackbot/cli.js.map +1 -1
- package/dist/src/platforms/slackbot/commands/index.d.ts +1 -0
- package/dist/src/platforms/slackbot/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/slackbot/commands/index.js +1 -0
- package/dist/src/platforms/slackbot/commands/index.js.map +1 -1
- package/dist/src/platforms/slackbot/commands/whoami.d.ts +14 -0
- package/dist/src/platforms/slackbot/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/slackbot/commands/whoami.js +32 -0
- package/dist/src/platforms/slackbot/commands/whoami.js.map +1 -0
- package/dist/src/platforms/teams/cli.d.ts.map +1 -1
- package/dist/src/platforms/teams/cli.js +2 -1
- package/dist/src/platforms/teams/cli.js.map +1 -1
- package/dist/src/platforms/teams/commands/index.d.ts +1 -0
- package/dist/src/platforms/teams/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/teams/commands/index.js +1 -0
- package/dist/src/platforms/teams/commands/index.js.map +1 -1
- package/dist/src/platforms/teams/commands/whoami.d.ts +6 -0
- package/dist/src/platforms/teams/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/teams/commands/whoami.js +30 -0
- package/dist/src/platforms/teams/commands/whoami.js.map +1 -0
- package/dist/src/platforms/telegram/cli.d.ts.map +1 -1
- package/dist/src/platforms/telegram/cli.js +2 -1
- package/dist/src/platforms/telegram/cli.js.map +1 -1
- package/dist/src/platforms/telegram/commands/index.d.ts +1 -0
- package/dist/src/platforms/telegram/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/telegram/commands/index.js +1 -0
- package/dist/src/platforms/telegram/commands/index.js.map +1 -1
- package/dist/src/platforms/telegram/commands/whoami.d.ts +7 -0
- package/dist/src/platforms/telegram/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/telegram/commands/whoami.js +27 -0
- package/dist/src/platforms/telegram/commands/whoami.js.map +1 -0
- package/dist/src/platforms/webex/cli.d.ts.map +1 -1
- package/dist/src/platforms/webex/cli.js +2 -1
- package/dist/src/platforms/webex/cli.js.map +1 -1
- package/dist/src/platforms/webex/commands/index.d.ts +1 -0
- package/dist/src/platforms/webex/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/webex/commands/index.js +1 -0
- package/dist/src/platforms/webex/commands/index.js.map +1 -1
- package/dist/src/platforms/webex/commands/message.js +1 -1
- package/dist/src/platforms/webex/commands/message.js.map +1 -1
- package/dist/src/platforms/webex/commands/whoami.d.ts +6 -0
- package/dist/src/platforms/webex/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/webex/commands/whoami.js +30 -0
- package/dist/src/platforms/webex/commands/whoami.js.map +1 -0
- package/dist/src/platforms/wechatbot/cli.d.ts.map +1 -1
- package/dist/src/platforms/wechatbot/cli.js +2 -1
- package/dist/src/platforms/wechatbot/cli.js.map +1 -1
- package/dist/src/platforms/wechatbot/commands/index.d.ts +1 -0
- package/dist/src/platforms/wechatbot/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/wechatbot/commands/index.js +1 -0
- package/dist/src/platforms/wechatbot/commands/index.js.map +1 -1
- package/dist/src/platforms/wechatbot/commands/whoami.d.ts +12 -0
- package/dist/src/platforms/wechatbot/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/wechatbot/commands/whoami.js +33 -0
- package/dist/src/platforms/wechatbot/commands/whoami.js.map +1 -0
- package/dist/src/platforms/whatsapp/cli.d.ts.map +1 -1
- package/dist/src/platforms/whatsapp/cli.js +2 -1
- package/dist/src/platforms/whatsapp/cli.js.map +1 -1
- package/dist/src/platforms/whatsapp/client.d.ts +8 -0
- package/dist/src/platforms/whatsapp/client.d.ts.map +1 -1
- package/dist/src/platforms/whatsapp/client.js +116 -8
- package/dist/src/platforms/whatsapp/client.js.map +1 -1
- package/dist/src/platforms/whatsapp/commands/auth.d.ts.map +1 -1
- package/dist/src/platforms/whatsapp/commands/auth.js +115 -45
- package/dist/src/platforms/whatsapp/commands/auth.js.map +1 -1
- package/dist/src/platforms/whatsapp/commands/index.d.ts +1 -0
- package/dist/src/platforms/whatsapp/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/whatsapp/commands/index.js +1 -0
- package/dist/src/platforms/whatsapp/commands/index.js.map +1 -1
- package/dist/src/platforms/whatsapp/commands/shared.js +2 -2
- package/dist/src/platforms/whatsapp/commands/shared.js.map +1 -1
- package/dist/src/platforms/whatsapp/commands/whoami.d.ts +7 -0
- package/dist/src/platforms/whatsapp/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/whatsapp/commands/whoami.js +19 -0
- package/dist/src/platforms/whatsapp/commands/whoami.js.map +1 -0
- package/dist/src/platforms/whatsapp/ensure-auth.js +2 -2
- package/dist/src/platforms/whatsapp/ensure-auth.js.map +1 -1
- package/dist/src/platforms/whatsappbot/cli.d.ts.map +1 -1
- package/dist/src/platforms/whatsappbot/cli.js +2 -1
- package/dist/src/platforms/whatsappbot/cli.js.map +1 -1
- package/dist/src/platforms/whatsappbot/commands/index.d.ts +1 -0
- package/dist/src/platforms/whatsappbot/commands/index.d.ts.map +1 -1
- package/dist/src/platforms/whatsappbot/commands/index.js +1 -0
- package/dist/src/platforms/whatsappbot/commands/index.js.map +1 -1
- package/dist/src/platforms/whatsappbot/commands/whoami.d.ts +17 -0
- package/dist/src/platforms/whatsappbot/commands/whoami.d.ts.map +1 -0
- package/dist/src/platforms/whatsappbot/commands/whoami.js +39 -0
- package/dist/src/platforms/whatsappbot/commands/whoami.js.map +1 -0
- package/dist/src/shared/utils/qr.d.ts +15 -0
- package/dist/src/shared/utils/qr.d.ts.map +1 -0
- package/dist/src/shared/utils/qr.js +74 -0
- package/dist/src/shared/utils/qr.js.map +1 -0
- package/dist/src/tui/adapters/whatsapp-adapter.d.ts.map +1 -1
- package/dist/src/tui/adapters/whatsapp-adapter.js +20 -15
- package/dist/src/tui/adapters/whatsapp-adapter.js.map +1 -1
- package/docs/content/docs/cli/channeltalk.mdx +11 -0
- package/docs/content/docs/cli/channeltalkbot.mdx +9 -0
- package/docs/content/docs/cli/discord.mdx +10 -0
- package/docs/content/docs/cli/discordbot.mdx +9 -0
- package/docs/content/docs/cli/instagram.mdx +11 -0
- package/docs/content/docs/cli/kakaotalk.mdx +24 -0
- package/docs/content/docs/cli/line.mdx +4 -4
- package/docs/content/docs/cli/slack.mdx +10 -0
- package/docs/content/docs/cli/slackbot.mdx +9 -0
- package/docs/content/docs/cli/teams.mdx +10 -0
- package/docs/content/docs/cli/telegram.mdx +11 -0
- package/docs/content/docs/cli/webex.mdx +10 -0
- package/docs/content/docs/cli/wechatbot.mdx +9 -0
- package/docs/content/docs/cli/whatsapp.mdx +36 -7
- package/docs/content/docs/cli/whatsappbot.mdx +9 -0
- package/package.json +1 -1
- package/skills/agent-channeltalk/SKILL.md +12 -1
- package/skills/agent-channeltalkbot/SKILL.md +10 -1
- package/skills/agent-discord/SKILL.md +11 -1
- package/skills/agent-discordbot/SKILL.md +10 -1
- package/skills/agent-instagram/SKILL.md +12 -1
- package/skills/agent-kakaotalk/SKILL.md +14 -8
- package/skills/agent-kakaotalk/references/common-patterns.md +1 -1
- package/skills/agent-line/SKILL.md +5 -5
- package/skills/agent-slack/SKILL.md +11 -1
- package/skills/agent-slackbot/SKILL.md +10 -1
- package/skills/agent-teams/SKILL.md +11 -1
- package/skills/agent-telegram/SKILL.md +6 -1
- package/skills/agent-webex/SKILL.md +11 -1
- package/skills/agent-wechatbot/SKILL.md +10 -1
- package/skills/agent-whatsapp/SKILL.md +52 -15
- package/skills/agent-whatsapp/references/authentication.md +36 -6
- package/skills/agent-whatsappbot/SKILL.md +10 -1
- package/src/platforms/channeltalk/cli.ts +2 -0
- package/src/platforms/channeltalk/commands/index.ts +1 -0
- package/src/platforms/channeltalk/commands/whoami.test.ts +64 -0
- package/src/platforms/channeltalk/commands/whoami.ts +62 -0
- package/src/platforms/channeltalkbot/cli.ts +2 -0
- package/src/platforms/channeltalkbot/commands/index.ts +1 -0
- package/src/platforms/channeltalkbot/commands/whoami.test.ts +104 -0
- package/src/platforms/channeltalkbot/commands/whoami.ts +42 -0
- package/src/platforms/discord/cli.ts +2 -0
- package/src/platforms/discord/commands/index.ts +1 -0
- package/src/platforms/discord/commands/whoami.test.ts +91 -0
- package/src/platforms/discord/commands/whoami.ts +36 -0
- package/src/platforms/discordbot/cli.ts +2 -0
- package/src/platforms/discordbot/commands/index.ts +1 -0
- package/src/platforms/discordbot/commands/whoami.test.ts +96 -0
- package/src/platforms/discordbot/commands/whoami.ts +44 -0
- package/src/platforms/instagram/cli.ts +2 -1
- package/src/platforms/instagram/client.ts +13 -0
- package/src/platforms/instagram/commands/chat.test.ts +1 -5
- package/src/platforms/instagram/commands/index.ts +1 -0
- package/src/platforms/instagram/commands/message.test.ts +1 -5
- package/src/platforms/instagram/commands/whoami.test.ts +60 -0
- package/src/platforms/instagram/commands/whoami.ts +21 -0
- package/src/platforms/kakaotalk/cli.ts +2 -2
- package/src/platforms/kakaotalk/client.test.ts +25 -14
- package/src/platforms/kakaotalk/client.ts +204 -24
- package/src/platforms/kakaotalk/commands/index.ts +1 -1
- package/src/platforms/kakaotalk/commands/{profile.test.ts → whoami.test.ts} +37 -5
- package/src/platforms/kakaotalk/commands/{profile.ts → whoami.ts} +4 -4
- package/src/platforms/kakaotalk/protocol/session.ts +27 -7
- package/src/platforms/kakaotalk/protocol/types.ts +9 -0
- package/src/platforms/kakaotalk/types.ts +12 -0
- package/src/platforms/line/cli.ts +2 -2
- package/src/platforms/line/commands/auth.ts +37 -70
- package/src/platforms/line/commands/index.ts +1 -1
- package/src/platforms/line/commands/{profile.test.ts → whoami.test.ts} +11 -11
- package/src/platforms/line/commands/{profile.ts → whoami.ts} +4 -4
- package/src/platforms/slack/cli.ts +2 -0
- package/src/platforms/slack/commands/index.ts +1 -0
- package/src/platforms/slack/commands/whoami.test.ts +126 -0
- package/src/platforms/slack/commands/whoami.ts +40 -0
- package/src/platforms/slackbot/cli.ts +2 -1
- package/src/platforms/slackbot/commands/index.ts +1 -0
- package/src/platforms/slackbot/commands/whoami.test.ts +102 -0
- package/src/platforms/slackbot/commands/whoami.ts +44 -0
- package/src/platforms/teams/cli.ts +2 -0
- package/src/platforms/teams/commands/index.ts +1 -0
- package/src/platforms/teams/commands/whoami.test.ts +83 -0
- package/src/platforms/teams/commands/whoami.ts +33 -0
- package/src/platforms/telegram/cli.ts +2 -1
- package/src/platforms/telegram/commands/index.ts +1 -0
- package/src/platforms/telegram/commands/whoami.test.ts +75 -0
- package/src/platforms/telegram/commands/whoami.ts +29 -0
- package/src/platforms/webex/cli.ts +2 -1
- package/src/platforms/webex/commands/auth.test.ts +58 -46
- package/src/platforms/webex/commands/index.ts +1 -0
- package/src/platforms/webex/commands/member.test.ts +1 -5
- package/src/platforms/webex/commands/message.test.ts +1 -5
- package/src/platforms/webex/commands/message.ts +1 -1
- package/src/platforms/webex/commands/snapshot.test.ts +1 -5
- package/src/platforms/webex/commands/space.test.ts +1 -5
- package/src/platforms/webex/commands/whoami.test.ts +113 -0
- package/src/platforms/webex/commands/whoami.ts +31 -0
- package/src/platforms/webex/credential-manager.test.ts +0 -1
- package/src/platforms/wechatbot/cli.ts +2 -1
- package/src/platforms/wechatbot/commands/index.ts +1 -0
- package/src/platforms/wechatbot/commands/whoami.test.ts +109 -0
- package/src/platforms/wechatbot/commands/whoami.ts +43 -0
- package/src/platforms/whatsapp/cli.ts +2 -1
- package/src/platforms/whatsapp/client.ts +156 -24
- package/src/platforms/whatsapp/commands/auth.ts +176 -70
- package/src/platforms/whatsapp/commands/index.ts +1 -0
- package/src/platforms/whatsapp/commands/shared.ts +2 -2
- package/src/platforms/whatsapp/commands/whoami.test.ts +59 -0
- package/src/platforms/whatsapp/commands/whoami.ts +21 -0
- package/src/platforms/whatsapp/ensure-auth.ts +2 -2
- package/src/platforms/whatsappbot/cli.ts +2 -1
- package/src/platforms/whatsappbot/commands/index.ts +1 -0
- package/src/platforms/whatsappbot/commands/whoami.test.ts +100 -0
- package/src/platforms/whatsappbot/commands/whoami.ts +57 -0
- package/src/shared/utils/qr.ts +92 -0
- package/src/tui/adapters/whatsapp-adapter.ts +19 -16
- package/dist/src/platforms/kakaotalk/commands/profile.d.ts +0 -3
- package/dist/src/platforms/kakaotalk/commands/profile.d.ts.map +0 -1
- package/dist/src/platforms/kakaotalk/commands/profile.js.map +0 -1
- package/dist/src/platforms/line/commands/profile.d.ts +0 -3
- package/dist/src/platforms/line/commands/profile.d.ts.map +0 -1
- package/dist/src/platforms/line/commands/profile.js.map +0 -1
|
@@ -9,14 +9,17 @@ description: Complete reference for the agent-whatsapp CLI.
|
|
|
9
9
|
|
|
10
10
|
WhatsApp integration uses [Baileys](https://github.com/WhiskeySockets/Baileys), a reverse-engineered WhatsApp Web API:
|
|
11
11
|
|
|
12
|
-
- Links as a **companion device** via pairing code, so your phone stays connected.
|
|
12
|
+
- Links as a **companion device** via QR code or pairing code, so your phone stays connected.
|
|
13
13
|
- Each command opens a WebSocket connection on demand and disconnects when done. No persistent background process.
|
|
14
14
|
- Multiple WhatsApp accounts can be linked simultaneously.
|
|
15
15
|
|
|
16
16
|
## Quick Start
|
|
17
17
|
|
|
18
18
|
```bash
|
|
19
|
-
# Link as companion device
|
|
19
|
+
# Link as companion device via QR code (scan with your phone)
|
|
20
|
+
agent-whatsapp auth login --qr
|
|
21
|
+
|
|
22
|
+
# Or link via pairing code (enter the code on your phone)
|
|
20
23
|
agent-whatsapp auth login --phone +1234567890
|
|
21
24
|
|
|
22
25
|
# List chats
|
|
@@ -28,16 +31,23 @@ agent-whatsapp message send +1234567890 "Hello from agent-whatsapp"
|
|
|
28
31
|
|
|
29
32
|
## Authentication
|
|
30
33
|
|
|
31
|
-
|
|
34
|
+
The CLI supports two authentication methods. Both register as a companion (linked) device, so your phone session is never affected.
|
|
32
35
|
|
|
33
|
-
|
|
36
|
+
### QR Code Login
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
agent-whatsapp auth login --qr
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
A QR code is displayed in the terminal and opened in the browser. Scan it with WhatsApp on your phone: Settings > Linked Devices > Link a Device.
|
|
43
|
+
|
|
44
|
+
### Pairing Code Login
|
|
34
45
|
|
|
35
46
|
```bash
|
|
36
|
-
# Start login (displays a pairing code)
|
|
37
47
|
agent-whatsapp auth login --phone +1234567890
|
|
38
48
|
```
|
|
39
49
|
|
|
40
|
-
|
|
50
|
+
A numeric pairing code is displayed. Enter it on your phone: WhatsApp > Settings > Linked Devices > Link with phone number.
|
|
41
51
|
|
|
42
52
|
### Account Management
|
|
43
53
|
|
|
@@ -59,6 +69,17 @@ agent-whatsapp auth logout --account <id>
|
|
|
59
69
|
|
|
60
70
|
## Commands
|
|
61
71
|
|
|
72
|
+
### Whoami Command
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
# Show current authenticated user
|
|
76
|
+
agent-whatsapp whoami
|
|
77
|
+
agent-whatsapp whoami --pretty
|
|
78
|
+
agent-whatsapp whoami --account <account-id>
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Output includes the authenticated user's identity information.
|
|
82
|
+
|
|
62
83
|
### Chat Commands
|
|
63
84
|
|
|
64
85
|
```bash
|
|
@@ -135,6 +156,14 @@ npx -y --package agent-messenger agent-whatsapp chat list --pretty
|
|
|
135
156
|
|
|
136
157
|
**NEVER run `npx agent-whatsapp`** without `--package agent-messenger`. It will fail or install a wrong package.
|
|
137
158
|
|
|
159
|
+
### QR code not scanning
|
|
160
|
+
|
|
161
|
+
1. Make sure WhatsApp is open on your phone
|
|
162
|
+
2. Go to Settings > Linked Devices > Link a Device
|
|
163
|
+
3. Point your phone camera at the QR code in the terminal or browser
|
|
164
|
+
4. If the QR code expires, run `auth login --qr` again for a fresh code
|
|
165
|
+
5. If QR scanning fails, try pairing code: `auth login --phone <number>`
|
|
166
|
+
|
|
138
167
|
### Pairing code not working
|
|
139
168
|
|
|
140
169
|
1. Make sure WhatsApp is open on your phone
|
|
@@ -152,7 +181,7 @@ WhatsApp may disconnect linked devices that are inactive for extended periods. I
|
|
|
152
181
|
agent-whatsapp auth status
|
|
153
182
|
|
|
154
183
|
# Re-link if needed
|
|
155
|
-
agent-whatsapp auth login --
|
|
184
|
+
agent-whatsapp auth login --qr
|
|
156
185
|
```
|
|
157
186
|
|
|
158
187
|
## AI Agent Integration
|
|
@@ -74,6 +74,15 @@ agent-whatsappbot auth remove <account-id>
|
|
|
74
74
|
|
|
75
75
|
## Commands
|
|
76
76
|
|
|
77
|
+
### Whoami Command
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
# Show current authenticated bot
|
|
81
|
+
agent-whatsappbot whoami
|
|
82
|
+
agent-whatsappbot whoami --pretty
|
|
83
|
+
agent-whatsappbot whoami --account <account-id>
|
|
84
|
+
```
|
|
85
|
+
|
|
77
86
|
### Message Commands
|
|
78
87
|
|
|
79
88
|
```bash
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-channeltalk
|
|
3
3
|
description: Interact with Channel Talk using extracted desktop app or browser credentials - read chats, send messages, search messages, manage groups
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-channeltalk:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -186,6 +186,17 @@ agent-channeltalk auth use <workspace-id>
|
|
|
186
186
|
agent-channeltalk auth remove <workspace-id>
|
|
187
187
|
```
|
|
188
188
|
|
|
189
|
+
### Whoami Command
|
|
190
|
+
|
|
191
|
+
```bash
|
|
192
|
+
# Show current authenticated user
|
|
193
|
+
agent-channeltalk whoami
|
|
194
|
+
agent-channeltalk whoami --pretty
|
|
195
|
+
agent-channeltalk whoami --workspace <workspace-id>
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
Output includes the authenticated user's identity information.
|
|
199
|
+
|
|
189
200
|
### Message Commands
|
|
190
201
|
|
|
191
202
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-channeltalkbot
|
|
3
3
|
description: Interact with Channel Talk workspaces using API credentials - send messages, read chats, manage groups and bots
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-channeltalkbot:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -184,6 +184,15 @@ agent-channeltalkbot auth remove <workspace-id>
|
|
|
184
184
|
agent-channeltalkbot auth bot <name>
|
|
185
185
|
```
|
|
186
186
|
|
|
187
|
+
### Whoami Command
|
|
188
|
+
|
|
189
|
+
```bash
|
|
190
|
+
# Show current authenticated bot
|
|
191
|
+
agent-channeltalkbot whoami
|
|
192
|
+
agent-channeltalkbot whoami --pretty
|
|
193
|
+
agent-channeltalkbot whoami --workspace <workspace-id>
|
|
194
|
+
```
|
|
195
|
+
|
|
187
196
|
### Message Commands
|
|
188
197
|
|
|
189
198
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-discord
|
|
3
3
|
description: Interact with Discord servers - send messages, read channels, manage reactions
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-discord:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -145,6 +145,16 @@ agent-discord auth status
|
|
|
145
145
|
agent-discord auth logout
|
|
146
146
|
```
|
|
147
147
|
|
|
148
|
+
### Whoami Command
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
# Show current authenticated user
|
|
152
|
+
agent-discord whoami
|
|
153
|
+
agent-discord whoami --pretty
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
Output includes the authenticated user's identity information.
|
|
157
|
+
|
|
148
158
|
### Message Commands
|
|
149
159
|
|
|
150
160
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-discordbot
|
|
3
3
|
description: Interact with Discord servers using bot tokens - send messages, read channels, manage reactions
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-discordbot:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -158,6 +158,15 @@ agent-discordbot auth use <bot-id>
|
|
|
158
158
|
agent-discordbot auth remove <bot-id>
|
|
159
159
|
```
|
|
160
160
|
|
|
161
|
+
### Whoami Command
|
|
162
|
+
|
|
163
|
+
```bash
|
|
164
|
+
# Show current authenticated bot
|
|
165
|
+
agent-discordbot whoami
|
|
166
|
+
agent-discordbot whoami --pretty
|
|
167
|
+
agent-discordbot whoami --bot <bot-id>
|
|
168
|
+
```
|
|
169
|
+
|
|
161
170
|
### Server Commands
|
|
162
171
|
|
|
163
172
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-instagram
|
|
3
3
|
description: Interact with Instagram DMs - send messages, read conversations, manage accounts
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-instagram:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -242,6 +242,17 @@ agent-instagram auth logout
|
|
|
242
242
|
agent-instagram auth logout --account <id>
|
|
243
243
|
```
|
|
244
244
|
|
|
245
|
+
### Whoami Command
|
|
246
|
+
|
|
247
|
+
```bash
|
|
248
|
+
# Show current authenticated user
|
|
249
|
+
agent-instagram whoami
|
|
250
|
+
agent-instagram whoami --pretty
|
|
251
|
+
agent-instagram whoami --account <account-id>
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
Output includes the authenticated user's identity information.
|
|
255
|
+
|
|
245
256
|
### Chat Commands
|
|
246
257
|
|
|
247
258
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-kakaotalk
|
|
3
3
|
description: Interact with KakaoTalk - send messages, read chats, manage conversations
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-kakaotalk:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -47,8 +47,8 @@ agent-kakaotalk message send <chat-id> "Hello from AI agent!"
|
|
|
47
47
|
# List messages in a chat
|
|
48
48
|
agent-kakaotalk message list <chat-id>
|
|
49
49
|
|
|
50
|
-
# Show your
|
|
51
|
-
agent-kakaotalk
|
|
50
|
+
# Show your identity
|
|
51
|
+
agent-kakaotalk whoami
|
|
52
52
|
```
|
|
53
53
|
|
|
54
54
|
## Authentication
|
|
@@ -288,13 +288,13 @@ agent-kakaotalk auth status --account <account-id>
|
|
|
288
288
|
agent-kakaotalk auth logout --account <account-id>
|
|
289
289
|
```
|
|
290
290
|
|
|
291
|
-
###
|
|
291
|
+
### Whoami Command
|
|
292
292
|
|
|
293
293
|
```bash
|
|
294
|
-
# Show
|
|
295
|
-
agent-kakaotalk
|
|
296
|
-
agent-kakaotalk
|
|
297
|
-
agent-kakaotalk
|
|
294
|
+
# Show current authenticated user
|
|
295
|
+
agent-kakaotalk whoami
|
|
296
|
+
agent-kakaotalk whoami --pretty
|
|
297
|
+
agent-kakaotalk whoami --account <account-id>
|
|
298
298
|
```
|
|
299
299
|
|
|
300
300
|
Output includes:
|
|
@@ -304,6 +304,12 @@ Output includes:
|
|
|
304
304
|
- `original_profile_image_url` — original profile image URL
|
|
305
305
|
- `status_message` — your status message
|
|
306
306
|
- `account_display_id` — your KakaoTalk ID (may be null if not set)
|
|
307
|
+
- `background_image_url` — background image URL
|
|
308
|
+
- `original_background_image_url` — original background image URL
|
|
309
|
+
- `fullname` — real name (may be null)
|
|
310
|
+
- `account_email` — account email (may be null)
|
|
311
|
+
- `pstn_number` — phone number (may be null)
|
|
312
|
+
- `email_verified` — whether email is verified (may be null)
|
|
307
313
|
|
|
308
314
|
### Chat Commands
|
|
309
315
|
|
|
@@ -144,7 +144,7 @@ NEW_MESSAGES=$(agent-kakaotalk message list "$CHAT_ID" --from "$LAST_SEEN")
|
|
|
144
144
|
|
|
145
145
|
**When to use**: Reading long chat histories, catching up on new messages since last check.
|
|
146
146
|
|
|
147
|
-
**Pagination details**: The
|
|
147
|
+
**Pagination details**: The CLI now prefers KakaoTalk's `MCHATLOGS` flow for history reads, fetching message batches from the requested `--from` point and returning the last N messages after deduplication and ascending sort. If that path cannot provide results, it falls back to `CHATONROOM` + `SYNCMSG` for compatibility. As a safety net, both paths are capped at 50 internal pages. A warning is printed to stderr only when that cap is actually hit and the returned history may be incomplete.
|
|
148
148
|
|
|
149
149
|
## Pattern 6: Multi-Chat Broadcast
|
|
150
150
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-line
|
|
3
3
|
description: Interact with LINE - send messages, read chats, manage conversations
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-line:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -237,12 +237,12 @@ agent-line auth logout <account-id>
|
|
|
237
237
|
agent-line auth logout --pretty
|
|
238
238
|
```
|
|
239
239
|
|
|
240
|
-
###
|
|
240
|
+
### Whoami Command
|
|
241
241
|
|
|
242
242
|
```bash
|
|
243
|
-
# Show
|
|
244
|
-
agent-line
|
|
245
|
-
agent-line
|
|
243
|
+
# Show current authenticated user
|
|
244
|
+
agent-line whoami
|
|
245
|
+
agent-line whoami --pretty
|
|
246
246
|
```
|
|
247
247
|
|
|
248
248
|
Output includes:
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-slack
|
|
3
3
|
description: Interact with Slack workspaces - send messages, read channels, manage reactions
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-slack:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -149,6 +149,16 @@ agent-slack auth logout
|
|
|
149
149
|
agent-slack auth logout <workspace-id>
|
|
150
150
|
```
|
|
151
151
|
|
|
152
|
+
### Whoami Command
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
# Show current authenticated user
|
|
156
|
+
agent-slack whoami
|
|
157
|
+
agent-slack whoami --pretty
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
Output includes the authenticated user's identity information.
|
|
161
|
+
|
|
152
162
|
### Message Commands
|
|
153
163
|
|
|
154
164
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-slackbot
|
|
3
3
|
description: Interact with Slack workspaces using bot tokens - send messages, read channels, manage reactions
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-slackbot:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -165,6 +165,15 @@ If a memorized ID returns an error (channel not found, user not found), remove i
|
|
|
165
165
|
|
|
166
166
|
## Commands
|
|
167
167
|
|
|
168
|
+
### Whoami Command
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
# Show current authenticated bot
|
|
172
|
+
agent-slackbot whoami
|
|
173
|
+
agent-slackbot whoami --pretty
|
|
174
|
+
agent-slackbot whoami --bot <bot-id>
|
|
175
|
+
```
|
|
176
|
+
|
|
168
177
|
### Message Commands
|
|
169
178
|
|
|
170
179
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-teams
|
|
3
3
|
description: Interact with Microsoft Teams - send messages, read channels, manage reactions
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-teams:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -161,6 +161,16 @@ agent-teams auth switch-account work
|
|
|
161
161
|
agent-teams auth switch-account personal
|
|
162
162
|
```
|
|
163
163
|
|
|
164
|
+
### Whoami Command
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
# Show current authenticated user
|
|
168
|
+
agent-teams whoami
|
|
169
|
+
agent-teams whoami --pretty
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
Output includes the authenticated user's identity information.
|
|
173
|
+
|
|
164
174
|
### Message Commands
|
|
165
175
|
|
|
166
176
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-telegram
|
|
3
3
|
description: Interact with Telegram through TDLib - authenticate, inspect chats, and send messages
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-telegram:*)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -103,6 +103,11 @@ agent-telegram auth logout # Logout
|
|
|
103
103
|
## Common Commands
|
|
104
104
|
|
|
105
105
|
```bash
|
|
106
|
+
# Show current authenticated user
|
|
107
|
+
agent-telegram whoami
|
|
108
|
+
agent-telegram whoami --pretty
|
|
109
|
+
agent-telegram whoami --account <account-id>
|
|
110
|
+
|
|
106
111
|
# Search chats by title or username
|
|
107
112
|
agent-telegram chat search "project"
|
|
108
113
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-webex
|
|
3
3
|
description: Interact with Cisco Webex - send messages, read spaces, manage memberships
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-webex:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -188,6 +188,16 @@ agent-webex auth status
|
|
|
188
188
|
agent-webex auth logout
|
|
189
189
|
```
|
|
190
190
|
|
|
191
|
+
### Whoami Command
|
|
192
|
+
|
|
193
|
+
```bash
|
|
194
|
+
# Show current authenticated user
|
|
195
|
+
agent-webex whoami
|
|
196
|
+
agent-webex whoami --pretty
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
Output includes the authenticated user's identity information.
|
|
200
|
+
|
|
191
201
|
### Space Commands
|
|
192
202
|
|
|
193
203
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-wechatbot
|
|
3
3
|
description: Interact with WeChat Official Account using API credentials - send messages, manage templates, list followers
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-wechatbot:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -174,6 +174,15 @@ agent-wechatbot auth remove <account-id>
|
|
|
174
174
|
agent-wechatbot auth clear
|
|
175
175
|
```
|
|
176
176
|
|
|
177
|
+
### Whoami Command
|
|
178
|
+
|
|
179
|
+
```bash
|
|
180
|
+
# Show current authenticated bot
|
|
181
|
+
agent-wechatbot whoami
|
|
182
|
+
agent-wechatbot whoami --pretty
|
|
183
|
+
agent-wechatbot whoami --account <account-id>
|
|
184
|
+
```
|
|
185
|
+
|
|
177
186
|
### Message Commands
|
|
178
187
|
|
|
179
188
|
```bash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-whatsapp
|
|
3
3
|
description: Interact with WhatsApp - send messages, read chats, manage conversations
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
allowed-tools: Bash(agent-whatsapp:*)
|
|
6
6
|
metadata:
|
|
7
7
|
openclaw:
|
|
@@ -16,7 +16,7 @@ metadata:
|
|
|
16
16
|
|
|
17
17
|
# Agent WhatsApp
|
|
18
18
|
|
|
19
|
-
A Baileys-backed WhatsApp CLI for AI agents. Links as a companion device via pairing code, so your phone stays connected. Each command connects on demand and disconnects when done.
|
|
19
|
+
A Baileys-backed WhatsApp CLI for AI agents. Links as a companion device via QR code or pairing code, so your phone stays connected. Each command connects on demand and disconnects when done.
|
|
20
20
|
|
|
21
21
|
Use one of these entrypoints:
|
|
22
22
|
- Global install: `agent-whatsapp ...`
|
|
@@ -27,6 +27,7 @@ Use one of these entrypoints:
|
|
|
27
27
|
Before diving in, a few things about WhatsApp's architecture:
|
|
28
28
|
|
|
29
29
|
- **JID** (Jabber ID) = WhatsApp's address format. Individual: `1234567890@s.whatsapp.net`. Group: `123456789-123345@g.us`. You can pass plain phone numbers and the CLI resolves them to JIDs automatically.
|
|
30
|
+
- **QR code auth** = links the CLI as a companion device by scanning a QR code displayed in the terminal or browser. Open WhatsApp > Linked Devices > Link a Device and scan the code.
|
|
30
31
|
- **Pairing code auth** = links the CLI as a companion device using a numeric code displayed in your terminal. Enter it in WhatsApp on your phone under Linked Devices.
|
|
31
32
|
- **Connect-on-demand** = the CLI opens a WebSocket connection for each command and disconnects afterward. There's no persistent background process.
|
|
32
33
|
- **Multi-account** = multiple WhatsApp accounts can be linked. Use `auth list` and `auth use` to switch between them.
|
|
@@ -34,7 +35,10 @@ Before diving in, a few things about WhatsApp's architecture:
|
|
|
34
35
|
## Quick Start
|
|
35
36
|
|
|
36
37
|
```bash
|
|
37
|
-
# Link as companion device
|
|
38
|
+
# Link as companion device via QR code (scan with your phone)
|
|
39
|
+
agent-whatsapp auth login --qr
|
|
40
|
+
|
|
41
|
+
# Or link via pairing code (enter the code on your phone)
|
|
38
42
|
agent-whatsapp auth login --phone +1234567890
|
|
39
43
|
|
|
40
44
|
# List chats
|
|
@@ -46,7 +50,10 @@ agent-whatsapp message send +1234567890 "Hello from agent-whatsapp"
|
|
|
46
50
|
|
|
47
51
|
## Authentication Flow
|
|
48
52
|
|
|
49
|
-
WhatsApp
|
|
53
|
+
WhatsApp supports two authentication methods. Both register the CLI as a companion (linked) device, so your phone session is never affected.
|
|
54
|
+
|
|
55
|
+
- **QR code** (`--qr`): A QR code is displayed in the terminal and opened in the browser. Scan it with WhatsApp on your phone. No phone number needed.
|
|
56
|
+
- **Pairing code** (`--phone`): A numeric code is displayed. Enter it in WhatsApp on your phone under Linked Devices > Link with phone number.
|
|
50
57
|
|
|
51
58
|
### Agent Behavior (MANDATORY)
|
|
52
59
|
|
|
@@ -60,28 +67,36 @@ agent-whatsapp auth list
|
|
|
60
67
|
|
|
61
68
|
If accounts exist, use `agent-whatsapp auth use <account-id>` and retry the original command.
|
|
62
69
|
|
|
63
|
-
**Step 2: If no accounts,
|
|
70
|
+
**Step 2: If no accounts, start QR login (preferred)**
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
agent-whatsapp auth login --qr
|
|
74
|
+
# -> QR code displayed in terminal + opened in browser
|
|
75
|
+
# -> {"next_action":"scan_qr","qr_url":"...","message":"Scan with WhatsApp on your phone"}
|
|
76
|
+
```
|
|
64
77
|
|
|
65
|
-
|
|
78
|
+
Tell the user to scan the QR code with WhatsApp: Settings > Linked Devices > Link a Device > scan the QR code.
|
|
66
79
|
|
|
67
|
-
**
|
|
80
|
+
**Alternative: Pairing code login**
|
|
81
|
+
|
|
82
|
+
If QR scanning is not possible (e.g. headless environment), ask for the phone number and use pairing code:
|
|
68
83
|
|
|
69
84
|
```bash
|
|
70
85
|
agent-whatsapp auth login --phone +1234567890
|
|
71
|
-
# -> {"
|
|
86
|
+
# -> {"pairing_code":"A1B2-C3D4","message":"Enter this code in WhatsApp > Linked Devices > Link with phone number"}
|
|
72
87
|
```
|
|
73
88
|
|
|
74
|
-
Tell the user the pairing code and ask them to enter it on their phone
|
|
89
|
+
Tell the user the pairing code and ask them to enter it on their phone.
|
|
75
90
|
|
|
76
|
-
**Step
|
|
91
|
+
**Step 3: Wait for confirmation**
|
|
77
92
|
|
|
78
|
-
The CLI
|
|
93
|
+
The CLI waits until the user confirms on their phone. Once confirmed:
|
|
79
94
|
|
|
80
95
|
```bash
|
|
81
96
|
# -> {"authenticated":true,...}
|
|
82
97
|
```
|
|
83
98
|
|
|
84
|
-
**Step
|
|
99
|
+
**Step 4: Retry the original command**
|
|
85
100
|
|
|
86
101
|
After successful auth, immediately execute whatever the user originally asked for.
|
|
87
102
|
|
|
@@ -169,6 +184,9 @@ If a memorized JID returns an error, remove it from `MEMORY.md`. Don't blindly t
|
|
|
169
184
|
### Auth Commands
|
|
170
185
|
|
|
171
186
|
```bash
|
|
187
|
+
# Link as companion device via QR code (no phone number needed)
|
|
188
|
+
agent-whatsapp auth login --qr
|
|
189
|
+
|
|
172
190
|
# Link as companion device via pairing code
|
|
173
191
|
agent-whatsapp auth login --phone +1234567890
|
|
174
192
|
|
|
@@ -187,6 +205,17 @@ agent-whatsapp auth logout
|
|
|
187
205
|
agent-whatsapp auth logout --account <id>
|
|
188
206
|
```
|
|
189
207
|
|
|
208
|
+
### Whoami Command
|
|
209
|
+
|
|
210
|
+
```bash
|
|
211
|
+
# Show current authenticated user
|
|
212
|
+
agent-whatsapp whoami
|
|
213
|
+
agent-whatsapp whoami --pretty
|
|
214
|
+
agent-whatsapp whoami --account <account-id>
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
Output includes the authenticated user's identity information.
|
|
218
|
+
|
|
190
219
|
### Chat Commands
|
|
191
220
|
|
|
192
221
|
```bash
|
|
@@ -319,13 +348,13 @@ All commands return consistent error format:
|
|
|
319
348
|
|
|
320
349
|
```json
|
|
321
350
|
{
|
|
322
|
-
"error": "No WhatsApp account linked. Run: agent-whatsapp auth login --
|
|
351
|
+
"error": "No WhatsApp account linked. Run: agent-whatsapp auth login --qr"
|
|
323
352
|
}
|
|
324
353
|
```
|
|
325
354
|
|
|
326
355
|
Common errors:
|
|
327
356
|
|
|
328
|
-
- `No WhatsApp account linked` - not authenticated. Run `auth login --phone <number>`.
|
|
357
|
+
- `No WhatsApp account linked` - not authenticated. Run `auth login --qr` or `auth login --phone <number>`.
|
|
329
358
|
- `Connection timeout` - WebSocket connection to WhatsApp failed. Retry the command.
|
|
330
359
|
- `Invalid JID` - malformed phone number or JID. Use international format with `+` prefix.
|
|
331
360
|
- `Not a group participant` - can't send to a group you're not a member of.
|
|
@@ -361,6 +390,14 @@ pnpm dlx --package agent-messenger agent-whatsapp chat list --pretty
|
|
|
361
390
|
|
|
362
391
|
**NEVER run `npx agent-whatsapp`, `bunx agent-whatsapp`, or `pnpm dlx agent-whatsapp`** without `--package agent-messenger`. It will fail or install a wrong package since `agent-whatsapp` is not the npm package name.
|
|
363
392
|
|
|
393
|
+
### QR code not scanning
|
|
394
|
+
|
|
395
|
+
1. Make sure WhatsApp is open on your phone
|
|
396
|
+
2. Go to Settings > Linked Devices > Link a Device
|
|
397
|
+
3. Point your phone camera at the QR code in the terminal or browser
|
|
398
|
+
4. If the QR code expires, run `auth login --qr` again for a fresh code
|
|
399
|
+
5. If QR scanning fails, try pairing code: `auth login --phone <number>`
|
|
400
|
+
|
|
364
401
|
### Pairing code not working
|
|
365
402
|
|
|
366
403
|
1. Make sure WhatsApp is open on your phone
|
|
@@ -389,5 +426,5 @@ WhatsApp may disconnect linked devices that are inactive for extended periods. I
|
|
|
389
426
|
agent-whatsapp auth status
|
|
390
427
|
|
|
391
428
|
# Re-link if needed
|
|
392
|
-
agent-whatsapp auth login --
|
|
429
|
+
agent-whatsapp auth login --qr
|
|
393
430
|
```
|