@wildo-ai/saas-models 1.1.1 → 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 (588) hide show
  1. package/dist/esm/applications/applications-context.schemas.d.ts +16 -10
  2. package/dist/esm/applications/applications-context.schemas.d.ts.map +1 -1
  3. package/dist/esm/applications/applications.shared.resources-config.schemas.d.ts.map +1 -1
  4. package/dist/esm/applications/applications.shared.resources-config.schemas.js +4 -3
  5. package/dist/esm/applications/applications.shared.resources-config.schemas.js.map +1 -1
  6. package/dist/esm/billing/billing-account.shared.resources-config.schemas.d.ts +1 -1
  7. package/dist/esm/billing/billing-account.shared.resources-config.schemas.d.ts.map +1 -1
  8. package/dist/esm/billing/billing-account.shared.resources-config.schemas.js +36 -0
  9. package/dist/esm/billing/billing-account.shared.resources-config.schemas.js.map +1 -1
  10. package/dist/esm/billing/billing-account.shared.schemas.d.ts.map +1 -1
  11. package/dist/esm/billing/billing-account.shared.schemas.js +8 -1
  12. package/dist/esm/billing/billing-account.shared.schemas.js.map +1 -1
  13. package/dist/esm/billing/billing-configuration.shared.schemas.d.ts +0 -4
  14. package/dist/esm/billing/billing-configuration.shared.schemas.d.ts.map +1 -1
  15. package/dist/esm/billing/billing-configuration.shared.schemas.js +59 -17
  16. package/dist/esm/billing/billing-configuration.shared.schemas.js.map +1 -1
  17. package/dist/esm/billing/billing-enums.shared.schemas.d.ts +77 -21
  18. package/dist/esm/billing/billing-enums.shared.schemas.d.ts.map +1 -1
  19. package/dist/esm/billing/billing-enums.shared.schemas.js +85 -23
  20. package/dist/esm/billing/billing-enums.shared.schemas.js.map +1 -1
  21. package/dist/esm/billing/billing-types.shared.schemas.d.ts +5 -5
  22. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.d.ts +1 -1
  23. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.d.ts.map +1 -1
  24. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.js +39 -0
  25. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.js.map +1 -1
  26. package/dist/esm/billing/credit-pool.shared.schemas.d.ts +6 -6
  27. package/dist/esm/billing/credit-pool.shared.schemas.d.ts.map +1 -1
  28. package/dist/esm/billing/credit-pool.shared.schemas.js +8 -4
  29. package/dist/esm/billing/credit-pool.shared.schemas.js.map +1 -1
  30. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.d.ts +1 -1
  31. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.d.ts.map +1 -1
  32. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.js +35 -0
  33. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.js.map +1 -1
  34. package/dist/esm/billing/invoice-ref.shared.schemas.d.ts.map +1 -1
  35. package/dist/esm/billing/invoice-ref.shared.schemas.js +8 -3
  36. package/dist/esm/billing/invoice-ref.shared.schemas.js.map +1 -1
  37. package/dist/esm/billing/price.shared.schemas.d.ts.map +1 -1
  38. package/dist/esm/billing/price.shared.schemas.js +7 -1
  39. package/dist/esm/billing/price.shared.schemas.js.map +1 -1
  40. package/dist/esm/billing/product-behavior-policy.shared.schemas.d.ts.map +1 -1
  41. package/dist/esm/billing/product-behavior-policy.shared.schemas.js +52 -11
  42. package/dist/esm/billing/product-behavior-policy.shared.schemas.js.map +1 -1
  43. package/dist/esm/billing/product-definition.shared.schemas.d.ts +2 -2
  44. package/dist/esm/billing/product.shared.resources-config.schemas.d.ts +2 -2
  45. package/dist/esm/billing/product.shared.schemas.d.ts +2 -2
  46. package/dist/esm/billing/product.shared.schemas.d.ts.map +1 -1
  47. package/dist/esm/billing/product.shared.schemas.js +7 -3
  48. package/dist/esm/billing/product.shared.schemas.js.map +1 -1
  49. package/dist/esm/billing/subscription.shared.resources-config.schemas.d.ts +2 -2
  50. package/dist/esm/billing/subscription.shared.resources-config.schemas.d.ts.map +1 -1
  51. package/dist/esm/billing/subscription.shared.resources-config.schemas.js +54 -1
  52. package/dist/esm/billing/subscription.shared.resources-config.schemas.js.map +1 -1
  53. package/dist/esm/billing/subscription.shared.schemas.d.ts +4 -4
  54. package/dist/esm/billing/subscription.shared.schemas.d.ts.map +1 -1
  55. package/dist/esm/billing/subscription.shared.schemas.js +6 -2
  56. package/dist/esm/billing/subscription.shared.schemas.js.map +1 -1
  57. package/dist/esm/billing/usage-record.shared.resources-config.schemas.d.ts +1 -1
  58. package/dist/esm/billing/usage-record.shared.resources-config.schemas.d.ts.map +1 -1
  59. package/dist/esm/billing/usage-record.shared.resources-config.schemas.js +39 -0
  60. package/dist/esm/billing/usage-record.shared.resources-config.schemas.js.map +1 -1
  61. package/dist/esm/billing/usage-record.shared.schemas.d.ts +11 -7
  62. package/dist/esm/billing/usage-record.shared.schemas.d.ts.map +1 -1
  63. package/dist/esm/billing/usage-record.shared.schemas.js +29 -6
  64. package/dist/esm/billing/usage-record.shared.schemas.js.map +1 -1
  65. package/dist/esm/companion/provider-discovery.shared.schemas.d.ts +69 -2
  66. package/dist/esm/companion/provider-discovery.shared.schemas.d.ts.map +1 -1
  67. package/dist/esm/companion/provider-discovery.shared.schemas.js +20 -1
  68. package/dist/esm/companion/provider-discovery.shared.schemas.js.map +1 -1
  69. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.d.ts +85 -0
  70. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.d.ts.map +1 -0
  71. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.js +157 -0
  72. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.js.map +1 -0
  73. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.d.ts.map +1 -1
  74. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.js +35 -2
  75. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.js.map +1 -1
  76. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.d.ts +23 -0
  77. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.d.ts.map +1 -1
  78. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.js +56 -0
  79. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.js.map +1 -1
  80. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.d.ts +541 -20
  81. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.d.ts.map +1 -1
  82. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.js +605 -23
  83. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.js.map +1 -1
  84. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.d.ts.map +1 -1
  85. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.js +96 -3
  86. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.js.map +1 -1
  87. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.d.ts +49 -0
  88. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.d.ts.map +1 -1
  89. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.js +124 -1
  90. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.js.map +1 -1
  91. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.d.ts +11 -3
  92. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.d.ts.map +1 -1
  93. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.js +11 -3
  94. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.js.map +1 -1
  95. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.d.ts +94 -0
  96. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.d.ts.map +1 -0
  97. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.js +211 -0
  98. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.js.map +1 -0
  99. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.d.ts +67 -12
  100. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.d.ts.map +1 -1
  101. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.js +95 -8
  102. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.js.map +1 -1
  103. package/dist/esm/compliance/privacy/privacy.shared.schemas.d.ts +17 -0
  104. package/dist/esm/compliance/privacy/privacy.shared.schemas.d.ts.map +1 -1
  105. package/dist/esm/compliance/privacy/privacy.shared.schemas.js +27 -4
  106. package/dist/esm/compliance/privacy/privacy.shared.schemas.js.map +1 -1
  107. package/dist/esm/compliance/privacy/redaction.shared.schemas.d.ts +89 -16
  108. package/dist/esm/compliance/privacy/redaction.shared.schemas.d.ts.map +1 -1
  109. package/dist/esm/compliance/privacy/redaction.shared.schemas.js +101 -15
  110. package/dist/esm/compliance/privacy/redaction.shared.schemas.js.map +1 -1
  111. package/dist/esm/compliance/privacy/subject-export.shared.schemas.d.ts.map +1 -1
  112. package/dist/esm/compliance/privacy/subject-export.shared.schemas.js +12 -5
  113. package/dist/esm/compliance/privacy/subject-export.shared.schemas.js.map +1 -1
  114. package/dist/esm/config/analytics-value-moments.shared.schemas.d.ts +21 -0
  115. package/dist/esm/config/analytics-value-moments.shared.schemas.d.ts.map +1 -1
  116. package/dist/esm/config/analytics-value-moments.shared.schemas.js +20 -0
  117. package/dist/esm/config/analytics-value-moments.shared.schemas.js.map +1 -1
  118. package/dist/esm/config/app-configuration-shared.shared.schemas.d.ts +9 -5
  119. package/dist/esm/config/app-configuration-shared.shared.schemas.d.ts.map +1 -1
  120. package/dist/esm/config/app-configuration-shared.shared.schemas.js +29 -0
  121. package/dist/esm/config/app-configuration-shared.shared.schemas.js.map +1 -1
  122. package/dist/esm/config/auth-config-resolution.shared.utils.d.ts +8 -1
  123. package/dist/esm/config/auth-config-resolution.shared.utils.d.ts.map +1 -1
  124. package/dist/esm/config/auth-config-resolution.shared.utils.js +29 -0
  125. package/dist/esm/config/auth-config-resolution.shared.utils.js.map +1 -1
  126. package/dist/esm/config/entity-identity-config.shared.schemas.d.ts +95 -17
  127. package/dist/esm/config/entity-identity-config.shared.schemas.d.ts.map +1 -1
  128. package/dist/esm/config/entity-identity-config.shared.schemas.js +86 -8
  129. package/dist/esm/config/entity-identity-config.shared.schemas.js.map +1 -1
  130. package/dist/esm/config/frontend/chart-definition.shared.schemas.d.ts +12 -12
  131. package/dist/esm/config/frontend/navigation.shared.schemas.d.ts +33 -0
  132. package/dist/esm/config/frontend/navigation.shared.schemas.d.ts.map +1 -1
  133. package/dist/esm/config/frontend/navigation.shared.schemas.js +32 -0
  134. package/dist/esm/config/frontend/navigation.shared.schemas.js.map +1 -1
  135. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.d.ts +40 -1
  136. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.d.ts.map +1 -1
  137. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.js +40 -1
  138. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.js.map +1 -1
  139. package/dist/esm/external-data/external-data-pipeline.shared.schemas.d.ts +57 -11
  140. package/dist/esm/external-data/external-data-pipeline.shared.schemas.d.ts.map +1 -1
  141. package/dist/esm/external-data/external-data-pipeline.shared.schemas.js.map +1 -1
  142. package/dist/esm/external-providers/engine-capabilities.shared.schemas.d.ts +109 -64
  143. package/dist/esm/external-providers/engine-capabilities.shared.schemas.d.ts.map +1 -1
  144. package/dist/esm/external-providers/engine-capabilities.shared.schemas.js +200 -19
  145. package/dist/esm/external-providers/engine-capabilities.shared.schemas.js.map +1 -1
  146. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.d.ts +15 -3
  147. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.d.ts.map +1 -1
  148. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.js +32 -7
  149. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.js.map +1 -1
  150. package/dist/esm/external-providers/frontend-bootstrap.shared.schemas.d.ts +84 -7
  151. package/dist/esm/external-providers/frontend-bootstrap.shared.schemas.d.ts.map +1 -1
  152. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.d.ts +59 -0
  153. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.d.ts.map +1 -0
  154. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.js +61 -0
  155. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.js.map +1 -0
  156. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.d.ts +97 -0
  157. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.d.ts.map +1 -0
  158. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.js +41 -0
  159. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.js.map +1 -0
  160. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.d.ts +148 -2
  161. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.d.ts.map +1 -1
  162. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.js +56 -1
  163. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.js.map +1 -1
  164. package/dist/esm/external-providers/provider-capability.shared.schemas.d.ts +9 -31
  165. package/dist/esm/external-providers/provider-capability.shared.schemas.d.ts.map +1 -1
  166. package/dist/esm/external-providers/provider-capability.shared.schemas.js +8 -5
  167. package/dist/esm/external-providers/provider-capability.shared.schemas.js.map +1 -1
  168. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.d.ts +18 -8
  169. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.d.ts.map +1 -1
  170. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.js +9 -4
  171. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.js.map +1 -1
  172. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.d.ts +338 -0
  173. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.d.ts.map +1 -0
  174. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.js +332 -0
  175. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.js.map +1 -0
  176. package/dist/esm/external-providers/provider-metadata.shared.schemas.d.ts +178 -9
  177. package/dist/esm/external-providers/provider-metadata.shared.schemas.d.ts.map +1 -1
  178. package/dist/esm/external-providers/provider-metadata.shared.schemas.js +181 -9
  179. package/dist/esm/external-providers/provider-metadata.shared.schemas.js.map +1 -1
  180. package/dist/esm/external-providers/provider-protocol.shared.schemas.d.ts +7 -5
  181. package/dist/esm/external-providers/provider-protocol.shared.schemas.d.ts.map +1 -1
  182. package/dist/esm/external-providers/provider-protocol.shared.schemas.js +7 -5
  183. package/dist/esm/external-providers/provider-protocol.shared.schemas.js.map +1 -1
  184. package/dist/esm/external-providers/provider-tier-rule.shared.utils.d.ts +40 -0
  185. package/dist/esm/external-providers/provider-tier-rule.shared.utils.d.ts.map +1 -0
  186. package/dist/esm/external-providers/provider-tier-rule.shared.utils.js +80 -0
  187. package/dist/esm/external-providers/provider-tier-rule.shared.utils.js.map +1 -0
  188. package/dist/esm/features/core-feature-definitions.shared.d.ts.map +1 -1
  189. package/dist/esm/features/core-feature-definitions.shared.js +7 -1
  190. package/dist/esm/features/core-feature-definitions.shared.js.map +1 -1
  191. package/dist/esm/features/feature-builders.shared.d.ts +32 -0
  192. package/dist/esm/features/feature-builders.shared.d.ts.map +1 -1
  193. package/dist/esm/features/feature-builders.shared.js +32 -0
  194. package/dist/esm/features/feature-builders.shared.js.map +1 -1
  195. package/dist/esm/features/user-features.shared.resources-config.schemas.d.ts +1 -1
  196. package/dist/esm/features/user-features.shared.resources-config.schemas.d.ts.map +1 -1
  197. package/dist/esm/features/user-features.shared.resources-config.schemas.js +48 -0
  198. package/dist/esm/features/user-features.shared.resources-config.schemas.js.map +1 -1
  199. package/dist/esm/files/file-upload-grant.shared.schemas.d.ts +156 -0
  200. package/dist/esm/files/file-upload-grant.shared.schemas.d.ts.map +1 -0
  201. package/dist/esm/files/file-upload-grant.shared.schemas.js +175 -0
  202. package/dist/esm/files/file-upload-grant.shared.schemas.js.map +1 -0
  203. package/dist/esm/files/files.shared.schemas.d.ts +52 -4
  204. package/dist/esm/files/files.shared.schemas.d.ts.map +1 -1
  205. package/dist/esm/files/files.shared.schemas.js +55 -4
  206. package/dist/esm/files/files.shared.schemas.js.map +1 -1
  207. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.d.ts +1 -1
  208. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.d.ts.map +1 -1
  209. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.js +33 -0
  210. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.js.map +1 -1
  211. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.schemas.d.ts.map +1 -1
  212. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.schemas.js +6 -2
  213. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.schemas.js.map +1 -1
  214. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.d.ts +1 -1
  215. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.d.ts.map +1 -1
  216. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.js +53 -0
  217. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.js.map +1 -1
  218. package/dist/esm/flows-actors/actors.shared.schemas.d.ts.map +1 -1
  219. package/dist/esm/flows-actors/actors.shared.schemas.js +3 -2
  220. package/dist/esm/flows-actors/actors.shared.schemas.js.map +1 -1
  221. package/dist/esm/flows-actors/agents.shared.schemas.d.ts +54 -5
  222. package/dist/esm/flows-actors/agents.shared.schemas.d.ts.map +1 -1
  223. package/dist/esm/flows-actors/agents.shared.schemas.js.map +1 -1
  224. package/dist/esm/flows-actors/apps-blueprint/apps-blueprint.shared.schemas.d.ts +6 -6
  225. package/dist/esm/flows-actors/deliberation.shared.schemas.d.ts +0 -3
  226. package/dist/esm/flows-actors/deliberation.shared.schemas.d.ts.map +1 -1
  227. package/dist/esm/flows-actors/deliberation.shared.schemas.js +0 -5
  228. package/dist/esm/flows-actors/deliberation.shared.schemas.js.map +1 -1
  229. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.d.ts +1 -1
  230. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.d.ts.map +1 -1
  231. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.js +43 -0
  232. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.js.map +1 -1
  233. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.d.ts +14 -0
  234. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.d.ts.map +1 -1
  235. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.js +48 -6
  236. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.js.map +1 -1
  237. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.d.ts +1 -1
  238. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.d.ts.map +1 -1
  239. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.js +41 -0
  240. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.js.map +1 -1
  241. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.d.ts +0 -7
  242. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.d.ts.map +1 -1
  243. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.js +23 -13
  244. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.js.map +1 -1
  245. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.d.ts +19 -0
  246. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.d.ts.map +1 -1
  247. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.js +33 -0
  248. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.js.map +1 -1
  249. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.d.ts +14 -9
  250. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.d.ts.map +1 -1
  251. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.js +14 -9
  252. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.js.map +1 -1
  253. package/dist/esm/flows-actors/flows-actors.system.shared.schemas.d.ts.map +1 -1
  254. package/dist/esm/flows-actors/flows-actors.system.shared.schemas.js +3 -2
  255. package/dist/esm/flows-actors/flows-actors.system.shared.schemas.js.map +1 -1
  256. package/dist/esm/flows-actors/flows.shared.schemas.d.ts.map +1 -1
  257. package/dist/esm/flows-actors/flows.shared.schemas.js +3 -2
  258. package/dist/esm/flows-actors/flows.shared.schemas.js.map +1 -1
  259. package/dist/esm/flows-actors/mcp-servers.shared.schemas.d.ts +128 -0
  260. package/dist/esm/flows-actors/mcp-servers.shared.schemas.d.ts.map +1 -0
  261. package/dist/esm/flows-actors/mcp-servers.shared.schemas.js +142 -0
  262. package/dist/esm/flows-actors/mcp-servers.shared.schemas.js.map +1 -0
  263. package/dist/esm/flows-actors/meta-workflows/budget-authority.meta-workflows.shared.schemas.d.ts +0 -3
  264. package/dist/esm/flows-actors/meta-workflows/budget-authority.meta-workflows.shared.schemas.d.ts.map +1 -1
  265. package/dist/esm/flows-actors/meta-workflows/budget-authority.meta-workflows.shared.schemas.js +1 -4
  266. package/dist/esm/flows-actors/meta-workflows/budget-authority.meta-workflows.shared.schemas.js.map +1 -1
  267. package/dist/esm/flows-actors/meta-workflows/context-selection.meta-workflows.shared.schemas.d.ts +0 -16
  268. package/dist/esm/flows-actors/meta-workflows/context-selection.meta-workflows.shared.schemas.d.ts.map +1 -1
  269. package/dist/esm/flows-actors/meta-workflows/context-selection.meta-workflows.shared.schemas.js +1 -17
  270. package/dist/esm/flows-actors/meta-workflows/context-selection.meta-workflows.shared.schemas.js.map +1 -1
  271. package/dist/esm/flows-actors/meta-workflows/decisions.meta-workflows.shared.schemas.d.ts +3 -3
  272. package/dist/esm/flows-actors/meta-workflows/decisions.meta-workflows.shared.schemas.js +3 -3
  273. package/dist/esm/flows-actors/meta-workflows/decisions.meta-workflows.shared.schemas.js.map +1 -1
  274. package/dist/esm/flows-actors/meta-workflows/execution-binding-common.meta-workflows.shared.schemas.d.ts +2 -8
  275. package/dist/esm/flows-actors/meta-workflows/execution-binding-common.meta-workflows.shared.schemas.d.ts.map +1 -1
  276. package/dist/esm/flows-actors/meta-workflows/execution-binding-common.meta-workflows.shared.schemas.js +4 -15
  277. package/dist/esm/flows-actors/meta-workflows/execution-binding-common.meta-workflows.shared.schemas.js.map +1 -1
  278. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.d.ts +1 -1
  279. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.d.ts.map +1 -1
  280. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.js +51 -0
  281. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.js.map +1 -1
  282. package/dist/esm/guidance/guidance-state.shared.schemas.d.ts.map +1 -1
  283. package/dist/esm/guidance/guidance-state.shared.schemas.js +8 -2
  284. package/dist/esm/guidance/guidance-state.shared.schemas.js.map +1 -1
  285. package/dist/esm/guidance/guidance-state.shared.utils.d.ts.map +1 -1
  286. package/dist/esm/guidance/guidance-state.shared.utils.js +1 -0
  287. package/dist/esm/guidance/guidance-state.shared.utils.js.map +1 -1
  288. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.d.ts +1 -1
  289. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.d.ts.map +1 -1
  290. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.js +51 -0
  291. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.js.map +1 -1
  292. package/dist/esm/guidance/lifecycle-state.shared.schemas.d.ts.map +1 -1
  293. package/dist/esm/guidance/lifecycle-state.shared.schemas.js +28 -3
  294. package/dist/esm/guidance/lifecycle-state.shared.schemas.js.map +1 -1
  295. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.d.ts +9 -1
  296. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.d.ts.map +1 -1
  297. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.js +51 -0
  298. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.js.map +1 -1
  299. package/dist/esm/guidance/progression-state.shared.schemas.d.ts +46 -0
  300. package/dist/esm/guidance/progression-state.shared.schemas.d.ts.map +1 -1
  301. package/dist/esm/guidance/progression-state.shared.schemas.js +67 -4
  302. package/dist/esm/guidance/progression-state.shared.schemas.js.map +1 -1
  303. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.d.ts +356 -52
  304. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.d.ts.map +1 -1
  305. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.js +166 -39
  306. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.js.map +1 -1
  307. package/dist/esm/index.d.ts +15 -0
  308. package/dist/esm/index.d.ts.map +1 -1
  309. package/dist/esm/index.js +15 -0
  310. package/dist/esm/index.js.map +1 -1
  311. package/dist/esm/notifications/email/email-template-registry.shared.schemas.d.ts +11 -2
  312. package/dist/esm/notifications/email/email-template-registry.shared.schemas.d.ts.map +1 -1
  313. package/dist/esm/notifications/email/email-template-registry.shared.schemas.js.map +1 -1
  314. package/dist/esm/notifications/email/email-template.shared.enums.d.ts +15 -0
  315. package/dist/esm/notifications/email/email-template.shared.enums.d.ts.map +1 -1
  316. package/dist/esm/notifications/email/email-template.shared.enums.js +15 -0
  317. package/dist/esm/notifications/email/email-template.shared.enums.js.map +1 -1
  318. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.d.ts +70 -0
  319. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.d.ts.map +1 -0
  320. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.js +71 -0
  321. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.js.map +1 -0
  322. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.d.ts +1 -0
  323. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.d.ts.map +1 -1
  324. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.js +19 -0
  325. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.js.map +1 -1
  326. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.d.ts +30 -0
  327. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.d.ts.map +1 -1
  328. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.js +65 -1
  329. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.js.map +1 -1
  330. package/dist/esm/notifications/notification-badges.core.definitions.d.ts +6 -4
  331. package/dist/esm/notifications/notification-badges.core.definitions.d.ts.map +1 -1
  332. package/dist/esm/notifications/notification-badges.core.definitions.js +6 -4
  333. package/dist/esm/notifications/notification-badges.core.definitions.js.map +1 -1
  334. package/dist/esm/notifications/notification-badges.schemas.d.ts +167 -5
  335. package/dist/esm/notifications/notification-badges.schemas.d.ts.map +1 -1
  336. package/dist/esm/notifications/notification-badges.schemas.js +191 -6
  337. package/dist/esm/notifications/notification-badges.schemas.js.map +1 -1
  338. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.d.ts +1 -1
  339. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.d.ts.map +1 -1
  340. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.js +36 -0
  341. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.js.map +1 -1
  342. package/dist/esm/notifications/notifications.shared.schemas.d.ts +107 -0
  343. package/dist/esm/notifications/notifications.shared.schemas.d.ts.map +1 -1
  344. package/dist/esm/notifications/notifications.shared.schemas.js +149 -1
  345. package/dist/esm/notifications/notifications.shared.schemas.js.map +1 -1
  346. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.d.ts +1 -1
  347. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.d.ts.map +1 -1
  348. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.js +44 -0
  349. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.js.map +1 -1
  350. package/dist/esm/organizations/organization-members.shared.schemas.d.ts.map +1 -1
  351. package/dist/esm/organizations/organization-members.shared.schemas.js +15 -4
  352. package/dist/esm/organizations/organization-members.shared.schemas.js.map +1 -1
  353. package/dist/esm/organizations/organization-notifications.shared.schemas.d.ts.map +1 -1
  354. package/dist/esm/organizations/organization-notifications.shared.schemas.js +22 -1
  355. package/dist/esm/organizations/organization-notifications.shared.schemas.js.map +1 -1
  356. package/dist/esm/organizations/organization-preferences.shared.schemas.d.ts +26 -0
  357. package/dist/esm/organizations/organization-preferences.shared.schemas.d.ts.map +1 -1
  358. package/dist/esm/organizations/organization-preferences.shared.schemas.js +25 -0
  359. package/dist/esm/organizations/organization-preferences.shared.schemas.js.map +1 -1
  360. package/dist/esm/organizations/organization-profile.shared.schemas.d.ts +25 -0
  361. package/dist/esm/organizations/organization-profile.shared.schemas.d.ts.map +1 -1
  362. package/dist/esm/organizations/organization-profile.shared.schemas.js +42 -17
  363. package/dist/esm/organizations/organization-profile.shared.schemas.js.map +1 -1
  364. package/dist/esm/organizations/organization-unit-narrowing.shared.d.ts +3 -2
  365. package/dist/esm/organizations/organization-unit-narrowing.shared.d.ts.map +1 -1
  366. package/dist/esm/organizations/organization-unit-narrowing.shared.js +9 -2
  367. package/dist/esm/organizations/organization-unit-narrowing.shared.js.map +1 -1
  368. package/dist/esm/organizations/organizations.shared.resources-config.schemas.d.ts.map +1 -1
  369. package/dist/esm/organizations/organizations.shared.resources-config.schemas.js +35 -12
  370. package/dist/esm/organizations/organizations.shared.resources-config.schemas.js.map +1 -1
  371. package/dist/esm/public-runtime/index.d.ts +49 -2
  372. package/dist/esm/public-runtime/index.d.ts.map +1 -1
  373. package/dist/esm/public-runtime/index.js +48 -1
  374. package/dist/esm/public-runtime/index.js.map +1 -1
  375. package/dist/esm/queue/jobs.shared.resources-config.schemas.d.ts +6 -5
  376. package/dist/esm/queue/jobs.shared.resources-config.schemas.d.ts.map +1 -1
  377. package/dist/esm/queue/jobs.shared.resources-config.schemas.js +23 -5
  378. package/dist/esm/queue/jobs.shared.resources-config.schemas.js.map +1 -1
  379. package/dist/esm/queue/jobs.shared.schemas.d.ts +16 -3
  380. package/dist/esm/queue/jobs.shared.schemas.d.ts.map +1 -1
  381. package/dist/esm/queue/jobs.shared.schemas.js +16 -3
  382. package/dist/esm/queue/jobs.shared.schemas.js.map +1 -1
  383. package/dist/esm/requests/manual-controllers-routes-documentation.d.ts +137 -0
  384. package/dist/esm/requests/manual-controllers-routes-documentation.d.ts.map +1 -0
  385. package/dist/esm/requests/manual-controllers-routes-documentation.js +1201 -0
  386. package/dist/esm/requests/manual-controllers-routes-documentation.js.map +1 -0
  387. package/dist/esm/requests/manual-controllers-routes-urls.d.ts +67 -0
  388. package/dist/esm/requests/manual-controllers-routes-urls.d.ts.map +1 -1
  389. package/dist/esm/requests/manual-controllers-routes-urls.js +78 -0
  390. package/dist/esm/requests/manual-controllers-routes-urls.js.map +1 -1
  391. package/dist/esm/requests/rate-limits.shared.schemas.d.ts +11 -1
  392. package/dist/esm/requests/rate-limits.shared.schemas.d.ts.map +1 -1
  393. package/dist/esm/requests/rate-limits.shared.schemas.js +11 -1
  394. package/dist/esm/requests/rate-limits.shared.schemas.js.map +1 -1
  395. package/dist/esm/requests/websocket.shared.schemas.d.ts +86 -4
  396. package/dist/esm/requests/websocket.shared.schemas.d.ts.map +1 -1
  397. package/dist/esm/requests/websocket.shared.schemas.js +138 -0
  398. package/dist/esm/requests/websocket.shared.schemas.js.map +1 -1
  399. package/dist/esm/resources/collection-query-parameters.shared.d.ts +22 -0
  400. package/dist/esm/resources/collection-query-parameters.shared.d.ts.map +1 -0
  401. package/dist/esm/resources/collection-query-parameters.shared.js +22 -0
  402. package/dist/esm/resources/collection-query-parameters.shared.js.map +1 -0
  403. package/dist/esm/resources/resources-config.shared.factory.d.ts +1 -0
  404. package/dist/esm/resources/resources-config.shared.factory.d.ts.map +1 -1
  405. package/dist/esm/resources/resources-config.shared.factory.js +189 -31
  406. package/dist/esm/resources/resources-config.shared.factory.js.map +1 -1
  407. package/dist/esm/resources/resources-config.shared.schemas.d.ts +395 -92
  408. package/dist/esm/resources/resources-config.shared.schemas.d.ts.map +1 -1
  409. package/dist/esm/resources/resources-config.shared.schemas.js +109 -20
  410. package/dist/esm/resources/resources-config.shared.schemas.js.map +1 -1
  411. package/dist/esm/resources/resources-registry.shared.core.definitions.d.ts.map +1 -1
  412. package/dist/esm/resources/resources-registry.shared.core.definitions.js +97 -5
  413. package/dist/esm/resources/resources-registry.shared.core.definitions.js.map +1 -1
  414. package/dist/esm/resources/resources-relationships.shared.factory.d.ts.map +1 -1
  415. package/dist/esm/resources/resources-relationships.shared.factory.js +15 -0
  416. package/dist/esm/resources/resources-relationships.shared.factory.js.map +1 -1
  417. package/dist/esm/resources/resources.shared.core.definitions.d.ts +37 -0
  418. package/dist/esm/resources/resources.shared.core.definitions.d.ts.map +1 -1
  419. package/dist/esm/resources/resources.shared.core.definitions.js +51 -0
  420. package/dist/esm/resources/resources.shared.core.definitions.js.map +1 -1
  421. package/dist/esm/resources/resources.shared.schemas.d.ts +11 -2
  422. package/dist/esm/resources/resources.shared.schemas.d.ts.map +1 -1
  423. package/dist/esm/resources/resources.shared.schemas.js +34 -3
  424. package/dist/esm/resources/resources.shared.schemas.js.map +1 -1
  425. package/dist/esm/resources/utils/field-value-disclosure.utils.d.ts +51 -0
  426. package/dist/esm/resources/utils/field-value-disclosure.utils.d.ts.map +1 -0
  427. package/dist/esm/resources/utils/field-value-disclosure.utils.js +53 -0
  428. package/dist/esm/resources/utils/field-value-disclosure.utils.js.map +1 -0
  429. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.d.ts.map +1 -1
  430. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.js +21 -6
  431. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.js.map +1 -1
  432. package/dist/esm/resources/utils/resources-summary.utils.d.ts +16 -2
  433. package/dist/esm/resources/utils/resources-summary.utils.d.ts.map +1 -1
  434. package/dist/esm/resources/utils/resources-summary.utils.js +19 -5
  435. package/dist/esm/resources/utils/resources-summary.utils.js.map +1 -1
  436. package/dist/esm/resources/utils/shared-persistence-collection.utils.d.ts.map +1 -1
  437. package/dist/esm/resources/utils/shared-persistence-collection.utils.js +11 -0
  438. package/dist/esm/resources/utils/shared-persistence-collection.utils.js.map +1 -1
  439. package/dist/esm/runtime/domain-module.shared.definitions.d.ts +25 -0
  440. package/dist/esm/runtime/domain-module.shared.definitions.d.ts.map +1 -1
  441. package/dist/esm/runtime/domain-module.shared.definitions.js.map +1 -1
  442. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.d.ts +1 -0
  443. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.d.ts.map +1 -1
  444. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.js +38 -0
  445. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.js.map +1 -1
  446. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.d.ts +1 -0
  447. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.d.ts.map +1 -1
  448. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.js +38 -0
  449. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.js.map +1 -1
  450. package/dist/esm/security/authentications/authentication.shared.dto.schemas.d.ts +4 -11
  451. package/dist/esm/security/authentications/authentication.shared.dto.schemas.d.ts.map +1 -1
  452. package/dist/esm/security/authentications/authentication.shared.dto.schemas.js +0 -1
  453. package/dist/esm/security/authentications/authentication.shared.dto.schemas.js.map +1 -1
  454. package/dist/esm/security/authentications/authentication.shared.schemas.d.ts +141 -5
  455. package/dist/esm/security/authentications/authentication.shared.schemas.d.ts.map +1 -1
  456. package/dist/esm/security/authentications/authentication.shared.schemas.js +147 -3
  457. package/dist/esm/security/authentications/authentication.shared.schemas.js.map +1 -1
  458. package/dist/esm/security/authentications/consumable-token.shared.schemas.d.ts +17 -1
  459. package/dist/esm/security/authentications/consumable-token.shared.schemas.d.ts.map +1 -1
  460. package/dist/esm/security/authentications/consumable-token.shared.schemas.js +16 -0
  461. package/dist/esm/security/authentications/consumable-token.shared.schemas.js.map +1 -1
  462. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.d.ts +28 -0
  463. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.d.ts.map +1 -0
  464. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.js +28 -0
  465. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.js.map +1 -0
  466. package/dist/esm/security/authentications/registration.shared.dto.schemas.d.ts +1 -0
  467. package/dist/esm/security/authentications/registration.shared.dto.schemas.d.ts.map +1 -1
  468. package/dist/esm/security/authentications/registration.shared.dto.schemas.js +11 -0
  469. package/dist/esm/security/authentications/registration.shared.dto.schemas.js.map +1 -1
  470. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.d.ts +15 -0
  471. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.d.ts.map +1 -1
  472. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.js +21 -4
  473. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.js.map +1 -1
  474. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.d.ts +21 -0
  475. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.d.ts.map +1 -0
  476. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.js +21 -0
  477. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.js.map +1 -0
  478. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.d.ts +61 -1
  479. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.d.ts.map +1 -1
  480. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.js +208 -6
  481. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.js.map +1 -1
  482. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.d.ts +37 -27
  483. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.d.ts.map +1 -1
  484. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.js +134 -12
  485. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.js.map +1 -1
  486. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.d.ts +0 -6
  487. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.d.ts.map +1 -1
  488. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.js +17 -8
  489. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.js.map +1 -1
  490. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.d.ts +1 -1
  491. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.d.ts.map +1 -1
  492. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.js +70 -0
  493. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.js.map +1 -1
  494. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.d.ts +45 -8
  495. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.d.ts.map +1 -1
  496. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.js +56 -10
  497. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.js.map +1 -1
  498. package/dist/esm/security/authorizations/roles.shared.schemas.d.ts +16 -1
  499. package/dist/esm/security/authorizations/roles.shared.schemas.d.ts.map +1 -1
  500. package/dist/esm/security/authorizations/roles.shared.schemas.js +16 -1
  501. package/dist/esm/security/authorizations/roles.shared.schemas.js.map +1 -1
  502. package/dist/esm/security/authorizations/roles.shared.utils.d.ts +54 -0
  503. package/dist/esm/security/authorizations/roles.shared.utils.d.ts.map +1 -1
  504. package/dist/esm/security/authorizations/roles.shared.utils.js +59 -0
  505. package/dist/esm/security/authorizations/roles.shared.utils.js.map +1 -1
  506. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.d.ts +31 -0
  507. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.d.ts.map +1 -0
  508. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.js +198 -0
  509. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.js.map +1 -0
  510. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.d.ts +31 -0
  511. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.d.ts.map +1 -0
  512. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.js +191 -0
  513. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.js.map +1 -0
  514. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.d.ts +250 -0
  515. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.d.ts.map +1 -0
  516. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.js +486 -0
  517. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.js.map +1 -0
  518. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.d.ts +4 -1
  519. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.d.ts.map +1 -1
  520. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.js +29 -0
  521. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.js.map +1 -1
  522. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.d.ts +4 -1
  523. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.d.ts.map +1 -1
  524. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.js +29 -0
  525. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.js.map +1 -1
  526. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.d.ts +67 -0
  527. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.d.ts.map +1 -1
  528. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.js +44 -1
  529. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.js.map +1 -1
  530. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.d.ts +1 -1
  531. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.d.ts.map +1 -1
  532. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.js +35 -0
  533. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.js.map +1 -1
  534. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.d.ts +13 -0
  535. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.d.ts.map +1 -1
  536. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.js +31 -4
  537. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.js.map +1 -1
  538. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.d.ts +1 -1
  539. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.d.ts.map +1 -1
  540. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.js +34 -0
  541. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.js.map +1 -1
  542. package/dist/esm/users/inbound-contacts.shared.schemas.d.ts.map +1 -1
  543. package/dist/esm/users/inbound-contacts.shared.schemas.js +7 -4
  544. package/dist/esm/users/inbound-contacts.shared.schemas.js.map +1 -1
  545. package/dist/esm/users/user-credentials.shared.resources-config.schemas.d.ts +1 -1
  546. package/dist/esm/users/user-credentials.shared.resources-config.schemas.d.ts.map +1 -1
  547. package/dist/esm/users/user-credentials.shared.resources-config.schemas.js +37 -0
  548. package/dist/esm/users/user-credentials.shared.resources-config.schemas.js.map +1 -1
  549. package/dist/esm/users/user-credentials.shared.schemas.d.ts.map +1 -1
  550. package/dist/esm/users/user-credentials.shared.schemas.js +17 -2
  551. package/dist/esm/users/user-credentials.shared.schemas.js.map +1 -1
  552. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.d.ts +1 -1
  553. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.d.ts.map +1 -1
  554. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.js +36 -0
  555. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.js.map +1 -1
  556. package/dist/esm/users/user-identity-links.shared.schemas.d.ts.map +1 -1
  557. package/dist/esm/users/user-identity-links.shared.schemas.js +15 -5
  558. package/dist/esm/users/user-identity-links.shared.schemas.js.map +1 -1
  559. package/dist/esm/users/user-preferences.shared.resources-config.schemas.d.ts +5 -5
  560. package/dist/esm/users/user-preferences.shared.resources-config.schemas.d.ts.map +1 -1
  561. package/dist/esm/users/user-preferences.shared.resources-config.schemas.js +53 -0
  562. package/dist/esm/users/user-preferences.shared.resources-config.schemas.js.map +1 -1
  563. package/dist/esm/users/user-profiles.shared.resources-config.schemas.d.ts +1 -1
  564. package/dist/esm/users/user-profiles.shared.resources-config.schemas.d.ts.map +1 -1
  565. package/dist/esm/users/user-profiles.shared.resources-config.schemas.js +62 -0
  566. package/dist/esm/users/user-profiles.shared.resources-config.schemas.js.map +1 -1
  567. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.d.ts +5 -5
  568. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.d.ts.map +1 -1
  569. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.js +53 -0
  570. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.js.map +1 -1
  571. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.d.ts +1 -1
  572. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.d.ts.map +1 -1
  573. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.js +62 -0
  574. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.js.map +1 -1
  575. package/dist/esm/users/user-self.shared.resources-config.schemas.d.ts.map +1 -1
  576. package/dist/esm/users/user-self.shared.resources-config.schemas.js +33 -3
  577. package/dist/esm/users/user-self.shared.resources-config.schemas.js.map +1 -1
  578. package/dist/esm/users/users.shared.resources-config.schemas.d.ts +17 -1
  579. package/dist/esm/users/users.shared.resources-config.schemas.d.ts.map +1 -1
  580. package/dist/esm/users/users.shared.resources-config.schemas.js +136 -5
  581. package/dist/esm/users/users.shared.resources-config.schemas.js.map +1 -1
  582. package/dist/esm/users/users.shared.schemas.d.ts +62 -12
  583. package/dist/esm/users/users.shared.schemas.d.ts.map +1 -1
  584. package/dist/esm/users/users.shared.schemas.js +79 -23
  585. package/dist/esm/users/users.shared.schemas.js.map +1 -1
  586. package/dist/tsconfig.build.tsbuildinfo +1 -1
  587. package/package.json +5 -6
  588. package/dist/esm/.builder.pid +0 -9
