twenty 2.55.0 → 2.57.0

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 (127) hide show
  1. package/dist/app-template/yarn.lock +38 -38
  2. package/dist/app-worker.cjs +1 -1
  3. package/dist/chunks/api-key-stdin-hint.constant-BTPNgm3m.cjs +1 -0
  4. package/dist/chunks/application-T4xvzjbB.cjs +5 -0
  5. package/dist/chunks/{build-source-manifest-CS9qVNh-.cjs → build-source-manifest-tGYOCdor.cjs} +1 -1
  6. package/dist/chunks/{build-source-snapshot-CpGCu13I.cjs → build-source-snapshot-CzwiB8HK.cjs} +3 -3
  7. package/dist/chunks/{cli-version.constant-Cu5tVcCH.cjs → cli-version.constant-1uwk-lMz.cjs} +1 -1
  8. package/dist/chunks/{collect-translatable-strings-DCyYBNLJ.cjs → collect-translatable-strings-BB6KpZT2.cjs} +1 -1
  9. package/dist/chunks/compile-application-translations-S-xuODkF.cjs +870 -0
  10. package/dist/chunks/constants-Bw_pUpSi-BsJPlw-e.cjs +55 -0
  11. package/dist/chunks/{create-http-status-error-C0btwkS0.cjs → create-http-status-error-DBUhBnxP.cjs} +1 -1
  12. package/dist/chunks/create-metadata-client-wHecaKNL.cjs +6 -0
  13. package/dist/chunks/create-pull-base-write-BZnZwrLk.cjs +1 -0
  14. package/dist/chunks/{create-rest-client-YAG6kSAm.cjs → create-rest-client-B-kdRm7C.cjs} +1 -1
  15. package/dist/chunks/extract-manifest-from-file-CNGCZF6o.cjs +1 -0
  16. package/dist/chunks/{extract-source-translations-DhYrd7jw.cjs → extract-source-translations-BHWNS2e9.cjs} +1 -1
  17. package/dist/chunks/{fetch-metadata-inspection-DzssW2Dw.cjs → fetch-metadata-inspection-Dqn8jToW.cjs} +1 -1
  18. package/dist/chunks/{fetch-signed-in-identity-CId23qtn.cjs → fetch-signed-in-identity-DCqCwASL.cjs} +1 -1
  19. package/dist/chunks/fetch-workspace-or-throw-CBKYiJI0.cjs +1 -0
  20. package/dist/chunks/{format-data-value-pZjy4e4h.cjs → format-data-value-DuQjxLye.cjs} +1 -1
  21. package/dist/chunks/{format-metadata-fields-Dh6CmU5G.cjs → format-metadata-fields-DPClLlzD.cjs} +1 -1
  22. package/dist/chunks/{format-metadata-owner-CCxXpga0.cjs → format-metadata-owner-ffrpq9D6.cjs} +1 -1
  23. package/dist/chunks/{generate-application-client-pMdNJ3g0.cjs → generate-application-client-DjE_Tp0M.cjs} +1 -1
  24. package/dist/chunks/{get-client-generation-skip-reason-DruQtHYQ.cjs → get-client-generation-skip-reason-DZmeP0IC.cjs} +1 -1
  25. package/dist/chunks/{get-system-view-universal-identifier.util-BjGghzoH-Cg8Rg3uX.cjs → get-system-view-universal-identifier.util-DgYnPEO1-CKEQWit5.cjs} +1 -1
  26. package/dist/chunks/global-flags.constant-C8Yu1rWc.cjs +1 -0
  27. package/dist/chunks/{is-access-token-expiring-BcJiLtlE.cjs → is-access-token-expiring-Cin0OQ-E.cjs} +1 -1
  28. package/dist/chunks/{is-application-not-found-error-C8ifQUn8.cjs → is-application-not-found-error-BAsQDAoQ.cjs} +1 -1
  29. package/dist/chunks/is-exported-manifest-COVWXnDs.cjs +1 -0
  30. package/dist/chunks/{is-valid-package-name-YNq-0I2a.cjs → is-valid-package-name-CfHS8_Lr.cjs} +1 -1
  31. package/dist/chunks/{locale-catalog-format-CFYxqgvL.cjs → locale-catalog-format-Cg9YplKA.cjs} +2 -2
  32. package/dist/chunks/metadata-Db5EuDpT.cjs +1 -0
  33. package/dist/chunks/parse-app-export-Dnu8mFrS.cjs +1 -0
  34. package/dist/chunks/{parse-graphql-response-C_4SPebO.cjs → parse-graphql-response-BSRJqolm.cjs} +1 -1
  35. package/dist/chunks/{parse-json-input-B87VP1pj.cjs → parse-json-input-CN9Wyj73.cjs} +1 -1
  36. package/dist/chunks/print-typescript-value-BsjFUceV.cjs +3 -0
  37. package/dist/chunks/pull-minimum-sdk-version.constant-BxmmUfee.cjs +6 -0
  38. package/dist/chunks/pull-source-BPng2lln.cjs +1 -0
  39. package/dist/chunks/{read-app-identity-DK9znGhT.cjs → read-app-identity-yX9-Ylxj.cjs} +1 -1
  40. package/dist/chunks/{read-application-identifier-BXkar-mo.cjs → read-application-identifier-DuI_jnU7.cjs} +1 -1
  41. package/dist/chunks/read-application-identity-BFQ0oOna.cjs +1 -0
  42. package/dist/chunks/{read-config-DWLaxc3C.cjs → read-config-DdGLulo-.cjs} +1 -1
  43. package/dist/chunks/{read-infer-deletion-option-BrShRRHT.cjs → read-infer-deletion-option-uFunybak.cjs} +1 -1
  44. package/dist/chunks/read-json-object-DcNHNB8I.cjs +1 -0
  45. package/dist/chunks/{read-local-container-C_kAPeoE.cjs → read-local-container-CPiVE1-D.cjs} +1 -1
  46. package/dist/chunks/{read-source-identity-BXYVcnXR.cjs → read-source-identity-CaErC5Qk.cjs} +1 -1
  47. package/dist/chunks/{record-pull-base-CkpPTblT.cjs → record-pull-base-RQ2mlIWr.cjs} +1 -1
  48. package/dist/chunks/{record-typecheck-config-inputs-DKn7fk11.cjs → record-typecheck-config-inputs-BAruvIZV.cjs} +1 -1
  49. package/dist/chunks/{request-oauth-tokens-C59XNnQs.cjs → request-oauth-tokens-Bp2eRh4F.cjs} +1 -1
  50. package/dist/chunks/{resolve-app-project-Cu1DLASA.cjs → resolve-app-project-aqOLK3Gb.cjs} +1 -1
  51. package/dist/chunks/{resolve-command-target-DXXwJ9aE.cjs → resolve-command-target-D4gMeXgA.cjs} +1 -1
  52. package/dist/chunks/{resolve-project-typescript-Dozy60cc.cjs → resolve-project-typescript-DkwXiCmt.cjs} +1 -1
  53. package/dist/chunks/{resolve-source-sdk-CizL-ZLW.cjs → resolve-source-sdk-CggXRBVx.cjs} +1 -1
  54. package/dist/chunks/{run-api-graphql-command-D_Gxp4_P.cjs → run-api-graphql-command-C3sJMP8H.cjs} +1 -1
  55. package/dist/chunks/{run-api-rest-command-Bm9KC7bB.cjs → run-api-rest-command-DQOP-cn8.cjs} +1 -1
  56. package/dist/chunks/run-app-add-command-qkKHuv9-.cjs +174 -0
  57. package/dist/chunks/{run-app-apply-command-pqnuwLNJ.cjs → run-app-apply-command-XNJHctjU.cjs} +1 -1
  58. package/dist/chunks/{run-app-build-command-DRslTZoC.cjs → run-app-build-command-CaInzuD2.cjs} +1 -1
  59. package/dist/chunks/{run-app-dev-command-9CKFKDBQ.cjs → run-app-dev-command-D6zVdTId.cjs} +1 -1
  60. package/dist/chunks/{run-app-exec-command-Bu_SM816.cjs → run-app-exec-command-DMHS9gpq.cjs} +2 -2
  61. package/dist/chunks/{run-app-generate-client-command-BKfbtgIG.cjs → run-app-generate-client-command-Ddq9lT40.cjs} +1 -1
  62. package/dist/chunks/{run-app-init-command-BDu78coZ.cjs → run-app-init-command-DcS8RfBK.cjs} +1 -1
  63. package/dist/chunks/{run-app-install-command-BNpFqYXx.cjs → run-app-install-command-DUB3JTon.cjs} +1 -1
  64. package/dist/chunks/{run-app-logs-command-DzQj1tdd.cjs → run-app-logs-command-CQHxh_Dt.cjs} +3 -3
  65. package/dist/chunks/{run-app-operation-Bj0hut-D.cjs → run-app-operation-KdXiXPb6.cjs} +1 -1
  66. package/dist/chunks/{run-app-plan-command-CIFK-61b.cjs → run-app-plan-command-DcjgbzTy.cjs} +1 -1
  67. package/dist/chunks/{run-app-publish-command-CuLrcX3d.cjs → run-app-publish-command-DEV9zgL1.cjs} +1 -1
  68. package/dist/chunks/{run-app-pull-command-CKoe_QKd.cjs → run-app-pull-command-B-hxnqvY.cjs} +3 -3
  69. package/dist/chunks/{run-app-translations-extract-command-riW4Ozc-.cjs → run-app-translations-extract-command-C0OfqFii.cjs} +1 -1
  70. package/dist/chunks/{run-app-typecheck-command-CPDDSwEm.cjs → run-app-typecheck-command-D2Po43IB.cjs} +1 -1
  71. package/dist/chunks/{run-app-uninstall-command-DFOMGmKw.cjs → run-app-uninstall-command-DXyjeBwO.cjs} +1 -1
  72. package/dist/chunks/run-auth-login-command-CVLvoJ7G.cjs +1 -0
  73. package/dist/chunks/{run-auth-logout-command-DjUjq_ug.cjs → run-auth-logout-command-ChrdwI-r.cjs} +1 -1
  74. package/dist/chunks/{run-auth-status-command-OAibzgLu.cjs → run-auth-status-command-X0m6rzI-.cjs} +1 -1
  75. package/dist/chunks/{run-cli-BjMuvO_y.cjs → run-cli-BoGzN25b.cjs} +8 -8
  76. package/dist/chunks/{run-commands-command-BhPkYc2t.cjs → run-commands-command-hMdnwU8-.cjs} +1 -1
  77. package/dist/chunks/{run-data-get-command-tV2bf5h6.cjs → run-data-get-command-DFE4NM2R.cjs} +1 -1
  78. package/dist/chunks/{run-data-list-command-D16ADH_r.cjs → run-data-list-command-BMEzitv6.cjs} +1 -1
  79. package/dist/chunks/{run-doctor-command-CEFSxor5.cjs → run-doctor-command-Bj2UR9ai.cjs} +2 -2
  80. package/dist/chunks/{run-local-logs-command-CkDxKsj7.cjs → run-local-logs-command-mUwB2XdV.cjs} +1 -1
  81. package/dist/chunks/{run-local-reset-command-pPzlL7jd.cjs → run-local-reset-command-WooW50PQ.cjs} +1 -1
  82. package/dist/chunks/{run-local-start-command-B_vDDsVi.cjs → run-local-start-command-CiXP155w.cjs} +1 -1
  83. package/dist/chunks/{run-local-status-command-CKh4246H.cjs → run-local-status-command-ClvEgxcU.cjs} +1 -1
  84. package/dist/chunks/{run-local-stop-command-BWJbZxK2.cjs → run-local-stop-command-BuV_YdJ7.cjs} +1 -1
  85. package/dist/chunks/{run-local-upgrade-command-CFDAkOsj.cjs → run-local-upgrade-command--O_EiVZc.cjs} +1 -1
  86. package/dist/chunks/{run-metadata-field-describe-command-D7q8KpLp.cjs → run-metadata-field-describe-command-iEw4KqIg.cjs} +1 -1
  87. package/dist/chunks/{run-metadata-field-list-command-yLteJu7m.cjs → run-metadata-field-list-command-YCsoqOo1.cjs} +1 -1
  88. package/dist/chunks/{run-metadata-object-describe-command-CHKnSf0E.cjs → run-metadata-object-describe-command-DpTobKR3.cjs} +1 -1
  89. package/dist/chunks/{run-metadata-object-list-command-D8CLvav9.cjs → run-metadata-object-list-command-BnSIIMDP.cjs} +1 -1
  90. package/dist/chunks/{run-open-command-CyBcIK9P.cjs → run-open-command-DWLQ7z_P.cjs} +1 -1
  91. package/dist/chunks/{run-remote-list-command-WKiOwCbu.cjs → run-remote-list-command-0f2QIf8C.cjs} +1 -1
  92. package/dist/chunks/{run-remote-remove-command-DPKQXI17.cjs → run-remote-remove-command-ClFB0Ub7.cjs} +1 -1
  93. package/dist/chunks/{run-remote-rename-command-CwuCickV.cjs → run-remote-rename-command-BVUcpZxq.cjs} +1 -1
  94. package/dist/chunks/{run-remote-use-command-BlB3SFV7.cjs → run-remote-use-command-ByRTqnq5.cjs} +1 -1
  95. package/dist/chunks/{run-version-command-BuWJdr6h.cjs → run-version-command-_9OGraNf.cjs} +1 -1
  96. package/dist/chunks/{select-target-DiY6zT7M.cjs → select-target-BHGEOc55.cjs} +1 -1
  97. package/dist/chunks/{sign-in-to-remote-again-DalF_h0k.cjs → sign-in-to-remote-again-DF27JFsz.cjs} +1 -1
  98. package/dist/chunks/{sign-in-with-browser-B2nBTir7.cjs → sign-in-with-browser-BNG4oa7e.cjs} +1 -1
  99. package/dist/chunks/{to-worker-output-diagnostics-CUKNJ_L6.cjs → to-worker-output-diagnostics-WZlUWvcj.cjs} +1 -1
  100. package/dist/chunks/{typecheck-application-BcS7ldNI.cjs → typecheck-application-BYPGp8lW.cjs} +1 -1
  101. package/dist/chunks/{update-config-D63n0BNZ.cjs → update-config-ClCVH3C5.cjs} +1 -1
  102. package/dist/chunks/{utils-BJdjZ6I2-DgqSVlwy.cjs → utils-Ds_lD5Ag-DfSfzJJP.cjs} +2 -2
  103. package/dist/chunks/{wait-for-local-environment-j4IZq_Nn.cjs → wait-for-local-environment-CjCRJnhK.cjs} +1 -1
  104. package/dist/chunks/{write-config-atomically-CkC-GT16.cjs → write-config-atomically-CQdFdvWo.cjs} +1 -1
  105. package/dist/cli.cjs +1 -1
  106. package/docs/commands.md +1 -1
  107. package/package.json +2 -2
  108. package/src/app/add/README.md +6 -6
  109. package/src/app/pull/README.md +6 -2
  110. package/dist/chunks/application-ChMyraCB.cjs +0 -5
  111. package/dist/chunks/compile-application-translations-Bp686pj4.cjs +0 -870
  112. package/dist/chunks/constants-BF6GWIop-98tUMN2U.cjs +0 -55
  113. package/dist/chunks/create-metadata-client-FcJiT9Hx.cjs +0 -6
  114. package/dist/chunks/create-pull-base-write-anQPBDx-.cjs +0 -1
  115. package/dist/chunks/extract-manifest-from-file-DA5fSI0W.cjs +0 -1
  116. package/dist/chunks/fetch-workspace-or-throw-BroNuadP.cjs +0 -1
  117. package/dist/chunks/global-flags.constant-BU7HyPk3.cjs +0 -1
  118. package/dist/chunks/is-exported-manifest-mJcgLfg0.cjs +0 -1
  119. package/dist/chunks/metadata-Cu3_OTI1.cjs +0 -1
  120. package/dist/chunks/parse-app-export-DAfsN3RE.cjs +0 -1
  121. package/dist/chunks/print-typescript-value-ChOUZ7Mm.cjs +0 -3
  122. package/dist/chunks/pull-minimum-sdk-version.constant-Dm7g3dNP.cjs +0 -5
  123. package/dist/chunks/pull-source-DvVJhvaO.cjs +0 -1
  124. package/dist/chunks/read-application-identity-D7fnqlw6.cjs +0 -1
  125. package/dist/chunks/read-json-object-B5Q55dbM.cjs +0 -1
  126. package/dist/chunks/run-app-add-command-BcuwnGCB.cjs +0 -163
  127. package/dist/chunks/run-auth-login-command-DOILzUGB.cjs +0 -1
