aitextaroo 0.1.2__tar.gz → 0.2.1__tar.gz

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.
Files changed (38) hide show
  1. aitextaroo-0.2.1/PKG-INFO +229 -0
  2. aitextaroo-0.2.1/README.md +196 -0
  3. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/__init__.py +1 -1
  4. aitextaroo-0.2.1/aitextaroo/agent_cli.py +268 -0
  5. aitextaroo-0.2.1/aitextaroo/agents.py +381 -0
  6. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/bridge.py +3 -1
  7. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/cli.py +28 -6
  8. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/client.py +238 -18
  9. aitextaroo-0.2.1/aitextaroo/credentials.py +76 -0
  10. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/setup.py +65 -14
  11. aitextaroo-0.2.1/aitextaroo.egg-info/PKG-INFO +229 -0
  12. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo.egg-info/SOURCES.txt +6 -1
  13. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo.egg-info/entry_points.txt +1 -0
  14. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/pyproject.toml +3 -2
  15. aitextaroo-0.2.1/tests/test_agent_cli.py +276 -0
  16. aitextaroo-0.2.1/tests/test_agents.py +288 -0
  17. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_bridge.py +40 -0
  18. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_client.py +55 -1
  19. aitextaroo-0.2.1/tests/test_client_replies.py +199 -0
  20. aitextaroo-0.2.1/tests/test_setup.py +66 -0
  21. aitextaroo-0.1.2/PKG-INFO +0 -230
  22. aitextaroo-0.1.2/README.md +0 -197
  23. aitextaroo-0.1.2/aitextaroo/agents.py +0 -235
  24. aitextaroo-0.1.2/aitextaroo.egg-info/PKG-INFO +0 -230
  25. aitextaroo-0.1.2/tests/test_agents.py +0 -107
  26. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/LICENSE +0 -0
  27. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/commands.py +0 -0
  28. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/conversation.py +0 -0
  29. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/formatting.py +0 -0
  30. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo/models.py +0 -0
  31. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo.egg-info/dependency_links.txt +0 -0
  32. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo.egg-info/requires.txt +0 -0
  33. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/aitextaroo.egg-info/top_level.txt +0 -0
  34. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/setup.cfg +0 -0
  35. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_commands.py +0 -0
  36. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_conversation.py +0 -0
  37. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_formatting.py +0 -0
  38. {aitextaroo-0.1.2 → aitextaroo-0.2.1}/tests/test_models.py +0 -0
