{"_id":"@aakash-a-dev/atich","name":"@aakash-a-dev/atich","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@aakash-a-dev/atich","version":"1.0.0","description":"A JSON event-stream terminal client for WhatsApp — reads like a webhook debug tail, not a chat app.","main":"dist/index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1","build":"tsc","dev":"tsx src/index.ts","start":"node dist/index.js","typecheck":"tsc --noEmit","prepublishOnly":"npm run build"},"keywords":["whatsapp","cli","terminal","baileys","chat"],"author":{"name":"Aakash Amod Rajput"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/aakash-a-dev/atich.git"},"bugs":{"url":"https://github.com/aakash-a-dev/atich/issues"},"homepage":"https://github.com/aakash-a-dev/atich#readme","bin":{"atich":"dist/index.js"},"dependencies":{"@hapi/boom":"^9.1.4","@whiskeysockets/baileys":"^6.7.23","chalk":"^5.6.2","figlet":"^1.11.3","pino":"^10.3.1","qrcode-terminal":"^0.12.0"},"devDependencies":{"@types/node":"^26.1.1","@types/qrcode-terminal":"^0.12.2","tsx":"^4.23.1","typescript":"^7.0.2"},"type":"module","_id":"@aakash-a-dev/atich@1.0.0","gitHead":"0c870a77b8ce7b4f61e0d89dc4a2633f385bb2d9","_nodeVersion":"22.15.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-EbxjB1gDSGMasXlHHf8Z/wrRZZh0GJM20CHO/ZH5/YCF7QU2F/QJQA8XayyLhYzKXtIySpOil7sxkcZj18OgXQ==","shasum":"4c9c95147ed7414fb52c4f217f164bc72d90aff5","tarball":"https://registry.npmjs.org/@aakash-a-dev/atich/-/atich-1.0.0.tgz","fileCount":12,"unpackedSize":22746,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEMCIFRNwFQ2yoxBzILbZQU6X0LR+ncRAvskiDulT8+b2IKCAh94LmoClYHBUGLuVdBDG3mk5dLEiDEL9JgBDtZFvcJL"}]},"_npmUser":{"name":"aakash-a-dev","email":"aakashamodrajput@gmail.com"},"directories":{},"maintainers":[{"name":"aakash-a-dev","email":"aakashamodrajput@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/atich_1.0.0_1784831062712_0.7176663729306234"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-23T18:24:22.582Z","1.0.0":"2026-07-23T18:24:22.880Z","modified":"2026-07-23T18:24:23.060Z"},"maintainers":[{"name":"aakash-a-dev","email":"aakashamodrajput@gmail.com"}],"description":"A JSON event-stream terminal client for WhatsApp — reads like a webhook debug tail, not a chat app.","homepage":"https://github.com/aakash-a-dev/atich#readme","keywords":["whatsapp","cli","terminal","baileys","chat"],"repository":{"type":"git","url":"git+https://github.com/aakash-a-dev/atich.git"},"author":{"name":"Aakash Amod Rajput"},"bugs":{"url":"https://github.com/aakash-a-dev/atich/issues"},"license":"MIT","readme":"# Atich\r\n\r\nA terminal WhatsApp client that renders every message as a structured JSON\r\nevent, like tailing a webhook/queue consumer log — not a chat UI.\r\n\r\n```\r\n{\"ts\":\"14:22:03.912\",\"event\":\"msg\",\"from\":\"john.d\",\"body\":\"hey are you free later\"}\r\n{\"ts\":\"14:22:41.204\",\"event\":\"sent\",\"to\":\"john.d\",\"body\":\"yeah give me 10\"}\r\n```\r\n\r\n## Install\r\n\r\nAs a global CLI from npm:\r\n\r\n```\r\nnpm install -g atich\r\natich\r\n```\r\n\r\nOr without installing, via `npx`:\r\n\r\n```\r\nnpx atich\r\n```\r\n\r\nOr from source:\r\n\r\n```\r\ngit clone https://github.com/aakash-a-dev/atich.git\r\ncd atich\r\nnpm install\r\nnpm run build\r\nnpm start\r\n```\r\n\r\nOn first run it prints a QR code — scan it from WhatsApp on your phone under\r\n**Linked devices**. The session is saved to `~/.config/atich/session` so you\r\nwon't need to re-scan on later runs.\r\n\r\n## Usage\r\n\r\nOnce connected, the process streams incoming/outgoing messages, one line per\r\nevent. By default this shows raw JSON plus internal diagnostics\r\n(`/debug` toggles a clean `Name: message` view instead). Type into the same\r\nterminal to send:\r\n\r\n- `/list` — show every known contact; ↑/↓ to move, **Enter** to open, **Esc**\r\n  to cancel. Populated by actively pulling your WhatsApp app-state\r\n  (`sock.resyncAppState`) right after connecting, plus anyone who messages you\r\n  or you message. Only shows contacts saved in your phone's address book that\r\n  are also on WhatsApp, not arbitrary WhatsApp users.\r\n- `/open <name or number fragment>` — open a contact directly; if more than\r\n  one matches, the same ↑/↓ picker as `/list` opens to disambiguate.\r\n- `/search <name or number fragment>` — same as `/open`, but always opens the\r\n  picker even for a single match.\r\n- `/close` (alias `/leave`) — deactivate the current chat without quitting.\r\n- `/debug` — toggle between the raw event/diagnostic view and a clean,\r\n  human-readable chat view. Everything is logged to\r\n  `~/.config/atich/atich.log` regardless of this setting.\r\n- `/logout` — unlink this device from WhatsApp and clear the local session.\r\n- `/login` — reconnect and re-pair (prompts a fresh QR code) after `/logout`.\r\n- anything else — sent as a message to the active chat\r\n- `/quit` (alias `/exit`) — exit\r\n\r\n## Testing\r\n\r\n**Run this from your own laptop's regular network, not a cloud VM/CI/sandbox\r\nenvironment.** WhatsApp's servers reject WebSocket handshakes from known\r\ndatacenter/hosting-provider IP ranges as a bot-mitigation measure — this\r\nshows up as an immediate `\"connection closed (Connection Failure)\"` before\r\nthe QR code ever appears, and no code change fixes it. It's an IP-reputation\r\ncheck on WhatsApp's side, not a bug in this client.\r\n\r\nTo verify end to end:\r\n\r\n1. `npm start` on your laptop → a QR code should print within a few seconds.\r\n2. Scan it from WhatsApp → **Linked devices** on your phone.\r\n3. Confirm `{\"event\":\"status\",\"body\":\"connected\"}` appears.\r\n4. Send yourself (or have someone send you) a WhatsApp message — confirm a\r\n   `{\"event\":\"msg\", ...}` line appears.\r\n5. Run `/list`, then `/open <name>`, then type a message — confirm it arrives\r\n   on the recipient's phone and a `{\"event\":\"sent\", ...}` line prints locally.\r\n\r\n## Notes\r\n\r\n- Contacts arrive via an actively-triggered app-state resync\r\n  (`sock.resyncAppState`), not by passively waiting for WhatsApp to send a\r\n  history-sync notification — the latter often never arrives on a reconnect\r\n  to an already-linked session, which is why contacts could come up empty\r\n  even minutes after connecting in earlier versions of this client.\r\n- Uses [`@whiskeysockets/baileys`](https://github.com/WhiskeySockets/Baileys),\r\n  an unofficial WhatsApp Web protocol implementation. This is not an official\r\n  WhatsApp client — accounts using unofficial clients can occasionally be\r\n  flagged or temporarily restricted by WhatsApp.\r\n- Pinned to the `6.7.23` \"legacy\" line (CommonJS-era predecessor patched for\r\n  the message-spoofing advisory GHSA-qvv5-jq5g-4cgg). `7.x` is the actively\r\n  developed line if you want to track upstream more closely later.\r\n- No message history is persisted to disk beyond the current process's\r\n  in-memory contact list — restarting loses the `/list` cache (not the\r\n  WhatsApp session itself).\r\n","readmeFilename":"README.md","_rev":"1-a47fd31b6b7b2f4fea67793134c89f29"}