@wildo-ai/saas-specifications 1.1.2 → 1.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (410) hide show
  1. package/dist/esm/_core/brand/brand-asset.schemas.d.ts +4 -6
  2. package/dist/esm/_core/brand/brand-asset.schemas.d.ts.map +1 -1
  3. package/dist/esm/_core/brand/brand-asset.schemas.js +4 -12
  4. package/dist/esm/_core/brand/brand-asset.schemas.js.map +1 -1
  5. package/dist/esm/_core/brand/brand-generation.schemas.d.ts +5 -3
  6. package/dist/esm/_core/brand/brand-generation.schemas.d.ts.map +1 -1
  7. package/dist/esm/_core/brand/brand-generation.schemas.js +5 -2
  8. package/dist/esm/_core/brand/brand-generation.schemas.js.map +1 -1
  9. package/dist/esm/_core/brand/brand-snapshot.schemas.d.ts +10 -3
  10. package/dist/esm/_core/brand/brand-snapshot.schemas.d.ts.map +1 -1
  11. package/dist/esm/_core/brand/brand-snapshot.schemas.js +10 -2
  12. package/dist/esm/_core/brand/brand-snapshot.schemas.js.map +1 -1
  13. package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts.map +1 -1
  14. package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.js +15 -5
  15. package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.js.map +1 -1
  16. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts +40 -3
  17. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts.map +1 -1
  18. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js +85 -6
  19. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js.map +1 -1
  20. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-generation.schemas.d.ts.map +1 -1
  21. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-generation.schemas.js +10 -4
  22. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-generation.schemas.js.map +1 -1
  23. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-validation.d.ts +15 -0
  24. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-validation.d.ts.map +1 -1
  25. package/dist/esm/_core/business-model-lite/business-model-lite-snapshot-validation.js.map +1 -1
  26. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts +10 -0
  27. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts.map +1 -1
  28. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js +17 -0
  29. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js.map +1 -1
  30. package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.d.ts +6 -7
  31. package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.d.ts.map +1 -1
  32. package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.js +6 -13
  33. package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.js.map +1 -1
  34. package/dist/esm/_core/expert-personas/expert-persona-validation.d.ts +0 -11
  35. package/dist/esm/_core/expert-personas/expert-persona-validation.d.ts.map +1 -1
  36. package/dist/esm/_core/expert-personas/expert-persona-validation.js +0 -19
  37. package/dist/esm/_core/expert-personas/expert-persona-validation.js.map +1 -1
  38. package/dist/esm/_core/expert-personas/expert-role-template.schemas.d.ts +1 -2
  39. package/dist/esm/_core/expert-personas/expert-role-template.schemas.d.ts.map +1 -1
  40. package/dist/esm/_core/expert-personas/expert-role-template.schemas.js +1 -2
  41. package/dist/esm/_core/expert-personas/expert-role-template.schemas.js.map +1 -1
  42. package/dist/esm/_core/feature-drafts/feature-specification-drafts-generation.schemas.d.ts.map +1 -1
  43. package/dist/esm/_core/feature-drafts/feature-specification-drafts-generation.schemas.js +17 -4
  44. package/dist/esm/_core/feature-drafts/feature-specification-drafts-generation.schemas.js.map +1 -1
  45. package/dist/esm/_core/index.d.ts +1 -0
  46. package/dist/esm/_core/index.d.ts.map +1 -1
  47. package/dist/esm/_core/index.js +1 -0
  48. package/dist/esm/_core/index.js.map +1 -1
  49. package/dist/esm/_core/market/market-snapshot-generation.schemas.d.ts.map +1 -1
  50. package/dist/esm/_core/market/market-snapshot-generation.schemas.js +5 -40
  51. package/dist/esm/_core/market/market-snapshot-generation.schemas.js.map +1 -1
  52. package/dist/esm/_core/market/market-snapshot-validation.d.ts +15 -0
  53. package/dist/esm/_core/market/market-snapshot-validation.d.ts.map +1 -1
  54. package/dist/esm/_core/market/market-snapshot-validation.js.map +1 -1
  55. package/dist/esm/_core/placement-plan/placement-plan-generation.schemas.d.ts.map +1 -1
  56. package/dist/esm/_core/placement-plan/placement-plan-generation.schemas.js +11 -5
  57. package/dist/esm/_core/placement-plan/placement-plan-generation.schemas.js.map +1 -1
  58. package/dist/esm/_core/placement-plan/placement-plan-validation.d.ts +66 -9
  59. package/dist/esm/_core/placement-plan/placement-plan-validation.d.ts.map +1 -1
  60. package/dist/esm/_core/placement-plan/placement-plan-validation.js +62 -20
  61. package/dist/esm/_core/placement-plan/placement-plan-validation.js.map +1 -1
  62. package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts +4 -1
  63. package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts.map +1 -1
  64. package/dist/esm/_core/placement-plan/placement-plan.schemas.js +4 -1
  65. package/dist/esm/_core/placement-plan/placement-plan.schemas.js.map +1 -1
  66. package/dist/esm/_core/provider-specification.schemas.d.ts +82 -0
  67. package/dist/esm/_core/provider-specification.schemas.d.ts.map +1 -0
  68. package/dist/esm/_core/provider-specification.schemas.js +144 -0
  69. package/dist/esm/_core/provider-specification.schemas.js.map +1 -0
  70. package/dist/esm/_core/requirements/requirements-snapshot-generation.schemas.d.ts.map +1 -1
  71. package/dist/esm/_core/requirements/requirements-snapshot-generation.schemas.js +13 -8
  72. package/dist/esm/_core/requirements/requirements-snapshot-generation.schemas.js.map +1 -1
  73. package/dist/esm/_core/requirements/requirements-snapshot-validation.d.ts +15 -0
  74. package/dist/esm/_core/requirements/requirements-snapshot-validation.d.ts.map +1 -1
  75. package/dist/esm/_core/requirements/requirements-snapshot-validation.js.map +1 -1
  76. package/dist/esm/_core/roadmap/roadmap-snapshot-generation.schemas.d.ts.map +1 -1
  77. package/dist/esm/_core/roadmap/roadmap-snapshot-generation.schemas.js +7 -2
  78. package/dist/esm/_core/roadmap/roadmap-snapshot-generation.schemas.js.map +1 -1
  79. package/dist/esm/_core/roadmap/roadmap-snapshot-validation.d.ts +15 -0
  80. package/dist/esm/_core/roadmap/roadmap-snapshot-validation.d.ts.map +1 -1
  81. package/dist/esm/_core/roadmap/roadmap-snapshot-validation.js.map +1 -1
  82. package/dist/esm/_core/utils/family-ref-stamping.d.ts +64 -0
  83. package/dist/esm/_core/utils/family-ref-stamping.d.ts.map +1 -0
  84. package/dist/esm/_core/utils/family-ref-stamping.js +73 -0
  85. package/dist/esm/_core/utils/family-ref-stamping.js.map +1 -0
  86. package/dist/esm/_core/vision/vision-snapshot-generation.schemas.d.ts.map +1 -1
  87. package/dist/esm/_core/vision/vision-snapshot-generation.schemas.js +23 -9
  88. package/dist/esm/_core/vision/vision-snapshot-generation.schemas.js.map +1 -1
  89. package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.d.ts +0 -4
  90. package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.d.ts.map +1 -1
  91. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts +7 -7
  92. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts.map +1 -1
  93. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js +6 -7
  94. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js.map +1 -1
  95. package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.d.ts +3 -3
  96. package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.js +3 -3
  97. package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.js.map +1 -1
  98. package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.d.ts +2 -2
  99. package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js +2 -2
  100. package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js.map +1 -1
  101. package/dist/esm/application-creation/journey.application-creation.schemas.d.ts +18 -6
  102. package/dist/esm/application-creation/journey.application-creation.schemas.d.ts.map +1 -1
  103. package/dist/esm/application-creation/journey.application-creation.schemas.js +18 -6
  104. package/dist/esm/application-creation/journey.application-creation.schemas.js.map +1 -1
  105. package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts +8 -23
  106. package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts.map +1 -1
  107. package/dist/esm/application-creation/playbooks.application-creation.schemas.js +57 -27
  108. package/dist/esm/application-creation/playbooks.application-creation.schemas.js.map +1 -1
  109. package/dist/esm/assurance/application-document-publication.schemas.d.ts +20 -6
  110. package/dist/esm/assurance/application-document-publication.schemas.d.ts.map +1 -1
  111. package/dist/esm/assurance/application-document-publication.schemas.js +26 -10
  112. package/dist/esm/assurance/application-document-publication.schemas.js.map +1 -1
  113. package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts +72 -49
  114. package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts.map +1 -1
  115. package/dist/esm/assurance/assurance-authority-basis.definitions.js +161 -60
  116. package/dist/esm/assurance/assurance-authority-basis.definitions.js.map +1 -1
  117. package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts +25 -0
  118. package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts.map +1 -1
  119. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts +36 -0
  120. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts.map +1 -0
  121. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js +859 -0
  122. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js.map +1 -0
  123. package/dist/esm/assurance/assurance-foundation.schemas.d.ts +43 -0
  124. package/dist/esm/assurance/assurance-foundation.schemas.d.ts.map +1 -1
  125. package/dist/esm/assurance/assurance-foundation.schemas.js +56 -0
  126. package/dist/esm/assurance/assurance-foundation.schemas.js.map +1 -1
  127. package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts +14 -7
  128. package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts.map +1 -1
  129. package/dist/esm/assurance/assurance-objective-catalog.definitions.js +24 -7
  130. package/dist/esm/assurance/assurance-objective-catalog.definitions.js.map +1 -1
  131. package/dist/esm/assurance/assurance-program-generation.schemas.d.ts +8 -1
  132. package/dist/esm/assurance/assurance-program-generation.schemas.d.ts.map +1 -1
  133. package/dist/esm/assurance/assurance-program-generation.schemas.js +10 -2
  134. package/dist/esm/assurance/assurance-program-generation.schemas.js.map +1 -1
  135. package/dist/esm/assurance/assurance-program.schemas.d.ts +447 -11
  136. package/dist/esm/assurance/assurance-program.schemas.d.ts.map +1 -1
  137. package/dist/esm/assurance/assurance-program.schemas.js +293 -5
  138. package/dist/esm/assurance/assurance-program.schemas.js.map +1 -1
  139. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.d.ts +35 -0
  140. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.d.ts.map +1 -0
  141. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js +999 -0
  142. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js.map +1 -0
  143. package/dist/esm/companion-exports.d.ts +7 -6
  144. package/dist/esm/companion-exports.d.ts.map +1 -1
  145. package/dist/esm/companion-exports.js.map +1 -1
  146. package/dist/esm/engine/_bootstrap.js +3 -1
  147. package/dist/esm/engine/_bootstrap.js.map +1 -1
  148. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.d.ts.map +1 -1
  149. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js +13 -1
  150. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js.map +1 -1
  151. package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js +1 -1
  152. package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js.map +1 -1
  153. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts +2 -0
  154. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts.map +1 -1
  155. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js +14 -2
  156. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js.map +1 -1
  157. package/dist/esm/engine/applications/resources/application-versions.resource.specification.js +9 -9
  158. package/dist/esm/engine/applications/resources/application-versions.resource.specification.js.map +1 -1
  159. package/dist/esm/engine/applications/resources/applications.resource.specification.js +1 -1
  160. package/dist/esm/engine/applications/resources/applications.resource.specification.js.map +1 -1
  161. package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.js +3 -3
  162. package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.js.map +1 -1
  163. package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js +1 -1
  164. package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js.map +1 -1
  165. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.d.ts.map +1 -1
  166. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js +13 -1
  167. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js.map +1 -1
  168. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts +2 -0
  169. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts.map +1 -1
  170. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js +14 -2
  171. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js.map +1 -1
  172. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts +32 -0
  173. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts.map +1 -0
  174. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js +308 -0
  175. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js.map +1 -0
  176. package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.js +4 -4
  177. package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.js.map +1 -1
  178. package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js +2 -2
  179. package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js.map +1 -1
  180. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js +6 -6
  181. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js.map +1 -1
  182. package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js +9 -9
  183. package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js.map +1 -1
  184. package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js +2 -2
  185. package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js.map +1 -1
  186. package/dist/esm/engine/auth/resources/sso-config.resource.specification.d.ts +9 -25
  187. package/dist/esm/engine/auth/resources/sso-config.resource.specification.d.ts.map +1 -1
  188. package/dist/esm/engine/auth/resources/sso-config.resource.specification.js +104 -10
  189. package/dist/esm/engine/auth/resources/sso-config.resource.specification.js.map +1 -1
  190. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts +0 -6
  191. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts.map +1 -1
  192. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts +32 -0
  193. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts.map +1 -0
  194. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js +297 -0
  195. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js.map +1 -0
  196. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.d.ts.map +1 -1
  197. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js +4 -3
  198. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js.map +1 -1
  199. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js +2 -2
  200. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js.map +1 -1
  201. package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js +3 -3
  202. package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js.map +1 -1
  203. package/dist/esm/engine/billing/resources/prices.resource.specification.js +7 -7
  204. package/dist/esm/engine/billing/resources/prices.resource.specification.js.map +1 -1
  205. package/dist/esm/engine/billing/resources/products.resource.specification.js +7 -7
  206. package/dist/esm/engine/billing/resources/products.resource.specification.js.map +1 -1
  207. package/dist/esm/engine/billing/resources/promotions.resource.specification.d.ts.map +1 -1
  208. package/dist/esm/engine/billing/resources/promotions.resource.specification.js +14 -12
  209. package/dist/esm/engine/billing/resources/promotions.resource.specification.js.map +1 -1
  210. package/dist/esm/engine/billing/resources/referrals.resource.specification.js +7 -7
  211. package/dist/esm/engine/billing/resources/referrals.resource.specification.js.map +1 -1
  212. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts.map +1 -1
  213. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js +6 -3
  214. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js.map +1 -1
  215. package/dist/esm/engine/billing/resources/usage-records.resource.specification.d.ts +7 -3
  216. package/dist/esm/engine/billing/resources/usage-records.resource.specification.d.ts.map +1 -1
  217. package/dist/esm/engine/billing/resources/usage-records.resource.specification.js +28 -11
  218. package/dist/esm/engine/billing/resources/usage-records.resource.specification.js.map +1 -1
  219. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js +8 -8
  220. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js.map +1 -1
  221. package/dist/esm/engine/engine-resource-specifications.registry.d.ts +2 -2
  222. package/dist/esm/engine/engine-resource-specifications.registry.d.ts.map +1 -1
  223. package/dist/esm/engine/engine-resource-specifications.registry.js +6 -2
  224. package/dist/esm/engine/engine-resource-specifications.registry.js.map +1 -1
  225. package/dist/esm/engine/engine-resource-sub-domain.d.ts +20 -0
  226. package/dist/esm/engine/engine-resource-sub-domain.d.ts.map +1 -1
  227. package/dist/esm/engine/engine-resource-sub-domain.js +66 -0
  228. package/dist/esm/engine/engine-resource-sub-domain.js.map +1 -1
  229. package/dist/esm/engine/errors/error-messages.specification.d.ts.map +1 -1
  230. package/dist/esm/engine/errors/error-messages.specification.js +14 -0
  231. package/dist/esm/engine/errors/error-messages.specification.js.map +1 -1
  232. package/dist/esm/engine/features/audit-logs.feature.specification.js +4 -4
  233. package/dist/esm/engine/features/audit-logs.feature.specification.js.map +1 -1
  234. package/dist/esm/engine/features/core-limits.feature.specifications.js +7 -7
  235. package/dist/esm/engine/features/core-limits.feature.specifications.js.map +1 -1
  236. package/dist/esm/engine/features/resources/application-features.resource.specification.js +3 -3
  237. package/dist/esm/engine/features/resources/application-features.resource.specification.js.map +1 -1
  238. package/dist/esm/engine/features/resources/organization-features.resource.specification.js +3 -3
  239. package/dist/esm/engine/features/resources/organization-features.resource.specification.js.map +1 -1
  240. package/dist/esm/engine/features/resources/user-features.resource.specification.js +3 -3
  241. package/dist/esm/engine/features/resources/user-features.resource.specification.js.map +1 -1
  242. package/dist/esm/engine/files/resources/files.resource.specification.js +10 -10
  243. package/dist/esm/engine/files/resources/files.resource.specification.js.map +1 -1
  244. package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js +11 -11
  245. package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js.map +1 -1
  246. package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js +4 -4
  247. package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js.map +1 -1
  248. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js +2 -2
  249. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js.map +1 -1
  250. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.d.ts +5 -0
  251. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.d.ts.map +1 -0
  252. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js +81 -0
  253. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js.map +1 -0
  254. package/dist/esm/engine/frontend-components/app/public-layout-file-upload-grant.frontend-component.specification.d.ts +4 -0
  255. package/dist/esm/engine/frontend-components/app/public-layout-file-upload-grant.frontend-component.specification.d.ts.map +1 -0
  256. package/dist/esm/engine/frontend-components/app/public-layout-file-upload-grant.frontend-component.specification.js +22 -0
  257. package/dist/esm/engine/frontend-components/app/public-layout-file-upload-grant.frontend-component.specification.js.map +1 -0
  258. package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.d.ts +0 -4
  259. package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.d.ts.map +0 -1
  260. package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.js +0 -21
  261. package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.js.map +0 -1
  262. package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.d.ts +0 -4
  263. package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.d.ts.map +0 -1
  264. package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.js +0 -21
  265. package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.js.map +0 -1
  266. package/dist/esm/engine/frontend-components/index.d.ts +0 -2
  267. package/dist/esm/engine/frontend-components/index.d.ts.map +1 -1
  268. package/dist/esm/engine/frontend-components/index.js +4 -6
  269. package/dist/esm/engine/frontend-components/index.js.map +1 -1
  270. package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js +12 -12
  271. package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js.map +1 -1
  272. package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js +9 -9
  273. package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js.map +1 -1
  274. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts +8 -0
  275. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts.map +1 -1
  276. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js +6 -6
  277. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js.map +1 -1
  278. package/dist/esm/engine/index.d.ts +1 -0
  279. package/dist/esm/engine/index.d.ts.map +1 -1
  280. package/dist/esm/engine/index.js +1 -0
  281. package/dist/esm/engine/index.js.map +1 -1
  282. package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js +17 -17
  283. package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js.map +1 -1
  284. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js +7 -7
  285. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js.map +1 -1
  286. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js +8 -8
  287. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js.map +1 -1
  288. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.d.ts +7 -2
  289. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.d.ts.map +1 -1
  290. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js +10 -5
  291. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js.map +1 -1
  292. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.d.ts.map +1 -1
  293. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js +20 -15
  294. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js.map +1 -1
  295. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.d.ts.map +1 -1
  296. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js +11 -10
  297. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js.map +1 -1
  298. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.d.ts.map +1 -1
  299. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js +29 -6
  300. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js.map +1 -1
  301. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js +9 -9
  302. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js.map +1 -1
  303. package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js +3 -3
  304. package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js.map +1 -1
  305. package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js +4 -4
  306. package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js.map +1 -1
  307. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js +2 -2
  308. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js.map +1 -1
  309. package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js +1 -1
  310. package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js.map +1 -1
  311. package/dist/esm/engine/organizations/resources/organizations.resource.specification.js +7 -7
  312. package/dist/esm/engine/organizations/resources/organizations.resource.specification.js.map +1 -1
  313. package/dist/esm/engine/providers/_engine-provider-shared.d.ts +9 -0
  314. package/dist/esm/engine/providers/_engine-provider-shared.d.ts.map +1 -0
  315. package/dist/esm/engine/providers/_engine-provider-shared.js +19 -0
  316. package/dist/esm/engine/providers/_engine-provider-shared.js.map +1 -0
  317. package/dist/esm/engine/providers/anthropic.provider.specification.d.ts +7 -0
  318. package/dist/esm/engine/providers/anthropic.provider.specification.d.ts.map +1 -0
  319. package/dist/esm/engine/providers/anthropic.provider.specification.js +33 -0
  320. package/dist/esm/engine/providers/anthropic.provider.specification.js.map +1 -0
  321. package/dist/esm/engine/providers/apple.provider.specification.d.ts +7 -0
  322. package/dist/esm/engine/providers/apple.provider.specification.d.ts.map +1 -0
  323. package/dist/esm/engine/providers/apple.provider.specification.js +35 -0
  324. package/dist/esm/engine/providers/apple.provider.specification.js.map +1 -0
  325. package/dist/esm/engine/providers/email-preview.provider.specification.d.ts +7 -0
  326. package/dist/esm/engine/providers/email-preview.provider.specification.d.ts.map +1 -0
  327. package/dist/esm/engine/providers/email-preview.provider.specification.js +31 -0
  328. package/dist/esm/engine/providers/email-preview.provider.specification.js.map +1 -0
  329. package/dist/esm/engine/providers/github.provider.specification.d.ts +7 -0
  330. package/dist/esm/engine/providers/github.provider.specification.d.ts.map +1 -0
  331. package/dist/esm/engine/providers/github.provider.specification.js +30 -0
  332. package/dist/esm/engine/providers/github.provider.specification.js.map +1 -0
  333. package/dist/esm/engine/providers/google.provider.specification.d.ts +7 -0
  334. package/dist/esm/engine/providers/google.provider.specification.d.ts.map +1 -0
  335. package/dist/esm/engine/providers/google.provider.specification.js +34 -0
  336. package/dist/esm/engine/providers/google.provider.specification.js.map +1 -0
  337. package/dist/esm/engine/providers/grok.provider.specification.d.ts +7 -0
  338. package/dist/esm/engine/providers/grok.provider.specification.d.ts.map +1 -0
  339. package/dist/esm/engine/providers/grok.provider.specification.js +30 -0
  340. package/dist/esm/engine/providers/grok.provider.specification.js.map +1 -0
  341. package/dist/esm/engine/providers/index.d.ts +23 -0
  342. package/dist/esm/engine/providers/index.d.ts.map +1 -0
  343. package/dist/esm/engine/providers/index.js +37 -0
  344. package/dist/esm/engine/providers/index.js.map +1 -0
  345. package/dist/esm/engine/providers/microsoft.provider.specification.d.ts +7 -0
  346. package/dist/esm/engine/providers/microsoft.provider.specification.d.ts.map +1 -0
  347. package/dist/esm/engine/providers/microsoft.provider.specification.js +30 -0
  348. package/dist/esm/engine/providers/microsoft.provider.specification.js.map +1 -0
  349. package/dist/esm/engine/providers/mistral.provider.specification.d.ts +7 -0
  350. package/dist/esm/engine/providers/mistral.provider.specification.d.ts.map +1 -0
  351. package/dist/esm/engine/providers/mistral.provider.specification.js +33 -0
  352. package/dist/esm/engine/providers/mistral.provider.specification.js.map +1 -0
  353. package/dist/esm/engine/providers/openai.provider.specification.d.ts +7 -0
  354. package/dist/esm/engine/providers/openai.provider.specification.d.ts.map +1 -0
  355. package/dist/esm/engine/providers/openai.provider.specification.js +43 -0
  356. package/dist/esm/engine/providers/openai.provider.specification.js.map +1 -0
  357. package/dist/esm/engine/providers/opencode.provider.specification.d.ts +7 -0
  358. package/dist/esm/engine/providers/opencode.provider.specification.d.ts.map +1 -0
  359. package/dist/esm/engine/providers/opencode.provider.specification.js +50 -0
  360. package/dist/esm/engine/providers/opencode.provider.specification.js.map +1 -0
  361. package/dist/esm/engine/providers/perplexity.provider.specification.d.ts +7 -0
  362. package/dist/esm/engine/providers/perplexity.provider.specification.d.ts.map +1 -0
  363. package/dist/esm/engine/providers/perplexity.provider.specification.js +30 -0
  364. package/dist/esm/engine/providers/perplexity.provider.specification.js.map +1 -0
  365. package/dist/esm/engine/providers/resend.provider.specification.d.ts +7 -0
  366. package/dist/esm/engine/providers/resend.provider.specification.d.ts.map +1 -0
  367. package/dist/esm/engine/providers/resend.provider.specification.js +33 -0
  368. package/dist/esm/engine/providers/resend.provider.specification.js.map +1 -0
  369. package/dist/esm/engine/providers/stripe.provider.specification.d.ts +7 -0
  370. package/dist/esm/engine/providers/stripe.provider.specification.d.ts.map +1 -0
  371. package/dist/esm/engine/providers/stripe.provider.specification.js +35 -0
  372. package/dist/esm/engine/providers/stripe.provider.specification.js.map +1 -0
  373. package/dist/esm/engine/providers/twilio.provider.specification.d.ts +7 -0
  374. package/dist/esm/engine/providers/twilio.provider.specification.d.ts.map +1 -0
  375. package/dist/esm/engine/providers/twilio.provider.specification.js +33 -0
  376. package/dist/esm/engine/providers/twilio.provider.specification.js.map +1 -0
  377. package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js +7 -7
  378. package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js.map +1 -1
  379. package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js +9 -9
  380. package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js.map +1 -1
  381. package/dist/esm/engine/users/resources/user-credentials.resource.specification.js +2 -2
  382. package/dist/esm/engine/users/resources/user-credentials.resource.specification.js.map +1 -1
  383. package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js +8 -8
  384. package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js.map +1 -1
  385. package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts +4 -4
  386. package/dist/esm/engine/users/resources/user-preferences.resource.specification.js +4 -4
  387. package/dist/esm/engine/users/resources/user-preferences.resource.specification.js.map +1 -1
  388. package/dist/esm/engine/users/resources/user-profiles.resource.specification.js +2 -2
  389. package/dist/esm/engine/users/resources/user-profiles.resource.specification.js.map +1 -1
  390. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts +4 -4
  391. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts.map +1 -1
  392. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js +13 -11
  393. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js.map +1 -1
  394. package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js +1 -1
  395. package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js.map +1 -1
  396. package/dist/esm/engine/users/resources/user-self.resource.specification.js +8 -8
  397. package/dist/esm/engine/users/resources/user-self.resource.specification.js.map +1 -1
  398. package/dist/esm/engine/users/resources/users.resource.specification.d.ts.map +1 -1
  399. package/dist/esm/engine/users/resources/users.resource.specification.js +93 -0
  400. package/dist/esm/engine/users/resources/users.resource.specification.js.map +1 -1
  401. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.d.ts.map +1 -1
  402. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js +95 -45
  403. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js.map +1 -1
  404. package/dist/esm/technical-documentation/technical-documentation-units.schemas.d.ts +37 -1
  405. package/dist/esm/technical-documentation/technical-documentation-units.schemas.d.ts.map +1 -1
  406. package/dist/esm/technical-documentation/technical-documentation-units.schemas.js +36 -0
  407. package/dist/esm/technical-documentation/technical-documentation-units.schemas.js.map +1 -1
  408. package/dist/tsconfig.build.tsbuildinfo +1 -1
  409. package/package.json +8 -8
  410. package/dist/assurance/external-framework-mapping.json +0 -980
