autotouch-cli 0.2.8__tar.gz → 0.2.10__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 (65) hide show
  1. autotouch_cli-0.2.10/PKG-INFO +319 -0
  2. autotouch_cli-0.2.10/autotouch_cli.egg-info/PKG-INFO +319 -0
  3. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/autotouch_cli.egg-info/SOURCES.txt +2 -1
  4. autotouch_cli-0.2.10/docs/research-table/reference/autotouch-cli-pypi.md +310 -0
  5. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/pyproject.toml +2 -2
  6. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/smart_table_cli.py +447 -16
  7. autotouch_cli-0.2.10/scripts/verify_azurite_voicemail.py +64 -0
  8. autotouch_cli-0.2.8/PKG-INFO +0 -516
  9. autotouch_cli-0.2.8/autotouch_cli.egg-info/PKG-INFO +0 -516
  10. autotouch_cli-0.2.8/docs/research-table/reference/autotouch-cli.md +0 -507
  11. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/autotouch_cli.egg-info/dependency_links.txt +0 -0
  12. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/autotouch_cli.egg-info/entry_points.txt +0 -0
  13. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/autotouch_cli.egg-info/requires.txt +0 -0
  14. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/autotouch_cli.egg-info/top_level.txt +0 -0
  15. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/__init__.py +0 -0
  16. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/add_column_unique_index.py +0 -0
  17. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/attach_csv_import_leads_to_research_table.py +0 -0
  18. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/bundle_sequences_backend.py +0 -0
  19. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/check_agent_traces.py +0 -0
  20. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/check_column_mode.py +0 -0
  21. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/exit_terminal_leads_from_sequences.py +0 -0
  22. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/fetch_lead.py +0 -0
  23. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/fix_lead_titles_from_csv.py +0 -0
  24. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250106_add_column_position.py +0 -0
  25. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250108_fix_legacy_column_fields.py +0 -0
  26. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250109_add_user_fields_to_tables.py +0 -0
  27. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250117_add_call_logs_webhook_indexes.py +0 -0
  28. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250117_rename_call_logs_collection.py +0 -0
  29. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250119_create_leads_unique_email_index.py +0 -0
  30. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250123_add_filter_indexes.py +0 -0
  31. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250123_add_llm_responses_collection.py +0 -0
  32. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250128_migrate_user_ids_to_objectid.py +0 -0
  33. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250208_backfill_task_research_values.py +0 -0
  34. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250604_add_origin_indexes.py +0 -0
  35. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250608_cleanup_agent_metadata.py +0 -0
  36. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250608_rename_agent_metadata_to_metadata.py +0 -0
  37. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250922_add_activity_indexes.py +0 -0
  38. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250926_migrate_single_to_arrays.py +0 -0
  39. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250928_add_missing_timestamp_fields.py +0 -0
  40. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250929_add_task_join_indexes.py +0 -0
  41. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250929_add_task_join_indexes_safe.py +0 -0
  42. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20250929_create_shared_phone_cache.py +0 -0
  43. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20251007_add_rows_position_id_index.py +0 -0
  44. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20251109_add_ttl_for_llm_and_preview_traces.py +0 -0
  45. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20260113_normalize_table_filter_operators.py +0 -0
  46. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20260113_set_user_permissions_user_admin.py +0 -0
  47. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/20260204_sync_lead_owner_from_tasks.py +0 -0
  48. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/migrate_org_user_credits.py +0 -0
  49. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/set_default_lead_status.py +0 -0
  50. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/migrations/update_lead_owner_from_tasks.py +0 -0
  51. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/reassign_sequence_owner.py +0 -0
  52. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/run_sidecar_orchestrator_demo.py +0 -0
  53. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/test_crm_company_policy.py +0 -0
  54. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/test_sequences_instantly_e2e.py +0 -0
  55. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/test_sequences_personal_e2e.py +0 -0
  56. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/scripts/test_task_error_logger.py +0 -0
  57. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/setup.cfg +0 -0
  58. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_custom.py +0 -0
  59. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_integration.py +0 -0
  60. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_multi_titles.py +0 -0
  61. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_pipeline.py +0 -0
  62. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_simple.py +0 -0
  63. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_contactout_v2_bulk.py +0 -0
  64. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_lead_required_fields.py +0 -0
  65. {autotouch_cli-0.2.8 → autotouch_cli-0.2.10}/tests/test_phone_provider_pipeline.py +0 -0