@@ -7,16 +7,24 @@
7
7
  * contracts, no backend behavior. The fields are exactly what a UI needs
8
8
  * to render a provider entry (translation-ready display-name key, optional
9
9
  * legacy fallback label, optional icon ref) plus the stable `ref` used as
10
- * the join key between facet modules.
10
+ * the join key between facet modules — and, since #328, the provider's
11
+ * IDENTITY: which package ships it, which tier it belongs to, which vendor
12
+ * groups it, and where it came from.
11
13
  *
12
- * Phase 0 of the provider-registration refactor introduces this type as
13
- * the single source of truth for provider header information so that the
14
- * cross-facet seam (`FrontendBootstrapBackendService`) can project a
15
- * `BackendProviderModule` into a `FrontendProviderEntry` without ever
16
- * leaking backend-only fields.
14
+ * ## Why identity lives here and not on the ref
17
15
  *
18
- * See `.cursor/plans/provider-registration-refactor-implementation-plan.md`
19
- * §Phase 0.1 for the full rationale.
16
+ * A bare `ref` string cannot say whether a provider is one the engine
17
+ * REQUIRES (a MAIN provider binding an `EngineCapability` slot), one that
18
+ * merely MAY bind a slot as a substitute (EXTENSION), or one of the bulk
19
+ * loaded on demand that must never claim a slot (CATALOGUE). Nor can it say
20
+ * that `microsoft-graph-mail` and `microsoft-teams` are two packages of one
21
+ * vendor sharing an OAuth client. Encoding any of that in the ref's
22
+ * spelling is invisible to the compiler and to every consumer; encoding it
23
+ * as fields is what lets composition ENFORCE the tier rule
24
+ * (`assertProviderTierCoherence`) and lets tooling display and group.
25
+ *
26
+ * The identity fields are REQUIRED. A provider without a tier is a provider
27
+ * nobody has decided about, and "undecided" must not parse as "fine".
20
28
  */