@@ -6,9 +6,9 @@ __metadata:
6
6
  cacheKey: 10c0
7
7
 
8
8
  "@babel/runtime@npm:^7.29.7 || ^8.0.0":
9
- version: 8.0.10
10
- resolution: "@babel/runtime@npm:8.0.10"
11
- checksum: 10c0/c1a66577491f2beed448df8847051307d83ed3c1c22332bb338499d44542f2702227b2b546bbcfde8b1690e6f32de7ae4e8bee7d8b2e330d045caf6a766bfcf8
9
+ version: 8.1.0
10
+ resolution: "@babel/runtime@npm:8.1.0"
11
+ checksum: 10c0/4531254e3a031cb392b5a363eecce35592c944c656fb7a3a7ac619cbcc05007a8ceca56e3f438aabca17a5ef0d1d18ab54957cd6c5d16a0f2d088850b10a1a83
12
12
  languageName: node
13
13
  linkType: hard
14
14
 
@@ -774,9 +774,9 @@ __metadata:
774
774
  oxlint: "npm:^0.16.0"
775
775
  react: "npm:^19.0.0"
776
776
  react-dom: "npm:^19.0.0"
777
- twenty-client-sdk: "npm:2.55.0"
778
- twenty-sdk: "npm:2.55.0"
779
- twenty-ui: "npm:2.55.0"
777
+ twenty-client-sdk: "npm:2.57.0"
778
+ twenty-sdk: "npm:2.57.0"
779
+ twenty-ui: "npm:2.57.0"
780
780
  typescript: "npm:^5.9.3"
781
781
  vite-tsconfig-paths: "npm:^4.2.1"
782
782
  vitest: "npm:^4.1.12"
@@ -1058,9 +1058,9 @@ __metadata:
1058
1058
  linkType: hard
1059
1059
 
1060
1060
  "graphql@npm:^16.8.1":
1061
- version: 16.14.2
1062
- resolution: "graphql@npm:16.14.2"
1063
- checksum: 10c0/a95a96961eaff55cc9fe9d31fae6f33499ac988b972d07ea5085024cb1333f515b902f376e7393a5489aa82200a8aff3eb96580e4d1b69d702ed19b6eb1ce97a
1061
+ version: 16.15.0
1062
+ resolution: "graphql@npm:16.15.0"
1063
+ checksum: 10c0/b97c78a02dab6392cdc492e78290bca479b5881dbeeefaed79cc88128b0e9a810feea043da61c5cd086f1af645dc9c46d61ed5297995031d8542a11c94f7cd0f
1064
1064
  languageName: node
1065
1065
  linkType: hard
1066
1066
 
@@ -1365,7 +1365,7 @@ __metadata:
1365
1365
  languageName: node
1366
1366
  linkType: hard
1367
1367
 
1368
- "postcss@npm:^8.5.30":
1368
+ "postcss@npm:^8.5.32":
1369
1369
  version: 8.5.32
1370
1370
  resolution: "postcss@npm:8.5.32"
1371
1371
  dependencies:
@@ -1377,14 +1377,14 @@ __metadata:
1377
1377
  linkType: hard
1378
1378
 
1379
1379
  "preact@npm:^11.0.0":
1380
- version: 11.1.1
1381
- resolution: "preact@npm:11.1.1"
1380
+ version: 11.2.0
1381
+ resolution: "preact@npm:11.2.0"
1382
1382
  peerDependencies:
1383
1383
  preact-render-to-string: ">=6.7.0"
1384
1384
  peerDependenciesMeta:
1385
1385
  preact-render-to-string:
1386
1386
  optional: true
1387
- checksum: 10c0/405e3b51cd29e916934583b557de1880f3102f70c90c23cb68ceba0ecf6710d69bea525faabb82f21e3a28a8883c31f0ccf8ebaf5965ca05cb047b0e275c9782
1387
+ checksum: 10c0/fe41726420bd65227eae2c8ca134d2933fe20a072a811fad36d49ccdff033dcbd76faa5f7215c2ca2d00d35cc0186231d2350e59309d1ccb7e1a56799f3e81e9
1388
1388
  languageName: node
1389
1389
  linkType: hard
1390
1390
 
@@ -1447,7 +1447,7 @@ __metadata:
1447
1447
  languageName: node
1448
1448
  linkType: hard
1449
1449
 
1450
- "rolldown@npm:~1.2.14":
1450
+ "rolldown@npm:~1.2.16":
1451
1451
  version: 1.2.16
1452
1452
  resolution: "rolldown@npm:1.2.16"
1453
1453
  dependencies:
@@ -1513,11 +1513,11 @@ __metadata:
1513
1513
  linkType: hard
1514
1514
 
1515
1515
  "semver@npm:^7.3.5":
1516
- version: 7.8.5
1517
- resolution: "semver@npm:7.8.5"
1516
+ version: 7.8.6
1517
+ resolution: "semver@npm:7.8.6"
1518
1518
  bin:
1519
1519
  semver: bin/semver.js
1520
- checksum: 10c0/b1f3127a5be8125a94f37188b361c212466c292c6910adce3ec106cff5dc211ccaedc4739c11bb70fda59d6fc1f040a9bca289f4e093451521a2372e5231fe0c
1520
+ checksum: 10c0/bf0a4d16eb067e5391323649e46b4a268644d7f8ee88e37c7668d35e861ec145b6e7df576d898007fc0d9a2cedcbc33f71460aa3bbea18eedfa5af58c064d7fe
1521
1521
  languageName: node
1522
1522
  linkType: hard
1523
1523
 
@@ -1657,37 +1657,37 @@ __metadata:
1657
1657
  languageName: node
1658
1658
  linkType: hard
1659
1659
 
1660
- "twenty-client-sdk@npm:2.55.0":
1661
- version: 2.55.0
1662
- resolution: "twenty-client-sdk@npm:2.55.0"
1660
+ "twenty-client-sdk@npm:2.57.0":
1661
+ version: 2.57.0
1662
+ resolution: "twenty-client-sdk@npm:2.57.0"
1663
1663
  dependencies:
1664
1664
  "@genql/runtime": "npm:^2.10.0"
1665
1665
  esbuild: "npm:^0.28.1"
1666
1666
  graphql: "npm:^16.8.1"
1667
1667
  lodash: "npm:^4.17.21"
1668
1668
  prettier: "npm:^3.8.3"
1669
- checksum: 10c0/d9084dbde9215c886749f2bc0870c0a4002a9f32a8b9ab83346303c548375bf136ad56776e33eb9293d4f8e9174ca099160228b57fe92b810925a42835c69c48
1669
+ checksum: 10c0/becff40550ee933466889bcbc833f0bae685b4c11479405f8499210fcf8517c7b75df7e76e8331173bc5dce3335d86247ba670f92b537969935a5bb3bdb3d4f6
1670
1670
  languageName: node
1671
1671
  linkType: hard
1672
1672
 
1673
- "twenty-sdk@npm:2.55.0":
1674
- version: 2.55.0
1675
- resolution: "twenty-sdk@npm:2.55.0"
1673
+ "twenty-sdk@npm:2.57.0":
1674
+ version: 2.57.0
1675
+ resolution: "twenty-sdk@npm:2.57.0"
1676
1676
  dependencies:
1677
1677
  "@sniptt/guards": "npm:^0.2.0"
1678
1678
  esbuild: "npm:^0.28.1"
1679
1679
  preact: "npm:^11.0.0"
1680
1680
  react: "npm:^19.2.0"
1681
1681
  react-dom: "npm:^19.2.0"
1682
- twenty-client-sdk: "npm:2.55.0"
1682
+ twenty-client-sdk: "npm:2.57.0"
1683
1683
  uuid: "npm:^13.0.2"
1684
- checksum: 10c0/9e85ff1bfb01b36801a8ad380a4f16c5d0f9a1ed65195d1040dea4a22689512e36d7864274dacfc43b792012a8abc1c01deadd602813776f855701f5b788f031
1684
+ checksum: 10c0/e7993ab3e8de72bbb65f0b50efd50829d0936b5228e548e3d8cb7da6443e456e590c8574847434d0dd142bef09c64251ba2f5707fb495563bf9759fa73e4afed
1685
1685
  languageName: node
1686
1686
  linkType: hard
1687
1687
 
1688
- "twenty-ui@npm:2.55.0":
1689
- version: 2.55.0
1690
- resolution: "twenty-ui@npm:2.55.0"
1688
+ "twenty-ui@npm:2.57.0":
1689
+ version: 2.57.0
1690
+ resolution: "twenty-ui@npm:2.57.0"
1691
1691
  dependencies:
1692
1692
  "@base-ui/react": "npm:^1.9.0"
1693
1693
  "@base-ui/utils": "npm:0.5.0"
@@ -1707,7 +1707,7 @@ __metadata:
1707
1707
  optional: true
1708
1708
  monaco-editor:
1709
1709
  optional: true
1710
- checksum: 10c0/f7a1ced5afc211feacd1599e34cfff2b90cbbdc10fce10e32bd6751cd05051455ccadb424ef0b4d32fcefb7f456b412081d8f95708b91562d8dc1ef44b5dca83
1710
+ checksum: 10c0/24768fafa69d7b02aca270b0bb8cdd6b31df9c7dee7d9073d30ee4e956011e6adeba622b65cb26d2ce904f05602a405c7893eccafb458bf586eb54b8e5e71282
1711
1711
  languageName: node
1712
1712
  linkType: hard
1713
1713
 
@@ -1753,9 +1753,9 @@ __metadata:
1753
1753
  linkType: hard
1754
1754
 
1755
1755
  "undici@npm:^8.4.1":
1756
- version: 8.12.3
1757
- resolution: "undici@npm:8.12.3"
1758
- checksum: 10c0/714919e62b4160eea195fb35c7f5c4907235741e47bfde8a014ac58f6d24df13434e23400d7f48e2c455fd2b259d27f07fce514f04a5b4e99936ba62cbc4bb71
1756
+ version: 8.12.4
1757
+ resolution: "undici@npm:8.12.4"
1758
+ checksum: 10c0/2a83590ce3347ca4e8fb83917bd7ad1d0bcb72ecb6d1a5066f01a89b4941becac569412aa27d7318119ea1a20d217018cce535f8eeed3c1b307d87426f96cfe3
1759
1759
  languageName: node
1760
1760
  linkType: hard
1761
1761
 
@@ -1808,14 +1808,14 @@ __metadata:
1808
1808
  linkType: hard
1809
1809
 
1810
1810
  "vite@npm:^6.0.0 || ^7.0.0 || ^8.0.0":
1811
- version: 8.3.5
1812
- resolution: "vite@npm:8.3.5"
1811
+ version: 8.3.6
1812
+ resolution: "vite@npm:8.3.6"
1813
1813
  dependencies:
1814
1814
  fsevents: "npm:~2.3.3"
1815
1815
  lightningcss: "npm:^1.33.0"
1816
1816
  picomatch: "npm:^4.0.7"
1817
- postcss: "npm:^8.5.30"
1818
- rolldown: "npm:~1.2.14"
1817
+ postcss: "npm:^8.5.32"
1818
+ rolldown: "npm:~1.2.16"
1819
1819
  tinyglobby: "npm:^0.2.17"
1820
1820
  peerDependencies:
1821
1821
  "@types/node": ^20.19.0 || >=22.12.0
@@ -1860,7 +1860,7 @@ __metadata:
1860
1860
  optional: true
1861
1861
  bin:
1862
1862
  vite: bin/vite.js
1863
- checksum: 10c0/33991600925b6717429c14a2c2907554aed077489ee6ff7815f9f49d5de559f5173ccb0472f2b3f9eef2a49e2e014f6cb624db8d4adebb37baad3a8cbc15065a
1863
+ checksum: 10c0/59182f98865b9d41139edcc6ba7873fd63db9f30a6bb14d4b5125326cad1c1cda0aaeded4c0730c4a907991b7759119697296613bd9c4504a1d9db8fa7c6aa75
1864
1864
  languageName: node