@@ -0,0 +1,319 @@
1
+ Metadata-Version: 2.4
2
+ Name: autotouch-cli
3
+ Version: 0.2.10
4
+ Summary: Autotouch Smart Table CLI
5
+ Requires-Python: >=3.9
6
+ Description-Content-Type: text/markdown
7
+ Requires-Dist: requests>=2.31.0
8
+ Requires-Dist: python-dotenv>=1.0.0
9
+
10
+ # Autotouch CLI Quickstart (`autotouch`)
11
+
12
+ This is the package-facing quickstart for agents and humans using the installable CLI.
13
+
14
+ ## Install
15
+
16
+ ```bash
17
+ pipx install autotouch-cli
18
+ # or
19
+ pip install autotouch-cli
20
+ ```
21
+
22
+ ## Bootstrap account + API key (optional, recommended for new agents)
23
+
24
+ If you already have a developer API key, skip this and go to Configure auth.
25
+
26
+ ```bash
27
+ curl -X POST "https://app.autotouch.ai/api/auth/agent-bootstrap" \
28
+ -H "Content-Type: application/json" \
29
+ -d '{
30
+ "first_name": "Ada",
31
+ "last_name": "Lovelace",
32
+ "email": "ada@yourcompany.com",
33
+ "password": "use-a-strong-random-password",
34
+ "organization_name": "Your Company",
35
+ "key_name": "Agent bootstrap key"
36
+ }'
37
+ ```
38
+
39
+ Response includes:
40
+ - `apiKey` (returned once),
41
+ - `userData`,
42
+ - `key` metadata,
43
+ - `credits` snapshot.
44
+
45
+ Starter credits:
46
+ - New orgs created via signup/bootstrap start with `50` credits.
47
+
48
+ Identity linking:
49
+ - Human sign-in with the same normalized email lands in the same user/org account.
50
+
51
+ ## Configure auth
52
+
53
+ ```bash
54
+ autotouch auth set-key --api-key stk_... --base-url https://app.autotouch.ai
55
+ autotouch auth check
56
+ ```
57
+
58
+ ## Preflight (recommended before writes)
59
+
60
+ ```bash
61
+ # 1) Verify target table exists and copy the exact id
62
+ autotouch tables list --view-mode org --output human
63
+
64
+ # 2) Parse CSV only (no write)
65
+ autotouch rows import-csv \
66
+ --table-id <TABLE_ID> \
67
+ --confirm-table-id <TABLE_ID> \
68
+ --file contacts.csv \
69
+ --dry-run \
70
+ --output json
71
+ ```
72
+
73
+ Why this matters:
74
+ - Prevents wrong-table imports.
75
+ - Shows parsed row count and keys before spend/write.
76
+
77
+ ## Import CSV (default: optimized async)
78
+
79
+ ```bash
80
+ autotouch rows import-csv \
81
+ --table-id <TABLE_ID> \
82
+ --confirm-table-id <TABLE_ID> \
83
+ --file contacts.csv \
84
+ --checkpoint-file .autotouch-import.json \
85
+ --wait \
86
+ --output json
87
+ ```
88
+
89
+ Notes:
90
+ - `--transport optimized` is default (`/import-optimized`).
91
+ - `--wait` polls import status to terminal state.
92
+ - `--checkpoint-file` stores state and blocks accidental duplicate re-imports.
93
+ - Use `--allow-reimport` if you intentionally want to run the same file again.
94
+
95
+ ## Import modes
96
+
97
+ 1. `optimized` (default)
98
+ - Uses `/api/tables/{table_id}/import-optimized`.
99
+ - Best for larger files and resilient async handling.
100
+
101
+ 2. `direct`
102
+ - Uses row + cell API loops.
103
+ - Useful for debugging/smaller imports.
104
+
105
+ ```bash
106
+ autotouch rows import-csv \
107
+ --table-id <TABLE_ID> \
108
+ --confirm-table-id <TABLE_ID> \
109
+ --file contacts.csv \
110
+ --transport direct \
111
+ --output json
112
+ ```
113
+
114
+ ## Auto-run trigger contract
115
+
116
+ Auto-run is configured per column (`autoRun`), not per table.
117
+
118
+ - `never`: no automatic runs.
119
+ - `onInsert`: runs on newly inserted rows (for example CSV import/webhook ingest).
120
+ - `onSourceUpdate`: runs only when source values are updated (for example cell patch/update).
121
+
122
+ Important:
123
+ - Insert events do not run `onSourceUpdate` columns.
124
+ - Imports may queue auto-run dispatch evaluation, but only columns whose `autoRun` policy matches the event are queued.
125
+
126
+ ## Create a column
127
+
128
+ Recipe-first flow (recommended):
129
+
130
+ ```bash
131
+ autotouch columns recipe --type add_to_crm --output human
132
+ ```
133
+
134
+ Then create from the generated payload:
135
+
136
+ ```bash
137
+ autotouch columns create \
138
+ --table-id <TABLE_ID> \
139
+ --data-file column.json \
140
+ --output json
141
+ ```
142
+
143
+ Notes:
144
+ - `add_to_crm` is optional and non-billable.
145
+ - Email/phone enrichment does not require creating/running `add_to_crm`.
146
+ - For `add_to_crm`, required mapping keys are `linkedinUrl` and `companyDomain`.
147
+
148
+ ## Create basic/manual fields (text, number, date, etc.)
149
+
150
+ Use `kind=manual` for non-enrichment columns.
151
+
152
+ Supported `dataType` values:
153
+ - `text`
154
+ - `number`
155
+ - `date`
156
+ - `boolean`
157
+ - `email`
158
+ - `url`
159
+ - `json`
160
+
161
+ `manual-column.json`:
162
+
163
+ ```json
164
+ {
165
+ "key": "employee_count",
166
+ "label": "Employee Count",
167
+ "kind": "manual",
168
+ "dataType": "number",
169
+ "origin": "api",
170
+ "autoRun": "never"
171
+ }
172
+ ```
173
+
174
+ ```bash
175
+ autotouch columns create \
176
+ --table-id <TABLE_ID> \
177
+ --data-file manual-column.json \
178
+ --output json
179
+ ```
180
+
181
+ To create rows with values in one step:
182
+
183
+ `rows.json`:
184
+
185
+ ```json
186
+ {
187
+ "records": [
188
+ { "company": "Acme", "employee_count": 125, "founded_on": "2021-05-01" }
189
+ ]
190
+ }
191
+ ```
192
+
193
+ ```bash
194
+ autotouch rows add \
195
+ --table-id <TABLE_ID> \
196
+ --records-file rows.json \
197
+ --detect-types \
198
+ --output json
199
+ ```
200
+
201
+ To update existing rows/cells:
202
+
203
+ `updates.json`:
204
+
205
+ ```json
206
+ {
207
+ "updates": [
208
+ { "rowId": "<ROW_ID>", "key": "employee_count", "value": 130 },
209
+ { "rowId": "<ROW_ID>", "key": "founded_on", "value": "2021-05-01" }
210
+ ]
211
+ }
212
+ ```
213
+
214
+ ```bash
215
+ autotouch cells patch \
216
+ --table-id <TABLE_ID> \
217
+ --updates-file updates.json \
218
+ --detect-types \
219
+ --output json
220
+ ```
221
+
222
+ Note:
223
+ - If `updates[].key` does not exist, patch can auto-create a manual column (with `--detect-types`).
224
+
225
+ ## Run exactly next N rows (recommended for agents)
226
+
227
+ ```bash
228
+ autotouch columns run-next \
229
+ --table-id <TABLE_ID> \
230
+ --column-id <COLUMN_ID> \
231
+ --count 5 \
232
+ --show-estimate \
233
+ --wait \
234
+ --output json
235
+ ```
236
+
237
+ Why `run-next`:
238
+ - Deterministic exact-count batching.
239
+ - Avoids ambiguous `firstN` increments in agent loops.
240
+
241
+ For `add_to_crm`, prefer bounded runs first:
242
+
243
+ ```bash
244
+ autotouch columns run-next \
245
+ --table-id <TABLE_ID> \
246
+ --column-id <ADD_TO_CRM_COLUMN_ID> \
247
+ --count 25 \
248
+ --show-estimate \
249
+ --wait
250
+ ```
251
+
252
+ ## Credit-safe filtering pattern
253
+
254
+ Filter out rows that are missing required upstream fields before billable runs.
255
+
256
+ `filters.json`:
257
+
258
+ ```json
259
+ {
260
+ "mode": "and",
261
+ "filters": [
262
+ { "columnKey": "linkedin_url", "operator": "isNotEmpty" },
263
+ { "columnKey": "work_email_address", "operator": "isEmpty" }
264
+ ]
265
+ }
266
+ ```
267
+
268
+ Run:
269
+
270
+ ```bash
271
+ autotouch columns run-next \
272
+ --table-id <TABLE_ID> \
273
+ --column-id <COLUMN_ID> \
274
+ --count 5 \
275
+ --filters-file filters.json \
276
+ --show-estimate \
277
+ --wait
278
+ ```
279
+
280
+ ## Job truth contract (agent-safe)
281
+
282
+ - Treat a run as started only when you receive `job_id`.
283
+ - Treat a run as done only when `jobs get/watch` returns terminal status.
284
+
285
+ ```bash
286
+ autotouch jobs get --job-id <JOB_ID> --output json
287
+ autotouch jobs watch --job-id <JOB_ID> --interval 2 --output json
288
+ ```
289
+
290
+ Terminal statuses:
291
+ - `completed`
292
+ - `partial`
293
+ - `error`
294
+ - `cancelled`
295
+
296
+ ## Troubleshooting
297
+
298
+ 1. Import appears to run but rows are missing:
299
+ - Verify `table_id` in output matches intended target.
300
+ - Use `--confirm-table-id` on all mutating CSV imports.
301
+
302
+ 2. Duplicate imports:
303
+ - Use `--checkpoint-file`.
304
+ - Do not pass `--allow-reimport` unless intentional.
305
+
306
+ 3. Async import interrupted:
307
+ - Re-run with same `--checkpoint-file` and `--wait`.
308
+ - CLI can resume/poll an in-flight task from checkpoint state.
309
+
310
+ 4. Need to stop a running column job:
311
+
312
+ ```bash
313
+ autotouch columns stop --table-id <TABLE_ID> --column-id <COLUMN_ID>
314
+ ```
315
+
316
+ ---
317
+
318
+ Full reference (all commands/payload recipes):
319
+ `docs/research-table/reference/autotouch-cli.md`
@@ -0,0 +1,319 @@
1
+ Metadata-Version: 2.4
2
+ Name: autotouch-cli
3
+ Version: 0.2.10
4
+ Summary: Autotouch Smart Table CLI
5
+ Requires-Python: >=3.9
6
+ Description-Content-Type: text/markdown
7
+ Requires-Dist: requests>=2.31.0
8
+ Requires-Dist: python-dotenv>=1.0.0
9
+
10
+ # Autotouch CLI Quickstart (`autotouch`)
11
+
12
+ This is the package-facing quickstart for agents and humans using the installable CLI.
13
+
14
+ ## Install
15
+
16
+ ```bash
17
+ pipx install autotouch-cli
18
+ # or
19
+ pip install autotouch-cli
20
+ ```
21
+
22
+ ## Bootstrap account + API key (optional, recommended for new agents)
23
+
24
+ If you already have a developer API key, skip this and go to Configure auth.
25
+
26
+ ```bash
27
+ curl -X POST "https://app.autotouch.ai/api/auth/agent-bootstrap" \
28
+ -H "Content-Type: application/json" \
29
+ -d '{
30
+ "first_name": "Ada",
31
+ "last_name": "Lovelace",
32
+ "email": "ada@yourcompany.com",
33
+ "password": "use-a-strong-random-password",
34
+ "organization_name": "Your Company",
35
+ "key_name": "Agent bootstrap key"
36
+ }'
37
+ ```
38
+
39
+ Response includes:
40
+ - `apiKey` (returned once),
41
+ - `userData`,
42
+ - `key` metadata,
43
+ - `credits` snapshot.
44
+
45
+ Starter credits:
46
+ - New orgs created via signup/bootstrap start with `50` credits.
47
+
48
+ Identity linking:
49
+ - Human sign-in with the same normalized email lands in the same user/org account.
50
+
51
+ ## Configure auth
52
+
53
+ ```bash
54
+ autotouch auth set-key --api-key stk_... --base-url https://app.autotouch.ai
55
+ autotouch auth check
56
+ ```
57
+
58
+ ## Preflight (recommended before writes)
59
+
60
+ ```bash
61
+ # 1) Verify target table exists and copy the exact id
62
+ autotouch tables list --view-mode org --output human
63
+
64
+ # 2) Parse CSV only (no write)
65
+ autotouch rows import-csv \
66
+ --table-id <TABLE_ID> \
67
+ --confirm-table-id <TABLE_ID> \
68
+ --file contacts.csv \
69
+ --dry-run \
70
+ --output json
71
+ ```
72
+
73
+ Why this matters:
74
+ - Prevents wrong-table imports.
75
+ - Shows parsed row count and keys before spend/write.
76
+
77
+ ## Import CSV (default: optimized async)
78
+
79
+ ```bash
80
+ autotouch rows import-csv \
81
+ --table-id <TABLE_ID> \
82
+ --confirm-table-id <TABLE_ID> \
83
+ --file contacts.csv \
84
+ --checkpoint-file .autotouch-import.json \
85
+ --wait \
86
+ --output json
87
+ ```
88
+
89
+ Notes:
90
+ - `--transport optimized` is default (`/import-optimized`).
91
+ - `--wait` polls import status to terminal state.
92
+ - `--checkpoint-file` stores state and blocks accidental duplicate re-imports.
93
+ - Use `--allow-reimport` if you intentionally want to run the same file again.
94
+
95
+ ## Import modes
96
+
97
+ 1. `optimized` (default)
98
+ - Uses `/api/tables/{table_id}/import-optimized`.
99
+ - Best for larger files and resilient async handling.
100
+
101
+ 2. `direct`
102
+ - Uses row + cell API loops.
103
+ - Useful for debugging/smaller imports.
104
+
105
+ ```bash
106
+ autotouch rows import-csv \
107
+ --table-id <TABLE_ID> \
108
+ --confirm-table-id <TABLE_ID> \
109
+ --file contacts.csv \
110
+ --transport direct \
111
+ --output json
112
+ ```
113
+
114
+ ## Auto-run trigger contract
115
+
116
+ Auto-run is configured per column (`autoRun`), not per table.
117
+
118
+ - `never`: no automatic runs.
119
+ - `onInsert`: runs on newly inserted rows (for example CSV import/webhook ingest).
120
+ - `onSourceUpdate`: runs only when source values are updated (for example cell patch/update).
121
+
122
+ Important:
123
+ - Insert events do not run `onSourceUpdate` columns.
124
+ - Imports may queue auto-run dispatch evaluation, but only columns whose `autoRun` policy matches the event are queued.
125
+
126
+ ## Create a column
127
+
128
+ Recipe-first flow (recommended):
129
+
130
+ ```bash
131
+ autotouch columns recipe --type add_to_crm --output human
132
+ ```
133
+
134
+ Then create from the generated payload:
135
+
136
+ ```bash
137
+ autotouch columns create \
138
+ --table-id <TABLE_ID> \
139
+ --data-file column.json \
140
+ --output json
141
+ ```
142
+
143
+ Notes:
144
+ - `add_to_crm` is optional and non-billable.
145
+ - Email/phone enrichment does not require creating/running `add_to_crm`.
146
+ - For `add_to_crm`, required mapping keys are `linkedinUrl` and `companyDomain`.
147
+
148
+ ## Create basic/manual fields (text, number, date, etc.)
149
+
150
+ Use `kind=manual` for non-enrichment columns.
151
+
152
+ Supported `dataType` values:
153
+ - `text`
154
+ - `number`
155
+ - `date`
156
+ - `boolean`
157
+ - `email`
158
+ - `url`
159
+ - `json`
160
+
161
+ `manual-column.json`:
162
+
163
+ ```json
164
+ {
165
+ "key": "employee_count",
166
+ "label": "Employee Count",
167
+ "kind": "manual",
168
+ "dataType": "number",
169
+ "origin": "api",
170
+ "autoRun": "never"
171
+ }
172
+ ```
173
+
174
+ ```bash
175
+ autotouch columns create \
176
+ --table-id <TABLE_ID> \
177
+ --data-file manual-column.json \
178
+ --output json
179
+ ```
180
+
181
+ To create rows with values in one step:
182
+
183
+ `rows.json`:
184
+
185
+ ```json
186
+ {
187
+ "records": [
188
+ { "company": "Acme", "employee_count": 125, "founded_on": "2021-05-01" }
189
+ ]
190
+ }
191
+ ```
192
+
193
+ ```bash
194
+ autotouch rows add \
195
+ --table-id <TABLE_ID> \
196
+ --records-file rows.json \
197
+ --detect-types \
198
+ --output json
199
+ ```
200
+
201
+ To update existing rows/cells:
202
+
203
+ `updates.json`:
204
+
205
+ ```json
206
+ {
207
+ "updates": [
208
+ { "rowId": "<ROW_ID>", "key": "employee_count", "value": 130 },
209
+ { "rowId": "<ROW_ID>", "key": "founded_on", "value": "2021-05-01" }
210
+ ]
211
+ }
212
+ ```
213
+
214
+ ```bash
215
+ autotouch cells patch \
216
+ --table-id <TABLE_ID> \
217
+ --updates-file updates.json \
218
+ --detect-types \
219
+ --output json
220
+ ```
221
+
222
+ Note:
223
+ - If `updates[].key` does not exist, patch can auto-create a manual column (with `--detect-types`).
224
+
225
+ ## Run exactly next N rows (recommended for agents)
226
+
227
+ ```bash
228
+ autotouch columns run-next \
229
+ --table-id <TABLE_ID> \
230
+ --column-id <COLUMN_ID> \
231
+ --count 5 \
232
+ --show-estimate \
233
+ --wait \
234
+ --output json
235
+ ```
236
+
237
+ Why `run-next`:
238
+ - Deterministic exact-count batching.
239
+ - Avoids ambiguous `firstN` increments in agent loops.
240
+
241
+ For `add_to_crm`, prefer bounded runs first:
242
+
243
+ ```bash
244
+ autotouch columns run-next \
245
+ --table-id <TABLE_ID> \
246
+ --column-id <ADD_TO_CRM_COLUMN_ID> \
247
+ --count 25 \
248
+ --show-estimate \
249
+ --wait
250
+ ```
251
+
252
+ ## Credit-safe filtering pattern
253
+
254
+ Filter out rows that are missing required upstream fields before billable runs.
255
+
256
+ `filters.json`:
257
+
258
+ ```json
259
+ {
260
+ "mode": "and",
261
+ "filters": [
262
+ { "columnKey": "linkedin_url", "operator": "isNotEmpty" },
263
+ { "columnKey": "work_email_address", "operator": "isEmpty" }
264
+ ]
265
+ }
266
+ ```
267
+
268
+ Run:
269
+
270
+ ```bash
271
+ autotouch columns run-next \
272
+ --table-id <TABLE_ID> \
273
+ --column-id <COLUMN_ID> \
274
+ --count 5 \
275
+ --filters-file filters.json \
276
+ --show-estimate \
277
+ --wait
278
+ ```
279
+
280
+ ## Job truth contract (agent-safe)
281
+
282
+ - Treat a run as started only when you receive `job_id`.
283
+ - Treat a run as done only when `jobs get/watch` returns terminal status.
284
+
285
+ ```bash
286
+ autotouch jobs get --job-id <JOB_ID> --output json
287
+ autotouch jobs watch --job-id <JOB_ID> --interval 2 --output json
288
+ ```
289
+
290
+ Terminal statuses:
291
+ - `completed`
292
+ - `partial`
293
+ - `error`
294
+ - `cancelled`
295
+
296
+ ## Troubleshooting
297
+
298
+ 1. Import appears to run but rows are missing:
299
+ - Verify `table_id` in output matches intended target.
300
+ - Use `--confirm-table-id` on all mutating CSV imports.
301
+
302
+ 2. Duplicate imports:
303
+ - Use `--checkpoint-file`.
304
+ - Do not pass `--allow-reimport` unless intentional.
305
+
306
+ 3. Async import interrupted:
307
+ - Re-run with same `--checkpoint-file` and `--wait`.
308
+ - CLI can resume/poll an in-flight task from checkpoint state.
309
+
310
+ 4. Need to stop a running column job:
311
+
312
+ ```bash
313
+ autotouch columns stop --table-id <TABLE_ID> --column-id <COLUMN_ID>
314
+ ```
315
+
316
+ ---
317
+
318
+ Full reference (all commands/payload recipes):
319
+ `docs/research-table/reference/autotouch-cli.md`
@@ -5,7 +5,7 @@ autotouch_cli.egg-info/dependency_links.txt
5
5
  autotouch_cli.egg-info/entry_points.txt
6
6
  autotouch_cli.egg-info/requires.txt
7
7
  autotouch_cli.egg-info/top_level.txt
8
- docs/research-table/reference/autotouch-cli.md
8
+ docs/research-table/reference/autotouch-cli-pypi.md
9
9
  scripts/__init__.py
10
10
  scripts/add_column_unique_index.py
11
11
  scripts/attach_csv_import_leads_to_research_table.py
@@ -22,6 +22,7 @@ scripts/test_crm_company_policy.py
22
22
  scripts/test_sequences_instantly_e2e.py
23
23
  scripts/test_sequences_personal_e2e.py
24
24
  scripts/test_task_error_logger.py
25
+ scripts/verify_azurite_voicemail.py
25
26
  scripts/migrations/20250106_add_column_position.py
26
27
  scripts/migrations/20250108_fix_legacy_column_fields.py
27
28
  scripts/migrations/20250109_add_user_fields_to_tables.py