21
29
  import { z } from 'zod';
22
30
  /**
@@ -29,13 +37,145 @@ import { z } from 'zod';
29
37
  export function buildProviderDisplayNameLabelKey(providerRef) {
30
38
  return `providers.${providerRef}.displayName`;
31
39
  }
40
+ /**
41
+ * The three provider tiers (decided 2026-09-05, epic #337).
42
+ *
43
+ * The tier is a DECISION recorded on the module, never inferred from its
44
+ * capabilities at runtime — inference is silent and wrong for a provider
45
+ * such as Odoo, whose empty capability list says nothing about whether the
46
+ * engine depends on it.
47
+ */
48
+ export var ProviderTier;
49
+ (function (ProviderTier) {
50
+ /**
51
+ * Mandatory, engine-shipped. Binds an `EngineCapability` slot the engine
52
+ * itself consumes (email, billing, SMS, the AI slots) or is an SSO login
53
+ * provider the auth subsystem consumes. MAIN is the engine's own set:
54
+ * its origin is always `ENGINE`, and it is what stays in the static
55
+ * engine registry when everything else loads on demand.
56
+ */
57
+ ProviderTier["MAIN"] = "MAIN";
58
+ /**
59
+ * May ALSO bind an engine slot, as a substitute for a MAIN provider
60
+ * (a second email sink, a telemetry sink, an audit sink). Kept distinct
61
+ * from MAIN so the engine's floor is not confused with what happens to
62
+ * be installed.
63
+ */
64
+ ProviderTier["EXTENSION"] = "EXTENSION";
65
+ /**
66
+ * The bulk: integrations with no engine slot, loaded on demand when an
67
+ * application declares them. A CATALOGUE provider may claim only OPEN
68
+ * `ProviderCapability` tokens — never one that maps to an engine slot —
69
+ * which composition enforces.
70
+ */
71
+ ProviderTier["CATALOGUE"] = "CATALOGUE";
72
+ })(ProviderTier || (ProviderTier = {}));
73
+ /** Where a provider module's code comes from. */
74
+ export var ProviderOriginKind;
75
+ (function (ProviderOriginKind) {
76
+ /** Shipped by the framework's own connector packages. */
77
+ ProviderOriginKind["ENGINE"] = "ENGINE";
78
+ /** Authored inside an application (its own `provider-contributions`). */
79
+ ProviderOriginKind["APPLICATION"] = "APPLICATION";
80
+ /**
81
+ * Emitted by the framework packager from an external catalogue source;
82
+ * carries the catalogue provenance so the wrapped upstream artifact can
83
+ * be named, attributed and re-generated.
84
+ */
85
+ ProviderOriginKind["GENERATED"] = "GENERATED";
86
+ })(ProviderOriginKind || (ProviderOriginKind = {}));
87
+ /**
88
+ * External catalogues a build-time MAPPER reads to emit a native Wildo provider package.
89
+ *
90
+ * Every member is a SOURCE that is read, never a runtime the application depends on: the mapper
91
+ * extracts each operation's method, URL template, parameters and auth shape as DATA, and Wildo's
92
+ * own HTTP client executes them. Nothing third-party is installed or executed by a generated
93
+ * application. (An earlier revision of this enum described Activepieces as a set of executable
94
+ * bundles Wildo would WRAP; that model was built, measured and deleted on 2026-09-06 — see
95
+ * `providers-are-scraped-never-wrapped`.)
96
+ *
97
+ * - `ACTIVEPIECES` — the community pieces monorepo. Each piece's actions and triggers call
98
+ * `httpClient.sendRequest({ method, url, body })` in plain TypeScript an AST pass can read.
99
+ * Note the PUBLISHED bundle is NOT a usable input: its metadata carries name, inputs and auth
100
+ * but not the endpoint, which lives inside the compiled `run`.
101
+ * - `SIM` — Sim's tool modules, whose request declaration carries URL and headers the same way.
102
+ * Their `transformResponse` / `postProcess` are functions and are deliberately not read; response
103
+ * shaping stays Wildo's.
104
+ * - `OPENAPI_DOCUMENT` — a vendor-published OpenAPI document, the second mapper input feeding the
105
+ * same output shape. Authoritative where it exists, since it is the vendor's own description.
106
+ */
107
+ export var ProviderCatalogueSource;
108
+ (function (ProviderCatalogueSource) {
109
+ ProviderCatalogueSource["ACTIVEPIECES"] = "ACTIVEPIECES";
110
+ ProviderCatalogueSource["SIM"] = "SIM";
111
+ ProviderCatalogueSource["OPENAPI_DOCUMENT"] = "OPENAPI_DOCUMENT";
112
+ })(ProviderCatalogueSource || (ProviderCatalogueSource = {}));
113
+ export const ProviderCatalogueProvenanceSchema = z.object({
114
+ source: z.enum(ProviderCatalogueSource),
115
+ /**
116
+ * The upstream artifact read, addressed the way its catalogue addresses it: the piece's
117
+ * directory or package name, the Sim tool's module, the OpenAPI document's path.
118
+ */
119
+ sourceRef: z.string().min(1),
120
+ /**
121
+ * The exact upstream revision read — a source-control revision for a monorepo catalogue, a
122
+ * document version for an OpenAPI input. A re-generation pins a new one, which is what makes a
123
+ * regenerated package's diff attributable to a specific upstream movement.
124
+ */
125
+ sourceVersion: z.string().min(1),
126
+ });
127
+ /**
128
+ * Origin as ONE object with a `kind` and a provenance that is REQUIRED exactly when the kind is
129
+ * `GENERATED` (and forbidden otherwise), enforced by the refinement below.
130
+ *
131
+ * Not a `z.discriminatedUnion`, deliberately: under `strictNullChecks: false` — how the engine
132
+ * packages compile — Zod 4 infers a union-typed object key as OPTIONAL (the members' `optout`
133
+ * collapses to `"optional"` once `undefined` is erased), so `metadata.origin` would type as
134
+ * omittable in every engine consumer while the runtime refused its absence. A plain object
135
+ * infers as required in both modes; the invariant the union expressed lives in the refinement
136
+ * and in the `ProviderOrigin` type below.
137
+ */
138
+ export const ProviderOriginSchema = z
139
+ .object({
140
+ kind: z.enum(ProviderOriginKind),
141
+ /** Present iff `kind === GENERATED`. */
142
+ catalogue: ProviderCatalogueProvenanceSchema.optional(),
143
+ })
144
+ .superRefine((origin, ctx) => {
145
+ if (origin.kind === ProviderOriginKind.GENERATED && origin.catalogue === undefined) {
146
+ ctx.addIssue({ code: 'custom', path: ['catalogue'], message: 'A GENERATED origin must carry its catalogue provenance.' });
147
+ }
148
+ if (origin.kind !== ProviderOriginKind.GENERATED && origin.catalogue !== undefined) {
149
+ ctx.addIssue({ code: 'custom', path: ['catalogue'], message: `Only a GENERATED origin carries catalogue provenance (kind is ${origin.kind}).` });
150
+ }
151
+ });
152
+ /** The one engine origin value, so 22 modules do not each spell it. */
153
+ export const ENGINE_PROVIDER_ORIGIN = Object.freeze({ kind: ProviderOriginKind.ENGINE });
32
154
  export const ProviderMetadataSchema = z.object({
33
155
  /**
34
156
  * Stable identifier for the provider, e.g. `'resend'`, `'stripe'`,
35
157
  * `'openai'`. Used as the join key across facet modules and as the
36
158
  * map key inside `BackendProviderRegistry.modules`.
37
159
  */
38
- ref: z.string(),
160
+ ref: z.string().min(1),
161
+ /**
162
+ * The npm package that ships this provider's module(s), e.g.
163
+ * `@wildo-ai/external-connectors-private` for an engine provider or
164
+ * `@wildo-ai/provider-slack` for a per-provider package. One package,
165
+ * several facet barrels — this is the package, not a barrel.
166
+ */
167
+ packageName: z.string().min(1),
168
+ /** See {@link ProviderTier}. A recorded decision, never inferred. */
169
+ tier: z.enum(ProviderTier),
170
+ /**
171
+ * Vendor grouping. Equal to `ref` for a single-package vendor; the shared
172
+ * name for a sub-cut vendor (`vendor: 'microsoft'` on both
173
+ * `microsoft-graph-mail` and `microsoft-teams`), which is what lets an
174
+ * OAuth client or a secret be shared by reference across sub-packages.
175
+ */
176
+ vendor: z.string().min(1),
177
+ /** See {@link ProviderOriginSchema}. */
178
+ origin: ProviderOriginSchema,
39
179
  /**
40
180
  * Translation-ready key for the provider display name.
41
181
  *
@@ -55,4 +195,36 @@ export const ProviderMetadataSchema = z.object({
55
195
  */
56
196
  iconRef: z.string().optional(),
57
197
  });
