@wildo-ai/platform-config-lib 1.0.1 → 1.1.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 (414) hide show
  1. package/LICENSE +34 -0
  2. package/dist/esm/.builder.pid +9 -0
  3. package/dist/esm/_unimplemented/index.d.ts +3 -0
  4. package/dist/esm/_unimplemented/index.d.ts.map +1 -0
  5. package/dist/esm/_unimplemented/index.js +3 -0
  6. package/dist/esm/_unimplemented/index.js.map +1 -0
  7. package/dist/esm/_unimplemented/soft-warn.d.ts +124 -0
  8. package/dist/esm/_unimplemented/soft-warn.d.ts.map +1 -0
  9. package/dist/esm/_unimplemented/soft-warn.js +170 -0
  10. package/dist/esm/_unimplemented/soft-warn.js.map +1 -0
  11. package/dist/esm/_unimplemented/unimplemented-field-warning.d.ts +137 -0
  12. package/dist/esm/_unimplemented/unimplemented-field-warning.d.ts.map +1 -0
  13. package/dist/esm/_unimplemented/unimplemented-field-warning.js +153 -0
  14. package/dist/esm/_unimplemented/unimplemented-field-warning.js.map +1 -0
  15. package/dist/esm/bootstrap/application-backend-env.contracts.d.ts.map +1 -1
  16. package/dist/esm/bootstrap/application-backend-env.contracts.js +1 -1
  17. package/dist/esm/bootstrap/application-backend-env.contracts.js.map +1 -1
  18. package/dist/esm/bootstrap/application-creation-verification-env.contracts.d.ts +13 -0
  19. package/dist/esm/bootstrap/application-creation-verification-env.contracts.d.ts.map +1 -0
  20. package/dist/esm/bootstrap/application-creation-verification-env.contracts.js +14 -0
  21. package/dist/esm/bootstrap/application-creation-verification-env.contracts.js.map +1 -0
  22. package/dist/esm/bootstrap/bootstrap-planner.d.ts +1 -1
  23. package/dist/esm/bootstrap/bootstrap-planner.d.ts.map +1 -1
  24. package/dist/esm/bootstrap/bootstrap-planner.js +1 -1
  25. package/dist/esm/bootstrap/bootstrap-planner.js.map +1 -1
  26. package/dist/esm/bootstrap/bootstrap.contracts.d.ts +141 -37
  27. package/dist/esm/bootstrap/bootstrap.contracts.d.ts.map +1 -1
  28. package/dist/esm/bootstrap/bootstrap.contracts.js +104 -18
  29. package/dist/esm/bootstrap/bootstrap.contracts.js.map +1 -1
  30. package/dist/esm/bootstrap/bootstrap.schemas.d.ts +430 -421
  31. package/dist/esm/bootstrap/bootstrap.schemas.d.ts.map +1 -1
  32. package/dist/esm/bootstrap/bootstrap.schemas.js +383 -21
  33. package/dist/esm/bootstrap/bootstrap.schemas.js.map +1 -1
  34. package/dist/esm/bootstrap/platform-runtime-env.contracts.d.ts +213 -8
  35. package/dist/esm/bootstrap/platform-runtime-env.contracts.d.ts.map +1 -1
  36. package/dist/esm/bootstrap/platform-runtime-env.contracts.js +230 -5
  37. package/dist/esm/bootstrap/platform-runtime-env.contracts.js.map +1 -1
  38. package/dist/esm/bootstrap/runtime-backing-service-access.d.ts +79 -0
  39. package/dist/esm/bootstrap/runtime-backing-service-access.d.ts.map +1 -0
  40. package/dist/esm/bootstrap/runtime-backing-service-access.js +83 -0
  41. package/dist/esm/bootstrap/runtime-backing-service-access.js.map +1 -0
  42. package/dist/esm/bootstrap/runtime-network-policy.d.ts +63 -0
  43. package/dist/esm/bootstrap/runtime-network-policy.d.ts.map +1 -0
  44. package/dist/esm/bootstrap/runtime-network-policy.js +104 -0
  45. package/dist/esm/bootstrap/runtime-network-policy.js.map +1 -0
  46. package/dist/esm/bootstrap/runtime-network-topology.d.ts +78 -0
  47. package/dist/esm/bootstrap/runtime-network-topology.d.ts.map +1 -0
  48. package/dist/esm/bootstrap/runtime-network-topology.js +134 -0
  49. package/dist/esm/bootstrap/runtime-network-topology.js.map +1 -0
  50. package/dist/esm/bootstrap/runtime-platform-access.d.ts +67 -0
  51. package/dist/esm/bootstrap/runtime-platform-access.d.ts.map +1 -0
  52. package/dist/esm/bootstrap/runtime-platform-access.js +57 -0
  53. package/dist/esm/bootstrap/runtime-platform-access.js.map +1 -0
  54. package/dist/esm/bootstrap/runtime-principal.contracts.d.ts +173 -0
  55. package/dist/esm/bootstrap/runtime-principal.contracts.d.ts.map +1 -0
  56. package/dist/esm/bootstrap/runtime-principal.contracts.js +218 -0
  57. package/dist/esm/bootstrap/runtime-principal.contracts.js.map +1 -0
  58. package/dist/esm/bootstrap/runtime-topology.contracts.d.ts +112 -1
  59. package/dist/esm/bootstrap/runtime-topology.contracts.d.ts.map +1 -1
  60. package/dist/esm/bootstrap/runtime-topology.contracts.js +141 -8
  61. package/dist/esm/bootstrap/runtime-topology.contracts.js.map +1 -1
  62. package/dist/esm/config-authoring.entry.d.ts +3 -0
  63. package/dist/esm/config-authoring.entry.d.ts.map +1 -0
  64. package/dist/esm/config-authoring.entry.js +5 -0
  65. package/dist/esm/config-authoring.entry.js.map +1 -0
  66. package/dist/esm/credentials/credential-generator.service.d.ts.map +1 -1
  67. package/dist/esm/credentials/credential-generator.service.js +1 -1
  68. package/dist/esm/credentials/credential-generator.service.js.map +1 -1
  69. package/dist/esm/index.d.ts +30 -15
  70. package/dist/esm/index.d.ts.map +1 -1
  71. package/dist/esm/index.js +16 -1
  72. package/dist/esm/index.js.map +1 -1
  73. package/dist/esm/lockfile/canonical-json.d.ts +41 -0
  74. package/dist/esm/lockfile/canonical-json.d.ts.map +1 -0
  75. package/dist/esm/lockfile/canonical-json.js +56 -0
  76. package/dist/esm/lockfile/canonical-json.js.map +1 -0
  77. package/dist/esm/lockfile/lockfile-io.d.ts +231 -0
  78. package/dist/esm/lockfile/lockfile-io.d.ts.map +1 -0
  79. package/dist/esm/lockfile/lockfile-io.js +303 -0
  80. package/dist/esm/lockfile/lockfile-io.js.map +1 -0
  81. package/dist/esm/lockfile/materialize-infra-section.d.ts +99 -0
  82. package/dist/esm/lockfile/materialize-infra-section.d.ts.map +1 -0
  83. package/dist/esm/lockfile/materialize-infra-section.js +153 -0
  84. package/dist/esm/lockfile/materialize-infra-section.js.map +1 -0
  85. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.d.ts +522 -0
  86. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.d.ts.map +1 -0
  87. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.js +116 -0
  88. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.js.map +1 -0
  89. package/dist/esm/project-config/define-framework-config.d.ts +36 -10
  90. package/dist/esm/project-config/define-framework-config.d.ts.map +1 -1
  91. package/dist/esm/project-config/define-framework-config.js +67 -3
  92. package/dist/esm/project-config/define-framework-config.js.map +1 -1
  93. package/dist/esm/project-config/define-infra-env-config.d.ts +570 -0
  94. package/dist/esm/project-config/define-infra-env-config.d.ts.map +1 -0
  95. package/dist/esm/project-config/define-infra-env-config.js +726 -0
  96. package/dist/esm/project-config/define-infra-env-config.js.map +1 -0
  97. package/dist/esm/project-config/define-minion-config.d.ts +221 -23
  98. package/dist/esm/project-config/define-minion-config.d.ts.map +1 -1
  99. package/dist/esm/project-config/define-minion-config.js +228 -11
  100. package/dist/esm/project-config/define-minion-config.js.map +1 -1
  101. package/dist/esm/project-config/define-saas-config.d.ts +427 -218
  102. package/dist/esm/project-config/define-saas-config.d.ts.map +1 -1
  103. package/dist/esm/project-config/define-saas-config.js +704 -75
  104. package/dist/esm/project-config/define-saas-config.js.map +1 -1
  105. package/dist/esm/project-config/define-worker-config.d.ts +106 -10
  106. package/dist/esm/project-config/define-worker-config.d.ts.map +1 -1
  107. package/dist/esm/project-config/define-worker-config.js +99 -9
  108. package/dist/esm/project-config/define-worker-config.js.map +1 -1
  109. package/dist/esm/project-config/index.d.ts +28 -21
  110. package/dist/esm/project-config/index.d.ts.map +1 -1
  111. package/dist/esm/project-config/index.js +14 -7
  112. package/dist/esm/project-config/index.js.map +1 -1
  113. package/dist/esm/project-config/loader.d.ts +120 -10
  114. package/dist/esm/project-config/loader.d.ts.map +1 -1
  115. package/dist/esm/project-config/loader.js +290 -38
  116. package/dist/esm/project-config/loader.js.map +1 -1
  117. package/dist/esm/project-config/minion-local-provider-registration.d.ts +69 -0
  118. package/dist/esm/project-config/minion-local-provider-registration.d.ts.map +1 -0
  119. package/dist/esm/project-config/minion-local-provider-registration.js +72 -0
  120. package/dist/esm/project-config/minion-local-provider-registration.js.map +1 -0
  121. package/dist/esm/project-config/provider-catalog-types.d.ts +12 -0
  122. package/dist/esm/project-config/provider-catalog-types.d.ts.map +1 -0
  123. package/dist/esm/project-config/provider-catalog-types.js +49 -0
  124. package/dist/esm/project-config/provider-catalog-types.js.map +1 -0
  125. package/dist/esm/project-config/provider-companion-discovery.d.ts +24 -0
  126. package/dist/esm/project-config/provider-companion-discovery.d.ts.map +1 -0
  127. package/dist/esm/project-config/provider-companion-discovery.js +244 -0
  128. package/dist/esm/project-config/provider-companion-discovery.js.map +1 -0
  129. package/dist/esm/project-config/provider-runtime-artifacts.d.ts +297 -0
  130. package/dist/esm/project-config/provider-runtime-artifacts.d.ts.map +1 -0
  131. package/dist/esm/project-config/provider-runtime-artifacts.js +860 -0
  132. package/dist/esm/project-config/provider-runtime-artifacts.js.map +1 -0
  133. package/dist/esm/project-config/shared/application-creation-verification.schemas.d.ts +18 -0
  134. package/dist/esm/project-config/shared/application-creation-verification.schemas.d.ts.map +1 -0
  135. package/dist/esm/project-config/shared/application-creation-verification.schemas.js +25 -0
  136. package/dist/esm/project-config/shared/application-creation-verification.schemas.js.map +1 -0
  137. package/dist/esm/project-config/shared/application-modules.schemas.d.ts +10 -2
  138. package/dist/esm/project-config/shared/application-modules.schemas.d.ts.map +1 -1
  139. package/dist/esm/project-config/shared/application-modules.schemas.js +12 -1
  140. package/dist/esm/project-config/shared/application-modules.schemas.js.map +1 -1
  141. package/dist/esm/project-config/shared/application-modules.utils.d.ts +2 -1
  142. package/dist/esm/project-config/shared/application-modules.utils.d.ts.map +1 -1
  143. package/dist/esm/project-config/shared/application-modules.utils.js +6 -1
  144. package/dist/esm/project-config/shared/application-modules.utils.js.map +1 -1
  145. package/dist/esm/project-config/shared/auth.schemas.d.ts +102 -0
  146. package/dist/esm/project-config/shared/auth.schemas.d.ts.map +1 -0
  147. package/dist/esm/project-config/shared/auth.schemas.js +100 -0
  148. package/dist/esm/project-config/shared/auth.schemas.js.map +1 -0
  149. package/dist/esm/project-config/shared/backing-services.schemas.d.ts +316 -39
  150. package/dist/esm/project-config/shared/backing-services.schemas.d.ts.map +1 -1
  151. package/dist/esm/project-config/shared/backing-services.schemas.js +359 -24
  152. package/dist/esm/project-config/shared/backing-services.schemas.js.map +1 -1
  153. package/dist/esm/project-config/shared/cdn.example.d.ts +14 -0
  154. package/dist/esm/project-config/shared/cdn.example.d.ts.map +1 -0
  155. package/dist/esm/project-config/shared/cdn.example.js +38 -0
  156. package/dist/esm/project-config/shared/cdn.example.js.map +1 -0
  157. package/dist/esm/project-config/shared/cdn.schemas.d.ts +182 -0
  158. package/dist/esm/project-config/shared/cdn.schemas.d.ts.map +1 -0
  159. package/dist/esm/project-config/shared/cdn.schemas.js +151 -0
  160. package/dist/esm/project-config/shared/cdn.schemas.js.map +1 -0
  161. package/dist/esm/project-config/shared/csp-defaults.d.ts +92 -0
  162. package/dist/esm/project-config/shared/csp-defaults.d.ts.map +1 -0
  163. package/dist/esm/project-config/shared/csp-defaults.js +195 -0
  164. package/dist/esm/project-config/shared/csp-defaults.js.map +1 -0
  165. package/dist/esm/project-config/shared/csp-emit.d.ts +106 -0
  166. package/dist/esm/project-config/shared/csp-emit.d.ts.map +1 -0
  167. package/dist/esm/project-config/shared/csp-emit.js +305 -0
  168. package/dist/esm/project-config/shared/csp-emit.js.map +1 -0
  169. package/dist/esm/project-config/shared/csp.schemas.d.ts +266 -0
  170. package/dist/esm/project-config/shared/csp.schemas.d.ts.map +1 -0
  171. package/dist/esm/project-config/shared/csp.schemas.js +281 -0
  172. package/dist/esm/project-config/shared/csp.schemas.js.map +1 -0
  173. package/dist/esm/project-config/shared/data-services.schemas.d.ts +45 -9
  174. package/dist/esm/project-config/shared/data-services.schemas.d.ts.map +1 -1
  175. package/dist/esm/project-config/shared/data-services.schemas.js +45 -9
  176. package/dist/esm/project-config/shared/data-services.schemas.js.map +1 -1
  177. package/dist/esm/project-config/shared/env-example-defaults.d.ts +0 -1
  178. package/dist/esm/project-config/shared/env-example-defaults.d.ts.map +1 -1
  179. package/dist/esm/project-config/shared/env-example-defaults.js +1 -2
  180. package/dist/esm/project-config/shared/env-example-defaults.js.map +1 -1
  181. package/dist/esm/project-config/shared/environment.schemas.d.ts +134 -8
  182. package/dist/esm/project-config/shared/environment.schemas.d.ts.map +1 -1
  183. package/dist/esm/project-config/shared/environment.schemas.js +185 -2
  184. package/dist/esm/project-config/shared/environment.schemas.js.map +1 -1
  185. package/dist/esm/project-config/shared/infra-providers.schemas.d.ts +779 -0
  186. package/dist/esm/project-config/shared/infra-providers.schemas.d.ts.map +1 -0
  187. package/dist/esm/project-config/shared/infra-providers.schemas.js +210 -0
  188. package/dist/esm/project-config/shared/infra-providers.schemas.js.map +1 -0
  189. package/dist/esm/project-config/shared/infra-service.schemas.d.ts +18 -0
  190. package/dist/esm/project-config/shared/infra-service.schemas.d.ts.map +1 -0
  191. package/dist/esm/project-config/shared/infra-service.schemas.js +16 -0
  192. package/dist/esm/project-config/shared/infra-service.schemas.js.map +1 -0
  193. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.d.ts +83 -1
  194. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.d.ts.map +1 -1
  195. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.js +99 -2
  196. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.js.map +1 -1
  197. package/dist/esm/project-config/shared/k8s-utils.d.ts +51 -7
  198. package/dist/esm/project-config/shared/k8s-utils.d.ts.map +1 -1
  199. package/dist/esm/project-config/shared/k8s-utils.js +59 -12
  200. package/dist/esm/project-config/shared/k8s-utils.js.map +1 -1
  201. package/dist/esm/project-config/shared/minion-platform-access.vocabulary.d.ts +31 -0
  202. package/dist/esm/project-config/shared/minion-platform-access.vocabulary.d.ts.map +1 -0
  203. package/dist/esm/project-config/shared/minion-platform-access.vocabulary.js +32 -0
  204. package/dist/esm/project-config/shared/minion-platform-access.vocabulary.js.map +1 -0
  205. package/dist/esm/project-config/shared/minion-resource-access.validation.d.ts +142 -0
  206. package/dist/esm/project-config/shared/minion-resource-access.validation.d.ts.map +1 -0
  207. package/dist/esm/project-config/shared/minion-resource-access.validation.js +159 -0
  208. package/dist/esm/project-config/shared/minion-resource-access.validation.js.map +1 -0
  209. package/dist/esm/project-config/shared/object-storage-session-policy.d.ts +100 -0
  210. package/dist/esm/project-config/shared/object-storage-session-policy.d.ts.map +1 -0
  211. package/dist/esm/project-config/shared/object-storage-session-policy.js +130 -0
  212. package/dist/esm/project-config/shared/object-storage-session-policy.js.map +1 -0
  213. package/dist/esm/project-config/shared/platform-services.schemas.d.ts +9 -14
  214. package/dist/esm/project-config/shared/platform-services.schemas.d.ts.map +1 -1
  215. package/dist/esm/project-config/shared/platform-services.schemas.js +13 -9
  216. package/dist/esm/project-config/shared/platform-services.schemas.js.map +1 -1
  217. package/dist/esm/project-config/shared/schema-version.schemas.d.ts +15 -0
  218. package/dist/esm/project-config/shared/schema-version.schemas.d.ts.map +1 -0
  219. package/dist/esm/project-config/shared/schema-version.schemas.js +40 -0
  220. package/dist/esm/project-config/shared/schema-version.schemas.js.map +1 -0
  221. package/dist/esm/project-config/shared/service-definitions.schemas.d.ts +283 -8
  222. package/dist/esm/project-config/shared/service-definitions.schemas.d.ts.map +1 -1
  223. package/dist/esm/project-config/shared/service-definitions.schemas.js +325 -8
  224. package/dist/esm/project-config/shared/service-definitions.schemas.js.map +1 -1
  225. package/dist/esm/registry/artifact-domain.schemas.d.ts +54 -0
  226. package/dist/esm/registry/artifact-domain.schemas.d.ts.map +1 -0
  227. package/dist/esm/registry/artifact-domain.schemas.js +40 -0
  228. package/dist/esm/registry/artifact-domain.schemas.js.map +1 -0
  229. package/dist/esm/registry/companion-api.schemas.d.ts +176 -0
  230. package/dist/esm/registry/companion-api.schemas.d.ts.map +1 -0
  231. package/dist/esm/registry/companion-api.schemas.js +165 -0
  232. package/dist/esm/registry/companion-api.schemas.js.map +1 -0
  233. package/dist/esm/registry/digest.schemas.d.ts +20 -0
  234. package/dist/esm/registry/digest.schemas.d.ts.map +1 -0
  235. package/dist/esm/registry/digest.schemas.js +21 -0
  236. package/dist/esm/registry/digest.schemas.js.map +1 -0
  237. package/dist/esm/registry/index.d.ts +33 -0
  238. package/dist/esm/registry/index.d.ts.map +1 -0
  239. package/dist/esm/registry/index.js +33 -0
  240. package/dist/esm/registry/index.js.map +1 -0
  241. package/dist/esm/registry/lockfile-modules-section.schemas.d.ts +107 -0
  242. package/dist/esm/registry/lockfile-modules-section.schemas.d.ts.map +1 -0
  243. package/dist/esm/registry/lockfile-modules-section.schemas.js +67 -0
  244. package/dist/esm/registry/lockfile-modules-section.schemas.js.map +1 -0
  245. package/dist/esm/registry/module-artifact.schemas.d.ts +94 -0
  246. package/dist/esm/registry/module-artifact.schemas.d.ts.map +1 -0
  247. package/dist/esm/registry/module-artifact.schemas.js +69 -0
  248. package/dist/esm/registry/module-artifact.schemas.js.map +1 -0
  249. package/dist/esm/registry/module-manifest.schemas.d.ts +134 -0
  250. package/dist/esm/registry/module-manifest.schemas.d.ts.map +1 -0
  251. package/dist/esm/registry/module-manifest.schemas.js +155 -0
  252. package/dist/esm/registry/module-manifest.schemas.js.map +1 -0
  253. package/dist/esm/registry/registry-config.schemas.d.ts +31 -0
  254. package/dist/esm/registry/registry-config.schemas.d.ts.map +1 -0
  255. package/dist/esm/registry/registry-config.schemas.js +24 -0
  256. package/dist/esm/registry/registry-config.schemas.js.map +1 -0
  257. package/dist/esm/registry/registry-defaults.constants.d.ts +37 -0
  258. package/dist/esm/registry/registry-defaults.constants.d.ts.map +1 -0
  259. package/dist/esm/registry/registry-defaults.constants.js +37 -0
  260. package/dist/esm/registry/registry-defaults.constants.js.map +1 -0
  261. package/dist/esm/registry/registry-errors.d.ts +109 -0
  262. package/dist/esm/registry/registry-errors.d.ts.map +1 -0
  263. package/dist/esm/registry/registry-errors.js +185 -0
  264. package/dist/esm/registry/registry-errors.js.map +1 -0
  265. package/dist/esm/registry/registry-section-schemas.constants.d.ts +39 -0
  266. package/dist/esm/registry/registry-section-schemas.constants.d.ts.map +1 -0
  267. package/dist/esm/registry/registry-section-schemas.constants.js +22 -0
  268. package/dist/esm/registry/registry-section-schemas.constants.js.map +1 -0
  269. package/dist/esm/release/framework-release.constants.d.ts +26 -1
  270. package/dist/esm/release/framework-release.constants.d.ts.map +1 -1
  271. package/dist/esm/release/framework-release.constants.js +27 -2
  272. package/dist/esm/release/framework-release.constants.js.map +1 -1
  273. package/dist/esm/schemas/framework-info.schemas.d.ts +1 -1
  274. package/dist/esm/schemas/framework-info.schemas.d.ts.map +1 -1
  275. package/dist/esm/schemas/framework-info.schemas.js +1 -1
  276. package/dist/esm/schemas/framework-info.schemas.js.map +1 -1
  277. package/dist/esm/schemas/framework-secrets.schemas.d.ts +5 -5
  278. package/dist/esm/schemas/framework-secrets.schemas.d.ts.map +1 -1
  279. package/dist/esm/schemas/framework-secrets.schemas.js +1 -1
  280. package/dist/esm/schemas/framework-secrets.schemas.js.map +1 -1
  281. package/dist/esm/schemas/platform-application-config.schemas.d.ts +1 -1
  282. package/dist/esm/schemas/platform-application-config.schemas.d.ts.map +1 -1
  283. package/dist/esm/schemas/platform-application-config.schemas.js +11 -2
  284. package/dist/esm/schemas/platform-application-config.schemas.js.map +1 -1
  285. package/dist/esm/schemas/platform-application-secrets.schemas.d.ts +7 -7
  286. package/dist/esm/schemas/platform-application-secrets.schemas.d.ts.map +1 -1
  287. package/dist/esm/schemas/platform-application-secrets.schemas.js +17 -2
  288. package/dist/esm/schemas/platform-application-secrets.schemas.js.map +1 -1
  289. package/dist/esm/schemas/platform-config.schemas.d.ts +12 -13
  290. package/dist/esm/schemas/platform-config.schemas.d.ts.map +1 -1
  291. package/dist/esm/schemas/platform-config.schemas.js +15 -3
  292. package/dist/esm/schemas/platform-config.schemas.js.map +1 -1
  293. package/dist/esm/workspace-scope/application-subject-manifest.d.ts +26 -0
  294. package/dist/esm/workspace-scope/application-subject-manifest.d.ts.map +1 -0
  295. package/dist/esm/workspace-scope/application-subject-manifest.js +43 -0
  296. package/dist/esm/workspace-scope/application-subject-manifest.js.map +1 -0
  297. package/dist/esm/workspace-scope/index.d.ts +5 -2
  298. package/dist/esm/workspace-scope/index.d.ts.map +1 -1
  299. package/dist/esm/workspace-scope/index.js +4 -1
  300. package/dist/esm/workspace-scope/index.js.map +1 -1
  301. package/dist/esm/workspace-scope/resolve-homes.d.ts +20 -0
  302. package/dist/esm/workspace-scope/resolve-homes.d.ts.map +1 -0
  303. package/dist/esm/workspace-scope/resolve-homes.js +62 -0
  304. package/dist/esm/workspace-scope/resolve-homes.js.map +1 -0
  305. package/dist/esm/workspace-scope/workspace-homes.schemas.d.ts +211 -0
  306. package/dist/esm/workspace-scope/workspace-homes.schemas.d.ts.map +1 -0
  307. package/dist/esm/workspace-scope/workspace-homes.schemas.js +113 -0
  308. package/dist/esm/workspace-scope/workspace-homes.schemas.js.map +1 -0
  309. package/dist/esm/workspace-scope/workspace-scope-detector.d.ts +10 -5
  310. package/dist/esm/workspace-scope/workspace-scope-detector.d.ts.map +1 -1
  311. package/dist/esm/workspace-scope/workspace-scope-detector.js +22 -36
  312. package/dist/esm/workspace-scope/workspace-scope-detector.js.map +1 -1
  313. package/dist/esm/workspace-scope/workspace-scope.schemas.d.ts +147 -58
  314. package/dist/esm/workspace-scope/workspace-scope.schemas.d.ts.map +1 -1
  315. package/dist/esm/workspace-scope/workspace-scope.schemas.js +174 -78
  316. package/dist/esm/workspace-scope/workspace-scope.schemas.js.map +1 -1
  317. package/dist/tsconfig.build.tsbuildinfo +1 -1
  318. package/package.json +31 -17
  319. package/dist/esm/credentials/credentials-provisioner.service.d.ts +0 -190
  320. package/dist/esm/credentials/credentials-provisioner.service.d.ts.map +0 -1
  321. package/dist/esm/credentials/credentials-provisioner.service.js +0 -278
  322. package/dist/esm/credentials/credentials-provisioner.service.js.map +0 -1
  323. package/dist/esm/infra-managers/infra-manager.models.d.ts +0 -146
  324. package/dist/esm/infra-managers/infra-manager.models.d.ts.map +0 -1
  325. package/dist/esm/infra-managers/infra-manager.models.js +0 -2
  326. package/dist/esm/infra-managers/infra-manager.models.js.map +0 -1
  327. package/dist/esm/infra-managers/mongo-atlas-manager.service.d.ts +0 -64
  328. package/dist/esm/infra-managers/mongo-atlas-manager.service.d.ts.map +0 -1
  329. package/dist/esm/infra-managers/mongo-atlas-manager.service.js +0 -307
  330. package/dist/esm/infra-managers/mongo-atlas-manager.service.js.map +0 -1
  331. package/dist/esm/infra-managers/postgresql-manager.service.d.ts +0 -115
  332. package/dist/esm/infra-managers/postgresql-manager.service.d.ts.map +0 -1
  333. package/dist/esm/infra-managers/postgresql-manager.service.js +0 -403
  334. package/dist/esm/infra-managers/postgresql-manager.service.js.map +0 -1
  335. package/dist/esm/infra-managers/rabbitmq-manager.service.d.ts +0 -64
  336. package/dist/esm/infra-managers/rabbitmq-manager.service.d.ts.map +0 -1
  337. package/dist/esm/infra-managers/rabbitmq-manager.service.js +0 -288
  338. package/dist/esm/infra-managers/rabbitmq-manager.service.js.map +0 -1
  339. package/dist/esm/infra-managers/redis-manager.service.d.ts +0 -78
  340. package/dist/esm/infra-managers/redis-manager.service.d.ts.map +0 -1
  341. package/dist/esm/infra-managers/redis-manager.service.js +0 -326
  342. package/dist/esm/infra-managers/redis-manager.service.js.map +0 -1
  343. package/dist/esm/project-config/define-infra-config.d.ts +0 -128
  344. package/dist/esm/project-config/define-infra-config.d.ts.map +0 -1
  345. package/dist/esm/project-config/define-infra-config.js +0 -87
  346. package/dist/esm/project-config/define-infra-config.js.map +0 -1
  347. package/dist/esm/project-config/define-platform-config.d.ts +0 -65
  348. package/dist/esm/project-config/define-platform-config.d.ts.map +0 -1
  349. package/dist/esm/project-config/define-platform-config.js +0 -22
  350. package/dist/esm/project-config/define-platform-config.js.map +0 -1
  351. package/dist/esm/project-config/define-platform-env-config.d.ts +0 -41
  352. package/dist/esm/project-config/define-platform-env-config.d.ts.map +0 -1
  353. package/dist/esm/project-config/define-platform-env-config.js +0 -45
  354. package/dist/esm/project-config/define-platform-env-config.js.map +0 -1
  355. package/dist/esm/project-config/define-project-config.d.ts +0 -38
  356. package/dist/esm/project-config/define-project-config.d.ts.map +0 -1
  357. package/dist/esm/project-config/define-project-config.js +0 -57
  358. package/dist/esm/project-config/define-project-config.js.map +0 -1
  359. package/dist/esm/project-config/define-sharing-policy.d.ts +0 -35
  360. package/dist/esm/project-config/define-sharing-policy.d.ts.map +0 -1
  361. package/dist/esm/project-config/define-sharing-policy.js +0 -30
  362. package/dist/esm/project-config/define-sharing-policy.js.map +0 -1
  363. package/dist/esm/project-config/sharing-policy-validation.d.ts +0 -40
  364. package/dist/esm/project-config/sharing-policy-validation.d.ts.map +0 -1
  365. package/dist/esm/project-config/sharing-policy-validation.js +0 -143
  366. package/dist/esm/project-config/sharing-policy-validation.js.map +0 -1
  367. package/dist/esm/runtime-bridge/platform-runtime-bridge.contracts.d.ts +0 -23
  368. package/dist/esm/runtime-bridge/platform-runtime-bridge.contracts.d.ts.map +0 -1
  369. package/dist/esm/runtime-bridge/platform-runtime-bridge.contracts.js +0 -13
  370. package/dist/esm/runtime-bridge/platform-runtime-bridge.contracts.js.map +0 -1
  371. package/src/bootstrap/application-backend-env.contracts.ts +0 -17
  372. package/src/bootstrap/bootstrap-planner.ts +0 -46
  373. package/src/bootstrap/bootstrap.contracts.ts +0 -251
  374. package/src/bootstrap/bootstrap.schemas.ts +0 -164
  375. package/src/bootstrap/platform-runtime-env.contracts.ts +0 -99
  376. package/src/bootstrap/runtime-topology.contracts.ts +0 -102
  377. package/src/credentials/credential-generator.service.ts +0 -39
  378. package/src/index.ts +0 -16
  379. package/src/project-config/__tests__/application-modules.utils.test.ts +0 -53
  380. package/src/project-config/__tests__/define-framework-config.test.ts +0 -43
  381. package/src/project-config/__tests__/define-saas-config.test.ts +0 -210
  382. package/src/project-config/__tests__/loader.test.ts +0 -100
  383. package/src/project-config/define-framework-config.ts +0 -44
  384. package/src/project-config/define-infra-config.ts +0 -168
  385. package/src/project-config/define-minion-config.ts +0 -27
  386. package/src/project-config/define-platform-config.ts +0 -28
  387. package/src/project-config/define-platform-env-config.ts +0 -59
  388. package/src/project-config/define-project-config.ts +0 -63
  389. package/src/project-config/define-saas-config.ts +0 -171
  390. package/src/project-config/define-sharing-policy.ts +0 -36
  391. package/src/project-config/define-worker-config.ts +0 -27
  392. package/src/project-config/index.ts +0 -23
  393. package/src/project-config/loader.ts +0 -220
  394. package/src/project-config/shared/application-modules.schemas.ts +0 -12
  395. package/src/project-config/shared/application-modules.utils.ts +0 -65
  396. package/src/project-config/shared/backing-services.schemas.ts +0 -59
  397. package/src/project-config/shared/data-services.schemas.ts +0 -58
  398. package/src/project-config/shared/env-example-defaults.ts +0 -50
  399. package/src/project-config/shared/environment.schemas.ts +0 -136
  400. package/src/project-config/shared/infrastructure-defaults.schemas.ts +0 -47
  401. package/src/project-config/shared/k8s-utils.ts +0 -56
  402. package/src/project-config/shared/platform-services.schemas.ts +0 -33
  403. package/src/project-config/shared/service-definitions.schemas.ts +0 -38
  404. package/src/project-config/sharing-policy-validation.ts +0 -159
  405. package/src/release/framework-release.constants.ts +0 -2
  406. package/src/schemas/__tests__/platform-config.schemas.test.ts +0 -90
  407. package/src/schemas/framework-info.schemas.ts +0 -13
  408. package/src/schemas/framework-secrets.schemas.ts +0 -19
  409. package/src/schemas/platform-application-config.schemas.ts +0 -25
  410. package/src/schemas/platform-application-secrets.schemas.ts +0 -78
  411. package/src/schemas/platform-config.schemas.ts +0 -45
  412. package/src/workspace-scope/index.ts +0 -2
  413. package/src/workspace-scope/workspace-scope-detector.ts +0 -98
  414. package/src/workspace-scope/workspace-scope.schemas.ts +0 -224
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provider-runtime-artifacts.js","sourceRoot":"","sources":["../../../../src/project-config/provider-runtime-artifacts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC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a,CAAC,oBAAoB,CAAC,CAAC,IAAI,EAAE;gBACjF,SAAS,EAAE,CAAC,GAAG,YAAY,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,IAAI,EAAE;gBAC3D,YAAY,EAAE,YAAY,CAAC,aAAa,CAAC,YAAY;aACtD;YACD,CAAC,CAAC,SAAS;QACb,cAAc,EAAE,YAAY,CAAC,cAAc;KAC5C,CAAC,CAAC,CAAC;AACR,CAAC","sourcesContent":["import { createHash } from 'node:crypto';\nimport { existsSync, readFileSync } from 'node:fs';\nimport { resolve as resolvePath } from 'node:path';\nimport { z } from 'zod';\nimport {\n AppFrontendType,\n FrontendProvidersBlockSchema,\n type FrontendProviderEntry,\n type FrontendProvidersBlock,\n} from '@wildo-ai/saas-models';\nimport {\n SaasLockfileProvidersSectionSchema,\n type SaasLockfileProvidersSection,\n type SaasLockfileRuntimeScopesProviders,\n} from '../lockfile/wildo-saas-lock.shared.schemas';\nimport {\n getDeclaredApplicationModuleIds,\n getServiceBoundApplicationModuleIds,\n} from './shared/application-modules.utils';\nimport type { ApplicationModules } from './shared/application-modules.schemas';\nimport {\n SaasProvidersScopesSchema,\n SaasProviderScopeSelectionSchema,\n type SaasProviderScopeSelection,\n type SaasProvidersScopes,\n type WildoSaasConfig,\n} from './define-saas-config';\nimport type { DiscoveredProviderCompanionContribution } from './provider-companion-discovery';\n\nexport const PROVIDER_RUNTIME_ARTIFACT_AUTOGENERATED_WARNING =\n 'AUTO-GENERATED FILE. DO NOT EDIT. Regenerate with `wildo config sync`.';\n\nexport const PROVIDER_RUNTIME_ARTIFACT_GENERATOR = 'wildo provider-runtime-artifact';\n\n/**\n * Canonical relative paths (from saas root) for the per-runtime-kind\n * provider artifact JSON files emitted by `wildo config sync`.\n *\n * Moved from `.wildo-saas/providers/` → `.wildo-saas/generated/providers/`\n * on 2026-05-06 to group ALL CLI-generated runtime topology artifacts\n * under the `.wildo-saas/generated/` namespace (sibling to other\n * generated state). The legacy `.wildo-saas/providers/` location is\n * cleaned up by `cleanupLegacyProviderJsonArtifacts` in the CLI sync\n * so operators don't end up with two copies after the migration.\n */\nexport const PROVIDER_RUNTIME_ARTIFACT_RELATIVE_PATHS = {\n backend: '.wildo-saas/generated/providers/backend.runtime-providers.generated.json',\n companion: '.wildo-saas/generated/providers/companion.runtime-providers.generated.json',\n frontendServices: '.wildo-saas/generated/providers/frontend-services.runtime-providers.generated.json',\n minions: '.wildo-saas/generated/providers/minions.runtime-providers.generated.json',\n nodeWorkers: '.wildo-saas/generated/providers/node-workers.runtime-providers.generated.json',\n} as const;\n\n/**\n * Legacy paths (pre-2026-05-06) for the per-runtime-kind provider\n * artifact JSON files. These are NOT written anymore — kept here so\n * `wildo config sync` can clean them up if they exist on disk from a\n * pre-migration sync. Drop this constant entirely once Wonder Todos\n * + downstream apps have all run a post-migration sync at least once.\n */\nexport const LEGACY_PROVIDER_RUNTIME_ARTIFACT_RELATIVE_PATHS = {\n backend: '.wildo-saas/providers/backend.runtime-providers.generated.json',\n companion: '.wildo-saas/providers/companion.runtime-providers.generated.json',\n frontendServices: '.wildo-saas/providers/frontend-services.runtime-providers.generated.json',\n minions: '.wildo-saas/providers/minions.runtime-providers.generated.json',\n nodeWorkers: '.wildo-saas/providers/node-workers.runtime-providers.generated.json',\n} as const;\n\nexport type ProviderRuntimeArtifactKind = keyof typeof PROVIDER_RUNTIME_ARTIFACT_RELATIVE_PATHS;\n\nexport const PROVIDER_RUNTIME_GENERATED_MODULE_RELATIVE_PATH =\n 'src/generated/wildo-provider-runtime.generated.ts';\n\n/**\n * Canonical lockfile section path the provider-materialization\n * subsystem owns end-to-end. Used by the post-mutation provider sync\n * runner + materialization-hook return types and pinned by tests\n * (`provider-sync-runner.test.ts`, `provider-materialization-hook.test.ts`).\n *\n * Defined here as a single-source constant — used to live as a\n * literal in 3+ places across `wildo-module-client` (third-pass\n * review C-L1).\n */\nexport const PROVIDER_LOCK_SECTION_PATH = 'sections.providers.runtimeScopes' as const;\n\n/**\n * Per-worker generated env file written by `wildo config sync`. Carries\n * provider topology env vars derived from the materialized scope.\n *\n * This file is the **single delivery channel** non-Node workers (Rust /\n * Java / etc.) receive for provider topology — there is no executable\n * JS bundle in their case (Step 5b in\n * `.claude/plans/provider-migration-continuation.md`). Node workers\n * receive both this file and the per-package\n * `wildo-provider-runtime.generated.ts` source module; reading either\n * surface yields a consistent view because they share the same digest.\n *\n * The file is auto-generated and overwritten on every sync. Operator-\n * authored secrets and per-env config stay in the worker's `.env` (not\n * touched by `wildo config sync`); workers should load both files at\n * boot — operator vars from `.env` and provider vars from this file —\n * so the two channels never collide.\n */\nexport const PROVIDER_RUNTIME_GENERATED_ENV_FILE_NAME = '.wildo-providers.env';\n\nconst RuntimeProviderScopeArtifactSchema = z.strictObject({\n providers: z.record(z.string(), SaasProviderScopeSelectionSchema).default({}),\n selection: z.record(\n z.string(),\n z.strictObject({\n primary: z.string().min(1),\n fallbacks: z.array(z.string().min(1)).default([]),\n }),\n ).default({}),\n});\n\nconst RuntimeProviderModulesArtifactSchema = z.strictObject({\n declaredModules: z.record(\n z.string(),\n z.strictObject({\n services: z.array(z.string().min(1)),\n haveSamlIntegration: z.boolean().optional(),\n }),\n ).default({}),\n moduleIds: z.array(z.string().min(1)).default([]),\n moduleIdsByService: z.record(z.string(), z.array(z.string().min(1))).default({}),\n});\nexport type RuntimeProviderModulesArtifact = z.infer<typeof RuntimeProviderModulesArtifactSchema>;\n\nconst FrontendProviderBootstrapsSchema = z.record(\n z.string().min(1),\n FrontendProvidersBlockSchema,\n);\n\nexport const SaasRuntimeProvidersArtifactSchema = z.strictObject({\n __AUTOGENERATED__: z.literal(PROVIDER_RUNTIME_ARTIFACT_AUTOGENERATED_WARNING),\n generatedBy: z.literal(PROVIDER_RUNTIME_ARTIFACT_GENERATOR),\n generatedAt: z.string().datetime({ offset: true }),\n sourceDigest: z.string().min(1),\n providerRefs: z.array(z.string().min(1)).default([]),\n providerGraphDigest: z.string().min(1),\n lockfileSectionDigest: z.string().min(1),\n artifactKind: z.enum([\n 'backend',\n 'companion',\n 'frontendServices',\n 'minions',\n 'nodeWorkers',\n ]),\n modules: RuntimeProviderModulesArtifactSchema,\n scope: RuntimeProviderScopeArtifactSchema.optional(),\n scopes: z.record(z.string(), RuntimeProviderScopeArtifactSchema).optional(),\n frontendProviderBootstraps: FrontendProviderBootstrapsSchema.optional(),\n});\nexport type SaasRuntimeProvidersArtifact = z.infer<typeof SaasRuntimeProvidersArtifactSchema>;\n\nexport interface MaterializedSaasProviderRuntimeArtifacts {\n artifacts: Partial<Record<ProviderRuntimeArtifactKind, SaasRuntimeProvidersArtifact>>;\n lockSection: SaasLockfileProvidersSection;\n}\n\nexport function materializeSaasProviderRuntimeArtifacts(\n config: Pick<WildoSaasConfig, 'modules' | 'providers' | 'services'>,\n options?: {\n generatedAt?: string;\n nodeWorkerKeys?: string[];\n discoveredContributions?: DiscoveredProviderCompanionContribution[];\n },\n): MaterializedSaasProviderRuntimeArtifacts {\n const scopes = SaasProvidersScopesSchema.parse(config.providers.scopes);\n const generatedAt = options?.generatedAt ?? new Date().toISOString();\n const modules = materializeModules(config);\n const frontendServiceTypes: Record<string, AppFrontendType> = Object.fromEntries(\n Object.entries(config.services ?? {})\n .filter(([, definition]) => definition.frontendType !== undefined)\n .map(([serviceKey, definition]) => [serviceKey, definition.frontendType as AppFrontendType]),\n );\n const discoveryContext = buildProviderRuntimeDiscoveryContext({\n discoveredContributions: options?.discoveredContributions,\n frontendServiceTypes,\n });\n\n const lockSection = SaasLockfileProvidersSectionSchema.parse({\n runtimeScopes: materializeLockRuntimeScopes({\n scopes,\n discoveryContext,\n }),\n });\n const artifactMetadata = buildArtifactMetadata({\n discoveryContext,\n frontendServiceTypes,\n lockSection,\n modules,\n nodeWorkerKeys: options?.nodeWorkerKeys,\n scopes,\n });\n\n const artifacts = materializeRuntimeArtifacts({\n artifactMetadata,\n discoveryContext,\n frontendServiceTypes,\n generatedAt,\n modules,\n nodeWorkerKeys: options?.nodeWorkerKeys,\n scopes,\n });\n\n return { artifacts, lockSection };\n}\n\nexport function selectScopedProviderRuntimeArtifact(\n artifact: SaasRuntimeProvidersArtifact,\n scopeKey: string,\n): SaasRuntimeProvidersArtifact {\n if (!artifact.scopes) {\n throw new Error(`Provider runtime artifact '${artifact.artifactKind}' does not contain keyed scopes.`);\n }\n\n const scope = artifact.scopes[scopeKey];\n if (!scope) {\n throw new Error(`Provider runtime artifact '${artifact.artifactKind}' does not contain scope '${scopeKey}'.`);\n }\n\n // Recompute `providerRefs` from the projected per-host scope rather\n // than carrying the parent multi-scope union forward unchanged. The\n // multi-scope artifact's `providerRefs` is the union across all\n // hosts (`buildMultiScopeArtifactMetadata`); preserving that union\n // on a single-scope projection makes the per-host artifact internally\n // inconsistent — `scope.providers` would describe one host while\n // `providerRefs` would describe siblings too. The boot-time\n // `assertProviderRuntimeEnvInSync` guard treats `providerRefs.length > 0`\n // as \"this host has providers to reconcile\" — without this\n // recomputation, an empty-scope host would inherit the union and\n // trip the env-missing guard even though its `.wildo-providers.env`\n // was deliberately not written. Recomputation also tightens\n // `BackendProviderRegistry`'s filter (today defended by an empty-list\n // fallback) so the per-host artifact accurately advertises only the\n // refs it should resolve.\n const projectedProviderRefs = Object.keys(scope.providers).sort();\n\n return SaasRuntimeProvidersArtifactSchema.parse({\n ...artifact,\n providerRefs: projectedProviderRefs,\n frontendProviderBootstraps: artifact.frontendProviderBootstraps?.[scopeKey]\n ? { [scopeKey]: artifact.frontendProviderBootstraps[scopeKey] }\n : undefined,\n scope,\n scopes: undefined,\n });\n}\n\n/**\n * Resolve the absolute path to the canonical\n * `frontend-services.runtime-providers.generated.json` artifact under\n * `<saasRoot>/.wildo-saas/generated/providers/`.\n *\n * Build-time consumers (Wonder Todos website + tech-doc) call this\n * instead of hardcoding the relative path so the artifact location\n * stays canonical (single source of truth is\n * `PROVIDER_RUNTIME_ARTIFACT_RELATIVE_PATHS`).\n */\nexport function resolveFrontendServicesArtifactPath(saasRoot: string): string {\n return resolvePath(saasRoot, PROVIDER_RUNTIME_ARTIFACT_RELATIVE_PATHS.frontendServices);\n}\n\n/**\n * Read + project the materialized frontend-services artifact for the\n * given service key. Returns `undefined` if the artifact file is\n * missing (sync hasn't run yet / clean checkout) or if the service\n * has no provider bootstrap entry.\n *\n * The single source of truth for build-time loading of the frontend\n * provider bootstraps. Replaces the (previously duplicated)\n * `loadMaterializedFrontendProviders` helpers that lived in\n * `saas-technical-doc/src/build/load-materialized-frontend-providers.ts`\n * and inline in `examples/wonder-todos/website/src/website-site-context.ts`.\n *\n * Both consumers used identical control flow:\n * 1. existsSync() short-circuit\n * 2. JSON.parse + SaasRuntimeProvidersArtifactSchema.parse\n * 3. frontendProviderBootstraps[serviceKey] lookup\n * 4. FrontendProvidersBlockSchema.parse on the per-service block\n * Centralized 2026-05-06 so a future schema/path change only\n * requires editing this function.\n */\nexport function loadMaterializedFrontendProviders(input: {\n artifactPath: string;\n serviceKey: string;\n}): FrontendProvidersBlock | undefined {\n const { artifactPath, serviceKey } = input;\n\n if (!existsSync(artifactPath)) {\n return undefined;\n }\n\n const artifact = SaasRuntimeProvidersArtifactSchema.parse(\n JSON.parse(readFileSync(artifactPath, 'utf8')),\n );\n const providerBlock = artifact.frontendProviderBootstraps?.[serviceKey];\n\n return providerBlock === undefined\n ? undefined\n : FrontendProvidersBlockSchema.parse(providerBlock);\n}\n\nexport function renderProviderRuntimeGeneratedModule(\n artifact: SaasRuntimeProvidersArtifact,\n): string {\n const artifactLiteral = JSON.stringify(artifact, null, 2);\n\n return [\n '/**',\n ` * ${PROVIDER_RUNTIME_ARTIFACT_AUTOGENERATED_WARNING}`,\n ' *',\n ' * This module is generated from wildo.saas.config.ts by `wildo config sync`.',\n ' * It contains environment-independent provider topology only.',\n ' */',\n '',\n // Intentionally NOT `as const` — the generated artifact is *data*, not a\n // frozen literal-typed tuple. Each host (backend / companion / minion /\n // worker) casts the imported value to its own narrowed runtime-artifact\n // type (`ProviderRuntimeArtifact`, `MinionProviderRuntimeArtifact`, …).\n // `as const` would infer `readonly` tuples (e.g. `readonly [\"openai\"]`)\n // that fail TS2352 against the schema-inferred mutable `string[]` shape.\n // Contract conformance is enforced upstream by\n // `SaasRuntimeProvidersArtifactSchema.parse(...)` at materialization time,\n // so widening the TS surface here costs no runtime safety.\n `export const WILDO_PROVIDER_RUNTIME = ${artifactLiteral};`,\n '',\n 'export default WILDO_PROVIDER_RUNTIME;',\n '',\n ].join('\\n');\n}\n\n/**\n * Canonical worker provider env-var keys. All workers receive the same\n * three keys regardless of language; the values are stable across runs\n * as long as the authored scope and discovered contributions don't\n * change.\n *\n * - `WILDO_PROVIDER_REFS` — comma-separated list of authored refs (sorted).\n * Cheap to read from any language (no JSON parser needed).\n * - `WILDO_PROVIDER_TOPOLOGY_JSON` — the per-worker `scope` block from\n * the materialized artifact, JSON-encoded. Workers that want\n * structured access (capability/protocol set) parse this; workers\n * that only need ref membership read `WILDO_PROVIDER_REFS`.\n * - `WILDO_PROVIDER_RUNTIME_DIGEST` — the artifact's `sourceDigest`.\n * Workers can fail-closed at boot if their copy of the env-file\n * disagrees with the lockfile section digest the platform expects.\n */\nexport const PROVIDER_RUNTIME_ENV_KEYS = {\n REFS: 'WILDO_PROVIDER_REFS',\n TOPOLOGY_JSON: 'WILDO_PROVIDER_TOPOLOGY_JSON',\n RUNTIME_DIGEST: 'WILDO_PROVIDER_RUNTIME_DIGEST',\n} as const;\n\n/**\n * Render the per-worker provider env-file body. Inputs:\n * - `scope` — the per-worker scope block from\n * `WildoSaasConfig.providers.scopes.workers[<workerKey>]`. Carries\n * the authored providers + capability/protocol declarations that\n * this worker needs to resolve at runtime.\n * - `sourceDigest` — `SaasRuntimeProvidersArtifact.sourceDigest`\n * (from the lockfile or the corresponding generated artifact).\n *\n * Output: a deterministic dotenv body — sorted refs, stable JSON\n * key ordering — so re-running `wildo config sync` with no upstream\n * changes produces a byte-identical file.\n */\nexport function renderProviderRuntimeEnvFile(input: {\n scope: SaasProviderScopeSelections;\n sourceDigest: string;\n}): string {\n const refs = Object.keys(input.scope.providers).sort();\n const topology: Record<string, {\n engineCapabilities: string[];\n providerCapabilities: string[];\n protocols: string[];\n }> = {};\n for (const ref of refs) {\n const selection = input.scope.providers[ref];\n topology[ref] = {\n engineCapabilities: [...selection.engineCapabilities].sort(),\n providerCapabilities: [...selection.providerCapabilities].sort(),\n protocols: [...selection.protocols].sort(),\n };\n }\n\n return [\n `# ${PROVIDER_RUNTIME_ARTIFACT_AUTOGENERATED_WARNING}`,\n '#',\n '# This file is regenerated on every `wildo config sync`. Do not edit by hand.',\n '# Operator-authored secrets / per-env config stay in `.env` and are never touched here.',\n '',\n `${PROVIDER_RUNTIME_ENV_KEYS.REFS}=${refs.join(',')}`,\n `${PROVIDER_RUNTIME_ENV_KEYS.TOPOLOGY_JSON}=${JSON.stringify(topology)}`,\n `${PROVIDER_RUNTIME_ENV_KEYS.RUNTIME_DIGEST}=${input.sourceDigest}`,\n '',\n ].join('\\n');\n}\n\n/**\n * Result of comparing the runtime host's typed\n * `wildo-provider-runtime.generated.ts` module against its\n * `.wildo-providers.env` file at boot.\n *\n * Drift between the two indicates the operator regenerated one surface\n * but not the other — typically: edited `wildo.saas.config.ts` and\n * re-ran `wildo config sync` while the env file was cached, or vice\n * versa. Either case the runtime would silently boot with mismatched\n * topology unless someone reconciles. See\n * `assertProviderRuntimeEnvInSync` for the fail-closed assertion.\n */\nexport type ProviderRuntimeEnvReconciliationResult =\n | { kind: 'in-sync' }\n | { kind: 'env-missing'; missingKeys: ReadonlyArray<string> }\n | {\n kind: 'refs-mismatch';\n envRefs: ReadonlyArray<string>;\n artifactRefs: ReadonlyArray<string>;\n }\n | {\n kind: 'digest-mismatch';\n envDigest: string;\n artifactDigest: string;\n };\n\n/**\n * Reconcile a runtime artifact's typed projection against the\n * `.wildo-providers.env` mounted into the same process. Pure function\n * so callers can decide how to surface the result (throw / log / ignore).\n *\n * The env file is materialized by `renderProviderRuntimeEnvFile` for\n * EVERY runtime host that is a minion or worker; the typed module is\n * imported by the same hosts. Both should agree on\n * `(providerRefs, sourceDigest)` exactly. Drift means stale sync.\n *\n * Hosts that don't receive an env file (backend, companion, frontend\n * services per `provider-runtime-sync.service.ts`) MUST NOT call this —\n * `WILDO_PROVIDER_*` keys won't be set and every call returns\n * `env-missing`.\n */\nexport function reconcileProviderRuntimeEnv(input: {\n artifactProviderRefs: ReadonlyArray<string>;\n artifactSourceDigest: string;\n env?: NodeJS.ProcessEnv;\n}): ProviderRuntimeEnvReconciliationResult {\n const env = input.env ?? process.env;\n const envRefsRaw = env[PROVIDER_RUNTIME_ENV_KEYS.REFS];\n const envDigest = env[PROVIDER_RUNTIME_ENV_KEYS.RUNTIME_DIGEST];\n\n const missingKeys: string[] = [];\n if (envRefsRaw === undefined) missingKeys.push(PROVIDER_RUNTIME_ENV_KEYS.REFS);\n if (envDigest === undefined) missingKeys.push(PROVIDER_RUNTIME_ENV_KEYS.RUNTIME_DIGEST);\n if (missingKeys.length > 0) {\n return { kind: 'env-missing', missingKeys };\n }\n\n // Filter empty entries so trailing-comma input (e.g. `'openai,'`) or\n // operator-edited stray whitespace don't produce confusing `''`\n // entries in mismatch diagnostics. Materializer never emits trailing\n // commas, but defense-in-depth keeps the helper robust to anything\n // that lands the env file via dotenv loaders or hand-edits.\n const envRefs = envRefsRaw!\n .split(',')\n .map((s) => s.trim())\n .filter((s) => s.length > 0)\n .sort();\n const artifactRefs = [...input.artifactProviderRefs].sort();\n\n if (envRefs.length !== artifactRefs.length || envRefs.some((ref, i) => ref !== artifactRefs[i])) {\n return { kind: 'refs-mismatch', envRefs, artifactRefs };\n }\n\n if (envDigest !== input.artifactSourceDigest) {\n return {\n kind: 'digest-mismatch',\n envDigest: envDigest!,\n artifactDigest: input.artifactSourceDigest,\n };\n }\n\n return { kind: 'in-sync' };\n}\n\n/**\n * Fail-closed wrapper around `reconcileProviderRuntimeEnv`. Throws on\n * any divergence, returns silently when in sync. Designed to be called\n * once at runtime-host boot (minion / Node-worker startup) so a stale\n * `.wildo-providers.env` surfaces immediately instead of being masked\n * by `process.env` drift.\n *\n * Throws a plain `Error` (not `WildoError_Backend`) because this runs\n * BEFORE the DI container has built the error builder — the failure\n * mode here is \"the container can't be trusted to boot at all\".\n */\nexport function assertProviderRuntimeEnvInSync(input: {\n artifactProviderRefs: ReadonlyArray<string>;\n artifactSourceDigest: string;\n hostKind: 'minion' | 'node-worker';\n hostKey: string;\n env?: NodeJS.ProcessEnv;\n}): void {\n const result = reconcileProviderRuntimeEnv(input);\n switch (result.kind) {\n case 'in-sync':\n return;\n case 'env-missing':\n throw new Error(\n `[provider-runtime-env] ${input.hostKind} '${input.hostKey}' booted without `\n + `provider env vars (${result.missingKeys.join(', ')}). The `\n + `\\`.wildo-providers.env\\` file should be mounted into this process — check `\n + `the docker-compose \\`env_file:\\` directive, the K8s ConfigMap mount, or the `\n + `dotenv loader. Re-run \\`wildo config sync\\` to regenerate if missing.`,\n );\n case 'refs-mismatch':\n throw new Error(\n `[provider-runtime-env] ${input.hostKind} '${input.hostKey}' detected stale provider topology. `\n + `\\`.wildo-providers.env\\` advertises refs [${result.envRefs.join(', ')}] but the `\n + `imported \\`wildo-provider-runtime.generated.ts\\` module declares `\n + `[${result.artifactRefs.join(', ')}]. Run \\`wildo config sync\\` to regenerate `\n + `both surfaces from the same \\`wildo.saas.config.ts\\` source.`,\n );\n case 'digest-mismatch':\n throw new Error(\n `[provider-runtime-env] ${input.hostKind} '${input.hostKey}' detected provider runtime digest drift. `\n + `\\`.wildo-providers.env\\` carries digest '${result.envDigest}' but the imported `\n + `\\`wildo-provider-runtime.generated.ts\\` module carries '${result.artifactDigest}'. `\n + `Refs match, but per-provider capabilities/protocols may differ. `\n + `Run \\`wildo config sync\\` to regenerate.`,\n );\n }\n}\n\ntype SaasProviderScopeSelections = {\n providers: Record<string, {\n engineCapabilities: ReadonlyArray<string>;\n providerCapabilities: ReadonlyArray<string>;\n protocols: ReadonlyArray<string>;\n }>;\n};\n\nfunction materializeRuntimeArtifacts(input: {\n artifactMetadata: ProviderRuntimeArtifactMetadataByKind;\n discoveryContext: ProviderRuntimeDiscoveryContext;\n frontendServiceTypes: Record<string, AppFrontendType>;\n generatedAt: string;\n modules: RuntimeProviderModulesArtifact;\n nodeWorkerKeys?: string[];\n scopes: SaasProvidersScopes;\n}): MaterializedSaasProviderRuntimeArtifacts['artifacts'] {\n const { artifactMetadata, discoveryContext, frontendServiceTypes, generatedAt, modules, nodeWorkerKeys, scopes } = input;\n const nodeWorkerKeySet = nodeWorkerKeys ? new Set(nodeWorkerKeys) : undefined;\n const nodeWorkerScopes = scopes.workers\n ? Object.fromEntries(\n Object.entries(scopes.workers).filter(([workerKey]) =>\n nodeWorkerKeySet ? nodeWorkerKeySet.has(workerKey) : true,\n ),\n )\n : undefined;\n\n return pruneUndefined({\n backend: materializeRuntimeArtifactFile({\n artifactKind: 'backend',\n generatedAt,\n modules,\n metadata: artifactMetadata.backend,\n frontendProviderBootstraps: materializeFrontendProviderBootstraps({\n discoveredContributions: discoveryContext.contributions,\n frontendServiceScopes: scopes.frontendServices ?? {},\n frontendServiceTypes,\n }),\n scope: materializeRuntimeScope(scopes.backend ?? { providers: {}, selection: {} }),\n }),\n companion: materializeRuntimeArtifactFile({\n artifactKind: 'companion',\n generatedAt,\n modules,\n metadata: artifactMetadata.companion,\n scope: materializeRuntimeScope(scopes.companion ?? { providers: {}, selection: {} }),\n }),\n frontendServices: scopes.frontendServices\n ? materializeRuntimeArtifactFile({\n artifactKind: 'frontendServices',\n generatedAt,\n modules,\n metadata: artifactMetadata.frontendServices,\n frontendProviderBootstraps: materializeFrontendProviderBootstraps({\n discoveredContributions: discoveryContext.contributions,\n frontendServiceScopes: scopes.frontendServices,\n frontendServiceTypes,\n }),\n scopes: mapRecord(scopes.frontendServices, materializeRuntimeScope),\n })\n : undefined,\n minions: scopes.minions\n ? materializeRuntimeArtifactFile({\n artifactKind: 'minions',\n generatedAt,\n modules,\n metadata: artifactMetadata.minions,\n scopes: mapRecord(scopes.minions, materializeRuntimeScope),\n })\n : undefined,\n nodeWorkers: nodeWorkerScopes && Object.keys(nodeWorkerScopes).length > 0\n ? materializeRuntimeArtifactFile({\n artifactKind: 'nodeWorkers',\n generatedAt,\n modules,\n metadata: artifactMetadata.nodeWorkers,\n scopes: mapRecord(nodeWorkerScopes, materializeRuntimeScope),\n })\n : undefined,\n });\n}\n\nfunction materializeRuntimeArtifactFile(input: {\n artifactKind: ProviderRuntimeArtifactKind;\n generatedAt: string;\n metadata: ProviderRuntimeArtifactMetadata;\n modules: RuntimeProviderModulesArtifact;\n frontendProviderBootstraps?: Record<string, FrontendProvidersBlock>;\n scope?: z.infer<typeof RuntimeProviderScopeArtifactSchema>;\n scopes?: Record<string, z.infer<typeof RuntimeProviderScopeArtifactSchema>>;\n}): SaasRuntimeProvidersArtifact {\n return SaasRuntimeProvidersArtifactSchema.parse({\n __AUTOGENERATED__: PROVIDER_RUNTIME_ARTIFACT_AUTOGENERATED_WARNING,\n generatedBy: PROVIDER_RUNTIME_ARTIFACT_GENERATOR,\n generatedAt: input.generatedAt,\n sourceDigest: input.metadata.sourceDigest,\n providerRefs: input.metadata.providerRefs,\n providerGraphDigest: input.metadata.providerGraphDigest,\n lockfileSectionDigest: input.metadata.lockfileSectionDigest,\n artifactKind: input.artifactKind,\n modules: input.modules,\n scope: input.scope,\n scopes: input.scopes,\n frontendProviderBootstraps: input.frontendProviderBootstraps,\n });\n}\n\nfunction materializeRuntimeScope(scope: NonNullable<SaasProvidersScopes['backend']>) {\n return RuntimeProviderScopeArtifactSchema.parse({\n providers: scope.providers,\n selection: scope.selection ?? {},\n });\n}\n\nfunction materializeFrontendProviderBootstraps(input: {\n discoveredContributions: DiscoveredProviderCompanionContribution[];\n frontendServiceScopes: NonNullable<SaasProvidersScopes['frontendServices']>;\n frontendServiceTypes: Record<string, AppFrontendType>;\n}): Record<string, FrontendProvidersBlock> | undefined {\n const { discoveredContributions, frontendServiceScopes, frontendServiceTypes } = input;\n const entries = Object.entries(frontendServiceScopes).map(([serviceKey, scope]) => {\n const serviceType = frontendServiceTypes[serviceKey];\n if (!serviceType) {\n throw new Error(\n `Cannot materialize frontend bootstrap for service \"${serviceKey}\": ` +\n `service has no frontendType — only services with a frontendType may appear under providers.scopes.frontendServices.`,\n );\n }\n const providers = Object.fromEntries(Object.keys(scope.providers).map((providerRef) => {\n const matchingContribution = discoveredContributions.filter(\n (contribution) =>\n contribution.ref === providerRef\n && contribution.runtimeTargets.some(\n (target) => target.kind === 'frontendService' && target.serviceType === serviceType,\n ),\n );\n\n if (matchingContribution.length === 0) {\n throw new Error(\n `Cannot materialize frontend bootstrap for service \"${serviceKey}\" (type \"${serviceType}\"): ` +\n `provider \"${providerRef}\" has no discovered frontend companion contribution.`,\n );\n }\n\n if (matchingContribution.some((contribution) => !contribution.frontendEntry)) {\n throw new Error(\n `Cannot materialize frontend bootstrap for service \"${serviceKey}\": ` +\n `provider \"${providerRef}\" is missing frontendEntry on at least one discovered contribution.`,\n );\n }\n\n if (matchingContribution.length > 1) {\n throw new Error(\n `Cannot materialize frontend bootstrap for service \"${serviceKey}\": ` +\n `provider \"${providerRef}\" is contributed more than once for the same runtime.`,\n );\n }\n\n return [\n providerRef,\n matchingContribution[0].frontendEntry as FrontendProviderEntry,\n ] as const;\n }));\n\n return [serviceKey, FrontendProvidersBlockSchema.parse({ providers })] as const;\n });\n\n return entries.length > 0 ? Object.fromEntries(entries) : undefined;\n}\n\nfunction buildFrontendProviderBootstrapDigestInput(input: {\n discoveredContributions: DiscoveredProviderCompanionContribution[];\n frontendServiceScopes: NonNullable<SaasProvidersScopes['frontendServices']>;\n frontendServiceTypes: Record<string, AppFrontendType>;\n}): Record<string, unknown> | undefined {\n const bootstraps = materializeFrontendProviderBootstraps(input);\n if (!bootstraps) {\n return undefined;\n }\n\n return Object.fromEntries(\n Object.entries(bootstraps).map(([serviceKey, block]) => [\n serviceKey,\n Object.fromEntries(\n Object.entries(block.providers).map(([providerRef, providerEntry]) => [\n providerRef,\n {\n metadata: providerEntry.metadata,\n providerCapabilities: [...providerEntry.providerCapabilities].sort(),\n protocols: [...providerEntry.protocols].sort(),\n publicConfig: providerEntry.publicConfig,\n },\n ]),\n ),\n ]),\n );\n}\n\nfunction materializeModules(\n config: Pick<WildoSaasConfig, 'modules' | 'services'>,\n): RuntimeProviderModulesArtifact {\n const modules = (config.modules ?? {}) as NonNullable<ApplicationModules>;\n return RuntimeProviderModulesArtifactSchema.parse({\n declaredModules: modules,\n moduleIds: getDeclaredApplicationModuleIds(modules),\n moduleIdsByService: Object.fromEntries(\n Object.keys(config.services ?? {}).map((serviceKey) => [\n serviceKey,\n getServiceBoundApplicationModuleIds(modules, serviceKey),\n ]),\n ),\n });\n}\n\nfunction materializeLockRuntimeScopes(input: {\n scopes: SaasProvidersScopes;\n discoveryContext: ProviderRuntimeDiscoveryContext;\n}): SaasLockfileRuntimeScopesProviders {\n const { scopes, discoveryContext } = input;\n return pruneUndefined({\n backend: scopes.backend\n ? materializeLockScope(\n scopes.backend.providers,\n discoveryContext.contributions,\n discoveryContext.backend.matchesRuntimeTarget,\n )\n : undefined,\n companion: scopes.companion\n ? materializeLockScope(\n scopes.companion.providers,\n discoveryContext.contributions,\n discoveryContext.companion.matchesRuntimeTarget,\n )\n : undefined,\n frontendServices: scopes.frontendServices\n ? mapRecord(\n scopes.frontendServices,\n (scope, serviceKey) => materializeLockScope(\n scope.providers,\n discoveryContext.contributions,\n discoveryContext.frontendServices.matchesRuntimeTarget(serviceKey),\n ),\n )\n : undefined,\n minions: scopes.minions\n ? mapRecord(\n scopes.minions,\n (scope, minionKey) => materializeLockScope(\n scope.providers,\n discoveryContext.contributions,\n discoveryContext.minions.matchesRuntimeTarget(minionKey),\n ),\n )\n : undefined,\n workers: scopes.workers\n ? mapRecord(\n scopes.workers,\n (scope, workerKey) => materializeLockScope(\n scope.providers,\n discoveryContext.contributions,\n discoveryContext.workers.matchesRuntimeTarget(workerKey),\n ),\n )\n : undefined,\n });\n}\n\nfunction materializeLockScope(\n providers: Record<string, SaasProviderScopeSelection>,\n discoveredContributions: DiscoveredProviderCompanionContribution[],\n matchesRuntimeTarget: (target: DiscoveredProviderCompanionContribution['runtimeTargets'][number]) => boolean,\n): SaasLockfileRuntimeScopesProviders['backend'] {\n return mapRecord(providers, (selection, ref) => {\n const matchingContributions = findMatchingDiscoveredContributions({\n discoveredContributions,\n matchesRuntimeTarget,\n providerRef: ref,\n });\n const secretsContractShape = resolveProviderSecretsContractShape(ref, matchingContributions);\n\n return {\n ref,\n digest: digestJson({\n selection,\n providerGraph: normalizeDiscoveredContributionsForDigest(matchingContributions),\n }),\n engineCapabilities: selection.engineCapabilities,\n providerCapabilities: selection.providerCapabilities,\n protocols: selection.protocols,\n // assurance-control: WILDO.SECRETS.CONTRACT_INTEGRITY — lock drift\n // covers the values-free provider contract without persisting secret values.\n secretsContractDigest: digestJson({ ref, secretsContractShape }),\n };\n });\n}\n\n/**\n * Resolves one authoritative values-free secret contract for a provider in a\n * concrete runtime scope.\n *\n * Multiple runtime owners may legitimately contribute the same provider, but\n * they must agree on its secret requirements. Missing discovery and divergent\n * shapes fail closed: hashing either state as an empty contract would make the\n * lockfile claim integrity evidence it does not possess.\n */\nfunction resolveProviderSecretsContractShape(\n providerRef: string,\n matchingContributions: DiscoveredProviderCompanionContribution[],\n): DiscoveredProviderCompanionContribution['secretsContractShape'] {\n if (matchingContributions.length === 0) {\n throw new Error(\n `Cannot materialize provider lock entry for \"${providerRef}\": no discovered contribution supplies its secret-contract shape for this runtime.`,\n );\n }\n\n const canonicalShape = matchingContributions[0].secretsContractShape;\n const canonicalDigestInput = stableStringify(canonicalShape);\n for (const contribution of matchingContributions.slice(1)) {\n if (stableStringify(contribution.secretsContractShape) !== canonicalDigestInput) {\n throw new Error(\n `Cannot materialize provider lock entry for \"${providerRef}\": discovered runtime owners disagree on its secret-contract shape.`,\n );\n }\n }\n\n return canonicalShape;\n}\n\nfunction digestJson(value: unknown): string {\n return `sha256:${createHash('sha256').update(stableStringify(value)).digest('hex')}`;\n}\n\nfunction stableStringify(value: unknown): string {\n if (Array.isArray(value)) {\n return `[${value.map(stableStringify).join(',')}]`;\n }\n if (value && typeof value === 'object') {\n const record = value as Record<string, unknown>;\n return `{${Object.keys(record)\n .sort()\n .map((key) => `${JSON.stringify(key)}:${stableStringify(record[key])}`)\n .join(',')}}`;\n }\n return JSON.stringify(value);\n}\n\nfunction mapRecord<TValue, TResult>(\n record: Record<string, TValue>,\n mapper: (value: TValue, key: string) => TResult,\n): Record<string, TResult> {\n return Object.fromEntries(\n Object.entries(record).map(([key, value]) => [key, mapper(value, key)]),\n );\n}\n\nfunction pruneUndefined<T extends Record<string, unknown>>(record: T): T {\n return Object.fromEntries(\n Object.entries(record).filter(([, value]) => value !== undefined),\n ) as T;\n}\n\ninterface ProviderRuntimeArtifactMetadata {\n sourceDigest: string;\n providerRefs: string[];\n providerGraphDigest: string;\n lockfileSectionDigest: string;\n}\n\ninterface ProviderRuntimeArtifactMetadataByKind {\n backend: ProviderRuntimeArtifactMetadata;\n companion: ProviderRuntimeArtifactMetadata;\n frontendServices: ProviderRuntimeArtifactMetadata;\n minions: ProviderRuntimeArtifactMetadata;\n nodeWorkers: ProviderRuntimeArtifactMetadata;\n}\n\ninterface RuntimeContributionMatcherFactory {\n matchesRuntimeTarget: (target: DiscoveredProviderCompanionContribution['runtimeTargets'][number]) => boolean;\n}\n\ninterface ScopedRuntimeContributionMatcherFactory {\n matchesRuntimeTarget: (\n scopeKey: string,\n ) => (target: DiscoveredProviderCompanionContribution['runtimeTargets'][number]) => boolean;\n}\n\ninterface ProviderRuntimeDiscoveryContext {\n contributions: DiscoveredProviderCompanionContribution[];\n backend: RuntimeContributionMatcherFactory;\n companion: RuntimeContributionMatcherFactory;\n frontendServices: ScopedRuntimeContributionMatcherFactory;\n minions: ScopedRuntimeContributionMatcherFactory;\n workers: ScopedRuntimeContributionMatcherFactory;\n}\n\nfunction buildProviderRuntimeDiscoveryContext(input: {\n discoveredContributions?: DiscoveredProviderCompanionContribution[];\n frontendServiceTypes: Record<string, AppFrontendType>;\n}): ProviderRuntimeDiscoveryContext {\n const contributions = input.discoveredContributions ?? [];\n const { frontendServiceTypes } = input;\n\n return {\n contributions,\n backend: {\n matchesRuntimeTarget: (target) => target.kind === 'backend',\n },\n companion: {\n matchesRuntimeTarget: (target) => target.kind === 'companion',\n },\n frontendServices: {\n matchesRuntimeTarget: (serviceKey) => {\n const serviceType = frontendServiceTypes[serviceKey];\n // Service has no frontendType ⇒ no contribution can match it.\n if (!serviceType) return () => false;\n return (target) => target.kind === 'frontendService' && target.serviceType === serviceType;\n },\n },\n minions: {\n matchesRuntimeTarget: (minionKey) => (target) => target.kind === 'minion' && target.minionKey === minionKey,\n },\n workers: {\n matchesRuntimeTarget: (workerKey) => (target) => target.kind === 'worker' && target.workerKey === workerKey,\n },\n };\n}\n\nfunction buildArtifactMetadata(input: {\n discoveryContext: ProviderRuntimeDiscoveryContext;\n frontendServiceTypes: Record<string, AppFrontendType>;\n lockSection: SaasLockfileProvidersSection;\n modules: RuntimeProviderModulesArtifact;\n nodeWorkerKeys?: string[];\n scopes: SaasProvidersScopes;\n}): ProviderRuntimeArtifactMetadataByKind {\n const { discoveryContext, frontendServiceTypes, lockSection, modules, nodeWorkerKeys, scopes } = input;\n const nodeWorkerKeySet = nodeWorkerKeys ? new Set(nodeWorkerKeys) : undefined;\n\n return {\n backend: buildSingleScopeArtifactMetadata({\n modules,\n providers: scopes.backend?.providers ?? {},\n matchingContributions: findMatchingDiscoveredContributions({\n discoveredContributions: discoveryContext.contributions,\n matchesRuntimeTarget: discoveryContext.backend.matchesRuntimeTarget,\n }),\n extraArtifactState: buildFrontendProviderBootstrapDigestInput({\n discoveredContributions: discoveryContext.contributions,\n frontendServiceScopes: scopes.frontendServices ?? {},\n frontendServiceTypes,\n }),\n runtimeLockSection: lockSection.runtimeScopes.backend ?? {},\n scopes,\n }),\n companion: buildSingleScopeArtifactMetadata({\n modules,\n providers: scopes.companion?.providers ?? {},\n matchingContributions: findMatchingDiscoveredContributions({\n discoveredContributions: discoveryContext.contributions,\n matchesRuntimeTarget: discoveryContext.companion.matchesRuntimeTarget,\n }),\n runtimeLockSection: lockSection.runtimeScopes.companion ?? {},\n scopes,\n }),\n frontendServices: buildMultiScopeArtifactMetadata({\n keyedProviders: Object.fromEntries(\n Object.entries(scopes.frontendServices ?? {}).map(([scopeKey, scope]) => [scopeKey, scope.providers]),\n ),\n matchingContributionsByScope: Object.fromEntries(\n Object.keys(scopes.frontendServices ?? {}).map((scopeKey) => [\n scopeKey,\n findMatchingDiscoveredContributions({\n discoveredContributions: discoveryContext.contributions,\n matchesRuntimeTarget: discoveryContext.frontendServices.matchesRuntimeTarget(scopeKey),\n }),\n ]),\n ),\n modules,\n extraArtifactState: buildFrontendProviderBootstrapDigestInput({\n discoveredContributions: discoveryContext.contributions,\n frontendServiceScopes: scopes.frontendServices ?? {},\n frontendServiceTypes,\n }),\n runtimeLockSection: lockSection.runtimeScopes.frontendServices ?? {},\n scopes,\n }),\n minions: buildMultiScopeArtifactMetadata({\n keyedProviders: Object.fromEntries(\n Object.entries(scopes.minions ?? {}).map(([scopeKey, scope]) => [scopeKey, scope.providers]),\n ),\n matchingContributionsByScope: Object.fromEntries(\n Object.keys(scopes.minions ?? {}).map((scopeKey) => [\n scopeKey,\n findMatchingDiscoveredContributions({\n discoveredContributions: discoveryContext.contributions,\n matchesRuntimeTarget: discoveryContext.minions.matchesRuntimeTarget(scopeKey),\n }),\n ]),\n ),\n modules,\n runtimeLockSection: lockSection.runtimeScopes.minions ?? {},\n scopes,\n }),\n nodeWorkers: buildMultiScopeArtifactMetadata({\n keyedProviders: Object.fromEntries(\n Object.entries(scopes.workers ?? {})\n .filter(([scopeKey]) => nodeWorkerKeySet ? nodeWorkerKeySet.has(scopeKey) : true)\n .map(([scopeKey, scope]) => [scopeKey, scope.providers]),\n ),\n matchingContributionsByScope: Object.fromEntries(\n Object.keys(scopes.workers ?? {})\n .filter((scopeKey) => nodeWorkerKeySet ? nodeWorkerKeySet.has(scopeKey) : true)\n .map((scopeKey) => [\n scopeKey,\n findMatchingDiscoveredContributions({\n discoveredContributions: discoveryContext.contributions,\n matchesRuntimeTarget: discoveryContext.workers.matchesRuntimeTarget(scopeKey),\n }),\n ]),\n ),\n modules,\n runtimeLockSection: Object.fromEntries(\n Object.entries(lockSection.runtimeScopes.workers ?? {})\n .filter(([scopeKey]) => nodeWorkerKeySet ? nodeWorkerKeySet.has(scopeKey) : true),\n ),\n scopes,\n }),\n };\n}\n\nfunction buildSingleScopeArtifactMetadata(input: {\n matchingContributions: DiscoveredProviderCompanionContribution[];\n modules: RuntimeProviderModulesArtifact;\n providers: Record<string, SaasProviderScopeSelection>;\n extraArtifactState?: Record<string, unknown>;\n runtimeLockSection: Record<string, unknown>;\n scopes: SaasProvidersScopes;\n}): ProviderRuntimeArtifactMetadata {\n const providerRefs = Object.keys(input.providers).sort();\n const normalizedContributions = normalizeDiscoveredContributionsForDigest(input.matchingContributions);\n const providerGraphDigestInput = input.extraArtifactState\n ? {\n providerGraph: normalizedContributions,\n extraArtifactState: input.extraArtifactState,\n }\n : normalizedContributions;\n\n return {\n sourceDigest: digestJson({\n modules: input.modules,\n providers: input.providers,\n providerGraph: normalizedContributions,\n scopes: input.scopes,\n extraArtifactState: input.extraArtifactState,\n }),\n providerRefs,\n providerGraphDigest: digestJson(providerGraphDigestInput),\n lockfileSectionDigest: digestJson(input.runtimeLockSection),\n };\n}\n\nfunction buildMultiScopeArtifactMetadata(input: {\n keyedProviders: Record<string, Record<string, SaasProviderScopeSelection>>;\n matchingContributionsByScope: Record<string, DiscoveredProviderCompanionContribution[]>;\n modules: RuntimeProviderModulesArtifact;\n extraArtifactState?: Record<string, unknown>;\n runtimeLockSection: Record<string, unknown>;\n scopes: SaasProvidersScopes;\n}): ProviderRuntimeArtifactMetadata {\n const providerRefs = [...new Set(\n Object.values(input.keyedProviders).flatMap((providers) => Object.keys(providers)),\n )].sort();\n const normalizedContributionsByScope = Object.fromEntries(\n Object.entries(input.matchingContributionsByScope).map(([scopeKey, contributions]) => [\n scopeKey,\n normalizeDiscoveredContributionsForDigest(contributions),\n ]),\n );\n\n const providerGraphDigestInput = input.extraArtifactState\n ? {\n providerGraphByScope: normalizedContributionsByScope,\n extraArtifactState: input.extraArtifactState,\n }\n : normalizedContributionsByScope;\n\n return {\n sourceDigest: digestJson({\n keyedProviders: input.keyedProviders,\n modules: input.modules,\n providerGraphByScope: normalizedContributionsByScope,\n scopes: input.scopes,\n extraArtifactState: input.extraArtifactState,\n }),\n providerRefs,\n providerGraphDigest: digestJson(providerGraphDigestInput),\n lockfileSectionDigest: digestJson(input.runtimeLockSection),\n };\n}\n\nfunction findMatchingDiscoveredContributions(input: {\n discoveredContributions: DiscoveredProviderCompanionContribution[];\n matchesRuntimeTarget: (target: DiscoveredProviderCompanionContribution['runtimeTargets'][number]) => boolean;\n providerRef?: string;\n}): DiscoveredProviderCompanionContribution[] {\n return input.discoveredContributions.flatMap((contribution) => {\n if (input.providerRef && contribution.ref !== input.providerRef) {\n return [];\n }\n const runtimeTargets = contribution.runtimeTargets.filter(input.matchesRuntimeTarget);\n if (runtimeTargets.length === 0) {\n return [];\n }\n return [{ ...contribution, runtimeTargets }];\n });\n}\n\n/**\n * The portion of a contribution's `owner` that may enter a digest.\n *\n * **`packageRoot` is deliberately excluded, and this is the whole point of the\n * function.** Discovery builds it as `resolve(saasRoot, definition.path)` — an\n * ABSOLUTE filesystem path — so hashing it makes every value derived from this\n * normalizer a property of WHERE THE REPOSITORY HAPPENS TO BE CHECKED OUT\n * rather than of the provider graph.\n *\n * That is not a theoretical concern; it was measured on 2026-08-30. The same\n * Wonder Todos tree, materialized from its real directory and from a symlink to\n * it, produced two different lock digests for every provider in every scope\n * (`sha256:f7eeb2d6…` vs `sha256:d933b95a…` for backend `anthropic`), and a dump\n * of the two contribution sets differed in `owner.packageRoot` and nothing else.\n * The consequences were both real:\n *\n * - `examples/wonder-todos/.wildo-saas/wildo-saas.lock.json` carried 22 digests\n * scoped to whichever checkout last ran `wildo config sync`, so the\n * `Lockfile Drift Check` gate — which runs at `/home/runner/work/…` — could\n * never have agreed with a committed value regardless of actual drift.\n * - The same input feeds `sourceDigest` / `providerGraphDigest` in the generated\n * runtime artifacts and `.wildo-providers.env`, so artifacts generated on a\n * developer's machine and re-materialized under a container's `/app` would\n * trip the `digest-mismatch` runtime diagnostic while describing an identical\n * provider graph.\n *\n * `kind` + `key` already identify an owner uniquely (both are record keys within\n * their config block), so nothing distinguishing is lost. What IS given up is\n * that relocating an owner package without changing its contribution content no\n * longer moves the digest — accepted deliberately: a repository-layout change is\n * not a provider-contract change, and if that signal is ever wanted it must\n * arrive as a saas-root-RELATIVE path, never an absolute one.\n */\nfunction projectOwnerForDigest(\n owner: DiscoveredProviderCompanionContribution['owner'],\n): { kind: string; key: string } {\n return { kind: owner.kind, key: owner.key };\n}\n\nfunction normalizeDiscoveredContributionsForDigest(\n contributions: DiscoveredProviderCompanionContribution[],\n): Array<Record<string, unknown>> {\n return [...contributions]\n .sort((left, right) => stableStringify({\n leftOwner: projectOwnerForDigest(left.owner),\n leftRef: left.ref,\n leftRuntimeImportPath: left.runtimeImportPath,\n leftSourceModuleId: left.sourceModuleId,\n leftTargets: left.runtimeTargets,\n }).localeCompare(stableStringify({\n rightOwner: projectOwnerForDigest(right.owner),\n rightRef: right.ref,\n rightRuntimeImportPath: right.runtimeImportPath,\n rightSourceModuleId: right.sourceModuleId,\n rightTargets: right.runtimeTargets,\n })))\n .map((contribution) => ({\n ref: contribution.ref,\n owner: projectOwnerForDigest(contribution.owner),\n runtimeImportPath: contribution.runtimeImportPath,\n runtimeTargets: contribution.runtimeTargets,\n engineCapabilities: [...contribution.engineCapabilities].sort(),\n providerCapabilities: [...contribution.providerCapabilities].sort(),\n protocols: [...contribution.protocols].sort(),\n secretsContractShape: contribution.secretsContractShape,\n frontendEntry: contribution.frontendEntry\n ? {\n metadata: contribution.frontendEntry.metadata,\n providerCapabilities: [...contribution.frontendEntry.providerCapabilities].sort(),\n protocols: [...contribution.frontendEntry.protocols].sort(),\n publicConfig: contribution.frontendEntry.publicConfig,\n }\n : undefined,\n sourceModuleId: contribution.sourceModuleId,\n }));\n}\n"]}
@@ -0,0 +1,18 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Local operator posture for application-creation workflow verification.
4
+ *
5
+ * This is authored in `wildo.infra.local.config.ts`. It is never read directly
6
+ * by the verification command: config sync first snapshots it into generated
7
+ * `config.json`, then projects it into the ephemeral app-root `.env` consumed
8
+ * by the operator command. Keeping this block local-only prevents a developer
9
+ * diagnostic path or console preference from becoming deployment policy.
10
+ */
11
+ export declare const ApplicationCreationVerificationConfigSchema: z.ZodObject<{
12
+ /** App-root-relative destination for persistent verification evidence. */
13
+ evidenceDirectory: z.ZodString;
14
+ /** Suppress successful child/receipt presentation without weakening evidence. */
15
+ silent: z.ZodDefault<z.ZodBoolean>;
16
+ }, z.core.$strict>;
17
+ export type ApplicationCreationVerificationConfig = z.infer<typeof ApplicationCreationVerificationConfigSchema>;
18
+ //# sourceMappingURL=application-creation-verification.schemas.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"application-creation-verification.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-creation-verification.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;GAQG;AACH,eAAO,MAAM,2CAA2C;IACtD,0EAA0E;;IAU1E,iFAAiF;;kBAEjF,CAAC;AAEH,MAAM,MAAM,qCAAqC,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2CAA2C,CAAC,CAAC"}
@@ -0,0 +1,25 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Local operator posture for application-creation workflow verification.
4
+ *
5
+ * This is authored in `wildo.infra.local.config.ts`. It is never read directly
6
+ * by the verification command: config sync first snapshots it into generated
7
+ * `config.json`, then projects it into the ephemeral app-root `.env` consumed
8
+ * by the operator command. Keeping this block local-only prevents a developer
9
+ * diagnostic path or console preference from becoming deployment policy.
10
+ */
11
+ export const ApplicationCreationVerificationConfigSchema = z.strictObject({
12
+ /** App-root-relative destination for persistent verification evidence. */
13
+ evidenceDirectory: z.string().trim().min(1).superRefine((value, context) => {
14
+ const pathSegments = value.split(/[\\/]/u);
15
+ if (/^(?:[A-Za-z]:[\\/]|[\\/])/u.test(value) || pathSegments.includes('..') || value === '.') {
16
+ context.addIssue({
17
+ code: 'custom',
18
+ message: 'applicationCreationVerification.evidenceDirectory must be an app-root-relative descendant path.',
19
+ });
20
+ }
21
+ }),
22
+ /** Suppress successful child/receipt presentation without weakening evidence. */
23
+ silent: z.boolean().default(false),
24
+ });
25
+ //# sourceMappingURL=application-creation-verification.schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"application-creation-verification.schemas.js","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-creation-verification.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,2CAA2C,GAAG,CAAC,CAAC,YAAY,CAAC;IACxE,0EAA0E;IAC1E,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,KAAK,EAAE,OAAO,EAAE,EAAE;QACzE,MAAM,YAAY,GAAG,KAAK,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,4BAA4B,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,KAAK,KAAK,GAAG,EAAE,CAAC;YAC7F,OAAO,CAAC,QAAQ,CAAC;gBACf,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,iGAAiG;aAC3G,CAAC,CAAC;QACL,CAAC;IACH,CAAC,CAAC;IACF,iFAAiF;IACjF,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC;CACnC,CAAC,CAAC","sourcesContent":["import { z } from 'zod';\n\n/**\n * Local operator posture for application-creation workflow verification.\n *\n * This is authored in `wildo.infra.local.config.ts`. It is never read directly\n * by the verification command: config sync first snapshots it into generated\n * `config.json`, then projects it into the ephemeral app-root `.env` consumed\n * by the operator command. Keeping this block local-only prevents a developer\n * diagnostic path or console preference from becoming deployment policy.\n */\nexport const ApplicationCreationVerificationConfigSchema = z.strictObject({\n /** App-root-relative destination for persistent verification evidence. */\n evidenceDirectory: z.string().trim().min(1).superRefine((value, context) => {\n const pathSegments = value.split(/[\\\\/]/u);\n if (/^(?:[A-Za-z]:[\\\\/]|[\\\\/])/u.test(value) || pathSegments.includes('..') || value === '.') {\n context.addIssue({\n code: 'custom',\n message: 'applicationCreationVerification.evidenceDirectory must be an app-root-relative descendant path.',\n });\n }\n }),\n /** Suppress successful child/receipt presentation without weakening evidence. */\n silent: z.boolean().default(false),\n});\n\nexport type ApplicationCreationVerificationConfig = z.infer<typeof ApplicationCreationVerificationConfigSchema>;\n"]}
@@ -1,10 +1,18 @@
1
1
  import { z } from 'zod';
2
+ /**
3
+ * @wildo_source:part:start platform.config.application-modules facet:layer:platform facet:family:bootstrap
4
+ *
5
+ * SaaS root `modules` map: each module id binds to the service keys it consumes (`ApplicationModulesSchema`).
6
+ */
2
7
  export declare const ApplicationModuleBindingSchema: z.ZodObject<{
3
8
  services: z.ZodArray<z.ZodString>;
4
- }, z.core.$strip, core.$ZodObjectExtra>;
9
+ haveSamlIntegration: z.ZodOptional<z.ZodBoolean>;
10
+ }, z.core.$strip>;
5
11
  export type ApplicationModuleBinding = z.infer<typeof ApplicationModuleBindingSchema>;
