@wildo-ai/wildo-cli 1.1.2 → 1.1.3

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 (947) hide show
  1. package/dist/bin/wildo.d.ts.map +1 -1
  2. package/dist/src/__tests__/sandbox-dependencies.test-helpers.d.ts.map +1 -1
  3. package/dist/src/commands/acp/probe.command.d.ts.map +1 -1
  4. package/dist/src/commands/acp/probe.command.js +13 -0
  5. package/dist/src/commands/acp/probe.command.js.map +1 -1
  6. package/dist/src/commands/align-deps.command.d.ts.map +1 -1
  7. package/dist/src/commands/assets/sync.command.d.ts +6 -0
  8. package/dist/src/commands/assets/sync.command.d.ts.map +1 -1
  9. package/dist/src/commands/assets/sync.command.js +13 -3
  10. package/dist/src/commands/assets/sync.command.js.map +1 -1
  11. package/dist/src/commands/brand/propagate.command.d.ts.map +1 -1
  12. package/dist/src/commands/compose.command.d.ts.map +1 -1
  13. package/dist/src/commands/compose.command.js +16 -0
  14. package/dist/src/commands/compose.command.js.map +1 -1
  15. package/dist/src/commands/config/__tests__/reapply-declaration.command.test.d.ts.map +1 -1
  16. package/dist/src/commands/config/__tests__/reapply-declaration.command.test.js +1 -1
  17. package/dist/src/commands/config/__tests__/reapply-declaration.command.test.js.map +1 -1
  18. package/dist/src/commands/config/__tests__/sync.command.test.d.ts.map +1 -1
  19. package/dist/src/commands/config/__tests__/sync.command.test.js +115 -8
  20. package/dist/src/commands/config/__tests__/sync.command.test.js.map +1 -1
  21. package/dist/src/commands/config/__tests__/validate.command.test.d.ts.map +1 -1
  22. package/dist/src/commands/config/mutate.command.d.ts.map +1 -1
  23. package/dist/src/commands/config/reapply-declaration.command.d.ts.map +1 -1
  24. package/dist/src/commands/config/sync.command.d.ts +36 -0
  25. package/dist/src/commands/config/sync.command.d.ts.map +1 -1
  26. package/dist/src/commands/config/sync.command.js +61 -7
  27. package/dist/src/commands/config/sync.command.js.map +1 -1
  28. package/dist/src/commands/config/validate.command.d.ts.map +1 -1
  29. package/dist/src/commands/context/__tests__/jurisdictions.command.test.d.ts +19 -0
  30. package/dist/src/commands/context/__tests__/jurisdictions.command.test.d.ts.map +1 -0
  31. package/dist/src/commands/context/__tests__/jurisdictions.command.test.js +106 -0
  32. package/dist/src/commands/context/__tests__/jurisdictions.command.test.js.map +1 -0
  33. package/dist/src/commands/context/coherence.command.d.ts.map +1 -1
  34. package/dist/src/commands/context/context-command.utils.d.ts.map +1 -1
  35. package/dist/src/commands/context/health.command.d.ts.map +1 -1
  36. package/dist/src/commands/context/info.command.d.ts.map +1 -1
  37. package/dist/src/commands/context/journey.command.d.ts +6 -2
  38. package/dist/src/commands/context/journey.command.d.ts.map +1 -1
  39. package/dist/src/commands/context/journey.command.js +8 -4
  40. package/dist/src/commands/context/journey.command.js.map +1 -1
  41. package/dist/src/commands/context/jurisdictions.command.d.ts +36 -0
  42. package/dist/src/commands/context/jurisdictions.command.d.ts.map +1 -0
  43. package/dist/src/commands/context/jurisdictions.command.js +115 -0
  44. package/dist/src/commands/context/jurisdictions.command.js.map +1 -0
  45. package/dist/src/commands/context/list.command.d.ts.map +1 -1
  46. package/dist/src/commands/db/db-schema-plan.utils.d.ts.map +1 -1
  47. package/dist/src/commands/db/diff.command.d.ts.map +1 -1
  48. package/dist/src/commands/db/generate.command.d.ts.map +1 -1
  49. package/dist/src/commands/db/migrate.command.d.ts.map +1 -1
  50. package/dist/src/commands/db/resolve.command.d.ts.map +1 -1
  51. package/dist/src/commands/dev/__tests__/design-tokens.command.test.d.ts.map +1 -1
  52. package/dist/src/commands/dev/__tests__/start.command.test.d.ts.map +1 -1
  53. package/dist/src/commands/dev/__tests__/start.command.test.js +6 -6
  54. package/dist/src/commands/dev/__tests__/start.command.test.js.map +1 -1
  55. package/dist/src/commands/dev/__tests__/stop.command.test.d.ts.map +1 -1
  56. package/dist/src/commands/dev/__tests__/sync-csp.command.test.d.ts.map +1 -1
  57. package/dist/src/commands/dev/__tests__/sync-csp.command.test.js +71 -0
  58. package/dist/src/commands/dev/__tests__/sync-csp.command.test.js.map +1 -1
  59. package/dist/src/commands/dev/charts-audit.command.d.ts.map +1 -1
  60. package/dist/src/commands/dev/charts-audit.command.js +1 -1
  61. package/dist/src/commands/dev/charts-audit.command.js.map +1 -1
  62. package/dist/src/commands/dev/design-tokens-generate.command.d.ts.map +1 -1
  63. package/dist/src/commands/dev/design-tokens-init.command.d.ts.map +1 -1
  64. package/dist/src/commands/dev/design-tokens-validate.command.d.ts.map +1 -1
  65. package/dist/src/commands/dev/force-stop.command.d.ts.map +1 -1
  66. package/dist/src/commands/dev/resources.command.d.ts.map +1 -1
  67. package/dist/src/commands/dev/start.command.d.ts.map +1 -1
  68. package/dist/src/commands/dev/start.command.js +8 -7
  69. package/dist/src/commands/dev/start.command.js.map +1 -1
  70. package/dist/src/commands/dev/stop-all.command.d.ts.map +1 -1
  71. package/dist/src/commands/dev/sync-csp.command.d.ts.map +1 -1
  72. package/dist/src/commands/dev/sync-csp.command.js +35 -7
  73. package/dist/src/commands/dev/sync-csp.command.js.map +1 -1
  74. package/dist/src/commands/docs/__tests__/publish.command.test.d.ts +2 -0
  75. package/dist/src/commands/docs/__tests__/publish.command.test.d.ts.map +1 -0
  76. package/dist/src/commands/docs/__tests__/publish.command.test.js +101 -0
  77. package/dist/src/commands/docs/__tests__/publish.command.test.js.map +1 -0
  78. package/dist/src/commands/docs/publish.command.d.ts +29 -0
  79. package/dist/src/commands/docs/publish.command.d.ts.map +1 -0
  80. package/dist/src/commands/docs/publish.command.js +82 -0
  81. package/dist/src/commands/docs/publish.command.js.map +1 -0
  82. package/dist/src/commands/frontend/publish.command.d.ts.map +1 -1
  83. package/dist/src/commands/fwk/__tests__/dev-skills.command.test.d.ts.map +1 -1
  84. package/dist/src/commands/fwk/__tests__/generate-docs.command.test.d.ts.map +1 -1
  85. package/dist/src/commands/fwk/__tests__/generate-docs.command.test.js.map +1 -1
  86. package/dist/src/commands/fwk/audit.command.d.ts.map +1 -1
  87. package/dist/src/commands/fwk/dev-skills.command.d.ts.map +1 -1
  88. package/dist/src/commands/fwk/dev-skills.command.js +12 -0
  89. package/dist/src/commands/fwk/dev-skills.command.js.map +1 -1
  90. package/dist/src/commands/fwk/generate-docs.command.d.ts.map +1 -1
  91. package/dist/src/commands/fwk/generate-providers.command.d.ts +21 -0
  92. package/dist/src/commands/fwk/generate-providers.command.d.ts.map +1 -0
  93. package/dist/src/commands/fwk/generate-providers.command.js +309 -0
  94. package/dist/src/commands/fwk/generate-providers.command.js.map +1 -0
  95. package/dist/src/commands/fwk/graph.command.d.ts.map +1 -1
  96. package/dist/src/commands/fwk/publish-all.command.d.ts.map +1 -1
  97. package/dist/src/commands/fwk/publish-docker.command.d.ts.map +1 -1
  98. package/dist/src/commands/fwk/publish-npm.command.d.ts.map +1 -1
  99. package/dist/src/commands/fwk/version-bump.command.d.ts.map +1 -1
  100. package/dist/src/commands/fwk/version-set.command.d.ts.map +1 -1
  101. package/dist/src/commands/fwk/version-show.command.d.ts.map +1 -1
  102. package/dist/src/commands/fwk/version-show.command.js +9 -1
  103. package/dist/src/commands/fwk/version-show.command.js.map +1 -1
  104. package/dist/src/commands/fwk/version-sync.command.d.ts.map +1 -1
  105. package/dist/src/commands/fwk/what-touches.command.d.ts.map +1 -1
  106. package/dist/src/commands/fwk/wt-status.command.d.ts +13 -4
  107. package/dist/src/commands/fwk/wt-status.command.d.ts.map +1 -1
  108. package/dist/src/commands/fwk/wt-status.command.js +34 -5
  109. package/dist/src/commands/fwk/wt-status.command.js.map +1 -1
  110. package/dist/src/commands/fwk/wt-tail.command.d.ts +12 -6
  111. package/dist/src/commands/fwk/wt-tail.command.d.ts.map +1 -1
  112. package/dist/src/commands/fwk/wt-tail.command.js +40 -10
  113. package/dist/src/commands/fwk/wt-tail.command.js.map +1 -1
  114. package/dist/src/commands/generate/__tests__/email-command.utils.test.d.ts.map +1 -1
  115. package/dist/src/commands/generate/__tests__/email-command.utils.test.js +0 -1
  116. package/dist/src/commands/generate/__tests__/email-command.utils.test.js.map +1 -1
  117. package/dist/src/commands/generate/email-command.utils.d.ts.map +1 -1
  118. package/dist/src/commands/generate/email-command.utils.js +1 -0
  119. package/dist/src/commands/generate/email-command.utils.js.map +1 -1
  120. package/dist/src/commands/generate/email-preview.command.d.ts.map +1 -1
  121. package/dist/src/commands/generate/email-status.command.d.ts.map +1 -1
  122. package/dist/src/commands/generate/email-test-send.command.d.ts.map +1 -1
  123. package/dist/src/commands/generate/email-translate.command.d.ts.map +1 -1
  124. package/dist/src/commands/generate/email.command.d.ts.map +1 -1
  125. package/dist/src/commands/generate/labelling-command.utils.d.ts.map +1 -1
  126. package/dist/src/commands/generate/labelling-command.utils.js +1 -0
  127. package/dist/src/commands/generate/labelling-command.utils.js.map +1 -1
  128. package/dist/src/commands/generate/labels-plan.command.d.ts.map +1 -1
  129. package/dist/src/commands/generate/labels.command.d.ts.map +1 -1
  130. package/dist/src/commands/generate/translate.command.d.ts.map +1 -1
  131. package/dist/src/commands/help.command.d.ts.map +1 -1
  132. package/dist/src/commands/help.command.js +2 -0
  133. package/dist/src/commands/help.command.js.map +1 -1
  134. package/dist/src/commands/init.command.d.ts +17 -0
  135. package/dist/src/commands/init.command.d.ts.map +1 -1
  136. package/dist/src/commands/init.command.js +57 -4
  137. package/dist/src/commands/init.command.js.map +1 -1
  138. package/dist/src/commands/local/__tests__/dev-status.command.test.d.ts.map +1 -1
  139. package/dist/src/commands/local/__tests__/dev.command.test.d.ts.map +1 -1
  140. package/dist/src/commands/local/__tests__/dev.command.test.js +60 -0
  141. package/dist/src/commands/local/__tests__/dev.command.test.js.map +1 -1
  142. package/dist/src/commands/local/__tests__/doctor.command.test.d.ts.map +1 -1
  143. package/dist/src/commands/local/__tests__/doctor.command.test.js +16 -2
  144. package/dist/src/commands/local/__tests__/doctor.command.test.js.map +1 -1
  145. package/dist/src/commands/local/__tests__/init.command.test.d.ts.map +1 -1
  146. package/dist/src/commands/local/__tests__/init.command.test.js +28 -1
  147. package/dist/src/commands/local/__tests__/init.command.test.js.map +1 -1
  148. package/dist/src/commands/local/__tests__/reinit.command.test.d.ts.map +1 -1
  149. package/dist/src/commands/local/__tests__/reset.command.test.d.ts.map +1 -1
  150. package/dist/src/commands/local/__tests__/up.command.test.d.ts.map +1 -1
  151. package/dist/src/commands/local/__tests__/up.command.test.js +7 -0
  152. package/dist/src/commands/local/__tests__/up.command.test.js.map +1 -1
  153. package/dist/src/commands/local/dev-status.command.d.ts.map +1 -1
  154. package/dist/src/commands/local/dev.command.d.ts +6 -3
  155. package/dist/src/commands/local/dev.command.d.ts.map +1 -1
  156. package/dist/src/commands/local/dev.command.js +13 -4
  157. package/dist/src/commands/local/dev.command.js.map +1 -1
  158. package/dist/src/commands/local/doctor.command.d.ts +9 -0
  159. package/dist/src/commands/local/doctor.command.d.ts.map +1 -1
  160. package/dist/src/commands/local/doctor.command.js +24 -6
  161. package/dist/src/commands/local/doctor.command.js.map +1 -1
  162. package/dist/src/commands/local/down.command.d.ts.map +1 -1
  163. package/dist/src/commands/local/init.command.d.ts.map +1 -1
  164. package/dist/src/commands/local/init.command.js +11 -2
  165. package/dist/src/commands/local/init.command.js.map +1 -1
  166. package/dist/src/commands/local/logs.command.d.ts.map +1 -1
  167. package/dist/src/commands/local/reinit.command.d.ts.map +1 -1
  168. package/dist/src/commands/local/reset.command.d.ts.map +1 -1
  169. package/dist/src/commands/local/status.command.d.ts.map +1 -1
  170. package/dist/src/commands/local/up.command.d.ts.map +1 -1
  171. package/dist/src/commands/local/up.command.js.map +1 -1
  172. package/dist/src/commands/lock/__tests__/check.command.test.d.ts.map +1 -1
  173. package/dist/src/commands/lock/__tests__/check.live.contract.test.d.ts.map +1 -1
  174. package/dist/src/commands/lock/check.command.d.ts.map +1 -1
  175. package/dist/src/commands/lock/check.command.js +3 -10
  176. package/dist/src/commands/lock/check.command.js.map +1 -1
  177. package/dist/src/commands/market/__tests__/generate.command.test.d.ts.map +1 -1
  178. package/dist/src/commands/market/__tests__/market-command.utils.test.d.ts.map +1 -1
  179. package/dist/src/commands/market/__tests__/market-command.utils.test.js +0 -1
  180. package/dist/src/commands/market/__tests__/market-command.utils.test.js.map +1 -1
  181. package/dist/src/commands/market/generate.command.d.ts.map +1 -1
  182. package/dist/src/commands/market/market-command.utils.d.ts.map +1 -1
  183. package/dist/src/commands/market/market-command.utils.js +1 -0
  184. package/dist/src/commands/market/market-command.utils.js.map +1 -1
  185. package/dist/src/commands/providers/__tests__/required-inputs.test.d.ts +2 -0
  186. package/dist/src/commands/providers/__tests__/required-inputs.test.d.ts.map +1 -0
  187. package/dist/src/commands/providers/__tests__/required-inputs.test.js +35 -0
  188. package/dist/src/commands/providers/__tests__/required-inputs.test.js.map +1 -0
  189. package/dist/src/commands/providers/show.command.d.ts +51 -0
  190. package/dist/src/commands/providers/show.command.d.ts.map +1 -0
  191. package/dist/src/commands/providers/show.command.js +152 -0
  192. package/dist/src/commands/providers/show.command.js.map +1 -0
  193. package/dist/src/commands/registry/add.command.d.ts.map +1 -1
  194. package/dist/src/commands/registry/info.command.d.ts.map +1 -1
  195. package/dist/src/commands/registry/lockfile-smoke.command.d.ts.map +1 -1
  196. package/dist/src/commands/registry/login.command.d.ts.map +1 -1
  197. package/dist/src/commands/registry/logout.command.d.ts.map +1 -1
  198. package/dist/src/commands/registry/ping.command.d.ts.map +1 -1
  199. package/dist/src/commands/registry/publish.command.d.ts.map +1 -1
  200. package/dist/src/commands/registry/remove.command.d.ts.map +1 -1
  201. package/dist/src/commands/registry/repair-lockfile.command.d.ts.map +1 -1
  202. package/dist/src/commands/registry/search.command.d.ts.map +1 -1
  203. package/dist/src/commands/registry/update.command.d.ts.map +1 -1
  204. package/dist/src/commands/registry/whoami.command.d.ts.map +1 -1
  205. package/dist/src/commands/remote/__tests__/remote-commands.test.d.ts.map +1 -1
  206. package/dist/src/commands/remote/create.command.d.ts.map +1 -1
  207. package/dist/src/commands/remote/list.command.d.ts.map +1 -1
  208. package/dist/src/commands/remote/status.command.d.ts.map +1 -1
  209. package/dist/src/commands/remote/sync.command.d.ts.map +1 -1
  210. package/dist/src/commands/setup.command.d.ts.map +1 -1
  211. package/dist/src/commands/version.command.d.ts.map +1 -1
  212. package/dist/src/commands/website/__tests__/audit.command.test.d.ts.map +1 -1
  213. package/dist/src/commands/website/audit.command.d.ts.map +1 -1
  214. package/dist/src/commands/workbench/__tests__/workbench.commands.test.d.ts.map +1 -1
  215. package/dist/src/commands/workbench/open.command.d.ts.map +1 -1
  216. package/dist/src/commands/workbench/status.command.d.ts.map +1 -1
  217. package/dist/src/infrastructure/errors/error.utils.d.ts.map +1 -1
  218. package/dist/src/infrastructure/io/file.utils.d.ts.map +1 -1
  219. package/dist/src/infrastructure/io/io.schemas.d.ts.map +1 -1
  220. package/dist/src/infrastructure/io/template-processor.d.ts.map +1 -1
  221. package/dist/src/infrastructure/logger/logger.service.d.ts.map +1 -1
  222. package/dist/src/infrastructure/process/__tests__/spawn.utils.test.d.ts.map +1 -1
  223. package/dist/src/infrastructure/process/spawn.utils.d.ts.map +1 -1
  224. package/dist/src/infrastructure/ui/formatting.service.d.ts.map +1 -1
  225. package/dist/src/infrastructure/ui/interaction-engine.service.d.ts.map +1 -1
  226. package/dist/src/infrastructure/ui/markdown-renderer.service.d.ts.map +1 -1
  227. package/dist/src/infrastructure/ui/ui.schemas.d.ts.map +1 -1
  228. package/dist/src/infrastructure/utils/string.utils.d.ts.map +1 -1
  229. package/dist/src/infrastructure/validation/validator.service.d.ts.map +1 -1
  230. package/dist/src/kernel/__tests__/bootstrap.test.d.ts.map +1 -1
  231. package/dist/src/kernel/__tests__/command-registry.test.d.ts.map +1 -1
  232. package/dist/src/kernel/__tests__/command-registry.test.js +9 -0
  233. package/dist/src/kernel/__tests__/command-registry.test.js.map +1 -1
  234. package/dist/src/kernel/__tests__/command-runner.test.d.ts.map +1 -1
  235. package/dist/src/kernel/__tests__/command-scope-utils.test.d.ts.map +1 -1
  236. package/dist/src/kernel/__tests__/flag-utils.test.d.ts.map +1 -1
  237. package/dist/src/kernel/__tests__/hooks.test.d.ts.map +1 -1
  238. package/dist/src/kernel/base-command.d.ts.map +1 -1
  239. package/dist/src/kernel/bootstrap.d.ts.map +1 -1
  240. package/dist/src/kernel/command-registry.d.ts.map +1 -1
  241. package/dist/src/kernel/command-registry.js +6 -0
  242. package/dist/src/kernel/command-registry.js.map +1 -1
  243. package/dist/src/kernel/command-runner.d.ts.map +1 -1
  244. package/dist/src/kernel/command-scope-utils.d.ts.map +1 -1
  245. package/dist/src/kernel/flag-utils.d.ts.map +1 -1
  246. package/dist/src/kernel/hooks.d.ts.map +1 -1
  247. package/dist/src/kernel/logger.d.ts.map +1 -1
  248. package/dist/src/kernel/types.d.ts +17 -1
  249. package/dist/src/kernel/types.d.ts.map +1 -1
  250. package/dist/src/kernel/types.js +16 -0
  251. package/dist/src/kernel/types.js.map +1 -1
  252. package/dist/src/main.d.ts.map +1 -1
  253. package/dist/src/modules/domain/credentials/__tests__/admin-user.module.test.d.ts.map +1 -1
  254. package/dist/src/modules/domain/credentials/__tests__/providers-config.module.test.d.ts.map +1 -1
  255. package/dist/src/modules/domain/credentials/__tests__/providers-config.module.test.js +2 -2
  256. package/dist/src/modules/domain/credentials/__tests__/providers-config.module.test.js.map +1 -1
  257. package/dist/src/modules/domain/credentials/admin-user.module.d.ts.map +1 -1
  258. package/dist/src/modules/domain/credentials/module.types.d.ts.map +1 -1
  259. package/dist/src/modules/domain/credentials/providers-config.module.d.ts +17 -9
  260. package/dist/src/modules/domain/credentials/providers-config.module.d.ts.map +1 -1
  261. package/dist/src/modules/domain/credentials/providers-config.module.js +18 -10
  262. package/dist/src/modules/domain/credentials/providers-config.module.js.map +1 -1
  263. package/dist/src/modules/domain/environment/__tests__/database-config.module.test.d.ts.map +1 -1
  264. package/dist/src/modules/domain/environment/database-config.module.d.ts.map +1 -1
  265. package/dist/src/modules/domain/environment/module.types.d.ts.map +1 -1
  266. package/dist/src/modules/domain/environment/paths-config.module.d.ts.map +1 -1
  267. package/dist/src/modules/domain/environment/runtime-selector.module.d.ts.map +1 -1
  268. package/dist/src/modules/domain/environment/runtime-semantics.module.d.ts.map +1 -1
  269. package/dist/src/modules/domain/module.types.d.ts.map +1 -1
  270. package/dist/src/services/application/__tests__/app-bootstrap.service.apps-manager-reconnect.test.d.ts.map +1 -1
  271. package/dist/src/services/application/__tests__/app-bootstrap.service.degraded-env.test.d.ts.map +1 -1
  272. package/dist/src/services/application/__tests__/app-bootstrap.service.operation-timeout.test.d.ts.map +1 -1
  273. package/dist/src/services/application/__tests__/app-bootstrap.service.operation-timeout.test.js +1 -1
  274. package/dist/src/services/application/__tests__/app-bootstrap.service.operation-timeout.test.js.map +1 -1
  275. package/dist/src/services/application/__tests__/app-bootstrap.service.test.d.ts.map +1 -1
  276. package/dist/src/services/application/__tests__/app-bootstrap.service.test.js +22 -29
  277. package/dist/src/services/application/__tests__/app-bootstrap.service.test.js.map +1 -1
  278. package/dist/src/services/application/__tests__/app-bootstrap.two-phase-seeding.test.d.ts.map +1 -1
  279. package/dist/src/services/application/__tests__/app-bootstrap.two-phase-seeding.test.js +1 -1
  280. package/dist/src/services/application/__tests__/app-bootstrap.two-phase-seeding.test.js.map +1 -1
  281. package/dist/src/services/application/__tests__/app-runtime-targets.service.test.d.ts.map +1 -1
  282. package/dist/src/services/application/__tests__/app-runtime-targets.service.test.js +2 -2
  283. package/dist/src/services/application/__tests__/app-runtime-targets.service.test.js.map +1 -1
  284. package/dist/src/services/application/__tests__/application-assets-delivery.service.test.d.ts.map +1 -1
  285. package/dist/src/services/application/__tests__/application-assets-delivery.service.test.js +19 -0
  286. package/dist/src/services/application/__tests__/application-assets-delivery.service.test.js.map +1 -1
  287. package/dist/src/services/application/__tests__/application-dependency-alignment.service.test.d.ts.map +1 -1
  288. package/dist/src/services/application/__tests__/application-initialization-verification.service.test.d.ts.map +1 -1
  289. package/dist/src/services/application/__tests__/application-runtime-bootstrap.service.test.d.ts.map +1 -1
  290. package/dist/src/services/application/__tests__/apps-manager-unavailable-classification.test.d.ts.map +1 -1
  291. package/dist/src/services/application/__tests__/apps-manager-unavailable-classification.test.js.map +1 -1
  292. package/dist/src/services/application/__tests__/audit-provider-immudb-backing.test.d.ts.map +1 -1
  293. package/dist/src/services/application/__tests__/dev-orchestrator.service.test.d.ts.map +1 -1
  294. package/dist/src/services/application/__tests__/dev-schema-drift.service.test.d.ts.map +1 -1
  295. package/dist/src/services/application/__tests__/existing-app-bootstrap.service.test.d.ts.map +1 -1
  296. package/dist/src/services/application/__tests__/existing-app-bootstrap.service.test.js +0 -1
  297. package/dist/src/services/application/__tests__/existing-app-bootstrap.service.test.js.map +1 -1
  298. package/dist/src/services/application/__tests__/local-app-reinit.service.test.d.ts.map +1 -1
  299. package/dist/src/services/application/__tests__/local-app-reinit.service.test.js +8 -1
  300. package/dist/src/services/application/__tests__/local-app-reinit.service.test.js.map +1 -1
  301. package/dist/src/services/application/__tests__/local-application-initialization.guard.test.d.ts.map +1 -1
  302. package/dist/src/services/application/__tests__/local-application-initialization.service.test.d.ts.map +1 -1
  303. package/dist/src/services/application/__tests__/local-application-initialization.service.test.js +35 -0
  304. package/dist/src/services/application/__tests__/local-application-initialization.service.test.js.map +1 -1
  305. package/dist/src/services/application/__tests__/provider-package-links.service.test.d.ts +2 -0
  306. package/dist/src/services/application/__tests__/provider-package-links.service.test.d.ts.map +1 -0
  307. package/dist/src/services/application/__tests__/provider-package-links.service.test.js +156 -0
  308. package/dist/src/services/application/__tests__/provider-package-links.service.test.js.map +1 -0
  309. package/dist/src/services/application/__tests__/provider-runtime-sync.service.test.d.ts.map +1 -1
  310. package/dist/src/services/application/__tests__/provider-runtime-sync.service.test.js +28 -0
  311. package/dist/src/services/application/__tests__/provider-runtime-sync.service.test.js.map +1 -1
  312. package/dist/src/services/application/__tests__/saas-and-infra-contracts.test.d.ts.map +1 -1
  313. package/dist/src/services/application/__tests__/saas-and-infra-contracts.test.js +0 -1
  314. package/dist/src/services/application/__tests__/saas-and-infra-contracts.test.js.map +1 -1
  315. package/dist/src/services/application/__tests__/saas-scaffold.service.test.d.ts.map +1 -1
  316. package/dist/src/services/application/__tests__/saas-skeleton.service.test.d.ts.map +1 -1
  317. package/dist/src/services/application/__tests__/saas-skeleton.service.test.js.map +1 -1
  318. package/dist/src/services/application/app-bootstrap.service.d.ts +34 -10
  319. package/dist/src/services/application/app-bootstrap.service.d.ts.map +1 -1
  320. package/dist/src/services/application/app-bootstrap.service.js +62 -48
  321. package/dist/src/services/application/app-bootstrap.service.js.map +1 -1
  322. package/dist/src/services/application/app-env.service.d.ts.map +1 -1
  323. package/dist/src/services/application/app-local-runtime-addresses.service.d.ts.map +1 -1
  324. package/dist/src/services/application/app-runtime-targets.service.d.ts.map +1 -1
  325. package/dist/src/services/application/app-schema-bootstrap.service.d.ts.map +1 -1
  326. package/dist/src/services/application/application-assets-delivery.service.d.ts +22 -1
  327. package/dist/src/services/application/application-assets-delivery.service.d.ts.map +1 -1
  328. package/dist/src/services/application/application-assets-delivery.service.js +35 -7
  329. package/dist/src/services/application/application-assets-delivery.service.js.map +1 -1
  330. package/dist/src/services/application/application-dependency-alignment.service.d.ts.map +1 -1
  331. package/dist/src/services/application/application-dev-port-offsets.d.ts.map +1 -1
  332. package/dist/src/services/application/application-initialization-verification.service.d.ts.map +1 -1
  333. package/dist/src/services/application/application-root.utils.d.ts.map +1 -1
  334. package/dist/src/services/application/application-runtime-bootstrap.service.d.ts.map +1 -1
  335. package/dist/src/services/application/application-runtime-bootstrap.service.js +0 -2
  336. package/dist/src/services/application/application-runtime-bootstrap.service.js.map +1 -1
  337. package/dist/src/services/application/dev-orchestrator.service.d.ts.map +1 -1
  338. package/dist/src/services/application/dev-schema-drift.service.d.ts.map +1 -1
  339. package/dist/src/services/application/existing-app-bootstrap.service.d.ts.map +1 -1
  340. package/dist/src/services/application/local-app-reinit.service.d.ts.map +1 -1
  341. package/dist/src/services/application/local-application-initialization.service.d.ts.map +1 -1
  342. package/dist/src/services/application/local-application-initialization.service.js +22 -6
  343. package/dist/src/services/application/local-application-initialization.service.js.map +1 -1
  344. package/dist/src/services/application/provider-package-links.service.d.ts +130 -0
  345. package/dist/src/services/application/provider-package-links.service.d.ts.map +1 -0
  346. package/dist/src/services/application/provider-package-links.service.js +280 -0
  347. package/dist/src/services/application/provider-package-links.service.js.map +1 -0
  348. package/dist/src/services/application/provider-runtime-sync.service.d.ts.map +1 -1
  349. package/dist/src/services/application/provider-runtime-sync.service.js +6 -20
  350. package/dist/src/services/application/provider-runtime-sync.service.js.map +1 -1
  351. package/dist/src/services/application/saas-scaffold.service.d.ts.map +1 -1
  352. package/dist/src/services/application/saas-scaffold.service.js +11 -2
  353. package/dist/src/services/application/saas-scaffold.service.js.map +1 -1
  354. package/dist/src/services/application/saas-skeleton.service.d.ts.map +1 -1
  355. package/dist/src/services/application/saas-skeleton.service.js +24 -24
  356. package/dist/src/services/application/saas-skeleton.service.js.map +1 -1
  357. package/dist/src/services/brand/__tests__/brand-asset-delivery.test.d.ts.map +1 -1
  358. package/dist/src/services/brand/brand-asset-projection.d.ts.map +1 -1
  359. package/dist/src/services/brand/brand-destination-utils.d.ts.map +1 -1
  360. package/dist/src/services/brand/brand-propagation.types.d.ts.map +1 -1
  361. package/dist/src/services/brand/brand-ssot-reader.d.ts.map +1 -1
  362. package/dist/src/services/brand/destinations/app-public.destination.d.ts.map +1 -1
  363. package/dist/src/services/brand/destinations/runtime-app-config.destination.d.ts.map +1 -1
  364. package/dist/src/services/brand/destinations/technical-doc-static.destination.d.ts.map +1 -1
  365. package/dist/src/services/brand/destinations/website-og.destination.d.ts.map +1 -1
  366. package/dist/src/services/brand/destinations/website-public.destination.d.ts.map +1 -1
  367. package/dist/src/services/catalog/__tests__/durable-state-classification.test.d.ts +2 -0
  368. package/dist/src/services/catalog/__tests__/durable-state-classification.test.d.ts.map +1 -0
  369. package/dist/src/services/catalog/__tests__/durable-state-classification.test.js +93 -0
  370. package/dist/src/services/catalog/__tests__/durable-state-classification.test.js.map +1 -0
  371. package/dist/src/services/catalog/__tests__/service-address-resolver.service.test.d.ts.map +1 -1
  372. package/dist/src/services/catalog/__tests__/service-address-resolver.service.test.js +25 -5
  373. package/dist/src/services/catalog/__tests__/service-address-resolver.service.test.js.map +1 -1
  374. package/dist/src/services/catalog/__tests__/service-catalog.schemas.test.d.ts.map +1 -1
  375. package/dist/src/services/catalog/__tests__/service-catalog.schemas.test.js +109 -51
  376. package/dist/src/services/catalog/__tests__/service-catalog.schemas.test.js.map +1 -1
  377. package/dist/src/services/catalog/service-address-resolver.service.d.ts +0 -1
  378. package/dist/src/services/catalog/service-address-resolver.service.d.ts.map +1 -1
  379. package/dist/src/services/catalog/service-address-resolver.service.js +23 -7
  380. package/dist/src/services/catalog/service-address-resolver.service.js.map +1 -1
  381. package/dist/src/services/catalog/service-catalog.schemas.d.ts +148 -51
  382. package/dist/src/services/catalog/service-catalog.schemas.d.ts.map +1 -1
  383. package/dist/src/services/catalog/service-catalog.schemas.js +230 -78
  384. package/dist/src/services/catalog/service-catalog.schemas.js.map +1 -1
  385. package/dist/src/services/coding-agents/__tests__/acp-conformance-probe.service.test.d.ts +2 -0
  386. package/dist/src/services/coding-agents/__tests__/acp-conformance-probe.service.test.d.ts.map +1 -0
  387. package/dist/src/services/coding-agents/__tests__/acp-conformance-probe.service.test.js +110 -0
  388. package/dist/src/services/coding-agents/__tests__/acp-conformance-probe.service.test.js.map +1 -0
  389. package/dist/src/services/coding-agents/acp-conformance-probe.service.d.ts +32 -0
  390. package/dist/src/services/coding-agents/acp-conformance-probe.service.d.ts.map +1 -1
  391. package/dist/src/services/coding-agents/acp-conformance-probe.service.js +165 -7
  392. package/dist/src/services/coding-agents/acp-conformance-probe.service.js.map +1 -1
  393. package/dist/src/services/companion/__tests__/companion-client.service.test.d.ts.map +1 -1
  394. package/dist/src/services/companion/__tests__/companion-client.service.test.js +96 -0
  395. package/dist/src/services/companion/__tests__/companion-client.service.test.js.map +1 -1
  396. package/dist/src/services/companion/__tests__/companion-lifecycle.service.test.d.ts.map +1 -1
  397. package/dist/src/services/companion/__tests__/workbench-browser-launcher.service.test.d.ts.map +1 -1
  398. package/dist/src/services/companion/__tests__/workbench-cli.service.test.d.ts.map +1 -1
  399. package/dist/src/services/companion/companion-client-options.utils.d.ts.map +1 -1
  400. package/dist/src/services/companion/companion-client-options.utils.js +6 -0
  401. package/dist/src/services/companion/companion-client-options.utils.js.map +1 -1
  402. package/dist/src/services/companion/companion-client.service.d.ts.map +1 -1
  403. package/dist/src/services/companion/companion-client.service.js +34 -0
  404. package/dist/src/services/companion/companion-client.service.js.map +1 -1
  405. package/dist/src/services/companion/companion-lifecycle.service.d.ts.map +1 -1
  406. package/dist/src/services/companion/companion-local-token.utils.d.ts +20 -0
  407. package/dist/src/services/companion/companion-local-token.utils.d.ts.map +1 -0
  408. package/dist/src/services/companion/companion-local-token.utils.js +62 -0
  409. package/dist/src/services/companion/companion-local-token.utils.js.map +1 -0
  410. package/dist/src/services/companion/companion.schemas.d.ts +12 -0
  411. package/dist/src/services/companion/companion.schemas.d.ts.map +1 -1
  412. package/dist/src/services/companion/companion.schemas.js.map +1 -1
  413. package/dist/src/services/companion/git-helper.service.d.ts.map +1 -1
  414. package/dist/src/services/companion/local-companion-authority.service.d.ts.map +1 -1
  415. package/dist/src/services/companion/local-companion-authority.service.js +9 -30
  416. package/dist/src/services/companion/local-companion-authority.service.js.map +1 -1
  417. package/dist/src/services/companion/workbench-browser-launcher.service.d.ts.map +1 -1
  418. package/dist/src/services/companion/workbench-cli.service.d.ts.map +1 -1
  419. package/dist/src/services/context/__tests__/context-manager.installed-assets.test.d.ts.map +1 -1
  420. package/dist/src/services/context/__tests__/context-manager.installed-assets.test.js +7 -0
  421. package/dist/src/services/context/__tests__/context-manager.installed-assets.test.js.map +1 -1
  422. package/dist/src/services/context/__tests__/context-manager.service.test.d.ts.map +1 -1
  423. package/dist/src/services/context/context-manager.service.d.ts +9 -0
  424. package/dist/src/services/context/context-manager.service.d.ts.map +1 -1
  425. package/dist/src/services/context/context-manager.service.js +13 -1
  426. package/dist/src/services/context/context-manager.service.js.map +1 -1
  427. package/dist/src/services/context/context.schemas.d.ts.map +1 -1
  428. package/dist/src/services/context/state-manager.service.d.ts.map +1 -1
  429. package/dist/src/services/credentials/__tests__/ci-secrets-mapping.test.d.ts +28 -0
  430. package/dist/src/services/credentials/__tests__/ci-secrets-mapping.test.d.ts.map +1 -0
  431. package/dist/src/services/credentials/__tests__/ci-secrets-mapping.test.js +197 -0
  432. package/dist/src/services/credentials/__tests__/ci-secrets-mapping.test.js.map +1 -0
  433. package/dist/src/services/credentials/__tests__/composed-provider-secrets.guard.test.d.ts +2 -0
  434. package/dist/src/services/credentials/__tests__/composed-provider-secrets.guard.test.d.ts.map +1 -0
  435. package/dist/src/services/credentials/__tests__/composed-provider-secrets.guard.test.js +327 -0
  436. package/dist/src/services/credentials/__tests__/composed-provider-secrets.guard.test.js.map +1 -0
  437. package/dist/src/services/credentials/__tests__/framework-managed-secrets.test.d.ts.map +1 -1
  438. package/dist/src/services/credentials/__tests__/secrets-contracts.test.d.ts.map +1 -1
  439. package/dist/src/services/credentials/ci-secrets-adapter.service.d.ts.map +1 -1
  440. package/dist/src/services/credentials/ci-secrets-adapter.service.js +98 -37
  441. package/dist/src/services/credentials/ci-secrets-adapter.service.js.map +1 -1
  442. package/dist/src/services/credentials/composed-provider-catalogue.d.ts +175 -0
  443. package/dist/src/services/credentials/composed-provider-catalogue.d.ts.map +1 -0
  444. package/dist/src/services/credentials/composed-provider-catalogue.js +228 -0
  445. package/dist/src/services/credentials/composed-provider-catalogue.js.map +1 -0
  446. package/dist/src/services/credentials/credentials.schemas.d.ts +2 -22
  447. package/dist/src/services/credentials/credentials.schemas.d.ts.map +1 -1
  448. package/dist/src/services/credentials/credentials.schemas.js +17 -5
  449. package/dist/src/services/credentials/credentials.schemas.js.map +1 -1
  450. package/dist/src/services/credentials/credentials.service.d.ts.map +1 -1
  451. package/dist/src/services/credentials/framework-managed-secrets.d.ts +105 -1
  452. package/dist/src/services/credentials/framework-managed-secrets.d.ts.map +1 -1
  453. package/dist/src/services/credentials/framework-managed-secrets.js +2 -0
  454. package/dist/src/services/credentials/framework-managed-secrets.js.map +1 -1
  455. package/dist/src/services/credentials/provider-env-vars.utils.d.ts +127 -7
  456. package/dist/src/services/credentials/provider-env-vars.utils.d.ts.map +1 -1
  457. package/dist/src/services/credentials/provider-env-vars.utils.js +189 -45
  458. package/dist/src/services/credentials/provider-env-vars.utils.js.map +1 -1
  459. package/dist/src/services/credentials/secrets-provisioning.service.d.ts.map +1 -1
  460. package/dist/src/services/credentials/secrets-reader.service.d.ts.map +1 -1
  461. package/dist/src/services/credentials/secrets-rotation.service.d.ts.map +1 -1
  462. package/dist/src/services/credentials/secrets-writer.service.d.ts.map +1 -1
  463. package/dist/src/services/data-services/data-services.schemas.d.ts +0 -1
  464. package/dist/src/services/data-services/data-services.schemas.d.ts.map +1 -1
  465. package/dist/src/services/data-services/data-services.schemas.js +0 -1
  466. package/dist/src/services/data-services/data-services.schemas.js.map +1 -1
  467. package/dist/src/services/data-services/data-services.service.d.ts.map +1 -1
  468. package/dist/src/services/deployment/__tests__/apps-manager-diagnostics.service.test.d.ts.map +1 -1
  469. package/dist/src/services/deployment/__tests__/ci-deploy-generator.service.test.d.ts.map +1 -1
  470. package/dist/src/services/deployment/__tests__/ci-deploy-generator.service.test.js +91 -1
  471. package/dist/src/services/deployment/__tests__/ci-deploy-generator.service.test.js.map +1 -1
  472. package/dist/src/services/deployment/__tests__/ci-workflow-generator.service.test.d.ts.map +1 -1
  473. package/dist/src/services/deployment/__tests__/deployment-template-contracts.test.d.ts.map +1 -1
  474. package/dist/src/services/deployment/__tests__/deployment-template-contracts.test.js +45 -15
  475. package/dist/src/services/deployment/__tests__/deployment-template-contracts.test.js.map +1 -1
  476. package/dist/src/services/deployment/__tests__/host-toolchain-readiness.service.test.d.ts.map +1 -1
  477. package/dist/src/services/deployment/__tests__/host-toolchain-readiness.service.test.js +33 -1
  478. package/dist/src/services/deployment/__tests__/host-toolchain-readiness.service.test.js.map +1 -1
  479. package/dist/src/services/deployment/__tests__/infra-templates-render-smoke.test.d.ts.map +1 -1
  480. package/dist/src/services/deployment/__tests__/local-dev-observer-lifecycle.test.d.ts.map +1 -1
  481. package/dist/src/services/deployment/__tests__/local-dev-output-boundary.test.d.ts.map +1 -1
  482. package/dist/src/services/deployment/__tests__/local-dev-session-lease.service.test.d.ts.map +1 -1
  483. package/dist/src/services/deployment/__tests__/local-dev-shutdown-coordinator.test.d.ts.map +1 -1
  484. package/dist/src/services/deployment/__tests__/local-precondition-checks.service.test.d.ts.map +1 -1
  485. package/dist/src/services/deployment/__tests__/local-precondition-checks.service.test.js +44 -1
  486. package/dist/src/services/deployment/__tests__/local-precondition-checks.service.test.js.map +1 -1
  487. package/dist/src/services/deployment/__tests__/local-runtime-process-cleanup.service.test.d.ts.map +1 -1
  488. package/dist/src/services/deployment/__tests__/parity.compose-vs-k8s.test.d.ts.map +1 -1
  489. package/dist/src/services/deployment/__tests__/parity.compose-vs-k8s.test.js +82 -87
  490. package/dist/src/services/deployment/__tests__/parity.compose-vs-k8s.test.js.map +1 -1
  491. package/dist/src/services/deployment/__tests__/platform-lifecycle.service.test.d.ts.map +1 -1
  492. package/dist/src/services/deployment/__tests__/platform-runtime-policy.service.test.d.ts.map +1 -1
  493. package/dist/src/services/deployment/apps-manager-diagnostics.service.d.ts.map +1 -1
  494. package/dist/src/services/deployment/ci-deploy-generator.service.d.ts.map +1 -1
  495. package/dist/src/services/deployment/ci-deploy-generator.service.js +11 -1
  496. package/dist/src/services/deployment/ci-deploy-generator.service.js.map +1 -1
  497. package/dist/src/services/deployment/ci-workflow-generator.service.d.ts.map +1 -1
  498. package/dist/src/services/deployment/ci-workflow-generator.service.js +23 -4
  499. package/dist/src/services/deployment/ci-workflow-generator.service.js.map +1 -1
  500. package/dist/src/services/deployment/docker/__tests__/compose-env-value-encoding.test.d.ts.map +1 -1
  501. package/dist/src/services/deployment/docker/__tests__/compose-host-mounted-artifact.test.d.ts.map +1 -1
  502. package/dist/src/services/deployment/docker/__tests__/docker-compose-generator.service.test.d.ts.map +1 -1
  503. package/dist/src/services/deployment/docker/__tests__/docker-compose-generator.service.test.js +150 -7
  504. package/dist/src/services/deployment/docker/__tests__/docker-compose-generator.service.test.js.map +1 -1
  505. package/dist/src/services/deployment/docker/__tests__/docker-compose-readiness.service.test.d.ts.map +1 -1
  506. package/dist/src/services/deployment/docker/docker-compose-generator.service.d.ts +1 -1
  507. package/dist/src/services/deployment/docker/docker-compose-generator.service.d.ts.map +1 -1
  508. package/dist/src/services/deployment/docker/docker-compose-generator.service.js +60 -12
  509. package/dist/src/services/deployment/docker/docker-compose-generator.service.js.map +1 -1
  510. package/dist/src/services/deployment/docker/docker-compose-readiness.service.d.ts.map +1 -1
  511. package/dist/src/services/deployment/docker/docker.schemas.d.ts.map +1 -1
  512. package/dist/src/services/deployment/docker/docker.service.d.ts.map +1 -1
  513. package/dist/src/services/deployment/host-toolchain-readiness.service.d.ts.map +1 -1
  514. package/dist/src/services/deployment/infra-writer.service.d.ts.map +1 -1
  515. package/dist/src/services/deployment/infra-writer.service.js +11 -3
  516. package/dist/src/services/deployment/infra-writer.service.js.map +1 -1
  517. package/dist/src/services/deployment/k8s/__tests__/k8s-bootstrap.service.test.d.ts.map +1 -1
  518. package/dist/src/services/deployment/k8s/__tests__/k8s-manifest-generator.service.test.d.ts.map +1 -1
  519. package/dist/src/services/deployment/k8s/__tests__/k8s-manifest-generator.service.test.js +110 -9
  520. package/dist/src/services/deployment/k8s/__tests__/k8s-manifest-generator.service.test.js.map +1 -1
  521. package/dist/src/services/deployment/k8s/__tests__/k8s-operations.service.test.d.ts.map +1 -1
  522. package/dist/src/services/deployment/k8s/__tests__/k8s-runtime-env-secrets.test.d.ts +2 -0
  523. package/dist/src/services/deployment/k8s/__tests__/k8s-runtime-env-secrets.test.d.ts.map +1 -0
  524. package/dist/src/services/deployment/k8s/__tests__/k8s-runtime-env-secrets.test.js +226 -0
  525. package/dist/src/services/deployment/k8s/__tests__/k8s-runtime-env-secrets.test.js.map +1 -0
  526. package/dist/src/services/deployment/k8s/__tests__/k8s-secrets-generator.service.test.d.ts.map +1 -1
  527. package/dist/src/services/deployment/k8s/__tests__/k8s-secrets-generator.service.test.js +132 -12
  528. package/dist/src/services/deployment/k8s/__tests__/k8s-secrets-generator.service.test.js.map +1 -1
  529. package/dist/src/services/deployment/k8s/__tests__/kind.service.test.d.ts.map +1 -1
  530. package/dist/src/services/deployment/k8s/__tests__/local-k8s-application-pruning.service.test.d.ts.map +1 -1
  531. package/dist/src/services/deployment/k8s/k8s-bootstrap.service.d.ts.map +1 -1
  532. package/dist/src/services/deployment/k8s/k8s-bootstrap.service.js +3 -0
  533. package/dist/src/services/deployment/k8s/k8s-bootstrap.service.js.map +1 -1
  534. package/dist/src/services/deployment/k8s/k8s-local-infra-readiness.service.d.ts.map +1 -1
  535. package/dist/src/services/deployment/k8s/k8s-manifest-generator.service.d.ts.map +1 -1
  536. package/dist/src/services/deployment/k8s/k8s-manifest-generator.service.js +45 -9
  537. package/dist/src/services/deployment/k8s/k8s-manifest-generator.service.js.map +1 -1
  538. package/dist/src/services/deployment/k8s/k8s-manifest.schemas.d.ts +4 -3
  539. package/dist/src/services/deployment/k8s/k8s-manifest.schemas.d.ts.map +1 -1
  540. package/dist/src/services/deployment/k8s/k8s-manifest.schemas.js +0 -4
  541. package/dist/src/services/deployment/k8s/k8s-manifest.schemas.js.map +1 -1
  542. package/dist/src/services/deployment/k8s/k8s-operations.service.d.ts.map +1 -1
  543. package/dist/src/services/deployment/k8s/k8s-secrets-generator.service.d.ts +10 -1
  544. package/dist/src/services/deployment/k8s/k8s-secrets-generator.service.d.ts.map +1 -1
  545. package/dist/src/services/deployment/k8s/k8s-secrets-generator.service.js +193 -33
  546. package/dist/src/services/deployment/k8s/k8s-secrets-generator.service.js.map +1 -1
  547. package/dist/src/services/deployment/k8s/k8s.schemas.d.ts.map +1 -1
  548. package/dist/src/services/deployment/k8s/kind.service.d.ts.map +1 -1
  549. package/dist/src/services/deployment/k8s/local-k8s-application-pruning.service.d.ts.map +1 -1
  550. package/dist/src/services/deployment/local-dev-observer-lifecycle.d.ts.map +1 -1
  551. package/dist/src/services/deployment/local-dev-output-boundary.d.ts.map +1 -1
  552. package/dist/src/services/deployment/local-dev-session-lease.service.d.ts.map +1 -1
  553. package/dist/src/services/deployment/local-dev-shutdown-coordinator.d.ts.map +1 -1
  554. package/dist/src/services/deployment/local-infrastructure-initialization.service.d.ts.map +1 -1
  555. package/dist/src/services/deployment/local-precondition-checks.schemas.d.ts.map +1 -1
  556. package/dist/src/services/deployment/local-precondition-checks.service.d.ts +28 -17
  557. package/dist/src/services/deployment/local-precondition-checks.service.d.ts.map +1 -1
  558. package/dist/src/services/deployment/local-precondition-checks.service.js +83 -3
  559. package/dist/src/services/deployment/local-precondition-checks.service.js.map +1 -1
  560. package/dist/src/services/deployment/local-runtime-process-cleanup.service.d.ts.map +1 -1
  561. package/dist/src/services/deployment/platform-lifecycle.service.d.ts.map +1 -1
  562. package/dist/src/services/deployment/platform-runtime-policy.service.d.ts.map +1 -1
  563. package/dist/src/services/deployment/version-compare.utils.d.ts.map +1 -1
  564. package/dist/src/services/design-tokens/design-tokens-command.service.d.ts.map +1 -1
  565. package/dist/src/services/design-tokens/design-tokens-config.service.d.ts.map +1 -1
  566. package/dist/src/services/design-tokens/design-tokens-config.template.d.ts.map +1 -1
  567. package/dist/src/services/design-tokens/design-tokens-css-block.service.d.ts.map +1 -1
  568. package/dist/src/services/design-tokens/design-tokens-paths.service.d.ts.map +1 -1
  569. package/dist/src/services/design-tokens/design-tokens.constants.d.ts.map +1 -1
  570. package/dist/src/services/design-tokens/design-tokens.models.d.ts.map +1 -1
  571. package/dist/src/services/environment/__tests__/compose-converge-args.test.d.ts.map +1 -1
  572. package/dist/src/services/environment/__tests__/config-hydration-seam.test.d.ts.map +1 -1
  573. package/dist/src/services/environment/__tests__/env-configuration-generator.service.test.d.ts.map +1 -1
  574. package/dist/src/services/environment/__tests__/env-configuration-generator.service.test.js +36 -20
  575. package/dist/src/services/environment/__tests__/env-configuration-generator.service.test.js.map +1 -1
  576. package/dist/src/services/environment/__tests__/env-sync.service.test.d.ts.map +1 -1
  577. package/dist/src/services/environment/__tests__/env-sync.service.test.js +6 -4
  578. package/dist/src/services/environment/__tests__/env-sync.service.test.js.map +1 -1
  579. package/dist/src/services/environment/__tests__/env-vars-builder.service.test.d.ts.map +1 -1
  580. package/dist/src/services/environment/__tests__/env-vars-builder.service.test.js +89 -8
  581. package/dist/src/services/environment/__tests__/env-vars-builder.service.test.js.map +1 -1
  582. package/dist/src/services/environment/__tests__/environment-hydration.utils.test.d.ts.map +1 -1
  583. package/dist/src/services/environment/__tests__/environment-lifecycle.needs-local-mongodb.test.d.ts.map +1 -1
  584. package/dist/src/services/environment/__tests__/environment-lifecycle.needs-local-postgresql.test.d.ts.map +1 -1
  585. package/dist/src/services/environment/__tests__/environment-lifecycle.self-hosts-backing-service.test.d.ts +2 -0
  586. package/dist/src/services/environment/__tests__/environment-lifecycle.self-hosts-backing-service.test.d.ts.map +1 -0
  587. package/dist/src/services/environment/__tests__/environment-lifecycle.self-hosts-backing-service.test.js +136 -0
  588. package/dist/src/services/environment/__tests__/environment-lifecycle.self-hosts-backing-service.test.js.map +1 -0
  589. package/dist/src/services/environment/__tests__/environment-paths.service.test.d.ts.map +1 -1
  590. package/dist/src/services/environment/__tests__/environment-registry.service.test.d.ts.map +1 -1
  591. package/dist/src/services/environment/__tests__/environment-setup.non-interactive.test.d.ts.map +1 -1
  592. package/dist/src/services/environment/__tests__/environment-setup.non-interactive.test.js +23 -0
  593. package/dist/src/services/environment/__tests__/environment-setup.non-interactive.test.js.map +1 -1
  594. package/dist/src/services/environment/__tests__/platform-engine-change.utils.test.d.ts.map +1 -1
  595. package/dist/src/services/environment/__tests__/platform-image-ref.test.d.ts.map +1 -1
  596. package/dist/src/services/environment/__tests__/platform-image-ref.test.js.map +1 -1
  597. package/dist/src/services/environment/__tests__/platform-runtime-state.service.test.d.ts.map +1 -1
  598. package/dist/src/services/environment/__tests__/provider-secrets-env.service.test.d.ts.map +1 -1
  599. package/dist/src/services/environment/__tests__/runtime-bootstrap.authored-database-refresh.test.d.ts.map +1 -1
  600. package/dist/src/services/environment/authored-infra-config.utils.d.ts.map +1 -1
  601. package/dist/src/services/environment/env-configuration-generator.service.d.ts +52 -14
  602. package/dist/src/services/environment/env-configuration-generator.service.d.ts.map +1 -1
  603. package/dist/src/services/environment/env-configuration-generator.service.js +41 -38
  604. package/dist/src/services/environment/env-configuration-generator.service.js.map +1 -1
  605. package/dist/src/services/environment/env-sync.service.d.ts.map +1 -1
  606. package/dist/src/services/environment/env-sync.service.js +13 -13
  607. package/dist/src/services/environment/env-sync.service.js.map +1 -1
  608. package/dist/src/services/environment/env-vars-builder.service.d.ts +28 -0
  609. package/dist/src/services/environment/env-vars-builder.service.d.ts.map +1 -1
  610. package/dist/src/services/environment/env-vars-builder.service.js +169 -41
  611. package/dist/src/services/environment/env-vars-builder.service.js.map +1 -1
  612. package/dist/src/services/environment/environment-hydration.utils.d.ts.map +1 -1
  613. package/dist/src/services/environment/environment-lifecycle.service.d.ts +53 -1
  614. package/dist/src/services/environment/environment-lifecycle.service.d.ts.map +1 -1
  615. package/dist/src/services/environment/environment-lifecycle.service.js +65 -1
  616. package/dist/src/services/environment/environment-lifecycle.service.js.map +1 -1
  617. package/dist/src/services/environment/environment-paths.service.d.ts +2 -1
  618. package/dist/src/services/environment/environment-paths.service.d.ts.map +1 -1
  619. package/dist/src/services/environment/environment-paths.service.js +5 -3
  620. package/dist/src/services/environment/environment-paths.service.js.map +1 -1
  621. package/dist/src/services/environment/environment-registry.service.d.ts.map +1 -1
  622. package/dist/src/services/environment/environment-setup.service.d.ts.map +1 -1
  623. package/dist/src/services/environment/environment-setup.service.js +23 -9
  624. package/dist/src/services/environment/environment-setup.service.js.map +1 -1
  625. package/dist/src/services/environment/environment.schemas.d.ts.map +1 -1
  626. package/dist/src/services/environment/environment.service.d.ts +6 -1
  627. package/dist/src/services/environment/environment.service.d.ts.map +1 -1
  628. package/dist/src/services/environment/environment.service.js +2 -0
  629. package/dist/src/services/environment/environment.service.js.map +1 -1
  630. package/dist/src/services/environment/platform-engine-change.utils.d.ts.map +1 -1
  631. package/dist/src/services/environment/platform-runtime-state.service.d.ts.map +1 -1
  632. package/dist/src/services/environment/platform-runtime.schemas.d.ts.map +1 -1
  633. package/dist/src/services/environment/platform-runtime.schemas.js.map +1 -1
  634. package/dist/src/services/environment/runtime-bootstrap.service.d.ts.map +1 -1
  635. package/dist/src/services/framework/__tests__/application-rule-imports.test.d.ts +2 -0
  636. package/dist/src/services/framework/__tests__/application-rule-imports.test.d.ts.map +1 -0
  637. package/dist/src/services/framework/__tests__/application-rule-imports.test.js +58 -0
  638. package/dist/src/services/framework/__tests__/application-rule-imports.test.js.map +1 -0
  639. package/dist/src/services/framework/__tests__/engine-provider-specifications.reconciliation.test.d.ts +2 -0
  640. package/dist/src/services/framework/__tests__/engine-provider-specifications.reconciliation.test.d.ts.map +1 -0
  641. package/dist/src/services/framework/__tests__/engine-provider-specifications.reconciliation.test.js +47 -0
  642. package/dist/src/services/framework/__tests__/engine-provider-specifications.reconciliation.test.js.map +1 -0
  643. package/dist/src/services/framework/__tests__/fixtures/framework-knowledge-package-only.fixture.d.ts.map +1 -1
  644. package/dist/src/services/framework/__tests__/fixtures/framework-knowledge-package-only.fixture.js.map +1 -1
  645. package/dist/src/services/framework/__tests__/framework-development-skills-sync.installed-package.test.d.ts.map +1 -1
  646. package/dist/src/services/framework/__tests__/framework-development-skills-sync.installed-package.test.js.map +1 -1
  647. package/dist/src/services/framework/__tests__/framework-development-skills-sync.package-only.test.d.ts.map +1 -1
  648. package/dist/src/services/framework/__tests__/framework-development-skills-sync.service.test.d.ts.map +1 -1
  649. package/dist/src/services/framework/__tests__/framework-docker-publish.service.test.d.ts.map +1 -1
  650. package/dist/src/services/framework/__tests__/framework-docker-publish.service.test.js.map +1 -1
  651. package/dist/src/services/framework/__tests__/framework-knowledge-application-guidance.validator.test.d.ts.map +1 -1
  652. package/dist/src/services/framework/__tests__/framework-knowledge-audit.live.contract.test.d.ts.map +1 -1
  653. package/dist/src/services/framework/__tests__/framework-knowledge-audit.live.contract.test.js.map +1 -1
  654. package/dist/src/services/framework/__tests__/framework-knowledge-audit.service.test.d.ts.map +1 -1
  655. package/dist/src/services/framework/__tests__/framework-knowledge-audit.service.test.js +50 -0
  656. package/dist/src/services/framework/__tests__/framework-knowledge-audit.service.test.js.map +1 -1
  657. package/dist/src/services/framework/__tests__/framework-knowledge-generation.service.test.d.ts.map +1 -1
  658. package/dist/src/services/framework/__tests__/framework-knowledge-generation.service.test.js +4 -70
  659. package/dist/src/services/framework/__tests__/framework-knowledge-generation.service.test.js.map +1 -1
  660. package/dist/src/services/framework/__tests__/framework-npm-publish.service.test.d.ts.map +1 -1
  661. package/dist/src/services/framework/__tests__/framework-npm-publish.service.test.js.map +1 -1
  662. package/dist/src/services/framework/__tests__/framework-publish-manifest.service.test.d.ts.map +1 -1
  663. package/dist/src/services/framework/__tests__/framework-publish-manifest.service.test.js +78 -6
  664. package/dist/src/services/framework/__tests__/framework-publish-manifest.service.test.js.map +1 -1
  665. package/dist/src/services/framework/__tests__/framework-release.service.test.d.ts.map +1 -1
  666. package/dist/src/services/framework/__tests__/framework-release.service.test.js.map +1 -1
  667. package/dist/src/services/framework/__tests__/framework-secrets-writer.test.d.ts.map +1 -1
  668. package/dist/src/services/framework/__tests__/framework-version.service.test.d.ts.map +1 -1
  669. package/dist/src/services/framework/__tests__/framework-version.service.test.js.map +1 -1
  670. package/dist/src/services/framework/__tests__/installed-framework-assets.service.test.d.ts.map +1 -1
  671. package/dist/src/services/framework/application-rule-imports.d.ts +36 -0
  672. package/dist/src/services/framework/application-rule-imports.d.ts.map +1 -0
  673. package/dist/src/services/framework/application-rule-imports.js +77 -0
  674. package/dist/src/services/framework/application-rule-imports.js.map +1 -0
  675. package/dist/src/services/framework/framework-development-skills-sync.service.d.ts +23 -0
  676. package/dist/src/services/framework/framework-development-skills-sync.service.d.ts.map +1 -1
  677. package/dist/src/services/framework/framework-development-skills-sync.service.js +51 -0
  678. package/dist/src/services/framework/framework-development-skills-sync.service.js.map +1 -1
  679. package/dist/src/services/framework/framework-docker-publish.service.d.ts.map +1 -1
  680. package/dist/src/services/framework/framework-docker-publish.service.js.map +1 -1
  681. package/dist/src/services/framework/framework-knowledge-application-guidance.validator.d.ts.map +1 -1
  682. package/dist/src/services/framework/framework-knowledge-audit.service.d.ts +45 -0
  683. package/dist/src/services/framework/framework-knowledge-audit.service.d.ts.map +1 -1
  684. package/dist/src/services/framework/framework-knowledge-audit.service.js +122 -1
  685. package/dist/src/services/framework/framework-knowledge-audit.service.js.map +1 -1
  686. package/dist/src/services/framework/framework-knowledge-generation.service.d.ts +0 -1
  687. package/dist/src/services/framework/framework-knowledge-generation.service.d.ts.map +1 -1
  688. package/dist/src/services/framework/framework-knowledge-generation.service.js +29 -215
  689. package/dist/src/services/framework/framework-knowledge-generation.service.js.map +1 -1
  690. package/dist/src/services/framework/framework-knowledge-scan.constants.d.ts.map +1 -1
  691. package/dist/src/services/framework/framework-npm-publish.service.d.ts.map +1 -1
  692. package/dist/src/services/framework/framework-npm-publish.service.js +7 -3
  693. package/dist/src/services/framework/framework-npm-publish.service.js.map +1 -1
  694. package/dist/src/services/framework/framework-publish-manifest.service.d.ts +44 -1
  695. package/dist/src/services/framework/framework-publish-manifest.service.d.ts.map +1 -1
  696. package/dist/src/services/framework/framework-publish-manifest.service.js +79 -4
  697. package/dist/src/services/framework/framework-publish-manifest.service.js.map +1 -1
  698. package/dist/src/services/framework/framework-release.service.d.ts.map +1 -1
  699. package/dist/src/services/framework/framework-version.service.d.ts +13 -0
  700. package/dist/src/services/framework/framework-version.service.d.ts.map +1 -1
  701. package/dist/src/services/framework/framework-version.service.js +23 -24
  702. package/dist/src/services/framework/framework-version.service.js.map +1 -1
  703. package/dist/src/services/framework/installed-framework-assets.service.d.ts.map +1 -1
  704. package/dist/src/services/framework/provider-transposition/__tests__/client-and-schema-agree.test.d.ts +2 -0
  705. package/dist/src/services/framework/provider-transposition/__tests__/client-and-schema-agree.test.d.ts.map +1 -0
  706. package/dist/src/services/framework/provider-transposition/__tests__/client-and-schema-agree.test.js +92 -0
  707. package/dist/src/services/framework/provider-transposition/__tests__/client-and-schema-agree.test.js.map +1 -0
  708. package/dist/src/services/framework/provider-transposition/__tests__/decision-projection.test.d.ts +2 -0
  709. package/dist/src/services/framework/provider-transposition/__tests__/decision-projection.test.d.ts.map +1 -0
  710. package/dist/src/services/framework/provider-transposition/__tests__/decision-projection.test.js +83 -0
  711. package/dist/src/services/framework/provider-transposition/__tests__/decision-projection.test.js.map +1 -0
  712. package/dist/src/services/framework/provider-transposition/__tests__/plan-matches-emit.test.d.ts +2 -0
  713. package/dist/src/services/framework/provider-transposition/__tests__/plan-matches-emit.test.d.ts.map +1 -0
  714. package/dist/src/services/framework/provider-transposition/__tests__/plan-matches-emit.test.js +166 -0
  715. package/dist/src/services/framework/provider-transposition/__tests__/plan-matches-emit.test.js.map +1 -0
  716. package/dist/src/services/framework/provider-transposition/__tests__/provider-catalogue-record.test.d.ts +2 -0
  717. package/dist/src/services/framework/provider-transposition/__tests__/provider-catalogue-record.test.d.ts.map +1 -0
  718. package/dist/src/services/framework/provider-transposition/__tests__/provider-catalogue-record.test.js +372 -0
  719. package/dist/src/services/framework/provider-transposition/__tests__/provider-catalogue-record.test.js.map +1 -0
  720. package/dist/src/services/framework/provider-transposition/__tests__/transposition-contract.test.d.ts +2 -0
  721. package/dist/src/services/framework/provider-transposition/__tests__/transposition-contract.test.d.ts.map +1 -0
  722. package/dist/src/services/framework/provider-transposition/__tests__/transposition-contract.test.js +794 -0
  723. package/dist/src/services/framework/provider-transposition/__tests__/transposition-contract.test.js.map +1 -0
  724. package/dist/src/services/framework/provider-transposition/activepieces-source.reader.d.ts +14 -0
  725. package/dist/src/services/framework/provider-transposition/activepieces-source.reader.d.ts.map +1 -0
  726. package/dist/src/services/framework/provider-transposition/activepieces-source.reader.js +1047 -0
  727. package/dist/src/services/framework/provider-transposition/activepieces-source.reader.js.map +1 -0
  728. package/dist/src/services/framework/provider-transposition/openapi-enrichment.d.ts +26 -0
  729. package/dist/src/services/framework/provider-transposition/openapi-enrichment.d.ts.map +1 -0
  730. package/dist/src/services/framework/provider-transposition/openapi-enrichment.js +57 -0
  731. package/dist/src/services/framework/provider-transposition/openapi-enrichment.js.map +1 -0
  732. package/dist/src/services/framework/provider-transposition/openapi-source.reader.d.ts +35 -0
  733. package/dist/src/services/framework/provider-transposition/openapi-source.reader.d.ts.map +1 -0
  734. package/dist/src/services/framework/provider-transposition/openapi-source.reader.js +204 -0
  735. package/dist/src/services/framework/provider-transposition/openapi-source.reader.js.map +1 -0
  736. package/dist/src/services/framework/provider-transposition/provider-catalogue-record.d.ts +410 -0
  737. package/dist/src/services/framework/provider-transposition/provider-catalogue-record.d.ts.map +1 -0
  738. package/dist/src/services/framework/provider-transposition/provider-catalogue-record.js +434 -0
  739. package/dist/src/services/framework/provider-transposition/provider-catalogue-record.js.map +1 -0
  740. package/dist/src/services/framework/provider-transposition/provider-merge.d.ts +39 -0
  741. package/dist/src/services/framework/provider-transposition/provider-merge.d.ts.map +1 -0
  742. package/dist/src/services/framework/provider-transposition/provider-merge.js +274 -0
  743. package/dist/src/services/framework/provider-transposition/provider-merge.js.map +1 -0
  744. package/dist/src/services/framework/provider-transposition/provider-package.emitter.d.ts +130 -0
  745. package/dist/src/services/framework/provider-transposition/provider-package.emitter.d.ts.map +1 -0
  746. package/dist/src/services/framework/provider-transposition/provider-package.emitter.js +1466 -0
  747. package/dist/src/services/framework/provider-transposition/provider-package.emitter.js.map +1 -0
  748. package/dist/src/services/framework/provider-transposition/sim-source.reader.d.ts +35 -0
  749. package/dist/src/services/framework/provider-transposition/sim-source.reader.d.ts.map +1 -0
  750. package/dist/src/services/framework/provider-transposition/sim-source.reader.js +527 -0
  751. package/dist/src/services/framework/provider-transposition/sim-source.reader.js.map +1 -0
  752. package/dist/src/services/framework/provider-transposition/transposed-provider.model.d.ts +229 -0
  753. package/dist/src/services/framework/provider-transposition/transposed-provider.model.d.ts.map +1 -0
  754. package/dist/src/services/framework/provider-transposition/transposed-provider.model.js +96 -0
  755. package/dist/src/services/framework/provider-transposition/transposed-provider.model.js.map +1 -0
  756. package/dist/src/services/framework/provider-transposition/url-template.extractor.d.ts +55 -0
  757. package/dist/src/services/framework/provider-transposition/url-template.extractor.d.ts.map +1 -0
  758. package/dist/src/services/framework/provider-transposition/url-template.extractor.js +196 -0
  759. package/dist/src/services/framework/provider-transposition/url-template.extractor.js.map +1 -0
  760. package/dist/src/services/frontend/__tests__/cloudflare-cdn.service.test.d.ts.map +1 -1
  761. package/dist/src/services/frontend/__tests__/frontend-dist-uploader.service.test.d.ts.map +1 -1
  762. package/dist/src/services/frontend/__tests__/frontend-publish.service.test.d.ts.map +1 -1
  763. package/dist/src/services/frontend/cloudflare-cdn.service.d.ts.map +1 -1
  764. package/dist/src/services/frontend/frontend-dist-uploader.service.d.ts.map +1 -1
  765. package/dist/src/services/frontend/frontend-publish.service.d.ts.map +1 -1
  766. package/dist/src/services/frontend/frontend-publish.service.js +1 -1
  767. package/dist/src/services/frontend/frontend-publish.service.js.map +1 -1
  768. package/dist/src/services/generation/domain-generator.service.d.ts.map +1 -1
  769. package/dist/src/services/generation/generator.schemas.d.ts.map +1 -1
  770. package/dist/src/services/generation/operation-generator.service.d.ts.map +1 -1
  771. package/dist/src/services/generation/resource-generator.service.d.ts.map +1 -1
  772. package/dist/src/services/generation/template-registry.service.d.ts.map +1 -1
  773. package/dist/src/services/registry/artifact-extractor.utils.d.ts.map +1 -1
  774. package/dist/src/services/registry/boundary-fanout.utils.d.ts.map +1 -1
  775. package/dist/src/services/registry/index.d.ts.map +1 -1
  776. package/dist/src/services/registry/registry-command.utils.d.ts.map +1 -1
  777. package/dist/src/services/registry/registry-config-resolver.service.d.ts.map +1 -1
  778. package/dist/src/services/registry/registry-credentials.service.d.ts.map +1 -1
  779. package/dist/src/services/registry/saas-root-required.error.d.ts.map +1 -1
  780. package/dist/src/services/security/__tests__/csp-artifact-currency.live.contract.test.d.ts +67 -0
  781. package/dist/src/services/security/__tests__/csp-artifact-currency.live.contract.test.d.ts.map +1 -0
  782. package/dist/src/services/security/__tests__/csp-artifact-currency.live.contract.test.js +212 -0
  783. package/dist/src/services/security/__tests__/csp-artifact-currency.live.contract.test.js.map +1 -0
  784. package/dist/src/services/security/__tests__/csp-boundary.test.d.ts.map +1 -1
  785. package/dist/src/services/security/__tests__/csp-sync.service.test.d.ts.map +1 -1
  786. package/dist/src/services/security/__tests__/csp-sync.service.test.js +411 -5
  787. package/dist/src/services/security/__tests__/csp-sync.service.test.js.map +1 -1
  788. package/dist/src/services/security/csp-sync.service.d.ts +27 -5
  789. package/dist/src/services/security/csp-sync.service.d.ts.map +1 -1
  790. package/dist/src/services/security/csp-sync.service.js +204 -16
  791. package/dist/src/services/security/csp-sync.service.js.map +1 -1
  792. package/dist/src/services/tools/utility-tools.service.d.ts.map +1 -1
  793. package/dist/src/services/website/__tests__/website-structured-data-audit.adapter-seam.test.d.ts +2 -0
  794. package/dist/src/services/website/__tests__/website-structured-data-audit.adapter-seam.test.d.ts.map +1 -0
  795. package/dist/src/services/website/__tests__/website-structured-data-audit.adapter-seam.test.js +94 -0
  796. package/dist/src/services/website/__tests__/website-structured-data-audit.adapter-seam.test.js.map +1 -0
  797. package/dist/src/services/website/website-structured-data-audit.service.d.ts +9 -0
  798. package/dist/src/services/website/website-structured-data-audit.service.d.ts.map +1 -1
  799. package/dist/src/services/website/website-structured-data-audit.service.js +72 -11
  800. package/dist/src/services/website/website-structured-data-audit.service.js.map +1 -1
  801. package/dist/src/test-utils/resolved-homes.test.utils.d.ts.map +1 -1
  802. package/dist/tsconfig.build.tsbuildinfo +1 -1
  803. package/dist/tsconfig.tsbuildinfo +1 -1
  804. package/framework-root-package.json +2 -0
  805. package/package.json +19 -17
  806. package/scripts/app-dependency-alignment/propagated-engine-overrides.json +2 -0
  807. package/templates/infra/ci/deploy-docker-compose.yml.hbs +1 -1
  808. package/templates/infra/ci/deploy-k8s.yml.hbs +1 -1
  809. package/templates/infra/docker-compose/docker-compose.wildo-platform.yml.hbs +330 -74
  810. package/templates/infra/docker-images/backend/Dockerfile.backend-base +7 -1
  811. package/templates/infra/docker-images/backend/Dockerfile.backend-base-java +7 -1
  812. package/templates/infra/docker-images/platform/Dockerfile.platform-base.dockerignore +23 -0
  813. package/templates/infra/k8s/applications/wildo-ai-application/backend.deployment.yaml.hbs +8 -5
  814. package/templates/infra/k8s/applications/wildo-ai-application/ingress.yaml.hbs +3 -2
  815. package/templates/infra/k8s/applications/wildo-ai-application/minion.deployment.yaml.hbs +22 -6
  816. package/templates/infra/k8s/applications/wildo-ai-application/worker.deployment.yaml.hbs +17 -13
  817. package/templates/infra/k8s/platform/platform-crontabs-batches-manager/deployment.yaml.hbs +11 -0
  818. package/templates/infra/k8s/storage/local/persistent-volumes.yaml.hbs +18 -4
  819. package/templates/saas/i18n/email/components/EmailHeader.tsx +9 -0
  820. package/templates/saas/i18n/email/components/EmailLayout.tsx +14 -0
  821. package/templates/saas/i18n/email/resources/applicationApiKeys/create.application-administrator/template.tsx +1 -1
  822. package/templates/saas/i18n/email/resources/applicationApiKeys/deactivate.application-administrator/template.tsx +1 -1
  823. package/templates/saas/i18n/email/resources/applicationApiKeys/reactivate.application-administrator/template.tsx +1 -1
  824. package/templates/saas/i18n/email/resources/applicationApiKeys/regenerate.application-administrator/template.tsx +1 -1
  825. package/templates/saas/i18n/email/resources/applicationApiKeys/rotate.application-administrator/template.tsx +1 -1
  826. package/templates/saas/i18n/email/resources/applicationOAuthClients/create.application-administrator/template.tsx +1 -1
  827. package/templates/saas/i18n/email/resources/applicationOAuthClients/regenerate.application-administrator/template.tsx +1 -1
  828. package/templates/saas/i18n/email/resources/applicationOAuthClients/rotate.application-administrator/template.tsx +1 -1
  829. package/templates/saas/i18n/email/resources/applicationVersions/create.organization-administrative/template.tsx +1 -1
  830. package/templates/saas/i18n/email/resources/applicationVersions/delete.organization-administrative/template.tsx +1 -1
  831. package/templates/saas/i18n/email/resources/applicationVersions/deprecate.organization-administrative/template.tsx +1 -1
  832. package/templates/saas/i18n/email/resources/applicationVersions/promote.organization-administrative/template.tsx +1 -1
  833. package/templates/saas/i18n/email/resources/applicationVersions/rollback.organization-administrative/template.tsx +1 -1
  834. package/templates/saas/i18n/email/resources/applications/create.admin.organization-administrative/template.tsx +1 -1
  835. package/templates/saas/i18n/email/resources/applications/create.organization-administrative/template.tsx +1 -1
  836. package/templates/saas/i18n/email/resources/applications/delete.admin.organization-administrative/template.tsx +1 -1
  837. package/templates/saas/i18n/email/resources/applications/delete.organization-administrative/template.tsx +1 -1
  838. package/templates/saas/i18n/email/resources/applications/transfer.admin.organization-administrative/template.tsx +1 -1
  839. package/templates/saas/i18n/email/resources/applications/transfer.organization-administrative/template.tsx +1 -1
  840. package/templates/saas/i18n/email/resources/applications/update.admin.organization-administrative/template.tsx +1 -1
  841. package/templates/saas/i18n/email/resources/applications/update.organization-administrative/template.tsx +1 -1
  842. package/templates/saas/i18n/email/resources/organizationApiKeys/create.admin.organization-administrative/template.tsx +1 -1
  843. package/templates/saas/i18n/email/resources/organizationApiKeys/create.organization-administrative/template.tsx +1 -1
  844. package/templates/saas/i18n/email/resources/organizationApiKeys/deactivate.admin.organization-administrative/template.tsx +1 -1
  845. package/templates/saas/i18n/email/resources/organizationApiKeys/deactivate.organization-administrative/template.tsx +1 -1
  846. package/templates/saas/i18n/email/resources/organizationApiKeys/delete.admin.organization-administrative/template.tsx +1 -1
  847. package/templates/saas/i18n/email/resources/organizationApiKeys/delete.organization-administrative/template.tsx +1 -1
  848. package/templates/saas/i18n/email/resources/organizationApiKeys/reactivate.admin.organization-administrative/template.tsx +1 -1
  849. package/templates/saas/i18n/email/resources/organizationApiKeys/reactivate.organization-administrative/template.tsx +1 -1
  850. package/templates/saas/i18n/email/resources/organizationApiKeys/regenerate.admin.organization-administrative/template.tsx +1 -1
  851. package/templates/saas/i18n/email/resources/organizationApiKeys/regenerate.organization-administrative/template.tsx +1 -1
  852. package/templates/saas/i18n/email/resources/organizationApiKeys/rotate.admin.organization-administrative/template.tsx +1 -1
  853. package/templates/saas/i18n/email/resources/organizationApiKeys/rotate.organization-administrative/template.tsx +1 -1
  854. package/templates/saas/i18n/email/resources/organizationFeatures/disable_feature.organization-users/template.tsx +1 -1
  855. package/templates/saas/i18n/email/resources/organizationFeatures/enable_feature.organization-users/template.tsx +1 -1
  856. package/templates/saas/i18n/email/resources/organizationFeatures/reset_features.organization-administrative/template.tsx +1 -1
  857. package/templates/saas/i18n/email/resources/organizationFeatures/update.organization-users/template.tsx +1 -1
  858. package/templates/saas/i18n/email/resources/organizationMembers/create.user-self/template.tsx +1 -1
  859. package/templates/saas/i18n/email/resources/organizationMembers/delete.organization-users/template.tsx +1 -1
  860. package/templates/saas/i18n/email/resources/organizationMembers/grantOwnership.organization-users/template.tsx +1 -1
  861. package/templates/saas/i18n/email/resources/organizationMembers/reactivate.organization-users/template.tsx +1 -1
  862. package/templates/saas/i18n/email/resources/organizationMembers/reactivate.user-self/template.tsx +1 -1
  863. package/templates/saas/i18n/email/resources/organizationMembers/resend.user-self/template.tsx +1 -1
  864. package/templates/saas/i18n/email/resources/organizationMembers/revoke.user-self_admin/template.tsx +1 -1
  865. package/templates/saas/i18n/email/resources/organizationMembers/revoke.user-self_invitee/template.tsx +1 -1
  866. package/templates/saas/i18n/email/resources/organizationMembers/suspend.organization-users/template.tsx +1 -1
  867. package/templates/saas/i18n/email/resources/organizationMembers/suspend.user-self/template.tsx +1 -1
  868. package/templates/saas/i18n/email/resources/organizationMembers/update.organization-users/template.tsx +1 -1
  869. package/templates/saas/i18n/email/resources/organizationOAuthClients/create.admin.organization-administrative/template.tsx +1 -1
  870. package/templates/saas/i18n/email/resources/organizationOAuthClients/create.organization-administrative/template.tsx +1 -1
  871. package/templates/saas/i18n/email/resources/organizationOAuthClients/delete.admin.organization-administrative/template.tsx +1 -1
  872. package/templates/saas/i18n/email/resources/organizationOAuthClients/delete.organization-administrative/template.tsx +1 -1
  873. package/templates/saas/i18n/email/resources/organizationOAuthClients/regenerate.admin.organization-administrative/template.tsx +1 -1
  874. package/templates/saas/i18n/email/resources/organizationOAuthClients/regenerate.organization-administrative/template.tsx +1 -1
  875. package/templates/saas/i18n/email/resources/organizationOAuthClients/rotate.admin.organization-administrative/template.tsx +1 -1
  876. package/templates/saas/i18n/email/resources/organizationOAuthClients/rotate.organization-administrative/template.tsx +1 -1
  877. package/templates/saas/i18n/email/resources/organizationUnits/archive.organization-administrative/template.tsx +1 -1
  878. package/templates/saas/i18n/email/resources/organizationUnits/create.organization-administrative/template.tsx +1 -1
  879. package/templates/saas/i18n/email/resources/organizationUnits/delete.organization-administrative/template.tsx +1 -1
  880. package/templates/saas/i18n/email/resources/organizationUnits/move.organization-administrative/template.tsx +1 -1
  881. package/templates/saas/i18n/email/resources/organizationUnits/restore.organization-administrative/template.tsx +1 -1
  882. package/templates/saas/i18n/email/resources/organizationUnits/update.organization-administrative/template.tsx +1 -1
  883. package/templates/saas/i18n/email/resources/organizations/activate.organization-administrative/template.tsx +1 -1
  884. package/templates/saas/i18n/email/resources/organizations/create.admin.user-self/template.tsx +1 -1
  885. package/templates/saas/i18n/email/resources/organizations/create.user-self/template.tsx +1 -1
  886. package/templates/saas/i18n/email/resources/organizations/request_deletion.admin.organization-users/template.tsx +1 -1
  887. package/templates/saas/i18n/email/resources/organizations/request_deletion.organization-users/template.tsx +1 -1
  888. package/templates/saas/i18n/email/resources/organizations/restore.organization-users/template.tsx +1 -1
  889. package/templates/saas/i18n/email/resources/organizations/suspend.organization-users/template.tsx +1 -1
  890. package/templates/saas/i18n/email/resources/organizations/update.admin.organization-administrative/template.tsx +1 -1
  891. package/templates/saas/i18n/email/resources/organizations/update.organization-administrative/template.tsx +1 -1
  892. package/templates/saas/i18n/email/resources/platformAccessGrants/requestAccess.organization-users/template.tsx +1 -1
  893. package/templates/saas/i18n/email/resources/user_self/deactivate_account.user-self/template.tsx +1 -1
  894. package/templates/saas/i18n/email/resources/user_self/reactivate_account.user-self/template.tsx +1 -1
  895. package/templates/saas/i18n/email/resources/users/assign_roles.application-administrator/template.tsx +1 -1
  896. package/templates/saas/i18n/email/resources/users/create.application-administrator/template.tsx +1 -1
  897. package/templates/saas/i18n/email/resources/users/delete.application-administrator/template.tsx +1 -1
  898. package/templates/saas/i18n/email/resources/users/force_password_reset.application-administrator/template.tsx +1 -1
  899. package/templates/saas/i18n/email/resources/users/revoke_roles.application-administrator/template.tsx +1 -1
  900. package/templates/saas/i18n/email/resources/users/send_invitation.application-administrator/template.tsx +1 -1
  901. package/templates/saas/i18n/email/resources/users/suspend_user.application-administrator/template.tsx +1 -1
  902. package/templates/saas/i18n/email/resources/users/unsuspend_user.application-administrator/template.tsx +1 -1
  903. package/templates/saas/i18n/email/resources/users/update.application-administrator/template.tsx +1 -1
  904. package/templates/saas/i18n/email/system/email-otp/template.tsx +1 -0
  905. package/templates/saas/i18n/email/system/email-verification/template.tsx +1 -1
  906. package/templates/saas/i18n/email/system/magic-link/template.tsx +1 -1
  907. package/templates/saas/i18n/email/system/new-device-login/template.tsx +1 -1
  908. package/templates/saas/i18n/email/system/organization-invitation/template.tsx +1 -0
  909. package/templates/saas/i18n/email/system/organization-member-removed/template.tsx +1 -0
  910. package/templates/saas/i18n/email/system/password-reset/template.tsx +1 -1
  911. package/templates/saas/i18n/email/system/payment-failed/template.tsx +1 -1
  912. package/templates/saas/i18n/email/system/security-alert/template.tsx +1 -0
  913. package/templates/saas/i18n/email/system/subscription-cancelled/template.tsx +1 -1
  914. package/templates/saas/i18n/email/system/subscription-confirmation/template.tsx +1 -0
  915. package/templates/saas/i18n/email/system/welcome-email/template.tsx +1 -1
  916. package/templates/saas/scenarios/add-backend-provider/scenario.json +2 -2
  917. package/templates/saas/scenarios/add-file-picker-provider/files/frontend/src/engine/providers/__providerRef__.frontend-app.module.ts.hbs +10 -4
  918. package/templates/saas/scenarios/add-minion/files/minions/__minionDir__/src/index.ts.hbs +9 -5
  919. package/templates/saas/scenarios/add-module/scenario.json +3 -3
  920. package/templates/saas/scenarios/add-provider/scenario.json +36 -0
  921. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/docusaurus.config.ts.hbs +18 -2
  922. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/src/csp.config.ts +20 -3
  923. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/src/pages/auth/exchange.tsx +52 -0
  924. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/src/pages/search.tsx.hbs +47 -3
  925. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/src/theme/Root.tsx +26 -4
  926. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/static/img/favicon.svg +5 -4
  927. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/static/img/logo.svg +11 -5
  928. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/wildo.tech-doc.config.ts.hbs +18 -7
  929. package/templates/saas/scenarios/add-website/files/website/src/app-origin.ts.hbs +32 -16
  930. package/templates/saas/scenarios/add-website/files/website/src/components/HeaderComponent.tsx +2 -2
  931. package/templates/saas/scenarios/add-website/files/website/src/pages/index.astro +1 -0
  932. package/templates/saas/scenarios/add-website/files/website/src/sections/landing.sections.tsx +2 -2
  933. package/templates/saas/scenarios/add-worker-node/files/workers/__workerDir__/src/index.ts.hbs +9 -5
  934. package/templates/saas/skeleton/.wildo-saas/dev-framework-scripts/sync-engine.sh +46 -14
  935. package/templates/saas/skeleton/CLAUDE.md.hbs +12 -0
  936. package/templates/saas/skeleton/backend-api/src/index.ts +16 -0
  937. package/templates/saas/skeleton/frontend/src/config/settings-hub.config.ts +11 -5
  938. package/templates/saas/skeleton/frontend/src/engine/app-level-views/app-level-views.definitions.module.frontend.ts +1 -1
  939. package/templates/saas/skeleton/frontend/src/generated/csp.generated.json.hbs +17 -0
  940. package/templates/saas/skeleton/infrastructure/local/wildo.infra.local.config.ts.hbs +19 -0
  941. package/templates/saas/skeleton/wildo.saas.config.ts.init.hbs +59 -2
  942. package/wildo-framework.info.json +1 -1
  943. package/templates/infra/k8s/internal/gotenberg/deployment.yaml.hbs +0 -46
  944. package/templates/infra/k8s/internal/gotenberg/service.yaml.hbs +0 -19
  945. package/templates/infra/k8s/middleware.yaml.hbs +0 -101
  946. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/static/img/favicon.png +0 -0
  947. package/templates/saas/scenarios/add-technical-doc/files/technical-doc/static/img/logo.png +0 -0