198
+ /**
199
+ * The identity half of {@link ProviderMetadataSchema} on its own — what a
200
+ * companion contribution carries so tooling can display tiers and group
201
+ * vendors without loading a provider's runtime module.
202
+ */
203
+ export const ProviderIdentitySchema = ProviderMetadataSchema.pick({
204
+ packageName: true,
205
+ tier: true,
206
+ vendor: true,
207
+ origin: true,
208
+ });
209
+ /**
210
+ * The one way a provider module authors its metadata.
211
+ *
212
+ * Derives `displayNameLabelKey` from the ref (every module used to call
213
+ * `buildProviderDisplayNameLabelKey` by hand), defaults `vendor` to the ref,
214
+ * and parses the result so an incomplete identity fails at MODULE LOAD —
215
+ * in the package that owns the module — rather than at the first consumer
216
+ * that reads a field which is not there.
217
+ */
218
+ export function defineProviderMetadata(input) {
219
+ return ProviderMetadataSchema.parse({
220
+ ref: input.ref,
221
+ packageName: input.packageName,
222
+ tier: input.tier,
223
+ vendor: input.vendor ?? input.ref,
224
+ origin: input.origin,
225
+ displayNameLabelKey: buildProviderDisplayNameLabelKey(input.ref),
226
+ ...(input.displayName === undefined ? {} : { displayName: input.displayName }),
227
+ ...(input.iconRef === undefined ? {} : { iconRef: input.iconRef }),
228
+ });
229
+ }
58
230
  //# sourceMappingURL=provider-metadata.shared.schemas.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"provider-metadata.shared.schemas.js","sourceRoot":"","sources":["../../../../src/external-providers/provider-metadata.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;GAMG;AACH,MAAM,UAAU,gCAAgC,CAAC,WAAmB;IAClE,OAAO,aAAa,WAAW,cAAc,CAAC;AAChD,CAAC;AAED,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C;;;;OAIG;IACH,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE;IACf;;;;;OAKG;IACH,mBAAmB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1C;;;OAGG;IACH,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAClC;;;;OAIG;IACH,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC/B,CAAC,CAAC","sourcesContent":["/**\n * `ProviderMetadata` — shared, frontend-safe header carried by every\n * provider module across every facet (backend, frontend-app, techdoc,\n * website).\n *\n * Intentionally **frontend-safe**: holds no secrets, no protocol\n * contracts, no backend behavior. The fields are exactly what a UI needs\n * to render a provider entry (translation-ready display-name key, optional\n * legacy fallback label, optional icon ref) plus the stable `ref` used as\n * the join key between facet modules.\n *\n * Phase 0 of the provider-registration refactor introduces this type as\n * the single source of truth for provider header information so that the\n * cross-facet seam (`FrontendBootstrapBackendService`) can project a\n * `BackendProviderModule` into a `FrontendProviderEntry` without ever\n * leaking backend-only fields.\n *\n * See `.cursor/plans/provider-registration-refactor-implementation-plan.md`\n * §Phase 0.1 for the full rationale.\n */\n\nimport { z } from 'zod';\n\n/**\n * Translation key builder for provider display names.\n *\n * Provider modules stay locale-neutral by exporting this stable label key;\n * consuming frontend surfaces resolve it via the app i18n service at render\n * time instead of freezing human copy into generated/runtime artifacts.\n */\nexport function buildProviderDisplayNameLabelKey(providerRef: string): string {\n return `providers.${providerRef}.displayName`;\n}\n\nexport const ProviderMetadataSchema = z.object({\n /**\n * Stable identifier for the provider, e.g. `'resend'`, `'stripe'`,\n * `'openai'`. Used as the join key across facet modules and as the\n * map key inside `BackendProviderRegistry.modules`.\n */\n ref: z.string(),\n /**\n * Translation-ready key for the provider display name.\n *\n * Frontend/public surfaces should prefer this field over embedding\n * locale-bound copy in provider modules or runtime artifacts.\n */\n displayNameLabelKey: z.string().optional(),\n /**\n * Legacy human-readable fallback label for non-i18n-aware consumers.\n * When absent, consumers fall back to the `ref`.\n */\n displayName: z.string().optional(),\n /**\n * Optional icon reference resolved through the frontend icon registry.\n * Stays a string (not a URL or component reference) to keep this type\n * frontend-safe AND portable to non-React surfaces.\n */\n iconRef: z.string().optional(),\n});\n\nexport type ProviderMetadata = z.infer<typeof ProviderMetadataSchema>;\n"]}
