@notis_ai/cli 0.2.0-beta.178.1 → 0.2.0-beta.1792022492092.1

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 (124) hide show
  1. package/README.md +548 -98
  2. package/config/portal-route-roots.json +47 -0
  3. package/dist/agent-hooks/notis-agent-hook.mjs +32901 -5934
  4. package/dist/base-skills/notis-apps/SKILL.md +76 -51
  5. package/dist/base-skills/notis-apps/references/architecture.md +116 -164
  6. package/dist/base-skills/notis-apps/references/design.md +26 -107
  7. package/dist/base-skills/notis-apps/references/memory.md +58 -0
  8. package/dist/base-skills/notis-apps/references/reading.md +52 -74
  9. package/dist/base-skills/notis-apps/references/release.md +105 -96
  10. package/dist/base-skills/notis-apps/references/sdk.md +115 -60
  11. package/dist/base-skills/notis-apps/references/troubleshooting.md +22 -21
  12. package/dist/base-skills/notis-apps/references/views.md +145 -0
  13. package/dist/base-skills/notis-cli/SKILL.md +29 -12
  14. package/dist/base-skills/notis-cli/references/app-delivery.md +12 -11
  15. package/dist/base-skills/notis-cli/references/intelligence.md +94 -0
  16. package/dist/base-skills/notis-cli/references/native-databases.md +6 -5
  17. package/dist/base-skills/notis-cli/references/tool-examples.md +4 -4
  18. package/dist/base-skills/notis-query/SKILL.md +34 -60
  19. package/dist/base-skills/notis-query/references/database-discovery.md +60 -59
  20. package/dist/base-skills/notis-query/references/documents.md +53 -39
  21. package/dist/base-skills/notis-query/references/query.md +57 -524
  22. package/dist/sdk/src/bundleModule.ts +79 -0
  23. package/dist/sdk/src/components/DocumentEditor.tsx +6 -3
  24. package/dist/sdk/src/components/DocumentPage.tsx +144 -0
  25. package/dist/sdk/src/components/RecordComponents.tsx +33 -0
  26. package/dist/sdk/src/components/RenderChartData.tsx +19 -0
  27. package/dist/sdk/src/config.ts +4 -26
  28. package/dist/sdk/src/documents.ts +2 -0
  29. package/dist/sdk/src/hooks/useAction.ts +28 -0
  30. package/dist/sdk/src/hooks/useBackend.ts +3 -2
  31. package/dist/sdk/src/hooks/useCloudComputer.ts +35 -4
  32. package/dist/sdk/src/hooks/useCloudComputerShell.ts +114 -0
  33. package/dist/sdk/src/hooks/useCollectionInteractions.ts +4 -2
  34. package/dist/sdk/src/hooks/useHandover.ts +7 -7
  35. package/dist/sdk/src/hooks/useNativeDocumentBody.ts +50 -0
  36. package/dist/sdk/src/hooks/useNativeDocuments.ts +83 -0
  37. package/dist/sdk/src/hooks/useNotis.ts +3 -0
  38. package/dist/sdk/src/hooks/useNotisNavigation.ts +26 -11
  39. package/dist/sdk/src/hooks/useQuery.ts +7 -4
  40. package/dist/sdk/src/hooks/useViewParams.ts +121 -0
  41. package/dist/sdk/src/hooks/useViewerReads.ts +129 -0
  42. package/dist/sdk/src/index.ts +36 -0
  43. package/dist/sdk/src/interactions/shortcuts.tsx +42 -5
  44. package/dist/sdk/src/nativeData.ts +39 -0
  45. package/dist/sdk/src/presentation.tsx +82 -0
  46. package/dist/sdk/src/provider.tsx +9 -4
  47. package/dist/sdk/src/queryCache.ts +5 -3
  48. package/dist/sdk/src/queryErrors.ts +51 -0
  49. package/dist/sdk/src/runtime.ts +163 -13
  50. package/dist/sdk/src/space.ts +425 -0
  51. package/dist/sdk/src/styles.css +96 -72
  52. package/dist/sdk/src/vite.ts +11 -1
  53. package/dist/skill-sync/index.js +571 -80
  54. package/dist/skill-sync/index.js.map +4 -4
  55. package/dist/skill-sync-worker.mjs +858 -233
  56. package/dist/space-harness/host.js +66 -0
  57. package/dist/view-renderer/dist/host.css +1 -0
  58. package/dist/view-renderer/dist/host.js +1028 -0
  59. package/dist/view-renderer/dist/theme.css +73 -0
  60. package/dist/view-renderer/src/dom.js +180 -0
  61. package/dist/view-renderer/src/errors.js +8 -0
  62. package/dist/view-renderer/src/host.tsx +175 -0
  63. package/dist/view-renderer/src/index.js +4 -0
  64. package/dist/view-renderer/src/pool.js +76 -0
  65. package/dist/view-renderer/src/remote-broker.js +59 -0
  66. package/dist/view-renderer/src/renderer.js +201 -0
  67. package/package.json +16 -5
  68. package/skills/notis-apps/cli.md +323 -163
  69. package/skills/notis-cli/AGENT_INSTRUCTIONS.md +3 -3
  70. package/skills/notis-onboarding/BRIEF.md +7 -3
  71. package/src/command-specs/apps.js +2 -1
  72. package/src/command-specs/auth.js +2 -2
  73. package/src/command-specs/files.js +29 -0
  74. package/src/command-specs/handover.js +331 -79
  75. package/src/command-specs/helpers.js +2 -0
  76. package/src/command-specs/index.js +11 -5
  77. package/src/command-specs/profile.js +42 -1
  78. package/src/command-specs/skills.js +242 -1
  79. package/src/command-specs/spaces.js +645 -0
  80. package/src/command-specs/tools.js +0 -6
  81. package/src/command-specs/views.js +69 -0
  82. package/src/runtime/agent-browser.js +92 -29
  83. package/src/runtime/app-boundary-validator.js +7 -4
  84. package/src/runtime/app-data-literals.js +82 -0
  85. package/src/runtime/app-platform.js +321 -253
  86. package/src/runtime/computer-identity.d.ts +30 -0
  87. package/src/runtime/computer-identity.js +151 -0
  88. package/src/runtime/config-lock.js +135 -0
  89. package/src/runtime/confined-space-build.js +74 -0
  90. package/src/runtime/confined-space-verify.js +49 -0
  91. package/src/runtime/delegated-context.js +5 -21
  92. package/src/runtime/native-record-files.js +47 -0
  93. package/src/runtime/oauth.js +18 -1
  94. package/src/runtime/profiles.js +5 -107
  95. package/src/runtime/retired-sdk-files.js +20 -0
  96. package/src/runtime/screenshot-framing.js +85 -0
  97. package/src/runtime/skill-sync/cloud-client.ts +26 -4
  98. package/src/runtime/skill-sync/index.ts +230 -35
  99. package/src/runtime/skill-sync/local-scanner.ts +188 -29
  100. package/src/runtime/skill-sync/native-identity.ts +102 -0
  101. package/src/runtime/skill-sync/native-plan.ts +70 -0
  102. package/src/runtime/skill-sync/sync-plan.ts +16 -9
  103. package/src/runtime/skill-sync/types.ts +32 -6
  104. package/src/runtime/source-root.js +32 -0
  105. package/src/runtime/space-collection-scaffold.js +66 -0
  106. package/src/runtime/space-database-structures.js +229 -0
  107. package/src/runtime/space-fixture-broker.js +50 -0
  108. package/src/runtime/space-lock.js +337 -0
  109. package/src/runtime/space-platform.js +105 -0
  110. package/src/runtime/space-source.js +281 -0
  111. package/src/runtime/space-test-server.js +327 -0
  112. package/src/runtime/space-verification.js +89 -0
  113. package/src/runtime/space-verify-browser-worker.js +51 -0
  114. package/src/runtime/space-view-manifest.js +254 -0
  115. package/src/runtime/store-screenshot.js +10 -7
  116. package/src/runtime/sync-skills.d.ts +3 -1
  117. package/src/runtime/sync-skills.js +10 -2
  118. package/src/runtime/transport.js +8 -6
  119. package/src/runtime/view-render.js +49 -0
  120. package/src/skill-sync-worker.js +14 -2
  121. package/src/space-harness-host.ts +103 -0
  122. package/template/.harness/index.html.tmpl +7 -10
  123. package/template/app/globals.css +1 -0
  124. package/src/command-specs/reports.js +0 -97
