npm.io
0.3.1 • Published 2d agoCLI

@kamal0808/anytoany

Licence
MIT
Version
0.3.1
Deps
0
Size
23 kB
Vulns
0
Weekly
0

any — message people from inside Claude

Send a message to a friend and it lands inside their Claude Desktop — a banner pops, they click it, a Claude Code session opens that reads the message and helps them reply. AI-mediated messaging, human-in-the-loop.

you: any send @friend "hey"
        → hosted relay (Cloudflare Worker + D1)
        → friend's machine: watcher polls (cheap, 0 tokens idle)
        → 🔔 clickable macOS banner
        → click → claude://code/new opens a Claude Code session IN Claude Desktop
        → runs `any inbox` → reads → drafts → friend approves → any reply → back to you

Install (anyone, one command)

npx @kamal0808/anytoany@latest setup

Pick a unique @handle (+ optional display name). No token, no secrets. It registers you, installs a background banner watcher, and you're on the network. macOS + Node 18+ + Claude Desktop.

Use

any send @handle "text"    # message anyone by their handle
any inbox                  # your new messages
any read <id>              # open one
any reply <id> "text"      # reply
any whoami                 # your handle + status

How it works

  • Accounts: each person claims a unique @handle and gets their own key. from is server-verified (no spoofing); you can only read your own inbox. Registration is open (anyone can claim a handle and DM anyone by handle).
  • Relay: a Cloudflare Worker + D1 (worker/) — always-on, edge, durable. URL: https://anytoany-relay.kamalkhatwani69.workers.dev.
  • CLI: cli.js — published to npm as @kamal0808/anytoany (bin any).
  • Watcher → banner → Desktop: any poke (run by a launchd agent every ~15s) fires a terminal-notifier banner whose click opens claude://code/new?q=… — a tool-capable Claude Code session inside Claude Desktop (it can run any). Set up automatically by any setup. macOS-only.

Layout

Path What
cli.js the any CLI (published to npm)
worker/ the relay: Cloudflare Worker (worker.js) + D1 schema (schema.sql)
relay.js legacy standalone Node relay (superseded by the Worker)
SETUP-YASH.md copy-paste onboarding to send a friend
CLAUDE.md operator notes for maintaining/deploying this

Maintaining it

  • Deploy the relay: cd worker && npx wrangler deploy (needs wrangler login).
  • Publish the CLI: bump version in package.json, then npm publish --access public (needs npm login + 2FA).
  • See CLAUDE.md for the full operator playbook and known rough edges.

Not built yet

  • One persistent Claude thread for all messaging (deep links only open new sessions; would need the MCP-connector + fixed-chat approach).
  • A dedicated ~/anytoany folder per install (groups sessions, path-independent).
  • Spam/abuse controls (blocking, invite-only, rate limits) — registration is open.

Keywords