@opendatalabs/connect 0.8.1-canary.367ac08 → 0.8.1-canary.38ea4e7

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 (55) hide show
  1. package/README.md +220 -0
  2. package/dist/cli/bin.js +8 -0
  3. package/dist/cli/bin.js.map +1 -1
  4. package/dist/cli/index.d.ts.map +1 -1
  5. package/dist/cli/index.js +2266 -143
  6. package/dist/cli/index.js.map +1 -1
  7. package/dist/cli/main.d.ts.map +1 -1
  8. package/dist/cli/main.js +8 -0
  9. package/dist/cli/main.js.map +1 -1
  10. package/dist/cli/render/capabilities.d.ts +9 -0
  11. package/dist/cli/render/capabilities.d.ts.map +1 -0
  12. package/dist/cli/render/capabilities.js +24 -0
  13. package/dist/cli/render/capabilities.js.map +1 -0
  14. package/dist/cli/render/format.d.ts +22 -0
  15. package/dist/cli/render/format.d.ts.map +1 -0
  16. package/dist/cli/render/format.js +77 -0
  17. package/dist/cli/render/format.js.map +1 -0
  18. package/dist/cli/render/index.d.ts +6 -0
  19. package/dist/cli/render/index.d.ts.map +1 -0
  20. package/dist/cli/render/index.js +6 -0
  21. package/dist/cli/render/index.js.map +1 -0
  22. package/dist/cli/render/progress.d.ts +11 -0
  23. package/dist/cli/render/progress.d.ts.map +1 -0
  24. package/dist/cli/render/progress.js +56 -0
  25. package/dist/cli/render/progress.js.map +1 -0
  26. package/dist/cli/render/symbols.d.ts +11 -0
  27. package/dist/cli/render/symbols.d.ts.map +1 -0
  28. package/dist/cli/render/symbols.js +21 -0
  29. package/dist/cli/render/symbols.js.map +1 -0
  30. package/dist/cli/render/theme.d.ts +15 -0
  31. package/dist/cli/render/theme.d.ts.map +1 -0
  32. package/dist/cli/render/theme.js +41 -0
  33. package/dist/cli/render/theme.js.map +1 -0
  34. package/dist/core/cli-types.d.ts +475 -1
  35. package/dist/core/cli-types.d.ts.map +1 -1
  36. package/dist/core/cli-types.js +222 -1
  37. package/dist/core/cli-types.js.map +1 -1
  38. package/dist/core/state-store.d.ts +6 -0
  39. package/dist/core/state-store.d.ts.map +1 -1
  40. package/dist/core/state-store.js +68 -4
  41. package/dist/core/state-store.js.map +1 -1
  42. package/dist/runtime/core/contracts.d.ts +15 -1
  43. package/dist/runtime/core/contracts.d.ts.map +1 -1
  44. package/dist/runtime/managed-playwright.d.ts +5 -0
  45. package/dist/runtime/managed-playwright.d.ts.map +1 -1
  46. package/dist/runtime/managed-playwright.js +69 -10
  47. package/dist/runtime/managed-playwright.js.map +1 -1
  48. package/dist/runtime/playwright/browser.d.ts +1 -0
  49. package/dist/runtime/playwright/browser.d.ts.map +1 -1
  50. package/dist/runtime/playwright/browser.js +14 -4
  51. package/dist/runtime/playwright/browser.js.map +1 -1
  52. package/dist/runtime/playwright/in-process-run.d.ts.map +1 -1
  53. package/dist/runtime/playwright/in-process-run.js +68 -11
  54. package/dist/runtime/playwright/in-process-run.js.map +1 -1
  55. package/package.json +14 -1
package/README.md CHANGED
@@ -2,6 +2,65 @@
2
2
 
3
3
  Let your users bring their own data to your app.
4
4
 