@@ -1,34 +1,26 @@
1
- # Notis CLI — App Development Workflow
1
+ # Notis CLI: Space Development Workflow
2
2
 
3
- When running outside the Notis container, use the `notis` CLI to work with Notis Apps locally.
3
+ When running outside the Notis container, use the `notis` CLI to build Notis Spaces locally. Space views are
4
+ Vite + React source using `@notis/sdk`. The product `notis-apps` skill and its release guide own the workflow;
5
+ this file lists the commands generated from the CLI's own help.
4
6
 
5
- Notis apps are Vite + React projects using `@notis/sdk`. Workspace runs released versions only.
6
- Local and cloud create/edit requests authorize Workspace delivery after checks; explicit read-only,
7
- preview-only or no-deploy requests stop at local artifacts without remote mutation. Store publication
8
- requires separate approval.
7
+ Create and edit requests authorize delivery to the installed Space after checks; explicit read-only, preview-only
8
+ or no-deploy requests stop at local artifacts without remote mutation. Store publication requires separate approval.
9
9
 
10
10
  ## Core workflow
11
11
 
12
- 1. Preserve local edits; pull the exact existing released app and current deployment base. For an
13
- unreleased container, recover original source (or scaffold locally if unrecoverable), reconcile
14
- its exact ID/current version/edit permission/scope and run apps link <app-id> <source-directory>
15
- --expected-version 0. If a release has appeared, preserve local source separately and pull/reapply
16
- on that current release. Never pull missing source or create another remote recovery app.
17
- 2. Build and automatically verify before new remote creation. Browser tooling is required.
18
- 3. Reconcile exact profile/app identity and personal/team scope. Create only if absent; never duplicate
19
- a failed first-release container. Prepare only necessary backward-compatible resource changes.
20
- 4. Deploy the same linked app. Deploy builds, verifies a frozen snapshot, then uploads those bytes.
21
- `--skip-build` still verifies and rejects stale output. No Store media requirement applies.
22
- 5. Read back the exact installed ID/version/Portal URL, run live verification, and open the installed
23
- app in Portal. Report unknown or deployed-but-unverified outcomes; never blindly redeploy.
12
+ 1. `spaces pull` the exact existing Space (source, resource list, Skill folders and lock file), or `spaces init`
13
+ a new collection view.
14
+ 2. `spaces build` and `spaces verify` the selected source with fictional fixtures.
15
+ 3. `spaces deploy`, or `spaces preview` then `spaces promote`, within the user's authorization. Changed Skill
16
+ folders and resource links commit with the source release.
17
+ 4. Read back the published revision, then `views find` and `views render` its live view link.
24
18
 
