@notis_ai/cli 0.2.18 → 0.2.20

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 (395) hide show
  1. package/README.md +542 -146
  2. package/bin/check-runtime.js +15 -0
  3. package/bin/notis.js +2 -0
  4. package/config/notis_app_design_rules.json +320 -0
  5. package/config/portal-route-roots.json +45 -0
  6. package/dist/agent-hooks/notis-agent-hook.mjs +42325 -18273
  7. package/dist/base-skills/notis-cli/.notis-base-skill.json +1 -0
  8. package/dist/base-skills/notis-cli/SKILL.md +51 -280
  9. package/dist/base-skills/notis-cli/references/app-delivery.md +17 -0
  10. package/dist/base-skills/notis-cli/references/intelligence.md +94 -0
  11. package/dist/base-skills/notis-cli/references/native-databases.md +21 -0
  12. package/dist/base-skills/notis-cli/references/tool-examples.md +56 -0
  13. package/dist/base-skills/notis-cli/references/troubleshooting.md +67 -0
  14. package/dist/base-skills/notis-query/.notis-base-skill.json +1 -0
  15. package/dist/base-skills/notis-query/SKILL.md +35 -699
  16. package/dist/base-skills/notis-query/references/database-discovery.md +59 -0
  17. package/dist/base-skills/notis-query/references/documents.md +74 -0
  18. package/dist/base-skills/notis-query/references/query.md +76 -0
  19. package/dist/base-skills/notis-spaces/.notis-base-skill.json +1 -0
  20. package/dist/base-skills/notis-spaces/SKILL.md +218 -0
  21. package/dist/base-skills/notis-spaces/references/architecture.md +116 -0
  22. package/dist/base-skills/notis-spaces/references/context.md +81 -0
  23. package/dist/base-skills/notis-spaces/references/design.md +141 -0
  24. package/dist/base-skills/notis-spaces/references/fixtures.md +29 -0
  25. package/dist/base-skills/notis-spaces/references/memory.md +58 -0
  26. package/dist/base-skills/notis-spaces/references/reading.md +73 -0
  27. package/dist/base-skills/notis-spaces/references/release.md +120 -0
  28. package/dist/base-skills/notis-spaces/references/reports.md +77 -0
  29. package/dist/base-skills/notis-spaces/references/sdk.md +273 -0
  30. package/dist/base-skills/notis-spaces/references/store.md +118 -0
  31. package/dist/base-skills/notis-spaces/references/troubleshooting.md +28 -0
  32. package/dist/base-skills/notis-spaces/references/views.md +229 -0
  33. package/{template/packages → dist}/sdk/package.json +9 -10
  34. package/dist/sdk/src/agentContext.ts +36 -0
  35. package/dist/sdk/src/bundleModule.ts +175 -0
  36. package/dist/sdk/src/components/Dialog.tsx +103 -0
  37. package/dist/sdk/src/components/DocumentEditor.tsx +113 -0
  38. package/dist/sdk/src/components/DocumentPage.tsx +184 -0
  39. package/{template/packages → dist}/sdk/src/components/Markdown.tsx +9 -3
  40. package/{template/packages → dist}/sdk/src/components/MarkdownEditor.tsx +26 -5
  41. package/{template/packages → dist}/sdk/src/components/MultiSelectActionBar.tsx +95 -12
  42. package/{template/packages → dist}/sdk/src/components/MultiSelectCheckbox.tsx +4 -2
  43. package/dist/sdk/src/components/NotisCommentBoundary.tsx +172 -0
  44. package/{template/packages → dist}/sdk/src/components/NotisSelectionBoundary.tsx +9 -5
  45. package/dist/sdk/src/components/RecordComponents.tsx +111 -0
  46. package/dist/sdk/src/components/Skeleton.tsx +38 -0
  47. package/dist/sdk/src/config.ts +31 -0
  48. package/{template/packages → dist}/sdk/src/documents.ts +21 -6
  49. package/dist/sdk/src/hooks/useAction.ts +28 -0
  50. package/dist/sdk/src/hooks/useAgentContext.ts +23 -0
  51. package/{template/packages → dist}/sdk/src/hooks/useBackend.ts +3 -2
  52. package/dist/sdk/src/hooks/useCloudComputer.ts +94 -0
  53. package/dist/sdk/src/hooks/useCloudComputerShell.ts +114 -0
  54. package/{template/packages → dist}/sdk/src/hooks/useCollectionInteractions.ts +157 -147
  55. package/dist/sdk/src/hooks/useDatabaseSchema.ts +50 -0
  56. package/{template/packages → dist}/sdk/src/hooks/useDatabaseSubscription.ts +2 -2
  57. package/dist/sdk/src/hooks/useDocument.ts +51 -0
  58. package/{template/packages → dist}/sdk/src/hooks/useDocuments.ts +25 -59
  59. package/{template/packages → dist}/sdk/src/hooks/useHandover.ts +7 -7
  60. package/dist/sdk/src/hooks/useLongPressSelection.ts +79 -0
  61. package/dist/sdk/src/hooks/useMarqueeSelection.ts +194 -0
  62. package/{template/packages → dist}/sdk/src/hooks/useMultiSelect.ts +2 -8
  63. package/dist/sdk/src/hooks/useNativeDocumentBody.ts +50 -0
  64. package/dist/sdk/src/hooks/useNativeDocuments.ts +143 -0
  65. package/{template/packages → dist}/sdk/src/hooks/useNotis.ts +6 -1
  66. package/dist/sdk/src/hooks/useNotisNavigation.ts +70 -0
  67. package/dist/sdk/src/hooks/useQuery.ts +81 -0
  68. package/dist/sdk/src/hooks/useToolQuery.ts +12 -0
  69. package/dist/sdk/src/hooks/useTopBarSearch.ts +102 -0
  70. package/dist/sdk/src/hooks/useTopBarTitleLeaf.ts +75 -0
  71. package/{template/packages → dist}/sdk/src/hooks/useUpsertDocument.ts +1 -1
  72. package/dist/sdk/src/hooks/useViewParams.ts +195 -0
  73. package/dist/sdk/src/hooks/useViewerReads.ts +129 -0
  74. package/{template/packages → dist}/sdk/src/index.ts +64 -1
  75. package/{template/packages → dist}/sdk/src/interactions/actions.ts +14 -1
  76. package/{template/packages → dist}/sdk/src/interactions/shortcuts.tsx +129 -23
  77. package/dist/sdk/src/interactions/visibility.ts +13 -0
  78. package/{template/packages → dist}/sdk/src/interactions.ts +5 -1
  79. package/dist/sdk/src/nativeData.ts +39 -0
  80. package/{template/packages → dist}/sdk/src/provider.tsx +9 -4
  81. package/dist/sdk/src/queryCache.ts +292 -0
  82. package/dist/sdk/src/queryErrors.ts +51 -0
  83. package/dist/sdk/src/runtime.ts +675 -0
  84. package/dist/sdk/src/runtimeModules.ts +33 -0
  85. package/dist/sdk/src/space.ts +442 -0
  86. package/dist/sdk/src/standardViewParams.ts +36 -0
  87. package/{template/packages → dist}/sdk/src/styles.css +81 -16
  88. package/dist/sdk/src/tailwind.ts +66 -0
  89. package/dist/sdk/src/ui/charts/RenderChartData.tsx +25 -0
  90. package/dist/sdk/src/ui/engine/core.ts +392 -0
  91. package/dist/sdk/src/ui/engine/dom.ts +183 -0
  92. package/dist/sdk/src/ui/engine/hooks.ts +195 -0
  93. package/dist/sdk/src/ui/engine/instance.ts +63 -0
  94. package/dist/sdk/src/ui/engine/keycapContext.ts +2 -0
  95. package/dist/sdk/src/ui/engine/registry.ts +262 -0
  96. package/dist/sdk/src/ui/engine/types.ts +62 -0
  97. package/dist/sdk/src/ui/icons.tsx +91 -0
  98. package/dist/sdk/src/ui/util.ts +83 -0
  99. package/dist/sdk/src/viewPeriod.ts +26 -0
  100. package/dist/sdk/src/vite.ts +92 -0
  101. package/dist/sdk/src/words/actions.ts +295 -0
  102. package/dist/sdk/src/words/clashes.ts +158 -0
  103. package/dist/sdk/src/words/format.ts +136 -0
  104. package/dist/sdk/src/words/index.ts +13 -0
  105. package/dist/sdk/src/words/keymap.ts +72 -0
  106. package/dist/sdk/src/words/keys.ts +297 -0
  107. package/dist/sdk/src/words/shell.ts +46 -0
  108. package/dist/sdk/src/words/types.ts +65 -0
  109. package/dist/skill-sync/index.js +832 -151
  110. package/dist/skill-sync/index.js.map +4 -4
  111. package/dist/skill-sync-worker.mjs +3941 -0
  112. package/dist/space-harness/host.js +1460 -0
  113. package/dist/space-sdk/dist/chunk-ZSN57ATH.js +5 -0
  114. package/dist/space-sdk/dist/index.js +15 -0
  115. package/dist/space-sdk/dist/ui.js +18 -0
  116. package/dist/space-sdk/package.json +33 -0
  117. package/dist/space-sdk/src/agentContext.d.ts +36 -0
  118. package/dist/space-sdk/src/components/Dialog.d.ts +20 -0
  119. package/dist/space-sdk/src/components/DocumentEditor.d.ts +46 -0
  120. package/dist/space-sdk/src/components/DocumentPage.d.ts +53 -0
  121. package/dist/space-sdk/src/components/Markdown.d.ts +18 -0
  122. package/dist/space-sdk/src/components/MarkdownEditor.d.ts +11 -0
  123. package/dist/space-sdk/src/components/MultiSelectActionBar.d.ts +31 -0
  124. package/dist/space-sdk/src/components/MultiSelectCheckbox.d.ts +14 -0
  125. package/dist/space-sdk/src/components/MultiSelectDragOverlay.d.ts +8 -0
  126. package/dist/space-sdk/src/components/NotisCommentBoundary.d.ts +36 -0
  127. package/dist/space-sdk/src/components/NotisSelectionBoundary.d.ts +16 -0
  128. package/dist/space-sdk/src/components/RecordComponents.d.ts +64 -0
  129. package/dist/space-sdk/src/components/ShortcutHints.d.ts +12 -0
  130. package/dist/space-sdk/src/components/Skeleton.d.ts +23 -0
  131. package/dist/space-sdk/src/config.ts +31 -0
  132. package/dist/space-sdk/src/documents.d.ts +59 -0
  133. package/dist/space-sdk/src/hooks/useAction.d.ts +8 -0
  134. package/dist/space-sdk/src/hooks/useActiveResource.d.ts +3 -0
  135. package/dist/space-sdk/src/hooks/useAgentContext.d.ts +7 -0
  136. package/dist/space-sdk/src/hooks/useBackend.d.ts +23 -0
  137. package/dist/space-sdk/src/hooks/useCloudComputer.d.ts +45 -0
  138. package/dist/space-sdk/src/hooks/useCloudComputerShell.d.ts +49 -0
  139. package/dist/space-sdk/src/hooks/useCollectionInteractions.d.ts +118 -0
  140. package/dist/space-sdk/src/hooks/useDatabaseSchema.d.ts +14 -0
  141. package/dist/space-sdk/src/hooks/useDatabaseSubscription.d.ts +26 -0
  142. package/dist/space-sdk/src/hooks/useDocument.d.ts +22 -0
  143. package/dist/space-sdk/src/hooks/useDocuments.d.ts +31 -0
  144. package/dist/space-sdk/src/hooks/useHandover.d.ts +43 -0
  145. package/dist/space-sdk/src/hooks/useLongPressSelection.d.ts +9 -0
  146. package/dist/space-sdk/src/hooks/useMarqueeSelection.d.ts +57 -0
  147. package/dist/space-sdk/src/hooks/useMultiSelect.d.ts +51 -0
  148. package/dist/space-sdk/src/hooks/useNativeDocumentBody.d.ts +24 -0
  149. package/dist/space-sdk/src/hooks/useNativeDocuments.d.ts +55 -0
  150. package/dist/space-sdk/src/hooks/useNotis.d.ts +25 -0
  151. package/dist/space-sdk/src/hooks/useNotisNavigation.d.ts +33 -0
  152. package/dist/space-sdk/src/hooks/useQuery.d.ts +22 -0
  153. package/dist/space-sdk/src/hooks/useTool.d.ts +20 -0
  154. package/dist/space-sdk/src/hooks/useToolQuery.d.ts +3 -0
  155. package/dist/space-sdk/src/hooks/useTools.d.ts +15 -0
  156. package/dist/space-sdk/src/hooks/useTopBarSearch.d.ts +48 -0
  157. package/dist/space-sdk/src/hooks/useTopBarTitleLeaf.d.ts +24 -0
  158. package/dist/space-sdk/src/hooks/useUpsertDocument.d.ts +27 -0
  159. package/dist/space-sdk/src/hooks/useViewParams.d.ts +76 -0
  160. package/dist/space-sdk/src/hooks/useViewerReads.d.ts +38 -0
  161. package/dist/space-sdk/src/index.d.ts +98 -0
  162. package/dist/space-sdk/src/interactions/actions.d.ts +33 -0
  163. package/dist/space-sdk/src/interactions/shortcuts.d.ts +42 -0
  164. package/dist/space-sdk/src/interactions/visibility.d.ts +2 -0
  165. package/dist/space-sdk/src/nativeData.d.ts +66 -0
  166. package/dist/space-sdk/src/provider.d.ts +17 -0
  167. package/dist/space-sdk/src/queryCache.d.ts +45 -0
  168. package/dist/space-sdk/src/queryErrors.ts +51 -0
  169. package/dist/space-sdk/src/runtime.d.ts +615 -0
  170. package/dist/space-sdk/src/runtimeModules.ts +33 -0
  171. package/dist/space-sdk/src/space.ts +442 -0
  172. package/dist/space-sdk/src/standardViewParams.d.ts +15 -0
  173. package/dist/space-sdk/src/tailwind-candidates.d.ts +3418 -0
  174. package/dist/space-sdk/src/tailwind.ts +66 -0
  175. package/dist/space-sdk/src/ui/actions/ActionToast.d.ts +15 -0
  176. package/dist/space-sdk/src/ui/actions/actionWords.d.ts +16 -0
  177. package/dist/space-sdk/src/ui/actions/index.d.ts +7 -0
  178. package/dist/space-sdk/src/ui/actions/useActions.d.ts +69 -0
  179. package/dist/space-sdk/src/ui/actions/useToast.d.ts +41 -0
  180. package/dist/space-sdk/src/ui/blocks/Tabs.d.ts +139 -0
  181. package/dist/space-sdk/src/ui/blocks/blocks.d.ts +217 -0
  182. package/dist/space-sdk/src/ui/blocks/index.d.ts +4 -0
  183. package/dist/space-sdk/src/ui/board/BoardView.d.ts +36 -0
  184. package/dist/space-sdk/src/ui/board/boardModel.d.ts +46 -0
  185. package/dist/space-sdk/src/ui/board/boardWords.d.ts +9 -0
  186. package/dist/space-sdk/src/ui/board/index.d.ts +5 -0
  187. package/dist/space-sdk/src/ui/calendar/CalendarView.d.ts +49 -0
  188. package/dist/space-sdk/src/ui/calendar/DayPicker.d.ts +23 -0
  189. package/dist/space-sdk/src/ui/calendar/calendarMath.d.ts +81 -0
  190. package/dist/space-sdk/src/ui/charts/Chart.d.ts +203 -0
  191. package/dist/space-sdk/src/ui/charts/ChartTable.d.ts +37 -0
  192. package/dist/space-sdk/src/ui/charts/RenderChartData.d.ts +16 -0
  193. package/dist/space-sdk/src/ui/charts/StatRow.d.ts +59 -0
  194. package/dist/space-sdk/src/ui/charts/chartData.d.ts +84 -0
  195. package/dist/space-sdk/src/ui/comments/CommentPane.d.ts +58 -0
  196. package/dist/space-sdk/src/ui/comments/commentModel.d.ts +157 -0
  197. package/dist/space-sdk/src/ui/comments/commentWords.d.ts +60 -0
  198. package/dist/space-sdk/src/ui/comments/index.d.ts +4 -0
  199. package/dist/space-sdk/src/ui/comments/useComments.d.ts +146 -0
  200. package/dist/space-sdk/src/ui/engine/HelpSheet.d.ts +12 -0
  201. package/dist/space-sdk/src/ui/engine/KeyboardEngine.d.ts +27 -0
  202. package/dist/space-sdk/src/ui/engine/core.d.ts +73 -0
  203. package/dist/space-sdk/src/ui/engine/hooks.d.ts +64 -0
  204. package/dist/space-sdk/src/ui/engine/index.d.ts +14 -0
  205. package/dist/space-sdk/src/ui/engine/instance.d.ts +21 -0
  206. package/dist/space-sdk/src/ui/engine/keycapContext.d.ts +2 -0
  207. package/dist/space-sdk/src/ui/engine/registry.d.ts +77 -0
  208. package/dist/space-sdk/src/ui/engine/step.d.ts +11 -0
  209. package/dist/space-sdk/src/ui/engine/types.d.ts +54 -0
  210. package/dist/space-sdk/src/ui/fields/fieldWords.d.ts +56 -0
  211. package/dist/space-sdk/src/ui/fields/fields.d.ts +162 -0
  212. package/dist/space-sdk/src/ui/fields/index.d.ts +5 -0
  213. package/dist/space-sdk/src/ui/fields/useFieldDraft.d.ts +22 -0
  214. package/dist/space-sdk/src/ui/gallery/AttachmentGallery.d.ts +53 -0
  215. package/dist/space-sdk/src/ui/gallery/ImageViewer.d.ts +27 -0
  216. package/dist/space-sdk/src/ui/gallery/galleryWords.d.ts +95 -0
  217. package/dist/space-sdk/src/ui/gallery/index.d.ts +5 -0
  218. package/dist/space-sdk/src/ui/icons.d.ts +13 -0
  219. package/dist/space-sdk/src/ui/index.d.ts +54 -0
  220. package/dist/space-sdk/src/ui/keycap/Keycap.d.ts +22 -0
  221. package/dist/space-sdk/src/ui/keycap/index.d.ts +2 -0
  222. package/dist/space-sdk/src/ui/layout/Panels.d.ts +50 -0
  223. package/dist/space-sdk/src/ui/layout/chatPanelEdge.d.ts +77 -0
  224. package/dist/space-sdk/src/ui/layout/index.d.ts +5 -0
  225. package/dist/space-sdk/src/ui/layout/panelMath.d.ts +91 -0
  226. package/dist/space-sdk/src/ui/list/ListReader.d.ts +380 -0
  227. package/dist/space-sdk/src/ui/list/Row.d.ts +145 -0
  228. package/dist/space-sdk/src/ui/list/SelectionBar.d.ts +65 -0
  229. package/dist/space-sdk/src/ui/list/index.d.ts +14 -0
  230. package/dist/space-sdk/src/ui/list/rowState.d.ts +22 -0
  231. package/dist/space-sdk/src/ui/list/useListKeys.d.ts +89 -0
  232. package/dist/space-sdk/src/ui/list/useReorder.d.ts +86 -0
  233. package/dist/space-sdk/src/ui/list/useSelection.d.ts +90 -0
  234. package/dist/space-sdk/src/ui/open/OpenAsMenu.d.ts +15 -0
  235. package/dist/space-sdk/src/ui/open/index.d.ts +6 -0
  236. package/dist/space-sdk/src/ui/open/openModeStore.d.ts +39 -0
  237. package/dist/space-sdk/src/ui/open/useOpenMode.d.ts +17 -0
  238. package/dist/space-sdk/src/ui/overlay/Menu.d.ts +88 -0
  239. package/dist/space-sdk/src/ui/overlay/Popover.d.ts +28 -0
  240. package/dist/space-sdk/src/ui/overlay/Tooltip.d.ts +19 -0
  241. package/dist/space-sdk/src/ui/overlay/index.d.ts +9 -0
  242. package/dist/space-sdk/src/ui/overlay/layerRoot.d.ts +24 -0
  243. package/dist/space-sdk/src/ui/overlay/position.d.ts +31 -0
  244. package/dist/space-sdk/src/ui/period/PeriodPicker.d.ts +30 -0
  245. package/dist/space-sdk/src/ui/period/dateFormat.d.ts +50 -0
  246. package/dist/space-sdk/src/ui/period/dateWords.d.ts +88 -0
  247. package/dist/space-sdk/src/ui/period/periods.d.ts +70 -0
  248. package/dist/space-sdk/src/ui/period/usePeriod.d.ts +23 -0
  249. package/dist/space-sdk/src/ui/present/index.d.ts +3 -0
  250. package/dist/space-sdk/src/ui/present/presentWords.d.ts +27 -0
  251. package/dist/space-sdk/src/ui/present/screens.d.ts +36 -0
  252. package/dist/space-sdk/src/ui/present/useAudienceScreen.d.ts +38 -0
  253. package/dist/space-sdk/src/ui/styles.d.ts +21 -0
  254. package/dist/space-sdk/src/ui/timeline/TimelineView.d.ts +44 -0
  255. package/dist/space-sdk/src/ui/timeline/timelineMath.d.ts +123 -0
  256. package/dist/space-sdk/src/viewPeriod.d.ts +8 -0
  257. package/dist/space-sdk/src/vite.ts +92 -0
  258. package/dist/space-sdk/src/words/actions.ts +295 -0
  259. package/dist/space-sdk/src/words/clashes.ts +158 -0
  260. package/dist/space-sdk/src/words/format.ts +136 -0
  261. package/dist/space-sdk/src/words/index.ts +13 -0
  262. package/dist/space-sdk/src/words/keymap.ts +72 -0
  263. package/dist/space-sdk/src/words/keys.ts +297 -0
  264. package/dist/space-sdk/src/words/shell.ts +46 -0
  265. package/dist/space-sdk/src/words/types.ts +65 -0
  266. package/dist/view-renderer/dist/host.css +1 -0
  267. package/dist/view-renderer/dist/host.js +2374 -0
  268. package/dist/view-renderer/dist/theme.css +73 -0
  269. package/dist/view-renderer/src/dom.js +212 -0
  270. package/dist/view-renderer/src/errors.js +8 -0
  271. package/dist/view-renderer/src/host.tsx +250 -0
  272. package/dist/view-renderer/src/index.js +4 -0
  273. package/dist/view-renderer/src/png.js +213 -0
  274. package/dist/view-renderer/src/pool.js +110 -0
  275. package/dist/view-renderer/src/remote-broker.js +59 -0
  276. package/dist/view-renderer/src/renderer.js +279 -0
  277. package/package.json +21 -11
  278. package/skills/notis-cli/AGENT_INSTRUCTIONS.md +63 -12
  279. package/skills/notis-onboarding/BRIEF.md +14 -9
  280. package/skills/notis-query/cli.md +1 -1
  281. package/skills/notis-spaces/cli.md +540 -0
  282. package/src/cli.js +8 -8
  283. package/src/command-specs/agents.js +121 -8
  284. package/src/command-specs/auth.js +3 -3
  285. package/src/command-specs/diagnostics.js +97 -20
  286. package/src/command-specs/documents.js +158 -0
  287. package/src/command-specs/files.js +29 -0
  288. package/src/command-specs/handover.js +331 -79
  289. package/src/command-specs/helpers.js +50 -40
  290. package/src/command-specs/index.js +14 -5
  291. package/src/command-specs/meta.js +38 -9
  292. package/src/command-specs/onboarding.js +1 -1
  293. package/src/command-specs/profile.js +42 -1
  294. package/src/command-specs/skills.js +314 -9
  295. package/src/command-specs/smoke.js +16 -4
  296. package/src/command-specs/spaces.js +783 -0
  297. package/src/command-specs/tools.js +118 -21
  298. package/src/command-specs/version-history.js +20 -0
  299. package/src/command-specs/views.js +69 -0
  300. package/src/runtime/agent-browser.js +178 -267
  301. package/src/runtime/agent-setup.js +172 -13
  302. package/src/runtime/app-boundary-validator.js +338 -2
  303. package/src/runtime/app-data-literals.js +82 -0
  304. package/src/runtime/app-platform.js +750 -1570
  305. package/src/runtime/auth-recovery.js +17 -0
  306. package/src/runtime/base-skills.d.ts +11 -0
  307. package/src/runtime/base-skills.js +100 -3
  308. package/src/runtime/computer-identity.d.ts +30 -0
  309. package/src/runtime/computer-identity.js +151 -0
  310. package/src/runtime/config-lock.js +135 -0
  311. package/src/runtime/confined-space-build.js +74 -0
  312. package/src/runtime/confined-space-verify.js +49 -0
  313. package/src/runtime/delegated-context.js +5 -21
  314. package/src/runtime/native-record-files.js +47 -0
  315. package/src/runtime/oauth.js +342 -31
  316. package/src/runtime/profiles.js +19 -112
  317. package/src/runtime/retired-sdk-files.js +24 -0
  318. package/src/runtime/retry.js +150 -0
  319. package/src/runtime/skill-sync/cloud-client.ts +33 -8
  320. package/src/runtime/skill-sync/index.ts +443 -106
  321. package/src/runtime/skill-sync/local-scanner.ts +248 -32
  322. package/src/runtime/skill-sync/native-identity.ts +102 -0
  323. package/src/runtime/skill-sync/native-plan.ts +70 -0
  324. package/src/runtime/skill-sync/symlink-manager.ts +66 -16
  325. package/src/runtime/skill-sync/sync-plan.ts +34 -2
  326. package/src/runtime/skill-sync/types.ts +54 -0
  327. package/src/runtime/skill-sync/write-cloud-skill.ts +4 -4
  328. package/src/runtime/skill-sync-service.js +109 -0
  329. package/src/runtime/source-root.js +32 -0
  330. package/src/runtime/space-collection-scaffold.js +107 -0
  331. package/src/runtime/space-database-structures.js +229 -0
  332. package/src/runtime/space-fixture-broker.js +68 -0
  333. package/src/runtime/space-lock.js +337 -0
  334. package/src/runtime/space-platform.js +133 -0
  335. package/src/runtime/space-source.js +290 -0
  336. package/src/runtime/space-test-server.js +354 -0
  337. package/src/runtime/space-verification.js +94 -0
  338. package/src/runtime/space-verify-browser-worker.js +51 -0
  339. package/src/runtime/space-view-manifest.js +368 -0
  340. package/src/runtime/sync-skills.d.ts +5 -1
  341. package/src/runtime/sync-skills.js +11 -2
  342. package/src/runtime/tool-confirmation.js +138 -0
  343. package/src/runtime/transport.js +118 -24
  344. package/src/runtime/upsell.js +219 -0
  345. package/src/runtime/view-render.js +49 -0
  346. package/src/skill-sync-worker-entry.js +2 -0
  347. package/src/skill-sync-worker.js +114 -0
  348. package/src/space-harness-host.ts +122 -0
  349. package/template/.harness/index.html.tmpl +9 -352
  350. package/template/app/globals.css +29 -3
  351. package/template/app/layout.tsx +2 -6
  352. package/template/components/ui/badge.tsx +7 -4
  353. package/template/components/ui/button.tsx +1 -1
  354. package/template/components/ui/native-select.tsx +24 -0
  355. package/template/notis.config.ts +4 -36
  356. package/template/package-lock.json +1800 -1867
  357. package/template/package.json +16 -14
  358. package/template/postcss.config.mjs +1 -1
  359. package/template/tailwind.config.ts +1 -6
  360. package/template/tsconfig.json +1 -0
  361. package/template/vite.config.ts +2 -2
  362. package/dist/base-skills/notis-apps/SKILL.md +0 -613
  363. package/skills/notis-apps/cli.md +0 -285
  364. package/src/command-specs/apps.js +0 -3011
  365. package/src/runtime/app-changelog.js +0 -79
  366. package/src/runtime/app-dev-consumers.js +0 -154
  367. package/src/runtime/app-dev-host-lock.js +0 -80
  368. package/src/runtime/app-dev-process-identity.js +0 -111
  369. package/src/runtime/app-dev-roots.js +0 -284
  370. package/src/runtime/app-dev-server.js +0 -1140
  371. package/src/runtime/app-dev-sessions.js +0 -185
  372. package/src/runtime/app-registry-scaffolds.js +0 -367
  373. package/src/runtime/assets/store-screenshot-dark.png +0 -0
  374. package/src/runtime/cli-mode.generated.js +0 -5
  375. package/src/runtime/cli-mode.js +0 -34
  376. package/src/runtime/store-screenshot.js +0 -143
  377. package/template/CHANGELOG.md +0 -5
  378. package/template/app/page.tsx +0 -60
  379. package/template/components/ui/card.tsx +0 -56
  380. package/template/packages/sdk/src/components/DocumentEditor.tsx +0 -103
  381. package/template/packages/sdk/src/config.ts +0 -259
  382. package/template/packages/sdk/src/hooks/useCloudComputer.ts +0 -97
  383. package/template/packages/sdk/src/hooks/useDatabaseSchema.ts +0 -85
  384. package/template/packages/sdk/src/hooks/useDocument.ts +0 -78
  385. package/template/packages/sdk/src/hooks/useNotisNavigation.ts +0 -52
  386. package/template/packages/sdk/src/hooks/useTopBarSearch.ts +0 -73
  387. package/template/packages/sdk/src/runtime.ts +0 -439
  388. package/template/packages/sdk/src/vite.ts +0 -56
  389. package/template/packages/sdk/tsconfig.json +0 -15
  390. /package/{template/packages → dist}/sdk/src/components/MultiSelectDragOverlay.tsx +0 -0
  391. /package/{template/packages → dist}/sdk/src/components/ShortcutHints.tsx +0 -0
  392. /package/{template/packages → dist}/sdk/src/hooks/useActiveResource.ts +0 -0
  393. /package/{template/packages → dist}/sdk/src/hooks/useTool.ts +0 -0
  394. /package/{template/packages → dist}/sdk/src/hooks/useTools.ts +0 -0
  395. /package/{template/packages → dist}/sdk/src/ui.ts +0 -0
