@voltro/cli 0.38.0 → 0.39.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 (173) hide show
  1. package/CHANGELOG.md +276 -0
  2. package/THIRD-PARTY-NOTICES.md +80 -45
  3. package/dist/{addCommand-BNeoeSxe.js → addCommand-C05L9tZh.js} +2 -2
  4. package/dist/addCommand-C3MdJG-a.js +2 -0
  5. package/dist/{agentsMd-mhQMF1bx.js → agentsMd-7zI2h5l9.js} +3 -3
  6. package/dist/agentsMd-BFCXh2gl.js +2 -0
  7. package/dist/apiBuild-BmR_bIxN.js +2 -0
  8. package/dist/{apiBuild-CvacV4zA.js → apiBuild-D9FB13_2.js} +3 -3
  9. package/dist/baselineCommand-CXv680Dc.js +2 -0
  10. package/dist/{baselineCommand-C6NMt-oa.js → baselineCommand-Ck2Xm8M7.js} +18 -18
  11. package/dist/bin.js +1 -1
  12. package/dist/{build-_LoTC1s0.js → build-DORV5mLM.js} +107 -100
  13. package/dist/{capabilitiesCommand-nq_pz5xd.js → capabilitiesCommand-D5gucwYa.js} +8 -8
  14. package/dist/{checkCommand-Pjk5sBl2.js → checkCommand-Bf6oMao4.js} +35 -35
  15. package/dist/{checkCommand-wibtQx-N.js → checkCommand-D9qK_gtA.js} +1 -1
  16. package/dist/{cloudCmd-NQSwe_Qk.js → cloudCmd-C42gaO8s.js} +16 -16
  17. package/dist/{clusterCmd-D5wsCmA_.js → clusterCmd-DrVFCzSj.js} +8 -4
  18. package/dist/{codegen-GYYcdpCg.js → codegen-CbpGCWLG.js} +1 -1
  19. package/dist/codegen-i8QGcHsi.js +2 -0
  20. package/dist/codegenCommand-CxOyKmc1.js +129 -0
  21. package/dist/{codemodRunner-CXgQ-ecJ.js → codemodRunner-D-jTyvWo.js} +622 -551
  22. package/dist/{commands-DaZVi9wi.js → commands-D6aW_6AR.js} +48 -48
  23. package/dist/{connectionConfig-UFlIEiys.js → connectionConfig-Bk9IC7D0.js} +1 -1
  24. package/dist/{dashboardCommand-Dxy_kmoW.js → dashboardCommand-CwTZh-XZ.js} +3 -3
  25. package/dist/{dataCommand-D6-Ha2lf.js → dataCommand-Cc9RiLQZ.js} +14 -11
  26. package/dist/{dbCommand-C4UW8cVN.js → dbCommand-DSwGv9wS.js} +50 -49
  27. package/dist/dbCommand-DcqEyxju.js +2 -0
  28. package/dist/{dev-E7Eo5GHc.js → dev-3mgc8c-H.js} +2260 -2184
  29. package/dist/dev-CjJAasDs.js +3 -0
  30. package/dist/{dialectDriver-CgXnDfec.js → dialectDriver-czCHYpeH.js} +2 -1
  31. package/dist/doctorCommand-Cghssndo.js +2 -0
  32. package/dist/{doctorCommand-gmDyALFL.js → doctorCommand-oLuzc-aC.js} +261 -244
  33. package/dist/{dormancyCommand-CE6wG8lj.js → dormancyCommand-Bxe4WtHU.js} +1 -1
  34. package/dist/{e2eCmd-BRabZww-.js → e2eCmd-uFHig1hV.js} +8 -2
  35. package/dist/{embeddingsCommand-C3uAuf6N.js → embeddingsCommand-CyNQkFIc.js} +6 -6
  36. package/dist/{envCommand-DzuWh8ya.js → envCommand-CAkSgBbh.js} +19 -19
  37. package/dist/{evolveCommand-DPLqcYb2.js → evolveCommand-CWhBoe_P.js} +6 -8
  38. package/dist/frameworkTableAssembly-DgylYh9_.js +2 -0
  39. package/dist/{generateCommand-DbgcUpGw.js → generateCommand-CcyvH2ve.js} +1 -1
  40. package/dist/index.js +1 -1
  41. package/dist/{infoCommand-CmczGj_l.js → infoCommand-CTo8Jnhq.js} +7 -7
  42. package/dist/inspect-B7U7Cl_Z.js +1192 -0
  43. package/dist/inspect-DUze25t0.js +2 -0
  44. package/dist/{inspectCmd-EHFZ9yYu.js → inspectCmd-niF97fAq.js} +5 -5
  45. package/dist/inspectGateHint-BjnFubmH.js +7 -0
  46. package/dist/{logFileSink-C_D2wRN1.js → logFileSink-B4uP8pvf.js} +1 -1
  47. package/dist/{logsCmd-D36xK7Zu.js → logsCmd-B6oNsfaZ.js} +10 -7
  48. package/dist/{manifestBuild-hpPLaGxV.js → manifestBuild-BK42hu0k.js} +1 -1
  49. package/dist/manifestBuild-j0n109tt.js +2 -0
  50. package/dist/{metaCommands-CIoQNlaQ.js → metaCommands-DUYR--Ts.js} +1 -1
  51. package/dist/{migrate-RwgUWXfc.js → migrate-BnPw2zC8.js} +7 -4
  52. package/dist/{packageCommand-Cug_3Ogl.js → packageCommand-9SVyvsSo.js} +3 -2
  53. package/dist/{probeCommand-BPEpwT32.js → probeCommand-C9gazU0H.js} +35 -24
  54. package/dist/{projectScaffold-CxgtJvlb.js → projectScaffold-BEhhHjPr.js} +1 -1
  55. package/dist/{projectScaffold-DDgWbNLe.js → projectScaffold-BvhLOrLq.js} +17 -15
  56. package/dist/{runtimeTrace-6jfznSzr.js → runtimeTrace-gNXeLf6H.js} +1 -1
  57. package/dist/{scheduleManifestCmd-D2x0CTTY.js → scheduleManifestCmd-kmWzrO_w.js} +6 -9
  58. package/dist/{sdkgen-CEJZZQUA.js → sdkgen-C8zz10-X.js} +4 -4
  59. package/dist/{seedRunner-ZmLSqNe2.js → seedRunner-IdHEprqf.js} +1 -4
  60. package/dist/serveCommand-BpK8-m1N.js +1770 -0
  61. package/dist/serveCommand-CW-goXvh.js +2 -0
  62. package/dist/serveEntry.js +2 -2
  63. package/dist/{serverlessCommand-CfJZy6dS.js → serverlessCommand-DbJ7Plg9.js} +3 -3
  64. package/dist/{start-CidwCcjl.js → start-BNuTWdRd.js} +1 -1
  65. package/dist/{start-RCh6qKFe.js → start-ft_KzFTd.js} +257 -254
  66. package/dist/startEntry.js +1 -1
  67. package/dist/{test-DIQ0jlkQ.js → test-CLYXrZ2F.js} +1 -1
  68. package/dist/{tracesCmd-DStmCJPi.js → tracesCmd-DgtgOUdi.js} +7 -4
  69. package/dist/{typecheckCommand-BlsWiCNq.js → typecheckCommand-BuCtT92o.js} +7 -7
  70. package/dist/updateCommand-6FMU2klq.js +2 -0
  71. package/dist/{updateCommand-CmksX7m_.js → updateCommand-CHBmCB17.js} +5 -3
  72. package/dist/{webDev-BKdD7c_a.js → webDev-CTpSY-e_.js} +813 -775
  73. package/dist/webDev-id3I5PvG.js +2 -0
  74. package/dist/{webhookDiscovery-D7VaeMlz.js → webhookDiscovery-CphsQe59.js} +4 -6
  75. package/dist/{webhookDiscovery-CrGAfhIG.js → webhookDiscovery-il9ti-HE.js} +1 -1
  76. package/dist/{webhooksCommand-BHeaF1ZJ.js → webhooksCommand-EccPZQZ4.js} +1 -1
  77. package/package.json +27 -21
  78. package/templates/AGENTS.md +2 -2
  79. package/templates/agent-docs/_index.md +2 -2
  80. package/templates/agent-docs/_manifest.json +2 -2
  81. package/templates/agent-docs/authentication.md +43 -4
  82. package/templates/agent-docs/cli.md +17 -13
  83. package/templates/agent-docs/data.md +44 -1
  84. package/templates/agent-docs/database/migrations.md +2 -2
  85. package/templates/agent-docs/database/seedsdialects.md +2 -2
  86. package/templates/agent-docs/deployment.md +21 -7
  87. package/templates/agent-docs/internationalization.md +10 -3
  88. package/templates/agent-docs/local-first-mobile.md +141 -20
  89. package/templates/agent-docs/plugins/mail.md +1 -1
  90. package/templates/agent-docs/plugins/ratelimit.md +1 -1
  91. package/templates/agent-docs/plugins.md +3 -1
  92. package/templates/agent-docs/releases.md +130 -1
  93. package/templates/agent-docs/routing.md +34 -2
  94. package/templates/agent-docs/templates/apibackends.md +1 -1
  95. package/templates/agent-docs/templates/mobile.md +1 -1
  96. package/templates/agent-docs/whats-new.md +26 -66
  97. package/templates/apps/api-ai/package.json +7 -7
  98. package/templates/apps/api-auth/package.json +8 -8
  99. package/templates/apps/api-backend/package.json +7 -7
  100. package/templates/apps/api-backend-deactivation/package.json +7 -7
  101. package/templates/apps/api-backend-mail/package.json +8 -8
  102. package/templates/apps/api-backend-mariadb/package.json +9 -9
  103. package/templates/apps/api-backend-sqlite/package.json +8 -8
  104. package/templates/apps/api-backend-storage/package.json +8 -8
  105. package/templates/apps/api-cms/package.json +10 -10
  106. package/templates/apps/api-collab/package.json +8 -8
  107. package/templates/apps/api-data-advanced/package.json +8 -8
  108. package/templates/apps/api-durable/package.json +8 -8
  109. package/templates/apps/api-durable/startup/warm.startup.tsx +16 -2
  110. package/templates/apps/api-feature-flags/package.json +9 -9
  111. package/templates/apps/api-governance/package.json +8 -8
  112. package/templates/apps/api-kv/package.json +8 -8
  113. package/templates/apps/api-moderation/package.json +8 -8
  114. package/templates/apps/api-observability/package.json +8 -8
  115. package/templates/apps/api-ratelimit/package.json +8 -8
  116. package/templates/apps/api-rbac/authz.ts +16 -1
  117. package/templates/apps/api-rbac/package.json +8 -8
  118. package/templates/apps/api-rest/package.json +7 -7
  119. package/templates/apps/api-saas/package.json +11 -11
  120. package/templates/apps/api-saas-starter/package.json +10 -10
  121. package/templates/apps/api-search/package.json +8 -8
  122. package/templates/apps/api-status/package.json +8 -8
  123. package/templates/apps/api-versioning/package.json +8 -8
  124. package/templates/apps/api-webhooks/package.json +9 -9
  125. package/templates/apps/changelog/package.json +6 -6
  126. package/templates/apps/edge-functions/package.json +2 -2
  127. package/templates/apps/frontend-admin/package.json +8 -8
  128. package/templates/apps/frontend-app/package.json +9 -9
  129. package/templates/apps/frontend-auth/package.json +8 -8
  130. package/templates/apps/frontend-blank/package.json +7 -7
  131. package/templates/apps/frontend-cms/package.json +9 -9
  132. package/templates/apps/frontend-collab/package.json +10 -10
  133. package/templates/apps/frontend-contact/package.json +7 -7
  134. package/templates/apps/frontend-dashboard/package.json +7 -7
  135. package/templates/apps/frontend-docs/package.json +7 -7
  136. package/templates/apps/frontend-i18n/package.json +6 -6
  137. package/templates/apps/frontend-landing/package.json +7 -7
  138. package/templates/apps/frontend-portal/package.json +8 -8
  139. package/templates/apps/frontend-saas/package.json +8 -8
  140. package/templates/apps/frontend-spa/package.json +7 -7
  141. package/templates/apps/frontend-ssr/package.json +7 -7
  142. package/templates/apps/frontend-ssr-api/package.json +8 -8
  143. package/templates/apps/frontend-static-blog/package.json +6 -6
  144. package/templates/apps/frontend-status/package.json +8 -8
  145. package/templates/apps/mobile-app/README.md +41 -17
  146. package/templates/apps/mobile-app/app.config.ts +1 -1
  147. package/templates/apps/mobile-app/package.json +15 -11
  148. package/templates/apps/mobile-app/src/app/_layout.tsx +44 -13
  149. package/templates/apps/mobile-app/src/app/index.tsx +1 -1
  150. package/templates/apps/mobile-app/src/app/settings.tsx +4 -1
  151. package/templates/apps/mobile-app/src/client.ts +74 -57
  152. package/templates/apps/mobile-app/src/lib/api.ts +4 -4
  153. package/templates/apps/mobile-app/src/lib/deeplinks.ts +6 -6
  154. package/templates/apps/mobile-app/src/persistence.ts +24 -3
  155. package/templates/apps/mobile-app/tsconfig.json +17 -3
  156. package/dist/addCommand-aXSQveak.js +0 -2
  157. package/dist/agentsMd-BTchIZku.js +0 -2
  158. package/dist/apiBuild-ttSDDOGp.js +0 -2
  159. package/dist/baselineCommand-Cfw2Afwm.js +0 -2
  160. package/dist/codegen-uYrrDzQv.js +0 -2
  161. package/dist/codegenCommand-C60m_LCp.js +0 -30
  162. package/dist/dbCommand-CC-qNzpz.js +0 -2
  163. package/dist/dev-CAOoXOkc.js +0 -3
  164. package/dist/doctorCommand-Cjl8Yii8.js +0 -2
  165. package/dist/frameworkTableAssembly-YyVe32Cb.js +0 -2
  166. package/dist/inspect-CjTYzAs_.js +0 -1190
  167. package/dist/inspect-P4pxoMaV.js +0 -2
  168. package/dist/inspectGateHint-BF6608UT.js +0 -4
  169. package/dist/manifestBuild-COkJoyAr.js +0 -2
  170. package/dist/serveCommand-DNRF2nDI.js +0 -2
  171. package/dist/serveCommand-DnY4VS3D.js +0 -1767
  172. package/dist/updateCommand-B0J_T9Vs.js +0 -2
  173. package/dist/webDev-CcJfdSjl2.js +0 -2