@@ -1 +1 @@
1
- {"version":3,"file":"user-preferences.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,iCAAiC,IAAI,uCAAuC,EAAE,MAAM,8BAA8B,CAAC;AAC5H,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,qBAAqB,EACrB,0DAA0D,IAAI,sBAAsB,GACrF,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,sCAAsC,EAAE,MAAM,0CAA0C,CAAC;AAClG,OAAO,EACL,gCAAgC,EAChC,kCAAkC,EAClC,sCAAsC,EACtC,yCAAyC,GAC1C,MAAM,2CAA2C,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAO3E,MAAM,iCAAiC,GAAG,uCAIzC,CAAC;AAEF,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,sCAAsC,CAAC,CAAC,CAAC,CAAC;AAEvE,MAAM,CAAC,MAAM,oCAAoC,GAAG,8CAA8C,CAChG,6BAA6B,CAAC,iCAAiC,CAAC,EAChE,qBAAqB,CACnB,sBAAsB,EACtB,qBAAqB,EACrB,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,CAAC;IACpB,OAAO,EAAE,qJAAqJ;IAC9J,YAAY,EAAE,kKAA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userPreferences` — Wildo SaaS engine specification (mixed, admin-leaning).\n * Schema: `UserPreferencesSchema` (same document shape as `userSelfPreferences`).\n */\n\nimport { userPreferencesResourceUIBehavior as userPreferencesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserPreferencesSchema,\n userPreferencesResourceConfiguration_InitializationFactory as userPreferencesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport { selfServiceFrontEndSuccessNotification } from './self-service-user-notifications.shared';\nimport {\n USER_PREFERENCES_EXAMPLE_USER_ID,\n userPreferencesApiReferenceExample,\n userPreferencesApiReferencePathExample,\n userPreferencesApiReferenceSummaryExample,\n} from './user-preferences-api-reference.examples';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userPreferencesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userPreferencesResourceUIBehavior = userPreferencesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nexport const userPreferencesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userPreferencesResourceUIBehavior),\n resourceSpecification(\n userPreferencesFactory,\n UserPreferencesSchema,\n ({ schemaShape }) => ({\n purpose: 'Application-administration access to an addressed user’s preference document. Subject-facing access belongs exclusively to `USER_SELF_PREFERENCES`.',\n businessRole: 'Powers authorized support inspection and explicitly privileged preference corrections without republishing the self-service API under an addressable user route.',\n lifecycleRole: 'Created internally alongside the user and deleted internally with the user; administrators may read or update the existing row but cannot create or delete it over HTTP.',\n audience: LabelAudience.ADMIN,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserPreferencesSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userPreferencesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_PREFERENCES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userPreferencesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({ meaning: 'Preferences row id.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` row that owns this preference document — immutable after create.',\n whyItMatters: 'Anchors the preference record to a single identity so admin/impersonation reads and self-serve writes always resolve one owner and never leak preferences across users.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n notifications: schemaShape.notifications.objectSpec({ meaning: 'Channel toggles.', importance: FieldSemanticImportance.PRIMARY }),\n privacy: schemaShape.privacy.objectSpec({ meaning: 'Privacy and consent data.', importance: FieldSemanticImportance.PRIMARY }),\n ui: schemaShape.ui.objectSpec({ meaning: 'Theme and presentation block.', importance: FieldSemanticImportance.PRIMARY }),\n regional: schemaShape.regional.objectSpec({ meaning: 'Timezone and format settings.', importance: FieldSemanticImportance.PRIMARY }),\n languagePreferences: schemaShape.languagePreferences.objectSpec({ meaning: 'Language/locale block.', importance: FieldSemanticImportance.PRIMARY }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Read the preference document of an addressed user through the application-administration API. This cross-subject operation requires `APP_ADMIN_VIEWER`; a user reading their own preferences uses `USER_SELF_PREFERENCES` instead.',\n outcome: 'Support and application administrators can inspect the exact preference state that the addressed user sees without impersonating that user.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The addressed user’s complete preference document is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application-administration viewer role.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The addressed user does not exist or has no preferences row because provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Inspect a user’s delivery, privacy and regional choices',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Inspect preferences with their owning user context',\n request: userPreferencesApiReferencePathExample,\n response: {\n ...userPreferencesApiReferenceExample,\n user: { _id: USER_PREFERENCES_EXAMPLE_USER_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Inspect the compact locale and appearance summary',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Create the default preferences row from the trusted user-provisioning lifecycle.',\n outcome: 'Every newly created user starts with exactly one schema-default preferences row.',\n responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'The internal provisioning hook created the preferences row.' }],\n errorScenarios: [{ code: HttpResponseStatusCode.CONFLICT_409, when: 'The one-per-user preferences row already exists.' }],\n idempotent: false,\n },\n [Op.UPDATE]: {\n purpose: 'Correct selected preference blocks for an addressed user through the application-administration API. This cross-subject operation requires `APP_ADMIN_SUPER_ADMIN`; ordinary user changes use `USER_SELF_PREFERENCES`.',\n outcome: 'The selected blocks are replaced on the same preference document used by the self-service API, and the addressed user receives the updated state.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The addressed user’s preference document was updated and is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'A supplied preference block fails schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application super-administrator role.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The addressed user does not exist or has no preferences row because provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Correct the timezone used for a user’s scheduled work',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n regional: {\n timezone: 'Europe/Paris',\n dateFormat: 'DD/MM/YYYY',\n timeFormat: '24h',\n locale: 'fr',\n },\n },\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS on UPDATE (runtime).') },\n },\n [Op.DELETE]: {\n purpose: 'Delete the preferences row as part of the trusted user-composition cascade.',\n outcome: 'The dependent preferences row is removed when its owning user is deleted.',\n responseStatuses: [{ code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The internal lifecycle cascade deleted the preferences row.' }],\n errorScenarios: [],\n idempotent: true,\n },\n },\n\n businessConstraints: [\n 'Registry `resourcePrimaryScope` is `USER_SELF` from the `USERS → USER_PREFERENCES` composition rel — the document is user-anchored even when operators edit it in admin UIs.',\n 'The only HTTP variants are administrator-addressed READ and UPDATE. CREATE exists solely for eager `createAsSystem` provisioning; DELETE exists solely for the USERS composition cascade.',\n '`USER_PREFERENCES` and `USER_SELF_PREFERENCES` resolve to the SAME collection. Subject-facing READ, UPDATE and RESET_TO_DEFAULTS belong only to the self resource; this resource never republishes them under `/users/{userId}`.',\n 'Both administrative variants explicitly admit cross-subject user administration and retain independent APP_ADMIN role gates. The path user id selects the subject only after that authorization succeeds.',\n 'UPDATE accepts selected preference blocks, but a supplied block is validated as that block’s complete object. Send all fields of each block you change.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n purpose: 'Reuse the self-preference section structure (the admin preset sets its layout to the shared USER_SELF_PREFERENCES layout) so admin and user see identical field grouping: notifications/privacy/regional/language. UI theme is intentionally NOT a section here — the shared self-preferences layout omits it; theme is read-only in the summary and edited via the dedicated Appearance Settings-Hub panel. Do not re-add an appearance section unless the shared layout reintroduces the ref.',\n displayPurpose: 'Admin “Edit user preferences” or impersonation read-only view.',\n summaryPurpose: 'Theme, timezone, and language chips for list/table contexts.',\n sections: {\n notifications: {\n purpose: 'Per-channel opt-ins.',\n whenToUse: 'When support verifies notification storms or delivery issues.',\n textSlots: { title: { purpose: 'Notifications section label.' }, description: { purpose: 'Warn that admin edits may be audited in regulated tenants.' } },\n },\n privacy: {\n purpose: 'User privacy posture.',\n whenToUse: 'DSR and consent audits.',\n textSlots: { title: { purpose: 'Privacy section label.' }, description: { purpose: 'Tie to org default policies where applicable.' } },\n },\n regional: {\n purpose: 'Timezone and formats.',\n whenToUse: 'Scheduling support cases.',\n textSlots: { title: { purpose: 'Regional label.' }, description: { purpose: 'Remind that historical timestamps are not rewritten.' } },\n },\n language: {\n purpose: 'Language and fallback language stack.',\n whenToUse: 'i18n bug reports for a user.',\n textSlots: { title: { purpose: 'Language label.' }, description: { purpose: 'Reference auto-detect vs fixed locale behavior.' } },\n },\n },\n },\n views: {\n [Op.READ]: {\n variants: {\n admin: {\n purpose: 'Read preferences through the only public variant on this resource: application administration.',\n whenToUse: 'Back-office user-preferences inspection without impersonating the user.',\n },\n },\n },\n [Op.UPDATE]: {\n variants: {\n admin: {\n purpose: 'Update preferences on behalf of the user (super-admin / support).',\n whenToUse: 'Impersonation or break-glass preference fixes.',\n },\n },\n },\n },\n }),\n);\n"]}
1
+ {"version":3,"file":"user-preferences.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,iCAAiC,IAAI,uCAAuC,EAAE,MAAM,8BAA8B,CAAC;AAC5H,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,qBAAqB,EACrB,0DAA0D,IAAI,sBAAsB,GACrF,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,sCAAsC,EAAE,MAAM,0CAA0C,CAAC;AAClG,OAAO,EACL,gCAAgC,EAChC,kCAAkC,EAClC,sCAAsC,EACtC,yCAAyC,GAC1C,MAAM,2CAA2C,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAO3E,MAAM,iCAAiC,GAAG,uCAIzC,CAAC;AAEF,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,sCAAsC,CAAC,CAAC,CAAC,CAAC;AAEvE,MA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yEAAyE;iBACrF;aACF;SACF;QACD,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE;YACX,QAAQ,EAAE;gBACR,KAAK,EAAE;oBACL,OAAO,EAAE,mEAAmE;oBAC5E,SAAS,EAAE,gDAAgD;iBAC5D;aACF;SACF;KACF;CACF,CAAC,CACH,CAAC","sourcesContent":["/**\n * Resource: `userPreferences` — Wildo SaaS engine specification (mixed, admin-leaning).\n * Schema: `UserPreferencesSchema` (same document shape as `userSelfPreferences`).\n */\n\nimport { userPreferencesResourceUIBehavior as userPreferencesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserPreferencesSchema,\n userPreferencesResourceConfiguration_InitializationFactory as userPreferencesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport { selfServiceFrontEndSuccessNotification } from './self-service-user-notifications.shared';\nimport {\n USER_PREFERENCES_EXAMPLE_USER_ID,\n userPreferencesApiReferenceExample,\n userPreferencesApiReferencePathExample,\n userPreferencesApiReferenceSummaryExample,\n} from './user-preferences-api-reference.examples';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userPreferencesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userPreferencesResourceUIBehavior = userPreferencesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nexport const userPreferencesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userPreferencesResourceUIBehavior),\n resourceSpecification(\n userPreferencesFactory,\n UserPreferencesSchema,\n ({ schemaShape }) => ({\n purpose: 'Application-administration access to an addressed user’s preference document. Subject-facing access belongs exclusively to `USER_SELF_PREFERENCES`.',\n businessRole: 'Powers authorized support inspection and explicitly privileged preference corrections without republishing the self-service API under an addressable user route.',\n lifecycleRole: 'Created internally alongside the user and deleted internally with the user; administrators may read or update the existing row but cannot create or delete it over HTTP.',\n audience: LabelAudience.ADMIN,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserPreferencesSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userPreferencesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_PREFERENCES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userPreferencesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({ meaning: 'Preferences record id.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` record that owns this preference document — immutable after create.',\n whyItMatters: 'Anchors the preference record to a single identity so admin/impersonation reads and self-serve writes always resolve one owner and never leak preferences across users.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n notifications: schemaShape.notifications.objectSpec({ meaning: 'Channel toggles.', importance: FieldSemanticImportance.PRIMARY }),\n privacy: schemaShape.privacy.objectSpec({ meaning: 'Privacy and consent data.', importance: FieldSemanticImportance.PRIMARY }),\n ui: schemaShape.ui.objectSpec({ meaning: 'Theme and presentation block.', importance: FieldSemanticImportance.PRIMARY }),\n regional: schemaShape.regional.objectSpec({ meaning: 'Timezone and format settings.', importance: FieldSemanticImportance.PRIMARY }),\n languagePreferences: schemaShape.languagePreferences.objectSpec({ meaning: 'Language/locale block.', importance: FieldSemanticImportance.PRIMARY }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Read the preference document of an addressed user through the application-administration API. This cross-subject operation requires `APP_ADMIN_VIEWER`; a user reading their own preferences uses `USER_SELF_PREFERENCES` instead.',\n outcome: 'Support and application administrators can inspect the exact preference state that the addressed user sees without impersonating that user.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The addressed user’s complete preference document is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application-administration viewer role.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The addressed user does not exist or has no preferences row because provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Inspect a user’s delivery, privacy and regional choices',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Inspect preferences with their owning user context',\n request: userPreferencesApiReferencePathExample,\n response: {\n ...userPreferencesApiReferenceExample,\n user: { _id: USER_PREFERENCES_EXAMPLE_USER_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Inspect the compact locale and appearance summary',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Create the default preferences row from the trusted user-provisioning lifecycle.',\n outcome: 'Every newly created user starts with exactly one schema-default preferences row.',\n responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'The internal provisioning hook created the preferences record.' }],\n errorScenarios: [{ code: HttpResponseStatusCode.CONFLICT_409, when: 'The one-per-user preferences row already exists.' }],\n idempotent: false,\n },\n [Op.UPDATE]: {\n purpose: 'Correct selected preference blocks for an addressed user through the application-administration API. This cross-subject operation requires `APP_ADMIN_SUPER_ADMIN`; ordinary user changes use `USER_SELF_PREFERENCES`.',\n outcome: 'The selected blocks are replaced on the same preference document used by the self-service API, and the addressed user receives the updated state.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The addressed user’s preference document was updated and is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'A supplied preference block fails schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application super-administrator role.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The addressed user does not exist or has no preferences row because provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Correct the timezone used for a user’s scheduled work',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n regional: {\n timezone: 'Europe/Paris',\n dateFormat: 'DD/MM/YYYY',\n timeFormat: '24h',\n locale: 'fr',\n },\n },\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS on UPDATE (runtime).') },\n },\n [Op.DELETE]: {\n purpose: 'Delete the preferences row as part of the trusted user-composition cascade.',\n outcome: 'The dependent preferences row is removed when its owning user is deleted.',\n responseStatuses: [{ code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The internal lifecycle cascade deleted the preferences record.' }],\n errorScenarios: [],\n idempotent: true,\n },\n },\n\n businessConstraints: [\n 'Registry `resourcePrimaryScope` is `USER_SELF` from the `USERS → USER_PREFERENCES` composition rel — the document is user-anchored even when operators edit it in admin UIs.',\n 'The only HTTP variants are administrator-addressed READ and UPDATE. CREATE exists solely for eager `createAsSystem` provisioning; DELETE exists solely for the USERS composition cascade.',\n '`USER_PREFERENCES` and `USER_SELF_PREFERENCES` resolve to the SAME collection. Subject-facing READ, UPDATE and RESET_TO_DEFAULTS belong only to the self resource; this resource never republishes them under `/users/{userId}`.',\n 'Both administrative variants explicitly admit cross-subject user administration and retain independent APP_ADMIN role gates. The path user id selects the subject only after that authorization succeeds.',\n 'UPDATE accepts selected preference blocks, but a supplied block is validated as that block’s complete object. Send all fields of each block you change.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n purpose: 'Reuse the self-preference section structure (the admin preset sets its layout to the shared USER_SELF_PREFERENCES layout) so admin and user see identical field grouping: notifications/privacy/regional/language. UI theme is intentionally NOT a section here — the shared self-preferences layout omits it; theme is read-only in the summary and edited via the dedicated Appearance Settings-Hub panel. Do not re-add an appearance section unless the shared layout reintroduces the ref.',\n displayPurpose: 'Admin “Edit user preferences” or impersonation read-only view.',\n summaryPurpose: 'Theme, timezone, and language chips for list/table contexts.',\n sections: {\n notifications: {\n purpose: 'Per-channel opt-ins.',\n whenToUse: 'When support verifies notification storms or delivery issues.',\n textSlots: { title: { purpose: 'Notifications section label.' }, description: { purpose: 'Warn that admin edits may be audited in regulated tenants.' } },\n },\n privacy: {\n purpose: 'User privacy posture.',\n whenToUse: 'DSR and consent audits.',\n textSlots: { title: { purpose: 'Privacy section label.' }, description: { purpose: 'Tie to org default policies where applicable.' } },\n },\n regional: {\n purpose: 'Timezone and formats.',\n whenToUse: 'Scheduling support cases.',\n textSlots: { title: { purpose: 'Regional label.' }, description: { purpose: 'Remind that historical timestamps are not rewritten.' } },\n },\n language: {\n purpose: 'Language and fallback language stack.',\n whenToUse: 'i18n bug reports for a user.',\n textSlots: { title: { purpose: 'Language label.' }, description: { purpose: 'Reference auto-detect vs fixed locale behavior.' } },\n },\n },\n },\n views: {\n [Op.READ]: {\n variants: {\n admin: {\n purpose: 'Read preferences through the only public variant on this resource: application administration.',\n whenToUse: 'Back-office user-preferences inspection without impersonating the user.',\n },\n },\n },\n [Op.UPDATE]: {\n variants: {\n admin: {\n purpose: 'Update preferences on behalf of the user (super-admin / support).',\n whenToUse: 'Impersonation or break-glass preference fixes.',\n },\n },\n },\n },\n }),\n);\n"]}
@@ -95,7 +95,7 @@ export const userProfilesResourceSpecification = resourceSpecificationFromFronte
95
95
  fields: {
96
96
  _id: schemaShape._id.stringSpec({ meaning: 'Stable identifier of this profile document.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),
97
97
  userId: schemaShape.userId.foreignKeySpec({
98
- meaning: 'Foreign key to the `users` row this profile document describes — immutable after create; profiles are keyed one-per-user.',
98
+ meaning: 'Foreign key to the `users` record this profile document describes — immutable after create; profiles are keyed one-per-user.',
99
99
  whyItMatters: 'Binds the profile to one user so self-service and authorized administration address the same record without crossing tenant boundaries.',
100
100
  importance: FieldSemanticImportance.PRIMARY,
101
101
  }),
@@ -156,7 +156,7 @@ export const userProfilesResourceSpecification = resourceSpecificationFromFronte
156
156
  purpose: 'Search profiles by name. The administration variant additionally matches phone numbers and permits a larger page size.',
157
157
  outcome: 'A paginated page of matching profile records is returned.',
158
158
  responseStatuses: [
159
- { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of profile rows matching the name search for the active API variant.' },
159
+ { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of profile records matching the name search for the active API variant.' },
160
160
  ],
161
161
  errorScenarios: [
162
162
  { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks access to search profiles through the selected normal or administration variant.' },
@@ -1 +1 @@
1
- {"version":3,"file":"user-profiles.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-profiles.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,8BAA8B,IAAI,oCAAoC,EAAE,MAAM,8BAA8B,CAAC;AACtH,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,iBAAiB,EACjB,uBAAuB,EACvB,uDAAuD,IAAI,mBAAmB,GAC/E,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACL,sCAAsC,GACvC,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAO3E,MAAM,8BAA8B,GAAG,oCAItC,CAAC;AAEF,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,sCAAsC,CAAC,CAAC,CAAC,CAAC;AAEvE,MAAM,oBAAoB,GAAG;IAC3B,GAAG,EAAE,yBAAyB;IAC9B,MAAM,EAAE,iBAAiB;IACzB,SAAS,EAAE,KAAK;IAChB,QAAQ,EAAE,UAAU;IACpB,WAAW,EAAE,cAAc;IAC3B,MAAM,EAAE;QACN,MAAM,EAAE,wBAAwB;QAChC,SAAS,EAAE,0BAA0B;KACtC;IACD,GAAG,EAAE,mEAAmE;IACxE,WAAW,EAAE,e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C","sourcesContent":["/**\n * Resource: `userProfiles` — Wildo SaaS engine specification (mixed, admin-leaning).\n * Same `UserProfileSchema` as `userSelfProfiles` but `CoreResourceType.USER_PROFILES` with org/admin variants.\n */\n\nimport { userProfilesResourceUIBehavior as userProfilesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserProfileSchema,\n UserProfiles_Operations,\n userProfilesResourceConfiguration_InitializationFactory as userProfilesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport {\n selfServiceFrontEndSuccessNotification,\n} from './self-service-user-notifications.shared';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userProfilesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userProfilesResourceUIBehavior = userProfilesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nconst USER_PROFILE_EXAMPLE = {\n _id: 'user_profile_01JEXAMPLE',\n userId: 'user_01JEXAMPLE',\n firstName: 'Ada',\n lastName: 'Lovelace',\n displayName: 'Ada Lovelace',\n avatar: {\n fileId: 'file_avatar_01JEXAMPLE',\n updatedAt: '2026-08-20T10:30:00.000Z',\n },\n bio: 'Leads platform integration architecture and developer enablement.',\n phoneNumber: '+352621123456',\n title: 'Staff Engineer',\n _version: 7,\n} as const;\n\nconst USER_PROFILE_CONTEXT_EXAMPLE = {\n ...USER_PROFILE_EXAMPLE,\n user: { _id: USER_PROFILE_EXAMPLE.userId },\n} as const;\n\nconst USER_PROFILE_SUMMARY_EXAMPLE = {\n _id: USER_PROFILE_EXAMPLE._id,\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n _version: USER_PROFILE_EXAMPLE._version,\n} as const;\n\nconst USER_PROFILE_PAGE = {\n data: [USER_PROFILE_EXAMPLE],\n pagination: { page: 1, limit: 20, total: 1, totalPages: 1 },\n} as const;\n\nexport const userProfilesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userProfilesResourceUIBehavior),\n resourceSpecification(\n userProfilesFactory,\n UserProfileSchema,\n ({ schemaShape }) => ({\n purpose: 'The addressed user’s profile and contact card: name, display name, avatar, biography, phone number, and professional title.',\n businessRole: 'Use the normal API for a user’s own profile and the application-administration API to inspect or maintain another user’s profile.',\n lifecycleRole: 'One profile is created for each user, changes as their public or contact information changes, and is removed with that user or by an authorized administrator.',\n audience: LabelAudience.ADMIN,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserProfileSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userProfilesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_PROFILES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserProfiles_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userProfilesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({ meaning: 'Stable identifier of this profile document.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` row this profile document describes — immutable after create; profiles are keyed one-per-user.',\n whyItMatters: 'Binds the profile to one user so self-service and authorized administration address the same record without crossing tenant boundaries.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n firstName: schemaShape.firstName.stringSpec({ meaning: 'The user’s given name.', importance: FieldSemanticImportance.PRIMARY }),\n lastName: schemaShape.lastName.stringSpec({ meaning: 'The user’s family name.', importance: FieldSemanticImportance.PRIMARY }),\n displayName: schemaShape.displayName.stringSpec({ meaning: 'Optional name shown instead of composing the given and family names.' }),\n avatar: schemaShape.avatar.fileSpec({ meaning: 'Uploaded square profile image, represented by its managed file reference. External image URLs are not accepted.' }),\n bio: schemaShape.bio.stringSpec({ meaning: 'Optional short biography shown on the user’s profile.' }),\n phoneNumber: schemaShape.phoneNumber.stringSpec({ meaning: 'Optional contact number in E.164 international format. Storing it does not by itself prove possession of the number.', semanticRole: 'identifier' }),\n title: schemaShape.title.stringSpec({ meaning: 'Optional professional title shown in people and profile surfaces.' }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Read the profile belonging to the user identified in the route. The normal variant is self-scoped; the administration variant can address another user.',\n outcome: 'The user’s profile fields and current resource version are returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The profile document was found and returned with the field visibility of the active API variant.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks application profile-viewing authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Read your complete profile',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Read your profile with its user relationship',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_CONTEXT_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Read your compact profile identity',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_SUMMARY_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n admin: {\n examples: [{\n title: 'Inspect another user’s complete profile',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.SEARCH]: {\n purpose: 'Search profiles by name. The administration variant additionally matches phone numbers and permits a larger page size.',\n outcome: 'A paginated page of matching profile records is returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of profile rows matching the name search for the active API variant.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks access to search profiles through the selected normal or administration variant.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Find a profile by name',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n q: 'Ada',\n page: 1,\n limit: 20,\n sort: 'lastName:asc',\n },\n response: USER_PROFILE_PAGE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n admin: {\n examples: [{\n title: 'Find a profile by contact number as an administrator',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n q: '+352621123456',\n page: 1,\n limit: 100,\n sort: 'lastName:asc',\n },\n response: {\n ...USER_PROFILE_PAGE,\n pagination: { ...USER_PROFILE_PAGE.pagination, limit: 100 },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Create the addressed user’s profile. The normal variant creates the caller’s own profile; the administration variant provisions one for another existing user.',\n outcome: 'The new profile is returned with its server-assigned id and initial resource version.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A profile document was created for the subject user and is returned with its server-assigned id.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The profile payload fails schema validation (for example, a required name is missing or `phoneNumber` is malformed).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-provisioning authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The referenced owning `userId` does not resolve to a known user.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A profile document already exists for the supplied `userId` (profiles are keyed one-per-user).' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Create your own profile',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n bio: USER_PROFILE_EXAMPLE.bio,\n phoneNumber: USER_PROFILE_EXAMPLE.phoneNumber,\n title: USER_PROFILE_EXAMPLE.title,\n },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n variants: {\n admin: {\n examples: [{\n title: 'Provision a profile for an existing user',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n title: USER_PROFILE_EXAMPLE.title,\n },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.CREATED_201,\n }],\n },\n },\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is created.') },\n },\n [Op.UPDATE]: {\n purpose: 'Replace one or more editable profile fields. The normal variant edits the caller’s profile; the administration variant edits another user’s profile.',\n outcome: 'The updated profile and its incremented resource version are returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The profile document was patched and the new state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The edited profile fields fail schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-editing authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Update your display name and biography',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n displayName: 'Ada L.',\n bio: 'Builds reliable application integrations and developer platforms.',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n displayName: 'Ada L.',\n bio: 'Builds reliable application integrations and developer platforms.',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n admin: {\n examples: [{\n title: 'Correct another user’s professional title',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n title: 'Principal Engineer',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n title: 'Principal Engineer',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is updated.') },\n },\n [Op.DELETE]: {\n purpose: 'Delete the addressed profile. The normal variant removes the caller’s own profile; the administration variant removes another user’s profile.',\n outcome: 'The profile is removed and subsequent reads return 404 until a new profile is created.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The profile document was deleted; no body is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-deletion authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id (or it was already deleted).' },\n ],\n idempotent: true,\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is deleted.') },\n },\n [UserProfiles_Operations.UPDATE_AVATAR]: {\n operationId: UserProfiles_Operations.UPDATE_AVATAR,\n purpose: 'Replace the caller’s avatar with an uploaded, application-managed image file.',\n outcome: 'The managed file reference is stored and the refreshed profile is returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The avatar file reference was updated and the refreshed profile is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The avatar is missing, is not a valid managed file reference, or violates the profile image constraints.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to change this profile’s avatar.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Use an uploaded image as your avatar',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n avatar: {\n fileId: 'file_avatar_01JNEW',\n updatedAt: '2026-08-21T09:00:00.000Z',\n },\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n avatar: {\n fileId: 'file_avatar_01JNEW',\n updatedAt: '2026-08-21T09:00:00.000Z',\n },\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n communications: { notification: toast('The profile owner receives an in-app confirmation after the avatar is updated.') },\n },\n [UserProfiles_Operations.REMOVE_AVATAR]: {\n operationId: UserProfiles_Operations.REMOVE_AVATAR,\n purpose: 'Reserved avatar-removal operation. It is not published as an application-consumer API capability while managed-file release is unimplemented.',\n outcome: 'Runtime requests fail closed; no profile or file reference is changed.',\n responseStatuses: [\n { code: HttpResponseStatusCode.INTERNAL_SERVER_ERROR_500, meaning: 'The acknowledged implementation gap refuses the request instead of reporting a successful no-op.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to clear this profile’s avatar.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n },\n [UserProfiles_Operations.UPDATE_CONTACT_INFO]: {\n operationId: UserProfiles_Operations.UPDATE_CONTACT_INFO,\n purpose: 'Replace the caller’s profile contact number with a valid E.164 international number.',\n outcome: 'The new number is stored and the refreshed profile is returned. Number verification remains a separate authentication flow.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The contact fields were updated and the refreshed profile is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The supplied phone number is not a valid E.164 value or the contact payload fails validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to change this profile’s contact data.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Update your contact number',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n phoneNumber: '+352621654321',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n phoneNumber: '+352621654321',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n communications: { notification: toast('The profile owner receives an in-app confirmation after the contact number is updated.') },\n },\n },\n\n businessConstraints: [\n 'Registry scope resolves through the `USERS` composition edge — the spec’s `resourcePrimaryScope` is `USER_SELF` to match the self-anchor, even though the product copy talks about “org directory”.',\n 'Core operations in the factory register both a default `APP_USER` API variant and an `admin` API variant; the identity `userProfilesResourceUIBehavior` UI preset only hosts the `admin` operation keys in `views`, so `frontend.views` documents `admin` only. End-user “my profile” UI is covered by `USER_SELF_PROFILES`, not a `default` view row on this resource type.',\n 'Custom operations (`update_avatar` … `update_contact_info`) are `APP_USER`-only in the factory (no `admin` variant). They appear in `base.operations` for API and DF-1; the admin UI preset does not add view hosts for them (see `identity.resource-presets.tsx`).',\n 'Phone-number possession is NOT proved on this resource. There is no `verify_phone` custom operation: the challenge/response against an issued code is fully implemented in the auth subsystem by `AuthPhoneVerificationBackendService` (`PHONE_VERIFICATION` consumable tokens — single-use, 10-minute expiry — a constant-time code comparison, audit events on both the success and failure paths, and the verified state persisted through `setVerifiedPhone`), with `AuthMethod.SMS_OTP` covering the same proof as a first-or-second auth factor. `USER_SELF_PROFILES` dropped its equivalent op for the same reason, and an admin-directory resource is the wrong place regardless — an SMS code proves possession by the phone’s owner, not by the admin submitting it. `update_contact_info` changes the number; it does not attest it.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n // Admin `USER_PROFILES` reuses the self-profile layout verbatim\n // (`layout: main[USER_SELF_PROFILES].layout`), which is now a flat,\n // sectionless field list. `sections` must stay empty to match — the\n // structural-slot validator compares this against the SHARED merged layout\n // refs, so a documented section here would crash-loop the companion.\n purpose: 'Reuse the flat self-profile layout for admin/end-user parity — no section grouping.',\n displayPurpose: 'Directory detail drawer (admin) or people search result expansion.',\n summaryPurpose: 'Name and title in compact list rows.',\n sections: {},\n },\n views: {\n [Op.READ]: {\n variants: {\n admin: {\n purpose: 'Admin and elevated directory read — the identity preset only surfaces the `admin` operation variant for USER_PROFILES.',\n whenToUse: 'User management console, directory admin, and support workflows using `USER_PROFILES` (not the self `USER_SELF_PROFILES` type).',\n },\n },\n },\n [Op.SEARCH]: {\n variants: {\n admin: {\n purpose: 'Admin search with expanded searchable fields from the runtime config.',\n whenToUse: 'Compliance lookup and back-office people search.',\n },\n },\n },\n [Op.CREATE]: {\n variants: {\n admin: {\n purpose: 'Admin-provisioned profile creation (imports, support).',\n whenToUse: 'When operators create profile rows on behalf of users — the merged preset only exposes the `admin` variant.',\n },\n },\n },\n [Op.UPDATE]: {\n variants: {\n admin: {\n purpose: 'Admin update path for a user’s profile document.',\n whenToUse: 'Support edits and data-fix flows under super-admin or equivalent roles.',\n },\n },\n },\n [Op.DELETE]: {\n variants: {\n admin: {\n purpose: 'Admin deletion of a profile for compliance or offboarding support.',\n whenToUse: 'DSR, abuse, or org teardown — the preset surfaces only the `admin` delete variant here.',\n },\n },\n },\n },\n }),\n);\n"]}
1
+ {"version":3,"file":"user-profiles.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-profiles.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,8BAA8B,IAAI,oCAAoC,EAAE,MAAM,8BAA8B,CAAC;AACtH,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,iBAAiB,EACjB,uBAAuB,EACvB,uDAAuD,IAAI,mBAAmB,GAC/E,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACL,sCAAsC,GACvC,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAO3E,MAAM,8BAA8B,GAAG,oCAItC,CAAC;AAEF,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,sCAAsC,CAAC,CAAC,CAAC,CAAC;AAEvE,MAAM,oBAAoB,GAAG;IAC3B,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ACL,OAAO,EAAE,kDAAkD;oBAC3D,SAAS,EAAE,yEAAyE;iBACrF;aACF;SACF;QACD,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE;YACX,QAAQ,EAAE;gBACR,KAAK,EAAE;oBACL,OAAO,EAAE,oEAAoE;oBAC7E,SAAS,EAAE,yFAAyF;iBACrG;aACF;SACF;KACF;CACF,CAAC,CACH,CAAC","sourcesContent":["/**\n * Resource: `userProfiles` — Wildo SaaS engine specification (mixed, admin-leaning).\n * Same `UserProfileSchema` as `userSelfProfiles` but `CoreResourceType.USER_PROFILES` with org/admin variants.\n */\n\nimport { userProfilesResourceUIBehavior as userProfilesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserProfileSchema,\n UserProfiles_Operations,\n userProfilesResourceConfiguration_InitializationFactory as userProfilesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport {\n selfServiceFrontEndSuccessNotification,\n} from './self-service-user-notifications.shared';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userProfilesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userProfilesResourceUIBehavior = userProfilesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nconst USER_PROFILE_EXAMPLE = {\n _id: 'user_profile_01JEXAMPLE',\n userId: 'user_01JEXAMPLE',\n firstName: 'Ada',\n lastName: 'Lovelace',\n displayName: 'Ada Lovelace',\n avatar: {\n fileId: 'file_avatar_01JEXAMPLE',\n updatedAt: '2026-08-20T10:30:00.000Z',\n },\n bio: 'Leads platform integration architecture and developer enablement.',\n phoneNumber: '+352621123456',\n title: 'Staff Engineer',\n _version: 7,\n} as const;\n\nconst USER_PROFILE_CONTEXT_EXAMPLE = {\n ...USER_PROFILE_EXAMPLE,\n user: { _id: USER_PROFILE_EXAMPLE.userId },\n} as const;\n\nconst USER_PROFILE_SUMMARY_EXAMPLE = {\n _id: USER_PROFILE_EXAMPLE._id,\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n _version: USER_PROFILE_EXAMPLE._version,\n} as const;\n\nconst USER_PROFILE_PAGE = {\n data: [USER_PROFILE_EXAMPLE],\n pagination: { page: 1, limit: 20, total: 1, totalPages: 1 },\n} as const;\n\nexport const userProfilesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userProfilesResourceUIBehavior),\n resourceSpecification(\n userProfilesFactory,\n UserProfileSchema,\n ({ schemaShape }) => ({\n purpose: 'The addressed user’s profile and contact card: name, display name, avatar, biography, phone number, and professional title.',\n businessRole: 'Use the normal API for a user’s own profile and the application-administration API to inspect or maintain another user’s profile.',\n lifecycleRole: 'One profile is created for each user, changes as their public or contact information changes, and is removed with that user or by an authorized administrator.',\n audience: LabelAudience.ADMIN,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserProfileSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userProfilesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_PROFILES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserProfiles_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userProfilesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({ meaning: 'Stable identifier of this profile document.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` record this profile document describes — immutable after create; profiles are keyed one-per-user.',\n whyItMatters: 'Binds the profile to one user so self-service and authorized administration address the same record without crossing tenant boundaries.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n firstName: schemaShape.firstName.stringSpec({ meaning: 'The user’s given name.', importance: FieldSemanticImportance.PRIMARY }),\n lastName: schemaShape.lastName.stringSpec({ meaning: 'The user’s family name.', importance: FieldSemanticImportance.PRIMARY }),\n displayName: schemaShape.displayName.stringSpec({ meaning: 'Optional name shown instead of composing the given and family names.' }),\n avatar: schemaShape.avatar.fileSpec({ meaning: 'Uploaded square profile image, represented by its managed file reference. External image URLs are not accepted.' }),\n bio: schemaShape.bio.stringSpec({ meaning: 'Optional short biography shown on the user’s profile.' }),\n phoneNumber: schemaShape.phoneNumber.stringSpec({ meaning: 'Optional contact number in E.164 international format. Storing it does not by itself prove possession of the number.', semanticRole: 'identifier' }),\n title: schemaShape.title.stringSpec({ meaning: 'Optional professional title shown in people and profile surfaces.' }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Read the profile belonging to the user identified in the route. The normal variant is self-scoped; the administration variant can address another user.',\n outcome: 'The user’s profile fields and current resource version are returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The profile document was found and returned with the field visibility of the active API variant.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks application profile-viewing authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Read your complete profile',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Read your profile with its user relationship',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_CONTEXT_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Read your compact profile identity',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_SUMMARY_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n admin: {\n examples: [{\n title: 'Inspect another user’s complete profile',\n request: { userId: USER_PROFILE_EXAMPLE.userId },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.SEARCH]: {\n purpose: 'Search profiles by name. The administration variant additionally matches phone numbers and permits a larger page size.',\n outcome: 'A paginated page of matching profile records is returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of profile records matching the name search for the active API variant.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks access to search profiles through the selected normal or administration variant.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Find a profile by name',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n q: 'Ada',\n page: 1,\n limit: 20,\n sort: 'lastName:asc',\n },\n response: USER_PROFILE_PAGE,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n admin: {\n examples: [{\n title: 'Find a profile by contact number as an administrator',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n q: '+352621123456',\n page: 1,\n limit: 100,\n sort: 'lastName:asc',\n },\n response: {\n ...USER_PROFILE_PAGE,\n pagination: { ...USER_PROFILE_PAGE.pagination, limit: 100 },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Create the addressed user’s profile. The normal variant creates the caller’s own profile; the administration variant provisions one for another existing user.',\n outcome: 'The new profile is returned with its server-assigned id and initial resource version.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A profile document was created for the subject user and is returned with its server-assigned id.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The profile payload fails schema validation (for example, a required name is missing or `phoneNumber` is malformed).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-provisioning authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'The referenced owning `userId` does not resolve to a known user.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A profile document already exists for the supplied `userId` (profiles are keyed one-per-user).' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Create your own profile',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n bio: USER_PROFILE_EXAMPLE.bio,\n phoneNumber: USER_PROFILE_EXAMPLE.phoneNumber,\n title: USER_PROFILE_EXAMPLE.title,\n },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n variants: {\n admin: {\n examples: [{\n title: 'Provision a profile for an existing user',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n firstName: USER_PROFILE_EXAMPLE.firstName,\n lastName: USER_PROFILE_EXAMPLE.lastName,\n displayName: USER_PROFILE_EXAMPLE.displayName,\n title: USER_PROFILE_EXAMPLE.title,\n },\n response: USER_PROFILE_EXAMPLE,\n forStatus: HttpResponseStatusCode.CREATED_201,\n }],\n },\n },\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is created.') },\n },\n [Op.UPDATE]: {\n purpose: 'Replace one or more editable profile fields. The normal variant edits the caller’s profile; the administration variant edits another user’s profile.',\n outcome: 'The updated profile and its incremented resource version are returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The profile document was patched and the new state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The edited profile fields fail schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-editing authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Update your display name and biography',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n displayName: 'Ada L.',\n bio: 'Builds reliable application integrations and developer platforms.',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n displayName: 'Ada L.',\n bio: 'Builds reliable application integrations and developer platforms.',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n admin: {\n examples: [{\n title: 'Correct another user’s professional title',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n title: 'Principal Engineer',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n title: 'Principal Engineer',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is updated.') },\n },\n [Op.DELETE]: {\n purpose: 'Delete the addressed profile. The normal variant removes the caller’s own profile; the administration variant removes another user’s profile.',\n outcome: 'The profile is removed and subsequent reads return 404 until a new profile is created.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The profile document was deleted; no body is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The normal caller addresses another user, or the administration caller lacks profile-deletion authority.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id (or it was already deleted).' },\n ],\n idempotent: true,\n communications: { notification: toast('The profile owner receives an in-app confirmation after the profile is deleted.') },\n },\n [UserProfiles_Operations.UPDATE_AVATAR]: {\n operationId: UserProfiles_Operations.UPDATE_AVATAR,\n purpose: 'Replace the caller’s avatar with an uploaded, application-managed image file.',\n outcome: 'The managed file reference is stored and the refreshed profile is returned.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The avatar file reference was updated and the refreshed profile is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The avatar is missing, is not a valid managed file reference, or violates the profile image constraints.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to change this profile’s avatar.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Use an uploaded image as your avatar',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n avatar: {\n fileId: 'file_avatar_01JNEW',\n updatedAt: '2026-08-21T09:00:00.000Z',\n },\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n avatar: {\n fileId: 'file_avatar_01JNEW',\n updatedAt: '2026-08-21T09:00:00.000Z',\n },\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n communications: { notification: toast('The profile owner receives an in-app confirmation after the avatar is updated.') },\n },\n [UserProfiles_Operations.REMOVE_AVATAR]: {\n operationId: UserProfiles_Operations.REMOVE_AVATAR,\n purpose: 'Reserved avatar-removal operation. It is not published as an application-consumer API capability while managed-file release is unimplemented.',\n outcome: 'Runtime requests fail closed; no profile or file reference is changed.',\n responseStatuses: [\n { code: HttpResponseStatusCode.INTERNAL_SERVER_ERROR_500, meaning: 'The acknowledged implementation gap refuses the request instead of reporting a successful no-op.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to clear this profile’s avatar.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n },\n [UserProfiles_Operations.UPDATE_CONTACT_INFO]: {\n operationId: UserProfiles_Operations.UPDATE_CONTACT_INFO,\n purpose: 'Replace the caller’s profile contact number with a valid E.164 international number.',\n outcome: 'The new number is stored and the refreshed profile is returned. Number verification remains a separate authentication flow.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The contact fields were updated and the refreshed profile is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The supplied phone number is not a valid E.164 value or the contact payload fails validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the profile subject and lacks authority to change this profile’s contact data.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No profile document exists for the supplied id within the caller’s scope.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Update your contact number',\n request: {\n userId: USER_PROFILE_EXAMPLE.userId,\n phoneNumber: '+352621654321',\n },\n response: {\n ...USER_PROFILE_EXAMPLE,\n phoneNumber: '+352621654321',\n _version: 8,\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n communications: { notification: toast('The profile owner receives an in-app confirmation after the contact number is updated.') },\n },\n },\n\n businessConstraints: [\n 'Registry scope resolves through the `USERS` composition edge — the spec’s `resourcePrimaryScope` is `USER_SELF` to match the self-anchor, even though the product copy talks about “org directory”.',\n 'Core operations in the factory register both a default `APP_USER` API variant and an `admin` API variant; the identity `userProfilesResourceUIBehavior` UI preset only hosts the `admin` operation keys in `views`, so `frontend.views` documents `admin` only. End-user “my profile” UI is covered by `USER_SELF_PROFILES`, not a `default` view row on this resource type.',\n 'Custom operations (`update_avatar` … `update_contact_info`) are `APP_USER`-only in the factory (no `admin` variant). They appear in `base.operations` for API and DF-1; the admin UI preset does not add view hosts for them (see `identity.resource-presets.tsx`).',\n 'Phone-number possession is NOT proved on this resource. There is no `verify_phone` custom operation: the challenge/response against an issued code is fully implemented in the auth subsystem by `AuthPhoneVerificationBackendService` (`PHONE_VERIFICATION` consumable tokens — single-use, 10-minute expiry — a constant-time code comparison, audit events on both the success and failure paths, and the verified state persisted through `setVerifiedPhone`), with `AuthMethod.SMS_OTP` covering the same proof as a first-or-second auth factor. `USER_SELF_PROFILES` dropped its equivalent op for the same reason, and an admin-directory resource is the wrong place regardless — an SMS code proves possession by the phone’s owner, not by the admin submitting it. `update_contact_info` changes the number; it does not attest it.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n // Admin `USER_PROFILES` reuses the self-profile layout verbatim\n // (`layout: main[USER_SELF_PROFILES].layout`), which is now a flat,\n // sectionless field list. `sections` must stay empty to match — the\n // structural-slot validator compares this against the SHARED merged layout\n // refs, so a documented section here would crash-loop the companion.\n purpose: 'Reuse the flat self-profile layout for admin/end-user parity — no section grouping.',\n displayPurpose: 'Directory detail drawer (admin) or people search result expansion.',\n summaryPurpose: 'Name and title in compact list rows.',\n sections: {},\n },\n views: {\n [Op.READ]: {\n variants: {\n admin: {\n purpose: 'Admin and elevated directory read — the identity preset only surfaces the `admin` operation variant for USER_PROFILES.',\n whenToUse: 'User management console, directory admin, and support workflows using `USER_PROFILES` (not the self `USER_SELF_PROFILES` type).',\n },\n },\n },\n [Op.SEARCH]: {\n variants: {\n admin: {\n purpose: 'Admin search with expanded searchable fields from the runtime config.',\n whenToUse: 'Compliance lookup and back-office people search.',\n },\n },\n },\n [Op.CREATE]: {\n variants: {\n admin: {\n purpose: 'Admin-provisioned profile creation (imports, support).',\n whenToUse: 'When operators create profile rows on behalf of users — the merged preset only exposes the `admin` variant.',\n },\n },\n },\n [Op.UPDATE]: {\n variants: {\n admin: {\n purpose: 'Admin update path for a user’s profile document.',\n whenToUse: 'Support edits and data-fix flows under super-admin or equivalent roles.',\n },\n },\n },\n [Op.DELETE]: {\n variants: {\n admin: {\n purpose: 'Admin deletion of a profile for compliance or offboarding support.',\n whenToUse: 'DSR, abuse, or org teardown — the preset surfaces only the `admin` delete variant here.',\n },\n },\n },\n },\n }),\n);\n"]}
@@ -20,10 +20,10 @@ export declare const userSelfPreferencesResourceSpecification: import("../../../
20
20
  theme: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("zod").ZodEnum<typeof import("@wildo-ai/saas-models").UserTheme>>>;
21
21
  }, import("zod/v4/core").$strip>>>;
22
22
  regional: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("zod").ZodObject<{
23
- timezone: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("zod").ZodUnion<[import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").CommonTimezone>, import("zod").ZodString]>>>;
24
- dateFormat: import("zod").ZodDefault<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").DateFormat>>>;
25
- timeFormat: import("zod").ZodDefault<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").TimeFormat>>>;
26
- locale: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").AvailableLanguage>>>>;
23
+ timezone: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodOptional<import("zod").ZodUnion<[import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").CommonTimezone>, import("zod").ZodString]>>>;
24
+ dateFormat: import("zod").ZodOptional<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").DateFormat>>>;
25
+ timeFormat: import("zod").ZodOptional<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").TimeFormat>>>;
26
+ locale: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodOptional<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").AvailableLanguage>>>>;
27
27
  }, import("zod/v4/core").$strip>>>>;
28
28
  languagePreferences: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("zod").ZodObject<{
29
29
  primaryLanguage: import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodDefault<import("@wildo-ai/zod-decorators").DecoratedPrimitiveZodType<import("zod").ZodEnum<typeof import("@wildo-ai/presets-components-models").AvailableLanguage>>>>;
@@ -1 +1 @@
1
- {"version":3,"file":"user-self-preferences.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-self-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAUH,OAAO,EACL,qBAAqB,IAAI,EAAE,EAI3B,8BAA8B,EAE/B,MAAM,uBAAuB,CAAC;AA8B/B,eAAO,MAAM,wCAAwC;;;;;;;;;;;;;;;;;;;;;;;;;;;;iCA+QpD,CAAC"}
1
+ {"version":3,"file":"user-self-preferences.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-self-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAUH,OAAO,EACL,qBAAqB,IAAI,EAAE,EAI3B,8BAA8B,EAE/B,MAAM,uBAAuB,CAAC;AA8B/B,eAAO,MAAM,wCAAwC;;;;;;;;;;;;;;;;;;;;;;;;;;;;iCAiRpD,CAAC"}
@@ -69,7 +69,7 @@ export const userSelfPreferencesResourceSpecification = resourceSpecificationFro
69
69
  importance: FieldSemanticImportance.PRIMARY,
70
70
  }),
71
71
  userId: schemaShape.userId.foreignKeySpec({
72
- meaning: 'Foreign key to the `users` row that owns this self-preference document — immutable after create.',
72
+ meaning: 'Foreign key to the `users` record that owns this self-preference document — immutable after create.',
73
73
  whyItMatters: 'Scopes every self-serve read/write to the signed-in identity through the user-self access strategy, so a caller can only ever load or mutate their own preferences.',
74
74
  importance: FieldSemanticImportance.PRIMARY,
75
75
  }),
@@ -86,7 +86,7 @@ export const userSelfPreferencesResourceSpecification = resourceSpecificationFro
86
86
  importance: FieldSemanticImportance.PRIMARY,
87
87
  }),
88
88
  regional: schemaShape.regional.objectSpec({
89
- meaning: 'Timezone, locale, and date/time presentation formats.',
89
+ meaning: 'Timezone, locale, and date/time presentation formats — every field OPTIONAL, because an absent one is not a gap but an inheritance. Formatting resolves member, then the organization\u2019s own regional settings, then the framework floor, one field at a time, so a member who sets only a timezone still follows the tenant on date format. Omitting a field is therefore how a member says \u201cwhatever my organization uses\u201d, and sending a value is how they override it.',
90
90
  importance: FieldSemanticImportance.PRIMARY,
91
91
  }),
92
92
  languagePreferences: schemaShape.languagePreferences.objectSpec({
@@ -96,7 +96,9 @@ export const userSelfPreferencesResourceSpecification = resourceSpecificationFro
96
96
  },
97
97
  operations: {
98
98
  [Op.READ]: {
99
- purpose: 'Return the caller’s eagerly seeded preferences row for settings hydration. The `userId` path value must identify the authenticated caller; it is not an administrator-addressable user selector. ALSO exposed as an MCP tool (`operation.mcp.exposed`) to a USER-DELEGATED agent caller — a machine principal carries no `userId`, so this USER_SELF operation is never advertised to it; the read always resolves the consenting user’s own document.',
99
+ // Seeded with the user, so a first read never 404s. That is why the caller never has to
100
+ // create preferences, and it is the only part of the mechanism a reader needs.
101
+ purpose: 'Return the signed-in user’s own preferences, ready for a settings screen to bind to. The `userId` path value must identify the authenticated caller; it is not an administrator-addressable user selector. Also published as an MCP tool to an agent acting on the user’s behalf — never to a machine identity, which carries no user and is therefore never offered this operation; the read always resolves the consenting user’s own preferences.',
100
102
  outcome: 'Client forms can bind to every subsection in one fetch; an agent acting for the user can read their preferences (locale/timezone/theme/notifications) over MCP.',
101
103
  responseStatuses: [
102
104
  { code: HttpResponseStatusCode.OK_200, meaning: 'The signed-in user’s own preferences document is returned with every subsection.' },
@@ -142,8 +144,8 @@ export const userSelfPreferencesResourceSpecification = resourceSpecificationFro
142
144
  },
143
145
  },
144
146
  [Op.UPDATE]: {
145
- purpose: 'Patch any subset of preference sub-objects in one save. The `userId` path value must identify the authenticated caller. ALSO exposed as an MCP tool (`operation.mcp.exposed`) to a USER-DELEGATED agent caller (never to a machine principal — see READ); the write targets the consenting user’s own document.',
146
- outcome: 'Bulk “Save settings” buttons can send a merged DTO; an agent acting for the user can change their preferences over MCP.',
147
+ purpose: 'Change any subset of the preference groups in one save. The `userId` path value must identify the authenticated caller. Also published as an MCP tool to an agent acting on the user’s behalf, never to a machine identity — see the read operation; the write always targets the consenting user’s own preferences.',
148
+ outcome: 'A “Save settings” button can send every changed group at once; an agent acting for the user can change their preferences over MCP.',
147
149
  responseStatuses: [
148
150
  { code: HttpResponseStatusCode.OK_200, meaning: 'The supplied preference sub-objects were merged and the new state is returned.' },
149
151
  ],
@@ -207,12 +209,12 @@ export const userSelfPreferencesResourceSpecification = resourceSpecificationFro
207
209
  sms: false,
208
210
  inApp: true,
209
211
  },
210
- regional: {
211
- timezone: 'UTC',
212
- dateFormat: 'YYYY-MM-DD',
213
- timeFormat: '24h',
214
- locale: 'en',
215
- },
212
+ // Resetting the regional group clears it to EMPTY rather than writing four values,
213
+ // and that is what "default" means here: every regional field is optional, so an
214
+ // absent one is inherited from the organization's own regional record and only then
215
+ // from the framework floor. Writing `UTC`/`en` back would be the opposite — it would
216
+ // record a fresh explicit choice that the tenant can never override again.
217
+ regional: {},
216
218
  },
217
219
  forStatus: HttpResponseStatusCode.OK_200,
218
220
  },
@@ -1 +1 @@
1
- {"version":3,"file":"user-self-preferences.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-self-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,qCAAqC,IAAI,2CAA2C,EAAE,MAAM,8BAA8B,CAAC;AACpI,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,mBAAmB,EACnB,qBAAqB,EACrB,8BAA8B,EAC9B,8DAA8D,IAAI,0BAA0B,GAC7F,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,sCAAsC,EAAE,MAAM,0CAA0C,CAAC;AAClG,OAAO,EACL,gCAAgC,EAChC,kCAAkC,EAClC,sCAAsC,EACtC,yCAAyC,GAC1C,MAAM,2CAA2C,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CA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EAAE,OAAO,EAAE,0IAA0I,EAAE,SAAS,EAAE,8CAA8C,EAAE;KACvQ;CACF,CAAC,CACH,CAAC","sourcesContent":["/**\n * Resource: `userSelfPreferences` — Wildo SaaS engine specification (mixed).\n * Runtime: `user-self-preferences.shared.resources-config.schemas.ts`, schema `UserPreferencesSchema`.\n */\n\nimport { userSelfPreferencesResourceUIBehavior as userSelfPreferencesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserPreferenceGroup,\n UserPreferencesSchema,\n UserSelfPreferences_Operations,\n userSelfPreferencesResourceConfiguration_InitializationFactory as userSelfPreferencesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport { selfServiceFrontEndSuccessNotification } from './self-service-user-notifications.shared';\nimport {\n USER_PREFERENCES_EXAMPLE_USER_ID,\n userPreferencesApiReferenceExample,\n userPreferencesApiReferencePathExample,\n userPreferencesApiReferenceSummaryExample,\n} from './user-preferences-api-reference.examples';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userSelfPreferencesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userSelfPreferencesResourceUIBehavior = userSelfPreferencesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nexport const userSelfPreferencesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userSelfPreferencesResourceUIBehavior),\n resourceSpecification(\n userSelfPreferencesFactory,\n UserPreferencesSchema,\n ({ schemaShape }) => ({\n purpose: 'Persist the signed-in user’s notification, privacy, UI, regional, and language preferences as a single document.',\n businessRole: 'Self-scoped preference store — same shape as org-admin `USER_PREFERENCES` but only `APP_USER` may call it here.',\n lifecycleRole:\n 'Seeded with product defaults when the user account is created, then updated by the signed-in user through the generic update or selective reset operations.',\n audience: LabelAudience.END_USER,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserPreferencesSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userSelfPreferencesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_SELF_PREFERENCES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserSelfPreferences_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userSelfPreferencesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Primary key for the preferences document.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` row that owns this self-preference document — immutable after create.',\n whyItMatters: 'Scopes every self-serve read/write to the signed-in identity through the user-self access strategy, so a caller can only ever load or mutate their own preferences.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n notifications: schemaShape.notifications.objectSpec({\n meaning: 'Channel toggles (email, push, SMS, in-app) for notification fan-out.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n privacy: schemaShape.privacy.objectSpec({\n meaning: 'User-level privacy flags and consent mirrors for product features.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n ui: schemaShape.ui.objectSpec({\n meaning: 'UI theme selection (light/dark/system) and related presentation defaults.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n regional: schemaShape.regional.objectSpec({\n meaning: 'Timezone, locale, and date/time presentation formats.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n languagePreferences: schemaShape.languagePreferences.objectSpec({\n meaning: 'Primary/fallback languages and auto-detect behavior for i18n.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Return the caller’s eagerly seeded preferences row for settings hydration. The `userId` path value must identify the authenticated caller; it is not an administrator-addressable user selector. ALSO exposed as an MCP tool (`operation.mcp.exposed`) to a USER-DELEGATED agent caller — a machine principal carries no `userId`, so this USER_SELF operation is never advertised to it; the read always resolves the consenting user’s own document.',\n outcome: 'Client forms can bind to every subsection in one fetch; an agent acting for the user can read their preferences (locale/timezone/theme/notifications) over MCP.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The signed-in user’s own preferences document is returned with every subsection.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Load my notification, privacy and regional choices',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Load my preferences with their owning user context',\n request: userPreferencesApiReferencePathExample,\n response: {\n ...userPreferencesApiReferenceExample,\n user: { _id: USER_PREFERENCES_EXAMPLE_USER_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Load the compact locale and appearance summary',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.UPDATE]: {\n purpose: 'Patch any subset of preference sub-objects in one save. The `userId` path value must identify the authenticated caller. ALSO exposed as an MCP tool (`operation.mcp.exposed`) to a USER-DELEGATED agent caller (never to a machine principal — see READ); the write targets the consenting user’s own document.',\n outcome: 'Bulk “Save settings” buttons can send a merged DTO; an agent acting for the user can change their preferences over MCP.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The supplied preference sub-objects were merged and the new state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'One of the edited preference sub-objects fails schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Use French formats in the Europe/Paris timezone',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n regional: {\n timezone: 'Europe/Paris',\n dateFormat: 'DD/MM/YYYY',\n timeFormat: '24h',\n locale: 'fr',\n },\n languagePreferences: {\n primaryLanguage: 'fr',\n fallbackLanguages: ['en'],\n autoDetect: true,\n useOrganizationDefault: false,\n },\n },\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS after generic UPDATE on self preferences.') },\n },\n [UserSelfPreferences_Operations.RESET_TO_DEFAULTS]: {\n operationId: UserSelfPreferences_Operations.RESET_TO_DEFAULTS,\n purpose: 'Return the named preference blocks to product defaults. The request carries `groups` — one or more members of the closed `UserPreferenceGroup` vocabulary, whose values are the persisted block names — and a \"reset everything\" is expressed by naming every block, not by a separate flag.',\n outcome: 'Each named block is replaced by its schema defaults; a block the request does not name is left exactly as it was. Resetting `privacy` changes only the two preference settings in that block. Governed notice, contract, and consent interactions are separate immutable release-bound records, are not members of this resource, and are never modified by a preferences reset.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The named preference blocks were reset to product defaults and the refreshed preferences are returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: '`groups` is absent or empty, or names a block outside the vocabulary. A request naming nothing is rejected rather than answered with an empty write.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Restore notification and regional defaults without changing privacy or language',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n groups: [UserPreferenceGroup.NOTIFICATIONS, UserPreferenceGroup.REGIONAL],\n },\n response: {\n ...userPreferencesApiReferenceExample,\n notifications: {\n email: true,\n push: true,\n sms: false,\n inApp: true,\n },\n regional: {\n timezone: 'UTC',\n dateFormat: 'YYYY-MM-DD',\n timeFormat: '24h',\n locale: 'en',\n },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS after reset operation completes.') },\n },\n },\n businessConstraints: [\n 'A preferences row is created eagerly from schema defaults when the user account is created. There is no public self-service CREATE operation; a missing row is a provisioning failure, not a normal client lifecycle state.',\n 'The `userId` URL segment identifies the authenticated user-self scope. Supplying another user id never turns this API into an administrative preferences API.',\n 'UPDATE accepts selected preference blocks, but a supplied block is validated as that block’s complete object. Send all fields of each block you change.',\n 'RESET_TO_DEFAULTS is selective: only groups named in the request are replaced. It does not alter separate governed-document interaction records.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n purpose: 'Mirror the preset’s four settings sections: notifications, privacy, regional, and language. UI theme is intentionally NOT a section here — `ui.theme` is read-only in the summary projection and is edited via the dedicated Appearance Settings-Hub panel (`AppPage_AppearanceSettings`); the editable duplicate was removed from this page (mirrors the preset’s omission note). Do not re-add an `appearance` section unless the preset reintroduces the ref.',\n displayPurpose: 'End-user settings tabs; nested `ObjectScope` names in the preset must stay aligned with these section keys.',\n summaryPurpose: 'Condensed summary with theme + timezone + primary language.',\n sections: {\n notifications: {\n purpose: 'Channel-level opt-in matrix for email/push/SMS/in-app.',\n whenToUse: 'Notification center onboarding and digest controls.',\n textSlots: {\n title: { purpose: 'Label the notifications section card.' },\n description: { purpose: 'Explain binding to actual delivery channels in the worker layer.' },\n },\n },\n privacy: {\n purpose: 'Consent and data-processing toggles that affect compliance posture.',\n whenToUse: 'GDPR/CCPA style self-service privacy center.',\n textSlots: {\n title: { purpose: 'Label the privacy block.' },\n description: { purpose: 'Cross-link to org-level policies when the deployment requires it.' },\n },\n },\n regional: {\n purpose: 'Timezone and format preferences for scheduling and numbers.',\n whenToUse: 'First-day setup or travel scenarios.',\n textSlots: {\n title: { purpose: 'Label regional settings.' },\n description: { purpose: 'State that changes affect formatting, not historical stored instant fields.' },\n },\n },\n language: {\n purpose: 'Primary and fallback languages with auto-detect options.',\n whenToUse: 'Internationalized products and accessibility requirements.',\n textSlots: {\n title: { purpose: 'Label language preferences.' },\n description: { purpose: 'Note interaction with org default language when `useOrganizationDefault` is true.' },\n },\n },\n },\n },\n views: {\n [Op.READ]: { purpose: 'Load self preferences for any settings surface.', whenToUse: 'Initial settings fetch.' },\n [Op.UPDATE]: { purpose: 'Save all tabs in one DTO.', whenToUse: '“Save” with multi-section dirty state.' },\n [UserSelfPreferences_Operations.RESET_TO_DEFAULTS]: { purpose: 'Danger-zone reset: the form is a multi-select over the preference blocks, and being CRITICAL it gates its submit behind type-to-confirm.', whenToUse: '“Restore defaults” CTA in advanced settings.' },\n },\n }),\n);\n"]}
1
+ {"version":3,"file":"user-self-preferences.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/users/resources/user-self-preferences.resource.specification.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,qCAAqC,IAAI,2CAA2C,EAAE,MAAM,8BAA8B,CAAC;AACpI,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,oBAAoB,EACpB,mBAAmB,EACnB,qBAAqB,EACrB,8BAA8B,EAC9B,8DAA8D,IAAI,0BAA0B,GAC7F,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAC/C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,sCAAsC,EAAE,MAAM,0CAA0C,CAAC;AAClG,OAAO,EACL,gCAAgC,EAChC,kCAAkC,EAClC,sCAAsC,EACtC,yCAAyC,GAC1C,MAAM,2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AAS,EAAE,wCAAwC,EAAE;QAC1G,CAAC,8BAA8B,CAAC,iBAAiB,CAAC,EAAE,EAAE,OAAO,EAAE,0IAA0I,EAAE,SAAS,EAAE,8CAA8C,EAAE;KACvQ;CACF,CAAC,CACH,CAAC","sourcesContent":["/**\n * Resource: `userSelfPreferences` — Wildo SaaS engine specification (mixed).\n * Runtime: `user-self-preferences.shared.resources-config.schemas.ts`, schema `UserPreferencesSchema`.\n */\n\nimport { userSelfPreferencesResourceUIBehavior as userSelfPreferencesResourceUIBehaviorSource } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n ResourcePrimaryScope,\n UserPreferenceGroup,\n UserPreferencesSchema,\n UserSelfPreferences_Operations,\n userSelfPreferencesResourceConfiguration_InitializationFactory as userSelfPreferencesFactory,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n} from '~wildo-specifications/_core';\n\nimport { selfServiceFrontEndSuccessNotification } from './self-service-user-notifications.shared';\nimport {\n USER_PREFERENCES_EXAMPLE_USER_ID,\n userPreferencesApiReferenceExample,\n userPreferencesApiReferencePathExample,\n userPreferencesApiReferenceSummaryExample,\n} from './user-preferences-api-reference.examples';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype Cfg = ReturnType<typeof userSelfPreferencesFactory>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = Cfg['mainSchema'];\n\nconst userSelfPreferencesResourceUIBehavior = userSelfPreferencesResourceUIBehaviorSource as ResourceUIBehaviorConfig<\n Custom,\n Core,\n Main\n>;\n\nconst toast = (s: string) => selfServiceFrontEndSuccessNotification(s);\n\nexport const userSelfPreferencesResourceSpecification = resourceSpecificationFromFrontendConfiguration(\n resourceFrontendConfiguration(userSelfPreferencesResourceUIBehavior),\n resourceSpecification(\n userSelfPreferencesFactory,\n UserPreferencesSchema,\n ({ schemaShape }) => ({\n purpose: 'Persist the signed-in user’s notification, privacy, UI, regional, and language preferences as a single document.',\n businessRole: 'Self-scoped preference store — same shape as org-admin `USER_PREFERENCES` but only `APP_USER` may call it here.',\n lifecycleRole:\n 'Seeded with product defaults when the user account is created, then updated by the signed-in user through the generic update or selective reset operations.',\n audience: LabelAudience.END_USER,\n subDomain: EngineResourceSubDomain.USERS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserPreferencesSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'userSelfPreferencesResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: 'USER_SELF_PREFERENCES',\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'UserSelfPreferences_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n frontendConfigurationSources: [\n {\n packageName: '@wildo-ai/presets-components',\n exportName: 'userSelfPreferencesResourceUIBehavior',\n symbolKind: CodeSymbolKind.UI_BEHAVIOR,\n },\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Primary key for the preferences document.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n userId: schemaShape.userId.foreignKeySpec({\n meaning: 'Foreign key to the `users` record that owns this self-preference document — immutable after create.',\n whyItMatters: 'Scopes every self-serve read/write to the signed-in identity through the user-self access strategy, so a caller can only ever load or mutate their own preferences.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n notifications: schemaShape.notifications.objectSpec({\n meaning: 'Channel toggles (email, push, SMS, in-app) for notification fan-out.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n privacy: schemaShape.privacy.objectSpec({\n meaning: 'User-level privacy flags and consent mirrors for product features.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n ui: schemaShape.ui.objectSpec({\n meaning: 'UI theme selection (light/dark/system) and related presentation defaults.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n regional: schemaShape.regional.objectSpec({\n meaning: 'Timezone, locale, and date/time presentation formats — every field OPTIONAL, because an absent one is not a gap but an inheritance. Formatting resolves member, then the organization\\u2019s own regional settings, then the framework floor, one field at a time, so a member who sets only a timezone still follows the tenant on date format. Omitting a field is therefore how a member says \\u201cwhatever my organization uses\\u201d, and sending a value is how they override it.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n languagePreferences: schemaShape.languagePreferences.objectSpec({\n meaning: 'Primary/fallback languages and auto-detect behavior for i18n.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n },\n\n operations: {\n [Op.READ]: {\n // Seeded with the user, so a first read never 404s. That is why the caller never has to\n // create preferences, and it is the only part of the mechanism a reader needs.\n purpose: 'Return the signed-in user’s own preferences, ready for a settings screen to bind to. The `userId` path value must identify the authenticated caller; it is not an administrator-addressable user selector. Also published as an MCP tool to an agent acting on the user’s behalf — never to a machine identity, which carries no user and is therefore never offered this operation; the read always resolves the consenting user’s own preferences.',\n outcome: 'Client forms can bind to every subsection in one fetch; an agent acting for the user can read their preferences (locale/timezone/theme/notifications) over MCP.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The signed-in user’s own preferences document is returned with every subsection.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Load my notification, privacy and regional choices',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Load my preferences with their owning user context',\n request: userPreferencesApiReferencePathExample,\n response: {\n ...userPreferencesApiReferenceExample,\n user: { _id: USER_PREFERENCES_EXAMPLE_USER_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Load the compact locale and appearance summary',\n request: userPreferencesApiReferencePathExample,\n response: userPreferencesApiReferenceSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.UPDATE]: {\n purpose: 'Change any subset of the preference groups in one save. The `userId` path value must identify the authenticated caller. Also published as an MCP tool to an agent acting on the user’s behalf, never to a machine identity — see the read operation; the write always targets the consenting user’s own preferences.',\n outcome: 'A “Save settings” button can send every changed group at once; an agent acting for the user can change their preferences over MCP.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The supplied preference sub-objects were merged and the new state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'One of the edited preference sub-objects fails schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Use French formats in the Europe/Paris timezone',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n regional: {\n timezone: 'Europe/Paris',\n dateFormat: 'DD/MM/YYYY',\n timeFormat: '24h',\n locale: 'fr',\n },\n languagePreferences: {\n primaryLanguage: 'fr',\n fallbackLanguages: ['en'],\n autoDetect: true,\n useOrganizationDefault: false,\n },\n },\n response: userPreferencesApiReferenceExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS after generic UPDATE on self preferences.') },\n },\n [UserSelfPreferences_Operations.RESET_TO_DEFAULTS]: {\n operationId: UserSelfPreferences_Operations.RESET_TO_DEFAULTS,\n purpose: 'Return the named preference blocks to product defaults. The request carries `groups` — one or more members of the closed `UserPreferenceGroup` vocabulary, whose values are the persisted block names — and a \"reset everything\" is expressed by naming every block, not by a separate flag.',\n outcome: 'Each named block is replaced by its schema defaults; a block the request does not name is left exactly as it was. Resetting `privacy` changes only the two preference settings in that block. Governed notice, contract, and consent interactions are separate immutable release-bound records, are not members of this resource, and are never modified by a preferences reset.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The named preference blocks were reset to product defaults and the refreshed preferences are returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.UNAUTHORIZED_401, when: 'The request carries no valid authenticated session.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The `userId` path value does not identify the authenticated caller.' },\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: '`groups` is absent or empty, or names a block outside the vocabulary. A request naming nothing is rejected rather than answered with an empty write.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No preferences row exists for the authenticated user because account provisioning did not complete successfully.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Restore notification and regional defaults without changing privacy or language',\n request: {\n userId: USER_PREFERENCES_EXAMPLE_USER_ID,\n groups: [UserPreferenceGroup.NOTIFICATIONS, UserPreferenceGroup.REGIONAL],\n },\n response: {\n ...userPreferencesApiReferenceExample,\n notifications: {\n email: true,\n push: true,\n sms: false,\n inApp: true,\n },\n // Resetting the regional group clears it to EMPTY rather than writing four values,\n // and that is what \"default\" means here: every regional field is optional, so an\n // absent one is inherited from the organization's own regional record and only then\n // from the framework floor. Writing `UTC`/`en` back would be the opposite — it would\n // record a fresh explicit choice that the tenant can never override again.\n regional: {},\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n communications: { notification: toast('FRONT_END_SUCCESS after reset operation completes.') },\n },\n },\n businessConstraints: [\n 'A preferences row is created eagerly from schema defaults when the user account is created. There is no public self-service CREATE operation; a missing row is a provisioning failure, not a normal client lifecycle state.',\n 'The `userId` URL segment identifies the authenticated user-self scope. Supplying another user id never turns this API into an administrative preferences API.',\n 'UPDATE accepts selected preference blocks, but a supplied block is validated as that block’s complete object. Send all fields of each block you change.',\n 'RESET_TO_DEFAULTS is selective: only groups named in the request are replaced. It does not alter separate governed-document interaction records.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.USER_SELF },\n ),\n () => ({\n layout: {\n purpose: 'Mirror the preset’s four settings sections: notifications, privacy, regional, and language. UI theme is intentionally NOT a section here — `ui.theme` is read-only in the summary projection and is edited via the dedicated Appearance Settings-Hub panel (`AppPage_AppearanceSettings`); the editable duplicate was removed from this page (mirrors the preset’s omission note). Do not re-add an `appearance` section unless the preset reintroduces the ref.',\n displayPurpose: 'End-user settings tabs; nested `ObjectScope` names in the preset must stay aligned with these section keys.',\n summaryPurpose: 'Condensed summary with theme + timezone + primary language.',\n sections: {\n notifications: {\n purpose: 'Channel-level opt-in matrix for email/push/SMS/in-app.',\n whenToUse: 'Notification center onboarding and digest controls.',\n textSlots: {\n title: { purpose: 'Label the notifications section card.' },\n description: { purpose: 'Explain binding to actual delivery channels in the worker layer.' },\n },\n },\n privacy: {\n purpose: 'Consent and data-processing toggles that affect compliance posture.',\n whenToUse: 'GDPR/CCPA style self-service privacy center.',\n textSlots: {\n title: { purpose: 'Label the privacy block.' },\n description: { purpose: 'Cross-link to org-level policies when the deployment requires it.' },\n },\n },\n regional: {\n purpose: 'Timezone and format preferences for scheduling and numbers.',\n whenToUse: 'First-day setup or travel scenarios.',\n textSlots: {\n title: { purpose: 'Label regional settings.' },\n description: { purpose: 'State that changes affect formatting, not historical stored instant fields.' },\n },\n },\n language: {\n purpose: 'Primary and fallback languages with auto-detect options.',\n whenToUse: 'Internationalized products and accessibility requirements.',\n textSlots: {\n title: { purpose: 'Label language preferences.' },\n description: { purpose: 'Note interaction with org default language when `useOrganizationDefault` is true.' },\n },\n },\n },\n },\n views: {\n [Op.READ]: { purpose: 'Load self preferences for any settings surface.', whenToUse: 'Initial settings fetch.' },\n [Op.UPDATE]: { purpose: 'Save all tabs in one DTO.', whenToUse: '“Save” with multi-section dirty state.' },\n [UserSelfPreferences_Operations.RESET_TO_DEFAULTS]: { purpose: 'Danger-zone reset: the form is a multi-select over the preference blocks, and being CRITICAL it gates its submit behind type-to-confirm.', whenToUse: '“Restore defaults” CTA in advanced settings.' },\n },\n }),\n);\n"]}
@@ -61,7 +61,7 @@ export const userSelfProfilesResourceSpecification = resourceSpecificationFromFr
61
61
  importance: FieldSemanticImportance.PRIMARY,
62
62
  }),
63
63
  userId: schemaShape.userId.foreignKeySpec({
64
- meaning: 'Foreign key to the `users` row that owns this self profile document — immutable after create in self-service flows.',
64
+ meaning: 'Foreign key to the `users` record that owns this self profile document — immutable after create in self-service flows.',
65
65
  whyItMatters: 'Scopes profile reads/writes to the signed-in identity so a caller can only self-provision and edit their own profile card, never another user’s.',
66
66
  importance: FieldSemanticImportance.PRIMARY,
67
67
  }),