@@ -0,0 +1,540 @@
1
+ # Notis CLI: Space Development Workflow
2
+
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-spaces` skill and its release guide own the workflow;
5
+ this file lists the commands generated from the CLI's own help.
6
+
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
+
10
+ ## Core workflow
11
+
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.
18
+
19
+ ## Reports and HTML
20
+
21
+ 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.
22
+
23
+ ## Commands
24
+
25
+ ### `npx --package @notis_ai/cli@latest -- notis doctor`
26
+
27
+ Run a quick CLI health check for config, auth, and API reachability.
28
+
29
+ When to use: Use this before relying on the CLI in automation or after changing environments.
30
+
31
+ Examples:
32
+ - `npx --package @notis_ai/cli@latest -- notis doctor`
33
+ - `npx --package @notis_ai/cli@latest -- notis doctor --json`
34
+
35
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history list <space-id>`
36
+
37
+ Read a Space’s saved view versions, newest first.
38
+
39
+ When to use: Inspect when and by whom a view changed, before restoring or undoing a change.
40
+
41
+ Options:
42
+ - `--before <revision>` — Read versions before this cursor.
43
+
44
+ Examples:
45
+ - `npx --package @notis_ai/cli@latest -- notis spaces history list <space-id>`
46
+
47
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history restore <space-id>`
48
+
49
+ Republish a saved view and its settings as a new version; records stay unchanged.
50
+
51
+ When to use: Restore a chosen version, or undo your last change using the version immediately before it.
52
+
53
+ Options:
54
+ - `--target-revision <revision>` — The saved version to restore.
55
+ - `--revision <revision>` — Current Space metadata revision from history list.
56
+ - `--request-id <id>` — Stable restore request ID; reuse on retry.
57
+ - `--dry-run` — Check current access, bindings and saved source without publishing.
58
+
59
+ Examples:
60
+ - `npx --package @notis_ai/cli@latest -- notis spaces history restore <space-id> --target-revision 2 --revision 5 --request-id undo-last-change --dry-run`
61
+
62
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history read <space-id>`
63
+
64
+ Read the files of one saved Space version.
65
+
66
+ When to use: See exactly what a saved version contained, before comparing or restoring it. Editors only.
67
+
68
+ Options:
69
+ - `--revision <revision>` — The saved version from history list.
70
+ - `--path <path>` — Read only this file or folder.
71
+
72
+ Examples:
73
+ - `npx --package @notis_ai/cli@latest -- notis spaces history read <space-id> --revision 3 --path app/page.tsx`
74
+
75
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history diff <space-id>`
76
+
77
+ Compare two saved Space versions, or one with the current version.
78
+
79
+ When to use: See what changed between versions. Prints the unified diff; pass --json for the full comparison.
80
+
81
+ Options:
82
+ - `--from <revision>` — The older saved version.
83
+ - `--to <revision>` — The newer saved version, or current (default).
84
+ - `--path <path>` — Compare only this file or folder.
85
+
86
+ Examples:
87
+ - `npx --package @notis_ai/cli@latest -- notis spaces history diff <space-id> --from 3`
88
+ - `npx --package @notis_ai/cli@latest -- notis spaces history diff <space-id> --from 3 --to 5 --json`
89
+
90
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history name <space-id>`
91
+
92
+ Name a saved Space version, or clear its name.
93
+
94
+ When to use: Mark a version worth keeping, such as a launch. Named versions are kept past the usual retention.
95
+
96
+ Options:
97
+ - `--revision <revision>` — The saved version from history list.
98
+ - `--name <name>` — The version name.
99
+ - `--clear` — Remove the version name.
100
+
101
+ Examples:
102
+ - `npx --package @notis_ai/cli@latest -- notis spaces history name <space-id> --revision 3 --name "Launch"`
103
+ - `npx --package @notis_ai/cli@latest -- notis spaces history name <space-id> --revision 3 --clear`
104
+
105
+ ### `npx --package @notis_ai/cli@latest -- notis spaces history delete <space-id>`
106
+
107
+ Delete one saved Space version for good.
108
+
109
+ When to use: Only when the user asked to delete this version. It cannot be restored afterwards.
110
+
111
+ Options:
112
+ - `--revision <revision>` — The saved version from history list.
113
+ - `--yes` — Confirm the user asked to delete this version for good.
114
+
115
+ Examples:
116
+ - `npx --package @notis_ai/cli@latest -- notis spaces history delete <space-id> --revision 3 --yes`
117
+
118
+ ### `npx --package @notis_ai/cli@latest -- notis spaces screenshot <url>`
119
+
120
+ Capture a full-height PNG of a live view with your current access.
121
+
122
+ When to use: Check the actual deployed view; writes are blocked and current access is checked again before any output is saved.
123
+
124
+ Options:
125
+ - `--width <pixels>` — 1440 (default) or 390.
126
+ - `--output-dir <path>` — New output directory; defaults to a unique .notis/renders directory. Existing files are never overwritten.
127
+
128
+ Examples:
129
+ - `npx --package @notis_ai/cli@latest -- notis spaces screenshot <view-link> --width 390`
130
+
131
+ ### `npx --package @notis_ai/cli@latest -- notis spaces init <name> [dir]`
132
+
133
+ Scaffold an editable collection view with first-party record components.
134
+
135
+ When to use: Start a local Space collection source for an existing linked database. Does not create or deploy remote resources.
136
+
137
+ Options:
138
+ - `--database-key <key>` — Portable key of the database this Space links.
139
+ - `--path <path>` — Descriptive view path; defaults to records.
140
+ - `--title-property <id>` — Canonical title/number property ID, or the title column (default).
141
+
142
+ Examples:
143
+ - `npx --package @notis_ai/cli@latest -- notis spaces init Notes ./notes --database-key notes --path notes`
144
+
145
+ ### `npx --package @notis_ai/cli@latest -- notis spaces navigation bind <space-id>`
146
+
147
+ Bind a named destination for the next source publication without granting target access.
148
+
149
+ When to use: Connect a portable navigation alias to an existing Space or exact record before building and publishing.
150
+
151
+ Options:
152
+ - `--alias <name>` — Declared portable navigation alias.
153
+ - `--target <json>` — Exact {space_id,document_id?}, or null to remove the draft binding.
154
+ - `--revision <number>` — Current source Space metadata revision.
155
+ - `--dry-run` — Check current source/target access and revision without changing anything.
156
+
157
+ Examples:
158
+ - `npx --package @notis_ai/cli@latest -- notis spaces navigation bind <space-id> --alias history --target '{"space_id":"<history-id>"}' --revision 2 --dry-run`
159
+
160
+ ### `npx --package @notis_ai/cli@latest -- notis spaces resources name <space-id> <binding-id>`
161
+
162
+ Give an included resource a portable alias before the first source revision.
163
+
164
+ When to use: Prepare staged resources for source authoring without replacing their IDs, scope or owners.
165
+
166
+ Options:
167
+ - `--alias <name>` — Stable lowercase alias to use in source.
168
+ - `--revision <number>` — Current Space metadata revision.
169
+ - `--dry-run` — Check naming, current access and revision without changing metadata.
170
+
171
+ Examples:
172
+ - `npx --package @notis_ai/cli@latest -- notis spaces resources name <space-id> <binding-id> --alias weekly-report --revision 0 --dry-run`
173
+
174
+ ### `npx --package @notis_ai/cli@latest -- notis spaces links list <space-id>`
175
+
176
+ List the databases, Skills, automations and records linked into one Space.
177
+
178
+ When to use: Find a link binding and its revision before removing it, including a link left behind by a deleted Skill.
179
+
180
+ Examples:
181
+ - `npx --package @notis_ai/cli@latest -- notis spaces links list <space-id>`
182
+
183
+ ### `npx --package @notis_ai/cli@latest -- notis spaces links remove <space-id> <binding-id>`
184
+
185
+ Remove one database, Skill or automation link from a Space by its binding.
186
+
187
+ 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.
188
+
189
+ Options:
190
+ - `--revision <number>` — Current binding revision from spaces links list.
191
+ - `--request-id <key>` — Stable intent key; reuse it unchanged when retrying this removal.
192
+
193
+ Examples:
194
+ - `npx --package @notis_ai/cli@latest -- notis spaces links remove <space-id> <binding-id> --revision 1 --request-id remove-link-1`
195
+
196
+ ### `npx --package @notis_ai/cli@latest -- notis spaces aliases list`
197
+
198
+ List the old App page links you manage and the Space each one opens.
199
+
200
+ When to use: Find an old App page link that opens a binned Space (trashed: true) before repointing it.
201
+
202
+ Options:
203
+ - `--legacy-id <id>` — Old App ID the links belong to.
204
+ - `--kind <kind>` — app (default), report or html.
205
+
206
+ Examples:
207
+ - `npx --package @notis_ai/cli@latest -- notis spaces aliases list --legacy-id <app-id>`
208
+
209
+ ### `npx --package @notis_ai/cli@latest -- notis spaces aliases repoint`
210
+
211
+ Point one old App page link at a live Space you edit.
212
+
213
+ 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.
214
+
215
+ Options:
216
+ - `--legacy-id <id>` — Old App ID the link belongs to.
217
+ - `--route <slug>` — Old App page route from spaces aliases list.
218
+ - `--space <space-id>` — Live Space the old link should open.
219
+ - `--expected-space <space-id>` — Space the link opens now; the change is refused if it moved since you listed it.
220
+ - `--selection-param <name>` — Declared view parameter that receives the old page selection, if any.
221
+ - `--request-id <key>` — Stable intent key; reuse it unchanged when retrying this change.
222
+ - `--dry-run` — Check authority and the new Space without changing the link.
223
+
224
+ Examples:
225
+ - `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`
226
+
227
+ ### `npx --package @notis_ai/cli@latest -- notis spaces pull <space-id> [dir]`
228
+
229
+ Pull one editable Space source snapshot, its resource list and its Skill folders into an empty directory.
230
+
231
+ 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.
232
+
233
+ Options:
234
+ - `--revision <number>` — Exact published source revision; defaults to the current one.
235
+
236
+ Examples:
237
+ - `npx --package @notis_ai/cli@latest -- notis spaces pull <space-id> ./space-source`
238
+
239
+ ### `npx --package @notis_ai/cli@latest -- notis spaces verify [dir]`
240
+
241
+ Render one frozen Space with offline fixtures and validate its current action authorizations.
242
+
243
+ When to use: Check immutable build bytes and authoring compatibility without executing actions or publishing.
244
+
245
+ Options:
246
+ - `--space <key>` — Exact source key from the workspace index.
247
+ - `--space-id <id>` — Exact existing destination Space.
248
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
249
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
250
+
251
+ Examples:
252
+ - `npx --package @notis_ai/cli@latest -- notis spaces verify . --space overview --space-id <space-id>`
253
+
254
+ ### `npx --package @notis_ai/cli@latest -- notis spaces preview [dir]`
255
+
256
+ Seal a checked unpublished revision of the same Space and return its authenticated preview link.
257
+
258
+ When to use: Review a checked candidate using current Editor access without changing live source or cloning the Space.
259
+
260
+ Options:
261
+ - `--space <key>` — Exact source key from the workspace index.
262
+ - `--space-id <id>` — Exact existing destination Space.
263
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
264
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
265
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
266
+ - `--dry-run` — Validate without uploading or publishing.
267
+
268
+ Examples:
269
+ - `npx --package @notis_ai/cli@latest -- notis spaces preview . --space overview --space-id <space-id> --request-id release-1`
270
+
271
+ ### `npx --package @notis_ai/cli@latest -- notis spaces deploy [dir]`
272
+
273
+ Publish one built Space with a retry-safe, independent source revision.
274
+
275
+ When to use: Update only the selected existing Space; this does not publish to the Store or change siblings.
276
+
277
+ Options:
278
+ - `--space <key>` — Exact source key from the workspace index.
279
+ - `--space-id <id>` — Exact existing destination Space.
280
+ - `--reuse-grants <json>` — Explicit action-key to saved-grant-ID map. Otherwise your own connections are used.
281
+ - `--reuse-grants-only` — Never authorize new actions. Reuse only the supplied saved grants; other declarations remain unavailable. Requires existing bound databases.
282
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
283
+ - `--dry-run` — Validate without uploading or publishing.
284
+
285
+ Examples:
286
+ - `npx --package @notis_ai/cli@latest -- notis spaces deploy . --space overview --space-id <space-id> --request-id release-1`
287
+
288
+ ### `npx --package @notis_ai/cli@latest -- notis spaces promote <release-id> [dir]`
289
+
290
+ Publish the exact sealed Space revision, with its pending Skill and link changes, after current permission and concurrency checks.
291
+
292
+ 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.
293
+
294
+ Examples:
295
+ - `npx --package @notis_ai/cli@latest -- notis spaces promote <release-id>`
296
+
297
+ ### `npx --package @notis_ai/cli@latest -- notis spaces abandon <release-id>`
298
+
299
+ Close an unpublished Space preview without changing its live source, Skills or links, or deleting action history.
300
+
301
+ When to use: Stop using a candidate while preserving live source and completed effects.
302
+
303
+ Examples:
304
+ - `npx --package @notis_ai/cli@latest -- notis spaces abandon <release-id>`
305
+
306
+ ### `npx --package @notis_ai/cli@latest -- notis spaces list`
307
+
308
+ List Spaces currently available to your account.
309
+
310
+ When to use: Discover accessible Spaces without exposing an issuer-wide resource catalogue.
311
+
312
+ Examples:
313
+ - `npx --package @notis_ai/cli@latest -- notis spaces list`
314
+
315
+ ### `npx --package @notis_ai/cli@latest -- notis spaces get <space-id>`
316
+
317
+ Read one accessible Space and its scoped resources.
318
+
319
+ When to use: Inspect the current published revision and named capabilities before executing.
320
+
321
+ Options:
322
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
323
+
324
+ Examples:
325
+ - `npx --package @notis_ai/cli@latest -- notis spaces get <space-id>`
326
+
327
+ ### `npx --package @notis_ai/cli@latest -- notis spaces action <space-id> <action-id>`
328
+
329
+ Execute a declared action using its saved authorization.
330
+
331
+ When to use: Use Space capabilities as the actual actor, with the saved issuer connection and payer.
332
+
333
+ Options:
334
+ - `--revision <number>` — Exact published source revision.
335
+ - `--preview-release <id>` — Exact sealed candidate ID; requires current Editor access.
336
+ - `--schema-revision <number>` — Native schema revision; required for native row writes.
337
+ - `--inputs <json>` — Declared action input values; defaults to {}.
338
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
339
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
340
+ - `--dry-run` — Validate current access and action inputs without executing or billing.
341
+
342
+ Examples:
343
+ - `npx --package @notis_ai/cli@latest -- notis spaces action <space-id> refresh --revision 1 --inputs '{}' --request-id refresh-1 --dry-run`
344
+
345
+ ### `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> <operation>`
346
+
347
+ Run one declared viewer read as yourself.
348
+
349
+ 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.
350
+
351
+ Options:
352
+ - `--revision <number>` — Exact published source revision.
353
+ - `--preview-release <id>` — Exact sealed candidate ID; requires current Editor access.
354
+ - `--input <json>` — Read input, e.g. {"database_id":"<id>"}; defaults to {}.
355
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
356
+
357
+ Examples:
358
+ - `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> list_databases --revision 3`
359
+ - `npx --package @notis_ai/cli@latest -- notis spaces viewer-read <space-id> query_database --revision 3 --input '{"database_id":"<id>","request":{"page_size":20}}'`
360
+
361
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants list <space-id>`
362
+
363
+ Inspect authorization records for a Space you can edit.
364
+
365
+ When to use: Inspect issuers and exact constraints without exposing connection secrets.
366
+
367
+ Options:
368
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
369
+
370
+ Examples:
371
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants list <space-id>`
372
+
373
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants create <space-id>`
374
+
375
+ Authorize an exact template using your current connection.
376
+
377
+ When to use: Create a Space-bound authorization; the server resolves the signed-in issuer connection.
378
+
379
+ Options:
380
+ - `--template <file>` — Canonical action template JSON file.
381
+ - `--record <record-key>` — Fixed record context, when this is a record-scoped Space.
382
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
383
+ - `--dry-run` — Validate the template and Editor access without creating a grant.
384
+
385
+ Examples:
386
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants create <space-id> --template action.json --request-id grant-1 --dry-run`
387
+
388
+ ### `npx --package @notis_ai/cli@latest -- notis spaces grants revoke <grant-id>`
389
+
390
+ Revoke one saved Space authorization.
391
+
392
+ When to use: Stop future dispatches for an authorization you issued or can administer.
393
+
394
+ Examples:
395
+ - `npx --package @notis_ai/cli@latest -- notis spaces grants revoke <grant-id>`
396
+
397
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store list`
398
+
399
+ List Space Store listings you can see.
400
+
401
+ When to use: Find Space templates published to your team or approved for everyone, and your own listings.
402
+
403
+ Options:
404
+ - `--channel <team|public>` — Only one channel.
405
+
406
+ Examples:
407
+ - `npx --package @notis_ai/cli@latest -- notis spaces store list --channel team`
408
+
409
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store get <listing-id>`
410
+
411
+ Read one Store listing with its versions and your installs.
412
+
413
+ When to use: Check what a listing contains, its review state and whether your copies have an update.
414
+
415
+ Examples:
416
+ - `npx --package @notis_ai/cli@latest -- notis spaces store get <listing-id>`
417
+
418
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store installs`
419
+
420
+ List the Spaces you installed from the Store.
421
+
422
+ When to use: See which installed copies have an update or conflicts to resolve.
423
+
424
+ Examples:
425
+ - `npx --package @notis_ai/cli@latest -- notis spaces store installs`
426
+
427
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store publish <space-id>`
428
+
429
+ Publish a Space and its sub-Spaces as the next Store version.
430
+
431
+ When to use: Share a Space you own as an installable template: team listings publish at once, public ones wait for review. Notis runs the same safety scan and Owner check as the submission page and explains any refusal.
432
+
433
+ Options:
434
+ - `--channel <team|public>` — Where to publish.
435
+ - `--metadata <json>` — Listing name, tagline, description, category, icon, accent.
436
+ - `--starter <json>` — Starter row IDs per database ({"<database-id>":["<record-key>"]}).
437
+ - `--notes <text>` — Release notes for this version.
438
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
439
+ - `--dry-run` — Show the package counts and review diff without publishing.
440
+
441
+ Examples:
442
+ - `npx --package @notis_ai/cli@latest -- notis spaces store publish <space-id> --channel team --request-id publish-1 --dry-run`
443
+
444
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store install <listing-id>`
445
+
446
+ Install a Store listing as your own independent copy.
447
+
448
+ When to use: Add a published Space template to your account; your copy keeps your changes on later updates.
449
+
450
+ Options:
451
+ - `--name <name>` — Name of the installed top Space.
452
+ - `--parent <space-id>` — Install under one of your Spaces.
453
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
454
+ - `--dry-run` — Show what the copy contains without installing.
455
+
456
+ Examples:
457
+ - `npx --package @notis_ai/cli@latest -- notis spaces store install <listing-id> --request-id install-1`
458
+
459
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id>`
460
+
461
+ Update an installed copy, keeping your changes, or resolve its conflicts.
462
+
463
+ When to use: Take a newer Store version: unchanged parts update, your edits stay, and parts both sides changed become conflicts you resolve.
464
+
465
+ Options:
466
+ - `--resolve <json>` — Per conflict key: "keep_mine" or "take_theirs".
467
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
468
+ - `--dry-run` — Show the three-way plan without changing anything.
469
+
470
+ Examples:
471
+ - `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id> --request-id update-1 --dry-run`
472
+ - `npx --package @notis_ai/cli@latest -- notis spaces store update <install-id> --resolve '{"skill:<key>":"keep_mine"}' --request-id resolve-1`
473
+
474
+ ### `npx --package @notis_ai/cli@latest -- notis spaces store unpublish <listing-id>`
475
+
476
+ Stop new installs of a Store listing.
477
+
478
+ When to use: Withdraw a listing: existing copies keep working and a version waiting for review is withdrawn.
479
+
480
+ Options:
481
+ - `--request-id <key>` — Stable intent key. Reuse after timeouts or lost replies.
482
+
483
+ Examples:
484
+ - `npx --package @notis_ai/cli@latest -- notis spaces store unpublish <listing-id> --request-id unpublish-1`
485
+
486
+ ### `npx --package @notis_ai/cli@latest -- notis spaces build [dir]`
487
+
488
+ Build one independent Space and save its frozen source/artifact snapshot.
489
+
490
+ When to use: Prepare a selected Space for verification without publishing it or changing siblings.
491
+
492
+ Options:
493
+ - `--space <key>` — Exact source key from the workspace Space index.
494
+
495
+ Examples:
496
+ - `npx --package @notis_ai/cli@latest -- notis spaces build . --space overview`
497
+
498
+ ### `npx --package @notis_ai/cli@latest -- notis spaces inspect [dir]`
499
+
500
+ Inspect one local Space definition and its declared capabilities.
501
+
502
+ When to use: Read the selected source definition without loading sibling definitions or account resources.
503
+
504
+ Options:
505
+ - `--space <key>` — Exact source key from the workspace Space index.
506
+
507
+ Examples:
508
+ - `npx --package @notis_ai/cli@latest -- notis spaces inspect . --space overview`
509
+
510
+ ### `npx --package @notis_ai/cli@latest -- notis views find`
511
+
512
+ Find the views you can open for a record, database, view link, Space or search.
513
+
514
+ When to use: Get fresh view-qualified links and declared URL parameters before citing or opening a view.
515
+
516
+ Options:
517
+ - `--record-key <id>` — Find views that show this exact native record.
518
+ - `--database-id <id>` — Find views over this database.
519
+ - `--url <url>` — Resolve this view link and its current parameters.
520
+ - `--space-id <id>` — Describe this Space view.
521
+ - `--query <text>` — Search accessible view names, descriptions and readable context.
522
+
523
+ Examples:
524
+ - `npx --package @notis_ai/cli@latest -- notis views find --record-key <record-key>`
525
+ - `npx --package @notis_ai/cli@latest -- notis views find --url <view-link>`
526
+ - `npx --package @notis_ai/cli@latest -- notis views find --query inbox`
527
+
528
+ ### `npx --package @notis_ai/cli@latest -- notis views render <url>`
529
+
530
+ Render a live view as Markdown and a full-height PNG with your current access.
531
+
532
+ When to use: Check the actual deployed view; writes are blocked and current access is checked again before any output is saved.
533
+
534
+ Options:
535
+ - `--outputs <kinds>` — Comma-separated markdown,screenshot (default both).
536
+ - `--width <pixels>` — 1440 (default) or 390.
537
+ - `--output-dir <path>` — New output directory; defaults to a unique .notis/renders directory. Existing files are never overwritten.
538
+
539
+ Examples:
540
+ - `npx --package @notis_ai/cli@latest -- notis views render <view-link> --outputs markdown,screenshot`
package/src/cli.js CHANGED
@@ -10,6 +10,7 @@ import { reportCliCommand } from './runtime/telemetry.js';
10
10
  import { reconcileBaseSkillsBestEffort } from './runtime/base-skills.js';