25
- For source restoration, pull the current release into a fresh checkout and historical source into
26
- another folder. Replace source while retaining the current profile/app link and deployment base,
27
- change the package release label, check resource compatibility and deploy as a new release.
19
+ `notis apps` is the legacy App group for accounts not yet moved to Spaces; a legacy App cannot declare Skills.
28
20
 
29
- ## Reports
21
+ ## Reports and HTML
30
22
 
31
- For a standalone live report, use `reports init → build → verify/preview → save` instead of the app deployment workflow above. Author exactly one route with kind: report, declare its tools, and supply a readable context file. No installed app or database is required. Revisions preserve the record ID and require its freshly read revision. See the product `notis-reports` skill for source recovery, ownership and readback. These commands do not deploy an app or publish a Store listing.
23
+ Interactive reports are independent Space views. Save self-contained HTML pages and reports in Notis Notes with its Save HTML Skill; pages and reports saved before Spaces open there too. See the canonical product guidance for build, revision, native file and view-link rules.
32
24
 
33
25
  ## Commands
34
26
 
@@ -42,258 +34,426 @@ Examples:
42
34
  - `npx --package @notis_ai/cli@latest -- notis doctor`
43
35
  - `npx --package @notis_ai/cli@latest -- notis doctor --json`
44
36
 
45
- ### `npx --package @notis_ai/cli@latest -- notis apps list`
37
+ ### `npx --package @notis_ai/cli@latest -- notis spaces screenshot <url>`
46
38
 
47
- List apps the current profile can access.
39
+ Capture a full-height PNG of a live view with your current access.
48
40
 
49
- When to use: Discover existing apps before linking or deploying.
41
+ When to use: Check the actual deployed view; writes are blocked and current access is checked again before any output is saved.
42
+
43
+ Options:
44
+ - `--width <pixels>` — 1440 (default) or 390.
45
+ - `--output-dir <path>` — New output directory; defaults to a unique .notis/renders directory. Existing files are never overwritten.
46
+
47
+ Examples:
48
+ - `npx --package @notis_ai/cli@latest -- notis spaces screenshot <view-link> --width 390`
49
+
50
+ ### `npx --package @notis_ai/cli@latest -- notis spaces init <name> [dir]`
51
+
52
+ Scaffold an editable collection view with first-party record components.
53
+
54
+ When to use: Start a local Space collection source for an existing linked database. Does not create or deploy remote resources.
55
+
56
+ Options:
57
+ - `--database-key <key>` — Portable key of the database this Space links.
58
+ - `--path <path>` — Descriptive view path; defaults to records.
59
+ - `--title-property <id>` — Canonical title/number property ID, or the title column (default).
60
+
61
+ Examples:
62
+ - `npx --package @notis_ai/cli@latest -- notis spaces init Notes ./notes --database-key notes --path notes`
63
+
64
+ ### `npx --package @notis_ai/cli@latest -- notis spaces navigation bind <space-id>`
65
+
66
+ Bind a named destination for the next source publication without granting target access.
67
+
68
+ When to use: Connect a portable navigation alias to an existing Space or exact record before building and publishing.
69
+
70
+ Options:
71
+ - `--alias <name>` — Declared portable navigation alias.
72
+ - `--target <json>` — Exact {space_id,document_id?}, or null to remove the draft binding.
73
+ - `--revision <number>` — Current source Space metadata revision.
74
+ - `--dry-run` — Check current source/target access and revision without changing anything.
75
+
76
+ Examples:
77
+ - `npx --package @notis_ai/cli@latest -- notis spaces navigation bind <space-id> --alias history --target '{"space_id":"<history-id>"}' --revision 2 --dry-run`
78
+
79
+ ### `npx --package @notis_ai/cli@latest -- notis spaces resources name <space-id> <binding-id>`
80
+
81
+ Give an included resource a portable alias before the first source revision.
82
+
83
+ When to use: Prepare staged resources for source authoring without replacing their IDs, scope or owners.
84
+
85
+ Options:
86
+ - `--alias <name>` — Stable lowercase alias to use in source.
87
+ - `--revision <number>` — Current Space metadata revision.
88
+ - `--dry-run` — Check naming, current access and revision without changing metadata.
89
+
90
+ Examples:
91
+ - `npx --package @notis_ai/cli@latest -- notis spaces resources name <space-id> <binding-id> --alias weekly-report --revision 0 --dry-run`
92
+
93
+ ### `npx --package @notis_ai/cli@latest -- notis spaces links list <space-id>`
94
+
95
+ List the databases, Skills, automations and records linked into one Space.
96
+
97
+ When to use: Find a link binding and its revision before removing it, including a link left behind by a deleted Skill.
98
+
99
+ Examples:
100
+ - `npx --package @notis_ai/cli@latest -- notis spaces links list <space-id>`
101
+
102
+ ### `npx --package @notis_ai/cli@latest -- notis spaces links remove <space-id> <binding-id>`
103
+
104
+ Remove one database, Skill or automation link from a Space by its binding.
105
+
106
+ When to use: Unlist a resource from a Space you edit, including a link whose Skill was deleted. The resource keeps its ID; removing the last available link of a live resource keeps it as its owner's standalone resource.
107
+
108
+ Options:
109
+ - `--revision <number>` — Current binding revision from spaces links list.
110
+ - `--request-id <key>` — Stable intent key; reuse it unchanged when retrying this removal.
111
+
112
+ Examples:
113
+ - `npx --package @notis_ai/cli@latest -- notis spaces links remove <space-id> <binding-id> --revision 1 --request-id remove-link-1`
114
+
115
+ ### `npx --package @notis_ai/cli@latest -- notis spaces aliases list`
116
+
117
+ List the old App page links you manage and the Space each one opens.
118
+
119
+ When to use: Find an old App page link that opens a binned Space (trashed: true) before repointing it.
120
+
121
+ Options:
122
+ - `--legacy-id <id>` — Old App ID the links belong to.
123
+ - `--kind <kind>` — app (default), report or html.
124
+
125
+ Examples:
126
+ - `npx --package @notis_ai/cli@latest -- notis spaces aliases list --legacy-id <app-id>`
127
+
128
+ ### `npx --package @notis_ai/cli@latest -- notis spaces aliases repoint`
129
+
130
+ Point one old App page link at a live Space you edit.
131
+
132
+ When to use: Repair an old App page link whose Space was binned. You must own the old App or edit the Space the link opens now, and edit the new Space; everyone who opens the link still needs their own access to it.
133
+
134
+ Options:
135
+ - `--legacy-id <id>` — Old App ID the link belongs to.
136
+ - `--route <slug>` — Old App page route from spaces aliases list.
137
+ - `--space <space-id>` — Live Space the old link should open.
138
+ - `--expected-space <space-id>` — Space the link opens now; the change is refused if it moved since you listed it.
139
+ - `--selection-param <name>` — Declared view parameter that receives the old page selection, if any.
140
+ - `--request-id <key>` — Stable intent key; reuse it unchanged when retrying this change.
141
+ - `--dry-run` — Check authority and the new Space without changing the link.
142
+
143
+ Examples:
144
+ - `npx --package @notis_ai/cli@latest -- notis spaces aliases repoint --legacy-id <app-id> --route pages --space <space-id> --expected-space <binned-space-id> --request-id repoint-pages --dry-run`
145
+
146
+ ### `npx --package @notis_ai/cli@latest -- notis spaces pull <space-id> [dir]`
147
+
148
+ Pull one editable Space source snapshot, its resource list and its Skill folders into an empty directory.
149
+
150
+ When to use: Edit a Space you can administer: the source, its links (resources.json) and every editable linked Skill (skills/<alias>/) arrive together, with a local lock file so a later deploy sends only what you changed.
151
+
152
+ Options:
153
+ - `--revision <number>` — Exact published source revision; defaults to the current one.
50
154
 