@@ -0,0 +1,1466 @@
1
+ import { existsSync, mkdirSync, readdirSync, rmSync, writeFileSync } from 'node:fs';
2
+ import { join } from 'node:path';
3
+ import { engineBackendProviderContributions } from '@wildo-ai/external-connectors-private/companion';
4
+ import { ProviderTier } from '@wildo-ai/saas-models';
5
+ import { ExternalProvider_Connection_DelegationMode, ExternalProvider_Connection_OwnerScope, } from '@wildo-ai/external-connectors-models';
6
+ import { applyRecord, ledgerRefs, readDecisionRefs, readDecisions, readLedger, withdrawVendor, writeLedger, } from './provider-catalogue-record.js';
7
+ import { TransposedAuthKind, TransposedInputKind, TransposedOperationResolution, TransposedParameterLocation, } from './transposed-provider.model.js';
8
+ /**
9
+ * Why an otherwise-resolved operation was not emitted.
10
+ *
11
+ * A closed vocabulary rather than a sentence, because the ACCEPTANCE of a refusal is stored as a
12
+ * per-vendor shrink-only baseline keyed by this code — the shape `spec-citations.baseline.json` and
13
+ * `check:invented-display-text` already use — so that a NEW refusal stands out against an
14
+ * understood one. The list of refused ids is deliberately NOT stored: the guard re-derives it every
15
+ * run, and a stored copy would rot the first time a hole is named.
16
+ */
17
+ export var EmitRefusalReason;
18
+ (function (EmitRefusalReason) {
19
+ /** No path template at all, or `/` — there is no endpoint to call. */
20
+ EmitRefusalReason["NO_PATH_TEMPLATE"] = "NO_PATH_TEMPLATE";
21
+ /** A `{hole}` in the path that the operation's own parameters never declare. */
22
+ EmitRefusalReason["UNDECLARED_PATH_HOLE"] = "UNDECLARED_PATH_HOLE";
23
+ /**
24
+ * A PATH parameter no input field feeds. Dominated by positionally-named holes (`{param1}`,
25
+ * `{param2}`) where the source's URL expression was too complex to name, and `declareWhatTheWireNeeds`
26
+ * declines to invent a name because an input called `param1` is a sentence no caller can act on.
27
+ */
28
+ EmitRefusalReason["UNFED_PATH_PARAMETER"] = "UNFED_PATH_PARAMETER";
29
+ /**
30
+ * A path template that is not a PATH — it carries whitespace, so it is a query language the source
31
+ * expressed as a URL rather than an endpoint.
32
+ *
33
+ * Measured 2026-09-09 across 4,328 emitted operations: THREE, all Salesforce, all SOQL —
34
+ * `/SELECT FIELDS(ALL) FROM {object} WHERE {field} = '…' LIMIT 200`. Salesforce takes SOQL in a
35
+ * QUERY PARAMETER (`/services/data/vXX.0/query?q=…`), never in the path, so each of the three
36
+ * would have requested a nonsense URL. They shipped as callable and typechecked perfectly.
37
+ *
38
+ * Whitespace, and NOT the quotes or parentheses a first pass reached for. Eleven operations carry
39
+ * one of those and eight are correct: OData addresses a resource as
40
+ * `/workbook/worksheets('{sheetName}')/range(address='{address}')`, where both are legal inside a
41
+ * path segment. A space is not legal unencoded, so it is the one character that separates a
42
+ * malformed path from an unusual one.
43
+ */
44
+ EmitRefusalReason["PATH_TEMPLATE_IS_NOT_A_PATH"] = "PATH_TEMPLATE_IS_NOT_A_PATH";
45
+ })(EmitRefusalReason || (EmitRefusalReason = {}));
46
+ const PACKAGE_NAME = '@wildo-ai/providers';
47
+ /**
48
+ * Where a HUMAN supplements a generated vendor.
49
+ *
50
+ * `providers/src/_authored/<ref>.authored.ts`. It lives INSIDE `src/` because the package compiles
51
+ * with `rootDir: "./src"` and an `authored/` sibling would need a different dist layout and a
52
+ * different exports map for one file — churn in the two places a mistake is most expensive.
53
+ *
54
+ * So the replace narrows instead: the emitter removes every child of `src/` that does not begin with
55
+ * `_`, and everything it writes is a vendor directory or a root module. The underscore is the whole
56
+ * convention — hand-owned, never regenerated — which is checkable in one line rather than a growing
57
+ * list of names to remember.
58
+ *
59
+ * The file is TypeScript rather than JSON on purpose: an authored operation carries a Zod input
60
+ * schema, and it is checked against the SAME contract the generated ones satisfy, by the same
61
+ * compiler, in the same package. A JSON supplement could express neither.
62
+ */
63
+ const AUTHORED_DIRECTORY = 'src/_authored';
64
+ const AUTHORED_FILE_SUFFIX = '.authored.ts';
65
+ /** From `src/<ref>/backend.exports.ts` across to `src/_authored/`. */
66
+ const AUTHORED_IMPORT_PREFIX = '../_authored/';
67
+ /** The import specifier drops `.ts`, which the emitted module resolves through the package's own tsconfig. */
68
+ const AUTHORED_FILE_SUFFIX_IMPORT = '.authored';
69
+ /**
70
+ * Which vendors a human has supplemented.
71
+ *
72
+ * Discovered by LISTING rather than by evaluating: the emitter never loads an authored file, so a
73
+ * supplement that does not compile fails the package typecheck — where a compiler explains it — and
74
+ * not the batch, where it would take 693 unrelated vendors down with it.
75
+ */
76
+ function readAuthoredVendors(packageRoot) {
77
+ const directory = join(packageRoot, AUTHORED_DIRECTORY);
78
+ if (!existsSync(directory))
79
+ return new Set();
80
+ return new Set(readdirSync(directory)
81
+ .filter((entry) => entry.endsWith(AUTHORED_FILE_SUFFIX))
82
+ .map((entry) => entry.slice(0, -AUTHORED_FILE_SUFFIX.length)));
83
+ }
84
+ /**
85
+ * An operation whose declaration disagrees with its own path template is not emitted.
86
+ *
87
+ * The executor binds a `{token}` from a declared PATH parameter. A hole with no parameter cannot be
88
+ * bound and the call goes out with a literal `{token}` in the URL; a path with no holes at all is a
89
+ * template that lost its subject. Both are broken operations that TYPECHECK perfectly — the shape is
90
+ * right and the content disagrees with itself — which is why the check has to exist here rather than
91
+ * being left to the compiler. Measured when it was added: 18 unbound holes and 11 empty paths across
92
+ * 6,955 operations, every one of which would have failed at the vendor rather than at the batch.
93
+ *
94
+ * Refused rather than repaired: the mapper cannot know what the vendor meant by a hole nobody named.
95
+ */
96
+ /**
97
+ * A parameter the operation declares but its input does not — DECLARED, not dropped and not refused.
98
+ *
99
+ * This replaces refusing 1,334 operations, and the reconsideration is worth writing down. A parameter
100
+ * with no feeding input field is a gap in the DOCUMENTATION, not proof that the operation is
101
+ * impossible: the value is one the vendor's own URL asks for, the name comes from that URL, and the
102
+ * input schema is loose, so a caller who knows to pass it already can. Refusing the operation
103
+ * withheld a capability to punish a missing sentence.
104
+ *
105
+ * So the missing sentence is written instead. The field is named after what the compiler will look
106
+ * for (`from ?? name`), required exactly when the wire position requires it — a path cannot have a
107
+ * hole — and described as coming from the request rather than from a source that never mentioned it.
108
+ * Nothing is guessed: every name here is one the source's own URL template or query bag states.
109
+ *
110
+ * What still refuses, in `refusalReason`, is the case this cannot honestly repair: a hole named
111
+ * positionally (`param1`), where the source's expression was too complex to name. Declaring an input
112
+ * called `param1` would be a sentence no caller can act on.
113
+ */
114
+ function declareWhatTheWireNeeds(operation) {
115
+ const declared = new Set(operation.inputFields.map((field) => field.name));
116
+ const missing = [];
117
+ for (const parameter of operation.parameters) {
118
+ if (parameter.in === TransposedParameterLocation.BODY)
119
+ continue;
120
+ const feeder = parameter.from ?? parameter.name;
121
+ if (declared.has(feeder) || /^param\d+$/.test(feeder))
122
+ continue;
123
+ // A credential is resolved, never asked for — except in a PATH, where the name is a resource id
124
+ // wearing a credential's spelling and nothing but the caller can supply it.
125
+ if (parameter.in !== TransposedParameterLocation.PATH && CALLER_SUPPLIES_NO_CREDENTIAL.has(feeder))
126
+ continue;
127
+ declared.add(feeder);
128
+ missing.push({
129
+ name: feeder,
130
+ kind: parameter.in === TransposedParameterLocation.PATH ? TransposedInputKind.WIRE_SCALAR : TransposedInputKind.WIRE_SCALAR_OR_LIST,
131
+ required: parameter.in === TransposedParameterLocation.PATH,
132
+ description: `Sent as the ${parameter.in} parameter \`${parameter.name}\`.`,
133
+ });
134
+ }
135
+ return missing.length === 0 ? operation : { ...operation, inputFields: [...operation.inputFields, ...missing] };
136
+ }
137
+ function refusalReason(operation) {
138
+ const template = operation.pathTemplate ?? '';
139
+ if (template === '' || template === '/')
140
+ return EmitRefusalReason.NO_PATH_TEMPLATE;
141
+ // Before asking anything about the HOLES, ask whether this is a path at all — see the enum member.
142
+ if (/\s/.test(template))
143
+ return EmitRefusalReason.PATH_TEMPLATE_IS_NOT_A_PATH;
144
+ const pathParameters = operation.parameters.filter((parameter) => parameter.in === TransposedParameterLocation.PATH);
145
+ const declared = new Set(pathParameters.map((parameter) => parameter.name));
146
+ if (![...template.matchAll(/\{([^}]+)\}/g)].every((match) => declared.has(match[1])))
147
+ return EmitRefusalReason.UNDECLARED_PATH_HOLE;
148
+ // A PATH parameter no input field can feed makes the operation UNEXECUTABLE by anyone following its
149
+ // own types: the compiler reads `from ?? name`, finds nothing in the input, and refuses with
150
+ // INPUT_INCOMPLETE before a socket opens. Measured when this clause was added: 1,722 operations
151
+ // across 313 vendors shipped in exactly that state, every one of them typechecking perfectly.
152
+ //
153
+ // Only checked when the operation HAS an input schema. An operation that declares no input at all
154
+ // passes its input through unvalidated, which the contract permits, and there is nothing to
155
+ // disagree with.
156
+ if (operation.inputFields.length === 0)
157
+ return undefined;
158
+ const fields = new Set(operation.inputFields.map((field) => field.name));
159
+ return pathParameters.every((parameter) => fields.has(parameter.from ?? parameter.name)) ? undefined : EmitRefusalReason.UNFED_PATH_PARAMETER;
160
+ }
161
+ export function emitProvidersPackage(options) {
162
+ const sourceRoot = join(options.packageRoot, 'src');
163
+ const authoredVendors = readAuthoredVendors(options.packageRoot);
164
+ // Today's date is read ONCE, so every row a single run writes carries the same `firstEmitted` and
165
+ // a batch spanning midnight does not produce two answers to one question.
166
+ const today = new Date().toISOString().slice(0, 10);
167
+ // ── PLAN ─────────────────────────────────────────────────────────────────────────────────────
168
+ // Nothing is written and nothing is deleted until the record has reconciled. A refusal that fires
169
+ // halfway through leaves a package with vendor directories and no `companion-exports.ts` — a
170
+ // correct refusal with a broken outcome, which is worse than either alone.
171
+ const planned = [];
172
+ const refusedByVendor = new Map();
173
+ const seenRefs = new Set();
174
+ const unmatchedRecordEntries = [];
175
+ const refusalMovement = new Map();
176
+ let executable = 0;
177
+ let pending = 0;
178
+ let unreadable = 0;
179
+ for (const provider of options.providers) {
180
+ const plan = planVendor(provider);
181
+ if (plan.refusals.size > 0)
182
+ refusedByVendor.set(provider.ref, plan.refusals);
183
+ pending += plan.pendingOperations.length;
184
+ unreadable += (options.unreadableByVendor.get(provider.ref) ?? []).length;
185
+ // IDENTITY comes from the ledger, not from this run's derivation. An id an application already
186
+ // calls survives a source rename, a re-ordering and a new collision; only an operation the
187
+ // ledger has never seen gets a freshly derived id. This is the whole point of #390.
188
+ const applied = applyRecord({
189
+ provider,
190
+ operations: plan.resolved,
191
+ pending: plan.pendingOperations,
192
+ ledger: readLedger(options.packageRoot, provider.ref),
193
+ decisions: readDecisions(options.packageRoot, provider.ref),
194
+ refusals: plan.refusals,
195
+ today,
196
+ });
197
+ unmatchedRecordEntries.push(...applied.unmatched);
198
+ if (Object.keys(applied.refusalDelta).length > 0)
199
+ refusalMovement.set(provider.ref, applied.refusalDelta);
200
+ seenRefs.add(provider.ref);
201
+ executable += applied.operations.length;
202
+ // `scrape: false` withholds the SUBPATH and nothing else. The vendor is still emitted and its
203
+ // ledger still maintained, so re-enabling it cannot renumber ids an application called before it
204
+ // was withheld — which is exactly the breakage this record exists to prevent.
205
+ //
206
+ // A vendor with nothing executable is likewise not exported: a subpath that resolves to auth and
207
+ // no operations looks complete to everyone downstream and can do nothing.
208
+ const decisions = readDecisions(options.packageRoot, provider.ref);
209
+ planned.push({
210
+ provider,
211
+ resolved: applied.operations,
212
+ pendingOperations: plan.pendingOperations,
213
+ refusals: plan.refusals,
214
+ ledger: applied.ledger,
215
+ exported: vendorIsExported(provider.ref, applied.operations.length, decisions),
216
+ decisions,
217
+ });
218
+ }
219
+ reconcileRecord({
220
+ packageRoot: options.packageRoot,
221
+ seenRefs,
222
+ unmatched: unmatchedRecordEntries,
223
+ fullBatch: options.fullBatch,
224
+ today,
225
+ });
226
+ // ── WRITE ────────────────────────────────────────────────────────────────────────────────────
227
+ // A regeneration REPLACES the vendor tree. A vendor that disappears upstream must disappear here,
228
+ // and leaving its directory behind would keep a subpath exported that the package no longer
229
+ // describes — a door onto a room that was demolished.
230
+ //
231
+ // Everything EXCEPT an underscore-prefixed child: those are hand-owned and survive by convention
232
+ // (`src/_authored/`). One rule, checkable in a line, rather than a list of exceptions to remember.
233
+ mkdirSync(sourceRoot, { recursive: true });
234
+ for (const entry of readdirSync(sourceRoot)) {
235
+ if (entry.startsWith('_'))
236
+ continue;
237
+ rmSync(join(sourceRoot, entry), { recursive: true, force: true });
238
+ }
239
+ const emitted = [];
240
+ for (const entry of planned) {
241
+ writeLedger(options.packageRoot, entry.ledger);
242
+ if (!entry.exported)
243
+ continue;
244
+ emitted.push(entry.provider);
245
+ const directory = join(sourceRoot, entry.provider.ref);
246
+ mkdirSync(directory, { recursive: true });
247
+ writeFileSync(join(directory, 'operations.generated.ts'), renderOperations(entry.provider, entry.resolved), 'utf8');
248
+ writeFileSync(join(directory, 'backend.exports.ts'), renderBackendModule(entry.provider, entry.resolved, authoredVendors.has(entry.provider.ref), entry.decisions), 'utf8');
249
+ writeFileSync(join(directory, 'pending-operations.json'), `${JSON.stringify({
250
+ provider: entry.provider.ref,
251
+ pending: entry.pendingOperations,
252
+ unreadable: options.unreadableByVendor.get(entry.provider.ref) ?? [],
253
+ refusedAtEmit: Object.fromEntries(entry.refusals),
254
+ }, null, 2)}\n`, 'utf8');
255
+ }
256
+ writeFileSync(join(sourceRoot, 'companion-exports.ts'), renderCompanionExports(emitted, new Map(planned.filter((e) => e.decisions !== undefined).map((e) => [e.provider.ref, e.decisions]))), 'utf8');
257
+ writeFileSync(join(options.packageRoot, 'package.json'), renderPackageJson(emitted), 'utf8');
258
+ writeFileSync(join(options.packageRoot, 'tsconfig.build.json'), renderBuildTsconfig(), 'utf8');
259
+ writeFileSync(join(options.packageRoot, 'tsconfig.json'), renderTypecheckTsconfig(), 'utf8');
260
+ writeFileSync(join(options.packageRoot, 'NOTICE'), renderNotice(emitted), 'utf8');
261
+ return {
262
+ vendors: emitted.length,
263
+ executableOperations: executable,
264
+ pendingOperations: pending,
265
+ unreadableOperations: unreadable,
266
+ refusedByVendor,
267
+ refusalMovement,
268
+ };
269
+ }
270
+ /**
271
+ * What a vendor WOULD emit, computed once so that a dry run and a real emit cannot disagree.
272
+ *
273
+ * They did disagree, by 856 operations (~14%): the dry-run branch counted every RESOLVED operation
274
+ * while the emit branch counted RESOLVED minus the coherence guard's refusals. A dry run exists to
275
+ * predict an emit; two copies of the accounting is how a prediction stops predicting (#393).
276
+ */
277
+ function planVendor(provider) {
278
+ // The guard REFUSES rather than filtering: a refusal is recorded with its reason, so that an
279
+ // operation leaving the catalogue is a fact somebody can read afterwards. Filtering silently is
280
+ // how 856 operations left with no count anywhere (#392).
281
+ const refusals = new Map();
282
+ const resolved = [];
283
+ for (const operation of provider.operations) {
284
+ if (operation.resolution !== TransposedOperationResolution.RESOLVED)
285
+ continue;
286
+ const declared = declareWhatTheWireNeeds(operation);
287
+ const reason = refusalReason(declared);
288
+ if (reason === undefined) {
289
+ resolved.push(declared);
290
+ continue;
291
+ }
292
+ refusals.set(reason, (refusals.get(reason) ?? 0) + 1);
293
+ }
294
+ // A stable order so the committed artifact diffs as CONTENT. Neither reader sorts `readdirSync`
295
+ // and the merge preserves read order, so without this the same source yields the same operations
296
+ // in a filesystem-dependent order — a regeneration on another machine reads as a 6,000-line
297
+ // rewrite, and a diff nobody can read is a record nobody can review.
298
+ resolved.sort((left, right) => left.operationId.localeCompare(right.operationId));
299
+ return {
300
+ resolved,
301
+ refusals,
302
+ pendingOperations: provider.operations.filter((o) => o.resolution === TransposedOperationResolution.PENDING_ENDPOINT),
303
+ };
304
+ }
305
+ /** The emit's own accounting, without writing anything. `--dry-run` reports exactly this. */
306
+ /**
307
+ * The provider refs the ENGINE owns, read from the engine's own registry.
308
+ *
309
+ * A ref is an application's whole address for a provider — `providerRef: 'stripe'` in an HTTP-API
310
+ * binding, `stripe:` in a saas-config provider scope — so two contributions carrying one ref is not
311
+ * a duplicate, it is a name that means two things. The platform refuses it rather than picking:
312
+ * `wildo config sync` fails with *"discovered runtime owners disagree on its secret-contract
313
+ * shape"*, and the refusal lands on the APPLICATION, which never asked for the catalogue's copy.
314
+ * Installing this package for `slack` was enough to make an unrelated `openai` declaration
315
+ * unmaterializable.
316
+ *
317
+ * The engine's contribution wins every time, and not by seniority: it is bound to an engine
318
+ * capability, its secrets contract was AUTHORED rather than transposed from a source that had no
319
+ * opinion about it, and applications already declare it.
320
+ *
321
+ * ## Why this is DERIVED, and what it cost to learn
322
+ *
323
+ * This rule shipped on 2026-09-08 as NINE hand-written `scrape: false` decision files, one per
324
+ * colliding vendor, each carrying the sentence *"Nine of the engine's 23 providers collide this
325
+ * way."* Measured 2026-09-09 against the engine registry: **eleven** collide. `openai` and `google`
326
+ * were missed, and the count in the reason — derived by the same hand, in the same pass — recorded
327
+ * the miss as fact.
328
+ *
329
+ * Only `openai` was live: `google` is withheld anyway for having nothing executable, so its
330
+ * collision was covered by luck and would have surfaced the day the source grew it an operation.
331
+ * `openai` had no such cover, and every application that installed this package while declaring the
332
+ * engine's LLM provider — which is to say every application that wants an LLM and any integration —
333
+ * could not run `wildo config sync` at all.
334
+ *
335
+ * So the set is read from `engineBackendProviderContributions`, the same value the platform's own
336
+ * discovery uses. A list that enumerates ANOTHER party's catalogue by hand is a list that rots; the
337
+ * 24th engine provider is now withheld here on the day it is added, by nobody remembering anything.
338
+ */
339
+ const ENGINE_OWNED_PROVIDER_REFS = new Set(engineBackendProviderContributions.map((contribution) => contribution.ref));
340
+ /**
341
+ * Whether a vendor gets a SUBPATH in the emitted package.
342
+ *
343
+ * One function because the answers must agree and twice already did not. `--dry-run` exists so a
344
+ * batch can be inspected before it replaces every vendor directory in the package, which is worth
345
+ * nothing if the plan and the emit compute different things: they disagreed by 856 operations once
346
+ * (#393, one copy of the refusal accounting), and by 9 VENDORS until 2026-09-08 — the plan applied
347
+ * the "nothing executable" half and skipped the decisions half, so a dry run promised subpaths for
348
+ * exactly the nine vendors then withheld for colliding with an engine provider. That is the worst
349
+ * possible set to over-report: it tells the reader the collision is back.
350
+ *
351
+ * The three clauses:
352
+ *
353
+ * - **nothing executable** — a subpath resolving to auth and no operations looks complete to
354
+ * everyone downstream and can do nothing;
355
+ * - **the engine owns the ref** — see `ENGINE_OWNED_PROVIDER_REFS`. Derived, so it cannot be short
356
+ * by two the way the hand-written version was;
357
+ * - **`scrape: false`** — a deliberate withholding, for a reason no rule derives. It is the door
358
+ * that stays open for the next one-off.
359
+ *
360
+ * All three withhold the SUBPATH and nothing else: the vendor is still emitted and its ledger still
361
+ * maintained, so re-enabling it cannot renumber ids an application called before it was withheld,
362
+ * which is exactly the breakage the record exists to prevent.
363
+ */
364
+ export function vendorIsExported(ref, resolvedOperationCount, decisions) {
365
+ return resolvedOperationCount > 0 && !ENGINE_OWNED_PROVIDER_REFS.has(ref) && decisions?.scrape !== false;
366
+ }
367
+ export function planProvidersPackage(options) {
368
+ const refusedByVendor = new Map();
369
+ let vendors = 0;
370
+ let executable = 0;
371
+ let pending = 0;
372
+ let unreadable = 0;
373
+ for (const provider of options.providers) {
374
+ const { resolved, refusals, pendingOperations } = planVendor(provider);
375
+ if (refusals.size > 0)
376
+ refusedByVendor.set(provider.ref, refusals);
377
+ pending += pendingOperations.length;
378
+ unreadable += (options.unreadableByVendor.get(provider.ref) ?? []).length;
379
+ if (resolved.length === 0)
380
+ continue;
381
+ executable += resolved.length;
382
+ // The SAME predicate the emit applies. Counting `resolved.length > 0` alone is what made a dry
383
+ // run promise nine subpaths the emit withholds.
384
+ if (vendorIsExported(provider.ref, resolved.length, readDecisions(options.packageRoot, provider.ref)))
385
+ vendors += 1;
386
+ }
387
+ // A plan does not consult the ledger, so it cannot know what moved. Empty rather than absent: the
388
+ // shape is the emit's, and a dry run that invented a movement would be reporting on a comparison
389
+ // it never made.
390
+ return { vendors, executableOperations: executable, pendingOperations: pending, unreadableOperations: unreadable, refusedByVendor, refusalMovement: new Map() };
391
+ }
392
+ /**
393
+ * Close the record against what this run actually produced, and REFUSE anything that matched
394
+ * nothing.
395
+ *
396
+ * ## Why a refusal, and not a warning
397
+ *
398
+ * Every correction in this lane has failed the same way: a fix that silently stops applying. A
399
+ * succession for an endpoint that moved again, a decision for a vendor the source dropped — each is
400
+ * a statement about a world that has moved, and each is invisible unless the run refuses. Withdrawal
401
+ * is the explicit way to say "this is gone", precisely so that silence never means it.
402
+ *
403
+ * ## Why only on a FULL batch
404
+ *
405
+ * A partial run CANNOT SEE the entries it did not cover: `--vendor slack` leaves 696 vendors'
406
+ * records matching nothing, and one catalogue alone leaves every entry the other contributed. Making
407
+ * those fail would refuse a run for doing exactly what it was asked to do. So a partial run reports
408
+ * and writes no withdrawals, and only a full batch may conclude that something is gone.
409
+ */
410
+ function reconcileRecord(options) {
411
+ if (!options.fullBatch)
412
+ return;
413
+ /*
414
+ * A vendor the sources stop describing is WITHDRAWN, not deleted (#500).
415
+ *
416
+ * This used to `removeLedger`, which was the one path in this record where an id could be lost. An
417
+ * operation that disappears keeps its keys so a restored endpoint resurrects its id; a withheld
418
+ * vendor keeps its whole ledger so re-enabling reuses every id. A vendor that vanishes upstream for
419
+ * one release and returns had neither — every operation came back freshly derived, and every
420
+ * application calling one of its ids broke silently.
421
+ *
422
+ * `withdrawVendor` drops refusals and moves every live operation to `withdrawn`, so a vendor whose
423
+ * ledger held ONLY refusals reduces to nothing and `writeLedger` removes the file. That is right:
424
+ * there were no ids to preserve, and a file asserting three empty objects records nothing.
425
+ */
426
+ for (const ref of ledgerRefs(options.packageRoot)) {
427
+ if (options.seenRefs.has(ref))
428
+ continue;
429
+ const ledger = readLedger(options.packageRoot, ref);
430
+ if (ledger === undefined)
431
+ continue;
432
+ writeLedger(options.packageRoot, withdrawVendor(ledger, options.today, 'This batch produced no such vendor — the sources no longer describe it.'));
433
+ }
434
+ const stale = [
435
+ ...readDecisionRefs(options.packageRoot)
436
+ .filter((ref) => !options.seenRefs.has(ref))
437
+ .map((ref) => `decisions/${ref}.json names a vendor this batch did not produce`),
438
+ ...options.unmatched.map((entry) => `${entry.ref}: ${entry.detail}`),
439
+ ];
440
+ if (stale.length === 0)
441
+ return;
442
+ throw new Error(`The catalogue record contains ${stale.length} entr${stale.length === 1 ? 'y' : 'ies'} that matched nothing in this batch:\n`
443
+ + stale.map((line) => ` - ${line}`).join('\n')
444
+ + '\n\nA record entry that matches nothing is a decision that has stopped applying. Either the thing it names is genuinely gone '
445
+ + '(delete the entry, or record the withdrawal deliberately) or it moved (follow it). Silence must never mean either.');
446
+ }
447
+ const GENERATED_BANNER = `/**
448
+ * GENERATED by \`wildo fwk generate-providers\`. Do not edit by hand — a regeneration overwrites it.
449
+ *
450
+ * An edit made in this file is lost the next time the batch runs, and a fix that silently disappears
451
+ * is worse than one that was never made. Corrections have three homes instead:
452
+ * - the transposer, for a defect that spans vendors;
453
+ * - the source catalogue, for something the vendor's own entry gets wrong;
454
+ * - \`src/_authored/<ref>.authored.ts\`, for one vendor's peculiarity — an operation no source
455
+ * describes, an operation to withhold, a credential entry, a corrected runtime fact.
456
+ */`;
457
+ /**
458
+ * The subpath a vendor is imported through: `@wildo-ai/providers/slack`.
459
+ *
460
+ * The vendor's name is in the PATH, never in the package name — which is the whole point of the
461
+ * one-package shape, and the half that cannot be quietly undone once published.
462
+ */
463
+ function subpathFor(ref) {
464
+ return `./${ref}`;
465
+ }
466
+ /**
467
+ * One manifest, one published name, and an export map with one entry per vendor.
468
+ *
469
+ * `sideEffects: false` is load-bearing rather than hygiene: it tells a bundler that importing one
470
+ * vendor's subpath can never require evaluating another's, which is what keeps an application's
471
+ * bundle proportional to what it declares even though its `node_modules` holds every vendor.
472
+ *
473
+ * The version is a placeholder the publish lane sets. A generator cannot know which release a batch
474
+ * belongs to, and inventing one would put a plausible wrong version on the whole catalogue.
475
+ */
476
+ function renderPackageJson(providers) {
477
+ const exportsMap = {
478
+ // The ONE door discovery opens. `resolvePackageCompanionEntryPath` reads this subpath from the
479
+ // manifest and hands the resolved path to the loader, so no application ever writes the
480
+ // specifier — which is why it must exist even though nothing imports it by name.
481
+ './companion': {
482
+ // `companion-exports.ts`, hyphenated, because `resolvePackageCompanionEntryPath` hard-codes
483
+ // exactly that filename as its source fallback and every other contributing package uses it.
484
+ // Emitting `companion.exports.ts` resolved fine through the export map once BUILT and failed
485
+ // the moment discovery ran against source — which is how it was found: by running the real
486
+ // walk rather than by reading the manifest and believing it.
487
+ source: './src/companion-exports.ts',
488
+ types: './dist/esm/companion-exports.d.ts',
489
+ default: './dist/esm/companion-exports.js',
490
+ },
491
+ };
492
+ for (const provider of [...providers].sort((left, right) => left.ref.localeCompare(right.ref))) {
493
+ exportsMap[subpathFor(provider.ref)] = {
494
+ source: `./src/${provider.ref}/backend.exports.ts`,
495
+ types: `./dist/esm/${provider.ref}/backend.exports.d.ts`,
496
+ default: `./dist/esm/${provider.ref}/backend.exports.js`,
497
+ };
498
+ }
499
+ return `${JSON.stringify({
500
+ name: PACKAGE_NAME,
501
+ version: '0.0.0',
502
+ type: 'module',
503
+ description: `Wildo provider catalogue: ${providers.length} vendors transposed from open integration catalogues. Each vendor is a subpath export; there is no root barrel.`,
504
+ license: 'MIT',
505
+ publishConfig: { access: 'public' },
506
+ sideEffects: false,
507
+ files: ['dist', 'NOTICE'],
508
+ /*
509
+ * `watch` is what puts this package in the dev fleet, and its absence is why the catalogue's
510
+ * `dist` went silently stale.
511
+ *
512
+ * `selectWatchPackages` in the dev orchestrator filters on `pkg.scripts.watch`, so a package
513
+ * that declares only `build` is never watched — and 103 watchers were running while nothing
514
+ * rebuilt this one. Everything that reads the catalogue at RUNTIME resolves through the
515
+ * `exports` map to `dist`: discovery, `wildo config sync`, a booted backend. Measured
516
+ * 2026-09-07, `dist` sat 29 minutes behind `src` and `config sync` refused against a barrel
517
+ * that no longer existed — a wrong diagnosis until the artifact was dated.
518
+ *
519
+ * The alias finalizer runs on `--onSuccess` in both scripts, matching every engine package.
520
+ * Nothing generated here uses a `~` alias, so it rewrites nothing today; it is the step that
521
+ * marks an emitted tree PUBLISHED, and a build that skips it leaves readers looking at a dist
522
+ * nobody finished.
523
+ *
524
+ * `../scripts/` and not `../../scripts/`: this package sits one level below the repository
525
+ * root, where every engine package sits two.
526
+ */
527
+ scripts: {
528
+ // `pnpm -r typecheck` visits every workspace member that declares this script and SKIPS the
529
+ // rest, so without it nothing in CI ever compiled the catalogue — every vendor and every
530
+ // operation in it, checked by the emitter's own unit tests and by no compiler. `tsconfig.json`
531
+ // exists for exactly this: it extends the emit config with `noEmit`, so the two cannot drift
532
+ // into describing different programs.
533
+ typecheck: 'tsc -p tsconfig.json',
534
+ build: 'tsc -p tsconfig.build.json && node ../scripts/run-tsc-alias-safe.mjs --project tsconfig.build.json --dist dist/esm',
535
+ watch: 'node ../scripts/run-tsc-watch-single-writer.mjs --dist dist/esm --exec tsc-watch -- -p tsconfig.build.json --preserveWatchOutput '
536
+ + '--onSuccess "node ../scripts/run-tsc-alias-safe.mjs --project tsconfig.build.json --dist dist/esm"',
537
+ },
538
+ exports: exportsMap,
539
+ // `workspace:*` for the engine, matching every other package in this monorepo. `"*"` looked
540
+ // equivalent and is not: pnpm resolved it from the REGISTRY, so the generated catalogue
541
+ // compiled and loaded against a PUBLISHED 1.1.2 engine while the local source moved under it —
542
+ // which is how a probe for #378 died on an export that had existed locally for a day. pnpm
543
+ // rewrites `workspace:*` to the concrete version at publish time, so the published manifest is
544
+ // unaffected. `zod` stays `"*"`, which the publish lane substitutes from the root override.
545
+ dependencies: {
546
+ '@wildo-ai/saas-models': 'workspace:*',
547
+ '@wildo-ai/external-connectors-models': 'workspace:*',
548
+ '@wildo-ai/external-connectors-private': 'workspace:*',
549
+ zod: '*',
550
+ },
551
+ /**
552
+ * The COMPILER, declared for the same reason every other package in this fleet declares it —
553
+ * and its absence was not cosmetic. Measured 2026-09-09: `providers` was the ONLY workspace
554
+ * package with no `typescript` devDependency, and consequently the only one whose `tsc`
555
+ * resolved **7.0.2** instead of the fleet's 5.9.3. With nothing in its own `node_modules`,
556
+ * every invocation walked up to the repository root, where the TS7 alias installed for the
557
+ * native-compiler migration also publishes a `tsc` bin.
558
+ *
559
+ * So the largest emitter in the repository was on the native lane by accident. That lane is
560
+ * OPT-IN per package by design — `wildo-compiler-runner.mjs` asserts its exact version and
561
+ * fails closed — and this package bypassed it entirely, because its own `build` and `watch`
562
+ * scripts call `tsc` directly rather than through the runner. Its published `dist`, which
563
+ * every consumer resolves, was emitted by a compiler nobody chose for it.
564
+ *
565
+ * It also hid the defect above: TypeScript 7 does not surface `watchOptions` in
566
+ * `--showConfig`, so the missing watch exclusions read as an inheritance failure until the
567
+ * measurement was repeated naming 5.9.3 explicitly.
568
+ *
569
+ * `"*"` rather than a version: the pin is the root `pnpm.overrides` entry, exactly as for the
570
+ * rest of the fleet, so a compiler bump needs no edit here.
571
+ */
572
+ devDependencies: {
573
+ typescript: '*',
574
+ },
575
+ }, null, 2)}\n`;
576
+ }
577
+ /**
578
+ * One tsconfig for the whole catalogue, and therefore one `tsc` process.
579
+ *
580
+ * Measured on 2026-09-06, when the 684-package shape took a development machine down: a single `tsc`
581
+ * peaks at ~391 MB, almost all of it the engine's `.d.ts` closure and the TypeScript lib — a fixed
582
+ * cost per PROCESS, not per package. One process typechecking every vendor peaks at 1.23 GB in about
583
+ * a second. The package count was never what cost anything; the process count was.
584
+ *
585
+ * Self-contained on purpose: no `extends` reaching outside this package, so it builds from a checkout
586
+ * that contains only this directory.
587
+ */
588
+ /**
589
+ * The EMIT config, and the one the dev fleet compiles this package with.
590
+ *
591
+ * `tsconfig.build.json` is not a preference — it is the watcher's package contract, hard-coded in
592
+ * `dev-compile-status.mjs` (`projectPath: resolve(pkg.root, 'tsconfig.build.json')`, and again in
593
+ * `emitted-artifact-validity.mjs` and the declaration-recovery path). Emitting only `tsconfig.json`
594
+ * made the package eligible for watching and then unwatchable: the fleet spawned a watcher that died
595
+ * on `TS5058: The specified path does not exist: 'tsconfig.build.json'`, and the application's
596
+ * diagnostics reported `NOT_READY @wildo-ai/providers — COMPILE_WATCHER_EXITED`.
597
+ *
598
+ * `composite: true` matches every engine package, because the fleet's machinery is built around
599
+ * packages that have it — interrupted-declaration recovery and emitted-artifact validity both open
600
+ * this project by path.
601
+ */
602
+ function renderBuildTsconfig() {
603
+ return `${JSON.stringify({
604
+ // The repository-wide WATCH exclusions, inherited exactly as every engine package inherits them
605
+ // (through `engine/tsconfig.common.json`, which extends this same file). Added 2026-09-09.
606
+ //
607
+ // Without it this package was watched with NO `watchOptions` at all, and it is the worst one in
608
+ // the repository to watch naively: it emits 1,380 `.d.ts` files and its `.wildo-runtime-signals/`
609
+ // had grown to 23 MB. Those journals snapshot every emitted declaration on each compile cycle,
610
+ // and pnpm links make the directory reachable as
611
+ // `<consumer>/node_modules/@wildo-ai/providers/.wildo-runtime-signals/…` — so every consumer
612
+ // installs a recursive watcher over it and reschedules a recompile on each journal write. That
613
+ // is the compile storm `tsconfig.watch-exclusions.json` documents, aimed at the largest emitter
614
+ // in the tree, and it went live the moment the catalogue became fleet-watched.
615
+ //
616
+ // It must be inherited from the REPOSITORY ROOT rather than restated here: TypeScript re-roots
617
+ // path-like options against the file that DECLARED them, so a copy living in `providers/` would
618
+ // resolve its globs to `providers/**` and cover nothing else.
619
+ extends: '../tsconfig.watch-exclusions.json',
620
+ compilerOptions: {
621
+ target: 'ES2022',
622
+ module: 'ESNext',
623
+ moduleResolution: 'Bundler',
624
+ composite: true,
625
+ declaration: true,
626
+ strict: false,
627
+ skipLibCheck: true,
628
+ esModuleInterop: true,
629
+ outDir: './dist/esm',
630
+ rootDir: './src',
631
+ },
632
+ include: ['src/**/*.ts'],
633
+ exclude: ['node_modules', 'dist'],
634
+ }, null, 2)}\n`;
635
+ }
636
+ /**
637
+ * The TYPECHECK config, which emits nothing.
638
+ *
639
+ * Extends the build config so the two cannot drift into disagreeing about what compiles — the pair
640
+ * exists to separate emitting from checking, not to describe two different programs.
641
+ */
642
+ function renderTypecheckTsconfig() {
643
+ return `${JSON.stringify({
644
+ extends: './tsconfig.build.json',
645
+ compilerOptions: { composite: false, noEmit: true },
646
+ include: ['src/**/*.ts'],
647
+ }, null, 2)}\n`;
648
+ }
649
+ function renderNotice(providers) {
650
+ const sources = new Map();
651
+ for (const provider of providers) {
652
+ for (const provenance of provider.provenances) {
653
+ const revisions = sources.get(provenance.source) ?? new Set();
654
+ revisions.add(provenance.sourceVersion);
655
+ sources.set(provenance.source, revisions);
656
+ }
657
+ }
658
+ const lines = [...sources.entries()].map(([source, revisions]) => `- ${source} — revision(s) ${[...revisions].join(', ')}`);
659
+ return `${PACKAGE_NAME}
660
+
661
+ This package's provider DEFINITIONS were derived at build time from the catalogues below, covering
662
+ ${providers.length} vendors. No code from them is redistributed here and none of it executes: what
663
+ ships is a Wildo operation catalogue — method, path template, parameters and auth shape — executed by
664
+ Wildo's own HTTP client.
665
+
666
+ ${lines.join('\n')}
667
+
668
+ Activepieces pieces are MIT (Activepieces Inc). Sim is Apache-2.0. Their notices apply to the source
669
+ that was read, not to this file. Each vendor's own provenance, down to the exact artifact read, is
670
+ recorded in its generated module's metadata.
671
+ `;
672
+ }
673
+ /**
674
+ * The operation's declared input as a Zod object — the half of D4's promise the emitter used to drop.
675
+ *
676
+ * `requestBody: { encoding: JSON }` says a body exists and nothing about what is in it, which is not
677
+ * enough for anything: the executor cannot validate a call, a typed client (R3) has nothing to derive
678
+ * an argument type from, and a caller cannot discover what to pass. The sources declare it — 12,193
679
+ * `Property.ShortText`, 3,797 `Property.Number` and so on in Activepieces, a `type` string per param
680
+ * in Sim — so the schema is READ, never invented.
681
+ *
682
+ * Two decisions inside it. Optional fields stay optional rather than being given a default, because a
683
+ * default is a decision about the VENDOR's behaviour that no catalogue states. And an input whose kind
684
+ * could not be read is `z.unknown()` rather than `z.string()`: most inputs are strings, and typing an
685
+ * unknown as the common case is exactly how a schema comes to lie about the one that is not.
686
+ *
687
+ * Absent when the source declared no input at all — an operation with no fields is passed through
688
+ * unvalidated, which the contract permits and which is honest about carrying no contract.
689
+ *
690
+ * ## Every object schema is rendered `z.looseObject<z.ZodRawShape>({...})`, never bare
691
+ *
692
+ * The explicit type argument is what keeps the catalogue compilable, and it was measured rather than
693
+ * reasoned about. `ProviderRestOperationCatalogue` types every schema slot as a plain `z.ZodType`, and
694
+ * nothing anywhere derives a TypeScript type from these schemas (the typed client renders its own
695
+ * argument types from the same field set). Yet a bare `z.looseObject({ ... })` still makes the checker
696
+ * INFER the call's full generic result — a mapped input/output type over every field — once per call,
697
+ * and the catalogue makes ~7,200 such calls. On 2026-09-09 that cost the package's watcher its life:
698
+ * one compile of 689 vendors needed 3.5 GB of heap (4.0M symbols, 1.9M types, 5.8M instantiations,
699
+ * 21 s to check), an incremental rebuild holds two programs, and `tsc-watch` died with "JavaScript
700
+ * heap out of memory" at the default 4 GB limit — taking the platform watch group down with it.
701
+ *
702
+ * With the type argument supplied, inference has nothing to do: the argument is checked against the
703
+ * one shared `ZodRawShape` instantiation and the result type is the same for every call. The same
704
+ * 689 vendors then compile in 0.9 GB (0.73M symbols, 0.19M types, 0.10M instantiations, 1.5 s to
705
+ * check). The emitted RUNTIME value is byte-identical — a type argument is erased — so validation,
706
+ * OpenAPI projection and the executor see exactly the schemas they saw before.
707
+ */
708
+ function renderInputSchema(operation) {
709
+ // The SAME set the typed client renders — see `callerSuppliedInputFields`. Walking
710
+ // `operation.inputFields` raw here is what made 1,668 operations uncallable through their own
711
+ // client: the schema demanded a credential the client refuses to accept.
712
+ const fields = callerSuppliedInputFields(operation);
713
+ if (fields.length === 0)
714
+ return undefined;
715
+ const entries = fields
716
+ .map((field) => {
717
+ const base = zodFor(field.kind);
718
+ const described = field.description === undefined ? base : `${base}.describe(${quote(field.description)})`;
719
+ return ` ${quote(field.name)}: ${field.required ? described : `${described}.optional()`},`;
720
+ })
721
+ .join('\n');
722
+ // `looseObject`, deliberately: a vendor's API accepts fields no catalogue mentioned, and a strict
723
+ // schema would refuse a legitimate call for the crime of being more complete than the source.
724
+ return `z.looseObject<z.ZodRawShape>({\n${entries}\n })`;
725
+ }
726
+ /**
727
+ * A response shape as Zod, rendered recursively.
728
+ *
729
+ * Every object is LOOSE and every member keeps whatever optionality its source stated. Both are
730
+ * about the same asymmetry: a response schema exists so a caller can rely on the fields it names,
731
+ * not so Wildo can police a vendor. A vendor that adds a field must never break a call, and a
732
+ * vendor that omits one the source happened to describe must not either — the engine contract says
733
+ * as much ("authors should keep these permissive; the value is in naming the fields a caller may
734
+ * rely on"). A strict response schema turns every vendor release into an outage.
735
+ */
736
+ function renderShape(shape, indent) {
737
+ const pad = ' '.repeat(indent);
738
+ const described = (rendered) => shape.description === undefined ? rendered : `${rendered}.describe(${quote(shape.description)})`;
739
+ // EVERY member of a response is optional, whatever the source said it was required.
740
+ //
741
+ // Not a weakening — a correction, and it was found by a socket rather than reasoned about. Slack's
742
+ // `conversations.info` answers `{ ok, channel }`; the source's own output description named a
743
+ // required `channelInfo`, so the executor refused a perfectly good vendor response with
744
+ // "expected object, received undefined". A source describes what it CHOSE to surface, under its
745
+ // own names — it is not, and never was, a statement about the vendor's wire format.
746
+ //
747
+ // The engine contract asks for exactly this: "a vendor adding a field must never break a call, so
748
+ // authors should keep these permissive; the value is in naming the fields a caller may rely on,
749
+ // not in policing the vendor." Required-ness derived from a third party's summary is how a
750
+ // generated catalogue turns a working vendor into an outage.
751
+ const optional = (rendered) => (rendered.endsWith('.optional()') ? rendered : `${rendered}.optional()`);
752
+ if (shape.kind === TransposedInputKind.OBJECT && shape.fields !== undefined && Object.keys(shape.fields).length > 0) {
753
+ const members = Object.entries(shape.fields)
754
+ .map(([name, member]) => `${pad} ${quote(name)}: ${renderShape(member, indent + 2)},`)
755
+ .join('\n');
756
+ return optional(described(`z.looseObject<z.ZodRawShape>({\n${members}\n${pad}})`));
757
+ }
758
+ if (shape.kind === TransposedInputKind.ARRAY) {
759
+ const element = shape.items === undefined ? 'z.unknown()' : renderShape(shape.items, indent + 2);
760
+ return optional(described(`z.array(${element})`));
761
+ }
762
+ return optional(described(zodFor(shape.kind)));
763
+ }
764
+ function zodFor(kind) {
765
+ switch (kind) {
766
+ case TransposedInputKind.STRING:
767
+ return 'z.string()';
768
+ case TransposedInputKind.NUMBER:
769
+ return 'z.number()';
770
+ case TransposedInputKind.BOOLEAN:
771
+ return 'z.boolean()';
772
+ case TransposedInputKind.ARRAY:
773
+ return 'z.array(z.unknown())';
774
+ case TransposedInputKind.OBJECT:
775
+ return 'z.looseObject<z.ZodRawShape>({})';
776
+ case TransposedInputKind.UNKNOWN:
777
+ return 'z.unknown()';
778
+ case TransposedInputKind.WIRE_SCALAR:
779
+ return 'z.union([z.string(), z.number(), z.boolean()])';
780
+ case TransposedInputKind.WIRE_SCALAR_OR_LIST:
781
+ return 'z.union([z.string(), z.number(), z.boolean(), z.array(z.union([z.string(), z.number(), z.boolean()]))])';
782
+ }
783
+ }
784
+ /** An operation's classification and method are engine enums; everything else is data. */
785
+ function renderOperations(provider, operations) {
786
+ const entries = operations
787
+ .map((operation) => {
788
+ const parameters = operation.parameters
789
+ .filter((parameter) => parameter.in !== TransposedParameterLocation.BODY)
790
+ .map((parameter) => {
791
+ // `from` is emitted only when the wire name and the input field DIFFER, which is what the
792
+ // contract asks for: absent means "the input field is spelled exactly like the wire name".
793
+ const from = parameter.from === undefined || parameter.from === parameter.name ? '' : `, from: ${quote(parameter.from)}`;
794
+ return ` { name: ${quote(parameter.name)}, in: ProviderRestParameterLocation.${parameter.in.toUpperCase()}, required: ${parameter.required === true}${from} },`;
795
+ })
796
+ .join('\n');
797
+ const inputSchema = renderInputSchema(operation);
798
+ const outputSchema = operation.outputShape === undefined ? undefined : renderShape(operation.outputShape, 6);
799
+ return ` ${quote(operation.operationId)}: {
800
+ operationId: ${quote(operation.operationId)},
801
+ domain: ${quote(operation.domain)},
802
+ method: API_HttpMethod.${operation.method},
803
+ pathTemplate: ${quote(operation.pathTemplate ?? '/')},
804
+ classification: ExternalOperation_Classification.${operation.classification},${operation.summary === undefined ? '' : `
805
+ summary: ${quote(operation.summary)},`}${parameters === '' ? '' : `
806
+ parameters: [
807
+ ${parameters}
808
+ ],`}${declaresRequestBody(operation) ? `
809
+ requestBody: { encoding: ProviderRestRequestBodyEncoding.JSON },` : ''}${inputSchema === undefined ? '' : `
810
+ inputSchema: ${inputSchema},`}${outputSchema === undefined ? '' : `
811
+ outputSchema: ${outputSchema},`}
812
+ },`;
813
+ })
814
+ .join('\n');
815
+ return `${GENERATED_BANNER}
816
+
817
+ import { z } from 'zod';
818
+
819
+ import {
820
+ API_HttpMethod,
821
+ ExternalOperation_Classification,
822
+ ProviderRestParameterLocation,
823
+ ProviderRestRequestBodyEncoding,
824
+ type ProviderRestOperationCatalogue,
825
+ } from '@wildo-ai/external-connectors-models';
826
+
827
+ /** ${operations.length} executable operation(s) transposed for \`${provider.ref}\`. */
828
+ export const catalogue: ProviderRestOperationCatalogue = {
829
+ domains: ['default'],
830
+ operations: {
831
+ ${entries}
832
+ },
833
+ };
834
+ `;
835
+ }
836
+ /**
837
+ * A GET or HEAD operation NEVER declares a request body, whatever the source did.
838
+ *
839
+ * `fetch` refuses outright — `Request with GET/HEAD method cannot have body` — so an operation that
840
+ * declares one is not merely unusual, it is unexecutable, and it fails at the socket with a message
841
+ * about the method rather than about the vendor. 231 generated operations across 53 vendors carried
842
+ * one, and every single one of them would have failed on first use.
843
+ * spec-cite: RFC 9110 §9.3.1 — a GET's payload has no defined semantics; the Fetch standard turns
844
+ * that into a hard refusal.
845
+ *
846
+ * Sources do write it: a piece passes a `body` alongside a GET because its own HTTP helper ignores
847
+ * it, or because the vendor tolerates it. The transposer cannot carry that forward — the parameters
848
+ * that matter are already declared as QUERY, so dropping the body loses nothing a caller can send.
849
+ *
850
+ * Found by executing a generated operation against a real server, which is the only thing that could
851
+ * have found it: it typechecks, it parses, it validates against every schema, and it fails the
852
+ * instant a socket is involved.
853
+ */
854
+ function declaresRequestBody(operation) {
855
+ if (!operation.hasRequestBody)
856
+ return false;
857
+ return operation.method !== 'GET' && operation.method !== 'HEAD';
858
+ }
859
+ /**
860
+ * The vendor's TIER, from the record — `CATALOGUE` unless a human promoted it.
861
+ *
862
+ * `ProviderMetadata.tier`'s own contract says "a recorded decision, never inferred", and until this
863
+ * existed the emitter hardcoded `CATALOGUE` while `CatalogueDecisions.tier` was read by nothing. A
864
+ * declared field that nothing consumes is the exact failure the catalogue record was built to stop —
865
+ * a decision that silently does not apply — sitting inside the record's own consumer.
866
+ *
867
+ * An unrecognised value REFUSES rather than falling back, because a typo that quietly leaves a vendor
868
+ * at `CATALOGUE` is indistinguishable from not having written the decision at all.
869
+ */
870
+ function renderTier(decisions, ref) {
871
+ const declared = decisions?.tier;
872
+ if (declared === undefined)
873
+ return 'ProviderTier.CATALOGUE';
874
+ const member = Object.entries(ProviderTier).find(([, value]) => value === declared)?.[0];
875
+ if (member === undefined) {
876
+ throw new Error(`decisions/${ref}.json declares tier '${declared}', which is not a ProviderTier value `
877
+ + `(${Object.values(ProviderTier).join(', ')}).`);
878
+ }
879
+ return `ProviderTier.${member}`;
880
+ }
881
+ /**
882
+ * WHICH connections the vendor admits — projected from the record, never derived from the source.
883
+ *
884
+ * Emitting nothing is the floor (`APPLICATION` × `SERVICE`), and it is what every vendor gets until
885
+ * someone records otherwise. The generator cannot know whether a vendor can be connected per tenant:
886
+ * that is a fact about the vendor's product and about what somebody verified, and "it declares OAuth2"
887
+ * is a fact about the scraped catalogue. Deriving one from the other would produce an unfalsifiable
888
+ * claim that one upstream change flips silently.
889
+ *
890
+ * An unrecognised member REFUSES for the same reason as the tier: a typo that silently narrows a
891
+ * vendor back to the floor reads exactly like a decision nobody made.
892
+ */
893
+ function renderAdmissibleConnections(decisions) {
894
+ const admissible = decisions?.admissibleConnections;
895
+ if (admissible === undefined || admissible.length === 0)
896
+ return '';
897
+ const ownerScopes = Object.entries(ExternalProvider_Connection_OwnerScope);
898
+ const delegations = Object.entries(ExternalProvider_Connection_DelegationMode);
899
+ const rendered = admissible.map((entry) => {
900
+ const owner = ownerScopes.find(([, value]) => value === entry.ownerScope)?.[0];
901
+ const delegation = delegations.find(([, value]) => value === entry.delegation)?.[0];
902
+ if (owner === undefined || delegation === undefined) {
903
+ throw new Error(`decisions/${decisions?.ref}.json admits '${entry.ownerScope}' × '${entry.delegation}', `
904
+ + `which is not a (ExternalProvider_Connection_OwnerScope × ExternalProvider_Connection_DelegationMode) pair.`);
905
+ }
906
+ return ` { ownerScope: ExternalProvider_Connection_OwnerScope.${owner}, delegation: ExternalProvider_Connection_DelegationMode.${delegation} },`;
907
+ });
908
+ return `\n admissibleConnections: [\n${rendered.join('\n')}\n ],`;
909
+ }
910
+ /**
911
+ * NOTE on `import('./operations.generated.js')` in this template — the extension is load-bearing and
912
+ * must not be "tidied" away.
913
+ *
914
+ * That literal is DATA: the text written into every vendor module. But it is import-SHAPED, so the
915
+ * alias finalizer rewrote it when THIS file was built — the source said `./operations.generated` and
916
+ * the shipped generator wrote `./operations.generated.js`. The generator's OUTPUT therefore depended
917
+ * on how the generator itself had been built, and running it from source rather than from dist would
918
+ * emit a different catalogue.
919
+ *
920
+ * It went unnoticed for the worst possible reason: the rewrite was RIGHT. The emitted module compiles
921
+ * to ESM, where the extension is required. Found 2026-09-08 by reading a regeneration diff, not by a
922
+ * test — none pinned either form. Saying it at the source makes source and build agree, and rule
923
+ * `lazy-catalogue-import-drops-its-extension` in `check-provider-catalogue.mjs` pins it on the SHIPPED
924
+ * tree, whichever build produced it.
925
+ *
926
+ * The reasoning lives here rather than beside the line because the line is inside a template literal:
927
+ * a comment there is emitted into every vendor module, and a backtick in it ends the template.
928
+ */
929
+ function renderBackendModule(provider, operations, authored, decisions) {
930
+ // Computed once: the metadata block and the import line must agree, and rendering the enums
931
+ // without importing them emits a module that reads correctly and does not compile.
932
+ const admissible = renderAdmissibleConnections(decisions);
933
+ const envPrefix = envPrefixFor(provider.ref);
934
+ const secretEnvVar = `${envPrefix}_API_KEY`;
935
+ const header = authHeaderFor(provider.auth.kind);
936
+ return `${GENERATED_BANNER}
937
+
938
+ import { z } from 'zod';
939
+
940
+ import { ProviderProtocolRuntimeKind, ExternalProvider_ExchangeProtocol_Kind${admissible === '' ? '' : ', ExternalProvider_Connection_DelegationMode, ExternalProvider_Connection_OwnerScope'} } from '@wildo-ai/external-connectors-models';
941
+ import { defineProviderMetadata, ProviderCatalogueSource, ProviderOriginKind, ProviderTier } from '@wildo-ai/saas-models';
942
+ import type { ProviderOperationExecute } from '@wildo-ai/external-connectors-models';
943
+ import type { ExternalProvider_ConnectionTarget } from '@wildo-ai/external-connectors-models';
944
+ import type { BackendProviderModule, BackendProviderRegistryFragment, ProviderRef } from '@wildo-ai/external-connectors-private/backend';
945
+ ${authored ? `import { withAuthoredSupplement } from '@wildo-ai/external-connectors-private/backend';
946
+
947
+ import { authored as authoredSupplement, authoredClient } from '${AUTHORED_IMPORT_PREFIX}${provider.ref}${AUTHORED_FILE_SUFFIX_IMPORT}';
948
+ ` : ''}
949
+ /**
950
+ * \`${provider.ref}\` — transposed from ${provider.provenances.map((p) => p.source).join(', ')}.
951
+ *
952
+ * Auth shape read from the source: ${provider.auth.kind}.${provider.auth.kind === TransposedAuthKind.CUSTOM
953
+ ? `
954
+ * The source declares a vendor-specific credential bag (${(provider.auth.customFields ?? []).join(', ') || 'fields not recovered'});
955
+ * the secrets contract below names ONE key, and completing it is a human decision the transposer
956
+ * refuses to guess.`
957
+ : ''}${provider.auth.kind === TransposedAuthKind.OAUTH2
958
+ ? `
959
+ * OAuth2 endpoints: authorize ${provider.auth.authUrl ?? '(not recovered)'}, token ${provider.auth.tokenUrl ?? '(not recovered)'}.
960
+ * The dance itself is Wildo's and identical for every vendor; only these endpoints and the scopes differ.`
961
+ : ''}
962
+ */
963
+ ${authored ? 'const generated' : `export const ${identifierFor(provider.ref)}BackendProvider`}: BackendProviderModule = {
964
+ metadata: defineProviderMetadata({
965
+ ref: ${quote(provider.ref)},
966
+ packageName: ${quote(PACKAGE_NAME)},
967
+ tier: ${renderTier(decisions, provider.ref)},
968
+ vendor: ${quote(provider.vendor)},
969
+ origin: {
970
+ kind: ProviderOriginKind.GENERATED,
971
+ catalogue: {
972
+ source: ProviderCatalogueSource.${provider.provenances[0]?.source ?? 'ACTIVEPIECES'},
973
+ sourceRef: ${quote(provider.provenances[0]?.sourceRef ?? provider.ref)},
974
+ sourceVersion: ${quote(provider.provenances[0]?.sourceVersion ?? 'unknown')},
975
+ },
976
+ },
977
+ }),
978
+ providerCapabilities: [],${admissible}
979
+ secretsContract: {
980
+ ${renderSecretsContract(provider, secretEnvVar, envPrefix)} },
981
+ protocols: [
982
+ {
983
+ // The MEMBER NAME, not the enum value. \`composeBackendProviders\` indexes the enum BY this
984
+ // string and compares the result to \`runtimeContract.kind\`, so the value ("rest_api") makes the
985
+ // lookup \`undefined\` and composition refuses the provider. The binding is typed
986
+ // \`TProtocol extends string\`, so the wrong one compiled — and every generated provider carried
987
+ // it, unloadable, until the chain was walked instead of doubled.
988
+ protocol: 'REST_API',
989
+ // The operation catalogue is the authoring surface, and it is DATA rather than an editable
990
+ // parameter shape, so the binding exposes nothing to the visual editor and validates nothing
991
+ // at the binding level: each operation carries its own input schema, checked by the executor.
992
+ designTimeExposed: false,
993
+ parameterSchema: z.unknown(),
994
+ runtimeContract: {
995
+ kind: ProviderProtocolRuntimeKind.REST,
996
+ ${provider.baseUrl === undefined ? ` // No single base URL was recovered from the source; the deployment names it.
997
+ baseUrlEnvVarName: ${quote(`${envPrefix}_BASE_URL`)},` : ` baseUrl: ${quote(provider.baseUrl)},`}
998
+ ${renderOAuth2Block(provider, envPrefix)} apiKey: { secretRef: ${quote(secretEnvVar)}, headerName: ${quote(header.name)}${header.prefix === undefined ? '' : `, prefix: ${quote(header.prefix)}`} },
999
+ operations: async () => (await import('./operations.generated.js')).catalogue,
1000
+ },
1001
+ },
1002
+ ],
1003
+ };
1004
+ ${authored ? `
1005
+ /**
1006
+ * The generated module, supplemented by hand. See the authored file for why it exists — the batch
1007
+ * regenerates everything above and never touches it.
1008
+ */
1009
+ export const ${identifierFor(provider.ref)}BackendProvider: BackendProviderModule = withAuthoredSupplement(generated, authoredSupplement);
1010
+ ` : ''}
1011
+ /**
1012
+ * The CONVENTIONAL export a host loads this vendor by.
1013
+ *
1014
+ * A host resolving \`${PACKAGE_NAME}/${provider.ref}\` knows the specifier and nothing else — not
1015
+ * which symbol inside is the provider. So the name is fixed for every package, and
1016
+ * \`readBackendProviderFragment\` refuses a namespace that does not carry it. Without this export the
1017
+ * subpath resolves, typechecks, and is unloadable.
1018
+ *
1019
+ * The key is the module's OWN declared ref, branded at this boundary exactly as
1020
+ * \`EngineBackendProviderRegistryFragment\` brands its own — \`ProviderRef\` is a compile-time facet with
1021
+ * no runtime content, and the value being branded is the identity this module already publishes.
1022
+ * That is a different act from casting a dynamically imported namespace, which asserts a shape
1023
+ * nobody checked; here the shape is the literal above.
1024
+ */
1025
+ export const backendProviderFragment: BackendProviderRegistryFragment = {
1026
+ modules: new Map([[${identifierFor(provider.ref)}BackendProvider.metadata.ref as ProviderRef, ${identifierFor(provider.ref)}BackendProvider]]),
1027
+ };
1028
+
1029
+ ${renderTypedClient(provider, operations, authored)}`;
1030
+ }
1031
+ /**
1032
+ * The typed client — R3, bought with a TYPE rather than a dependency.
1033
+ *
1034
+ * `slack.slackGetChannelInfo({ channel: 'C1' })`, with the compiler checking the parameters and no
1035
+ * runtime import of the engine: the factory takes the executor as an argument, so an application
1036
+ * wires its own. Importing the executor here would put the whole backend into the module graph of
1037
+ * anything touching a vendor — the exact weight #378 removed.
1038
+ *
1039
+ * ## Only RESOLVED operations appear
1040
+ *
1041
+ * A pending operation has no method and no path. Putting one on the client would offer a method that
1042
+ * cannot execute, which is worse than an absent one: the absent method sends a caller to look, and
1043
+ * the present one sends them to file a bug against the vendor. The emitter passes only resolved
1044
+ * operations here, and the catalogue keyed beside it contains exactly the same set.
1045
+ *
1046
+ * ## The name comes from the FINAL operation id
1047
+ *
1048
+ * Ids are already disambiguated upstream — method, then path tail, then ordinal — so deriving a name
1049
+ * from anything else re-collides the cases that pass already resolved (twenty of them in `discord`).
1050
+ * The camelCase name is ergonomics; the id travelling inside the call is identity, and the two are
1051
+ * derived one from the other so they cannot drift.
1052
+ *
1053
+ * ## Inputs are typed CLOSED, while the runtime is loose
1054
+ *
1055
+ * The input type names exactly the fields the request needs. The `inputSchema` beside it is a
1056
+ * `looseObject`, so a vendor field no catalogue mentioned is still ACCEPTED at runtime and a caller
1057
+ * who needs one passes it through a cast. Widening the type with an index signature instead would
1058
+ * make every typo compile, which is the one thing a typed client exists to prevent.
1059
+ *
1060
+ * ## The argument covers the WIRE, not only what the catalogue asked its user for
1061
+ *
1062
+ * Input fields and parameters are different populations: an input field is what the SOURCE CATALOGUE
1063
+ * asked its user for, a parameter is what the REQUEST places on the wire. A path token is routinely
1064
+ * the second without the first — an unsubscribe reads `/webhooks/{webhookId}`, and the id is one the
1065
+ * caller already holds from the subscribe rather than something a form asked for. A client typed from
1066
+ * input fields as the source left them therefore REFUSED to offer the value the executor demands.
1067
+ *
1068
+ * `declareWhatTheWireNeeds` folds the wire's parameters into `inputFields` before anything is
1069
+ * rendered, under the key `compileProviderOperationRequest` reads (`from ?? name`), so the argument
1070
+ * type and the `inputSchema` beside it stay two renderings of one set rather than two lists that can
1071
+ * disagree.
1072
+ */
1073
+ function renderTypedClient(provider, operations, authored) {
1074
+ const usedNames = new Set();
1075
+ const methods = operations
1076
+ .map((operation) => {
1077
+ const name = uniqueMethodName(operation.operationId, usedNames);
1078
+ const fields = callerSuppliedFields(operation)
1079
+ .map((field) => `${quote(field.key)}${field.required ? '' : '?'}: ${field.type}`)
1080
+ .join('; ');
1081
+ const shape = fields.length === 0 ? 'Record<string, never>' : `{ ${fields} }`;
1082
+ const summary = (operation.summary ?? operation.operationId).replace(/\*\//g, '*\\/');
1083
+ return ` /** ${summary} */
1084
+ ${name}: (input: ${shape}, connection?: ExternalProvider_ConnectionTarget): Promise<unknown> =>
1085
+ execute(${quote(provider.ref)}, ${quote(operation.operationId)}, input, connection),`;
1086
+ })
1087
+ .join('\n');
1088
+ return `/**
1089
+ * Typed access to ${provider.vendor}'s ${operations.length} executable operation(s).
1090
+ *
1091
+ * Takes the executor rather than importing one, so this package carries no runtime dependency on the
1092
+ * engine. Operations awaiting an endpoint are absent by construction.${authored ? `
1093
+ *
1094
+ * The authored fragment is spread LAST, so a hand-written method wins a name collision with a
1095
+ * generated one — the author saw both and chose.` : ''}
1096
+ */
1097
+ export function create${identifierFor(provider.ref)}Client(execute: ProviderOperationExecute) {
1098
+ return {
1099
+ ${methods}${authored ? `
1100
+ ...authoredClient(execute),` : ''}
1101
+ };
1102
+ }
1103
+ `;
1104
+ }
1105
+ /**
1106
+ * The fields a CALLER supplies for one operation.
1107
+ *
1108
+ * A projection of `inputFields` and nothing else, which is the point: `declareWhatTheWireNeeds` has
1109
+ * already folded every wire parameter into that list, so the client's argument type and the
1110
+ * `inputSchema` beside it are two renderings of ONE set. An earlier revision computed the union here
1111
+ * as well, and that was two mechanisms for one invariant — the second silently doing nothing, and a
1112
+ * pin written against it passing for the wrong reason.
1113
+ *
1114
+ * The one thing this must know that a name cannot tell it: which fields ride in a PATH. A credential
1115
+ * is resolved and never asked for, but nothing except the caller can fill a path token, so a token
1116
+ * whose name merely SPELLS like a credential must still be offered — `simplybookme`'s
1117
+ * `/admin/clients/{clientId}` is a client RECORD's id, and filtering it by name shipped a method
1118
+ * whose URL kept a literal hole. Requiredness comes from the same authority: the executor refuses an
1119
+ * empty path token whatever the declaration says.
1120
+ */
1121
+ function callerSuppliedFields(operation) {
1122
+ return callerSuppliedInputFields(operation).map((field) => ({
1123
+ key: field.name,
1124
+ required: field.required,
1125
+ type: typeScriptFor(field.kind),
1126
+ }));
1127
+ }
1128
+ /**
1129
+ * THE set — the one both the typed client and the runtime `inputSchema` render.
1130
+ *
1131
+ * Extracted 2026-09-08, because the sentence above ("two renderings of ONE set") was describing an
1132
+ * invariant the code did not hold. `callerSuppliedFields` filtered; `renderInputSchema` walked
1133
+ * `operation.inputFields` raw. So every generated module shipped a typed client that WITHHELD the
1134
+ * credential — correctly, it is resolved from the secrets contract — beside a Zod schema that
1135
+ * REQUIRED it, and the executor validates against the schema.
1136
+ *
1137
+ * The consequence is the worst arrangement available: the type-safe door is the one that fails. An
1138
+ * application calling `client.salesforceGetDashboard({ dashboardId })` compiles, because the client's
1139
+ * argument type does not mention `accessToken`, and is then refused at execution with
1140
+ * `INPUT_REJECTED: accessToken — Required`. Measured across the catalogue before the fix: **1,668 of
1141
+ * 5,675 operations (29.4%), across 151 of 689 vendors**, could not be called at all through their own
1142
+ * client.
1143
+ *
1144
+ * Found by driving one operation to a socket for the first time — the ETL-binding proof. No
1145
+ * typecheck could see it (the two artifacts are a `.ts` type and a Zod value), and no test did,
1146
+ * because every existing pin either read the client's TEXT or executed a vendor whose auth happens to
1147
+ * carry no input field at all.
1148
+ *
1149
+ * The PATH exemption is carried here, once, and it is not optional: nothing except the caller can
1150
+ * fill a path token, so a token that merely SPELLS like a credential must still be offered and must
1151
+ * be required. `simplybookme`'s `/admin/clients/{clientId}` is a client RECORD's id.
1152
+ */
1153
+ function callerSuppliedInputFields(operation) {
1154
+ const pathKeys = new Set(operation.parameters
1155
+ .filter((parameter) => parameter.in === TransposedParameterLocation.PATH)
1156
+ .map((parameter) => parameter.from ?? parameter.name));
1157
+ return operation.inputFields
1158
+ .filter((field) => pathKeys.has(field.name) || !CALLER_SUPPLIES_NO_CREDENTIAL.has(field.name))
1159
+ .map((field) => ({ ...field, required: field.required === true || pathKeys.has(field.name) }));
1160
+ }
1161
+ /**
1162
+ * Input names a CALLER never supplies, because Wildo supplies them.
1163
+ *
1164
+ * A source catalogue declares the credential alongside the operation's real parameters — a piece's
1165
+ * props carry `accessToken` and `botToken` beside `channel` — because in that catalogue the user
1166
+ * fills both in. In Wildo they are different things entirely: the credential is resolved from the
1167
+ * provider's secrets contract at execution, and the operation's parameters come from the caller. A
1168
+ * typed client that asked for both would invite an application to pass a token by hand, which is the
1169
+ * one habit the whole secrets contract exists to remove.
1170
+ *
1171
+ * **A PATH position is exempt, and the exemption is not optional** — see `callerSuppliedFields` and
1172
+ * `declareWhatTheWireNeeds`, which both carry it. Nothing except the caller can fill a path token, so
1173
+ * withholding one by NAME ships a method whose URL keeps a literal hole. `simplybookme`
1174
+ * `/admin/clients/{clientId}` is a client RECORD's id that merely spells itself like OAuth's, and a
1175
+ * name-based filter cannot see through that coincidence. Do not unify the two positions: the same
1176
+ * spelling in a QUERY really is the credential, which is why they must be decided separately.
1177
+ *
1178
+ * Matched on EXACT names only, and the omissions are deliberate. Bare `token` and `secret` are not
1179
+ * here: a vendor legitimately uses `token` for pagination, and dropping a real parameter to tidy the
1180
+ * type would make a call silently incomplete — worse than an extra field a caller can ignore.
1181
+ */
1182
+ const CALLER_SUPPLIES_NO_CREDENTIAL = new Set([
1183
+ 'authMethod', 'auth_method',
1184
+ 'accessToken', 'access_token',
1185
+ // `authToken` joined on 2026-09-08, after the first sweep that could see the population: it is
1186
+ // unambiguous in a way bare `token` is not — nothing paginates with an `authToken` — and it was
1187
+ // Twilio's credential, sitting in the input schema of every one of its operations.
1188
+ 'authToken', 'auth_token',
1189
+ 'botToken', 'bot_token',
1190
+ 'apiKey', 'api_key',
1191
+ 'bearerToken', 'bearer_token',
1192
+ 'clientId', 'client_id',
1193
+ 'clientSecret', 'client_secret',
1194
+ 'password',
1195
+ 'refreshToken', 'refresh_token',
1196
+ ]);
1197
+ /** The source's declared kind, as the type a caller writes against. */
1198
+ function typeScriptFor(kind) {
1199
+ switch (kind) {
1200
+ case TransposedInputKind.STRING:
1201
+ return 'string';
1202
+ case TransposedInputKind.NUMBER:
1203
+ return 'number';
1204
+ case TransposedInputKind.BOOLEAN:
1205
+ return 'boolean';
1206
+ case TransposedInputKind.ARRAY:
1207
+ return 'readonly unknown[]';
1208
+ case TransposedInputKind.OBJECT:
1209
+ return 'Record<string, unknown>';
1210
+ case TransposedInputKind.UNKNOWN:
1211
+ // The source declared the field and not its kind. `unknown` forces the caller to be explicit
1212
+ // rather than quietly accepting whatever they had — a guess here would be a lie with a type.
1213
+ return 'unknown';
1214
+ case TransposedInputKind.WIRE_SCALAR:
1215
+ return 'string | number | boolean';
1216
+ case TransposedInputKind.WIRE_SCALAR_OR_LIST:
1217
+ return 'string | number | boolean | readonly (string | number | boolean)[]';
1218
+ default: {
1219
+ const exhaustive = kind;
1220
+ return exhaustive;
1221
+ }
1222
+ }
1223
+ }
1224
+ /**
1225
+ * `slack-find-user-by-email` → `slackFindUserByEmail`; `trigger.new-lead.poll` → `triggerNewLeadPoll`.
1226
+ *
1227
+ * Collisions take an ordinal rather than overwriting each other: two methods with one name silently
1228
+ * drops an operation the catalogue shows, which is the same defect the operation-id uniqueness pass
1229
+ * exists for one layer down.
1230
+ */
1231
+ function uniqueMethodName(operationId, taken) {
1232
+ const parts = operationId.split(/[^a-zA-Z0-9]+/).filter((part) => part.length > 0);
1233
+ const base = parts
1234
+ .map((part, index) => (index === 0 ? part[0].toLowerCase() + part.slice(1) : part[0].toUpperCase() + part.slice(1)))
1235
+ .join('');
1236
+ const safe = /^[a-zA-Z_]/.test(base) ? base : `operation${base}`;
1237
+ let candidate = safe;
1238
+ let ordinal = 2;
1239
+ while (taken.has(candidate)) {
1240
+ candidate = `${safe}${ordinal}`;
1241
+ ordinal += 1;
1242
+ }
1243
+ taken.add(candidate);
1244
+ return candidate;
1245
+ }
1246
+ /**
1247
+ * The `./companion` barrel — how discovery learns that 699 vendors exist without loading one.
1248
+ *
1249
+ * A contribution is a values-free DECLARATION: the ref, the identity, the protocols, the runtime
1250
+ * targets and the shape of the secrets a deployment must supply. The CLI reads them to build the
1251
+ * lockfile and the generated catalogue types; the companion reads them to know what an application
1252
+ * may declare. None of it loads a provider's runtime module, which is the point — the whole
1253
+ * catalogue is discoverable at a cost that does not grow with what it contains.
1254
+ *
1255
+ * `runtimeImportPath` is each vendor's SUBPATH (`@wildo-ai/providers/slack`), and that is what makes
1256
+ * the one-package shape work with on-demand loading: discovery names 699 reachable entries, and a
1257
+ * host imports exactly the one an application declared.
1258
+ *
1259
+ * `runtimeTargets` is `backend` only. These are REST providers reached by an application's own
1260
+ * services; nothing here belongs in the companion, whose LLM-provider exception exists for
1261
+ * AI-assisted development and has no analogue in a vendor catalogue.
1262
+ */
1263
+ /**
1264
+ * `protocols` carries the enum MEMBER NAME, not its value.
1265
+ *
1266
+ * That is what an application authors — `protocols: ['REST_API']` — and what every engine-shipped
1267
+ * contribution declares, and discovery VALIDATES the application's scope against this list. Emitting
1268
+ * the enum value made `wildo config sync` refuse with *"declares protocol 'REST_API' but discovery
1269
+ * does not report that protocol"*, which reads like a missing binding and is a spelling
1270
+ * disagreement.
1271
+ *
1272
+ * The THIRD field in this emitter where the convention is the name and the value was written
1273
+ * instead, after the protocol binding and the loader fragment. The convention is stated nowhere a
1274
+ * generator can read, and every one of these types accepts a bare string — so each instance had to be
1275
+ * found by running the real thing (#397).
1276
+ */
1277
+ function renderCompanionExports(providers, decisionsByRef) {
1278
+ const entries = [...providers]
1279
+ .sort((left, right) => left.ref.localeCompare(right.ref))
1280
+ .map((provider) => {
1281
+ const envPrefix = envPrefixFor(provider.ref);
1282
+ return ` {
1283
+ ref: ${quote(provider.ref)},
1284
+ identity: {
1285
+ packageName: ${quote(PACKAGE_NAME)},
1286
+ tier: ${renderTier(decisionsByRef.get(provider.ref), provider.ref)},
1287
+ vendor: ${quote(provider.vendor)},
1288
+ origin: {
1289
+ kind: ProviderOriginKind.GENERATED,
1290
+ catalogue: {
1291
+ source: ProviderCatalogueSource.${provider.provenances[0]?.source ?? 'ACTIVEPIECES'},
1292
+ sourceRef: ${quote(provider.provenances[0]?.sourceRef ?? provider.ref)},
1293
+ sourceVersion: ${quote(provider.provenances[0]?.sourceVersion ?? 'unknown')},
1294
+ },
1295
+ },
1296
+ },
1297
+ runtimeImportPath: ${quote(`${PACKAGE_NAME}/${provider.ref}`)},
1298
+ runtimeTargets: [{ kind: 'backend' }],
1299
+ engineCapabilities: [],
1300
+ providerCapabilities: [],
1301
+ protocols: ['REST_API'],
1302
+ secretsContractShape: [
1303
+ ${renderContributionSecretShape(provider, envPrefix)} ],
1304
+ },`;
1305
+ })
1306
+ .join('\n');
1307
+ return `${GENERATED_BANNER}
1308
+
1309
+ import { ExternalProvider_ExchangeProtocol_Kind } from '@wildo-ai/external-connectors-models';
1310
+ import { ProviderCatalogueSource, ProviderOriginKind, ProviderTier } from '@wildo-ai/saas-models';
1311
+ import type { RuntimeOwnerCompanionExports } from '@wildo-ai/saas-models/companion';
1312
+
1313
+ /** ${providers.length} vendors, declared without loading any of them. */
1314
+ const companionExports: RuntimeOwnerCompanionExports = {
1315
+ providerContributions: [
1316
+ ${entries}
1317
+ ],
1318
+ };
1319
+
1320
+ export default companionExports;
1321
+ `;
1322
+ }
1323
+ /**
1324
+ * The same secrets the module declares, in the discovery contract's own shape.
1325
+ *
1326
+ * It must AGREE with `renderSecretsContract` — discovery's whole job is to say what a deployment
1327
+ * owes before anything is loaded, and a contribution that disagreed with the module would be a
1328
+ * lockfile built on a promise the runtime does not keep. Sorted by slug, because the schema's
1329
+ * `superRefine` requires it and an unsorted list fails discovery at parse rather than at use.
1330
+ */
1331
+ function renderContributionSecretShape(provider, envPrefix) {
1332
+ const entry = (slug, envVarName, required, description) => ` {
1333
+ slug: ${quote(slug)},
1334
+ envVarName: ${quote(envVarName)},
1335
+ required: ${required},
1336
+ description: ${quote(description)},
1337
+ },
1338
+ `;
1339
+ if (provider.auth.kind !== TransposedAuthKind.OAUTH2) {
1340
+ return entry('apiKey', `${envPrefix}_API_KEY`, true, `Credential for ${provider.vendor}, transposed as ${provider.auth.kind}.`);
1341
+ }
1342
+ return (entry('accessToken', `${envPrefix}_API_KEY`, false, `Access token for ${provider.vendor}. Minted by the OAuth2 exchange, not authored — set it only if ${provider.vendor} issues a long-lived token.`)
1343
+ + entry('clientId', `${envPrefix}_CLIENT_ID`, true, `OAuth2 client id for the application's ${provider.vendor} registration.`)
1344
+ + entry('clientSecret', `${envPrefix}_CLIENT_SECRET`, true, `OAuth2 client secret for the application's ${provider.vendor} registration.`));
1345
+ }
1346
+ /** The env-var prefix a vendor's credential takes. One derivation, used by both emitted files. */
1347
+ function envPrefixFor(ref) {
1348
+ return ref.replace(/[^a-zA-Z0-9]+/g, '_').toUpperCase();
1349
+ }
1350
+ /**
1351
+ * What a deployment must actually supply, which differs by credential model.
1352
+ *
1353
+ * For a pasted credential — an API key, a basic password — that is one secret and the runtime reads
1354
+ * it directly. For OAuth2 it is the APPLICATION REGISTRATION (client id and client secret), which an
1355
+ * operator genuinely does paste, plus a slot for the ACCESS TOKEN that an authorization exchange
1356
+ * mints and nobody types. Declaring the token slot as `required: false` is the honest statement:
1357
+ * absent is the normal state until an account is connected, and demanding it at boot would make
1358
+ * every OAuth2 provider un-deployable.
1359
+ */
1360
+ function renderSecretsContract(provider, secretEnvVar, envPrefix) {
1361
+ if (provider.auth.kind !== TransposedAuthKind.OAUTH2) {
1362
+ return ` apiKey: {
1363
+ envVarName: ${quote(secretEnvVar)},
1364
+ required: true,
1365
+ description: ${quote(`Credential for ${provider.vendor}, transposed as ${provider.auth.kind}.`)},
1366
+ },
1367
+ `;
1368
+ }
1369
+ return ` clientId: {
1370
+ envVarName: ${quote(`${envPrefix}_CLIENT_ID`)},
1371
+ required: true,
1372
+ description: ${quote(`OAuth2 client id for the application's ${provider.vendor} registration.`)},
1373
+ },
1374
+ clientSecret: {
1375
+ envVarName: ${quote(`${envPrefix}_CLIENT_SECRET`)},
1376
+ required: true,
1377
+ description: ${quote(`OAuth2 client secret for the application's ${provider.vendor} registration.`)},
1378
+ },
1379
+ accessToken: {
1380
+ envVarName: ${quote(secretEnvVar)},
1381
+ required: false,
1382
+ description: ${quote(`Access token for ${provider.vendor}. Minted by the OAuth2 exchange, not authored — set it only if ${provider.vendor} issues a long-lived token.`)},
1383
+ },
1384
+ `;
1385
+ }
1386
+ /**
1387
+ * The OAuth2 declaration, emitted as DATA rather than as the JSDoc comment it used to be.
1388
+ *
1389
+ * These endpoints and scopes exist nowhere in this repository except the catalogue that was read.
1390
+ * Extracting them and keeping them in prose meant the delegated-authorization lane would re-derive
1391
+ * 131 vendors' worth of endpoints by hand.
1392
+ */
1393
+ function renderOAuth2Block(provider, envPrefix) {
1394
+ if (provider.auth.kind !== TransposedAuthKind.OAUTH2 || provider.auth.authUrl === undefined || provider.auth.tokenUrl === undefined) {
1395
+ return '';
1396
+ }
1397
+ const scopes = provider.auth.scopes ?? [];
1398
+ const connectionParameters = collectEndpointPlaceholders([provider.auth.authUrl, provider.auth.tokenUrl]);
1399
+ return ` oauth2: {
1400
+ authorizeUrl: ${quote(provider.auth.authUrl)},
1401
+ tokenUrl: ${quote(provider.auth.tokenUrl)},${scopes.length === 0 ? '' : `
1402
+ scopes: [${scopes.map((scope) => quote(scope)).join(', ')}],`}
1403
+ clientIdSecretRef: ${quote(`${envPrefix}_CLIENT_ID`)},
1404
+ clientSecretSecretRef: ${quote(`${envPrefix}_CLIENT_SECRET`)},${connectionParameters.length === 0 ? '' : `
1405
+ connectionParameters: [${connectionParameters.map((name) => quote(name)).join(', ')}],`}
1406
+ },
1407
+ `;
1408
+ }
1409
+ /**
1410
+ * The `{token}` placeholders an OAuth2 endpoint carries, deduplicated and in first-appearance order.
1411
+ *
1412
+ * Measured over the transposed catalogue on 2026-09-08: 21 of the 96 vendors with both endpoints
1413
+ * carry at least one — `{cloud}` (18), `{location}` (10), `{tenantId}` (6), plus `{region}`,
1414
+ * `{environment}`, `{domain}`, `{baseUrl}`, `{authHost}`, `{apiHost}`. Each names something only the
1415
+ * person connecting the account can supply.
1416
+ *
1417
+ * Deliberately the same brace syntax the operation path templates already use, so one vocabulary
1418
+ * covers both. Deliberately NOT a URL parse: an authorize URL with an unresolved placeholder in its
1419
+ * HOST is not a parseable URL, which is exactly the population this exists to find.
1420
+ *
1421
+ * First-appearance order rather than sorted, because the order a vendor writes them in is the order
1422
+ * they read to a person filling in a form — `{cloud}` then `{tenantId}` is how Microsoft's own
1423
+ * documentation presents them, and re-sorting to `cloud, tenantId` is luck rather than design.
1424
+ */
1425
+ function collectEndpointPlaceholders(urls) {
1426
+ const names = [];
1427
+ for (const url of urls) {
1428
+ for (const match of url.matchAll(/\{([A-Za-z_][A-Za-z0-9_]*)\}/g)) {
1429
+ const name = match[1];
1430
+ if (!names.includes(name))
1431
+ names.push(name);
1432
+ }
1433
+ }
1434
+ return names;
1435
+ }
1436
+ /**
1437
+ * Where the credential rides.
1438
+ *
1439
+ * A bearer header is the right default for SECRET_TEXT and OAUTH2 and is what the overwhelming
1440
+ * majority of the catalogue's vendors use; BASIC and CUSTOM are named honestly rather than forced
1441
+ * into it, because a wrong header placement authenticates nothing and the failure reads as a
1442
+ * credential problem rather than a transposition one.
1443
+ */
1444
+ function authHeaderFor(kind) {
1445
+ switch (kind) {
1446
+ case TransposedAuthKind.OAUTH2:
1447
+ case TransposedAuthKind.SECRET_TEXT:
1448
+ return { name: 'Authorization', prefix: 'Bearer ' };
1449
+ case TransposedAuthKind.BASIC:
1450
+ return { name: 'Authorization', prefix: 'Basic ' };
1451
+ case TransposedAuthKind.CUSTOM:
1452
+ case TransposedAuthKind.NONE:
1453
+ return { name: 'Authorization' };
1454
+ }
1455
+ }
1456
+ function identifierFor(ref) {
1457
+ return ref
1458
+ .split(/[^a-zA-Z0-9]+/)
1459
+ .filter((part) => part.length > 0)
1460
+ .map((part) => part[0].toUpperCase() + part.slice(1))
1461
+ .join('');
1462
+ }
1463
+ function quote(value) {
1464
+ return JSON.stringify(value);
1465
+ }
1466
+ //# sourceMappingURL=provider-package.emitter.js.map