@@ -0,0 +1,2 @@
1
+ import { r as e } from "./inspect-B7U7Cl_Z.js";
2
+ export { e as buildCapabilityManifest };
@@ -76,7 +76,7 @@ var o = {
76
76
  n++;
77
77
  continue;
78
78
  }
79
- if (!(e.status === "running" || e.status === "suspended" || e.status === "cancelled")) break;
79
+ if (e.status !== "running" && e.status !== "suspended" && e.status !== "cancelled") break;
80
80
  }
81
81
  let r = t[0];
82
82
  return {
@@ -100,7 +100,7 @@ var o = {
100
100
  a++;
101
101
  continue;
102
102
  }
103
- if (!(e.status === "skipped" || e.status === "missed")) break;
103
+ if (e.status !== "skipped" && e.status !== "missed") break;
104
104
  }
105
105
  let o = r[0];
106
106
  return {
@@ -174,8 +174,7 @@ var o = {
174
174
  let n = t.filter((e) => e.kind === "ok"), r = t.filter((e) => e.kind === "err").map((e) => ({
175
175
  name: e.name,
176
176
  error: e.error
177
- }));
178
- return e(r.length > 0 ? {
177
+ })), i = r.length > 0 ? {
179
178
  results: n.map((e) => ({
180
179
  process: e.name,
181
180
  data: e.data
@@ -184,7 +183,8 @@ var o = {
184
183
  } : { results: n.map((e) => ({
185
184
  process: e.name,
186
185
  data: e.data
187
- })) }, { pretty: !1 }), +(n.length === 0);
186
+ })) };
187
+ return e(i, { pretty: !1 }), +(n.length === 0);
188
188
  }, v = (t, n) => {
189
189
  let r = !1;
190
190
  for (let i of n) i.kind === "ok" ? (r = !0, console.log(a.bold(`# ${t} @${i.name}`)), e(i.data)) : console.error(a.dim(`# fetch failed: ${i.name}: ${i.error}`));
@@ -0,0 +1,7 @@
1
+ //#region src/inspectGateHint.ts
2
+ var e = (e) => e === 401 || e === 403, t = (e) => e === 403 ? "The inspect surface rejected the credential. VOLTRO_INSPECT_TOKEN must be set on the SERVER and in this shell, and the two values must match. (This is a framework gate, not a database permission.)" : "The inspect surface is gated and this request carried no credential. Set VOLTRO_INSPECT_TOKEN on the server and in this shell (same value), or pass --token.", n = "`voltro dev` mints VOLTRO_INSPECT_WRITE_TOKEN into the project's gitignored .env.local, so read the value from there and send it in this shell; outside dev nothing mints it and you set it explicitly on both sides.", r = (e, t) => {
3
+ let r = `inspect: ${(t || "unknown-method").toUpperCase()} is a mutating request and needs the WRITE credential — VOLTRO_INSPECT_WRITE_TOKEN, sent as the \`x-voltro-inspect-write\` header alongside the bearer. The read token authorises reads only.`;
4
+ return e === "unset" ? `${r} The SERVER has none configured, so no header can satisfy this. Mutating inspect endpoints (GDPR erase/export, storage share/revoke, schedule fire) need their own secret. ${n}` : e === "mismatch" ? `${r} The header was sent and does not match the server's value — so this is the two values disagreeing, not a missing setting. ${n}` : `${r} This request carried no such header. ${n}`;
5
+ };
6
+ //#endregion
7
+ export { r as n, e as r, t };
@@ -5,7 +5,7 @@ import { homedir as u } from "node:os";
5
5
  //#region src/logFileSink.ts
6
6
  var d = e(u(), ".voltro", "logs"), f = () => {
7
7
  let e = Number(process.env.VOLTRO_LOG_FILE_TTL_MS);
8
- return Number.isFinite(e) && e > 0 ? e : 3600 * 1e3;
8
+ return Number.isFinite(e) && e > 0 ? e : 36e5;
9
9
  }, p = !1, m = () => {
10
10
  if (p) return;
11
11
  p = !0;
@@ -1,5 +1,5 @@
1
1
  import { n as e } from "./runtimeRegistry-DMeKfTHP.js";
2
- import { r as t, t as n } from "./logFileSink-C_D2wRN1.js";
2
+ import { r as t, t as n } from "./logFileSink-B4uP8pvf.js";
3
3
  import { n as r } from "./cliOutput-D1tSBoRM.js";
4
4
  import { a as i, i as a } from "./inspectFetch-EMuhTG_9.js";
5
5
  import { ansi as o } from "@voltro/logger";
@@ -133,10 +133,13 @@ var s = (e) => {
133
133
  name: e.name,
134
134
  error: e.error
135
135
  });
136
- if (m.sort((e, t) => e.ts - t.ts), a.format === "json") return r(_.length > 0 ? {
137
- records: m,
138
- fetchErrors: _
139
- } : { records: m }, { pretty: !1 }), +(_.length === u.length);
136
+ if (m.sort((e, t) => e.ts - t.ts), a.format === "json") {
137
+ let e = _.length > 0 ? {
138
+ records: m,
139
+ fetchErrors: _
140
+ } : { records: m };
141
+ return r(e, { pretty: !1 }), +(_.length === u.length);
142
+ }
140
143
  if (a.format === "text") {
141
144
  for (let e of m) console.log(h(e));
142
145
  for (let e of _) console.error(`# fetch failed: ${e.name}: ${e.error}`);
@@ -188,14 +191,14 @@ var s = (e) => {
188
191
  error: 4,
189
192
  fatal: 5
190
193
  }, c = n.level === void 0 ? 0 : s[n.level], l = n.scope?.toLowerCase(), u = n.source, d = n.filter?.toLowerCase(), f = n.traceId;
191
- for (let e of a) s[e.level] < c || u !== void 0 && e.source !== u || l !== void 0 && (e.scope === void 0 || !e.scope.toLowerCase().includes(l)) || d !== void 0 && !e.message.toLowerCase().includes(d) || f !== void 0 && e.fields.traceId !== f || o.push({
194
+ for (let e of a) s[e.level] < c || (u === void 0 || e.source === u) && (l !== void 0 && (e.scope === void 0 || !e.scope.toLowerCase().includes(l)) || d !== void 0 && !e.message.toLowerCase().includes(d) || (f === void 0 || e.fields.traceId === f) && o.push({
192
195
  ts: e.ts,
193
196
  level: e.level,
194
197
  source: e.source,
195
198
  message: e.message,
196
199
  fields: e.fields,
197
200
  ...e.scope === void 0 ? {} : { scope: e.scope }
198
- });
201
+ }));
199
202
  let p = o.length > n.tail ? o.slice(o.length - n.tail) : o;
200
203
  return {
201
204
  kind: "ok",
@@ -1,4 +1,4 @@
1
- import { P as e } from "./inspect-CjTYzAs_.js";
1
+ import { P as e } from "./inspect-B7U7Cl_Z.js";
2
2
  import { JSONSchema as t } from "effect";
3
3
  //#region src/manifestBuild.ts
4
4
  var n = (e) => {
@@ -0,0 +1,2 @@
1
+ import { t as e } from "./manifestBuild-BK42hu0k.js";
2
+ export { e as buildRpcEntry };
@@ -1,7 +1,7 @@
1
1
  import { i as e, n as t, r as n } from "./cliArgs-D4p8n7EE.js";
2
2
  import { t as r } from "./cliRuntime-Dh7UDinH.js";
3
3
  import { n as i } from "./renderProfile-1OWWAAtx.js";
4
- import { a, i as o } from "./projectScaffold-DDgWbNLe.js";
4
+ import { a, i as o } from "./projectScaffold-BvhLOrLq.js";
5
5
  import { t as s } from "./discover-C9XKJDco.js";
6
6
  import { basename as c, join as l, relative as u, resolve as d } from "node:path";
7
7
  import { createLogger as f } from "@voltro/logger";
@@ -1,6 +1,6 @@
1
1
  import { t as e } from "./cliError-BmdYnghb.js";
2
- import { r as t } from "./dialectDriver-CgXnDfec.js";
3
- import { a as n, r } from "./connectionConfig-UFlIEiys.js";
2
+ import { r as t } from "./dialectDriver-czCHYpeH.js";
3
+ import { a as n, r } from "./connectionConfig-Bk9IC7D0.js";
4
4
  import { n as i, s as a, y as o } from "./frameworkTableAssembly-oMPBKqlE.js";
5
5
  import { t as s } from "./cliRuntime-Dh7UDinH.js";
6
6
  import { join as c, relative as l, resolve as u } from "node:path";
@@ -75,8 +75,11 @@ var _ = /* @__PURE__ */ new Set([
75
75
  if (n === "memory") throw new e("voltro migrate: cannot migrate against an in-memory store. Set DB_DIALECT to one of: postgres, sqlite, mysql, mariadb, mssql, turso.");
76
76
  return t(n);
77
77
  }, T = async (e) => {
78
- if (e.includes("--create-only")) return s(S(u(e.find((e) => !e.startsWith("-")) ?? process.cwd())), { scope: "voltro:migrate" });
79
- let { runDbCommand: t } = await import("./dbCommand-CC-qNzpz.js");
78
+ if (e.includes("--create-only")) {
79
+ let t = u(e.find((e) => !e.startsWith("-")) ?? process.cwd());
80
+ return s(S(t), { scope: "voltro:migrate" });
81
+ }
82
+ let { runDbCommand: t } = await import("./dbCommand-DcqEyxju.js");
80
83
  return t(["apply", ...e]);
81
84
  };
82
85
  //#endregion
@@ -96,7 +96,7 @@ var p = d({ scope: "voltro:package" }), m = (e) => {
96
96
  if (typeof e == "string") return t(e) ?? e;
97
97
  if (e && typeof e == "object") {
98
98
  let n = {};
99
- for (let [r, i] of Object.entries(e)) typeof i == "string" ? n[r] = t(i) ?? i : n[r] = i;
99
+ for (let [r, i] of Object.entries(e)) n[r] = typeof i == "string" ? t(i) ?? i : i;
100
100
  return n;
101
101
  }
102
102
  return e;
@@ -239,7 +239,8 @@ var p = d({ scope: "voltro:package" }), m = (e) => {
239
239
  await P(o, a);
240
240
  let p = await N(o, a), m = F(a);
241
241
  return console.log(), console.log(`${l.name ?? r} → publishable${u ? " (already was; refreshed)" : ""}`), console.log(` version: ${d.version}`), console.log(" build: vite build (via @voltro/build preset)"), console.log(" publishConfig: exports/main/types → ./dist (dev exports unchanged)"), console.log(" tsconfig: rootDir:\"src\" + outDir:\"dist\" (emits to ./dist)"), f && console.log(" wrote: vite.config.ts"), p && console.log(" license: LICENSE copied from workspace root"), m && console.log(` api-extract: ${m}`), console.log(` publish via: pnpm --filter ${d.name} publish`), 0;
242
- } else return await k(c, T(l)), console.log(), console.log(`${l.name ?? r} → private (in-workspace source)${u ? "" : " (already was)"}`), console.log(" private: true; publishConfig/files/prepack removed; exports unchanged"), 0;
242
+ }
243
+ return await k(c, T(l)), console.log(), console.log(`${l.name ?? r} → private (in-workspace source)${u ? "" : " (already was)"}`), console.log(" private: true; publishConfig/files/prepack removed; exports unchanged"), 0;
243
244
  }, U = async (t) => {
244
245
  let n = g(process.cwd());
245
246
  if (!n) return p.error("no workspace root found", { cwd: process.cwd() }), 2;
@@ -1,6 +1,6 @@
1
- import { n as e } from "./cliOutput-D1tSBoRM.js";
2
- import { n as t, o as n, r, t as i } from "./inspectFetch-EMuhTG_9.js";
3
- import { n as a, t as o } from "./inspectGateHint-BF6608UT.js";
1
+ import { r as e, t } from "./inspectGateHint-BjnFubmH.js";
2
+ import { n } from "./cliOutput-D1tSBoRM.js";
3
+ import { n as r, o as i, r as a, t as o } from "./inspectFetch-EMuhTG_9.js";
4
4
  import { ansi as s } from "@voltro/logger";
5
5
  //#region src/probeCommand.ts
6
6
  var c = () => {
@@ -64,7 +64,7 @@ server and in this shell.`);
64
64
  payload: {},
65
65
  headers: []
66
66
  }), p = async (e, t) => {
67
- let { verdict: n, detail: r } = u(await i(e, "/rpc", {
67
+ let { verdict: n, detail: r } = u(await o(e, "/rpc", {
68
68
  method: "POST",
69
69
  body: f(t.tag),
70
70
  anonymous: !0
@@ -75,44 +75,55 @@ server and in this shell.`);
75
75
  verdict: n,
76
76
  detail: r
77
77
  };
78
- }, m = (t, n, r, i) => {
79
- let a = n.filter((e) => e.verdict === "admitted"), o = n.filter((e) => e.verdict === "inconclusive"), c = n.filter((e) => e.verdict === "refused");
80
- if (r === "json") e({
81
- app: t,
82
- probed: n.length,
78
+ }, m = (e, t, r, i) => {
79
+ let a = t.filter((e) => e.verdict === "admitted"), o = t.filter((e) => e.verdict === "inconclusive"), c = t.filter((e) => e.verdict === "refused");
80
+ if (r === "json") n({
81
+ app: e,
82
+ probed: t.length,
83
83
  refused: c.length,
84
84
  admitted: a.length,
85
85
  inconclusive: o.length,
86
- results: n
86
+ results: t
87
87
  });
88
- else if (n.length === 0) console.log(`${s.yellow("○")} ${t}: no guarded procedure to probe — every route is openAccess or undecided.`), console.log(" Undecided routes are `voltro check`'s finding, not this one's.");
88
+ else if (t.length === 0) console.log(`${s.yellow("○")} ${e}: no guarded procedure to probe — every route is openAccess or undecided.`), console.log(" Undecided routes are `voltro check`'s finding, not this one's.");
89
89
  else {
90
- console.log(`${s.bold(t)}: probed ${n.length} guarded procedure(s) with NO credentials`);
90
+ console.log(`${s.bold(e)}: probed ${t.length} guarded procedure(s) with NO credentials`);
91
91
  for (let e of a) console.log(` ${s.red("✗")} ${s.bold(e.tag)} — ${e.detail}`);
92
92
  for (let e of o) console.log(` ${s.yellow("?")} ${e.tag} — ${e.detail}`);
93
93
  console.log(` ${s.green("✓")} ${c.length} refused · ${s.yellow(String(o.length))} inconclusive · ${s.red(String(a.length))} admitted`);
94
94
  }
95
95
  return a.length > 0 ? (r !== "json" && console.error(`\n${s.red("A declared guard did not refuse an anonymous caller.")}\n The declaration and the behaviour disagree — the guard is on the descriptor and
96
96
  nothing enforces it on this path. Check that the procedure is bound through the
97
- dispatch spine (not a hand-mounted route), and that its guard list is not empty.`), 1) : i && o.length > 0 ? (r !== "json" && console.error(`\n${s.yellow("--strict:")} ${o.length} procedure(s) could not be judged.\n Their calls failed before the guard was reached (usually payload validation).
97
+ dispatch spine (not a hand-mounted route), and that its guard list is not empty.
98
+
99
+ ${s.yellow("RULE THAT OUT FIRST IF THIS IS A `voltro dev` PROCESS.")} A login-less request\n there does NOT resolve to a tenant-less subject: dev supplies a FALLBACK TENANT
100
+ (\`\$TENANT ?? 'acme'\`). So an app whose scopes derive from the tenant admits, and
101
+ this line says nothing about it — the caller was never anonymous. The local
102
+ registry only ever holds dev/start processes (\`voltro serve\` does not register),
103
+ so every target picked up WITHOUT --url is in that state.
104
+
105
+ For a verdict that means production, address a \`voltro serve\` process directly:
106
+ voltro probe access --url http://<host>:<port>
107
+ There an anonymous request carries \`tenantId: null\`, which is the case a guard
108
+ has to refuse — and the case a tenant-keyed role map most easily gets wrong.`), 1) : i && o.length > 0 ? (r !== "json" && console.error(`\n${s.yellow("--strict:")} ${o.length} procedure(s) could not be judged.\n Their calls failed before the guard was reached (usually payload validation).
98
109
  That is not evidence of enforcement, so under --strict it is not a pass.`), 1) : 0;
99
- }, h = async (e) => {
100
- let c = t(e);
110
+ }, h = async (n) => {
111
+ let c = r(n);
101
112
  if ("error" in c) return console.error(`voltro probe access: ${c.error}`), 1;
102
- let { format: u } = c, { process: d, target: f, rest: h, error: g } = r(c.rest);
113
+ let { format: u } = c, { process: d, target: f, rest: h, error: g } = a(c.rest);
103
114
  if (g !== void 0) return console.error(`voltro probe access: ${g}`), 1;
104
- let _ = h.includes("--strict"), v = await n(d, f);
115
+ let _ = h.includes("--strict"), v = await i(d, f);
105
116
  if (v.length === 0) return console.error("voltro probe access: no live api found.\n This command asks a RUNNING app what it does — there is nothing to ask a source tree.\n Start one (`voltro dev` / `voltro serve`), or address it directly with --url."), 1;
106
117
  let y = 0;
107
- for (let e of v) {
108
- let t = await i(e, "/_voltro/inspect/manifest");
109
- if (t.kind === "err" || t.status < 200 || t.status >= 300) {
110
- console.error(`${s.red("✗")} ${e.name}: could not read the manifest — ${t.kind === "err" ? t.error : `HTTP ${t.status}`}`), t.kind === "ok" && a(t.status) && console.error(` ${o(t.status)}`), y = 1;
118
+ for (let n of v) {
119
+ let r = await o(n, "/_voltro/inspect/manifest");
120
+ if (r.kind === "err" || r.status < 200 || r.status >= 300) {
121
+ console.error(`${s.red("✗")} ${n.name}: could not read the manifest — ${r.kind === "err" ? r.error : `HTTP ${r.status}`}`), r.kind === "ok" && e(r.status) && console.error(` ${t(r.status)}`), y = 1;
111
122
  continue;
112
123
  }
113
- let n = l(t.data?.procedures ?? []), r = [];
114
- for (let t of n) r.push(await p(e, t));
115
- y = Math.max(y, m(e.name, r, u, _));
124
+ let i = l(r.data?.procedures ?? []), a = [];
125
+ for (let e of i) a.push(await p(n, e));
126
+ y = Math.max(y, m(n.name, a, u, _));
116
127
  }
117
128
  return y;
118
129
  }, g = async (e) => {
@@ -1,2 +1,2 @@
1
- import { c as e, l as t, s as n } from "./projectScaffold-DDgWbNLe.js";
1
+ import { c as e, l as t, s as n } from "./projectScaffold-BvhLOrLq.js";
2
2
  export { n as runAddApp, e as runCreateProject, t as runListTemplates };
@@ -1,9 +1,9 @@
1
1
  import { a as e, i as t, n, r, t as i } from "./templates-BR-fb4SP.js";
2
2
  import { i as a, n as o, t as s } from "./cloudClient-DWL-Hw_T.js";
3
3
  import { t as c } from "./cliRuntime-Dh7UDinH.js";
4
- import { n as l } from "./agentsMd-mhQMF1bx.js";
5
- import { n as u } from "./addCommand-BNeoeSxe.js";
6
- import { a as d, n as f, r as p } from "./baselineCommand-C6NMt-oa.js";
4
+ import { n as l } from "./agentsMd-7zI2h5l9.js";
5
+ import { n as u } from "./addCommand-C05L9tZh.js";
6
+ import { a as d, n as f, r as p } from "./baselineCommand-Ck2Xm8M7.js";
7
7
  import { basename as m, dirname as h, join as g, resolve as _ } from "node:path";
8
8
  import { existsSync as v, mkdirSync as y, promises as b, writeFileSync as x } from "node:fs";
9
9
  import { createLogger as S } from "@voltro/logger";
@@ -366,7 +366,7 @@ ${U.join("\n")}
366
366
  if (v(a)) {
367
367
  let e = JSON.parse(await b.readFile(a, "utf8")), t = { ...e.scripts ?? {} }, n = { ...e.devDependencies ?? {} }, r = !1;
368
368
  for (let [e, n] of Object.entries(B)) t[e] === void 0 && (t[e] = n, r = !0);
369
- for (let [t, i] of Object.entries(V)) n[t] !== void 0 || e.dependencies?.[t] !== void 0 || (n[t] = i, r = !0);
369
+ for (let [t, i] of Object.entries(V)) n[t] === void 0 && e.dependencies?.[t] === void 0 && (n[t] = i, r = !0);
370
370
  r && (e.scripts = t, e.devDependencies = n, await b.writeFile(a, JSON.stringify(e, null, 2) + "\n", "utf8"), i.push("package.json"));
371
371
  } else {
372
372
  let e = de(), n = {
@@ -705,17 +705,19 @@ ${U.join("\n")}
705
705
  let x = g(m, b);
706
706
  if (v(x)) return R.error("create-project: target directory already exists", { projectDir: x }), 1;
707
707
  let S = _.api ?? null, C = _.web ?? null, w = _.mobile ?? null;
708
- if (!S && !C) if (_.noInput) S = "api-backend", C = "frontend-blank";
709
- else {
710
- let e = E({
711
- input: D,
712
- output: O
713
- });
714
- try {
715
- let t = (await e.question("Scaffold apps/api (api-backend) and apps/web (frontend-blank)? [Y/n]: ")).trim().toLowerCase();
716
- (t === "" || t === "y" || t === "yes") && (S = "api-backend", C = "frontend-blank");
717
- } finally {
718
- e.close();
708
+ if (!S && !C) {
709
+ if (_.noInput) S = "api-backend", C = "frontend-blank";
710
+ else {
711
+ let e = E({
712
+ input: D,
713
+ output: O
714
+ });
715
+ try {
716
+ let t = (await e.question("Scaffold apps/api (api-backend) and apps/web (frontend-blank)? [Y/n]: ")).trim().toLowerCase();
717
+ (t === "" || t === "y" || t === "yes") && (S = "api-backend", C = "frontend-blank");
718
+ } finally {
719
+ e.close();
720
+ }
719
721
  }
720
722
  }
721
723
  let T = S ? await n(S) : null, k = C ? await n(C) : null, A = w ? await n(w) : null;
@@ -1,4 +1,4 @@
1
- import { n as e } from "./apiBuild-CvacV4zA.js";
1
+ import { n as e } from "./apiBuild-D9FB13_2.js";
2
2
  import { join as t, resolve as n, sep as r } from "node:path";
3
3
  import { existsSync as i, promises as a } from "node:fs";
4
4
  import { createLogger as o } from "@voltro/logger";
@@ -162,13 +162,10 @@ external scheduler owns the once-only guarantee.
162
162
  content: `#!/bin/sh\n# AWS EventBridge Scheduler — generated from defineSchedule(...).\n# Review the cron translations flagged with ⚠ before applying.\nset -e\n\n${i.map((e) => m(e, n)).join("\n")}`
163
163
  });
164
164
  break;
165
- case "azure":
166
- a.push({
167
- path: ".voltro/scheduling/azure-recurrence.jsonc",
168
- content: i.map((e) => h(e, n)).join("\n")
169
- });
170
- break;
171
- case "generic": break;
165
+ case "azure": a.push({
166
+ path: ".voltro/scheduling/azure-recurrence.jsonc",
167
+ content: i.map((e) => h(e, n)).join("\n")
168
+ });
172
169
  }
173
170
  return a.push({
174
171
  path: ".voltro/scheduling/README.md",
@@ -209,8 +206,8 @@ external scheduler owns the once-only guarantee.
209
206
  ], C = async (s) => {
210
207
  let l = i(t(s, S) ?? process.cwd()), u, d = "app";
211
208
  try {
212
- let e = (await import(o(r(l, "app.config.ts")).href)).default ?? {};
213
- d = typeof e.name == "string" ? e.name : d, u = e.scheduling?.externalProvider;
209
+ let e = r(l, "app.config.ts"), t = (await import(o(e).href)).default ?? {};
210
+ d = typeof t.name == "string" ? t.name : d, u = t.scheduling?.externalProvider;
214
211
  } catch {}
215
212
  let f = e(s, "--provider") ?? u ?? "generic";
216
213
  if (!y.has(f)) return v.error(`unknown --provider "${f}" (expected: ${[...y].join(", ")})`), 1;
@@ -422,7 +422,7 @@ let package = Package(
422
422
  await l.mkdir(o(e), { recursive: !0 }), await l.writeFile(e, n.content, "utf8");
423
423
  }
424
424
  }, X = async (e) => {
425
- let { offlineManifest: t } = await import("./checkCommand-wibtQx-N.js"), { manifest: n } = await t(e);
425
+ let { offlineManifest: t } = await import("./checkCommand-D9qK_gtA.js"), { manifest: n } = await t(e);
426
426
  return n;
427
427
  }, Z = async (e) => {
428
428
  let t = J(await (e.manifestProvider ?? X)(e.root), {
@@ -461,8 +461,7 @@ let package = Package(
461
461
  }, te = (e, t) => c(e, "sdk", t), ne = async (t, n = process.cwd()) => {
462
462
  let r = $(t, n);
463
463
  if ("error" in r) return console.error(`voltro build --target: ${r.error}`), 1;
464
- let i = r.outDir ?? te(r.root, r.target);
465
- return e(d.gen(function* () {
464
+ let i = r.outDir ?? te(r.root, r.target), a = d.gen(function* () {
466
465
  let e = yield* d.tryPromise({
467
466
  try: () => Z({
468
467
  root: r.root,
@@ -478,7 +477,8 @@ let package = Package(
478
477
  files: e.files.length,
479
478
  out: i
480
479
  })), 0;
481
- }), { scope: "voltro:sdk" });
480
+ });
481
+ return e(a, { scope: "voltro:sdk" });
482
482
  };
483
483
  //#endregion
484
484
  export { ne as runSdkBuildCommand };
@@ -88,10 +88,7 @@ var y = (e, t = process.env) => {
88
88
  stale: i.stale
89
89
  });
90
90
  break;
91
- case "failed":
92
- e.log.warn("reactive triggers: the boot check could not run — reactivity may be silently degraded. Run `voltro db apply` to converge them explicitly.", { error: i.detail });
93
- break;
94
- default: break;
91
+ case "failed": e.log.warn("reactive triggers: the boot check could not run — reactivity may be silently degraded. Run `voltro db apply` to converge them explicitly.", { error: i.detail });
95
92
  }
96
93
  return i;
97
94
  }, C = async (n, r) => {