6
12
  export declare const ApplicationModulesSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
7
13
  services: z.ZodArray<z.ZodString>;
8
- }, z.core.$strip, core.$ZodObjectExtra>>>;
14
+ haveSamlIntegration: z.ZodOptional<z.ZodBoolean>;
15
+ }, z.core.$strip>>>;
9
16
  export type ApplicationModules = z.infer<typeof ApplicationModulesSchema>;
17
+ /** @wildo_source:part:end platform.config.application-modules */
10
18
  //# sourceMappingURL=application-modules.schemas.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"application-modules.schemas.d.ts","sourceRoot":"","sources":["../../../../src/project-config/shared/application-modules.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,8BAA8B;;uCAEzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC;AAEtF,eAAO,MAAM,wBAAwB;;yCAGzB,CAAC;AACb,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
1
+ {"version":3,"file":"application-modules.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-modules.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;GAIG;AACH,eAAO,MAAM,8BAA8B;;;iBAOzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC;AAEtF,eAAO,MAAM,wBAAwB;;;mBAGzB,CAAC;AACb,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,iEAAiE"}
@@ -1,6 +1,17 @@
1
1
  import { z } from 'zod';
2
+ /**
3
+ * @wildo_source:part:start platform.config.application-modules facet:layer:platform facet:family:bootstrap
4
+ *
5
+ * SaaS root `modules` map: each module id binds to the service keys it consumes (`ApplicationModulesSchema`).
6
+ */
2
7
  export const ApplicationModuleBindingSchema = z.object({
3
8
  services: z.array(z.string().min(1)).min(1),
9
+ /**
10
+ * When true, at least one backend workload for this module requires the
11
+ * Java-enabled framework backend base image (for example SAML/XSD flows).
12
+ */
13
+ haveSamlIntegration: z.boolean().optional(),
4
14
  });