51
155
  Examples:
52
- - `npx --package @notis_ai/cli@latest -- notis apps list`
53
- - `npx --package @notis_ai/cli@latest -- notis apps list --json`
156
+ - `npx --package @notis_ai/cli@latest -- notis spaces pull <space-id> ./space-source`
54
157
 
55
- ### `npx --package @notis_ai/cli@latest -- notis apps init <name> [dir]`
158
+ ### `npx --package @notis_ai/cli@latest -- notis spaces verify [dir]`
56
159
 
57
- Scaffold a new Notis app project.
160
+ Render one frozen Space with offline fixtures and validate its current action authorizations.
58
161
 
59
- When to use: Start a new Notis app. Use --from with a published Store app when one is close to the desired app; otherwise creates the bare Vite + React project.
162
+ When to use: Check immutable build bytes and authoring compatibility without executing actions or publishing.
60
163
 
61
164
  Options:
62
- - `--from <slug>` — Start from a published Store app listed by `notis apps scaffolds list`. Downloads its source from the public app registry.
165
+ - `--space <key>` — Exact source key from the workspace index.
166
+ - `--space-id <id>` — Exact existing destination Space.
167
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
168
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
63
169
 
64
170
  Examples:
65
- - `npx --package @notis_ai/cli@latest -- notis apps scaffolds list`
66
- - `npx --package @notis_ai/cli@latest -- notis apps init "Mind the Flo"`
67
- - `npx --package @notis_ai/cli@latest -- notis apps init "My CRM" --from databases`
68
- - `npx --package @notis_ai/cli@latest -- notis apps init "My App" ~/code/my-app`
171
+ - `npx --package @notis_ai/cli@latest -- notis spaces verify . --space overview --space-id <space-id>`
69
172
 
70
- ### `npx --package @notis_ai/cli@latest -- notis apps scaffolds list`
173
+ ### `npx --package @notis_ai/cli@latest -- notis spaces preview [dir]`
71
174
 
72
- List published Store apps available as scaffolds.
175
+ Seal a checked unpublished revision of the same Space and return its authenticated preview link.
73
176
 
74
- When to use: Discover published Store apps to start from before creating a new app. Every app published to the public Store is automatically a scaffold; use --search to narrow the catalog.
177
+ When to use: Review a checked candidate using current Editor access without changing live source or cloning the Space.
75
178
 
76
179
  Options:
77
- - `--search <term>` — Filter scaffolds by name, tagline, description, or category.
180
+ - `--space <key>` — Exact source key from the workspace index.
181
+ - `--space-id <id>` — Exact existing destination Space.
182
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
183
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
184
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
185
+ - `--dry-run` — Validate without uploading or publishing.
78
186
 
79
187
  Examples:
80
- - `npx --package @notis_ai/cli@latest -- notis apps scaffolds list`
81
- - `npx --package @notis_ai/cli@latest -- notis apps scaffolds list --search journal`
82
- - `npx --package @notis_ai/cli@latest -- notis apps init "My App" --from databases`
188
+ - `npx --package @notis_ai/cli@latest -- notis spaces preview . --space overview --space-id <space-id> --request-id release-1`
83
189
 
84
- ### `npx --package @notis_ai/cli@latest -- notis apps create <name> [dir]`
190
+ ### `npx --package @notis_ai/cli@latest -- notis spaces deploy [dir]`
85
191
 