1
+ {"version":3,"file":"provider-metadata.shared.schemas.js","sourceRoot":"","sources":["../../../../src/external-providers/provider-metadata.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB;;;;;;GAMG;AACH,MAAM,UAAU,gCAAgC,CAAC,WAAmB;IAClE,OAAO,aAAa,WAAW,cAAc,CAAC;AAChD,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,CAAN,IAAY,YAuBX;AAvBD,WAAY,YAAY;IACtB;;;;;;OAMG;IACH,6BAAa,CAAA;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AAE;CAC/B,CAAC,CAAC;AAIH;;;;GAIG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAG,sBAAsB,CAAC,IAAI,CAAC;IAChE,WAAW,EAAE,IAAI;IACjB,IAAI,EAAE,IAAI;IACV,MAAM,EAAE,IAAI;IACZ,MAAM,EAAE,IAAI;CACb,CAAC,CAAC;AAcH;;;;;;;;GAQG;AACH,MAAM,UAAU,sBAAsB,CAAC,KAAkC;IACvE,OAAO,sBAAsB,CAAC,KAAK,CAAC;QAClC,GAAG,EAAE,KAAK,CAAC,GAAG;QACd,WAAW,EAAE,KAAK,CAAC,WAAW;QAC9B,IAAI,EAAE,KAAK,CAAC,IAAI;QAChB,MAAM,EAAE,KAAK,CAAC,MAAM,IAAI,KAAK,CAAC,GAAG;QACjC,MAAM,EAAE,KAAK,CAAC,MAAM;QACpB,mBAAmB,EAAE,gCAAgC,CAAC,KAAK,CAAC,GAAG,CAAC;QAChE,GAAG,CAAC,KAAK,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,KAAK,CAAC,WAAW,EAAE,CAAC;QAC9E,GAAG,CAAC,KAAK,CAAC,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,CAAC;KACnE,CAAqB,CAAC;AACzB,CAAC","sourcesContent":["/**\n * `ProviderMetadata` — shared, frontend-safe header carried by every\n * provider module across every facet (backend, frontend-app, techdoc,\n * website).\n *\n * Intentionally **frontend-safe**: holds no secrets, no protocol\n * contracts, no backend behavior. The fields are exactly what a UI needs\n * to render a provider entry (translation-ready display-name key, optional\n * legacy fallback label, optional icon ref) plus the stable `ref` used as\n * the join key between facet modules — and, since #328, the provider's\n * IDENTITY: which package ships it, which tier it belongs to, which vendor\n * groups it, and where it came from.\n *\n * ## Why identity lives here and not on the ref\n *\n * A bare `ref` string cannot say whether a provider is one the engine\n * REQUIRES (a MAIN provider binding an `EngineCapability` slot), one that\n * merely MAY bind a slot as a substitute (EXTENSION), or one of the bulk\n * loaded on demand that must never claim a slot (CATALOGUE). Nor can it say\n * that `microsoft-graph-mail` and `microsoft-teams` are two packages of one\n * vendor sharing an OAuth client. Encoding any of that in the ref's\n * spelling is invisible to the compiler and to every consumer; encoding it\n * as fields is what lets composition ENFORCE the tier rule\n * (`assertProviderTierCoherence`) and lets tooling display and group.\n *\n * The identity fields are REQUIRED. A provider without a tier is a provider\n * nobody has decided about, and \"undecided\" must not parse as \"fine\".\n */\n\nimport { z } from 'zod';\n\n\n/**\n * Translation key builder for provider display names.\n *\n * Provider modules stay locale-neutral by exporting this stable label key;\n * consuming frontend surfaces resolve it via the app i18n service at render\n * time instead of freezing human copy into generated/runtime artifacts.\n */\nexport function buildProviderDisplayNameLabelKey(providerRef: string): string {\n return `providers.${providerRef}.displayName`;\n}\n\n/**\n * The three provider tiers (decided 2026-09-05, epic #337).\n *\n * The tier is a DECISION recorded on the module, never inferred from its\n * capabilities at runtime — inference is silent and wrong for a provider\n * such as Odoo, whose empty capability list says nothing about whether the\n * engine depends on it.\n */\nexport enum ProviderTier {\n /**\n * Mandatory, engine-shipped. Binds an `EngineCapability` slot the engine\n * itself consumes (email, billing, SMS, the AI slots) or is an SSO login\n * provider the auth subsystem consumes. MAIN is the engine's own set:\n * its origin is always `ENGINE`, and it is what stays in the static\n * engine registry when everything else loads on demand.\n */\n MAIN = 'MAIN',\n /**\n * May ALSO bind an engine slot, as a substitute for a MAIN provider\n * (a second email sink, a telemetry sink, an audit sink). Kept distinct\n * from MAIN so the engine's floor is not confused with what happens to\n * be installed.\n */\n EXTENSION = 'EXTENSION',\n /**\n * The bulk: integrations with no engine slot, loaded on demand when an\n * application declares them. A CATALOGUE provider may claim only OPEN\n * `ProviderCapability` tokens — never one that maps to an engine slot —\n * which composition enforces.\n */\n CATALOGUE = 'CATALOGUE',\n}\n\n/** Where a provider module's code comes from. */\nexport enum ProviderOriginKind {\n /** Shipped by the framework's own connector packages. */\n ENGINE = 'ENGINE',\n /** Authored inside an application (its own `provider-contributions`). */\n APPLICATION = 'APPLICATION',\n /**\n * Emitted by the framework packager from an external catalogue source;\n * carries the catalogue provenance so the wrapped upstream artifact can\n * be named, attributed and re-generated.\n */\n GENERATED = 'GENERATED',\n}\n\n/**\n * External catalogues a build-time MAPPER reads to emit a native Wildo provider package.\n *\n * Every member is a SOURCE that is read, never a runtime the application depends on: the mapper\n * extracts each operation's method, URL template, parameters and auth shape as DATA, and Wildo's\n * own HTTP client executes them. Nothing third-party is installed or executed by a generated\n * application. (An earlier revision of this enum described Activepieces as a set of executable\n * bundles Wildo would WRAP; that model was built, measured and deleted on 2026-09-06 — see\n * `providers-are-scraped-never-wrapped`.)\n *\n * - `ACTIVEPIECES` — the community pieces monorepo. Each piece's actions and triggers call\n * `httpClient.sendRequest({ method, url, body })` in plain TypeScript an AST pass can read.\n * Note the PUBLISHED bundle is NOT a usable input: its metadata carries name, inputs and auth\n * but not the endpoint, which lives inside the compiled `run`.\n * - `SIM` — Sim's tool modules, whose request declaration carries URL and headers the same way.\n * Their `transformResponse` / `postProcess` are functions and are deliberately not read; response\n * shaping stays Wildo's.\n * - `OPENAPI_DOCUMENT` — a vendor-published OpenAPI document, the second mapper input feeding the\n * same output shape. Authoritative where it exists, since it is the vendor's own description.\n */\nexport enum ProviderCatalogueSource {\n ACTIVEPIECES = 'ACTIVEPIECES',\n SIM = 'SIM',\n OPENAPI_DOCUMENT = 'OPENAPI_DOCUMENT',\n}\n\nexport const ProviderCatalogueProvenanceSchema = z.object({\n source: z.enum(ProviderCatalogueSource),\n /**\n * The upstream artifact read, addressed the way its catalogue addresses it: the piece's\n * directory or package name, the Sim tool's module, the OpenAPI document's path.\n */\n sourceRef: z.string().min(1),\n /**\n * The exact upstream revision read — a source-control revision for a monorepo catalogue, a\n * document version for an OpenAPI input. A re-generation pins a new one, which is what makes a\n * regenerated package's diff attributable to a specific upstream movement.\n */\n sourceVersion: z.string().min(1),\n});\nexport type ProviderCatalogueProvenance = z.infer<typeof ProviderCatalogueProvenanceSchema>;\n\n/**\n * Origin as ONE object with a `kind` and a provenance that is REQUIRED exactly when the kind is\n * `GENERATED` (and forbidden otherwise), enforced by the refinement below.\n *\n * Not a `z.discriminatedUnion`, deliberately: under `strictNullChecks: false` — how the engine\n * packages compile — Zod 4 infers a union-typed object key as OPTIONAL (the members' `optout`\n * collapses to `\"optional\"` once `undefined` is erased), so `metadata.origin` would type as\n * omittable in every engine consumer while the runtime refused its absence. A plain object\n * infers as required in both modes; the invariant the union expressed lives in the refinement\n * and in the `ProviderOrigin` type below.\n */\nexport const ProviderOriginSchema = z\n .object({\n kind: z.enum(ProviderOriginKind),\n /** Present iff `kind === GENERATED`. */\n catalogue: ProviderCatalogueProvenanceSchema.optional(),\n })\n .superRefine((origin, ctx) => {\n if (origin.kind === ProviderOriginKind.GENERATED && origin.catalogue === undefined) {\n ctx.addIssue({ code: 'custom', path: ['catalogue'], message: 'A GENERATED origin must carry its catalogue provenance.' });\n }\n if (origin.kind !== ProviderOriginKind.GENERATED && origin.catalogue !== undefined) {\n ctx.addIssue({ code: 'custom', path: ['catalogue'], message: `Only a GENERATED origin carries catalogue provenance (kind is ${origin.kind}).` });\n }\n });\nexport type ProviderOrigin =\n | { kind: ProviderOriginKind.ENGINE; catalogue?: undefined }\n | { kind: ProviderOriginKind.APPLICATION; catalogue?: undefined }\n | { kind: ProviderOriginKind.GENERATED; catalogue: ProviderCatalogueProvenance };\n\n/** The one engine origin value, so 22 modules do not each spell it. */\nexport const ENGINE_PROVIDER_ORIGIN: ProviderOrigin = Object.freeze({ kind: ProviderOriginKind.ENGINE });\n\nexport const ProviderMetadataSchema = z.object({\n /**\n * Stable identifier for the provider, e.g. `'resend'`, `'stripe'`,\n * `'openai'`. Used as the join key across facet modules and as the\n * map key inside `BackendProviderRegistry.modules`.\n */\n ref: z.string().min(1),\n /**\n * The npm package that ships this provider's module(s), e.g.\n * `@wildo-ai/external-connectors-private` for an engine provider or\n * `@wildo-ai/provider-slack` for a per-provider package. One package,\n * several facet barrels — this is the package, not a barrel.\n */\n packageName: z.string().min(1),\n /** See {@link ProviderTier}. A recorded decision, never inferred. */\n tier: z.enum(ProviderTier),\n /**\n * Vendor grouping. Equal to `ref` for a single-package vendor; the shared\n * name for a sub-cut vendor (`vendor: 'microsoft'` on both\n * `microsoft-graph-mail` and `microsoft-teams`), which is what lets an\n * OAuth client or a secret be shared by reference across sub-packages.\n */\n vendor: z.string().min(1),\n /** See {@link ProviderOriginSchema}. */\n origin: ProviderOriginSchema,\n /**\n * Translation-ready key for the provider display name.\n *\n * Frontend/public surfaces should prefer this field over embedding\n * locale-bound copy in provider modules or runtime artifacts.\n */\n displayNameLabelKey: z.string().optional(),\n /**\n * Legacy human-readable fallback label for non-i18n-aware consumers.\n * When absent, consumers fall back to the `ref`.\n */\n displayName: z.string().optional(),\n /**\n * Optional icon reference resolved through the frontend icon registry.\n * Stays a string (not a URL or component reference) to keep this type\n * frontend-safe AND portable to non-React surfaces.\n */\n iconRef: z.string().optional(),\n});\n\nexport type ProviderMetadata = Omit<z.infer<typeof ProviderMetadataSchema>, 'origin'> & { origin: ProviderOrigin };\n\n/**\n * The identity half of {@link ProviderMetadataSchema} on its own — what a\n * companion contribution carries so tooling can display tiers and group\n * vendors without loading a provider's runtime module.\n */\nexport const ProviderIdentitySchema = ProviderMetadataSchema.pick({\n packageName: true,\n tier: true,\n vendor: true,\n origin: true,\n});\nexport type ProviderIdentity = Omit<z.infer<typeof ProviderIdentitySchema>, 'origin'> & { origin: ProviderOrigin };\n\nexport interface DefineProviderMetadataInput {\n ref: string;\n packageName: string;\n tier: ProviderTier;\n origin: ProviderOrigin;\n /** Defaults to `ref` — the single-package vendor case. */\n vendor?: string;\n displayName?: string;\n iconRef?: string;\n}\n\n/**\n * The one way a provider module authors its metadata.\n *\n * Derives `displayNameLabelKey` from the ref (every module used to call\n * `buildProviderDisplayNameLabelKey` by hand), defaults `vendor` to the ref,\n * and parses the result so an incomplete identity fails at MODULE LOAD —\n * in the package that owns the module — rather than at the first consumer\n * that reads a field which is not there.\n */\nexport function defineProviderMetadata(input: DefineProviderMetadataInput): ProviderMetadata {\n return ProviderMetadataSchema.parse({\n ref: input.ref,\n packageName: input.packageName,\n tier: input.tier,\n vendor: input.vendor ?? input.ref,\n origin: input.origin,\n displayNameLabelKey: buildProviderDisplayNameLabelKey(input.ref),\n ...(input.displayName === undefined ? {} : { displayName: input.displayName }),\n ...(input.iconRef === undefined ? {} : { iconRef: input.iconRef }),\n }) as ProviderMetadata;\n}\n"]}
@@ -24,14 +24,19 @@
24
24
  * documented allow-list of deliberate exclusions. **`AUDIO_PROVIDER` and
25
25
  * `VIDEO_PROVIDER` are deliberately absent** — see that file for the reason and
26
26
  * for the exact condition under which they are admitted.
27
+ *
28
+ * RETIRED 2026-09-05 (#327) together with the engine enum members: `MCP_CONNECTOR`,
29
+ * `A2A_CONNECTOR`, `GIT_PROVIDER`, `GRPC`, `SSO_SAML` — authorable here, typed in the union,
30
+ * declared by no provider module, resolvable by no runtime arm. An application that still
31
+ * writes one is refused at config time by `ProviderProtocolSelectorSchema`, which now accepts
32
+ * ONLY these keys (the engine's snake_case wire values were also accepted before, a second
33
+ * spelling nothing else understood).
27
34
  */
28
35
  export declare const BUILTIN_PROVIDER_PROTOCOL: {
29
36
  readonly REST_API: "REST_API";
30
37
  readonly WEBHOOK_ORIGINATOR: "WEBHOOK_ORIGINATOR";
31
38
  readonly LLM_PROVIDER: "LLM_PROVIDER";
32
39
  readonly AGENT_CLIENT_PROTOCOL: "AGENT_CLIENT_PROTOCOL";
33
- readonly MCP_CONNECTOR: "MCP_CONNECTOR";
34
- readonly A2A_CONNECTOR: "A2A_CONNECTOR";
35
40
  /**
36
41
  * Text-to-image generation (wired: gpt-image, via the OpenAI provider's
37
42
  * `IMAGE_PROVIDER` transport). Serves the IMAGE artifact modality.
@@ -52,10 +57,7 @@ export declare const BUILTIN_PROVIDER_PROTOCOL: {
52
57
  */
53
58
  readonly DOCUMENT_EXTRACTION_PROVIDER: "DOCUMENT_EXTRACTION_PROVIDER";
54
59
  readonly EMAIL_PROVIDER: "EMAIL_PROVIDER";
55
- readonly GIT_PROVIDER: "GIT_PROVIDER";
56
- readonly GRPC: "GRPC";
57
60
  readonly SSO_OAUTH2: "SSO_OAUTH2";
58
- readonly SSO_SAML: "SSO_SAML";
59
61
  readonly BILLING_PROVIDER: "BILLING_PROVIDER";
60
62
  readonly SMS_PROVIDER: "SMS_PROVIDER";
61
63
  readonly FRONTEND_SDK: "FRONTEND_SDK";
@@ -1 +1 @@
1
- {"version":3,"file":"provider-protocol.shared.schemas.d.ts","sourceRoot":"","sources":["../../../../src/external-providers/provider-protocol.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,eAAO,MAAM,yBAAyB;;;;;;;IAOpC;;;OAGG;;IAEH;;;;;;OAMG;;IAEH;;;;OAIG;;;;;;;;;;CAUK,CAAC;AAEX,MAAM,MAAM,uBAAuB,GACjC,CAAC,OAAO,yBAAyB,CAAC,CAAC,MAAM,OAAO,yBAAyB,CAAC,CAAC;AAE7E,MAAM,MAAM,gBAAgB,GAAG,uBAAuB,CAAC"}
1
+ {"version":3,"file":"provider-protocol.shared.schemas.d.ts","sourceRoot":"","sources":["../../../../src/external-providers/provider-protocol.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,eAAO,MAAM,yBAAyB;;;;;IAKpC;;;OAGG;;IAEH;;;;;;OAMG;;IAEH;;;;OAIG;;;;;;;CAOK,CAAC;AAEX,MAAM,MAAM,uBAAuB,GACjC,CAAC,OAAO,yBAAyB,CAAC,CAAC,MAAM,OAAO,yBAAyB,CAAC,CAAC;AAE7E,MAAM,MAAM,gBAAgB,GAAG,uBAAuB,CAAC"}
@@ -24,14 +24,19 @@
24
24
  * documented allow-list of deliberate exclusions. **`AUDIO_PROVIDER` and
25
25
  * `VIDEO_PROVIDER` are deliberately absent** — see that file for the reason and
26
26
  * for the exact condition under which they are admitted.
27
+ *
28
+ * RETIRED 2026-09-05 (#327) together with the engine enum members: `MCP_CONNECTOR`,
29
+ * `A2A_CONNECTOR`, `GIT_PROVIDER`, `GRPC`, `SSO_SAML` — authorable here, typed in the union,
30
+ * declared by no provider module, resolvable by no runtime arm. An application that still
31
+ * writes one is refused at config time by `ProviderProtocolSelectorSchema`, which now accepts
32
+ * ONLY these keys (the engine's snake_case wire values were also accepted before, a second
33
+ * spelling nothing else understood).
27
34
  */
28
35
  export const BUILTIN_PROVIDER_PROTOCOL = {
29
36
  REST_API: 'REST_API',
30
37
  WEBHOOK_ORIGINATOR: 'WEBHOOK_ORIGINATOR',
31
38
  LLM_PROVIDER: 'LLM_PROVIDER',
32
39
  AGENT_CLIENT_PROTOCOL: 'AGENT_CLIENT_PROTOCOL',
33
- MCP_CONNECTOR: 'MCP_CONNECTOR',
34
- A2A_CONNECTOR: 'A2A_CONNECTOR',
35
40
  /**
36
41
  * Text-to-image generation (wired: gpt-image, via the OpenAI provider's
37
42
  * `IMAGE_PROVIDER` transport). Serves the IMAGE artifact modality.
@@ -52,10 +57,7 @@ export const BUILTIN_PROVIDER_PROTOCOL = {
52
57
  */
53
58
  DOCUMENT_EXTRACTION_PROVIDER: 'DOCUMENT_EXTRACTION_PROVIDER',
54
59
  EMAIL_PROVIDER: 'EMAIL_PROVIDER',
55
- GIT_PROVIDER: 'GIT_PROVIDER',
56
- GRPC: 'GRPC',
57
60
  SSO_OAUTH2: 'SSO_OAUTH2',
58
- SSO_SAML: 'SSO_SAML',
59
61
  BILLING_PROVIDER: 'BILLING_PROVIDER',
60
62
  SMS_PROVIDER: 'SMS_PROVIDER',
61
63
  FRONTEND_SDK: 'FRONTEND_SDK',
@@ -1 +1 @@
1
- {"version":3,"file":"provider-protocol.shared.schemas.js","sourceRoot":"","sources":["../../../../src/external-providers/provider-protocol.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACvC,QAAQ,EAAE,UAAU;IACpB,kBAAkB,EAAE,oBAAoB;IACxC,YAAY,EAAE,cAAc;IAC5B,qBAAqB,EAAE,uBAAuB;IAC9C,aAAa,EAAE,eAAe;IAC9B,aAAa,EAAE,eAAe;IAC9B;;;OAGG;IACH,cAAc,EAAE,gBAAgB;IAChC;;;;;;OAMG;IACH,mBAAmB,EAAE,qBAAqB;IAC1C;;;;OAIG;IACH,4BAA4B,EAAE,8BAA8B;IAC5D,cAAc,EAAE,gBAAgB;IAChC,YAAY,EAAE,cAAc;IAC5B,IAAI,EAAE,MAAM;IACZ,UAAU,EAAE,YAAY;IACxB,QAAQ,EAAE,UAAU;IACpB,gBAAgB,EAAE,kBAAkB;IACpC,YAAY,EAAE,cAAc;IAC5B,YAAY,EAAE,cAAc;CACpB,CAAC","sourcesContent":["/**\n * Closed built-in provider protocol vocabulary used by app authoring and\n * runtime-provider declarations.\n *\n * This is intentionally a pure `as const` object + union type so browser-bound\n * packages can consume it through `@wildo-ai/saas-models/public-runtime`\n * without pulling decorators or broader config-authoring seams. Do NOT add an\n * import here — not even an `import type` of the engine enum this list mirrors.\n *\n * ## Relationship to `ExternalProvider_ExchangeProtocol_Kind`\n *\n * This list re-states a population the engine owns: every member of\n * `ExternalProvider_ExchangeProtocol_Kind`\n * (`@wildo-ai/external-connectors-models`) that an application may legally\n * WRITE in `wildo.saas.config.ts > providers.scopes.<scope>.providers.<ref>`.\n * Two hand-maintained enumerations of one population is the shape that drifts,\n * and this one did: `IMAGE_PROVIDER` and `EMBEDDINGS_PROVIDER` shipped as live\n * engine protocols — a provider module declares them, discovery reports them,\n * the backend registry resolves them — while this list had no legal value for\n * either, so no application could declare what those transports speak.\n *\n * The keys are therefore checked against the engine enum by\n * `__tests__/provider-protocol-vocabulary.drift.test.ts`, which also owns the\n * documented allow-list of deliberate exclusions. **`AUDIO_PROVIDER` and\n * `VIDEO_PROVIDER` are deliberately absent** — see that file for the reason and\n * for the exact condition under which they are admitted.\n */\nexport const BUILTIN_PROVIDER_PROTOCOL = {\n REST_API: 'REST_API',\n WEBHOOK_ORIGINATOR: 'WEBHOOK_ORIGINATOR',\n LLM_PROVIDER: 'LLM_PROVIDER',\n AGENT_CLIENT_PROTOCOL: 'AGENT_CLIENT_PROTOCOL',\n MCP_CONNECTOR: 'MCP_CONNECTOR',\n A2A_CONNECTOR: 'A2A_CONNECTOR',\n /**\n * Text-to-image generation (wired: gpt-image, via the OpenAI provider's\n * `IMAGE_PROVIDER` transport). Serves the IMAGE artifact modality.\n */\n IMAGE_PROVIDER: 'IMAGE_PROVIDER',\n /**\n * Text → vector embeddings (wired: OpenAI `text-embedding-3-*`). Serves the\n * RAG derived-data tier — corpus embedding in the `rag:embedding-drain`\n * worker, query-time embedding in retrieval. Its own protocol rather than an\n * `LLM_PROVIDER` operation so a provider can be selected for embeddings\n * independently of chat.\n */\n EMBEDDINGS_PROVIDER: 'EMBEDDINGS_PROVIDER',\n /**\n * Document bytes → text (wired: Mistral `mistral-ocr-latest`). Serves file text extraction and\n * the `.ragSource()` corpus built on it, and fills `EngineCapability.AI_DOCUMENT_EXTRACTION` so\n * an OCR provider is selected independently of chat and embeddings.\n */\n DOCUMENT_EXTRACTION_PROVIDER: 'DOCUMENT_EXTRACTION_PROVIDER',\n EMAIL_PROVIDER: 'EMAIL_PROVIDER',\n GIT_PROVIDER: 'GIT_PROVIDER',\n GRPC: 'GRPC',\n SSO_OAUTH2: 'SSO_OAUTH2',\n SSO_SAML: 'SSO_SAML',\n BILLING_PROVIDER: 'BILLING_PROVIDER',\n SMS_PROVIDER: 'SMS_PROVIDER',\n FRONTEND_SDK: 'FRONTEND_SDK',\n} as const;\n\nexport type BuiltinProviderProtocol =\n (typeof BUILTIN_PROVIDER_PROTOCOL)[keyof typeof BUILTIN_PROVIDER_PROTOCOL];\n\nexport type ProviderProtocol = BuiltinProviderProtocol;\n"]}
1
+ {"version":3,"file":"provider-protocol.shared.schemas.js","sourceRoot":"","sources":["../../../../src/external-providers/provider-protocol.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACvC,QAAQ,EAAE,UAAU;IACpB,kBAAkB,EAAE,oBAAoB;IACxC,YAAY,EAAE,cAAc;IAC5B,qBAAqB,EAAE,uBAAuB;IAC9C;;;OAGG;IACH,cAAc,EAAE,gBAAgB;IAChC;;;;;;OAMG;IACH,mBAAmB,EAAE,qBAAqB;IAC1C;;;;OAIG;IACH,4BAA4B,EAAE,8BAA8B;IAC5D,cAAc,EAAE,gBAAgB;IAChC,UAAU,EAAE,YAAY;IACxB,gBAAgB,EAAE,kBAAkB;IACpC,YAAY,EAAE,cAAc;IAC5B,YAAY,EAAE,cAAc;CACpB,CAAC","sourcesContent":["/**\n * Closed built-in provider protocol vocabulary used by app authoring and\n * runtime-provider declarations.\n *\n * This is intentionally a pure `as const` object + union type so browser-bound\n * packages can consume it through `@wildo-ai/saas-models/public-runtime`\n * without pulling decorators or broader config-authoring seams. Do NOT add an\n * import here — not even an `import type` of the engine enum this list mirrors.\n *\n * ## Relationship to `ExternalProvider_ExchangeProtocol_Kind`\n *\n * This list re-states a population the engine owns: every member of\n * `ExternalProvider_ExchangeProtocol_Kind`\n * (`@wildo-ai/external-connectors-models`) that an application may legally\n * WRITE in `wildo.saas.config.ts > providers.scopes.<scope>.providers.<ref>`.\n * Two hand-maintained enumerations of one population is the shape that drifts,\n * and this one did: `IMAGE_PROVIDER` and `EMBEDDINGS_PROVIDER` shipped as live\n * engine protocols — a provider module declares them, discovery reports them,\n * the backend registry resolves them — while this list had no legal value for\n * either, so no application could declare what those transports speak.\n *\n * The keys are therefore checked against the engine enum by\n * `__tests__/provider-protocol-vocabulary.drift.test.ts`, which also owns the\n * documented allow-list of deliberate exclusions. **`AUDIO_PROVIDER` and\n * `VIDEO_PROVIDER` are deliberately absent** — see that file for the reason and\n * for the exact condition under which they are admitted.\n *\n * RETIRED 2026-09-05 (#327) together with the engine enum members: `MCP_CONNECTOR`,\n * `A2A_CONNECTOR`, `GIT_PROVIDER`, `GRPC`, `SSO_SAML` — authorable here, typed in the union,\n * declared by no provider module, resolvable by no runtime arm. An application that still\n * writes one is refused at config time by `ProviderProtocolSelectorSchema`, which now accepts\n * ONLY these keys (the engine's snake_case wire values were also accepted before, a second\n * spelling nothing else understood).\n */\nexport const BUILTIN_PROVIDER_PROTOCOL = {\n REST_API: 'REST_API',\n WEBHOOK_ORIGINATOR: 'WEBHOOK_ORIGINATOR',\n LLM_PROVIDER: 'LLM_PROVIDER',\n AGENT_CLIENT_PROTOCOL: 'AGENT_CLIENT_PROTOCOL',\n /**\n * Text-to-image generation (wired: gpt-image, via the OpenAI provider's\n * `IMAGE_PROVIDER` transport). Serves the IMAGE artifact modality.\n */\n IMAGE_PROVIDER: 'IMAGE_PROVIDER',\n /**\n * Text → vector embeddings (wired: OpenAI `text-embedding-3-*`). Serves the\n * RAG derived-data tier — corpus embedding in the `rag:embedding-drain`\n * worker, query-time embedding in retrieval. Its own protocol rather than an\n * `LLM_PROVIDER` operation so a provider can be selected for embeddings\n * independently of chat.\n */\n EMBEDDINGS_PROVIDER: 'EMBEDDINGS_PROVIDER',\n /**\n * Document bytes → text (wired: Mistral `mistral-ocr-latest`). Serves file text extraction and\n * the `.ragSource()` corpus built on it, and fills `EngineCapability.AI_DOCUMENT_EXTRACTION` so\n * an OCR provider is selected independently of chat and embeddings.\n */\n DOCUMENT_EXTRACTION_PROVIDER: 'DOCUMENT_EXTRACTION_PROVIDER',\n EMAIL_PROVIDER: 'EMAIL_PROVIDER',\n SSO_OAUTH2: 'SSO_OAUTH2',\n BILLING_PROVIDER: 'BILLING_PROVIDER',\n SMS_PROVIDER: 'SMS_PROVIDER',\n FRONTEND_SDK: 'FRONTEND_SDK',\n} as const;\n\nexport type BuiltinProviderProtocol =\n (typeof BUILTIN_PROVIDER_PROTOCOL)[keyof typeof BUILTIN_PROVIDER_PROTOCOL];\n\nexport type ProviderProtocol = BuiltinProviderProtocol;\n"]}
@@ -0,0 +1,40 @@
1
+ /**
2
+ * The provider TIER RULE, enforced at composition on every facet (#328).
3
+ *
4
+ * - A `CATALOGUE` provider may claim only OPEN `ProviderCapability` tokens.
5
+ * It must never bind an `EngineCapability` slot: the engine's floor is
6
+ * the MAIN set, and a bulk-loaded integration that quietly filled the
7
+ * billing or email slot would make "mandatory" mean "whatever happened
8
+ * to be installed".
9
+ * - A `MAIN` provider is the engine's own: its origin is `ENGINE`. An
10
+ * application or a generated package cannot declare itself MAIN.
11
+ * - An `EXTENSION` provider may bind a slot through
12
+ * `PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY` — that is what the tier is for.
13
+ *
14
+ * Lives in `saas-models` (not in the private package) because the rule is
15
+ * facet-neutral: the three browser-bound registries compose through it too,
16
+ * and they reach this package only through `/public-runtime`.
17
+ */
18
+ import { type EngineCapability } from './engine-capabilities.shared.schemas';
19
+ import { type ProviderMetadata } from './provider-metadata.shared.schemas';
20
+ /** What the rule needs from a module, on any facet. */
21
+ export interface ProviderTierRuleSubject {
22
+ metadata: ProviderMetadata;
23
+ providerCapabilities: ReadonlyArray<string>;
24
+ }
25
+ /** Engine slots a capability list binds through the closed map. */
26
+ export declare function engineSlotsBoundByCapabilities(providerCapabilities: ReadonlyArray<string>): Array<{
27
+ capability: string;
28
+ slot: EngineCapability;
29
+ }>;
30
+ /**
31
+ * Every tier-rule violation across the given modules, as human sentences
32
+ * naming the ref, the tier and the offending fact. Empty when coherent.
33
+ */
34
+ export declare function findProviderTierViolations(modules: Iterable<ProviderTierRuleSubject>): string[];
35
+ /**
36
+ * Refuse a registry whose modules break the tier rule. Called by every
37
+ * facet's `compose*Providers` so the rule holds wherever modules meet.
38
+ */
39
+ export declare function assertProviderTierCoherence(facetLabel: string, modules: Iterable<ProviderTierRuleSubject>): void;
40
+ //# sourceMappingURL=provider-tier-rule.shared.utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provider-tier-rule.shared.utils.d.ts","sourceRoot":"","sources":["../../../../src/external-providers/provider-tier-rule.shared.utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAEL,KAAK,gBAAgB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAoC,KAAK,gBAAgB,EAAE,MAAM,oCAAoC,CAAC;AAG7G,uDAAuD;AACvD,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,gBAAgB,CAAC;IAC3B,oBAAoB,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;CAC7C;AAED,mEAAmE;AACnE,wBAAgB,8BAA8B,CAC5C,oBAAoB,EAAE,aAAa,CAAC,MAAM,CAAC,GAC1C,KAAK,CAAC;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,gBAAgB,CAAA;CAAE,CAAC,CAOvD;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CAAC,OAAO,EAAE,QAAQ,CAAC,uBAAuB,CAAC,GAAG,MAAM,EAAE,CAuC/F;AAED;;;GAGG;AACH,wBAAgB,2BAA2B,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,CAAC,uBAAuB,CAAC,GAAG,IAAI,CAOhH"}
@@ -0,0 +1,80 @@
1
+ /**
2
+ * The provider TIER RULE, enforced at composition on every facet (#328).
3
+ *
4
+ * - A `CATALOGUE` provider may claim only OPEN `ProviderCapability` tokens.
5
+ * It must never bind an `EngineCapability` slot: the engine's floor is
6
+ * the MAIN set, and a bulk-loaded integration that quietly filled the
7
+ * billing or email slot would make "mandatory" mean "whatever happened
8
+ * to be installed".
9
+ * - A `MAIN` provider is the engine's own: its origin is `ENGINE`. An
10
+ * application or a generated package cannot declare itself MAIN.
11
+ * - An `EXTENSION` provider may bind a slot through
12
+ * `PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY` — that is what the tier is for.
13
+ *
14
+ * Lives in `saas-models` (not in the private package) because the rule is
15
+ * facet-neutral: the three browser-bound registries compose through it too,
16
+ * and they reach this package only through `/public-runtime`.
17
+ */
18
+ import { PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY, } from './engine-capabilities.shared.schemas.js';
19
+ import { ProviderOriginKind, ProviderTier } from './provider-metadata.shared.schemas.js';
20
+ /** Engine slots a capability list binds through the closed map. */
21
+ export function engineSlotsBoundByCapabilities(providerCapabilities) {
22
+ const bound = [];
23
+ for (const capability of providerCapabilities) {
24
+ const slot = PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY[capability];
25
+ if (slot !== undefined)
26
+ bound.push({ capability, slot });
27
+ }
28
+ return bound;
29
+ }
30
+ /**
31
+ * Every tier-rule violation across the given modules, as human sentences
32
+ * naming the ref, the tier and the offending fact. Empty when coherent.
33
+ */
34
+ export function findProviderTierViolations(modules) {
35
+ const violations = [];
36
+ for (const module of modules) {
37
+ if (!module.metadata) {
38
+ // A module with no metadata has no ref to name; refuse in words rather than with a TypeError.
39
+ violations.push('(module without metadata): every provider module declares ProviderMetadata via defineProviderMetadata');
40
+ continue;
41
+ }
42
+ const { ref, tier, origin } = module.metadata;
43
+ switch (tier) {
44
+ case ProviderTier.CATALOGUE: {
45
+ const bound = engineSlotsBoundByCapabilities(module.providerCapabilities);
46
+ if (bound.length > 0) {
47
+ violations.push(`${ref}: tier CATALOGUE may claim only open ProviderCapability tokens, but `
48
+ + bound.map((entry) => `"${entry.capability}" binds the ${entry.slot} engine slot`).join(', ')
49
+ + '. Declare the provider EXTENSION if it is meant to substitute for a MAIN provider.');
50
+ }
51
+ break;
52
+ }
53
+ case ProviderTier.MAIN: {
54
+ if (origin.kind !== ProviderOriginKind.ENGINE) {
55
+ violations.push(`${ref}: tier MAIN is the engine's own set, but its origin is ${origin.kind}. `
56
+ + 'A package or application provider that binds an engine slot is an EXTENSION.');
57
+ }
58
+ break;
59
+ }
60
+ case ProviderTier.EXTENSION:
61
+ break;
62
+ default: {
63
+ const unhandled = tier;
64
+ violations.push(`${ref}: unknown provider tier "${String(unhandled)}".`);
65
+ }
66
+ }
67
+ }
68
+ return violations;
69
+ }
70
+ /**
71
+ * Refuse a registry whose modules break the tier rule. Called by every
72
+ * facet's `compose*Providers` so the rule holds wherever modules meet.
73
+ */
74
+ export function assertProviderTierCoherence(facetLabel, modules) {
75
+ const violations = findProviderTierViolations(modules);
76
+ if (violations.length > 0) {
77
+ throw new Error(`${facetLabel} provider composition refused by the tier rule — ${violations.join('; ')}`);
78
+ }
79
+ }
80
+ //# sourceMappingURL=provider-tier-rule.shared.utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provider-tier-rule.shared.utils.js","sourceRoot":"","sources":["../../../../src/external-providers/provider-tier-rule.shared.utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EACL,wCAAwC,GAEzC,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAyB,MAAM,oCAAoC,CAAC;AAS7G,mEAAmE;AACnE,MAAM,UAAU,8BAA8B,CAC5C,oBAA2C;IAE3C,MAAM,KAAK,GAA0D,EAAE,CAAC;IACxE,KAAK,MAAM,UAAU,IAAI,oBAAoB,EAAE,CAAC;QAC9C,MAAM,IAAI,GAAG,wCAAwC,CAAC,UAAuC,CAAC,CAAC;QAC/F,IAAI,IAAI,KAAK,SAAS;YAAE,KAAK,CAAC,IAAI,CAAC,EAAE,UAAU,EAAE,IAAI,EAAE,CAAC,CAAC;IAC3D,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,0BAA0B,CAAC,OAA0C;IACnF,MAAM,UAAU,GAAa,EAAE,CAAC;IAChC,KAAK,MAAM,MAAM,IAAI,OAAO,E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B,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,2BAA2B,CAAC,UAAkB,EAAE,OAA0C;IACxG,MAAM,UAAU,GAAG,0BAA0B,CAAC,OAAO,CAAC,CAAC;IACvD,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC1B,MAAM,IAAI,KAAK,CACb,GAAG,UAAU,oDAAoD,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CACzF,CAAC;IACJ,CAAC;AACH,CAAC","sourcesContent":["/**\n * The provider TIER RULE, enforced at composition on every facet (#328).\n *\n * - A `CATALOGUE` provider may claim only OPEN `ProviderCapability` tokens.\n * It must never bind an `EngineCapability` slot: the engine's floor is\n * the MAIN set, and a bulk-loaded integration that quietly filled the\n * billing or email slot would make \"mandatory\" mean \"whatever happened\n * to be installed\".\n * - A `MAIN` provider is the engine's own: its origin is `ENGINE`. An\n * application or a generated package cannot declare itself MAIN.\n * - An `EXTENSION` provider may bind a slot through\n * `PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY` — that is what the tier is for.\n *\n * Lives in `saas-models` (not in the private package) because the rule is\n * facet-neutral: the three browser-bound registries compose through it too,\n * and they reach this package only through `/public-runtime`.\n */\n\nimport {\n PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY,\n type EngineCapability,\n} from './engine-capabilities.shared.schemas';\nimport { ProviderOriginKind, ProviderTier, type ProviderMetadata } from './provider-metadata.shared.schemas';\nimport type { BuiltinProviderCapability } from './provider-capability.shared.schemas';\n\n/** What the rule needs from a module, on any facet. */\nexport interface ProviderTierRuleSubject {\n metadata: ProviderMetadata;\n providerCapabilities: ReadonlyArray<string>;\n}\n\n/** Engine slots a capability list binds through the closed map. */\nexport function engineSlotsBoundByCapabilities(\n providerCapabilities: ReadonlyArray<string>,\n): Array<{ capability: string; slot: EngineCapability }> {\n const bound: Array<{ capability: string; slot: EngineCapability }> = [];\n for (const capability of providerCapabilities) {\n const slot = PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY[capability as BuiltinProviderCapability];\n if (slot !== undefined) bound.push({ capability, slot });\n }\n return bound;\n}\n\n/**\n * Every tier-rule violation across the given modules, as human sentences\n * naming the ref, the tier and the offending fact. Empty when coherent.\n */\nexport function findProviderTierViolations(modules: Iterable<ProviderTierRuleSubject>): string[] {\n const violations: string[] = [];\n for (const module of modules) {\n if (!module.metadata) {\n // A module with no metadata has no ref to name; refuse in words rather than with a TypeError.\n violations.push('(module without metadata): every provider module declares ProviderMetadata via defineProviderMetadata');\n continue;\n }\n const { ref, tier, origin } = module.metadata;\n switch (tier) {\n case ProviderTier.CATALOGUE: {\n const bound = engineSlotsBoundByCapabilities(module.providerCapabilities);\n if (bound.length > 0) {\n violations.push(\n `${ref}: tier CATALOGUE may claim only open ProviderCapability tokens, but `\n + bound.map((entry) => `\"${entry.capability}\" binds the ${entry.slot} engine slot`).join(', ')\n + '. Declare the provider EXTENSION if it is meant to substitute for a MAIN provider.',\n );\n }\n break;\n }\n case ProviderTier.MAIN: {\n if (origin.kind !== ProviderOriginKind.ENGINE) {\n violations.push(\n `${ref}: tier MAIN is the engine's own set, but its origin is ${origin.kind}. `\n + 'A package or application provider that binds an engine slot is an EXTENSION.',\n );\n }\n break;\n }\n case ProviderTier.EXTENSION:\n break;\n default: {\n const unhandled: never = tier;\n violations.push(`${ref}: unknown provider tier \"${String(unhandled)}\".`);\n }\n }\n }\n return violations;\n}\n\n/**\n * Refuse a registry whose modules break the tier rule. Called by every\n * facet's `compose*Providers` so the rule holds wherever modules meet.\n */\nexport function assertProviderTierCoherence(facetLabel: string, modules: Iterable<ProviderTierRuleSubject>): void {\n const violations = findProviderTierViolations(modules);\n if (violations.length > 0) {\n throw new Error(\n `${facetLabel} provider composition refused by the tier rule — ${violations.join('; ')}`,\n );\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"core-feature-definitions.shared.d.ts","sourceRoot":"","sources":["../../../../src/features/core-feature-definitions.shared.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAMH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAE7E;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,2BAA2B,4BAA4B,CAAC;AAErE;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,iBAAiB,EAwHvD,CAAC"}
1
+ {"version":3,"file":"core-feature-definitions.shared.d.ts","sourceRoot":"","sources":["../../../../src/features/core-feature-definitions.shared.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAMH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAE7E;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,2BAA2B,4BAA4B,CAAC;AAErE;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,iBAAiB,EA8HvD,CAAC"}
@@ -99,7 +99,13 @@ export const CORE_FEATURE_DEFINITIONS = [
99
99
  defaultValue: false,
100
100
  scopeBoundary: true,
101
101
  },
102
- // ─── LIMIT features with counting configs (auto-checked by gate) ───
102
+ // ─── LIMIT features with counting configs ───
103
+ //
104
+ // NOT auto-checked. `registerCoreFeatures` registers these definitions and stops there; the
105
+ // auto-registration of a `limitChecks` entry runs only in `registerCustomFeatures`, for an
106
+ // application-declared limit built with `countResource`. No operation declares a check for either
107
+ // of the two below, so `counting` names the resource that WOULD be counted and nothing counts it.
108
+ // An application that wants the cap enforced declares the check on the counted resource's CREATE.
103
109
  {
104
110
  identifier: 'MAX_MEMBERS',
105
111
  valueType: FeatureValueType.LIMIT,
@@ -1 +1 @@
1
- {"version":3,"file":"core-feature-definitions.shared.js","sourceRoot":"","sources":["../../../../src/features/core-feature-definitions.shared.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,uDAAuD,CAAC;AACpF,OAAO,EAAE,gBAAgB,EAAE,MAAM,gDAAgD,CAAC;AAClF,OAAO,EAAE,oBAAoB,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G,4FAA4F;QAC5F,6FAA6F;QAC7F,EAAE;QACF,sFAAsF;QACtF,+FAA+F;QAC/F,6FAA6F;QAC7F,+EAA+E;QAC/E,UAAU,EAAE,2BAA2B;QACvC,SAAS,EAAE,gBAAgB,CAAC,KAAK;QACjC,aAAa,EAAE,oBAAoB,CAAC,OAAO;QAC3C,wFAAwF;QACxF,sFAAsF;QACtF,6FAA6F;QAC7F,4FAA4F;QAC5F,6FAA6F;QAC7F,gBAAgB,EAAE;YAChB,oBAAoB,CAAC,SAAS;YAC9B,oBAAoB,CAAC,aAAa;YAClC,oBAAoB,CAAC,WAAW;SACjC;QACD,YAAY,EAAE,EAAE;QAChB,YAAY,EAAE,kBAAkB;KACjC;CACF,CAAC","sourcesContent":["/**\n * Framework Core Feature Definitions\n *\n * These are business features managed by the engine (not tied to external providers).\n * Enabled by config profiles, billing products, or manual admin overrides.\n *\n * Note: PRIORITY_SUPPORT, CUSTOM_INTEGRATIONS, ADVANCED_PERMISSIONS from the old CoreOrganizationFeature\n * enum were dropped:\n * - PRIORITY_SUPPORT → modeled as a custom app feature (not engine-level)\n * - CUSTOM_INTEGRATIONS → modeled by provider declarations, not entitlement features\n * - ADVANCED_PERMISSIONS → handled by RBAC system, not feature gating\n */\n\nimport { CoreFeature } from '../organizations/organization-features.shared.schemas';\nimport { CoreResourceType } from '../resources/resources.shared.core.definitions';\nimport { ResourcePrimaryScope } from '../resources/resources.shared.schemas';\nimport { FEATURES_UNLIMITED, FeatureLimitSemantic, FeatureValueType } from './feature-definition.shared.schemas';\nimport type { FeatureDefinition } from './feature-definition.shared.schemas';\n\n/**\n * LIMIT-feature identifier for the inbound Agent2Agent (A2A) LLM **token budget**: how many LLM\n * tokens a tenant's A2A agent turns may consume per billing period. Grant it from a billing plan\n * (a `LimitGrant` on the product) and the A2A transport enforces it fail-closed, denying further\n * turns with HTTP 402 once exhausted.\n *\n * The single named source for this identifier — the backend budget service resolves the allowance\n * by this exact key, so definition and enforcement cannot drift.\n *\n * Measured in TOKENS, not currency: the framework's canonical provider-usage pricing registry is\n * deliberately not consulted by this A2A entitlement gate. The gate caps the transport's directly\n * metered token consumption; monetary reservation and settlement belong to the separate Work Cycle\n * budget authority.\n */\nexport const A2A_TOKEN_BUDGET_FEATURE_ID = 'a2a.llm.tokensPerPeriod';\n\n/**\n * Core feature definitions: every CoreFeature value + core LIMIT features.\n * Merged with custom app feature definitions at startup.\n */\nexport const CORE_FEATURE_DEFINITIONS: FeatureDefinition[] = [\n // ─── BOOLEAN features (on/off toggles) ───\n {\n identifier: CoreFeature.CUSTOM_BRANDING,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.ADVANCED_ANALYTICS,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.SINGLE_SIGN_ON,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.AUDIT_LOGS,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // Outbound delivery of audit-trail events to a tenant-owned SIEM /\n // compliance store. Depends on `AUDIT_LOGS` for the read-side surface,\n // but the gate is independent so admins can enable read-only auditing\n // without paying for outbound delivery.\n identifier: CoreFeature.SECURITY_EVENT_EXPORT,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // SCIM-driven user/group provisioning. Typically procured alongside\n // `SINGLE_SIGN_ON` but each feature is an independent gate so an org\n // can run SSO without provisioning (or vice versa).\n identifier: CoreFeature.DIRECTORY_PROVISIONING,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // M2M_WEBHOOK_DELIVERY is scope-bound: enabling it at the app level\n // does NOT auto-enable it for every organization. Each scope (app or\n // organization) opts in independently. See `FeatureDefinitionSchema.scopeBoundary`\n // and `FeatureResolutionBackendService.isFeatureEnabledAtScope`.\n identifier: CoreFeature.M2M_WEBHOOK_DELIVERY,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [\n ResourcePrimaryScope.APPLICATION,\n ResourcePrimaryScope.ORGANIZATIONS,\n ],\n dependencies: [],\n defaultValue: false,\n scopeBoundary: true,\n },\n // ─── LIMIT features with counting configs (auto-checked by gate) ───\n {\n identifier: 'MAX_MEMBERS',\n valueType: FeatureValueType.LIMIT,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: 5,\n counting: { resourceType: CoreResourceType.ORGANIZATION_MEMBERS },\n },\n {\n identifier: 'MAX_API_KEYS',\n valueType: FeatureValueType.LIMIT,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: 2,\n counting: { resourceType: CoreResourceType.ORG_API_KEYS },\n },\n {\n // Inbound A2A LLM token budget — see {@link A2A_TOKEN_BUDGET_FEATURE_ID}.\n //\n // Applies to all THREE A2A owner scopes: a user-delegated turn is owned by the delegating\n // user, a machine turn by its organization or application.\n //\n // NO `counting` config, deliberately: consumption here is a SUM OF TOKENS, not a count of\n // resource rows, so the gate's row-counting strategy cannot measure it. The A2A budget service\n // owns measurement (accumulating into the `a2aTokenBudgetState` singleton) and resolves this\n // limit directly — which is exactly the \"limit checking done in custom service code\" case the\n // `counting` field documents as its absent-branch.\n //\n // ⚠️ `limitSemantic: CEILING` is LOAD-BEARING — without it this feature is inert. Under the\n // default FLOOR semantic the merge is most-permissive-wins, so the `FEATURES_UNLIMITED` default\n // below would absorb every finite plan grant (`max(-1, 10_000) = -1`) and no cap could ever\n // engage. CEILING inverts it: `-1` means \"no ceiling\" and YIELDS to the plan's finite grant.\n //\n // With CEILING, `defaultValue: FEATURES_UNLIMITED` is both correct and required: this\n // definition is registered for EVERY application, so a finite default would silently cap every\n // tenant that never opted into A2A budgeting (and `0` would deny every A2A turn everywhere).\n // Budgeting stays opt-in — a real cap arrives only from a plan's `LimitGrant`.\n identifier: A2A_TOKEN_BUDGET_FEATURE_ID,\n valueType: FeatureValueType.LIMIT,\n limitSemantic: FeatureLimitSemantic.CEILING,\n // All three A2A owner scopes are declared because all three can OWN a turn. ⚠️ But only\n // ORGANIZATIONS and USER_SELF have a BILLING rail (`BILLING_SCOPE_TO_VARIANTS` has no\n // application variant), so an APPLICATION-scope cap cannot arrive from a plan `LimitGrant` —\n // it must come from a features profile or a manual `limitOverrides`. Declaring the scope is\n // still correct: without it an app-machine principal could never be capped by ANY mechanism.\n applicableScopes: [\n ResourcePrimaryScope.USER_SELF,\n ResourcePrimaryScope.ORGANIZATIONS,\n ResourcePrimaryScope.APPLICATION,\n ],\n dependencies: [],\n defaultValue: FEATURES_UNLIMITED,\n },\n];\n"]}
1
+ {"version":3,"file":"core-feature-definitions.shared.js","sourceRoot":"","sources":["../../../../src/features/core-feature-definitions.shared.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,uDAAuD,CAAC;AACpF,OAAO,EAAE,gBAAgB,EAAE,MAAM,gDAAgD,CAAC;AAClF,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AAGjH;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG,yBAAyB,CAAC;AAErE;;;GAGG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAwB;IAC3D,4CAA4C;IAC5C;QACE,UAAU,EAAE,W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,OAAO;QAC3C,wFAAwF;QACxF,sFAAsF;QACtF,6FAA6F;QAC7F,4FAA4F;QAC5F,6FAA6F;QAC7F,gBAAgB,EAAE;YAChB,oBAAoB,CAAC,SAAS;YAC9B,oBAAoB,CAAC,aAAa;YAClC,oBAAoB,CAAC,WAAW;SACjC;QACD,YAAY,EAAE,EAAE;QAChB,YAAY,EAAE,kBAAkB;KACjC;CACF,CAAC","sourcesContent":["/**\n * Framework Core Feature Definitions\n *\n * These are business features managed by the engine (not tied to external providers).\n * Enabled by config profiles, billing products, or manual admin overrides.\n *\n * Note: PRIORITY_SUPPORT, CUSTOM_INTEGRATIONS, ADVANCED_PERMISSIONS from the old CoreOrganizationFeature\n * enum were dropped:\n * - PRIORITY_SUPPORT → modeled as a custom app feature (not engine-level)\n * - CUSTOM_INTEGRATIONS → modeled by provider declarations, not entitlement features\n * - ADVANCED_PERMISSIONS → handled by RBAC system, not feature gating\n */\n\nimport { CoreFeature } from '../organizations/organization-features.shared.schemas';\nimport { CoreResourceType } from '../resources/resources.shared.core.definitions';\nimport { ResourcePrimaryScope } from '../resources/resources.shared.schemas';\nimport { FEATURES_UNLIMITED, FeatureLimitSemantic, FeatureValueType } from './feature-definition.shared.schemas';\nimport type { FeatureDefinition } from './feature-definition.shared.schemas';\n\n/**\n * LIMIT-feature identifier for the inbound Agent2Agent (A2A) LLM **token budget**: how many LLM\n * tokens a tenant's A2A agent turns may consume per billing period. Grant it from a billing plan\n * (a `LimitGrant` on the product) and the A2A transport enforces it fail-closed, denying further\n * turns with HTTP 402 once exhausted.\n *\n * The single named source for this identifier — the backend budget service resolves the allowance\n * by this exact key, so definition and enforcement cannot drift.\n *\n * Measured in TOKENS, not currency: the framework's canonical provider-usage pricing registry is\n * deliberately not consulted by this A2A entitlement gate. The gate caps the transport's directly\n * metered token consumption; monetary reservation and settlement belong to the separate Work Cycle\n * budget authority.\n */\nexport const A2A_TOKEN_BUDGET_FEATURE_ID = 'a2a.llm.tokensPerPeriod';\n\n/**\n * Core feature definitions: every CoreFeature value + core LIMIT features.\n * Merged with custom app feature definitions at startup.\n */\nexport const CORE_FEATURE_DEFINITIONS: FeatureDefinition[] = [\n // ─── BOOLEAN features (on/off toggles) ───\n {\n identifier: CoreFeature.CUSTOM_BRANDING,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.ADVANCED_ANALYTICS,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.SINGLE_SIGN_ON,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n identifier: CoreFeature.AUDIT_LOGS,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // Outbound delivery of audit-trail events to a tenant-owned SIEM /\n // compliance store. Depends on `AUDIT_LOGS` for the read-side surface,\n // but the gate is independent so admins can enable read-only auditing\n // without paying for outbound delivery.\n identifier: CoreFeature.SECURITY_EVENT_EXPORT,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // SCIM-driven user/group provisioning. Typically procured alongside\n // `SINGLE_SIGN_ON` but each feature is an independent gate so an org\n // can run SSO without provisioning (or vice versa).\n identifier: CoreFeature.DIRECTORY_PROVISIONING,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: false,\n },\n {\n // M2M_WEBHOOK_DELIVERY is scope-bound: enabling it at the app level\n // does NOT auto-enable it for every organization. Each scope (app or\n // organization) opts in independently. See `FeatureDefinitionSchema.scopeBoundary`\n // and `FeatureResolutionBackendService.isFeatureEnabledAtScope`.\n identifier: CoreFeature.M2M_WEBHOOK_DELIVERY,\n valueType: FeatureValueType.BOOLEAN,\n applicableScopes: [\n ResourcePrimaryScope.APPLICATION,\n ResourcePrimaryScope.ORGANIZATIONS,\n ],\n dependencies: [],\n defaultValue: false,\n scopeBoundary: true,\n },\n // ─── LIMIT features with counting configs ───\n //\n // NOT auto-checked. `registerCoreFeatures` registers these definitions and stops there; the\n // auto-registration of a `limitChecks` entry runs only in `registerCustomFeatures`, for an\n // application-declared limit built with `countResource`. No operation declares a check for either\n // of the two below, so `counting` names the resource that WOULD be counted and nothing counts it.\n // An application that wants the cap enforced declares the check on the counted resource's CREATE.\n {\n identifier: 'MAX_MEMBERS',\n valueType: FeatureValueType.LIMIT,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: 5,\n counting: { resourceType: CoreResourceType.ORGANIZATION_MEMBERS },\n },\n {\n identifier: 'MAX_API_KEYS',\n valueType: FeatureValueType.LIMIT,\n applicableScopes: [ResourcePrimaryScope.ORGANIZATIONS],\n dependencies: [],\n defaultValue: 2,\n counting: { resourceType: CoreResourceType.ORG_API_KEYS },\n },\n {\n // Inbound A2A LLM token budget — see {@link A2A_TOKEN_BUDGET_FEATURE_ID}.\n //\n // Applies to all THREE A2A owner scopes: a user-delegated turn is owned by the delegating\n // user, a machine turn by its organization or application.\n //\n // NO `counting` config, deliberately: consumption here is a SUM OF TOKENS, not a count of\n // resource rows, so the gate's row-counting strategy cannot measure it. The A2A budget service\n // owns measurement (accumulating into the `a2aTokenBudgetState` singleton) and resolves this\n // limit directly — which is exactly the \"limit checking done in custom service code\" case the\n // `counting` field documents as its absent-branch.\n //\n // ⚠️ `limitSemantic: CEILING` is LOAD-BEARING — without it this feature is inert. Under the\n // default FLOOR semantic the merge is most-permissive-wins, so the `FEATURES_UNLIMITED` default\n // below would absorb every finite plan grant (`max(-1, 10_000) = -1`) and no cap could ever\n // engage. CEILING inverts it: `-1` means \"no ceiling\" and YIELDS to the plan's finite grant.\n //\n // With CEILING, `defaultValue: FEATURES_UNLIMITED` is both correct and required: this\n // definition is registered for EVERY application, so a finite default would silently cap every\n // tenant that never opted into A2A budgeting (and `0` would deny every A2A turn everywhere).\n // Budgeting stays opt-in — a real cap arrives only from a plan's `LimitGrant`.\n identifier: A2A_TOKEN_BUDGET_FEATURE_ID,\n valueType: FeatureValueType.LIMIT,\n limitSemantic: FeatureLimitSemantic.CEILING,\n // All three A2A owner scopes are declared because all three can OWN a turn. ⚠️ But only\n // ORGANIZATIONS and USER_SELF have a BILLING rail (`BILLING_SCOPE_TO_VARIANTS` has no\n // application variant), so an APPLICATION-scope cap cannot arrive from a plan `LimitGrant` —\n // it must come from a features profile or a manual `limitOverrides`. Declaring the scope is\n // still correct: without it an app-machine principal could never be capped by ANY mechanism.\n applicableScopes: [\n ResourcePrimaryScope.USER_SELF,\n ResourcePrimaryScope.ORGANIZATIONS,\n ResourcePrimaryScope.APPLICATION,\n ],\n dependencies: [],\n defaultValue: FEATURES_UNLIMITED,\n },\n];\n"]}
@@ -24,6 +24,37 @@ export type FeatureDefinitionWithAutoRegister = FeatureDefinition & {
24
24
  };
25
25
  };
26
26
  /**
27
+ * @wildo_source:part:start saas.models.features.definition-builders facet:layer:shared facet:audience:app-developer
28
+ *
29
+ * Declaring what an application can SELL or gate on. Two builders, from `@wildo-ai/saas-models`:
30
+ * `defineFeature` for a boolean capability, `defineLimitFeature` for a numeric allowance.
31
+ *
32
+ * A product in the billing catalogue then grants them through `grantedFeatures` / `grantedLimits`,
33
+ * and any surface gates on the identifier with `requiredFeatures` — a resource operation, a view, a
34
+ * chart, a navigation item, a settings section.
35
+ *
36
+ * ## Two things that decide whether the gate actually fires
37
+ *
38
+ * (`limitSemantic` is the third and is covered by the product-definitions skill's own guidance —
39
+ * the default `FLOOR` is an entitlement the tenant is ALLOWED, and a consumption CAP needs `CEILING`.)
40
+ *
41
+ * - **`countResource` is the one-call form.** It registers a limit check on that resource's CREATE
42
+ * automatically, so "at most ten projects per organisation" is one declaration rather than a
43
+ * definition plus a hand-written gate. A limit declared WITHOUT counting cannot be checked
44
+ * automatically: `checkLimit` REFUSES rather than guessing at a remaining quota, and the caller
45
+ * must pass a counting override or measure consumption itself. That is the right answer for a
46
+ * quantity that is not a row count — a sum of tokens, for instance.
47
+ * - **`rateLimit` on a definition is RESERVED and ignored by the gate.** A time-windowed allowance
48
+ * like "one hundred calls an hour" is not expressible here at all; abuse throttling is a separate
49
+ * mechanism with its own declaration.
50
+ *
51
+ * ## Granting a capability does not configure it
52
+ *
53
+ * An entitlement says the tenant MAY have the thing. Single sign-on entitles an organisation to
54
+ * register an identity provider; somebody still has to register one. The same holds for provisioning
55
+ * tokens, export destinations and webhook endpoints — so a plan that grants one of these still needs
56
+ * an onboarding step behind it.
57
+ *
27
58
  * Simple boolean feature builder.
28
59
  *
29
60
  * @example
@@ -98,4 +129,5 @@ export declare function defineLimitFeature(identifier: string, options: {
98
129
  dependencies?: string[];
99
130
  unavailability?: FeatureUnavailabilityOverride;
100
131
  }): FeatureDefinitionWithAutoRegister;
132
+ /** @wildo_source:part:end saas.models.features.definition-builders */
101
133
  //# sourceMappingURL=feature-builders.shared.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"feature-builders.shared.d.ts","sourceRoot":"","sources":["../../../../src/features/feature-builders.shared.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAGL,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,KAAK,6BAA6B,EAClC,KAAK,mBAAmB,EACzB,MAAM,qCAAqC,CAAC;AAM7C;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,eAA0C,CAAC;AAEjF;;;GAGG;AACH,MAAM,MAAM,iCAAiC,GAAG,iBAAiB,GAAG;IAClE,CAAC,yBAAyB,CAAC,CAAC,EAAE;QAC5B,oFAAoF;QACpF,aAAa,EAAE,MAAM,CAAC;KACvB,CAAC;CACH,CAAC;AAcF;;;;;;;;;;;;;GAaG;AACH,wBAAgB,aAAa,CAC3B,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE;IACP,KAAK,EAAE,oBAAoB,GAAG,oBAAoB,EAAE,CAAC;IACrD,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,6BAA6B,CAAC;CAChD,GACA,iBAAiB,CASnB;AAMD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,kBAAkB,CAChC,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE;IACP,KAAK,EAAE,oBAAoB,GAAG,oBAAoB,EAAE,CAAC;IACrD,OAAO,EAAE,MAAM,CAAC;IAChB;;;;;;;;;OASG;IACH,aAAa,CAAC,EAAE,oBAAoB,CAAC;IACrC,kFAAkF;IAClF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,oFAAoF;IACpF,QAAQ,CAAC,EAAE,mBAAmB,CAAC;IAC/B,wFAAwF;IACxF,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,6BAA6B,CAAC;CAChD,GACA,iCAAiC,CA0BnC"}
1
+ {"version":3,"file":"feature-builders.shared.d.ts","sourceRoot":"","sources":["../../../../src/features/feature-builders.shared.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAGL,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,KAAK,6BAA6B,EAClC,KAAK,mBAAmB,EACzB,MAAM,qCAAqC,CAAC;AAM7C;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,eAA0C,CAAC;AAEjF;;;GAGG;AACH,MAAM,MAAM,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