5
15
  export const ApplicationModulesSchema = z.record(z.string().min(1), ApplicationModuleBindingSchema).optional();
6
- //# sourceMappingURL=application-modules.schemas.js.map
16
+ /** @wildo_source:part:end platform.config.application-modules */
17
+ //# sourceMappingURL=application-modules.schemas.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"application-modules.schemas.js","sourceRoot":"","sources":["../../../../src/project-config/shared/application-modules.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC;IACrD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;CAC5C,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAC9C,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,EACjB,8BAA8B,CAC/B,CAAC,QAAQ,EAAE,CAAC"}
1
+ {"version":3,"file":"application-modules.schemas.js","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-modules.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;GAIG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC;IACrD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3C;;;OAGG;IACH,mBAAmB,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAC5C,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAC9C,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,EACjB,8BAA8B,CAC/B,CAAC,QAAQ,EAAE,CAAC;AAEb,iEAAiE","sourcesContent":["import { z } from 'zod';\n\n/**\n * @wildo_source:part:start platform.config.application-modules facet:layer:platform facet:family:bootstrap\n *\n * SaaS root `modules` map: each module id binds to the service keys it consumes (`ApplicationModulesSchema`).\n */\nexport const ApplicationModuleBindingSchema = z.object({\n services: z.array(z.string().min(1)).min(1),\n /**\n * When true, at least one backend workload for this module requires the\n * Java-enabled framework backend base image (for example SAML/XSD flows).\n */\n haveSamlIntegration: z.boolean().optional(),\n});\nexport type ApplicationModuleBinding = z.infer<typeof ApplicationModuleBindingSchema>;\n\nexport const ApplicationModulesSchema = z.record(\n z.string().min(1),\n ApplicationModuleBindingSchema,\n).optional();\nexport type ApplicationModules = z.infer<typeof ApplicationModulesSchema>;\n/** @wildo_source:part:end platform.config.application-modules */\n"]}
@@ -1,6 +1,7 @@
1
- import type { ApplicationModules } from './application-modules.schemas.js';
1
+ import type { ApplicationModules } from './application-modules.schemas';
2
2
  export declare function getDeclaredApplicationModuleIds(modules: ApplicationModules | undefined): string[];