86
- Create a new remote Notis app and optionally link a local project to it.
192
+ Publish one built Space with a retry-safe, independent source revision.
87
193
 
88
- When to use: Provision a fresh remote app before the first deploy. Pass a project directory to link it immediately.
194
+ When to use: Update only the selected existing Space; this does not publish to the Store or change siblings.
89
195
 
90
196
  Options:
91
- - `--team-id <id>` — Create or reuse the exact team-scoped app (default: personal).
197
+ - `--space <key>` — Exact source key from the workspace index.
198
+ - `--space-id <id>` — Exact existing destination Space.
199
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
200
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
201
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
202
+ - `--dry-run` — Validate without uploading or publishing.
203
+
204
+ Examples:
205
+ - `npx --package @notis_ai/cli@latest -- notis spaces deploy . --space overview --space-id <space-id> --request-id release-1`
206
+
207
+ ### `npx --package @notis_ai/cli@latest -- notis spaces promote <release-id> [dir]`
208
+
209
+ Publish the exact sealed Space revision, with its pending Skill and link changes, after current permission and concurrency checks.
210
+
211
+ When to use: Finish a reviewed preview without rebuilding or substituting a different candidate. The Skill edits, new Skills and list changes the preview carried go live in the same transaction.
212
+
213
+ Examples:
214
+ - `npx --package @notis_ai/cli@latest -- notis spaces promote <release-id>`
215
+
216
+ ### `npx --package @notis_ai/cli@latest -- notis spaces abandon <release-id>`
217
+
218
+ Close an unpublished Space preview without changing its live source, Skills or links, or deleting action history.
219
+
220
+ When to use: Stop using a candidate while preserving live source and completed effects.
92
221
 
93
222
  Examples:
94
- - `npx --package @notis_ai/cli@latest -- notis apps create "My App"`
95
- - `npx --package @notis_ai/cli@latest -- notis apps create "My App" .`
223
+ - `npx --package @notis_ai/cli@latest -- notis spaces abandon <release-id>`
96
224
 
97
- ### `npx --package @notis_ai/cli@latest -- notis apps build [dir]`
225
+ ### `npx --package @notis_ai/cli@latest -- notis spaces list`
98
226
 
99
- Build and package the app into .notis/output/.
227
+ List Spaces currently available to your account.
100
228
 
101
- When to use: Prepare the app for verification or deployment.
229
+ When to use: Discover accessible Spaces without exposing an issuer-wide resource catalogue.
102
230
 
103
231
  Examples:
104
- - `npx --package @notis_ai/cli@latest -- notis apps build`
105
- - `npx --package @notis_ai/cli@latest -- notis apps build ./my-app`
232
+ - `npx --package @notis_ai/cli@latest -- notis spaces list`
106
233
 
107
- ### `npx --package @notis_ai/cli@latest -- notis apps verify [dir]`
234
+ ### `npx --package @notis_ai/cli@latest -- notis spaces get <space-id>`
108
235
 
109
- Validate that every route renders and reports Store listing readiness.
236
+ Read one accessible Space and its scoped resources.
110
237
 
111
- When to use: Any time after notis apps build, and before deploy. Catches render-time crashes and missing runtime calls. Incomplete listing media is reported as a warning; pass --listing to fail on it instead.
238
+ When to use: Inspect the current published revision and named capabilities before executing.
112
239
 
113
240
  Options:
114
- - `--routes <slugs>` — Comma-separated route slugs. Default: every route in manifest.
115
- - `--port <n>` — Loopback port. Default: auto-pick.
116
- - `--skip-build` — Skip notis apps build; reuse existing .notis/output/.
117
- - `--mode <mode>` — stub | live. Default stub. Live posts to /portal_views/runtime_query with the CLI JWT and fails routes whose runtime calls all errored.
118
- - `--listing` — Fail instead of warn when the Store listing (tagline, categories, screenshots, changelog) is incomplete.
119
- - `--no-browser` — Start the harness server and print URLs; do not drive agent-browser.
120
- - `--keep-open` — Leave server + browser session running after report (for manual triage).
241
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
121
242
 
122
243
  Examples:
123
- - `npx --package @notis_ai/cli@latest -- notis apps verify`
124
- - `npx --package @notis_ai/cli@latest -- notis apps verify --routes notes`
125
- - `npx --package @notis_ai/cli@latest -- notis apps verify --mode live`
126
- - `npx --package @notis_ai/cli@latest -- notis apps verify --listing # gate on Store listing readiness before publish`
127
- - `npx --package @notis_ai/cli@latest -- notis apps verify --no-browser # start the harness, drive agent-browser yourself`
244
+ - `npx --package @notis_ai/cli@latest -- notis spaces get <space-id>`
128
245
 
129
- ### `npx --package @notis_ai/cli@latest -- notis apps screenshot [dir]`
246
+ ### `npx --package @notis_ai/cli@latest -- notis spaces action <space-id> <action-id>`
130
247
 
131
- Capture configured listing route/scenario states via the headless harness.
248
+ Execute a declared action using its saved authorization.
132
249
 
133
- When to use: Generate the 3–6 declared metadata/screenshot-N.png files for the App Store listing. Apps are icon-led (like Raycast) — there is no cover image, only these screenshots. Each screenshot may set a focus selector to remove empty canvas and a light or dark theme that also controls its Store frame. Run before notis apps verify / deploy / publish.
250
+ When to use: Use Space capabilities as the actual actor, with the saved issuer connection and payer.
134
251
 