11
11
  import { detectedAgentIds } from './runtime/agent-setup.js';
12
12
  import { withSkillSyncLock } from './runtime/sync-skills.js';
13
+ import { maybeInstallSkillSyncService } from './runtime/skill-sync-service.js';
13
14
  import {
14
15
  CHANNEL_SWITCH_ENV,
15
16
  resolveChannelSwitch,
@@ -81,15 +82,10 @@ function ensureParentCommand(program, parentMap, parentPath) {
81
82
 
82
83
  function buildRuntime(globalOptions, spec) {
83
84
  const localBackendTypes = new Set(['local', 'local_config', 'local_registry']);
84
- const commandName = spec.command_path.join(' ');
85
- const liveAppHarness = (
86
- commandName === 'apps verify' || commandName === 'apps screenshot'
87
- ) && globalOptions.mode === 'live';
88
85
  const runtime = resolveRuntimeProfile(globalOptions, {
89
86
  requireAuth: spec.require_auth !== false,
90
87
  allowUnknownProfile: spec.allow_unknown_profile === true,
91
- allowUnavailableWorktree:
92
- localBackendTypes.has(spec.backend_call?.type) && !liveAppHarness,
88
+ allowUnavailableWorktree: localBackendTypes.has(spec.backend_call?.type),
93
89
  });
94
90
  // A stopped local-only worktree may keep executing commands whose backend is
95
91
  // entirely local, but it must not carry a shared live credential into those
@@ -188,6 +184,9 @@ function attachSpec(program, parentMap, spec, specs, launchContext = {}) {
188
184
  ...launchContext,
189
185
  });
190
186
  process.exitCode = typeof exitCode === 'number' ? exitCode : 0;
187
+ if (process.exitCode === 0 && !['logout', 'agent-context', 'agent-capture'].includes(spec.command_path[0])) {
188
+ await maybeInstallSkillSyncService(runtime).catch(() => undefined);
189
+ }
191
190
  await reportCliCommand({
192
191
  spec,
193
192
  runtime,
@@ -219,7 +218,7 @@ export function createProgram(launchContext = {}) {
219
218
 
220
219
  program
221
220
  .name('notis')
222
- .description('Agent-first Notis CLI for apps and generic tool execution')
221
+ .description('Agent-first Notis CLI for Spaces and generic tool execution')
223
222
  .version(CLI_VERSION)
224
223
  .showHelpAfterError()
225
224
  .option('--json', 'Shortcut for --output json')
@@ -233,8 +232,9 @@ export function createProgram(launchContext = {}) {
233
232
  // `notis profile use`, pinning all commands to the default profile.
234
233
  .option('--profile <name>', 'CLI profile to run as (defaults to the active profile)')
235
234
  .option('--api-base <url>', 'Override the API base URL for this invocation')
236
- .option('--timeout-ms <n>', 'HTTP timeout in milliseconds')
235
+ .option('--timeout-ms <n>', 'Time limit in milliseconds for each call, automatic retries included')
237
236
  .option('--idempotency-key <key>', 'Override the generated idempotency key for mutating commands')
237
+ .option('--no-retry', 'Turn off automatic retries of interrupted calls that are safe to repeat (or set NOTIS_NO_RETRY=1)')
238
238
  .addOption(new Option('--notis-managed-agent-hook').hideHelp());
239
239
 
240
240
  const parentMap = new Map([['', program]]);