3
3
  export declare function getServiceBoundApplicationModuleIds(modules: ApplicationModules | undefined, serviceKey: string): string[];
4
+ export declare function hasServiceBoundModuleWithSamlIntegration(modules: ApplicationModules | undefined, serviceKeys: string | string[]): boolean;
4
5
  export declare function resolveDeclaredApplicationModules<T>(modules: ApplicationModules | undefined, declaredModulesById: Record<string, T>, consumerLabel: string): T[];
5
6
  export declare function resolveServiceBoundApplicationModules<T>(modules: ApplicationModules | undefined, serviceKey: string, declaredModulesById: Record<string, T>, consumerLabel?: string): T[];
6
7
  //# sourceMappingURL=application-modules.utils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"application-modules.utils.d.ts","sourceRoot":"","sources":["../../../../src/project-config/shared/application-modules.utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AA4BxE,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,kBAAkB,GAAG,SAAS,GACtC,MAAM,EAAE,CAEV;AAED,wBAAgB,mCAAmC,CACjD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,UAAU,EAAE,MAAM,GACjB,MAAM,EAAE,CAEV;AAED,wBAAgB,iCAAiC,CAAC,CAAC,EACjD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,EACtC,aAAa,EAAE,MAAM,GACpB,CAAC,EAAE,CAML;AAED,wBAAgB,qCAAqC,CAAC,CAAC,EACrD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,UAAU,EAAE,MAAM,EAClB,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,EACtC,aAAa,SAA4B,GACxC,CAAC,EAAE,CAML"}