135
252
  Options:
136
- - `--routes <slugs>` — Comma-separated route slugs. Default: every configured screenshot state.
137
- - `--port <n>` — Loopback port. Default: auto-pick.
138
- - `--width <px>` — Viewport width. Default: 2000.
139
- - `--height <px>` — Viewport height. Default: 1250 (16:10).
140
- - `--output-dir <dir>` — Where to write screenshot-N.png. Default: metadata/.
141
- - `--mode <mode>` — stub | live. Default stub. Live renders against real data via the CLI JWT (requires a linked app), so screenshots show actual content instead of empty states.
142
- - `--raw` — Write the unframed harness capture instead of the default Store presentation.
143
- - `--skip-build` — Skip notis apps build; reuse existing .notis/output/.
253
+ - `--revision <number>` — Exact published source revision.
254
+ - `--preview-release <id>` — Exact sealed candidate ID; requires current Editor access.
255
+ - `--schema-revision <number>` — Native schema revision; required for native row writes.
256
+ - `--inputs <json>` — Declared action input values; defaults to {}.
257
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
258
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
259
+ - `--dry-run` — Validate current access and action inputs without executing or billing.
144
260
 
145
261
  Examples:
146
- - `npx --package @notis_ai/cli@latest -- notis apps screenshot # honors notis.config.ts screenshot scenarios`
147
- - `npx --package @notis_ai/cli@latest -- notis apps screenshot --routes home,history`
148
- - `npx --package @notis_ai/cli@latest -- notis apps screenshot --mode live # populated screenshots from real data`
149
- - `npx --package @notis_ai/cli@latest -- notis apps screenshot --raw # diagnostic capture without Store framing`
262
+ - `npx --package @notis_ai/cli@latest -- notis spaces action <space-id> refresh --revision 1 --inputs '{}' --request-id refresh-1 --dry-run`
150
263
 
151
- ### `npx --package @notis_ai/cli@latest -- notis apps link <app-id> [dir]`
264
+ ### `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> <operation>`
152
265
 
153
- Link a local project to a remote Notis app.
266
+ Run one declared viewer read as yourself.
154
267
 
155
- When to use: Connect a local project to an existing app for deployment.
268
+ When to use: Check what an explorer Space shows you: the databases or Skills you can open, with your own access and never an issuer grant.
156
269
 
157
270
  Options:
158
- - `--expected-version <version>` — Link only if the remote deployment version still matches this non-negative integer.
271
+ - `--revision <number>` — Exact published source revision.
272
+ - `--preview-release <id>` — Exact sealed candidate ID; requires current Editor access.
273
+ - `--input <json>` — Read input, e.g. {"database_id":"<id>"}; defaults to {}.
274
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
159
275
 
160
276
  Examples:
161
- - `npx --package @notis_ai/cli@latest -- notis apps link abc123`
162
- - `npx --package @notis_ai/cli@latest -- notis apps link abc123 ./my-app`
163
- - `npx --package @notis_ai/cli@latest -- notis apps link abc123 ./recovered-app --expected-version 0`
277
+ - `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> list_databases --revision 3`
278
+ - `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> query_database --revision 3 --input '{"database_id":"<id>","request":{"page_size":20}}'`
164
279
 
165
- ### `npx --package @notis_ai/cli@latest -- notis apps pull <app-id> [dir]`
280
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants list <space-id>`
166
281
 
167
- Download a Notis app source snapshot into a local project folder.
282
+ Inspect authorization records for a Space you can edit.
168
283
 
169
- When to use: Edit an installed app. Preserve local edits, pull and link its persisted source, then build, verify and deploy.
284
+ When to use: Inspect issuers and exact constraints without exposing connection secrets.
170
285
 
171
286
  Options:
172
- - `--force` — Overwrite a non-empty target directory.
173
- - `--source-version <n>` — Pull a specific app source version (default: latest).
287
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
174
288
 
175
289
  Examples:
176
- - `npx --package @notis_ai/cli@latest -- notis apps pull abc123`
177
- - `npx --package @notis_ai/cli@latest -- notis apps pull abc123 ./my-app --force --source-version 3`
290
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants list <space-id>`
178
291
 
179
- ### `npx --package @notis_ai/cli@latest -- notis apps deploy [dir]`
292
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants create <space-id>`
180
293
 
181
- Build, verify and release the linked Workspace app.
294
+ Authorize an exact template using your current connection.
182
295
 
183
- When to use: Build, verify and release the linked personal or team Workspace app. This command does not publish to the Store.
296
+ When to use: Create a Space-bound authorization; the server resolves the signed-in issuer connection.
184
297
 
185
298
  Options:
186
- - `--app-id <id>` — Override linked app ID.
187
- - `--skip-build` — Reuse unchanged build output; automated verification still runs.
299
+ - `--template <file>` — Canonical action template JSON file.
300
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
301
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
302
+ - `--dry-run` — Validate the template and Editor access without creating a grant.
303
+
304
+ Examples:
305
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants create <space-id> --template action.json --request-id grant-1 --dry-run`
306
+
307
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants revoke <grant-id>`
308
+
309
+ Revoke one saved Space authorization.
310
+
311
+ When to use: Stop future dispatches for an authorization you issued or can administer.
188
312
 
189
313
  Examples:
314
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants revoke <grant-id>`
190
315
 