5
+ ## CLI preview
6
+
7
+ This branch also carries the new `vana` collection CLI preview.
8
+
9
+ - install the current canary on macOS with Homebrew:
10
+
11
+ ```bash
12
+ brew tap vana-com/vana
13
+ brew install vana
14
+ vana status
15
+ ```
16
+
17
+ - or use the hosted prerelease installer on macOS/Linux:
18
+
19
+ ```bash
20
+ curl -fsSL https://raw.githubusercontent.com/vana-com/vana-connect/feat/connect-cli-v1/install/install.sh | sh -s -- --version canary-feat-connect-cli-v1
21
+ ```
22
+
23
+ - branch release page:
24
+ `https://github.com/vana-com/vana-connect/releases/tag/canary-feat-connect-cli-v1`
25
+ - demo media:
26
+ [`status-and-sources.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/status-and-sources.gif),
27
+ [`data-inspection.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/data-inspection.gif),
28
+ [`connect-success.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/connect-success.gif)
29
+
30
+ Once installed, the best way to evaluate the CLI quickly is:
31
+
32
+ ```bash
33
+ vana --version
34
+ vana doctor
35
+ vana status
36
+ vana sources
37
+ vana connect github
38
+ vana data list
39
+ vana data show github
40
+ vana logs github
41
+ ```
42
+
43
+ Current reviewable transcripts:
44
+
45
+ - [`status`](./docs/transcripts/status.txt)
46
+ - [`doctor`](./docs/transcripts/doctor.txt)
47
+ - [`logs`](./docs/transcripts/logs.txt)
48
+ - [`setup`](./docs/transcripts/setup.txt)
49
+ - [`sources`](./docs/transcripts/sources.txt)
50
+ - [`data list`](./docs/transcripts/data-list.txt)
51
+ - [`data help`](./docs/transcripts/data-help.txt)
52
+ - [`data list (empty)`](./docs/transcripts/data-list-empty.txt)
53
+ - [`data show github`](./docs/transcripts/data-show-github.txt)
54
+ - [`data show github (missing)`](./docs/transcripts/data-show-github-missing.txt)
55
+ - [`data path github`](./docs/transcripts/data-path-github.txt)
56
+ - [`connect github`](./docs/transcripts/connect-github-success.txt)
57
+ - [`connect github --no-input`](./docs/transcripts/connect-github-no-input.txt)
58
+ - [`connect github session reuse --no-input`](./docs/transcripts/connect-github-session-reuse-no-input.txt)
59
+ - [`connect shop`](./docs/transcripts/connect-shop.txt)
60
+ - [`connect shop --no-input`](./docs/transcripts/connect-shop-no-input.txt)
61
+ - [`connect steam`](./docs/transcripts/connect-steam.txt)
62
+ - [`connect steam --no-input`](./docs/transcripts/connect-steam-no-input.txt)
63
+
5
64
  ## What problem this solves
6
65
 
7
66
  Your users already have rich personal data — ChatGPT conversations, Instagram activity, Gmail, purchase history — but it's locked inside the platforms that collected it. As a builder, you can't easily use that data to personalize onboarding, tailor recommendations, or skip lengthy signup forms.
@@ -80,6 +139,13 @@ If you prefer to integrate the SDK into an existing project, follow the steps be
80
139
 
81
140
  If you are evaluating this branch before it lands on `main`, use the prerelease path in the next section. The stable install commands below are the intended post-merge install path.
82
141
 
142
+ macOS with Homebrew:
143
+
144
+ ```bash
145
+ brew tap vana-com/vana
146
+ brew install vana
147
+ ```
148
+
83
149
  macOS and Linux:
84
150
 
85
151
  ```bash
@@ -98,6 +164,15 @@ Both installers fetch the latest GitHub release asset for your platform, verify
98
164
 
99
165
  If you are testing an unreleased branch build, install from the branch installer and pass the prerelease tag explicitly.
100
166
 
167
+ macOS with Homebrew:
168
+
169
+ ```bash
170
+ brew tap vana-com/vana
171
+ brew install vana
172
+ ```
173
+
174
+ The current Homebrew tap is following the latest `vana-connect` canary while this CLI is still rolling out.
175
+
101
176
  macOS and Linux:
102
177
 
103
178
  ```bash
@@ -127,10 +202,155 @@ npx -y @opendatalabs/connect status
127
202
  ### Commands
128
203
 
129
204
  ```bash
205
+ vana --version
206
+ vana version
207
+ vana doctor
208
+ vana logs
209
+ vana connect
130
210
  vana sources
131
211
  vana connect github
212
+ vana connect github --json --no-input
132
213
  vana status
133
214
  vana setup
215
+ vana data list
216
+ vana data path github --json
217
+ vana data show github --json | jq '.summary.lines'
218
+ ```
219
+
220
+ - `vana connect` opens a guided source picker in human mode.
221
+ - `vana connect <source>` runs the end-to-end collection flow.
222
+ - `vana connect <source> --json --no-input` is the strict machine-safe path for agents and shell automation.
223
+ - `vana sources` groups sources into ready-now vs manual-step flows.
224
+ - `vana status` prioritizes sources that need attention before already-connected sources.
225
+ - `vana doctor` checks the local install, browser runtime, and state directories.
226
+ - `vana logs` lets you inspect the latest stored connector run logs without hunting through `~/.dataconnect/logs`.
227
+ - `vana data ...` lets you inspect collected local datasets without opening the raw JSON file yourself.
228
+
229
+ ### Shell contract
230
+
231
+ - `--json` mode writes machine-readable output to stdout without human narration.
232
+ - Successful command completion returns exit code `0`.
233
+ - Actionable failures like missing source selection, unavailable connectors, or disabled prompting return exit code `1`.
234
+ - `vana --version`, `vana version`, and `vana --help` return exit code `0`.
235
+ - `vana doctor --json` includes `installMethod`, `channel`, and upgrade/uninstall commands so scripts can surface the right lifecycle guidance.
236
+
237
+ ### Shell examples
238
+
239
+ ```bash
240
+ vana status --json | jq '.channel, .installMethod, .summary | {connectedCount, localCount, syncedCount}'
241
+ vana sources --json | jq '.summary, .recommendedSource'
242
+ vana data list --json | jq '.summary, .datasets[] | {source, dataState, path}'
243
+ vana logs --json | jq '.latestLog, .logs[] | {source, path}'
244
+ vana doctor --json | jq '.paths.executable, .paths.dataHome, .lifecycle'
245
+ ```
246
+
247
+ ### Upgrade, channels, and uninstall
248
+
249
+ Upgrade with the same channel you installed from:
250
+
251
+ You can always confirm the current install method and exact lifecycle commands with:
252
+
253
+ ```bash
254
+ vana doctor
255
+ ```
256
+
257
+ - Homebrew:
258
+ ```bash
259
+ brew update
260
+ brew upgrade vana
261
+ ```
262
+ - macOS/Linux installer:
263
+ ```bash
264
+ curl -fsSL https://raw.githubusercontent.com/vana-com/vana-connect/main/install/install.sh | sh
265
+ ```
266
+ - Windows PowerShell installer:
267
+ ```powershell
268
+ iwr https://raw.githubusercontent.com/vana-com/vana-connect/main/install/install.ps1 -useb | iex
269
+ ```
270
+
271
+ Current channels:
272
+
273
+ - `stable`: install from `main` or the eventual stable Homebrew tap state
274
+ - `canary`: install from the latest prerelease assets while this CLI is still rolling out
275
+
276
+ To remove the installed CLI:
277
+
278
+ - Homebrew:
279
+ ```bash
280
+ brew uninstall vana
281
+ ```
282
+ - macOS/Linux installer:
283
+ ```bash
284
+ rm -f ~/.local/bin/vana
285
+ rm -rf ~/.local/share/vana
286
+ ```
287
+ - Windows PowerShell installer:
288
+ - remove `%USERPROFILE%\AppData\Local\Microsoft\WinGet\Links\vana.cmd`
289
+ - remove `%USERPROFILE%\AppData\Local\Vana`
290
+
291
+ To remove local runtime and collected state as well:
292
+
293
+ ```bash
294
+ rm -rf ~/.dataconnect
295
+ ```
296
+
297
+ ### CLI demos
298
+
299
+ The branch also includes deterministic VHS demo scaffolding under
300
+ [`docs/vhs/`](./docs/vhs/README.md).
301
+
302
+ Branch prerelease preview media:
303
+
304
+ - [`status-and-sources.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/status-and-sources.gif)
305
+ - [`data-inspection.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/data-inspection.gif)
306
+ - [`connect-success.gif`](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/connect-success.gif)
307
+
308
+ ![Vana status and sources demo](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/status-and-sources.gif)
309
+
310
+ ![Vana data inspection demo](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/data-inspection.gif)
311
+
312
+ ![Vana successful connect demo](https://github.com/vana-com/vana-connect/releases/download/canary-feat-connect-cli-v1/connect-success.gif)
313
+
314
+ Current reviewable transcripts:
315
+
316
+ - [`status`](./docs/transcripts/status.txt)
317
+ - [`doctor`](./docs/transcripts/doctor.txt)
318
+ - [`logs`](./docs/transcripts/logs.txt)
319
+ - [`setup`](./docs/transcripts/setup.txt)
320
+ - [`sources`](./docs/transcripts/sources.txt)
321
+ - [`data list`](./docs/transcripts/data-list.txt)
322
+ - [`data list (empty)`](./docs/transcripts/data-list-empty.txt)
323
+ - [`data show github`](./docs/transcripts/data-show-github.txt)
324
+ - [`data show github (missing)`](./docs/transcripts/data-show-github-missing.txt)
325
+ - [`data path github`](./docs/transcripts/data-path-github.txt)
326
+ - [`connect github`](./docs/transcripts/connect-github-success.txt)
327
+ - [`connect github --no-input`](./docs/transcripts/connect-github-no-input.txt)
328
+ - [`connect shop --no-input`](./docs/transcripts/connect-shop-no-input.txt)
329
+ - [`connect steam --no-input`](./docs/transcripts/connect-steam-no-input.txt)
330
+
331
+ To seed the fixture home used by the first tapes:
332
+
333
+ ```bash
334
+ pnpm demo:vhs:fixtures
335
+ ```
336
+
337
+ To render the checked-in tapes once `vhs` or Docker is available:
338
+
339
+ ```bash
340
+ pnpm demo:vhs
341
+ ```
342
+
343
+ To capture deterministic human-mode transcripts for review:
344
+
345
+ ```bash
346
+ pnpm demo:transcripts
347
+ ```
348
+
349
+ To watch the branch release lane, trigger Homebrew sync, and verify the
350
+ published installer automatically:
351
+
352
+ ```bash
353
+ pnpm release:watch
134
354
  ```
135
355
 
136
356
  ### Local development
package/dist/cli/bin.js CHANGED
@@ -1,5 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { runCli } from "./index.js";
3
+ for (const stream of [process.stdout, process.stderr]) {
4
+ stream.on("error", (error) => {
5
+ if (error.code === "EPIPE") {
6
+ process.exit(0);
7
+ }
8
+ throw error;
9
+ });
10
+ }
3
11
  const exitCode = await runCli(process.argv);
4
12
  if (typeof exitCode === "number") {
5
13
  process.exitCode = exitCode;
@@ -1 +1 @@
1
- {"version":3,"file":"bin.js","sourceRoot":"","sources":["../../src/cli/bin.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;AAC5C,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE,CAAC;IACjC,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC;AAC9B,CAAC"}
1
+ {"version":3,"file":"bin.js","sourceRoot":"","sources":["../../src/cli/bin.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,KAAK,MAAM,MAAM,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC;IACtD,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,KAA4B,EAAE,EAAE;QAClD,IAAI,KAAK,CAAC,IAAI,KAAK,OAAO,EAAE,CAAC;YAC3B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC;QACD,MAAM,KAAK,CAAC;IACd,CAAC,CAAC,CAAC;AACL,CAAC;AAED,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;AAC5C,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE,CAAC;IACjC,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC;AAC9B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":"AAmDA,wBAAsB,MAAM,CAAC,IAAI,WAAe,GAAG,OAAO,CAAC,MAAM,CAAC,CA2CjE"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":"AAkGA,wBAAsB,MAAM,CAAC,IAAI,WAAe,GAAG,OAAO,CAAC,MAAM,CAAC,CAiPjE"}