1
+ {"version":3,"file":"application-modules.utils.d.ts","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-modules.utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AA4BxE,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,kBAAkB,GAAG,SAAS,GACtC,MAAM,EAAE,CAEV;AAED,wBAAgB,mCAAmC,CACjD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,UAAU,EAAE,MAAM,GACjB,MAAM,EAAE,CAEV;AAED,wBAAgB,wCAAwC,CACtD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,WAAW,EAAE,MAAM,GAAG,MAAM,EAAE,GAC7B,OAAO,CAOT;AAED,wBAAgB,iCAAiC,CAAC,CAAC,EACjD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,EACtC,aAAa,EAAE,MAAM,GACpB,CAAC,EAAE,CAML;AAED,wBAAgB,qCAAqC,CAAC,CAAC,EACrD,OAAO,EAAE,kBAAkB,GAAG,SAAS,EACvC,UAAU,EAAE,MAAM,EAClB,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,EACtC,aAAa,SAA4B,GACxC,CAAC,EAAE,CAML"}
@@ -17,10 +17,15 @@ export function getDeclaredApplicationModuleIds(modules) {
17
17
  export function getServiceBoundApplicationModuleIds(modules, serviceKey) {
18
18
  return resolveModuleIds(modules, (serviceKeys) => serviceKeys.includes(serviceKey));
19
19
  }
20
+ export function hasServiceBoundModuleWithSamlIntegration(modules, serviceKeys) {
21
+ const serviceKeySet = new Set(Array.isArray(serviceKeys) ? serviceKeys : [serviceKeys]);
22
+ return Object.values(modules ?? {}).some((binding) => binding.haveSamlIntegration === true &&
23
+ binding.services.some((serviceKey) => serviceKeySet.has(serviceKey)));
24
+ }
20
25
  export function resolveDeclaredApplicationModules(modules, declaredModulesById, consumerLabel) {
21
26
  return pickApplicationModules(getDeclaredApplicationModuleIds(modules), declaredModulesById, consumerLabel);
22
27
  }
23
28
  export function resolveServiceBoundApplicationModules(modules, serviceKey, declaredModulesById, consumerLabel = `service "${serviceKey}"`) {
24
29
  return pickApplicationModules(getServiceBoundApplicationModuleIds(modules, serviceKey), declaredModulesById, consumerLabel);
25
30
  }
26
- //# sourceMappingURL=application-modules.utils.js.map
31
+ //# sourceMappingURL=application-modules.utils.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"application-modules.utils.js","sourceRoot":"","sources":["../../../../src/project-config/shared/application-modules.utils.ts"],"names":[],"mappings":"AAEA,SAAS,gBAAgB,CACvB,OAAuC,EACvC,SAA6C;IAE7C,OAAO,MAAM,CAAC,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;SACjC,MAAM,CAAC,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AsC,EACtC,aAAa,GAAG,YAAY,UAAU,GAAG;IAEzC,OAAO,sBAAsB,CAC3B,mCAAmC,CAAC,OAAO,EAAE,UAAU,CAAC,EACxD,mBAAmB,EACnB,aAAa,CACd,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"application-modules.utils.js","sourceRoot":"","sources":["../../../../../src/project-config/shared/application-modules.utils.ts"],"names":[],"mappings":"AAEA,SAAS,gBAAgB,CACvB,OAAuC,EACvC,SAA6C;IAE7C,OAAO,MAAM,CAAC,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;SACjC,MAAM,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,EAAE,CAAC,SAAS,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;SACpD,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC;AACnC,CAAC;AAED,SAAS,sBAAsB,CAC7B,SAAmB,EACnB,mBAAsC,EACtC,aAAqB;IAErB,MAAM,gBAAgB,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,IAAI,mBAAmB,CAAC,CAAC,CAAC;IAE5F,IAAI,gBAAgB,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAChC,MAAM,IAAI,KAAK,CACb,wBAAwB,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,sBAAsB,aAAa,GAAG;YACzF,wEAAwE,CACzE,CAAC;IACJ,CAAC;IAED,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,mBAAmB,CAAC,QAAQ,CAAE,CAAC,CAAC;AACrE,CAAC;AAED,MAAM,UAAU,+BAA+B,CAC7C,OAAuC;IAEvC,OAAO,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;AAC/C,CAAC;AAED,MAAM,UAAU,mCAAmC,CACjD,OAAuC,EACvC,UAAkB;IAElB,OAAO,gBAAgB,CAAC,OAAO,EAAE,CAAC,WAAW,EAAE,EAAE,CAAC,WAAW,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC,CAAC;AACtF,CAAC;AAED,MAAM,UAAU,wCAAwC,CACtD,OAAuC,EACvC,WAA8B;IAE9B,MAAM,aAAa,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC;IAExF,OAAO,MAAM,CAAC,MAAM,CAAC,OAAO,IAAI,EAAE,CAAC,CAAC,IAAI,CACtC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,mBAAmB,KAAK,IAAI;QAC/C,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,CACvE,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,iCAAiC,CAC/C,OAAuC,EACvC,mBAAsC,EACtC,aAAqB;IAErB,OAAO,sBAAsB,CAC3B,+BAA+B,CAAC,OAAO,CAAC,EACxC,mBAAmB,EACnB,aAAa,CACd,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,qCAAqC,CACnD,OAAuC,EACvC,UAAkB,EAClB,mBAAsC,EACtC,aAAa,GAAG,YAAY,UAAU,GAAG;IAEzC,OAAO,sBAAsB,CAC3B,mCAAmC,CAAC,OAAO,EAAE,UAAU,CAAC,EACxD,mBAAmB,EACnB,aAAa,CACd,CAAC;AACJ,CAAC","sourcesContent":["import type { ApplicationModules } from './application-modules.schemas';\n\nfunction resolveModuleIds(\n modules: ApplicationModules | undefined,\n predicate: (serviceKeys: string[]) => boolean,\n): string[] {\n return Object.entries(modules ?? {})\n .filter(([, binding]) => predicate(binding.services))\n .map(([moduleId]) => moduleId);\n}\n\nfunction pickApplicationModules<T>(\n moduleIds: string[],\n declaredModulesById: Record<string, T>,\n consumerLabel: string,\n): T[] {\n const missingModuleIds = moduleIds.filter((moduleId) => !(moduleId in declaredModulesById));\n\n if (missingModuleIds.length > 0) {\n throw new Error(\n `Application modules [${missingModuleIds.join(', ')}] are declared for ${consumerLabel} ` +\n 'in wildo.saas.config.ts but no matching implementation was registered.',\n );\n }\n\n return moduleIds.map((moduleId) => declaredModulesById[moduleId]!);\n}\n\nexport function getDeclaredApplicationModuleIds(\n modules: ApplicationModules | undefined,\n): string[] {\n return resolveModuleIds(modules, () => true);\n}\n\nexport function getServiceBoundApplicationModuleIds(\n modules: ApplicationModules | undefined,\n serviceKey: string,\n): string[] {\n return resolveModuleIds(modules, (serviceKeys) => serviceKeys.includes(serviceKey));\n}\n\nexport function hasServiceBoundModuleWithSamlIntegration(\n modules: ApplicationModules | undefined,\n serviceKeys: string | string[],\n): boolean {\n const serviceKeySet = new Set(Array.isArray(serviceKeys) ? serviceKeys : [serviceKeys]);\n\n return Object.values(modules ?? {}).some(\n (binding) => binding.haveSamlIntegration === true &&\n binding.services.some((serviceKey) => serviceKeySet.has(serviceKey)),\n );\n}\n\nexport function resolveDeclaredApplicationModules<T>(\n modules: ApplicationModules | undefined,\n declaredModulesById: Record<string, T>,\n consumerLabel: string,\n): T[] {\n return pickApplicationModules(\n getDeclaredApplicationModuleIds(modules),\n declaredModulesById,\n consumerLabel,\n );\n}\n\nexport function resolveServiceBoundApplicationModules<T>(\n modules: ApplicationModules | undefined,\n serviceKey: string,\n declaredModulesById: Record<string, T>,\n consumerLabel = `service \"${serviceKey}\"`,\n): T[] {\n return pickApplicationModules(\n getServiceBoundApplicationModuleIds(modules, serviceKey),\n declaredModulesById,\n consumerLabel,\n );\n}\n"]}
@@ -0,0 +1,102 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Authored JWT TTL policy block for `wildo.infra.<env>.config.ts`.
4
+ *
5
+ * Source-of-truth contract (Slice 3.3, F-24):
6
+ * - `accessTokenExpirationMinutes` and `refreshTokenExpirationDays` are
7
+ * threaded by the CLI through the apps-manager init endpoint
8
+ * (`AdminAppInitializeRequest.serviceAuth`) into
9
+ * `Wildo_Application_Config.jwt.{accessTokenExpirationMinutes,
10
+ * refreshTokenExpirationDays}`. The runtime backend reads them at
11
+ * token-sign time (`auth-token-issuer.backend.service.ts`,
12
+ * `jwt.backend.service.ts`).
13
+ * - When the operator omits `serviceAuth`, apps-manager applies these
14
+ * schema-level defaults (15 min / 30 days) via
15
+ * `WildoAuthConfigSchema.parse({})` \u2014 NOT a service-local literal.
16
+ *
17
+ * Default tightening (Auth-hardening Slice A Step 5, 2026-04-13):
18
+ * - `accessTokenExpirationMinutes` default was lowered from 60 \u2192 15 in
19
+ * conjunction with the cookie migration (Slice A Steps 2 + 3). With the
20
+ * refresh token now confined to an `HttpOnly` cookie, an XSS bug only
21
+ * exposes the SHORT-lived access token; the smaller the access-token
22
+ * window, the smaller the residual XSS-stolen-token blast radius.
23
+ * Operator overrides via `serviceAuth.accessTokenExpirationMinutes` in
24
+ * `wildo.infra.<env>.config.ts` are untouched \u2014 author a value to
25
+ * deviate from the framework recommendation. The refresh-token TTL
26
+ * (`refreshTokenExpirationDays`) is unchanged at 30 days because the
27
+ * cookie-confined refresh token does not benefit from an additional
28
+ * TTL squeeze (rotation + JTI blacklist + reuse detection already bound
29
+ * the steal window per use).
30
+ *
31
+ * Algorithm selection is intentionally NOT authored here: the application
32
+ * JWT signing path (`jwt.backend.service.ts`) selects per the per-service
33
+ * key convention, and the apps-manager response-signer pins ES256 for the
34
+ * config-handshake envelope (anti-replay, see F-55 JSDoc on
35
+ * `platform-services-to-manager.apps-manager.platform.controller.ts`).
36
+ * Authoring an algorithm here would add a knob with no honest consumer.
37
+ *
38
+ * CLI init-path scope (Slice 3.3 closeout, L-4):
39
+ * - The CLI forwards this block via `wildo init` /
40
+ * `wildo sync --override` for a SINGLE wildo-application at a time
41
+ * (`AdminAppInitializeRequestSchema.serviceAuth`). There is no
42
+ * batch-init transport surface that fans `serviceAuth` out across
43
+ * multiple apps; `AdminAppInitializeTargetSchema.serviceAuth` is
44
+ * evaluated per target by the apps-manager init endpoint.
45
+ * - The "current" CLI flow always carries `env.serviceAuth` when
46
+ * present in `wildo.infra.<env>.config.ts`.
47
+ *
48
+ * `override:true` + omitted `serviceAuth` semantics (Slice 3.3.10):
49
+ * - The apps-manager production call site invokes
50
+ * `_merge_WildoApplicationConfig(currentConfig=null, newConfig={})`,
51
+ * which reduces to "return the freshly-built `defaultConfig`". The
52
+ * `defaultConfig` is seeded by `_getDefault_WildoApplicationConfig`
53
+ * with `WildoAuthConfigSchema.parse(serviceAuth ?? {})`. So when an
54
+ * older CLI or a direct HTTP caller omits `serviceAuth` AND passes
55
+ * `override:true`, the persisted TTLs are RESET to the schema
56
+ * defaults below (60 min / 30 days) \u2014 they are NOT preserved. The
57
+ * only path that preserves the persisted TTLs is `override:false`,
58
+ * where the upstream guard at
59
+ * `wildo-application-lifecycle.apps-manager.platform.service.ts:~869`
60
+ * skips the `repository.update` call entirely.
61
+ * - Caveat: that upstream guard ALSO triggers `repository.update` on
62
+ * `needsPublicKeyUpdate` and `needsDatabaseConfigUpdate` (e.g. JWT
63
+ * key rotation, k8s host hydration). When either bypass fires with
64
+ * `override:false` AND `serviceAuth` omitted, the persisted TTLs
65
+ * silently rebind to the schema defaults too. See the JSDoc on
66
+ * `_merge_WildoApplicationConfig` for the full enumeration.
67
+ *
68
+ * Pinned by `wildo-application-lifecycle.defaults.test.ts` (production
69
+ * shape: `(null, {})` + omitted `serviceAuth` returns 15/30 from
70
+ * `WildoAuthConfigSchema.parse({})`).
71
+ */
72
+ /**
73
+ * `z.strictObject` (Zod 4) is intentional: any unknown key (e.g. a
74
+ * re-introduced `jwtAlgorithm`, or a typo'd `accessTokenExpirationMinute`)
75
+ * must surface as a parse error instead of being silently stripped. This
76
+ * is the framework-mindset enforcement of the "no honest consumer => no
77
+ * authored knob" rule documented in the file-level JSDoc above.
78
+ */
79
+ export declare const WildoAuthConfigSchema: z.ZodObject<{
80
+ /**
81
+ * Access-token TTL in minutes. Authored value > schema default (15).
82
+ * Threaded into `Wildo_Application_Config.jwt.accessTokenExpiration
83
+ * Minutes` at apps-manager init time; consumed at token-sign time by
84
+ * `AuthTokenIssuerBackendService.issueAccessToken`.
85
+ *
86
+ * Default = 15 (Auth-hardening Slice A Step 5, 2026-04-13). Pre-Slice-A
87
+ * the default was 60 \u2014 the file-level JSDoc above documents the
88
+ * threat-model rationale for the tightening.
89
+ */
90
+ accessTokenExpirationMinutes: z.ZodDefault<z.ZodNumber>;
91
+ /**
92
+ * Refresh-token TTL in days. Authored value > schema default (30).
93
+ * Threaded into `Wildo_Application_Config.jwt.refreshTokenExpiration
94
+ * Days` at apps-manager init time; consumed at token-sign time by
95
+ * `JwtBackendService.createRefreshToken` and at session-bookkeeping
96
+ * time by `AuthTokenIssuerBackendService.invalidateAllTokensForUser`.
97
+ */
98
+ refreshTokenExpirationDays: z.ZodDefault<z.ZodNumber>;
99
+ }, z.core.$strict>;
100
+ export type WildoAuthConfig = z.infer<typeof WildoAuthConfigSchema>;
101
+ export type WildoAuthConfigInput = z.input<typeof WildoAuthConfigSchema>;
102
+ //# sourceMappingURL=auth.schemas.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/project-config/shared/auth.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqEG;AACH;;;;;;GAMG;AACH,eAAO,MAAM,qBAAqB;IAChC;;;;;;;;;OASG;;IAEH;;;;;;OAMG;;kBAEH,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,100 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Authored JWT TTL policy block for `wildo.infra.<env>.config.ts`.
4
+ *
5
+ * Source-of-truth contract (Slice 3.3, F-24):
6
+ * - `accessTokenExpirationMinutes` and `refreshTokenExpirationDays` are
7
+ * threaded by the CLI through the apps-manager init endpoint
8
+ * (`AdminAppInitializeRequest.serviceAuth`) into
9
+ * `Wildo_Application_Config.jwt.{accessTokenExpirationMinutes,
10
+ * refreshTokenExpirationDays}`. The runtime backend reads them at
11
+ * token-sign time (`auth-token-issuer.backend.service.ts`,
12
+ * `jwt.backend.service.ts`).
13
+ * - When the operator omits `serviceAuth`, apps-manager applies these
14
+ * schema-level defaults (15 min / 30 days) via
15
+ * `WildoAuthConfigSchema.parse({})` \u2014 NOT a service-local literal.
16
+ *
17
+ * Default tightening (Auth-hardening Slice A Step 5, 2026-04-13):
18
+ * - `accessTokenExpirationMinutes` default was lowered from 60 \u2192 15 in
19
+ * conjunction with the cookie migration (Slice A Steps 2 + 3). With the
20
+ * refresh token now confined to an `HttpOnly` cookie, an XSS bug only
21
+ * exposes the SHORT-lived access token; the smaller the access-token
22
+ * window, the smaller the residual XSS-stolen-token blast radius.
23
+ * Operator overrides via `serviceAuth.accessTokenExpirationMinutes` in
24
+ * `wildo.infra.<env>.config.ts` are untouched \u2014 author a value to
25
+ * deviate from the framework recommendation. The refresh-token TTL
26
+ * (`refreshTokenExpirationDays`) is unchanged at 30 days because the
27
+ * cookie-confined refresh token does not benefit from an additional
28
+ * TTL squeeze (rotation + JTI blacklist + reuse detection already bound
29
+ * the steal window per use).
30
+ *
31
+ * Algorithm selection is intentionally NOT authored here: the application
32
+ * JWT signing path (`jwt.backend.service.ts`) selects per the per-service
33
+ * key convention, and the apps-manager response-signer pins ES256 for the
34
+ * config-handshake envelope (anti-replay, see F-55 JSDoc on
35
+ * `platform-services-to-manager.apps-manager.platform.controller.ts`).
36
+ * Authoring an algorithm here would add a knob with no honest consumer.
37
+ *
38
+ * CLI init-path scope (Slice 3.3 closeout, L-4):
39
+ * - The CLI forwards this block via `wildo init` /
40
+ * `wildo sync --override` for a SINGLE wildo-application at a time
41
+ * (`AdminAppInitializeRequestSchema.serviceAuth`). There is no
42
+ * batch-init transport surface that fans `serviceAuth` out across
43
+ * multiple apps; `AdminAppInitializeTargetSchema.serviceAuth` is
44
+ * evaluated per target by the apps-manager init endpoint.
45
+ * - The "current" CLI flow always carries `env.serviceAuth` when
46
+ * present in `wildo.infra.<env>.config.ts`.
47
+ *
48
+ * `override:true` + omitted `serviceAuth` semantics (Slice 3.3.10):
49
+ * - The apps-manager production call site invokes
50
+ * `_merge_WildoApplicationConfig(currentConfig=null, newConfig={})`,
51
+ * which reduces to "return the freshly-built `defaultConfig`". The
52
+ * `defaultConfig` is seeded by `_getDefault_WildoApplicationConfig`
53
+ * with `WildoAuthConfigSchema.parse(serviceAuth ?? {})`. So when an
54
+ * older CLI or a direct HTTP caller omits `serviceAuth` AND passes
55
+ * `override:true`, the persisted TTLs are RESET to the schema
56
+ * defaults below (60 min / 30 days) \u2014 they are NOT preserved. The
57
+ * only path that preserves the persisted TTLs is `override:false`,
58
+ * where the upstream guard at
59
+ * `wildo-application-lifecycle.apps-manager.platform.service.ts:~869`
60
+ * skips the `repository.update` call entirely.
61
+ * - Caveat: that upstream guard ALSO triggers `repository.update` on
62
+ * `needsPublicKeyUpdate` and `needsDatabaseConfigUpdate` (e.g. JWT
63
+ * key rotation, k8s host hydration). When either bypass fires with
64
+ * `override:false` AND `serviceAuth` omitted, the persisted TTLs
65
+ * silently rebind to the schema defaults too. See the JSDoc on
66
+ * `_merge_WildoApplicationConfig` for the full enumeration.
67
+ *
68
+ * Pinned by `wildo-application-lifecycle.defaults.test.ts` (production
69
+ * shape: `(null, {})` + omitted `serviceAuth` returns 15/30 from
70
+ * `WildoAuthConfigSchema.parse({})`).
71
+ */
72
+ /**
73
+ * `z.strictObject` (Zod 4) is intentional: any unknown key (e.g. a
74
+ * re-introduced `jwtAlgorithm`, or a typo'd `accessTokenExpirationMinute`)
75
+ * must surface as a parse error instead of being silently stripped. This
76
+ * is the framework-mindset enforcement of the "no honest consumer => no
77
+ * authored knob" rule documented in the file-level JSDoc above.
78
+ */
79
+ export const WildoAuthConfigSchema = z.strictObject({
80
+ /**
81
+ * Access-token TTL in minutes. Authored value > schema default (15).
82
+ * Threaded into `Wildo_Application_Config.jwt.accessTokenExpiration
83
+ * Minutes` at apps-manager init time; consumed at token-sign time by
84
+ * `AuthTokenIssuerBackendService.issueAccessToken`.
85
+ *
86
+ * Default = 15 (Auth-hardening Slice A Step 5, 2026-04-13). Pre-Slice-A
87
+ * the default was 60 \u2014 the file-level JSDoc above documents the
88
+ * threat-model rationale for the tightening.
89
+ */
90
+ accessTokenExpirationMinutes: z.number().int().positive().default(15),
91
+ /**
92
+ * Refresh-token TTL in days. Authored value > schema default (30).
93
+ * Threaded into `Wildo_Application_Config.jwt.refreshTokenExpiration
94
+ * Days` at apps-manager init time; consumed at token-sign time by
95
+ * `JwtBackendService.createRefreshToken` and at session-bookkeeping
96
+ * time by `AuthTokenIssuerBackendService.invalidateAllTokensForUser`.
97
+ */
98
+ refreshTokenExpirationDays: z.number().int().positive().default(30),
99
+ });
100
+ //# sourceMappingURL=auth.schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.schemas.js","sourceRoot":"","sources":["../../../../../src/project-config/shared/auth.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqEG;AACH;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,YAAY,CAAC;IAClD;;;;;;;;;OASG;IACH,4BAA4B,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;IACrE;;;;;;OAMG;IACH,0BAA0B,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;CACpE,CAAC,CAAC","sourcesContent":["import { z } from 'zod';\n\n/**\n * Authored JWT TTL policy block for `wildo.infra.<env>.config.ts`.\n *\n * Source-of-truth contract (Slice 3.3, F-24):\n * - `accessTokenExpirationMinutes` and `refreshTokenExpirationDays` are\n * threaded by the CLI through the apps-manager init endpoint\n * (`AdminAppInitializeRequest.serviceAuth`) into\n * `Wildo_Application_Config.jwt.{accessTokenExpirationMinutes,\n * refreshTokenExpirationDays}`. The runtime backend reads them at\n * token-sign time (`auth-token-issuer.backend.service.ts`,\n * `jwt.backend.service.ts`).\n * - When the operator omits `serviceAuth`, apps-manager applies these\n * schema-level defaults (15 min / 30 days) via\n * `WildoAuthConfigSchema.parse({})` \\u2014 NOT a service-local literal.\n *\n * Default tightening (Auth-hardening Slice A Step 5, 2026-04-13):\n * - `accessTokenExpirationMinutes` default was lowered from 60 \\u2192 15 in\n * conjunction with the cookie migration (Slice A Steps 2 + 3). With the\n * refresh token now confined to an `HttpOnly` cookie, an XSS bug only\n * exposes the SHORT-lived access token; the smaller the access-token\n * window, the smaller the residual XSS-stolen-token blast radius.\n * Operator overrides via `serviceAuth.accessTokenExpirationMinutes` in\n * `wildo.infra.<env>.config.ts` are untouched \\u2014 author a value to\n * deviate from the framework recommendation. The refresh-token TTL\n * (`refreshTokenExpirationDays`) is unchanged at 30 days because the\n * cookie-confined refresh token does not benefit from an additional\n * TTL squeeze (rotation + JTI blacklist + reuse detection already bound\n * the steal window per use).\n *\n * Algorithm selection is intentionally NOT authored here: the application\n * JWT signing path (`jwt.backend.service.ts`) selects per the per-service\n * key convention, and the apps-manager response-signer pins ES256 for the\n * config-handshake envelope (anti-replay, see F-55 JSDoc on\n * `platform-services-to-manager.apps-manager.platform.controller.ts`).\n * Authoring an algorithm here would add a knob with no honest consumer.\n *\n * CLI init-path scope (Slice 3.3 closeout, L-4):\n * - The CLI forwards this block via `wildo init` /\n * `wildo sync --override` for a SINGLE wildo-application at a time\n * (`AdminAppInitializeRequestSchema.serviceAuth`). There is no\n * batch-init transport surface that fans `serviceAuth` out across\n * multiple apps; `AdminAppInitializeTargetSchema.serviceAuth` is\n * evaluated per target by the apps-manager init endpoint.\n * - The \"current\" CLI flow always carries `env.serviceAuth` when\n * present in `wildo.infra.<env>.config.ts`.\n *\n * `override:true` + omitted `serviceAuth` semantics (Slice 3.3.10):\n * - The apps-manager production call site invokes\n * `_merge_WildoApplicationConfig(currentConfig=null, newConfig={})`,\n * which reduces to \"return the freshly-built `defaultConfig`\". The\n * `defaultConfig` is seeded by `_getDefault_WildoApplicationConfig`\n * with `WildoAuthConfigSchema.parse(serviceAuth ?? {})`. So when an\n * older CLI or a direct HTTP caller omits `serviceAuth` AND passes\n * `override:true`, the persisted TTLs are RESET to the schema\n * defaults below (60 min / 30 days) \\u2014 they are NOT preserved. The\n * only path that preserves the persisted TTLs is `override:false`,\n * where the upstream guard at\n * `wildo-application-lifecycle.apps-manager.platform.service.ts:~869`\n * skips the `repository.update` call entirely.\n * - Caveat: that upstream guard ALSO triggers `repository.update` on\n * `needsPublicKeyUpdate` and `needsDatabaseConfigUpdate` (e.g. JWT\n * key rotation, k8s host hydration). When either bypass fires with\n * `override:false` AND `serviceAuth` omitted, the persisted TTLs\n * silently rebind to the schema defaults too. See the JSDoc on\n * `_merge_WildoApplicationConfig` for the full enumeration.\n *\n * Pinned by `wildo-application-lifecycle.defaults.test.ts` (production\n * shape: `(null, {})` + omitted `serviceAuth` returns 15/30 from\n * `WildoAuthConfigSchema.parse({})`).\n */\n/**\n * `z.strictObject` (Zod 4) is intentional: any unknown key (e.g. a\n * re-introduced `jwtAlgorithm`, or a typo'd `accessTokenExpirationMinute`)\n * must surface as a parse error instead of being silently stripped. This\n * is the framework-mindset enforcement of the \"no honest consumer => no\n * authored knob\" rule documented in the file-level JSDoc above.\n */\nexport const WildoAuthConfigSchema = z.strictObject({\n /**\n * Access-token TTL in minutes. Authored value > schema default (15).\n * Threaded into `Wildo_Application_Config.jwt.accessTokenExpiration\n * Minutes` at apps-manager init time; consumed at token-sign time by\n * `AuthTokenIssuerBackendService.issueAccessToken`.\n *\n * Default = 15 (Auth-hardening Slice A Step 5, 2026-04-13). Pre-Slice-A\n * the default was 60 \\u2014 the file-level JSDoc above documents the\n * threat-model rationale for the tightening.\n */\n accessTokenExpirationMinutes: z.number().int().positive().default(15),\n /**\n * Refresh-token TTL in days. Authored value > schema default (30).\n * Threaded into `Wildo_Application_Config.jwt.refreshTokenExpiration\n * Days` at apps-manager init time; consumed at token-sign time by\n * `JwtBackendService.createRefreshToken` and at session-bookkeeping\n * time by `AuthTokenIssuerBackendService.invalidateAllTokensForUser`.\n */\n refreshTokenExpirationDays: z.number().int().positive().default(30),\n});\nexport type WildoAuthConfig = z.infer<typeof WildoAuthConfigSchema>;\nexport type WildoAuthConfigInput = z.input<typeof WildoAuthConfigSchema>;\n"]}