191
- ### `npx --package @notis_ai/cli@latest -- notis apps publish [dir]`
316
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store list`
192
317
 
193
- Submit the deployed app for Store review.
318
+ List Space Store listings you can see.
194
319
 
195
- When to use: After the user explicitly confirms the App Details page and Store listing are ready. Requires the current local project to match the latest deployed version.
320
+ When to use: Find Space templates published to your team or approved for everyone, and your own listings.
196
321
 
197
322
  Options:
198
- - `--app-id <id>` — Override linked app ID.
199
- - `--confirm-ready` — Confirm the user approved the current App Details page for Store submission.
323
+ - `--channel <team|public>` — Only one channel.
200
324
 
201
325
  Examples:
202
- - `npx --package @notis_ai/cli@latest -- notis apps publish --confirm-ready`
203
- - `npx --package @notis_ai/cli@latest -- notis apps publish ./my-app --confirm-ready`
326
+ - `npx --package @notis_ai/cli@latest -- notis spaces store list --channel team`
204
327
 
205
- ### `npx --package @notis_ai/cli@latest -- notis apps duplicate [dir]`
328
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store get <listing-id>`
206
329
 
207
- Duplicate an app into an independent copy with its own databases.
330
+ Read one Store listing with its versions and your installs.
208
331
 
209
- When to use: When the same app should run for a second purpose - a notes app for blog drafts alongside one for bookmarks. The copy shares no data with the source.
332
+ When to use: Check what a listing contains, its review state and whether your copies have an update.
333
+
334
+ Examples:
335
+ - `npx --package @notis_ai/cli@latest -- notis spaces store get <listing-id>`
336
+
337
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store installs`
338
+
339
+ List the Spaces you installed from the Store.
340
+
341
+ When to use: See which installed copies have an update or conflicts to resolve.
342
+
343
+ Examples:
344
+ - `npx --package @notis_ai/cli@latest -- notis spaces store installs`
345
+
346
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store publish <space-id>`
347
+
348
+ Publish a Space and its sub-Spaces as the next Store version.
349
+
350
+ When to use: Share a Space as an installable template: team listings publish at once, public ones wait for review.
210
351
 
211
352
  Options:
212
- - `--app-id <id>` — App to duplicate. Defaults to the app this project is linked to.
213
- - `--name <name>` — Name for the duplicate (default: the source name followed by "copy").
214
- - `--copy-documents <mode>` — Which rows to copy: 'declared' (default, the starter content a fresh install would have), 'all', or 'none'.
353
+ - `--channel <team|public>` — Where to publish.
354
+ - `--metadata <json>` — Listing name, tagline, description, category, icon, accent.
355
+ - `--starter <json>` — Starter row IDs per database ({"<database-id>":["<record-key>"]}).
356
+ - `--notes <text>` — Release notes for this version.
357
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
358
+ - `--dry-run` — Show the package counts and review diff without publishing.
215
359
 
216
360
  Examples:
217
- - `npx --package @notis_ai/cli@latest -- notis apps duplicate --name "Blog"`
218
- - `npx --package @notis_ai/cli@latest -- notis apps duplicate --app-id abc123 --name "Bookmarks" --copy-documents none`
361
+ - `npx --package @notis_ai/cli@latest -- notis spaces store publish <space-id> --channel team --request-id publish-1 --dry-run`
362
+
363
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store install <listing-id>`
219
364
 
220
- ### `npx --package @notis_ai/cli@latest -- notis apps doctor [dir]`
365
+ Install a Store listing as your own independent copy.
221
366
 
222
- Check project health and readiness.
367
+ When to use: Add a published Space template to your account; your copy keeps your changes on later updates.
223
368
 
224
- When to use: Diagnose issues with a Notis app project.
369
+ Options:
370
+ - `--name <name>` — Name of the installed top Space.
371
+ - `--parent <space-id>` — Install under one of your Spaces.
372
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
373
+ - `--dry-run` — Show what the copy contains without installing.
225
374
 
226
375
  Examples:
227
- - `npx --package @notis_ai/cli@latest -- notis apps doctor`
228
- - `npx --package @notis_ai/cli@latest -- notis apps doctor ./my-app`
376
+ - `npx --package @notis_ai/cli@latest -- notis spaces store install <listing-id> --request-id install-1`
229
377
 
230
- ### `npx --package @notis_ai/cli@latest -- notis reports init <name> [dir]`
378
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id>`
231
379
 
232
- Init a standalone live SDK report.
380
+ Update an installed copy, keeping your changes, or resolve its conflicts.
233
381
 
234
- When to use: Author a private standalone document using the shared view runtime; no app or database is required.
382
+ When to use: Take a newer Store version: unchanged parts update, your edits stay, and parts both sides changed become conflicts you resolve.
383
+
384
+ Options:
385
+ - `--resolve <json>` — Per conflict key: "keep_mine" or "take_theirs".
386
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
387
+ - `--dry-run` — Show the three-way plan without changing anything.
235
388
 
236
389
  Examples:
237
- - `npx --package @notis_ai/cli@latest -- notis reports init "Weekly report" ./weekly-report`
390
+ - `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id> --request-id update-1 --dry-run`
391
+ - `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id> --resolve '{"skill:<key>":"keep_mine"}' --request-id resolve-1`
392
+
393
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store unpublish <listing-id>`
238
394
 
239
- ### `npx --package @notis_ai/cli@latest -- notis reports build [dir]`
395
+ Stop new installs of a Store listing.
240
396
 
241
- Build a standalone live SDK report.
397
+ When to use: Withdraw a listing: existing copies keep working and a version waiting for review is withdrawn.
242
398
 
243
- When to use: Author a private standalone document using the shared view runtime; no app or database is required.
399
+ Options:
400
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
401
+
402
+ Examples:
403
+ - `npx --package @notis_ai/cli@latest -- notis spaces store unpublish <listing-id> --request-id unpublish-1`
404
+
405
+ ### `npx --package @notis_ai/cli@latest -- notis spaces build [dir]`
406
+
407
+ Build one independent Space and save its frozen source/artifact snapshot.
408
+
409
+ When to use: Prepare a selected Space for verification without publishing it or changing siblings.
410
+
411
+ Options:
412
+ - `--space <key>` — Exact source key from the workspace Space index.
244
413
 
245
414
  Examples:
246
- - `npx --package @notis_ai/cli@latest -- notis reports build ./weekly-report`
415
+ - `npx --package @notis_ai/cli@latest -- notis spaces build . --space overview`
247
416
 
248
- ### `npx --package @notis_ai/cli@latest -- notis reports verify [dir]`
417
+ ### `npx --package @notis_ai/cli@latest -- notis spaces inspect [dir]`
249
418
 
250
- Verify a standalone live SDK report.
419
+ Inspect one local Space definition and its declared capabilities.
251
420
 
252
- When to use: Author a private standalone document using the shared view runtime; no app or database is required.
421
+ When to use: Read the selected source definition without loading sibling definitions or account resources.
253
422
 
254
423
  Options:
255
- - `--routes <slugs>` — Comma-separated route slugs. Default: every route in manifest.
256
- - `--port <n>` — Loopback port. Default: auto-pick.
257
- - `--skip-build` — Skip notis apps build; reuse existing .notis/output/.
258
- - `--mode <mode>` — stub | live. Default stub. Live posts to /portal_views/runtime_query with the CLI JWT and fails routes whose runtime calls all errored.
259
- - `--no-browser` — Start the harness server and print URLs; do not drive agent-browser.
260
- - `--keep-open` — Leave server + browser session running after report (for manual triage).
261
- - `--document-id <id>` — Saved report for live verification.
262
- - `--expected-revision <revision>` — Saved report revision for live verification.
424
+ - `--space <key>` — Exact source key from the workspace Space index.
263
425
 
264
426
  Examples:
265
- - `npx --package @notis_ai/cli@latest -- notis reports verify ./weekly-report`
427
+ - `npx --package @notis_ai/cli@latest -- notis spaces inspect . --space overview`
266
428
 
267
- ### `npx --package @notis_ai/cli@latest -- notis reports preview [dir]`
429
+ ### `npx --package @notis_ai/cli@latest -- notis views find`
268
430
 
269
- Preview a standalone live SDK report.
431
+ Find the views you can open for a record, database, view link, Space or search.
270
432
 
271
- When to use: Author a private standalone document using the shared view runtime; no app or database is required.
433
+ When to use: Get fresh view-qualified links and declared URL parameters before citing or opening a view.
272
434
 
273
435
  Options:
274
- - `--routes <slugs>` — Comma-separated route slugs. Default: every route in manifest.
275
- - `--port <n>` — Loopback port. Default: auto-pick.
276
- - `--skip-build` — Skip notis apps build; reuse existing .notis/output/.
277
- - `--mode <mode>` — stub | live. Default stub. Live posts to /portal_views/runtime_query with the CLI JWT and fails routes whose runtime calls all errored.
278
- - `--no-browser` — Start the harness server and print URLs; do not drive agent-browser.
279
- - `--keep-open` — Leave server + browser session running after report (for manual triage).
280
- - `--document-id <id>` — Saved report for live verification.
281
- - `--expected-revision <revision>` — Saved report revision for live verification.
436
+ - `--record-key <id>` — Find views that show this exact native record.
437
+ - `--database-id <id>` — Find views over this database.
438
+ - `--url <url>` — Resolve this view link and its current parameters.
439
+ - `--space-id <id>` — Describe this Space view.
440
+ - `--query <text>` — Search accessible view names, descriptions and readable context.
282
441
 
283
442
  Examples:
284
- - `npx --package @notis_ai/cli@latest -- notis reports preview ./weekly-report`
443
+ - `npx --package @notis_ai/cli@latest -- notis views find --record-key <record-key>`
444
+ - `npx --package @notis_ai/cli@latest -- notis views find --url <view-link>`
445
+ - `npx --package @notis_ai/cli@latest -- notis views find --query inbox`
285
446
 
286
- ### `npx --package @notis_ai/cli@latest -- notis reports save [dir]`
447
+ ### `npx --package @notis_ai/cli@latest -- notis views render <url>`
287
448
 
288
- Build, verify and save a standalone live report document.
449
+ Render a live view as Markdown and a full-height PNG with your current access.
289
450
 
290
- When to use: Persist an independently owned report, not an app release.
451
+ When to use: Check the actual deployed view; writes are blocked and current access is checked again before any output is saved.
291
452
 
292
453
  Options:
293
- - `--document-id <id>` — Existing report document to update.
294
- - `--expected-revision <revision>` — Current saved report revision; required for updates.
295
- - `--title <title>` — Required, including updates. Document title.
296
- - `--context-file <file>` — Required. UTF-8 readable report content and structure.
454
+ - `--outputs <kinds>` — Comma-separated markdown,screenshot (default both).
455
+ - `--width <pixels>` — 1440 (default) or 390.
456
+ - `--output-dir <path>` — New output directory; defaults to a unique .notis/renders directory. Existing files are never overwritten.
297
457
 
298
458
  Examples:
299
- - `npx --package @notis_ai/cli@latest -- notis reports save ./weekly-report --title "Weekly review" --context-file ./context.md`
459
+ - `npx --package @notis_ai/cli@latest -- notis views render <view-link> --outputs markdown,screenshot`