1865
1865
  linkType: hard
1866
1866
 
@@ -1 +1 @@
1
- const e=require("./chunks/build--4zYt4wd.cjs"),t=require("./chunks/isDefined-Dtu5EYqP-CJctgvfE.cjs"),n=require("./chunks/constants-BF6GWIop-98tUMN2U.cjs");var r=e.t(),i=5e3,a=new AbortController,o,s=e=>{if(n.a(e)){if(e.type===`cancel`||e.type===`release`)return{type:e.type};if(e.type===`readSourceIdentity`||e.type===`buildManifest`||e.type===`typecheckSource`)return(0,r.isNonEmptyString)(e.appPath)?{type:e.type,appPath:e.appPath}:void 0;if(e.type===`bundleSnapshot`)return(0,r.isNonEmptyString)(e.appPath)?{type:`bundleSnapshot`,collectWatchInputs:e.collectWatchInputs===!0,appPath:e.appPath,holdSnapshot:e.holdSnapshot===!0}:void 0;if(e.type===`pull`)return!(0,r.isNonEmptyString)(e.appPath)||!n.a(e.target)||!(0,r.isNonEmptyString)(e.target.apiUrl)||!(0,r.isNonEmptyString)(e.target.workspaceId)||!n.a(e.applicationExport)||!n.a(e.applicationExport.application)||!(0,r.isNonEmptyString)(e.applicationExport.application.universalIdentifier)?void 0:{type:`pull`,appPath:e.appPath,target:{apiUrl:e.target.apiUrl,workspaceId:e.target.workspaceId},applicationExport:e.applicationExport};if(e.type===`extractTranslations`)return(0,r.isNonEmptyString)(e.appPath)&&(!t.t(e.locale)||(0,r.isString)(e.locale))?{type:`extractTranslations`,appPath:e.appPath,locale:e.locale??void 0}:void 0;if(e.type===`generateSourceClient`)return(0,r.isNonEmptyString)(e.appPath)&&(0,r.isString)(e.schema)?{type:`generateSourceClient`,appPath:e.appPath,schema:e.schema}:void 0}},c=e=>{process.connected||process.exit(1),process.send?.(e,void 0,{},()=>process.exit(0))},l=async()=>{if(!t.t(o))return null;let{snapshotApi:e,buildId:n}=o;return o=void 0,e.releaseSourceSnapshot({buildId:n})},u=()=>{l().then(()=>process.exit(1),()=>process.exit(1))},d=e=>{if(!process.connected){u();return}process.send?.(e)},f=e=>{if(!(!n.a(e)||e.success!==!0||!n.a(e.data)))return(0,r.isNonEmptyString)(e.data.buildId)?e.data.buildId:void 0},p=async({snapshotApi:e,appPath:n,holdSnapshot:r})=>{let i=a.signal,s=await e.buildSourceSnapshot({appPath:n,signal:i}),c=f(s);return t.t(c)?r?(o={snapshotApi:e,buildId:c},{type:`result`,result:s,isSnapshotHeld:!0}):{type:`result`,result:s,release:await e.releaseSourceSnapshot({buildId:c}),isSnapshotHeld:!1}:{type:`result`,result:s,isSnapshotHeld:!1}},m=e=>({type:`failure`,message:e instanceof Error?e.message:String(e),...e instanceof Error&&`code`in e&&(0,r.isString)(e.code)?{code:e.code}:{},...e instanceof Error&&`hint`in e&&(0,r.isString)(e.hint)?{hint:e.hint}:{},...e instanceof Error&&`details`in e&&n.a(e.details)?{details:e.details}:{}});process.on(`SIGINT`,()=>void 0),process.on(`disconnect`,()=>{a.abort(),setTimeout(()=>process.exit(1),i),t.t(o)&&u()}),process.on(`message`,e=>{let n=s(e);if(!t.t(n)){c({type:`failure`,message:`The app worker received a request it cannot read.`});return}if(n.type===`cancel`){a.abort();return}if(n.type===`release`){l().then(e=>c({type:`released`,release:e}),e=>c(m(e)));return}if(n.type===`pull`){Promise.resolve().then(()=>require("./chunks/pull-source-DvVJhvaO.cjs")).then(async({pullSource:e})=>{c({type:`result`,result:await e({...n,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`bundleSnapshot`){Promise.resolve().then(()=>require("./chunks/build-source-snapshot-CpGCu13I.cjs")).then(async({buildSourceSnapshot:e,releaseSourceSnapshot:t})=>{let r=()=>p({snapshotApi:{buildSourceSnapshot:e,releaseSourceSnapshot:t},appPath:n.appPath,holdSnapshot:n.holdSnapshot});if(!n.collectWatchInputs)return r();let{collectWatchInputs:i}=await Promise.resolve().then(()=>require("./chunks/collect-watch-inputs-Dn6g1cNu.cjs")).then(e=>e.t),{recordTypecheckConfigInputs:a}=await Promise.resolve().then(()=>require("./chunks/record-typecheck-config-inputs-DKn7fk11.cjs")),o=await i(async()=>(await a(n.appPath),r()));return{...o.result,watchInputs:o.watchInputs}}).then(e=>e.type===`result`&&e.isSnapshotHeld?d(e):c(e),e=>c(m(e)));return}if(n.type===`typecheckSource`){Promise.resolve().then(()=>require("./chunks/typecheck-application-BcS7ldNI.cjs")).then(e=>e.n).then(async({typecheckApplication:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`extractTranslations`){Promise.resolve().then(()=>require("./chunks/extract-source-translations-DhYrd7jw.cjs")).then(async({extractSourceTranslations:e})=>{c({type:`result`,result:await e({appPath:n.appPath,locale:n.locale,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`buildManifest`){Promise.resolve().then(()=>require("./chunks/build-source-manifest-CS9qVNh-.cjs")).then(async({buildSourceManifest:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`readSourceIdentity`){Promise.resolve().then(()=>require("./chunks/read-source-identity-BXYVcnXR.cjs")).then(async({readSourceIdentity:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`generateSourceClient`){Promise.resolve().then(()=>require("./chunks/generate-application-client-pMdNJ3g0.cjs")).then(async({generateApplicationClient:e})=>{c({type:`result`,result:await e({appPath:n.appPath,schema:n.schema,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}});
1
+ const e=require("./chunks/build--4zYt4wd.cjs"),t=require("./chunks/isDefined-Dtu5EYqP-CJctgvfE.cjs"),n=require("./chunks/constants-Bw_pUpSi-BsJPlw-e.cjs");var r=e.t(),i=5e3,a=new AbortController,o,s=e=>{if(n.i(e)){if(e.type===`cancel`||e.type===`release`)return{type:e.type};if(e.type===`readSourceIdentity`||e.type===`buildManifest`||e.type===`typecheckSource`)return(0,r.isNonEmptyString)(e.appPath)?{type:e.type,appPath:e.appPath}:void 0;if(e.type===`bundleSnapshot`)return(0,r.isNonEmptyString)(e.appPath)?{type:`bundleSnapshot`,collectWatchInputs:e.collectWatchInputs===!0,appPath:e.appPath,holdSnapshot:e.holdSnapshot===!0}:void 0;if(e.type===`pull`)return!(0,r.isNonEmptyString)(e.appPath)||!n.i(e.target)||!(0,r.isNonEmptyString)(e.target.apiUrl)||!(0,r.isNonEmptyString)(e.target.workspaceId)||!n.i(e.applicationExport)||!n.i(e.applicationExport.application)||!(0,r.isNonEmptyString)(e.applicationExport.application.universalIdentifier)?void 0:{type:`pull`,appPath:e.appPath,target:{apiUrl:e.target.apiUrl,workspaceId:e.target.workspaceId},applicationExport:e.applicationExport};if(e.type===`extractTranslations`)return(0,r.isNonEmptyString)(e.appPath)&&(!t.t(e.locale)||(0,r.isString)(e.locale))?{type:`extractTranslations`,appPath:e.appPath,locale:e.locale??void 0}:void 0;if(e.type===`generateSourceClient`)return(0,r.isNonEmptyString)(e.appPath)&&(0,r.isString)(e.schema)?{type:`generateSourceClient`,appPath:e.appPath,schema:e.schema}:void 0}},c=e=>{process.connected||process.exit(1),process.send?.(e,void 0,{},()=>process.exit(0))},l=async()=>{if(!t.t(o))return null;let{snapshotApi:e,buildId:n}=o;return o=void 0,e.releaseSourceSnapshot({buildId:n})},u=()=>{l().then(()=>process.exit(1),()=>process.exit(1))},d=e=>{if(!process.connected){u();return}process.send?.(e)},f=e=>{if(!(!n.i(e)||e.success!==!0||!n.i(e.data)))return(0,r.isNonEmptyString)(e.data.buildId)?e.data.buildId:void 0},p=async({snapshotApi:e,appPath:n,holdSnapshot:r})=>{let i=a.signal,s=await e.buildSourceSnapshot({appPath:n,signal:i}),c=f(s);return t.t(c)?r?(o={snapshotApi:e,buildId:c},{type:`result`,result:s,isSnapshotHeld:!0}):{type:`result`,result:s,release:await e.releaseSourceSnapshot({buildId:c}),isSnapshotHeld:!1}:{type:`result`,result:s,isSnapshotHeld:!1}},m=e=>({type:`failure`,message:e instanceof Error?e.message:String(e),...e instanceof Error&&`code`in e&&(0,r.isString)(e.code)?{code:e.code}:{},...e instanceof Error&&`hint`in e&&(0,r.isString)(e.hint)?{hint:e.hint}:{},...e instanceof Error&&`details`in e&&n.i(e.details)?{details:e.details}:{}});process.on(`SIGINT`,()=>void 0),process.on(`disconnect`,()=>{a.abort(),setTimeout(()=>process.exit(1),i),t.t(o)&&u()}),process.on(`message`,e=>{let n=s(e);if(!t.t(n)){c({type:`failure`,message:`The app worker received a request it cannot read.`});return}if(n.type===`cancel`){a.abort();return}if(n.type===`release`){l().then(e=>c({type:`released`,release:e}),e=>c(m(e)));return}if(n.type===`pull`){Promise.resolve().then(()=>require("./chunks/pull-source-BPng2lln.cjs")).then(async({pullSource:e})=>{c({type:`result`,result:await e({...n,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`bundleSnapshot`){Promise.resolve().then(()=>require("./chunks/build-source-snapshot-CzwiB8HK.cjs")).then(async({buildSourceSnapshot:e,releaseSourceSnapshot:t})=>{let r=()=>p({snapshotApi:{buildSourceSnapshot:e,releaseSourceSnapshot:t},appPath:n.appPath,holdSnapshot:n.holdSnapshot});if(!n.collectWatchInputs)return r();let{collectWatchInputs:i}=await Promise.resolve().then(()=>require("./chunks/collect-watch-inputs-Dn6g1cNu.cjs")).then(e=>e.t),{recordTypecheckConfigInputs:a}=await Promise.resolve().then(()=>require("./chunks/record-typecheck-config-inputs-BAruvIZV.cjs")),o=await i(async()=>(await a(n.appPath),r()));return{...o.result,watchInputs:o.watchInputs}}).then(e=>e.type===`result`&&e.isSnapshotHeld?d(e):c(e),e=>c(m(e)));return}if(n.type===`typecheckSource`){Promise.resolve().then(()=>require("./chunks/typecheck-application-BYPGp8lW.cjs")).then(e=>e.n).then(async({typecheckApplication:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`extractTranslations`){Promise.resolve().then(()=>require("./chunks/extract-source-translations-BHWNS2e9.cjs")).then(async({extractSourceTranslations:e})=>{c({type:`result`,result:await e({appPath:n.appPath,locale:n.locale,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`buildManifest`){Promise.resolve().then(()=>require("./chunks/build-source-manifest-tGYOCdor.cjs")).then(async({buildSourceManifest:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`readSourceIdentity`){Promise.resolve().then(()=>require("./chunks/read-source-identity-CaErC5Qk.cjs")).then(async({readSourceIdentity:e})=>{c({type:`result`,result:await e({appPath:n.appPath,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}if(n.type===`generateSourceClient`){Promise.resolve().then(()=>require("./chunks/generate-application-client-DjE_Tp0M.cjs")).then(async({generateApplicationClient:e})=>{c({type:`result`,result:await e({appPath:n.appPath,schema:n.schema,signal:a.signal}),isSnapshotHeld:!1})}).catch(e=>c(m(e)));return}});
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return`Pipe it in, for example: printf '%s' "$TWENTY_API_KEY" | twenty auth login --with-token --url <url>`}});
@@ -0,0 +1,5 @@
1
+ const e=require("./build--4zYt4wd.cjs"),t=require("./utils-Ds_lD5Ag-DfSfzJJP.cjs"),n=require("./isDefined-Dtu5EYqP-CJctgvfE.cjs"),r=require("./constants-Bw_pUpSi-BsJPlw-e.cjs"),i=require("./get-system-view-universal-identifier.util-DgYnPEO1-CKEQWit5.cjs");var a={invalid_type:`invalid_type`,too_big:`too_big`,too_small:`too_small`,invalid_format:`invalid_format`,not_multiple_of:`not_multiple_of`,unrecognized_keys:`unrecognized_keys`,invalid_union:`invalid_union`,invalid_key:`invalid_key`,invalid_element:`invalid_element`,invalid_value:`invalid_value`,custom:`custom`},o;o||={};function s(e){if(!i.p(e))throw TypeError(`Invalid UUID`);return parseInt(e.slice(14,15),16)}function c(e){return e instanceof Boolean||typeof e==`boolean`}function l(e){return e instanceof String||typeof e==`string`}function u(e){return e!=null&&(typeof e==`object`||typeof e==`function`)&&!Array.isArray(e)}var d=[`choice`,`score`,`boolean`],f=e=>new Set(e).size!==e.length,p=e=>n.t(e)&&(f((e.objectPermissions??[]).map(({objectUniversalIdentifier:e})=>e))||f((e.fieldPermissions??[]).map(({fieldUniversalIdentifier:e})=>e))),m=/^[a-zA-Z0-9_.-]{1,64}$/,h=e=>m.test(e),g=e.t(),_=r.ct({objectUniversalIdentifier:r.lt(),canReadObjectRecords:r.X().optional(),canUpdateObjectRecords:r.X().optional(),canSoftDeleteObjectRecords:r.X().optional(),canDestroyObjectRecords:r.X().optional()}),ee=r.ct({objectUniversalIdentifier:r.lt(),fieldUniversalIdentifier:r.lt(),canReadFieldValue:r.X().optional(),canUpdateFieldValue:r.X().optional()}),v=r.ct({canReadAllObjectRecords:r.X().optional(),canUpdateAllObjectRecords:r.X().optional(),canSoftDeleteAllObjectRecords:r.X().optional(),canDestroyAllObjectRecords:r.X().optional(),canUpdateAllSettings:r.X().optional(),canAccessAllTools:r.X().optional(),canAccessAllAgentChatChannels:r.X().optional(),objectPermissions:r.Y(_).optional(),fieldPermissions:r.Y(ee).optional(),permissionFlagUniversalIdentifiers:r.Y(r.lt()).optional()}).omit({canAccessAllAgentChatChannels:!0}),te=r.at({type:r.tt(`object`),properties:r.st(r.lt(),r.at({type:r.K([`string`,`number`,`boolean`]),description:r.lt().optional()})).refine(e=>Object.keys(e).every(h),{message:`Output field names can only contain letters, numbers, underscores, dots or hyphens (max 64 characters)`}),required:r.Y(r.lt()).optional(),additionalProperties:r.tt(!1).optional()}),y=r.Z(`type`,[r.at({type:r.tt(`text`)}),r.at({type:r.tt(`json`),schema:te})]),b=`trigger`,x=e=>{let t=[],n=``,r=!1,i=0;for(;i<e.length;){let a=e[i];if(a===`[`&&!r){n.length>0&&(t.push(n),n=``),r=!0,i++;continue}if(a===`]`&&r){t.push(n),n=``,r=!1,i++,i<e.length&&e[i]===`.`&&i++;continue}if(a===`.`&&!r){n.length>0&&(t.push(n),n=``),i++;continue}n+=a,i++}return n.length>0&&t.push(n),t},ne=/{{([^{}]+)}}/g;function*S(e){if((0,g.isString)(e)){for(let[,t]of e.matchAll(ne))n.t(t)&&(yield t);return}if((0,g.isObject)(e))for(let t of Object.values(e))yield*S(t)}var re=e=>[...S(e)],ie=(e,t)=>{let n=e.length+1,r=t.length+1,i=Array.from({length:n},()=>Array(r).fill(0));for(let e=0;e<n;e++)i[e][0]=e;for(let e=0;e<r;e++)i[0][e]=e;for(let a=1;a<n;a++){let n=i[a-1],o=i[a];for(let i=1;i<r;i++){let r=e[a-1]===t[i-1]?0:1;o[i]=Math.min(n[i]+1,o[i-1]+1,n[i-1]+r)}}return i[e.length][t.length]},C=e=>{if(!n.t(e)||!u(e)||Array.isArray(e))return!1;let t=Object.values(e);return t.length!==0&&t.every(e=>n.t(e)&&u(e)&&c(e.isLeaf))},ae=(e,t=[])=>{let n=[];if(!(0,g.isObject)(e))return n;for(let[r,i]of Object.entries(e)){if(!(0,g.isObject)(i))continue;let e=[...t,r];n.push(e.join(`.`)),!i.isLeaf&&(0,g.isObject)(i.value)&&n.push(...ae(i.value,e))}return n},oe=({schema:e,propertyPath:t})=>{let r=e;for(let e=0;e<t.length;e++){let i=t[e];if(!n.t(i))return;if(!(0,g.isObject)(r))return{validPrefix:t.slice(0,e),failedSegment:i,availableKeys:[]};let a=r[i];if(!n.t(a))return{validPrefix:t.slice(0,e),failedSegment:i,availableKeys:Object.keys(r)};if(a.isLeaf){let r=t[e+1];return n.t(r)?{validPrefix:t.slice(0,e+1),failedSegment:r,availableKeys:[]}:void 0}r=a.value}},w={found:!1},T=e=>r.i(e)&&c(e.isLeaf),E=e=>r.i(e)&&e._outputSchemaType===`RECORD`&&r.i(e.fields),se=e=>r.i(e)&&!(`_outputSchemaType`in e)&&T(e.first)&&e.first.isLeaf===!1&&E(e.first.value)&&T(e.totalCount),ce=e=>({found:!0,type:l(e.type)?e.type:void 0,label:l(e.label)?e.label:void 0}),le=(e,t)=>t.length===0?ce(e):pe(e.value,t),ue=(e,t)=>{for(let n=1;n<=t.length;n++){let r=e[t.slice(0,n).join(`.`)];if(T(r))return le(r,t.slice(n))}return w},de=(e,t)=>{let[n,...r]=t;if(n===`first`)return r.length===0?ce(e.first):pe(e.first.value,r);if(n===`all`||n===`totalCount`){let t=e[n];return r.length===0&&T(t)?ce(t):w}return w},fe=(e,t)=>{let[i,...a]=t;if(!n.t(i))return w;let o=e[i];return T(o)?le(o,a):n.t(o)?a.length===0?{found:!0}:r.i(o)?fe(o,a):w:w},pe=(e,t)=>t.length===0||!r.i(e)?w:E(e)?ue(e.fields,t):se(e)?de(e,t):fe(e,t),me=({schema:e,propertyPath:t})=>pe(e,t),D=e=>{let t=[];for(let[i,a]of Object.entries(e))if(T(a)){if(t.push(i),a.isLeaf)continue;let e=a.value;if(E(e))for(let n of D(e.fields))t.push(`${i}.${n}`);else if(r.i(e))for(let n of D(e))t.push(`${i}.${n}`)}else if(n.t(a)&&(t.push(i),r.i(a)))for(let e of D(a))t.push(`${i}.${e}`);return t},he=e=>{if(!r.i(e))return[];if(E(e))return D(e.fields);if(se(e)){let t=[];if(T(e.first)){t.push(`first`);for(let n of he(e.first.value))t.push(`first.${n}`)}return n.t(e.all)&&t.push(`all`),t.push(`totalCount`),t}return D(e)},ge=3,_e=e=>r.i(e)?e._outputSchemaType===`RECORD`||Object.values(e).some(e=>r.i(e)&&_e(e.value)):!1,ve=(e,t)=>t.map(t=>({candidate:t,distance:ie(e,t)})).filter(({candidate:e,distance:t})=>t<=Math.ceil(e.length/2)).sort((e,t)=>e.distance-t.distance).slice(0,ge).map(({candidate:e})=>e),ye=({schema:e,propertyPath:t,referencedStepId:r})=>{if(!C(e)||_e(e)){let n=he(e);return ve(t.join(`.`),n).map(e=>[r,e].join(`.`))}let i=oe({schema:e,propertyPath:t});if(!n.t(i))return[];let a=ve(i.failedSegment,i.availableKeys).map(e=>[r,...i.validPrefix,e].join(`.`));if((0,g.isNonEmptyArray)(a))return a;let o=ae(e);return ve(t.join(`.`),o).map(e=>[r,e].join(`.`))},be=e=>{if(e.type!==`CODE`||!(0,g.isObject)(e.settings?.input))return e.settings?.input;if(`logicFunctionInput`in e.settings.input)return e.settings.input.logicFunctionInput},xe=({workflow:e,graph:t,stepsById:r})=>{let i=[],a=new Set(e.steps?.map(e=>e.id)??[]);for(let o of e.steps??[]){let s=re(be(o)),c=t.ancestorsByStepId.get(o.id)??new Set;for(let t of s){let s=x(t),l=s[0];if(!n.t(l)){i.push({severity:`error`,code:`VARIABLE_INVALID_PATH`,message:`Step "${o.name??o.id}" has a variable "{{${t}}}" with an invalid path. Variable references must start with a step ID, e.g. "{{stepId.property}}".`,stepId:o.id,path:t});continue}let u=l===b;if(!u&&!a.has(l)){i.push({severity:`error`,code:`VARIABLE_UNKNOWN_STEP`,message:`Step "${o.name??o.id}" references variable "{{${t}}}" from an unknown step "${l}".`,stepId:o.id,path:t});continue}let d=l===o.id;if(!u&&!d&&!c.has(l)){let e=r.get(l)?.name??l;i.push({severity:`error`,code:`VARIABLE_NOT_UPSTREAM`,message:`Step "${o.name??o.id}" references variable "{{${t}}}" from step "${e}", which does not run before it. Ensure step "${e}" is an ancestor (connected via nextStepIds chain from the trigger, before this step).`,stepId:o.id,path:t});continue}i.push(...Se({step:o,variable:t,pathSegments:s,referencedStepId:l,isTriggerReference:u,trigger:e.trigger,stepsById:r}))}}return i},Se=({step:e,variable:t,pathSegments:r,referencedStepId:i,isTriggerReference:a,trigger:o,stepsById:s})=>{let c=r.slice(1);if(c.length===0)return[];let l=a?o?.settings?.outputSchema:s.get(i)?.settings?.outputSchema,u=n.t(l)&&(0,g.isObject)(l)&&!Array.isArray(l)&&Object.keys(l).length===0;if(!n.t(l)||u)return[];if(!me({schema:l,propertyPath:c}).found){let r=ye({schema:l,propertyPath:c,referencedStepId:i}),a=we(l,i),o=(0,g.isNonEmptyArray)(r)?`Did you mean "{{${r[0]}}}"?${r.length>1?` Other options: ${r.slice(1).map(e=>`{{${e}}}`).join(`, `)}.`:``}`:(0,g.isNonEmptyArray)(a)?`Available paths: ${a.map(e=>`{{${e}}}`).join(`, `)}.`:void 0;return[{severity:`error`,code:`VARIABLE_PATH_NOT_FOUND`,message:`Step "${e.name??e.id}" references variable "{{${t}}}" but the path "${c.join(`.`)}" was not found in the output of step "${i}".`,stepId:e.id,path:t,...n.t(o)?{hint:o}:{},...(0,g.isNonEmptyArray)(r)?{suggestions:r}:{},...(0,g.isNonEmptyArray)(a)?{availablePaths:a}:{}}]}return[]},Ce=20,we=(e,t)=>he(e).slice(0,Ce).map(e=>`${t}.${e}`),Te=256e3,Ee=[1e3,5e3,15e3],O=r.at({input:r.nt({}).describe(`Input data for the workflow action. Structure depends on the action type.`),outputSchema:r.nt({}).describe(`Schema defining the output data structure. This data can be referenced in subsequent steps using {{stepId.fieldName}}.`),errorHandlingOptions:r.at({retryOnFailure:r.at({value:r.ot(e=>typeof e==`boolean`?Number(e):e,r.it().int().min(0).max(Ee.length).describe(`How many times to retry the action if it fails, between 0 and ${Ee.length}. 0 disables retries.`))}),continueOnFailure:r.at({value:r.X().describe(`Whether to continue to the next step if this action fails.`)})})}),De={expectedOutputSchema:r.nt({}).optional().describe(`A sample output value declared by the user for steps whose output structure is only known at runtime.`)},Oe=r.at({code:r.lt().max(Te).optional().describe("The TypeScript source of the step. It must export `main` as an async arrow function, `export const main = async (params: { ... }) => { ... }`: params receives logicFunctionInput, its type declares the step inputs, and it returns an object."),logicFunctionId:r.lt().optional().describe("Deprecated: only set on steps created before inline code. Do NOT set this; write the source in `code` instead."),logicFunctionInput:r.st(r.lt(),r.J()).describe("Key-value map of input parameters passed to `main` at runtime.")});O.extend({input:Oe.refine(e=>(0,g.isNonEmptyString)(e.code)||(0,g.isNonEmptyString)(e.logicFunctionId),{message:"A CODE step needs a non-empty `code` (or, for legacy steps, a `logicFunctionId`)."}),...De});var ke=O.extend({input:r.at({url:r.lt(),method:r.K([`GET`,`POST`,`PUT`,`PATCH`,`DELETE`]),headers:r.st(r.lt(),r.lt()).optional(),body:r.st(r.lt(),r.dt([r.lt(),r.it(),r.X(),r.q(),r.Y(r.dt([r.lt(),r.it(),r.X(),r.q()]))])).or(r.lt()).optional()}),...De}),Ae=/^[a-zA-Z0-9_-]{1,64}$/,je=r.at({id:r.pt().describe(`Stable identifier for this criterion row.`),name:r.lt().describe(`Option name for a choice question, or the label of one score level.`),description:r.lt().optional().describe(`What the model should understand this option to mean.`)}),Me=r.at({id:r.pt().describe(`Stable identifier for this question row.`),name:r.lt().regex(Ae,`Answer name must be empty or contain 1 to 64 characters using only letters, digits, underscores and dashes`).or(r.tt(``)).describe(`Answer key for this question, made of letters, digits, underscores and dashes. Downstream steps read {{stepId.answers.<name>}}.`),type:r.K(d).describe(`choice picks one option, score grades an ordered rubric, boolean estimates the probability that a statement holds.`),instructions:r.lt().describe(`What the model should decide about the shared state.`),criteria:r.Y(je).describe(`Options for a choice question, or ordered levels (lowest first) for a score question. Empty for boolean.`)}),Ne=O.extend({input:r.at({state:r.lt().describe(`The shared state every question is asked about. Supports variables.`),questions:r.Y(Me)})}),Pe=O.extend({input:r.at({items:r.dt([r.Y(r.dt([r.lt(),r.it(),r.X(),r.q(),r.st(r.lt(),r.J()),r.J()])),r.lt()]).optional(),initialLoopStepIds:r.Y(r.lt()).optional(),shouldContinueOnIterationFailure:r.X().optional()})}),Fe=O.extend({input:r.at({delayType:r.K([`SCHEDULED_DATE`,`DURATION`]),scheduledDateTime:r.lt().nullable().optional(),duration:r.at({days:r.dt([r.it().min(0),r.lt()]).optional(),hours:r.dt([r.it().min(0),r.lt()]).optional(),minutes:r.dt([r.it().min(0),r.lt()]).optional(),seconds:r.dt([r.it().min(0),r.lt()]).optional()}).optional()})}),Ie=O.extend({input:r.at({eventName:r.lt().describe(`Event to wait for, in format objectName.action (e.g., "company.updated", "task.created", "person.deleted").`),recordId:r.lt().nullable().optional().describe(`Only resume for this record. Usually a variable such as {{trigger.properties.after.id}}. Leave empty to resume on any record.`),updatedFields:r.Y(r.lt()).nullable().optional().describe(`For update events, only resume when one of these fields changed.`),timeout:r.at({days:r.dt([r.it().min(0),r.lt()]).optional(),hours:r.dt([r.it().min(0),r.lt()]).optional(),minutes:r.dt([r.it().min(0),r.lt()]).optional()}).nullable().optional().describe(`Stop waiting after this duration. The step then succeeds with hasTimedOut set to true.`)})}),Le=O.extend({input:r.at({})}),Re=r.st(r.lt(),r.J()).describe(`Record data object. Use nested objects for relationships (e.g., "company": {"id": "{{reference}}"}). Common patterns:
2
+ - Person: {"name": {"firstName": "John", "lastName": "Doe"}, "emails": {"primaryEmail": "john@example.com"}, "company": {"id": "{{trigger.properties.after.id}}"}}
3
+ - Company: {"name": "Acme Corp", "domainName": {"primaryLinkUrl": "https://acme.com"}}
4
+ - Task: {"title": "Follow up", "status": "TODO", "assignee": {"id": "{{user.id}}"}}`),ze=O.extend({input:r.ct({objectName:r.lt().describe(`The name of the object to create a record in. Must be lowercase (e.g., "person", "company", "task").`),objectRecord:Re.describe(`The record data to create.`)})}),Be=O.extend({input:r.at({objectName:r.lt(),objectRecord:Re,objectRecordId:r.lt(),fieldsToUpdate:r.Y(r.lt())})}),Ve=O.extend({input:r.ct({objectName:r.lt(),objectRecord:Re})}),He=O.extend({input:r.at({objectName:r.lt(),objectRecordId:r.lt()})}),Ue=r.at({id:r.lt(),logicalOperator:r.K(r.w),parentRecordFilterGroupId:r.lt().nullable().optional(),positionInRecordFilterGroup:r.it().nullable().optional()}),We=r.at({id:r.lt().optional(),fieldMetadataId:r.lt(),operand:r.K(r._),value:r.lt().nullable().optional(),recordFilterGroupId:r.lt().nullable().optional(),positionInRecordFilterGroup:r.it().nullable().optional(),subFieldName:r.lt().nullable().optional(),relationTargetFieldMetadataId:r.lt().nullable().optional()}),Ge=r.at({fieldMetadataId:r.lt(),direction:r.K(r.b),subFieldName:r.lt().nullable().optional()}),k=r.lt().regex(/^{{[^{}]+}}$/,`Expected a workflow variable reference like {{stepId.path}}`),Ke=O.extend({input:r.at({objectName:r.lt(),limit:r.dt([r.it(),k]).optional(),offset:r.dt([r.it().int().nonnegative(),k]).optional(),filter:r.at({recordFilterGroups:r.Y(Ue).optional(),recordFilters:r.Y(We).optional()}).optional(),orderBy:r.ct({recordSorts:r.Y(Ge).optional()}).optional()})}),qe=r.at({id:r.lt(),name:r.lt(),label:r.lt(),type:r.dt([r.tt(r.R.TEXT),r.tt(r.R.NUMBER),r.tt(r.R.DATE),r.tt(r.R.SELECT),r.tt(r.R.MULTI_SELECT),r.tt(`RECORD`)]),placeholder:r.lt().optional(),settings:r.st(r.lt(),r.J()).optional(),value:r.J().optional()}),Je=O.extend({input:r.Y(qe),instructions:r.lt().optional()}),A=r.at({id:r.lt(),logicalOperator:r.K(r.U),parentStepFilterGroupId:r.lt().optional(),positionInStepFilterGroup:r.it().optional()}),j=r.at({id:r.lt(),type:r.lt(),stepOutputKey:r.lt(),operand:r.K(r._).or(r.K(r.y)),value:r.lt(),stepFilterGroupId:r.lt(),positionInStepFilterGroup:r.it().optional(),fieldMetadataId:r.lt().optional(),compositeFieldSubFieldName:r.lt().optional(),isFullRecord:r.X().optional()}),Ye=O.extend({input:r.at({stepFilterGroups:r.Y(A),stepFilters:r.Y(j)})}),Xe=r.at({id:r.lt(),nextStepIds:r.Y(r.lt()),filterGroupId:r.lt().optional()}),Ze=O.extend({input:r.at({stepFilterGroups:r.Y(A),stepFilters:r.Y(j),branches:r.Y(Xe)})}),Qe=r.at({id:r.lt().refine(e=>t.d(e)),name:r.lt(),size:r.it(),type:r.lt(),createdAt:r.lt()}),$e=r.Y(r.dt([Qe,k.describe(`A workflow variable reference resolving to files`)])),et=O.extend({input:r.at({connectedAccountId:r.lt(),fromHandle:r.lt().trim().optional(),recipients:r.at({to:r.lt().optional(),cc:r.lt().optional(),bcc:r.lt().optional()}),subject:r.lt().optional(),body:r.lt().optional().describe(`The email body as a serialized email document: JSON.stringify of {"type":"doc","attrs":{"schemaVersion":1},"content":[...]} with paragraph, heading, bulletList, orderedList, image, button, divider and html blocks. Use {{stepId.field}} for variables. To send a complete HTML email verbatim, including HTML produced by an earlier step such as {{stepId.html}}, make the body a single htmlDocument block ({"type":"htmlDocument","attrs":{"html":"..."}}): it is sent without the email layout and its variables are inserted as raw HTML, while an html block is embedded in the layout with escaped variables. HTML or plain text strings are rejected.`),files:$e.optional(),inReplyTo:r.lt().trim().optional()})}),tt=O.extend({input:r.at({connectedAccountId:r.lt(),title:r.lt(),description:r.lt().optional(),location:r.lt().optional(),startsAt:r.lt(),endsAt:r.lt(),isFullDay:r.X(),timeZone:r.lt().optional(),attendees:r.lt().optional(),sendInvitations:r.X(),addConferencing:r.X()})}),nt=r.K([`RUN`,`STEP`,`KEY`]),rt=r.at({scope:nt,key:r.lt().optional()}),it=r.at({humanInputInstructions:r.lt().optional(),conversation:rt.optional()}),at=r.at({enabled:r.X(),configuration:r.st(r.lt(),r.J()).optional()}),ot=r.at({webSearch:at.optional(),twitterSearch:at.optional()}),st=r.at({instructions:r.lt().optional(),modelId:r.lt().optional(),modelConfiguration:ot.optional(),scope:v.optional()}),ct=O.extend({input:r.at({agentId:r.lt().optional(),...st.shape,prompt:r.lt().optional(),responseFormat:y.optional(),workspaceMemberId:r.lt().optional(),...it.shape})}),lt=O.extend({input:r.at({workspaceMemberId:r.lt(),title:r.lt(),text:r.lt(),toolCall:r.at({toolName:r.lt(),arguments:r.st(r.lt(),r.J())}).optional(),conversation:rt.optional()})}),ut=r.K([`RANDOM`,`ROUND_ROBIN`,`LOAD_BALANCED`]);O.extend({input:r.at({objectName:r.lt(),strategy:ut,recordIds:r.Y(r.lt()),loadBalance:r.at({objectNameSingular:r.lt(),fieldName:r.lt()}).optional()}).superRefine((e,t)=>{e.strategy===`LOAD_BALANCED`&&!n.t(e.loadBalance)&&t.addIssue({code:a.custom,path:[`loadBalance`],message:`loadBalance is required when strategy is LOAD_BALANCED`})})});var dt={AGENT_STEP_HAS_INLINE_CONFIG:`A step running an agent takes its instructions, model and permissions from the agent. Remove the instructions, model and permissions set on the step, or remove its agent.`,GENERATE_STEP_HAS_CONVERSATION_CONFIG:`A step without an agent cannot ask humans or keep a conversation. Use an agent for this step, or remove its human input instructions and conversation setting.`,GENERATE_STEP_SCOPE_HAS_REPEATED_ENTRIES:`The permissions of a step without an agent list an object or field more than once. Keep a single entry for each.`},ft=(e,t)=>e.keyof().options.some(e=>{let r=t[e];return(0,g.isString)(r)?(0,g.isNonEmptyString)(r.trim()):n.t(r)}),pt=e=>!(0,g.isNonEmptyString)(e.agentId),mt=e=>pt(e)?[...ft(it,e)?[`GENERATE_STEP_HAS_CONVERSATION_CONFIG`]:[],...p(e.scope)?[`GENERATE_STEP_SCOPE_HAS_REPEATED_ENTRIES`]:[]]:ft(st,e)?[`AGENT_STEP_HAS_INLINE_CONFIG`]:[],ht=r.at({name:r.lt().optional().describe(`Human-readable name for the trigger. Optional but recommended for clarity.`),type:r.K([`DATABASE_EVENT`,`MANUAL`,`CRON`,`WEBHOOK`]).describe(`Type of trigger. DATABASE_EVENT for record changes, MANUAL for user-initiated, CRON for scheduled, WEBHOOK for external calls.`),position:r.at({x:r.it(),y:r.it()}).optional().nullable().describe(`Position coordinates for the trigger in the workflow diagram. Use (0, 0) for the trigger step.`),nextStepIds:r.Y(r.lt()).optional().nullable().describe(`Array of step IDs that the trigger connects to. These are the first steps in the workflow.`)}),gt=ht.extend({type:r.tt(`CRON`),settings:r.Z(`type`,[r.at({type:r.tt(`DAYS`),schedule:r.at({day:r.it().min(1),hour:r.it().min(0).max(23),minute:r.it().min(0).max(59)}),outputSchema:r.nt({})}),r.at({type:r.tt(`HOURS`),schedule:r.at({hour:r.it().min(1),minute:r.it().min(0).max(59)}),outputSchema:r.nt({})}),r.at({type:r.tt(`MINUTES`),schedule:r.at({minute:r.it().min(1).max(60)}),outputSchema:r.nt({})}),r.at({type:r.tt(`CUSTOM`),pattern:r.lt(),outputSchema:r.nt({})})])}),_t=ht.extend({type:r.tt(`WEBHOOK`),settings:r.Z(`httpMethod`,[r.at({outputSchema:r.nt({}),httpMethod:r.tt(`GET`),authentication:r.tt(`API_KEY`).nullable()}),r.at({outputSchema:r.nt({}),expectedOutputSchema:r.nt({}).optional(),httpMethod:r.tt(`POST`),expectedBody:r.nt({}),authentication:r.tt(`API_KEY`).nullable()})])}),M=function(e){return e.CODE=`CODE`,e.LOGIC_FUNCTION=`LOGIC_FUNCTION`,e.SEND_EMAIL=`SEND_EMAIL`,e.SEND_CHAT_MESSAGE=`SEND_CHAT_MESSAGE`,e.DRAFT_EMAIL=`DRAFT_EMAIL`,e.CREATE_CALENDAR_EVENT=`CREATE_CALENDAR_EVENT`,e.CREATE_RECORD=`CREATE_RECORD`,e.UPDATE_RECORD=`UPDATE_RECORD`,e.DELETE_RECORD=`DELETE_RECORD`,e.UPSERT_RECORD=`UPSERT_RECORD`,e.FIND_RECORDS=`FIND_RECORDS`,e.PICK_RECORD=`PICK_RECORD`,e.FORM=`FORM`,e.FILTER=`FILTER`,e.IF_ELSE=`IF_ELSE`,e.HTTP_REQUEST=`HTTP_REQUEST`,e.AI_AGENT=`AI_AGENT`,e.CLASSIFY=`CLASSIFY`,e.ITERATOR=`ITERATOR`,e.EMPTY=`EMPTY`,e.DELAY=`DELAY`,e.WAIT_FOR_EVENT=`WAIT_FOR_EVENT`,e}({}),vt=e=>{let t=e.settings?.input;return e.type===M.IF_ELSE&&(0,g.isObject)(t)&&`branches`in t&&Array.isArray(t.branches)},yt=e=>{let t=e.settings?.input;return e.type===M.ITERATOR&&(0,g.isObject)(t)&&`initialLoopStepIds`in t&&(0,g.isNonEmptyArray)(t.initialLoopStepIds)},bt=e=>{let t=e.settings?.input;if(n.t(t)&&(0,g.isObject)(t))return t},xt=e=>{let t=new Set(e.nextStepIds??[]);if(vt(e))for(let n of e.settings.input.branches??[])for(let e of n?.nextStepIds??[])t.add(e);if(yt(e))for(let n of e.settings.input.initialLoopStepIds??[])t.add(n);return[...t]},St=({trigger:e,steps:t})=>{let r=new Map,i=n.t(e?.nextStepIds)?e.nextStepIds.filter(n.t):[];r.set(b,i);for(let e of t??[])r.set(e.id,xt(e));let a=new Set,o=[b];for(;o.length>0;){let e=o.shift();if(!(!n.t(e)||a.has(e))){a.add(e);for(let t of r.get(e)??[])a.has(t)||o.push(t)}}return{childrenByStepId:r,reachableFromTrigger:a,ancestorsByStepId:Ct(r)}},Ct=e=>{let t=new Map;for(let[n,r]of e.entries())for(let e of r){let r=t.get(e)??new Set;r.add(n),t.set(e,r)}let n=new Map;for(let r of e.keys()){if(n.has(r))continue;let e=new Set,i=[...t.get(r)??[]];for(;i.length>0;){let n=i.shift();if(!e.has(n)){e.add(n);for(let r of t.get(n)??[])e.has(r)||i.push(r)}}n.set(r,e)}return n},wt=({workflow:e,graph:t})=>{let r=[],i=new Set,a=new Set,o=new Map((e.steps??[]).map(e=>[e.id,e])),s=(e,c=[],l)=>{let u=c[c.length-1];if(i.has(e)){if(e!==l&&u===e)return;r.push({severity:`error`,code:`WORKFLOW_CYCLE`,stepId:e,message:`Workflow contains a cycle at step ${e}`});return}let d=o.get(e),f=`${e}:${c.join(`,`)}`;if(!n.t(d)||a.has(f))return;i.add(e),yt(d)&&(d.settings.input.initialLoopStepIds??[]).forEach(t=>s(t,[...c,e],e));let p=d.type===M.ITERATOR?d.nextStepIds??[]:t.childrenByStepId.get(e)??[];n.t(u)&&p.length===0&&r.push({severity:`error`,code:`ITERATOR_MISSING_RETURN`,stepId:e,message:`Loop body step ${e} must return to iterator ${u}`}),p.forEach(t=>s(t,c,e)),i.delete(e),a.add(f)};return e.trigger?.nextStepIds?.forEach(e=>s(e)),r},Tt=({workflow:e,graph:r})=>{let i=[],a=e.steps??[],o=new Set(a.map(e=>e.id)),s=new Set;for(let e of a)s.has(e.id)&&i.push({severity:`error`,code:`DUPLICATE_STEP_ID`,message:`Duplicate step id "${e.id}". Every step id must be unique within the workflow.`,stepId:e.id}),s.add(e.id);let c=(e.trigger?.nextStepIds??[]).filter(n.t);t.o(a)&&c.length===0&&i.push({severity:`error`,code:`TRIGGER_HAS_NO_NEXT_STEP`,message:`The trigger is not connected to any step. The trigger must have a "nextStepIds" array pointing to the first step (e.g. nextStepIds: ["${a[0].id}"]). If you used edges, also set trigger.nextStepIds.`});for(let e of c)o.has(e)||i.push({severity:`error`,code:`DANGLING_REFERENCE`,message:`The trigger references a non-existent step "${e}".`});for(let e of a){for(let t of r.childrenByStepId.get(e.id)??[])o.has(t)||i.push({severity:`error`,code:`DANGLING_REFERENCE`,message:`Step "${e.name??e.id}" references a non-existent step "${t}".`,stepId:e.id});i.push(...Et(e))}for(let e of a)r.reachableFromTrigger.has(e.id)||i.push({severity:`error`,code:`UNREACHABLE_STEP`,message:`Step "${e.name??e.id}" is not reachable from the trigger. Ensure a chain of nextStepIds connects the trigger to this step. Check that the preceding step includes this step's id ("${e.id}") in its nextStepIds array.`,stepId:e.id});return i},Et=e=>{let t=[],r=bt(e);if(e.type===M.IF_ELSE){let i=r?.branches,a=Array.isArray(i)?i:[];a.length<2&&t.push({severity:`warning`,code:`IF_ELSE_INSUFFICIENT_BRANCHES`,message:`If/Else step "${e.name??e.id}" should have at least two branches (a condition branch and an else branch).`,stepId:e.id});let o=r?.stepFilterGroups,s=new Set((Array.isArray(o)?o:[]).filter(n.t).map(e=>e.id));for(let r of a){let i=r?.nextStepIds;(!Array.isArray(i)||i.length===0)&&t.push({severity:`error`,code:`IF_ELSE_BRANCH_HAS_NO_NEXT_STEP`,message:`A branch of If/Else step "${e.name??e.id}" is not connected to any step.`,stepId:e.id}),n.t(r?.filterGroupId)&&!s.has(r.filterGroupId)&&t.push({severity:`error`,code:`INVALID_STEP_PARAMS`,message:`A branch of If/Else step "${e.name??e.id}" references filter group "${r.filterGroupId}", which does not exist.`,stepId:e.id})}}if(e.type===M.ITERATOR){let n=r,i=n?.items,a=typeof i==`string`&&i.length>0||Array.isArray(i)&&i.length>0,o=n?.initialLoopStepIds,s=Array.isArray(o)&&o.length>0;a&&!s&&t.push({severity:`error`,code:`ITERATOR_MISSING_LOOP_BODY`,message:`Iterator step "${e.name??e.id}" has items to iterate over but no steps inside the loop.`,stepId:e.id})}return t};function Dt(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name===`Uint8Array`}function N(e,...t){if(!Dt(e))throw Error(`Uint8Array expected`);if(t.length>0&&!t.includes(e.length))throw Error(`Uint8Array expected of length `+t+`, got length=`+e.length)}function Ot(e,t=!0){if(e.destroyed)throw Error(`Hash instance has been destroyed`);if(t&&e.finished)throw Error(`Hash#digest() has already been called`)}function kt(e,t){N(e);let n=t.outputLen;if(e.length<n)throw Error(`digestInto() expects output buffer of length at least `+n)}function P(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function F(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}function I(e,t){return e<<32-t|e>>>t}var At=typeof Uint8Array.from([]).toHex==`function`&&typeof Uint8Array.fromHex==`function`,jt=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,`0`));function Mt(e){if(N(e),At)return e.toHex();let t=``;for(let n=0;n<e.length;n++)t+=jt[e[n]];return t}function L(e){if(typeof e!=`string`)throw Error(`string expected`);return new Uint8Array(new TextEncoder().encode(e))}function Nt(e){return typeof e==`string`&&(e=L(e)),N(e),e}var Pt=class{};function Ft(e){let t=t=>e().update(Nt(t)).digest(),n=e();return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=()=>e(),t}function It(e,t,n,r){if(typeof e.setBigUint64==`function`)return e.setBigUint64(t,n,r);let i=BigInt(32),a=BigInt(4294967295),o=Number(n>>i&a),s=Number(n&a),c=r?4:0,l=r?0:4;e.setUint32(t+c,o,r),e.setUint32(t+l,s,r)}function Lt(e,t,n){return e&t^~e&n}function Rt(e,t,n){return e&t^e&n^t&n}var zt=class extends Pt{constructor(e,t,n,r){super(),this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.blockLen=e,this.outputLen=t,this.padOffset=n,this.isLE=r,this.buffer=new Uint8Array(e),this.view=F(this.buffer)}update(e){Ot(this),e=Nt(e),N(e);let{view:t,buffer:n,blockLen:r}=this,i=e.length;for(let a=0;a<i;){let o=Math.min(r-this.pos,i-a);if(o===r){let t=F(e);for(;r<=i-a;a+=r)this.process(t,a);continue}n.set(e.subarray(a,a+o),this.pos),this.pos+=o,a+=o,this.pos===r&&(this.process(t,0),this.pos=0)}return this.length+=e.length,this.roundClean(),this}digestInto(e){Ot(this),kt(e,this),this.finished=!0;let{buffer:t,view:n,blockLen:r,isLE:i}=this,{pos:a}=this;t[a++]=128,P(this.buffer.subarray(a)),this.padOffset>r-a&&(this.process(n,0),a=0);for(let e=a;e<r;e++)t[e]=0;It(n,r-8,BigInt(this.length*8),i),this.process(n,0);let o=F(e),s=this.outputLen;if(s%4)throw Error(`_sha2: outputLen should be aligned to 32bit`);let c=s/4,l=this.get();if(c>l.length)throw Error(`_sha2: outputLen bigger than state`);for(let e=0;e<c;e++)o.setUint32(4*e,l[e],i)}digest(){let{buffer:e,outputLen:t}=this;this.digestInto(e);let n=e.slice(0,t);return this.destroy(),n}_cloneInto(e){e||=new this.constructor,e.set(...this.get());let{blockLen:t,buffer:n,length:r,finished:i,destroyed:a,pos:o}=this;return e.destroyed=a,e.finished=i,e.length=r,e.pos=o,r%t&&e.buffer.set(n),e}clone(){return this._cloneInto()}},R=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),z=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]),B=BigInt(2**32-1),Bt=BigInt(32);function Vt(e,t=!1){return t?{h:Number(e&B),l:Number(e>>Bt&B)}:{h:Number(e>>Bt&B)|0,l:Number(e&B)|0}}function Ht(e,t=!1){let n=e.length,r=new Uint32Array(n),i=new Uint32Array(n);for(let a=0;a<n;a++){let{h:n,l:o}=Vt(e[a],t);[r[a],i[a]]=[n,o]}return[r,i]}var Ut=(e,t,n)=>e>>>n,Wt=(e,t,n)=>e<<32-n|t>>>n,V=(e,t,n)=>e>>>n|t<<32-n,H=(e,t,n)=>e<<32-n|t>>>n,U=(e,t,n)=>e<<64-n|t>>>n-32,W=(e,t,n)=>e>>>n-32|t<<64-n;function G(e,t,n,r){let i=(t>>>0)+(r>>>0);return{h:e+n+(i/2**32|0)|0,l:i|0}}var Gt=(e,t,n)=>(e>>>0)+(t>>>0)+(n>>>0),Kt=(e,t,n,r)=>t+n+r+(e/2**32|0)|0,qt=(e,t,n,r)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0),Jt=(e,t,n,r,i)=>t+n+r+i+(e/2**32|0)|0,Yt=(e,t,n,r,i)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0)+(i>>>0),Xt=(e,t,n,r,i,a)=>t+n+r+i+a+(e/2**32|0)|0,Zt=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),K=new Uint32Array(64),Qt=class extends zt{constructor(e=32){super(64,e,8,!1),this.A=R[0]|0,this.B=R[1]|0,this.C=R[2]|0,this.D=R[3]|0,this.E=R[4]|0,this.F=R[5]|0,this.G=R[6]|0,this.H=R[7]|0}get(){let{A:e,B:t,C:n,D:r,E:i,F:a,G:o,H:s}=this;return[e,t,n,r,i,a,o,s]}set(e,t,n,r,i,a,o,s){this.A=e|0,this.B=t|0,this.C=n|0,this.D=r|0,this.E=i|0,this.F=a|0,this.G=o|0,this.H=s|0}process(e,t){for(let n=0;n<16;n++,t+=4)K[n]=e.getUint32(t,!1);for(let e=16;e<64;e++){let t=K[e-15],n=K[e-2],r=I(t,7)^I(t,18)^t>>>3;K[e]=(I(n,17)^I(n,19)^n>>>10)+K[e-7]+r+K[e-16]|0}let{A:n,B:r,C:i,D:a,E:o,F:s,G:c,H:l}=this;for(let e=0;e<64;e++){let t=I(o,6)^I(o,11)^I(o,25),u=l+t+Lt(o,s,c)+Zt[e]+K[e]|0,d=(I(n,2)^I(n,13)^I(n,22))+Rt(n,r,i)|0;l=c,c=s,s=o,o=a+u|0,a=i,i=r,r=n,n=u+d|0}n=n+this.A|0,r=r+this.B|0,i=i+this.C|0,a=a+this.D|0,o=o+this.E|0,s=s+this.F|0,c=c+this.G|0,l=l+this.H|0,this.set(n,r,i,a,o,s,c,l)}roundClean(){P(K)}destroy(){this.set(0,0,0,0,0,0,0,0),P(this.buffer)}},$t=Ht(`0x428a2f98d728ae22.0x7137449123ef65cd.0xb5c0fbcfec4d3b2f.0xe9b5dba58189dbbc.0x3956c25bf348b538.0x59f111f1b605d019.0x923f82a4af194f9b.0xab1c5ed5da6d8118.0xd807aa98a3030242.0x12835b0145706fbe.0x243185be4ee4b28c.0x550c7dc3d5ffb4e2.0x72be5d74f27b896f.0x80deb1fe3b1696b1.0x9bdc06a725c71235.0xc19bf174cf692694.0xe49b69c19ef14ad2.0xefbe4786384f25e3.0x0fc19dc68b8cd5b5.0x240ca1cc77ac9c65.0x2de92c6f592b0275.0x4a7484aa6ea6e483.0x5cb0a9dcbd41fbd4.0x76f988da831153b5.0x983e5152ee66dfab.0xa831c66d2db43210.0xb00327c898fb213f.0xbf597fc7beef0ee4.0xc6e00bf33da88fc2.0xd5a79147930aa725.0x06ca6351e003826f.0x142929670a0e6e70.0x27b70a8546d22ffc.0x2e1b21385c26c926.0x4d2c6dfc5ac42aed.0x53380d139d95b3df.0x650a73548baf63de.0x766a0abb3c77b2a8.0x81c2c92e47edaee6.0x92722c851482353b.0xa2bfe8a14cf10364.0xa81a664bbc423001.0xc24b8b70d0f89791.0xc76c51a30654be30.0xd192e819d6ef5218.0xd69906245565a910.0xf40e35855771202a.0x106aa07032bbd1b8.0x19a4c116b8d2d0c8.0x1e376c085141ab53.0x2748774cdf8eeb99.0x34b0bcb5e19b48a8.0x391c0cb3c5c95a63.0x4ed8aa4ae3418acb.0x5b9cca4f7763e373.0x682e6ff3d6b2b8a3.0x748f82ee5defb2fc.0x78a5636f43172f60.0x84c87814a1f0ab72.0x8cc702081a6439ec.0x90befffa23631e28.0xa4506cebde82bde9.0xbef9a3f7b2c67915.0xc67178f2e372532b.0xca273eceea26619c.0xd186b8c721c0c207.0xeada7dd6cde0eb1e.0xf57d4f7fee6ed178.0x06f067aa72176fba.0x0a637dc5a2c898a6.0x113f9804bef90dae.0x1b710b35131c471b.0x28db77f523047d84.0x32caab7b40c72493.0x3c9ebe0a15c9bebc.0x431d67c49c100d4c.0x4cc5d4becb3e42b6.0x597f299cfc657e2a.0x5fcb6fab3ad6faec.0x6c44198c4a475817`.split(`.`).map(e=>BigInt(e))),en=$t[0],tn=$t[1],q=new Uint32Array(80),J=new Uint32Array(80),nn=class extends zt{constructor(e=64){super(128,e,16,!1),this.Ah=z[0]|0,this.Al=z[1]|0,this.Bh=z[2]|0,this.Bl=z[3]|0,this.Ch=z[4]|0,this.Cl=z[5]|0,this.Dh=z[6]|0,this.Dl=z[7]|0,this.Eh=z[8]|0,this.El=z[9]|0,this.Fh=z[10]|0,this.Fl=z[11]|0,this.Gh=z[12]|0,this.Gl=z[13]|0,this.Hh=z[14]|0,this.Hl=z[15]|0}get(){let{Ah:e,Al:t,Bh:n,Bl:r,Ch:i,Cl:a,Dh:o,Dl:s,Eh:c,El:l,Fh:u,Fl:d,Gh:f,Gl:p,Hh:m,Hl:h}=this;return[e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h]}set(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h){this.Ah=e|0,this.Al=t|0,this.Bh=n|0,this.Bl=r|0,this.Ch=i|0,this.Cl=a|0,this.Dh=o|0,this.Dl=s|0,this.Eh=c|0,this.El=l|0,this.Fh=u|0,this.Fl=d|0,this.Gh=f|0,this.Gl=p|0,this.Hh=m|0,this.Hl=h|0}process(e,t){for(let n=0;n<16;n++,t+=4)q[n]=e.getUint32(t),J[n]=e.getUint32(t+=4);for(let e=16;e<80;e++){let t=q[e-15]|0,n=J[e-15]|0,r=V(t,n,1)^V(t,n,8)^Ut(t,n,7),i=H(t,n,1)^H(t,n,8)^Wt(t,n,7),a=q[e-2]|0,o=J[e-2]|0,s=V(a,o,19)^U(a,o,61)^Ut(a,o,6),c=qt(i,H(a,o,19)^W(a,o,61)^Wt(a,o,6),J[e-7],J[e-16]);q[e]=Jt(c,r,s,q[e-7],q[e-16])|0,J[e]=c|0}let{Ah:n,Al:r,Bh:i,Bl:a,Ch:o,Cl:s,Dh:c,Dl:l,Eh:u,El:d,Fh:f,Fl:p,Gh:m,Gl:h,Hh:g,Hl:_}=this;for(let e=0;e<80;e++){let t=V(u,d,14)^V(u,d,18)^U(u,d,41),ee=H(u,d,14)^H(u,d,18)^W(u,d,41),v=u&f^~u&m,te=d&p^~d&h,y=Yt(_,ee,te,tn[e],J[e]),b=Xt(y,g,t,v,en[e],q[e]),x=y|0,ne=V(n,r,28)^U(n,r,34)^U(n,r,39),S=H(n,r,28)^W(n,r,34)^W(n,r,39),re=n&i^n&o^i&o,ie=r&a^r&s^a&s;g=m|0,_=h|0,m=f|0,h=p|0,f=u|0,p=d|0,{h:u,l:d}=G(c|0,l|0,b|0,x|0),c=o|0,l=s|0,o=i|0,s=a|0,i=n|0,a=r|0;let C=Gt(x,S,ie);n=Kt(C,b,ne,re),r=C|0}({h:n,l:r}=G(this.Ah|0,this.Al|0,n|0,r|0)),{h:i,l:a}=G(this.Bh|0,this.Bl|0,i|0,a|0),{h:o,l:s}=G(this.Ch|0,this.Cl|0,o|0,s|0),{h:c,l}=G(this.Dh|0,this.Dl|0,c|0,l|0),{h:u,l:d}=G(this.Eh|0,this.El|0,u|0,d|0),{h:f,l:p}=G(this.Fh|0,this.Fl|0,f|0,p|0),{h:m,l:h}=G(this.Gh|0,this.Gl|0,m|0,h|0),{h:g,l:_}=G(this.Hh|0,this.Hl|0,g|0,_|0),this.set(n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_)}roundClean(){P(q,J)}destroy(){P(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}},rn=Ft(()=>new Qt),an=Ft(()=>new nn);r.u;var on=function(e){return e.OK=`OK`,e.SUCCESS=`SUCCESS`,e.INFO=`INFO`,e.WARNING=`WARNING`,e.ERROR=`ERROR`,e.NEUTRAL=`NEUTRAL`,e.UNKNOWN=`UNKNOWN`,e}({});Object.values(on).filter(e=>e!==on.OK&&e!==on.UNKNOWN),r.R.TEXT,r.R.ARRAY,r.R.BOOLEAN,r.R.DATE,r.R.DATE_TIME,r.R.NUMBER,r.R.NUMERIC,r.R.RAW_JSON,r.R.RICH_TEXT,r.R.SELECT,r.R.MULTI_SELECT;var sn=`dependencies/yarn.lock`,cn=`public`,ln=`front-component-shared-dependencies.mjs`;r.j.RECORD_PAGE,r.j.DASHBOARD;var un={CALL_RECORDER:`8da4b8b5-5edf-4880-b51f-ab6e679ec617`,EXA:`2b7f4a2e-9c4b-4a11-b63c-2e5e7d3f5a9a`,FATHOM:`c5fb24b3-15b0-48fb-a9b5-f182ba231e6c`,GRANOLA:`ffcc3979-0ee6-4d7d-912b-c12997d9f0f4`,LAST_CONTACT:`66a504cc-0a75-410e-a43f-cdeae1db1522`,PEOPLE_DATA_LABS:`4a1178c1-3535-4a47-b592-231d3216b36f`,SLACK:`a8c47f21-3b9e-4d2a-8f61-9c0e7d4a2b51`,TEAMS:`5955f8fe-6724-4749-b770-b849d63d5330`};un.SLACK,un.TEAMS,un.FATHOM;var dn={js:`import { createRequire as __createRequire } from 'module';
5
+ const require = __createRequire(import.meta.url);`},fn=`.twenty/output`,pn=({applicationUniversalIdentifier:e,roleUniversalIdentifier:t,fieldUniversalIdentifier:r,rowLevelPermissionPredicateGroupUniversalIdentifier:a})=>i.u({entityNamespace:`fieldPermission`,value:[t,r,...n.t(a)?[a]:[]].join(`:`),applicationUniversalIdentifier:e}),mn=({applicationUniversalIdentifier:e,roleUniversalIdentifier:t,objectUniversalIdentifier:n})=>i.u({entityNamespace:`objectPermission`,value:`${t}:${n}`,applicationUniversalIdentifier:e}),hn=({objectMetadataApplicationUniversalIdentifier:e,objectUniversalIdentifier:t})=>i.t({applicationUniversalIdentifier:e,objectUniversalIdentifier:t,name:r.j.RECORD_FORM});r.at({responseFormat:y.nullish(),scope:v.nullish()});var gn=({pageLayoutTabManifest:e,pageLayoutType:i})=>{let a=e.layoutMode??(i===r.j.STANDALONE_PAGE?r.C.VERTICAL_LIST:r.C.GRID),o=e.widgets??[],s=[];if(!Object.values(r.C).some(e=>e===a))return{status:`fail`,errors:[`Page layout tab "${e.title}" defines unsupported layoutMode "${a}". Expected GRID, VERTICAL_LIST or CANVAS.`]};for(let t of o){let i=[t.heightBehavior,r.i(t.position)&&`heightBehavior`in t.position?t.position.heightBehavior:void 0].filter(n.t);i.length>0&&a!==r.C.VERTICAL_LIST&&s.push(`Page layout widget "${t.title}" defines heightBehavior, but its parent tab "${e.title}" uses ${a}. heightBehavior is only supported for VERTICAL_LIST tabs.`);for(let e of i)Object.values(r.h).some(t=>t===e)||s.push(`Page layout widget "${t.title}" defines unsupported heightBehavior "${e}". Expected FIT_CONTENT or TAB_VIEWPORT.`)}if(s.length>0)return{status:`fail`,errors:s};let c={...e,layoutMode:a,widgets:o.map(({heightBehavior:e,position:i,gridPosition:o,...s},c)=>{if(n.t(i))return{...s,position:i.layoutMode===r.C.VERTICAL_LIST&&n.t(e)?{...i,heightBehavior:e}:i};if(n.t(o))return{...s,position:{layoutMode:r.C.GRID,...o}};switch(a){case r.C.GRID:return{...s,position:{layoutMode:a,row:0,column:0,rowSpan:r.l.default.h,columnSpan:r.l.default.w}};case r.C.VERTICAL_LIST:return{...s,position:{layoutMode:a,index:c,...n.t(e)?{heightBehavior:e}:{}}};case r.C.CANVAS:return{...s,position:{layoutMode:a}};default:return t.n(a)}})};for(let e of c.widgets)e.position.layoutMode!==a&&s.push(`Page layout widget "${e.title}" uses a ${e.position.layoutMode} position, but its parent tab "${c.title}" uses ${a}.`);if(a===r.C.VERTICAL_LIST){let e=c.widgets.filter(({type:e,position:n})=>n.layoutMode===r.C.VERTICAL_LIST&&t.i({widgetType:e,heightBehavior:n.heightBehavior})===r.h.TAB_VIEWPORT);e.length>1&&s.push(`Page layout tab "${c.title}" can contain only one TAB_VIEWPORT widget.`);let i=e.length===1?e[0]:void 0;n.t(i)&&c.widgets.some(e=>e!==i&&e.position.layoutMode===r.C.VERTICAL_LIST&&i.position.layoutMode===r.C.VERTICAL_LIST&&e.position.index>=i.position.index)&&s.push(`Page layout tab "${c.title}" must place its TAB_VIEWPORT widget last.`)}return s.length>0?{status:`fail`,errors:s}:{status:`success`,pageLayoutTab:c}},Y=[`canReadObjectRecords`,`canUpdateObjectRecords`,`canSoftDeleteObjectRecords`,`canDestroyObjectRecords`];[...Y];var _n=e=>Mt(an(L(e))).slice(0,32),vn=e=>_n(JSON.stringify(JSON.parse(e))),X={canReadObjectRecords:`canReadAllObjectRecords`,canUpdateObjectRecords:`canUpdateAllObjectRecords`,canSoftDeleteObjectRecords:`canSoftDeleteAllObjectRecords`,canDestroyObjectRecords:`canDestroyAllObjectRecords`},yn=({role:e,objectUniversalIdentifier:t})=>{let n=e.objectPermissions?.find(e=>e.objectUniversalIdentifier===t);return{canReadObjectRecords:n?.canReadObjectRecords??e[X.canReadObjectRecords]??!1,canUpdateObjectRecords:n?.canUpdateObjectRecords??e[X.canUpdateObjectRecords]??!1,canSoftDeleteObjectRecords:n?.canSoftDeleteObjectRecords??e[X.canSoftDeleteObjectRecords]??!1,canDestroyObjectRecords:n?.canDestroyObjectRecords??e[X.canDestroyObjectRecords]??!1}},bn=e=>JSON.stringify(e,(e,t)=>r.i(t)?Object.fromEntries(Object.entries(t).sort(([e],[t])=>e.localeCompare(t))):t),xn=({groupsByUniversalIdentifier:e,predicateGroupUniversalIdentifier:t})=>{let r=[],i=new Set,a=t;for(;n.t(a)&&!i.has(a);){i.add(a);let t=e.get(a);if(!n.t(t))break;r.push(t.logicalOperator),a=t.parentPredicateGroupUniversalIdentifier}return r},Sn=({role:e,objectUniversalIdentifier:t})=>{let n=new Map((e.rowLevelPermissionPredicateGroups??[]).map(e=>[e.universalIdentifier,e]));return(e.rowLevelPermissionPredicates??[]).filter(e=>e.objectUniversalIdentifier===t).map(e=>bn({fieldUniversalIdentifier:e.fieldUniversalIdentifier,subFieldName:e.subFieldName??null,operand:e.operand,value:e.value??null,workspaceMemberFieldUniversalIdentifier:e.workspaceMemberFieldUniversalIdentifier??null,workspaceMemberSubFieldName:e.workspaceMemberSubFieldName??null,groupOperatorPath:xn({groupsByUniversalIdentifier:n,predicateGroupUniversalIdentifier:e.predicateGroupUniversalIdentifier})})).sort()},Cn=r.f.map(e=>r.r[e]),wn=({roleSignature:e,supersetSignature:t})=>e.length===t.length&&e.every((e,n)=>e===t[n]),Tn=({role:e,superset:t})=>[...Y.filter(n=>{let r=X[n];return e[r]&&!t[r]}).map(e=>({type:`ALL_OBJECT_RECORDS`,action:e})),...e.canUpdateAllSettings&&!t.canUpdateAllSettings?[{type:`ALL_SETTINGS`}]:[],...e.canAccessAllTools&&!t.canAccessAllTools?[{type:`ALL_TOOLS`}]:[]],En=({role:e,superset:t,toolPermissionFlagUniversalIdentifiers:n})=>{let r=new Set([...Cn,...n]),i=new Set(t.permissionFlagUniversalIdentifiers??[]);return[...new Set(e.permissionFlagUniversalIdentifiers??[])].filter(e=>!(r.has(e)?t.canAccessAllTools:t.canUpdateAllSettings)&&!i.has(e)).map(e=>({type:`PERMISSION_FLAG`,permissionFlagUniversalIdentifier:e}))},Dn=({role:e,superset:t})=>[...new Set([...[...e.objectPermissions??[],...t.objectPermissions??[]].map(e=>e.objectUniversalIdentifier),...(t.rowLevelPermissionPredicates??[]).map(e=>e.objectUniversalIdentifier)])].flatMap(n=>{let r=yn({role:e,objectUniversalIdentifier:n}),i=yn({role:t,objectUniversalIdentifier:n}),a=Y.filter(e=>r[e]&&!i[e]).map(e=>({type:`OBJECT_RECORDS`,objectUniversalIdentifier:n,action:e})),o=Y.some(e=>r[e]),s=Sn({role:t,objectUniversalIdentifier:n}),c=Sn({role:e,objectUniversalIdentifier:n});return o&&s.length>0&&!wn({roleSignature:c,supersetSignature:s})?[...a,{type:`ROW_LEVEL_RESTRICTION`,objectUniversalIdentifier:n}]:a}),On=({role:e,superset:t})=>(t.fieldPermissions??[]).flatMap(t=>{let{objectUniversalIdentifier:n,fieldUniversalIdentifier:r}=t,i=yn({role:e,objectUniversalIdentifier:n}),a=e.fieldPermissions?.find(e=>e.objectUniversalIdentifier===n&&e.fieldUniversalIdentifier===r),o=t.canReadFieldValue===!1&&i.canReadObjectRecords&&a?.canReadFieldValue!==!1,s=t.canUpdateFieldValue===!1&&i.canUpdateObjectRecords&&a?.canUpdateFieldValue!==!1;return[...o?[{type:`FIELD_VALUE`,objectUniversalIdentifier:n,fieldUniversalIdentifier:r,action:`canReadFieldValue`}]:[],...s?[{type:`FIELD_VALUE`,objectUniversalIdentifier:n,fieldUniversalIdentifier:r,action:`canUpdateFieldValue`}]:[]]}),kn=({role:e,superset:t,toolPermissionFlagUniversalIdentifiers:n})=>[...Tn({role:e,superset:t}),...En({role:e,superset:t,toolPermissionFlagUniversalIdentifiers:n}),...Dn({role:e,superset:t}),...On({role:e,superset:t})],An=e=>{if(!(e.endsWith(`.ts`)||e.endsWith(`.tsx`))||e.endsWith(`.d.ts`)||e.startsWith(`/`)||/^[a-z]:/i.test(e)||e.includes(`\\`))return!1;let t=[`..`,`.`,``,`node_modules`,`dist`,`.twenty`];return e.split(`/`).every(e=>!t.includes(e))},jn=e=>i.p(e)&&s(e)>=4,Mn=r.at({x:r.it(),y:r.it()}),Nn={universalIdentifier:r.pt(),name:r.lt().min(1),nextStepIds:r.Y(r.pt()),position:Mn.nullable().optional(),outputSchema:r.st(r.lt(),r.ft()).optional(),expectedOutputSchema:r.st(r.lt(),r.ft()).optional(),errorHandlingOptions:O.shape.errorHandlingOptions.optional()},Z=(e,t)=>r.ct({...Nn,type:r.tt(e),input:t}),Pn=r.nt({fieldMetadataUniversalIdentifier:r.pt(),fieldMetadataId:r.rt().optional()}),Fn=j.omit({fieldMetadataId:!0}).extend({fieldMetadataUniversalIdentifier:r.pt().optional()}).strict(),In=We.omit({fieldMetadataId:!0,relationTargetFieldMetadataId:!0}).extend({fieldMetadataUniversalIdentifier:r.pt()}).strict(),Q={objectUniversalIdentifier:r.pt()},Ln={connectedAccountId:r.lt().optional(),connectedAccountHandle:r.lt().trim().min(1).optional()},Rn=(e,t)=>{n.t(e.connectedAccountId)===n.t(e.connectedAccountHandle)&&t.addIssue({code:`custom`,path:[`connectedAccountHandle`],message:`Set exactly one of connectedAccountId and connectedAccountHandle`})},zn=et.shape.input.extend(Ln).superRefine(Rn),Bn=[r.ct({...Nn,type:r.tt(`LOGIC_FUNCTION`),logicFunctionUniversalIdentifier:r.pt(),input:r.st(r.lt(),r.ft())}),Z(`CODE`,Oe.omit({logicFunctionId:!0}).extend({code:Oe.shape.code.unwrap().min(1)}).strict()),Z(`HTTP_REQUEST`,ke.shape.input),Z(`CLASSIFY`,Ne.shape.input),Z(`ITERATOR`,Pe.shape.input),Z(`DELAY`,Fe.shape.input),Z(`WAIT_FOR_EVENT`,Ie.shape.input),Z(`EMPTY`,Le.shape.input),Z(`CREATE_RECORD`,ze.shape.input.omit({objectName:!0}).extend(Q).strict()),Z(`UPDATE_RECORD`,Be.shape.input.omit({objectName:!0}).extend(Q).strict()),Z(`UPSERT_RECORD`,Ve.shape.input.omit({objectName:!0}).extend(Q).strict()),Z(`DELETE_RECORD`,He.shape.input.omit({objectName:!0}).extend(Q).strict()),Z(`FIND_RECORDS`,Ke.shape.input.omit({objectName:!0,filter:!0,orderBy:!0}).extend({...Q,filter:r.ct({recordFilterGroups:r.Y(Ue).optional(),recordFilters:r.Y(In).optional()}).optional(),orderBy:r.ct({recordSorts:r.Y(Pn.extend({direction:r.K([`ASC`,`DESC`]),subFieldName:r.lt().nullable().optional()})).optional()}).optional()}).strict()),Z(`PICK_RECORD`,r.ct({...Q,strategy:ut,recordIds:r.Y(r.lt()),loadBalance:r.ct({objectUniversalIdentifier:r.pt(),fieldUniversalIdentifier:r.pt()}).optional()}).superRefine((e,t)=>{e.strategy===`LOAD_BALANCED`&&!n.t(e.loadBalance)&&t.addIssue({code:`custom`,path:[`loadBalance`],message:`loadBalance is required when strategy is LOAD_BALANCED`})})),Z(`FILTER`,Ye.shape.input.extend({stepFilters:r.Y(Fn)})),Z(`IF_ELSE`,Ze.shape.input.extend({stepFilters:r.Y(Fn)})),Z(`FORM`,r.Y(Je.shape.input.element.extend({settings:r.st(r.lt(),r.ft()).optional()}).superRefine((e,t)=>{e.type===`RECORD`&&!r.pt().safeParse(e.settings?.objectUniversalIdentifier).success&&t.addIssue({code:`custom`,path:[`settings`,`objectUniversalIdentifier`],message:`Record picker fields require an object universal identifier`}),(e.type===`SELECT`||e.type===`MULTI_SELECT`)&&!r.pt().safeParse(e.settings?.selectedFieldUniversalIdentifier).success&&t.addIssue({code:`custom`,path:[`settings`,`selectedFieldUniversalIdentifier`],message:`Select fields require the universal identifier of the field whose options they offer`})}))),Z(`SEND_EMAIL`,zn),Z(`DRAFT_EMAIL`,zn),Z(`CREATE_CALENDAR_EVENT`,tt.shape.input.extend(Ln).superRefine(Rn)),Z(`SEND_CHAT_MESSAGE`,lt.shape.input),Z(`AI_AGENT`,ct.shape.input.omit({agentId:!0}).extend({agentUniversalIdentifier:r.pt().optional()}).strict().superRefine((e,t)=>{for(let n of mt({...e,agentId:e.agentUniversalIdentifier}))t.addIssue({code:`custom`,path:[`agentUniversalIdentifier`],message:dt[n]})}))],Vn=Bn.map(e=>e.shape.type.value),Hn=r.Z(`type`,Bn,{error:e=>e.code===`invalid_union`?`Unsupported step type. Application workflows support: ${Vn.join(`, `)}`:void 0}),Un=[`updated`,`upserted`],Wn=r.Z(`type`,[r.ct({type:r.tt(`GLOBAL`)}),r.ct({type:r.tt(`SINGLE_RECORD`),objectUniversalIdentifier:r.pt()}),r.ct({type:r.tt(`BULK_RECORDS`),objectUniversalIdentifier:r.pt()})]),[Gn,Kn,qn,Jn]=gt.shape.settings.options,Yn=r.Z(`type`,[Gn.omit({outputSchema:!0}).extend({schedule:Gn.shape.schedule.strict()}).strict(),Kn.omit({outputSchema:!0}).extend({schedule:Kn.shape.schedule.strict()}).strict(),qn.omit({outputSchema:!0}).extend({schedule:qn.shape.schedule.strict()}).strict(),Jn.omit({outputSchema:!0}).strict()]),[Xn,Zn]=_t.shape.settings.options,Qn=r.Z(`httpMethod`,[Xn.omit({outputSchema:!0,authentication:!0}).strict(),Zn.omit({outputSchema:!0,expectedOutputSchema:!0,authentication:!0}).strict()]),$={universalIdentifier:r.pt().optional(),name:r.lt().min(1).optional(),nextStepIds:r.Y(r.pt()).min(1),position:Mn.nullable().optional(),outputSchema:r.st(r.lt(),r.ft()).optional()},$n=[r.ct({...$,type:r.tt(`MANUAL`),settings:r.ct({availability:Wn.optional(),icon:r.lt().optional(),isPinned:r.X().optional()}).superRefine((e,t)=>{!n.t(e.availability)&&(n.t(e.icon)||n.t(e.isPinned))&&t.addIssue({code:`custom`,path:[`availability`],message:`Set an availability for the icon and pin to show in the command menu`})}).optional()}),r.ct({...$,type:r.tt(`CRON`),settings:Yn}),r.ct({...$,type:r.tt(`DATABASE_EVENT`),settings:r.ct({objectUniversalIdentifier:r.pt(),action:r.K([`created`,`updated`,`deleted`,`upserted`]),fieldUniversalIdentifiers:r.Y(r.pt()).optional(),filter:r.ct({stepFilterGroups:r.Y(A),stepFilters:r.Y(Fn.extend({operand:r.K(r._)}))}).optional()}).superRefine((e,r)=>{if(t.o(e.fieldUniversalIdentifiers)&&!Un.includes(e.action)&&r.addIssue({code:`custom`,path:[`fieldUniversalIdentifiers`],message:`Watched fields only apply to ${Un.join(` and `)} events`}),!n.t(e.filter))return;let i=new Map;e.filter.stepFilterGroups.forEach((e,t)=>{i.has(e.id)&&r.addIssue({code:`custom`,path:[`filter`,`stepFilterGroups`,t,`id`],message:`Filter group ${e.id} is declared more than once`}),i.set(e.id,e.parentStepFilterGroupId)}),e.filter.stepFilterGroups.forEach((e,t)=>{let a=e.parentStepFilterGroupId,o=[`filter`,`stepFilterGroups`,t,`parentStepFilterGroupId`];if(!n.t(a))return;if(!i.has(a)){r.addIssue({code:`custom`,path:o,message:`Filter group ${a} is not declared in stepFilterGroups`});return}let s=new Set([e.id]);for(let t=a;n.t(t);t=i.get(t)){if(s.has(t)){r.addIssue({code:`custom`,path:o,message:`Filter group ${e.id} is not reachable from a root group`});return}s.add(t)}}),e.filter.stepFilters.forEach((e,t)=>{i.has(e.stepFilterGroupId)||r.addIssue({code:`custom`,path:[`filter`,`stepFilters`,t,`stepFilterGroupId`],message:`Filter group ${e.stepFilterGroupId} is not declared in stepFilterGroups`})})})}),r.ct({...$,type:r.tt(`WEBHOOK`),settings:Qn})],er=$n.map(e=>e.shape.type.value),tr=r.Z(`type`,$n,{error:e=>e.code===`invalid_union`?`Unsupported trigger type. Application workflows support: ${er.join(`, `)}`:void 0});r.ct({universalIdentifier:r.pt(),name:r.lt().min(1),isSystem:r.X().optional(),version:r.ct({trigger:tr,steps:r.Y(Hn).min(1)})}).superRefine((e,t)=>{let{steps:r,trigger:i}=e.version,a=[e.universalIdentifier,i.universalIdentifier,...r.map(e=>e.universalIdentifier)].filter(n.t);new Set(a).size!==a.length&&t.addIssue({code:`custom`,message:`Workflow, trigger and steps must have distinct universal identifiers`});let o={trigger:{type:i.type,nextStepIds:i.nextStepIds},steps:r.map(e=>({...e,id:e.universalIdentifier,settings:{input:e.input}}))},s=St(o);for(let e of[...Tt({workflow:o,graph:s}),...wt({workflow:o,graph:s}),...xe({workflow:o,graph:s,stepsById:new Map(o.steps.map(e=>[e.id,e]))})])e.severity===`error`&&t.addIssue({code:`custom`,message:e.message})}),Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return kn}}),Object.defineProperty(exports,"c",{enumerable:!0,get:function(){return vn}}),Object.defineProperty(exports,"d",{enumerable:!0,get:function(){return gn}}),Object.defineProperty(exports,"f",{enumerable:!0,get:function(){return sn}}),Object.defineProperty(exports,"g",{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,"h",{enumerable:!0,get:function(){return rn}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return mn}}),Object.defineProperty(exports,"l",{enumerable:!0,get:function(){return An}}),Object.defineProperty(exports,"m",{enumerable:!0,get:function(){return cn}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return dn}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return pn}}),Object.defineProperty(exports,"p",{enumerable:!0,get:function(){return hn}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return _n}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return ln}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return fn}}),Object.defineProperty(exports,"u",{enumerable:!0,get:function(){return jn}});
@@ -1,2 +1,2 @@
1
- const e=require("./cli-error-CrUD8uMp.cjs"),t=require("./get-tooling-error-context-CZKTM7Q6.cjs"),n=require("./compile-application-translations-Bp686pj4.cjs"),r=require("./resolve-source-sdk-CizL-ZLW.cjs");let i=require("esbuild");var a=async({appPath:a,signal:o})=>{let s=[],c=e=>{s.push({severity:`warning`,code:`BUILD_WARNING`,message:e})};try{o.throwIfAborted(),await r.t({appPath:a});let e=await n.r(a);if(o.throwIfAborted(),!e.success)return{success:!1,error:{code:`MANIFEST_BUILD_FAILED`,message:e.errors.join(`
1
+ const e=require("./cli-error-CrUD8uMp.cjs"),t=require("./get-tooling-error-context-CZKTM7Q6.cjs"),n=require("./compile-application-translations-S-xuODkF.cjs"),r=require("./resolve-source-sdk-CggXRBVx.cjs");let i=require("esbuild");var a=async({appPath:a,signal:o})=>{let s=[],c=e=>{s.push({severity:`warning`,code:`BUILD_WARNING`,message:e})};try{o.throwIfAborted(),await r.t({appPath:a});let e=await n.r(a);if(o.throwIfAborted(),!e.success)return{success:!1,error:{code:`MANIFEST_BUILD_FAILED`,message:e.errors.join(`
2
2
  `)},diagnostics:e.errors.map(e=>({severity:`error`,code:`MANIFEST_BUILD_FAILED`,message:e}))};e.warnings.forEach(c);let t=await n.t({appPath:a,onWarning:c});return o.throwIfAborted(),{success:!0,data:{manifest:{...e.manifest,translations:t},filePaths:e.filePaths},diagnostics:s}}catch(n){return{success:!1,error:{code:o.aborted?`CANCELLED`:n instanceof e.t?n.code:`MANIFEST_BUILD_FAILED`,message:n instanceof Error?n.message:String(n),...t.t(n)},diagnostics:s}}finally{await(0,i.stop)()}};exports.buildSourceManifest=a;