@@ -0,0 +1,229 @@
1
+ Metadata-Version: 2.4
2
+ Name: aitextaroo
3
+ Version: 0.2.1
4
+ Summary: Client library for AI Text-a-roo — give any AI agent a phone number
5
+ Author-email: AI Text-a-roo <hello@aitextaroo.com>
6
+ License: MIT
7
+ Project-URL: Homepage, https://aitextaroo.com
8
+ Project-URL: Documentation, https://github.com/rwfresh/aitextaroo-clients
9
+ Project-URL: Repository, https://github.com/rwfresh/aitextaroo-clients
10
+ Project-URL: Issues, https://github.com/rwfresh/aitextaroo-clients/issues
11
+ Keywords: sms,ai,agent,chatbot,text-messaging,mcp,agent-skills,claude,chatgpt,codex,openclaw,hermes
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: License :: OSI Approved :: MIT License
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Programming Language :: Python :: 3.13
20
+ Classifier: Topic :: Communications :: Chat
21
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
22
+ Requires-Python: >=3.10
23
+ Description-Content-Type: text/markdown
24
+ License-File: LICENSE
25
+ Requires-Dist: httpx>=0.27.0
26
+ Provides-Extra: bridge
27
+ Requires-Dist: pyyaml>=6.0; extra == "bridge"
28
+ Provides-Extra: dev
29
+ Requires-Dist: pytest>=8.0; extra == "dev"
30
+ Requires-Dist: pytest-asyncio>=0.23; extra == "dev"
31
+ Requires-Dist: ruff>=0.4.0; extra == "dev"
32
+ Dynamic: license-file
33
+
34
+ # AI Text-a-roo
35
+
36
+ Give any AI agent a phone number, in about two minutes.
37
+
38
+ [AI Text-a-roo](https://aitextaroo.com) is an SMS gateway for AI agents. You verify your
39
+ phone once; then you can text your agent from any phone (no app), and it can text you back,
40
+ or first, when something needs you. This repo has everything an agent needs to use it: an
41
+ [Agent Skill](skills/aitextaroo/SKILL.md), plugin manifests for Claude, Codex, Cursor and
42
+ Gemini CLI, the `aitextaroo` command, a Python SDK, and an SMS bridge for CLI agents.
43
+
44
+ ## Install in your agent
45
+
46
+ | Agent | One step |
47
+ |---|---|
48
+ | Claude Code | `claude plugin install aitextaroo --marketplace rwfresh/aitextaroo-clients`, or in a session `/plugin marketplace add rwfresh/aitextaroo-clients` then `/plugin install aitextaroo@aitextaroo` |
49
+ | Claude, Claude Desktop, Claude Duet | Customize → Plugins → Add marketplace → `rwfresh/aitextaroo-clients`, or Customize → Connectors → Add custom connector → `https://api.aitextaroo.com/mcp` |
50
+ | ChatGPT and Dots | Plugins → + → Add custom MCP server → `https://api.aitextaroo.com/mcp` → OAuth |
51
+ | Codex | `codex plugin marketplace add rwfresh/aitextaroo-clients`, then `codex plugin add aitextaroo@aitextaroo` |
52
+ | Gemini CLI | `gemini extensions install https://github.com/rwfresh/aitextaroo-clients` |
53
+ | Grok Bot | Say: "Add a custom MCP server called AI Text-a-roo at https://api.aitextaroo.com/mcp" |
54
+ | Cursor | Add the MCP server to `~/.cursor/mcp.json` (run `aitextaroo connect cursor`) |
55
+ | Any skills-aware agent | `npx skills add rwfresh/aitextaroo-clients` |
56
+ | Claude Code, Codex, Hermes, OpenClaw, Grok, Gemini, Antigravity, Goose, Cursor (answer texts from your phone) | `pipx install aitextaroo`, then `aitextaroo-bridge` |
57
+
58
+ The plugins bundle the skill and the remote MCP server. They sign in with OAuth: you enter
59
+ your phone number and the 6-digit code we text you, so there's no API key to copy. Setup
60
+ guides for each agent: <https://aitextaroo.com/agents>.
61
+
62
+ Or just tell your agent:
63
+
64
+ > Set me up with AI Text-a-roo so I can text you. Instructions: aitextaroo.com/llms.txt
65
+
66
+ ## Quick start from a terminal
67
+
68
+ ```bash
69
+ pipx install aitextaroo # or: pip install --user aitextaroo
70
+ aitextaroo-setup --phone +12125551234 # texts you a 6-digit code
71
+ aitextaroo-setup --phone +12125551234 --code 123456 --save # saves the key (owner-only)
72
+ aitextaroo send "Hello from my agent!"
73
+ ```
74
+
75
+ `--save` stores the API key in `~/.aitextaroo/credentials.json` with owner-only permissions.
76
+ `aitextaroo` and `aitextaroo-bridge` find it there, or in `AITEXTAROO_API_KEY`, or in `--api-key`.
77
+
78
+ ## The `aitextaroo` command
79
+
80
+ Made for agents with a shell. Output is JSON; errors go to stderr with exit code 1.
81
+ `aitextaroo verify-pin` exits 2 when the PIN is wrong, so `aitextaroo verify-pin <<< 4821 && …`
82
+ only continues on a match. `verify-pin` and `set-pin` read the PIN from stdin when it isn't
83
+ an argument. At a terminal they ask for it without echoing, which keeps it out of your shell
84
+ history (a command with the PIN written in it, like the `<<<` form, can still be saved there).
85
+
86
+ ```bash
87
+ aitextaroo send "Build finished: 318 tests passing."
88
+ aitextaroo ask "Deploy to production? Reply YES or NO" --timeout 120 # text, then wait for the answer
89
+ aitextaroo wait --timeout 60 # wait for the next text
90
+ aitextaroo recent # texts from the last 5 minutes
91
+ aitextaroo relay --to +12125550100 --name Mom "Happy birthday!" # Pro: text a contact
92
+ aitextaroo verify-pin # check a PIN (hidden prompt)
93
+ aitextaroo set-pin # set the user's PIN (4-8 digits)
94
+ aitextaroo account
95
+ aitextaroo upgrade # Stripe link for Pro
96
+ aitextaroo webhook set https://example.com/hook --auth-header "Bearer <token>"
97
+ aitextaroo connect [claude-code|codex|gemini|cursor|muse-code|claude|chatgpt|grok]
98
+ ```
99
+
100
+ ## SMS bridge
101
+
102
+ The bridge holds one outbound connection to AI Text-a-roo. Each text you send becomes a
103
+ prompt for a CLI agent on your machine, and its answer is texted back. No webhook, no public
104
+ IP: it works behind NAT, firewalls and VPNs.
105
+
106
+ ```bash
107
+ aitextaroo-bridge # auto-detects an installed agent
108
+ aitextaroo-bridge --agent codex
109
+ aitextaroo-bridge --agent-command "pnpm --silent --dir ~/nanoclaw run chat" # any other CLI
110
+ ```
111
+
112
+ | `--agent` | Runs |
113
+ |---|---|
114
+ | `claude` | `claude -p "<prompt>"` |
115
+ | `codex` | `codex exec --skip-git-repo-check --color never -o <file> "<prompt>"` |
116
+ | `hermes` | `hermes -z "<prompt>"` |
117
+ | `openclaw` | `openclaw agent exec "<prompt>"` |
118
+ | `grok` | `grok --no-auto-update -p "<prompt>"` |
119
+ | `gemini` | `gemini -p "<prompt>"` |
120
+ | `antigravity` | `agy -p "<prompt>"` |
121
+ | `goose` | `goose run -q --no-session -t "<prompt>"` |
122
+ | `cursor` | `cursor-agent -p --trust "<prompt>"`, or `agent` if that's all there is (explicit only: Grok Build also installs an `agent` binary, and the bridge refuses it) |
123
+
124
+ Auto-detect tries them in this order. `--agent-command` runs any CLI that takes the prompt
125
+ as its last argument and prints the reply.
126
+
127
+ Conversation history is saved locally in `~/.aitextaroo/sessions/` and survives restarts.
128
+ Text `/help`, `/new` (fresh conversation) or `/status`. Use `--no-persist` for memory-only
129
+ history. Responses are stripped of markdown for SMS.
130
+
131
+ ```text
132
+ aitextaroo-bridge [OPTIONS]
133
+ --api-key KEY API key (default: AITEXTAROO_API_KEY or the saved credentials)
134
+ --agent NAME auto, claude, codex, hermes, openclaw, grok, gemini, antigravity, goose, cursor
135
+ --agent-command CMD Any other CLI agent (overrides --agent)
136
+ --sessions-dir PATH Session files (default ~/.aitextaroo/sessions/)
137
+ --no-persist Keep history in memory only
138
+ --base-url URL Custom API URL
139
+ -v, --verbose Debug logging
140
+ ```
141
+
142
+ ## Python SDK
143
+
144
+ ```python
145
+ import asyncio
146
+ from aitextaroo import TextarooClient
147
+
148
+ async def main():
149
+ client = TextarooClient(api_key="YOUR_KEY")
150
+ await client.send("All tests pass. Open a PR? Reply YES or NO.")
151
+ reply = await client.wait_for_reply(timeout_seconds=90)
152
+ print(reply.text if reply else "No answer yet")
153
+ await client.close()
154
+
155
+ asyncio.run(main())
156
+ ```
157
+
158
+ | Method | What it does |
159
+ |---|---|
160
+ | `send(text)` | Text the user. Returns the message ID. |
161
+ | `wait_for_reply(timeout_seconds=60)` | Wait up to 120 s for the user's next text (or one that arrived since your last send). Returns an `InboundMessage` or `None`. |
162
+ | `recent_messages(after_id=None)` | Texts from the last five minutes. |
163
+ | `listen()` | Async iterator over inbound texts via SSE, with automatic reconnect and replay. |
164
+ | `text_contact(to, text, recipient_name=None)` | Pro: text someone else; their replies go to the user's phone. |
165
+ | `verify_pin(pin)` | Check a PIN the user texted: `{"verified": bool, "attempts_remaining": int \| None}`. |
166
+ | `set_pin(pin)` / `remove_pin()` | Set, change or remove the user's security PIN (4–8 digits). |
167
+ | `set_webhook(url, auth_header=None)` / `remove_webhook()` | Forward inbound texts to a URL (signed with `X-Signature`). |
168
+ | `account()` | Plan, assigned number, usage and daily limit. |
169
+ | `upgrade_link()` | Stripe checkout link for Pro. |
170
+ | `TextarooClient.request_verification(phone)` / `confirm_verification(phone, code)` | Sign-up, no key needed. |
171
+
172
+ `InboundMessage` has `id`, `text`, `received_at`, `channel` (`"sms"`), `trust_level` and
173
+ `has_pin`. See [`examples/`](examples/) for an echo bot, a listener and an ask-and-wait flow.
174
+
175
+ ## MCP server
176
+
177
+ `https://api.aitextaroo.com/mcp` (streamable HTTP). Tools: `send_text`, `wait_for_reply`,
178
+ `get_recent_messages`, `text_contact`, `verify_pin`, `get_account`, `get_upgrade_link`.
179
+ Clients sign in with OAuth, or send `Authorization: Bearer <API key>`:
180
+
181
+ ```bash
182
+ claude mcp add --transport http --scope user aitextaroo https://api.aitextaroo.com/mcp \
183
+ --header "Authorization: Bearer $AITEXTAROO_API_KEY"
184
+ ```
185
+
186
+ Run `aitextaroo connect` for every client's exact setup. Reference: <https://aitextaroo.com/docs/mcp>.
187
+
188
+ ## Plans
189
+
190
+ | | Free ($0) | Pro ($5/mo, 14-day free trial) |
191
+ |---|---|---|
192
+ | Messages per day | 10 | 200 |
193
+ | Two-way texting, MCP, skill, SDK, bridge | ✓ | ✓ |
194
+ | Security PIN | ✓ | ✓ |
195
+ | Text your contacts, with replies forwarded | | ✓ |
196
+
197
+ Up to 5 texts per minute. Limits reset at midnight UTC.
198
+
199
+ ## Privacy and security
200
+
201
+ - Message content is never written to AI Text-a-roo's database. Texts are held in memory
202
+ for at most five minutes so an agent can catch up after a dropped connection.
203
+ - Phone numbers are encrypted at rest; PINs are stored as bcrypt hashes.
204
+ - The bridge's history and the saved credentials live only on your machine.
205
+ - SMS isn't end-to-end encrypted, and sender IDs can be spoofed. The bridge tells every agent
206
+ to ask for your PIN before anything sensitive, because some CLIs (for example `hermes -z`)
207
+ auto-approve their own tool calls in one-shot mode. Run the bridge with an agent whose
208
+ permissions you're comfortable exposing to your phone number.
209
+
210
+ Details: <https://aitextaroo.com/security>.
211
+
212
+ ## Environment variables
213
+
214
+ | Variable | Description |
215
+ |---|---|
216
+ | `AITEXTAROO_API_KEY` | API key (alternative to `--api-key` and the saved credentials) |
217
+ | `AITEXTAROO_BASE_URL` | Custom API URL |
218
+
219
+ ## Releasing
220
+
221
+ Bump the version in `pyproject.toml`, `aitextaroo/__init__.py`, `plugin.json`,
222
+ `.claude-plugin/plugin.json` and `gemini-extension.json`, merge to `main`, then push a
223
+ matching tag: `git tag v0.2.2 && git push origin v0.2.2`. The
224
+ [Release workflow](.github/workflows/release.yml) tests, builds and publishes to PyPI with
225
+ Trusted Publishing.
226
+
227
+ ## License
228
+
229
+ MIT
@@ -0,0 +1,196 @@
1
+ # AI Text-a-roo
2
+
3
+ Give any AI agent a phone number, in about two minutes.
4
+
5
+ [AI Text-a-roo](https://aitextaroo.com) is an SMS gateway for AI agents. You verify your
6
+ phone once; then you can text your agent from any phone (no app), and it can text you back,
7
+ or first, when something needs you. This repo has everything an agent needs to use it: an
8
+ [Agent Skill](skills/aitextaroo/SKILL.md), plugin manifests for Claude, Codex, Cursor and
9
+ Gemini CLI, the `aitextaroo` command, a Python SDK, and an SMS bridge for CLI agents.
10
+
11
+ ## Install in your agent
12
+
13
+ | Agent | One step |
14
+ |---|---|
15
+ | Claude Code | `claude plugin install aitextaroo --marketplace rwfresh/aitextaroo-clients`, or in a session `/plugin marketplace add rwfresh/aitextaroo-clients` then `/plugin install aitextaroo@aitextaroo` |
16
+ | Claude, Claude Desktop, Claude Duet | Customize → Plugins → Add marketplace → `rwfresh/aitextaroo-clients`, or Customize → Connectors → Add custom connector → `https://api.aitextaroo.com/mcp` |
17
+ | ChatGPT and Dots | Plugins → + → Add custom MCP server → `https://api.aitextaroo.com/mcp` → OAuth |
18
+ | Codex | `codex plugin marketplace add rwfresh/aitextaroo-clients`, then `codex plugin add aitextaroo@aitextaroo` |
19
+ | Gemini CLI | `gemini extensions install https://github.com/rwfresh/aitextaroo-clients` |
20
+ | Grok Bot | Say: "Add a custom MCP server called AI Text-a-roo at https://api.aitextaroo.com/mcp" |
21
+ | Cursor | Add the MCP server to `~/.cursor/mcp.json` (run `aitextaroo connect cursor`) |
22
+ | Any skills-aware agent | `npx skills add rwfresh/aitextaroo-clients` |
23
+ | Claude Code, Codex, Hermes, OpenClaw, Grok, Gemini, Antigravity, Goose, Cursor (answer texts from your phone) | `pipx install aitextaroo`, then `aitextaroo-bridge` |
24
+
25
+ The plugins bundle the skill and the remote MCP server. They sign in with OAuth: you enter
26
+ your phone number and the 6-digit code we text you, so there's no API key to copy. Setup
27
+ guides for each agent: <https://aitextaroo.com/agents>.
28
+
29
+ Or just tell your agent:
30
+
31
+ > Set me up with AI Text-a-roo so I can text you. Instructions: aitextaroo.com/llms.txt
32
+
33
+ ## Quick start from a terminal
34
+
35
+ ```bash
36
+ pipx install aitextaroo # or: pip install --user aitextaroo
37
+ aitextaroo-setup --phone +12125551234 # texts you a 6-digit code
38
+ aitextaroo-setup --phone +12125551234 --code 123456 --save # saves the key (owner-only)
39
+ aitextaroo send "Hello from my agent!"
40
+ ```
41
+
42
+ `--save` stores the API key in `~/.aitextaroo/credentials.json` with owner-only permissions.
43
+ `aitextaroo` and `aitextaroo-bridge` find it there, or in `AITEXTAROO_API_KEY`, or in `--api-key`.
44
+
45
+ ## The `aitextaroo` command
46
+
47
+ Made for agents with a shell. Output is JSON; errors go to stderr with exit code 1.
48
+ `aitextaroo verify-pin` exits 2 when the PIN is wrong, so `aitextaroo verify-pin <<< 4821 && …`
49
+ only continues on a match. `verify-pin` and `set-pin` read the PIN from stdin when it isn't
50
+ an argument. At a terminal they ask for it without echoing, which keeps it out of your shell
51
+ history (a command with the PIN written in it, like the `<<<` form, can still be saved there).
52
+
53
+ ```bash
54
+ aitextaroo send "Build finished: 318 tests passing."
55
+ aitextaroo ask "Deploy to production? Reply YES or NO" --timeout 120 # text, then wait for the answer
56
+ aitextaroo wait --timeout 60 # wait for the next text
57
+ aitextaroo recent # texts from the last 5 minutes
58
+ aitextaroo relay --to +12125550100 --name Mom "Happy birthday!" # Pro: text a contact
59
+ aitextaroo verify-pin # check a PIN (hidden prompt)
60
+ aitextaroo set-pin # set the user's PIN (4-8 digits)
61
+ aitextaroo account
62
+ aitextaroo upgrade # Stripe link for Pro
63
+ aitextaroo webhook set https://example.com/hook --auth-header "Bearer <token>"
64
+ aitextaroo connect [claude-code|codex|gemini|cursor|muse-code|claude|chatgpt|grok]
65
+ ```
66
+
67
+ ## SMS bridge
68
+
69
+ The bridge holds one outbound connection to AI Text-a-roo. Each text you send becomes a
70
+ prompt for a CLI agent on your machine, and its answer is texted back. No webhook, no public
71
+ IP: it works behind NAT, firewalls and VPNs.
72
+
73
+ ```bash
74
+ aitextaroo-bridge # auto-detects an installed agent
75
+ aitextaroo-bridge --agent codex
76
+ aitextaroo-bridge --agent-command "pnpm --silent --dir ~/nanoclaw run chat" # any other CLI
77
+ ```
78
+
79
+ | `--agent` | Runs |
80
+ |---|---|
81
+ | `claude` | `claude -p "<prompt>"` |
82
+ | `codex` | `codex exec --skip-git-repo-check --color never -o <file> "<prompt>"` |
83
+ | `hermes` | `hermes -z "<prompt>"` |
84
+ | `openclaw` | `openclaw agent exec "<prompt>"` |
85
+ | `grok` | `grok --no-auto-update -p "<prompt>"` |
86
+ | `gemini` | `gemini -p "<prompt>"` |
87
+ | `antigravity` | `agy -p "<prompt>"` |
88
+ | `goose` | `goose run -q --no-session -t "<prompt>"` |
89
+ | `cursor` | `cursor-agent -p --trust "<prompt>"`, or `agent` if that's all there is (explicit only: Grok Build also installs an `agent` binary, and the bridge refuses it) |
90
+
91
+ Auto-detect tries them in this order. `--agent-command` runs any CLI that takes the prompt
92
+ as its last argument and prints the reply.
93
+
94
+ Conversation history is saved locally in `~/.aitextaroo/sessions/` and survives restarts.
95
+ Text `/help`, `/new` (fresh conversation) or `/status`. Use `--no-persist` for memory-only
96
+ history. Responses are stripped of markdown for SMS.
97
+
98
+ ```text
99
+ aitextaroo-bridge [OPTIONS]
100
+ --api-key KEY API key (default: AITEXTAROO_API_KEY or the saved credentials)
101
+ --agent NAME auto, claude, codex, hermes, openclaw, grok, gemini, antigravity, goose, cursor
102
+ --agent-command CMD Any other CLI agent (overrides --agent)
103
+ --sessions-dir PATH Session files (default ~/.aitextaroo/sessions/)
104
+ --no-persist Keep history in memory only
105
+ --base-url URL Custom API URL
106
+ -v, --verbose Debug logging
107
+ ```
108
+
109
+ ## Python SDK
110
+
111
+ ```python
112
+ import asyncio
113
+ from aitextaroo import TextarooClient
114
+
115
+ async def main():
116
+ client = TextarooClient(api_key="YOUR_KEY")
117
+ await client.send("All tests pass. Open a PR? Reply YES or NO.")
118
+ reply = await client.wait_for_reply(timeout_seconds=90)
119
+ print(reply.text if reply else "No answer yet")
120
+ await client.close()
121
+
122
+ asyncio.run(main())
123
+ ```
124
+
125
+ | Method | What it does |
126
+ |---|---|
127
+ | `send(text)` | Text the user. Returns the message ID. |
128
+ | `wait_for_reply(timeout_seconds=60)` | Wait up to 120 s for the user's next text (or one that arrived since your last send). Returns an `InboundMessage` or `None`. |
129
+ | `recent_messages(after_id=None)` | Texts from the last five minutes. |
130
+ | `listen()` | Async iterator over inbound texts via SSE, with automatic reconnect and replay. |
131
+ | `text_contact(to, text, recipient_name=None)` | Pro: text someone else; their replies go to the user's phone. |
132
+ | `verify_pin(pin)` | Check a PIN the user texted: `{"verified": bool, "attempts_remaining": int \| None}`. |
133
+ | `set_pin(pin)` / `remove_pin()` | Set, change or remove the user's security PIN (4–8 digits). |
134
+ | `set_webhook(url, auth_header=None)` / `remove_webhook()` | Forward inbound texts to a URL (signed with `X-Signature`). |
135
+ | `account()` | Plan, assigned number, usage and daily limit. |
136
+ | `upgrade_link()` | Stripe checkout link for Pro. |
137
+ | `TextarooClient.request_verification(phone)` / `confirm_verification(phone, code)` | Sign-up, no key needed. |
138
+
139
+ `InboundMessage` has `id`, `text`, `received_at`, `channel` (`"sms"`), `trust_level` and
140
+ `has_pin`. See [`examples/`](examples/) for an echo bot, a listener and an ask-and-wait flow.
141
+
142
+ ## MCP server
143
+
144
+ `https://api.aitextaroo.com/mcp` (streamable HTTP). Tools: `send_text`, `wait_for_reply`,
145
+ `get_recent_messages`, `text_contact`, `verify_pin`, `get_account`, `get_upgrade_link`.
146
+ Clients sign in with OAuth, or send `Authorization: Bearer <API key>`:
147
+
148
+ ```bash
149
+ claude mcp add --transport http --scope user aitextaroo https://api.aitextaroo.com/mcp \
150
+ --header "Authorization: Bearer $AITEXTAROO_API_KEY"
151
+ ```
152
+
153
+ Run `aitextaroo connect` for every client's exact setup. Reference: <https://aitextaroo.com/docs/mcp>.
154
+
155
+ ## Plans
156
+
157
+ | | Free ($0) | Pro ($5/mo, 14-day free trial) |
158
+ |---|---|---|
159
+ | Messages per day | 10 | 200 |
160
+ | Two-way texting, MCP, skill, SDK, bridge | ✓ | ✓ |
161
+ | Security PIN | ✓ | ✓ |
162
+ | Text your contacts, with replies forwarded | | ✓ |
163
+
164
+ Up to 5 texts per minute. Limits reset at midnight UTC.
165
+
166
+ ## Privacy and security
167
+
168
+ - Message content is never written to AI Text-a-roo's database. Texts are held in memory
169
+ for at most five minutes so an agent can catch up after a dropped connection.
170
+ - Phone numbers are encrypted at rest; PINs are stored as bcrypt hashes.
171
+ - The bridge's history and the saved credentials live only on your machine.
172
+ - SMS isn't end-to-end encrypted, and sender IDs can be spoofed. The bridge tells every agent
173
+ to ask for your PIN before anything sensitive, because some CLIs (for example `hermes -z`)
174
+ auto-approve their own tool calls in one-shot mode. Run the bridge with an agent whose
175
+ permissions you're comfortable exposing to your phone number.
176
+
177
+ Details: <https://aitextaroo.com/security>.
178
+
179
+ ## Environment variables
180
+
181
+ | Variable | Description |
182
+ |---|---|
183
+ | `AITEXTAROO_API_KEY` | API key (alternative to `--api-key` and the saved credentials) |
184
+ | `AITEXTAROO_BASE_URL` | Custom API URL |
185
+
186
+ ## Releasing
187
+
188
+ Bump the version in `pyproject.toml`, `aitextaroo/__init__.py`, `plugin.json`,
189
+ `.claude-plugin/plugin.json` and `gemini-extension.json`, merge to `main`, then push a
190
+ matching tag: `git tag v0.2.2 && git push origin v0.2.2`. The
191
+ [Release workflow](.github/workflows/release.yml) tests, builds and publishes to PyPI with
192
+ Trusted Publishing.
193
+
194
+ ## License
195
+
196
+ MIT
@@ -14,5 +14,5 @@ Example:
14
14
  from aitextaroo.client import TextarooClient
15
15
  from aitextaroo.models import InboundMessage, StreamEvent
16
16
 
17
- __version__ = "0.1.2"
17
+ __version__ = "0.2.1"
18
18
  __all__ = ["TextarooClient", "InboundMessage", "StreamEvent"]