@elementumai/edk 0.8.2-alpha.6 → 0.9.2

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 (372) hide show
  1. package/README.md +18 -14
  2. package/dist-sdk/elementum-entity-client/clients/agents/models/agent-tool.d.ts +3 -3
  3. package/dist-sdk/elementum-entity-client/clients/aspects/models/index.d.ts +1 -1
  4. package/dist-sdk/elementum-entity-client/clients/aspects/models/picklist-config.d.ts +3 -11
  5. package/dist-sdk/elementum-entity-client/clients/automation/models/automation.d.ts +2 -10
  6. package/dist-sdk/elementum-entity-client/clients/skills/models/skill-tool.d.ts +1 -1
  7. package/dist-sdk/fs/entity.d.ts +2 -2
  8. package/dist-sdk/fs/entity.js +1 -1
  9. package/dist-sdk/pull/missing-report.d.ts +81 -0
  10. package/dist-sdk/pull/missing-report.js +52 -0
  11. package/dist-sdk/src/catalog/factories.d.ts +53 -19
  12. package/dist-sdk/src/catalog/factories.js +51 -12
  13. package/dist-sdk/src/catalog/from-authoring.js +13 -3
  14. package/dist-sdk/src/catalog/index.d.ts +2 -2
  15. package/dist-sdk/src/catalog/index.js +1 -1
  16. package/dist-sdk/src/catalog/org.js +1 -0
  17. package/dist-sdk/src/catalog/render.js +6 -0
  18. package/dist-sdk/src/catalog/token.js +7 -0
  19. package/dist-sdk/src/catalog/types.d.ts +34 -23
  20. package/dist-sdk/src/catalog/types.js +7 -4
  21. package/dist-sdk/src/core/app-to-ui.d.ts +6 -6
  22. package/dist-sdk/src/core/app-to-ui.js +7 -9
  23. package/dist-sdk/src/core/index.d.ts +1 -0
  24. package/dist-sdk/src/core/index.js +1 -0
  25. package/dist-sdk/src/core/platform-id.d.ts +11 -0
  26. package/dist-sdk/src/core/platform-id.js +8 -0
  27. package/dist-sdk/src/{entities/flow/activities/render-catalog.d.ts → core/render-tree.d.ts} +2 -2
  28. package/dist-sdk/src/{entities/flow/activities/render-catalog.js → core/render-tree.js} +6 -8
  29. package/dist-sdk/src/core/types/app.d.ts +13 -23
  30. package/dist-sdk/src/core/types/app.js +0 -1
  31. package/dist-sdk/src/engine/build/context.d.ts +3 -3
  32. package/dist-sdk/src/engine/pull/attrs.d.ts +4 -0
  33. package/dist-sdk/src/engine/pull/attrs.js +17 -0
  34. package/dist-sdk/src/engine/pull/context.d.ts +39 -0
  35. package/dist-sdk/src/engine/pull/org.d.ts +1 -0
  36. package/dist-sdk/src/engine/pull/org.js +2 -0
  37. package/dist-sdk/src/engine/tf/expr.d.ts +1 -1
  38. package/dist-sdk/src/engine/tf/expr.js +10 -3
  39. package/dist-sdk/src/engine/workspace/authoring-layout.js +4 -2
  40. package/dist-sdk/src/entities/access-policy/build.d.ts +4 -13
  41. package/dist-sdk/src/entities/access-policy/build.js +1 -1
  42. package/dist-sdk/src/entities/access-policy/from-tf.d.ts +12 -38
  43. package/dist-sdk/src/entities/access-policy/from-tf.js +16 -74
  44. package/dist-sdk/src/entities/access-policy/principal.d.ts +29 -0
  45. package/dist-sdk/src/entities/access-policy/principal.js +13 -0
  46. package/dist-sdk/src/entities/access-policy/to-tf.d.ts +20 -5
  47. package/dist-sdk/src/entities/access-policy/to-tf.js +26 -54
  48. package/dist-sdk/src/entities/agent/build.d.ts +39 -8
  49. package/dist-sdk/src/entities/agent/build.js +36 -15
  50. package/dist-sdk/src/entities/agent/deserializer/print-agent-v2.d.ts +5 -0
  51. package/dist-sdk/src/entities/agent/deserializer/print-agent-v2.js +121 -36
  52. package/dist-sdk/src/entities/agent/from-tf.js +5 -8
  53. package/dist-sdk/src/entities/agent/index.d.ts +5 -2
  54. package/dist-sdk/src/entities/agent/index.js +4 -2
  55. package/dist-sdk/src/entities/agent/module.js +5 -2
  56. package/dist-sdk/src/entities/agent/run-as.d.ts +16 -0
  57. package/dist-sdk/src/entities/agent/run-as.js +1 -0
  58. package/dist-sdk/src/entities/agent/to-tf.d.ts +2 -1
  59. package/dist-sdk/src/entities/agent/to-tf.js +2 -1
  60. package/dist-sdk/src/entities/agent/tools.d.ts +60 -48
  61. package/dist-sdk/src/entities/agent/tools.js +44 -38
  62. package/dist-sdk/src/entities/agent-a2a-skill/from-tf.js +1 -1
  63. package/dist-sdk/src/entities/agent-a2a-skill/to-tf.js +4 -4
  64. package/dist-sdk/src/entities/agent-tool/from-tf.d.ts +17 -8
  65. package/dist-sdk/src/entities/agent-tool/from-tf.js +127 -37
  66. package/dist-sdk/src/entities/agent-tool/module.js +6 -0
  67. package/dist-sdk/src/entities/agent-tool/to-tf.d.ts +5 -5
  68. package/dist-sdk/src/entities/agent-tool/to-tf.js +93 -20
  69. package/dist-sdk/src/entities/agent-tool/types.d.ts +4 -5
  70. package/dist-sdk/src/entities/agent-tool/types.js +36 -8
  71. package/dist-sdk/src/entities/app/build.d.ts +137 -25
  72. package/dist-sdk/src/entities/app/build.js +104 -53
  73. package/dist-sdk/src/entities/app/deserializer/normalize.d.ts +173 -1
  74. package/dist-sdk/src/entities/app/deserializer/pulled-expression.d.ts +59 -0
  75. package/dist-sdk/src/entities/app/deserializer/pulled-expression.js +68 -0
  76. package/dist-sdk/src/entities/app/display-blocks.d.ts +2 -1
  77. package/dist-sdk/src/entities/app/display-blocks.js +1 -1
  78. package/dist-sdk/src/entities/app/from-tf.d.ts +11 -1
  79. package/dist-sdk/src/entities/app/from-tf.js +30 -2
  80. package/dist-sdk/src/entities/app/index.d.ts +13 -4
  81. package/dist-sdk/src/entities/app/index.js +8 -1
  82. package/dist-sdk/src/entities/app/module.js +27 -2
  83. package/dist-sdk/src/entities/app/to-tf.js +75 -1
  84. package/dist-sdk/src/entities/approval-chain/build.d.ts +31 -16
  85. package/dist-sdk/src/entities/approval-chain/build.js +49 -49
  86. package/dist-sdk/src/entities/approval-chain/from-tf.d.ts +17 -0
  87. package/dist-sdk/src/entities/approval-chain/from-tf.js +57 -0
  88. package/dist-sdk/src/entities/approval-chain/index.d.ts +2 -3
  89. package/dist-sdk/src/entities/approval-chain/index.js +2 -3
  90. package/dist-sdk/src/entities/approval-chain/module.d.ts +3 -0
  91. package/dist-sdk/src/entities/approval-chain/module.js +51 -0
  92. package/dist-sdk/src/entities/approval-chain/printer.d.ts +2 -0
  93. package/dist-sdk/src/entities/approval-chain/printer.js +21 -0
  94. package/dist-sdk/src/entities/approval-chain/to-tf.d.ts +9 -0
  95. package/dist-sdk/src/entities/approval-chain/to-tf.js +43 -0
  96. package/dist-sdk/src/entities/automation/build.d.ts +10 -6
  97. package/dist-sdk/src/entities/automation/build.js +5 -4
  98. package/dist-sdk/src/entities/automation/deserializer/ast.d.ts +10 -8
  99. package/dist-sdk/src/entities/automation/deserializer/print-automation.js +51 -114
  100. package/dist-sdk/src/entities/automation/filter.d.ts +1 -115
  101. package/dist-sdk/src/entities/automation/filter.js +1 -197
  102. package/dist-sdk/src/entities/automation/from-tf.d.ts +4 -0
  103. package/dist-sdk/src/entities/automation/from-tf.js +202 -119
  104. package/dist-sdk/src/entities/automation/index.d.ts +4 -2
  105. package/dist-sdk/src/entities/automation/index.js +3 -1
  106. package/dist-sdk/src/entities/automation/module.js +10 -4
  107. package/dist-sdk/src/entities/automation/script-code.js +94 -6
  108. package/dist-sdk/src/entities/automation/tasks.d.ts +20 -19
  109. package/dist-sdk/src/entities/automation/tasks.js +2 -2
  110. package/dist-sdk/src/entities/automation/to-tf.d.ts +34 -2
  111. package/dist-sdk/src/entities/automation/to-tf.js +273 -98
  112. package/dist-sdk/src/entities/automation/triggers.d.ts +18 -17
  113. package/dist-sdk/src/entities/automation/triggers.js +1 -1
  114. package/dist-sdk/src/entities/dashboard/build.d.ts +17 -0
  115. package/dist-sdk/src/entities/dashboard/from-tf.d.ts +12 -0
  116. package/dist-sdk/src/entities/dashboard/from-tf.js +95 -0
  117. package/dist-sdk/src/entities/dashboard/module.d.ts +3 -0
  118. package/dist-sdk/src/entities/dashboard/module.js +16 -0
  119. package/dist-sdk/src/entities/dashboard/to-tf.d.ts +30 -0
  120. package/dist-sdk/src/entities/dashboard/to-tf.js +94 -0
  121. package/dist-sdk/src/entities/dashboard-widget/module.d.ts +3 -0
  122. package/dist-sdk/src/entities/dashboard-widget/module.js +10 -0
  123. package/dist-sdk/src/entities/data-lookup/module.d.ts +3 -0
  124. package/dist-sdk/src/entities/data-lookup/module.js +22 -0
  125. package/dist-sdk/src/entities/datamine/build.d.ts +22 -0
  126. package/dist-sdk/src/entities/datamine/build.js +1 -0
  127. package/dist-sdk/src/entities/datamine/from-tf.d.ts +17 -0
  128. package/dist-sdk/src/entities/datamine/from-tf.js +98 -0
  129. package/dist-sdk/src/entities/datamine/module.d.ts +3 -0
  130. package/dist-sdk/src/entities/datamine/module.js +23 -0
  131. package/dist-sdk/src/entities/datamine/to-tf.d.ts +11 -0
  132. package/dist-sdk/src/entities/datamine/to-tf.js +53 -0
  133. package/dist-sdk/src/entities/dynamic-layout/build.d.ts +303 -0
  134. package/dist-sdk/src/entities/dynamic-layout/build.js +4 -0
  135. package/dist-sdk/src/entities/dynamic-layout/dialect.d.ts +2 -0
  136. package/dist-sdk/src/entities/dynamic-layout/dialect.js +9 -0
  137. package/dist-sdk/src/entities/dynamic-layout/from-tf.d.ts +10 -0
  138. package/dist-sdk/src/entities/dynamic-layout/from-tf.js +233 -0
  139. package/dist-sdk/src/entities/dynamic-layout/module.d.ts +3 -0
  140. package/dist-sdk/src/entities/dynamic-layout/module.js +13 -0
  141. package/dist-sdk/src/entities/dynamic-layout/to-tf.d.ts +26 -0
  142. package/dist-sdk/src/entities/dynamic-layout/to-tf.js +267 -0
  143. package/dist-sdk/src/entities/element/build.d.ts +31 -14
  144. package/dist-sdk/src/entities/element/build.js +12 -4
  145. package/dist-sdk/src/entities/element/from-tf.d.ts +9 -1
  146. package/dist-sdk/src/entities/element/from-tf.js +31 -2
  147. package/dist-sdk/src/entities/element/index.d.ts +8 -3
  148. package/dist-sdk/src/entities/element/index.js +4 -1
  149. package/dist-sdk/src/entities/element/module.js +19 -2
  150. package/dist-sdk/src/entities/element/to-tf.js +57 -1
  151. package/dist-sdk/src/entities/field/build.d.ts +4 -3
  152. package/dist-sdk/src/entities/field/calculation-types.d.ts +6 -0
  153. package/dist-sdk/src/entities/field/calculation-types.js +42 -0
  154. package/dist-sdk/src/entities/field/from-tf.js +90 -11
  155. package/dist-sdk/src/entities/field/module.d.ts +1 -0
  156. package/dist-sdk/src/entities/field/module.js +5 -2
  157. package/dist-sdk/src/entities/field/record-shape.d.ts +1 -1
  158. package/dist-sdk/src/entities/field/to-tf.d.ts +1 -1
  159. package/dist-sdk/src/entities/field/to-tf.js +22 -6
  160. package/dist-sdk/src/entities/field/types.js +3 -0
  161. package/dist-sdk/src/entities/file-reader/build.d.ts +66 -19
  162. package/dist-sdk/src/entities/file-reader/build.js +49 -4
  163. package/dist-sdk/src/entities/file-reader/deserializer/print-file-reader.d.ts +1 -0
  164. package/dist-sdk/src/entities/file-reader/deserializer/print-file-reader.js +11 -9
  165. package/dist-sdk/src/entities/file-reader/from-tf.d.ts +1 -1
  166. package/dist-sdk/src/entities/file-reader/from-tf.js +31 -2
  167. package/dist-sdk/src/entities/file-reader/index.d.ts +3 -3
  168. package/dist-sdk/src/entities/file-reader/index.js +3 -3
  169. package/dist-sdk/src/entities/file-reader/module.js +6 -5
  170. package/dist-sdk/src/entities/file-reader/to-tf.d.ts +1 -1
  171. package/dist-sdk/src/entities/file-reader/to-tf.js +5 -2
  172. package/dist-sdk/src/entities/file-reader/types.d.ts +3 -4
  173. package/dist-sdk/src/entities/file-reader/types.js +4 -5
  174. package/dist-sdk/src/entities/org/category.js +4 -5
  175. package/dist-sdk/src/entities/org/group.js +4 -5
  176. package/dist-sdk/src/entities/org/index.d.ts +1 -0
  177. package/dist-sdk/src/entities/org/index.js +1 -0
  178. package/dist-sdk/src/entities/org/phone-provider.d.ts +4 -0
  179. package/dist-sdk/src/entities/org/phone-provider.js +33 -0
  180. package/dist-sdk/src/entities/org/role.d.ts +3 -3
  181. package/dist-sdk/src/entities/org/role.js +9 -6
  182. package/dist-sdk/src/entities/organization/build.d.ts +29 -0
  183. package/dist-sdk/src/entities/organization/build.js +24 -0
  184. package/dist-sdk/src/entities/organization/index.d.ts +2 -0
  185. package/dist-sdk/src/entities/organization/index.js +2 -0
  186. package/dist-sdk/src/entities/organization/module.d.ts +2 -0
  187. package/dist-sdk/src/entities/organization/module.js +18 -0
  188. package/dist-sdk/src/entities/organization/to-tf.d.ts +6 -0
  189. package/dist-sdk/src/entities/organization/to-tf.js +37 -0
  190. package/dist-sdk/src/entities/phone-service/build.d.ts +17 -0
  191. package/dist-sdk/src/entities/phone-service/build.js +31 -0
  192. package/dist-sdk/src/entities/phone-service/deserializer/print-phone-service.d.ts +4 -0
  193. package/dist-sdk/src/entities/phone-service/deserializer/print-phone-service.js +54 -0
  194. package/dist-sdk/src/entities/phone-service/from-tf.d.ts +25 -0
  195. package/dist-sdk/src/entities/phone-service/from-tf.js +75 -0
  196. package/dist-sdk/src/entities/phone-service/index.d.ts +2 -0
  197. package/dist-sdk/src/entities/phone-service/index.js +2 -0
  198. package/dist-sdk/src/entities/phone-service/module.d.ts +3 -0
  199. package/dist-sdk/src/entities/phone-service/module.js +55 -0
  200. package/dist-sdk/src/entities/phone-service/to-tf.d.ts +12 -0
  201. package/dist-sdk/src/entities/phone-service/to-tf.js +54 -0
  202. package/dist-sdk/src/entities/phone-service/types.d.ts +35 -0
  203. package/dist-sdk/src/entities/phone-service/types.js +22 -0
  204. package/dist-sdk/src/entities/record-create-form/from-tf.d.ts +11 -0
  205. package/dist-sdk/src/entities/record-create-form/from-tf.js +74 -0
  206. package/dist-sdk/src/entities/record-create-form/module.d.ts +11 -0
  207. package/dist-sdk/src/entities/record-create-form/module.js +24 -0
  208. package/dist-sdk/src/entities/record-create-form/to-tf.d.ts +33 -0
  209. package/dist-sdk/src/entities/record-create-form/to-tf.js +80 -0
  210. package/dist-sdk/src/entities/relationship/build.d.ts +16 -0
  211. package/dist-sdk/src/entities/relationship/build.js +1 -0
  212. package/dist-sdk/src/entities/relationship/from-tf.d.ts +12 -0
  213. package/dist-sdk/src/entities/relationship/from-tf.js +109 -0
  214. package/dist-sdk/src/entities/relationship/module.d.ts +3 -0
  215. package/dist-sdk/src/entities/relationship/module.js +16 -0
  216. package/dist-sdk/src/entities/relationship/to-tf.d.ts +31 -0
  217. package/dist-sdk/src/entities/relationship/to-tf.js +153 -0
  218. package/dist-sdk/src/entities/role/build.d.ts +65 -0
  219. package/dist-sdk/src/entities/role/build.js +33 -0
  220. package/dist-sdk/src/entities/role/from-tf.d.ts +13 -0
  221. package/dist-sdk/src/entities/role/from-tf.js +138 -0
  222. package/dist-sdk/src/entities/role/to-tf.d.ts +13 -0
  223. package/dist-sdk/src/entities/role/to-tf.js +69 -0
  224. package/dist-sdk/src/entities/search-table/build.d.ts +67 -28
  225. package/dist-sdk/src/entities/search-table/build.js +110 -56
  226. package/dist-sdk/src/entities/search-table/from-tf.d.ts +37 -0
  227. package/dist-sdk/src/entities/search-table/from-tf.js +113 -0
  228. package/dist-sdk/src/entities/search-table/index.d.ts +2 -2
  229. package/dist-sdk/src/entities/search-table/index.js +2 -2
  230. package/dist-sdk/src/entities/search-table/module.js +88 -10
  231. package/dist-sdk/src/entities/search-table/printer.d.ts +2 -0
  232. package/dist-sdk/src/entities/search-table/printer.js +52 -0
  233. package/dist-sdk/src/entities/search-table/to-tf.d.ts +14 -0
  234. package/dist-sdk/src/entities/search-table/to-tf.js +104 -0
  235. package/dist-sdk/src/entities/search-table/types.d.ts +8 -0
  236. package/dist-sdk/src/entities/search-table/types.js +21 -0
  237. package/dist-sdk/src/entities/service-account/build.d.ts +32 -0
  238. package/dist-sdk/src/entities/service-account/build.js +9 -0
  239. package/dist-sdk/src/entities/service-account/from-tf.d.ts +10 -0
  240. package/dist-sdk/src/entities/service-account/from-tf.js +109 -0
  241. package/dist-sdk/src/entities/service-account/module.d.ts +4 -0
  242. package/dist-sdk/src/entities/service-account/module.js +21 -0
  243. package/dist-sdk/src/entities/service-account/ref.d.ts +11 -0
  244. package/dist-sdk/src/entities/service-account/ref.js +5 -0
  245. package/dist-sdk/src/entities/service-account/to-tf.d.ts +11 -0
  246. package/dist-sdk/src/entities/service-account/to-tf.js +72 -0
  247. package/dist-sdk/src/entities/shared/connector-from-tf.d.ts +14 -0
  248. package/dist-sdk/src/entities/shared/connector-from-tf.js +14 -0
  249. package/dist-sdk/src/entities/shared/filters/ast.d.ts +21 -79
  250. package/dist-sdk/src/entities/shared/filters/ast.js +5 -2
  251. package/dist-sdk/src/entities/shared/filters/index.d.ts +94 -206
  252. package/dist-sdk/src/entities/shared/filters/index.js +189 -341
  253. package/dist-sdk/src/entities/shared/filters/print.d.ts +11 -0
  254. package/dist-sdk/src/entities/shared/filters/print.js +122 -0
  255. package/dist-sdk/src/entities/shared/filters/tf-codec.d.ts +170 -0
  256. package/dist-sdk/src/entities/shared/filters/tf-codec.js +527 -0
  257. package/dist-sdk/src/entities/shared/filters/types.d.ts +66 -69
  258. package/dist-sdk/src/entities/shared/filters/types.js +2 -3
  259. package/dist-sdk/src/entities/skill/build.d.ts +2 -2
  260. package/dist-sdk/src/entities/skill/build.js +4 -3
  261. package/dist-sdk/src/entities/skill/deserializer/print-skill-v2.d.ts +10 -0
  262. package/dist-sdk/src/entities/skill/deserializer/print-skill-v2.js +74 -32
  263. package/dist-sdk/src/entities/skill/index.d.ts +2 -1
  264. package/dist-sdk/src/entities/skill/index.js +2 -1
  265. package/dist-sdk/src/entities/skill/module.js +6 -0
  266. package/dist-sdk/src/entities/skill/to-tf.d.ts +5 -1
  267. package/dist-sdk/src/entities/skill/to-tf.js +18 -0
  268. package/dist-sdk/src/entities/skill/tools.d.ts +46 -31
  269. package/dist-sdk/src/entities/skill/tools.js +33 -20
  270. package/dist-sdk/src/entities/skill-tool/from-tf.d.ts +4 -1
  271. package/dist-sdk/src/entities/skill-tool/from-tf.js +76 -8
  272. package/dist-sdk/src/entities/skill-tool/module.js +9 -0
  273. package/dist-sdk/src/entities/skill-tool/to-tf.d.ts +6 -1
  274. package/dist-sdk/src/entities/skill-tool/to-tf.js +94 -42
  275. package/dist-sdk/src/entities/skill-tool/types.js +18 -1
  276. package/dist-sdk/src/entities/table/build.d.ts +64 -23
  277. package/dist-sdk/src/entities/table/build.js +33 -18
  278. package/dist-sdk/src/entities/table/catalog-render.js +6 -0
  279. package/dist-sdk/src/entities/table/deserializer/normalize.d.ts +99 -0
  280. package/dist-sdk/src/entities/table/deserializer/normalize.js +192 -0
  281. package/dist-sdk/src/entities/table/fields/types.d.ts +86 -0
  282. package/dist-sdk/src/entities/table/fields/types.js +12 -0
  283. package/dist-sdk/src/entities/table/fields.d.ts +107 -47
  284. package/dist-sdk/src/entities/table/fields.js +76 -55
  285. package/dist-sdk/src/entities/table/from-tf.d.ts +4 -0
  286. package/dist-sdk/src/entities/table/from-tf.js +261 -0
  287. package/dist-sdk/src/entities/table/index.d.ts +7 -5
  288. package/dist-sdk/src/entities/table/index.js +7 -7
  289. package/dist-sdk/src/entities/table/joins.d.ts +22 -9
  290. package/dist-sdk/src/entities/table/joins.js +8 -16
  291. package/dist-sdk/src/entities/table/module.d.ts +2 -1
  292. package/dist-sdk/src/entities/table/module.js +13 -6
  293. package/dist-sdk/src/entities/table/to-tf.d.ts +10 -0
  294. package/dist-sdk/src/entities/table/to-tf.js +230 -0
  295. package/dist-sdk/src/entities/task/build.d.ts +43 -0
  296. package/dist-sdk/src/entities/task/build.js +17 -0
  297. package/dist-sdk/src/entities/task/from-tf.d.ts +28 -0
  298. package/dist-sdk/src/entities/task/from-tf.js +38 -0
  299. package/dist-sdk/src/entities/task/index.d.ts +1 -0
  300. package/dist-sdk/src/entities/task/index.js +1 -0
  301. package/dist-sdk/src/entities/task/module.d.ts +3 -0
  302. package/dist-sdk/src/entities/task/module.js +12 -0
  303. package/dist-sdk/src/entities/task/to-tf.d.ts +9 -0
  304. package/dist-sdk/src/entities/task/to-tf.js +49 -0
  305. package/dist-sdk/src/entities/view/from-tf.d.ts +7 -2
  306. package/dist-sdk/src/entities/view/from-tf.js +209 -25
  307. package/dist-sdk/src/entities/view/module.js +5 -1
  308. package/dist-sdk/src/entities/view/to-tf.d.ts +49 -7
  309. package/dist-sdk/src/entities/view/to-tf.js +155 -18
  310. package/dist-sdk/src/entities/view/types.d.ts +8 -0
  311. package/dist-sdk/src/entities/view/types.js +43 -0
  312. package/dist-sdk/src/entities/visual-flow/build.d.ts +87 -0
  313. package/dist-sdk/src/entities/visual-flow/build.js +72 -0
  314. package/dist-sdk/src/entities/visual-flow/from-tf.d.ts +49 -0
  315. package/dist-sdk/src/entities/visual-flow/from-tf.js +124 -0
  316. package/dist-sdk/src/entities/visual-flow/index.d.ts +1 -0
  317. package/dist-sdk/src/entities/visual-flow/index.js +1 -0
  318. package/dist-sdk/src/entities/visual-flow/module.d.ts +3 -0
  319. package/dist-sdk/src/entities/visual-flow/module.js +41 -0
  320. package/dist-sdk/src/entities/visual-flow/printer.d.ts +8 -0
  321. package/dist-sdk/src/entities/visual-flow/printer.js +92 -0
  322. package/dist-sdk/src/entities/visual-flow/to-tf.d.ts +14 -0
  323. package/dist-sdk/src/entities/visual-flow/to-tf.js +101 -0
  324. package/dist-sdk/src/entities/widget/build.d.ts +55 -0
  325. package/dist-sdk/src/entities/widget/build.js +1 -0
  326. package/dist-sdk/src/entities/widget/from-tf.d.ts +11 -0
  327. package/dist-sdk/src/entities/widget/from-tf.js +209 -0
  328. package/dist-sdk/src/entities/widget/module.d.ts +3 -0
  329. package/dist-sdk/src/entities/widget/module.js +16 -0
  330. package/dist-sdk/src/entities/widget/to-tf.d.ts +44 -0
  331. package/dist-sdk/src/entities/widget/to-tf.js +204 -0
  332. package/dist-sdk/src/graph/deferred-catalog-render.d.ts +1 -1
  333. package/dist-sdk/src/graph/deferred-catalog-render.js +1 -1
  334. package/dist-sdk/src/graph/index.d.ts +7 -0
  335. package/dist-sdk/src/graph/index.js +4 -18
  336. package/dist-sdk/src/graph/modules.js +30 -1
  337. package/dist-sdk/src/graph/types.d.ts +55 -7
  338. package/dist-sdk/src/internal/sdk-package.d.ts +1 -1
  339. package/dist-sdk/src/internal/sdk-package.js +4 -2
  340. package/package.json +30 -15
  341. package/dist-sdk/src/entities/access-policy/filter.d.ts +0 -61
  342. package/dist-sdk/src/entities/access-policy/filter.js +0 -83
  343. package/dist-sdk/src/entities/approval-chain/steps.d.ts +0 -24
  344. package/dist-sdk/src/entities/approval-chain/steps.js +0 -20
  345. package/dist-sdk/src/entities/flow/activities/agent.d.ts +0 -15
  346. package/dist-sdk/src/entities/flow/activities/agent.js +0 -29
  347. package/dist-sdk/src/entities/flow/activities/approval.d.ts +0 -9
  348. package/dist-sdk/src/entities/flow/activities/approval.js +0 -18
  349. package/dist-sdk/src/entities/flow/activities/automation.d.ts +0 -12
  350. package/dist-sdk/src/entities/flow/activities/automation.js +0 -22
  351. package/dist-sdk/src/entities/flow/activities/ctx.d.ts +0 -34
  352. package/dist-sdk/src/entities/flow/activities/ctx.js +0 -38
  353. package/dist-sdk/src/entities/flow/activities/form.d.ts +0 -22
  354. package/dist-sdk/src/entities/flow/activities/form.js +0 -36
  355. package/dist-sdk/src/entities/flow/activities/index.d.ts +0 -14
  356. package/dist-sdk/src/entities/flow/activities/index.js +0 -13
  357. package/dist-sdk/src/entities/flow/activities/input-refs.d.ts +0 -39
  358. package/dist-sdk/src/entities/flow/activities/input-refs.js +0 -19
  359. package/dist-sdk/src/entities/flow/activities/prompt-template.d.ts +0 -13
  360. package/dist-sdk/src/entities/flow/activities/prompt-template.js +0 -34
  361. package/dist-sdk/src/entities/flow/activities/types.d.ts +0 -33
  362. package/dist-sdk/src/entities/flow/build.d.ts +0 -38
  363. package/dist-sdk/src/entities/flow/build.js +0 -115
  364. package/dist-sdk/src/entities/flow/index.d.ts +0 -8
  365. package/dist-sdk/src/entities/flow/index.js +0 -7
  366. package/dist-sdk/src/entities/flow/serialize.d.ts +0 -51
  367. package/dist-sdk/src/entities/flow/serialize.js +0 -94
  368. package/dist-sdk/src/entities/flow/util.d.ts +0 -27
  369. package/dist-sdk/src/entities/flow/util.js +0 -38
  370. package/dist-sdk/src/entities/table/filter.d.ts +0 -41
  371. package/dist-sdk/src/entities/table/filter.js +0 -89
  372. /package/dist-sdk/src/entities/{flow/activities/types.js → dashboard/build.js} +0 -0
@@ -3,7 +3,7 @@
3
3
  * Moves onto each kind's CatalogFacet when its module lands.
4
4
  */
5
5
  import { asNamedRef, namedFactoryEntry, } from "../catalog/render-helpers.js";
6
- /** Simple `{ name }` / optional parent — flow, approvalChain, nested stubs. */
6
+ /** Simple `{ name }` / optional parent for deferred catalog stubs. */
7
7
  export function renderDeferredNamedEntry(factoryName, opts) {
8
8
  return (args) => {
9
9
  const named = asNamedRef(args.ref);
@@ -40,6 +40,13 @@ export declare const BUILD_VS_EXPORT_REFERENCE_ALIASES: {
40
40
  readonly fromType: string;
41
41
  readonly toType: string;
42
42
  }[];
43
+ /** Entity-declared typed-data-vs-resolved-literal equivalences for export comparison. */
44
+ export declare const BUILD_VS_EXPORT_RESOLVED_DATA_REFERENCE_EQUIVALENCES: {
45
+ attribute: string;
46
+ nestedAttribute: string;
47
+ dataType: string;
48
+ blockType: string;
49
+ }[];
43
50
  /** Kind id → module. */
44
51
  export declare const KIND_BY_ID: ReadonlyMap<KindId, EntityKindModule>;
45
52
  /** @deprecated Use {@link KIND_BY_ID}. */
@@ -14,7 +14,7 @@ export const DATA_FACET_MODULES = KIND_MODULES.filter((m) => m.data.participates
14
14
  export const DATA_FACET_BY_TYPE = (() => {
15
15
  const map = new Map();
16
16
  for (const m of DATA_FACET_MODULES) {
17
- const type = singleResourceType(m);
17
+ const type = m.data.participates ? m.data.resourceType ?? singleResourceType(m) : undefined;
18
18
  if (type !== undefined)
19
19
  map.set(type, m);
20
20
  }
@@ -46,12 +46,14 @@ export const ADOPTABLE_RESOURCE_TYPES = new Set(KIND_MODULES.filter((m) => isTfL
46
46
  export const BUILD_VS_EXPORT_SCOPE_TYPES = new Set([
47
47
  ...KIND_MODULES.filter(isTfLive).flatMap((m) => implementedResourceTypes(m.resource)),
48
48
  ...DATA_FACET_MODULES.filter((m) => m.data.participates && m.data.referencedByBuild).flatMap((m) => {
49
- const type = singleResourceType(m);
49
+ const type = m.data.participates ? m.data.resourceType ?? singleResourceType(m) : undefined;
50
50
  return type !== undefined ? [type] : [];
51
51
  }),
52
52
  ]);
53
53
  /** Entity-declared reference aliases normalized by the live round-trip gate. */
54
54
  export const BUILD_VS_EXPORT_REFERENCE_ALIASES = KIND_MODULES.flatMap((module) => module.roundtrip?.referenceAliases ?? []);
55
+ /** Entity-declared typed-data-vs-resolved-literal equivalences for export comparison. */
56
+ export const BUILD_VS_EXPORT_RESOLVED_DATA_REFERENCE_EQUIVALENCES = KIND_MODULES.flatMap((module) => (module.roundtrip?.resolvedDataReferences ?? []).flatMap((equivalence) => implementedResourceTypes(module.resource).map((blockType) => ({ blockType, ...equivalence }))));
55
57
  /** Kind id → module. */
56
58
  export const KIND_BY_ID = new Map(KIND_MODULES.map((m) => [m.kind, m]));
57
59
  /** @deprecated Use {@link KIND_BY_ID}. */
@@ -137,22 +139,6 @@ function catalogMetaOf(facet) {
137
139
  * (triggerParameter, tableColumn, …) stay residual.
138
140
  */
139
141
  const DEFERRED_CATALOG_META = [
140
- {
141
- refKind: "flow",
142
- catalogBag: "flows",
143
- renderOrder: 25,
144
- catalogRoot: "app",
145
- factoryName: "flowRef",
146
- renderEntry: renderDeferredNamedEntry("flowRef"),
147
- },
148
- {
149
- refKind: "approvalChain",
150
- catalogBag: "approvalChains",
151
- renderOrder: 26,
152
- catalogRoot: "app",
153
- factoryName: "approvalChainRef",
154
- renderEntry: renderDeferredNamedEntry("approvalChainRef"),
155
- },
156
142
  {
157
143
  refKind: "tableColumn",
158
144
  catalogBag: "columns",
@@ -8,17 +8,32 @@ import { agentA2ASkillModule } from "../entities/agent-a2a-skill/module.js";
8
8
  import { agentToolModule } from "../entities/agent-tool/module.js";
9
9
  import { appModule } from "../entities/app/module.js";
10
10
  import { automationModule } from "../entities/automation/module.js";
11
+ import { approvalChainModule } from "../entities/approval-chain/module.js";
11
12
  import { elementModule } from "../entities/element/module.js";
13
+ import { dynamicLayoutModule } from "../entities/dynamic-layout/module.js";
14
+ import { dashboardModule } from "../entities/dashboard/module.js";
15
+ import { dashboardWidgetModule } from "../entities/dashboard-widget/module.js";
16
+ import { datamineModule } from "../entities/datamine/module.js";
17
+ import { dataLookupModules } from "../entities/data-lookup/module.js";
12
18
  import { fieldModule } from "../entities/field/module.js";
13
19
  import { fileReaderModule } from "../entities/file-reader/module.js";
14
- import { aiProviderModules, categoryModule, cloudLinkModule, connectorModule, groupModule, roleModule, userModule, } from "../entities/org/index.js";
20
+ import { visualFlowModule } from "../entities/visual-flow/module.js";
21
+ import { aiProviderModules, categoryModule, cloudLinkModule, connectorModule, groupModule, phoneProviderModule, roleModule, userModule, } from "../entities/org/index.js";
15
22
  import { searchTableModule } from "../entities/search-table/module.js";
23
+ import { recordCreateFormModule } from "../entities/record-create-form/module.js";
24
+ import { relationshipModule } from "../entities/relationship/module.js";
16
25
  import { skillModule } from "../entities/skill/module.js";
17
26
  import { skillToolModule } from "../entities/skill-tool/module.js";
27
+ import { serviceAccountModule } from "../entities/service-account/module.js";
18
28
  import { tableModule } from "../entities/table/module.js";
29
+ import { taskModule } from "../entities/task/module.js";
19
30
  import { managedViewOrderModule, viewModule } from "../entities/view/module.js";
31
+ import { phoneServiceModule } from "../entities/phone-service/module.js";
32
+ import { organizationModule } from "../entities/organization/module.js";
33
+ import { widgetModule } from "../entities/widget/module.js";
20
34
  /** Full kind graph: managed resources + data-facet / org-identity kinds. */
21
35
  export const KIND_MODULES = [
36
+ organizationModule,
22
37
  appModule,
23
38
  elementModule,
24
39
  fieldModule,
@@ -27,18 +42,32 @@ export const KIND_MODULES = [
27
42
  agentToolModule,
28
43
  agentA2ASkillModule,
29
44
  automationModule,
45
+ approvalChainModule,
30
46
  fileReaderModule,
47
+ visualFlowModule,
31
48
  viewModule,
32
49
  managedViewOrderModule,
50
+ recordCreateFormModule,
51
+ dynamicLayoutModule,
52
+ dashboardModule,
53
+ dashboardWidgetModule,
54
+ datamineModule,
55
+ ...dataLookupModules,
56
+ widgetModule,
57
+ relationshipModule,
33
58
  skillModule,
34
59
  skillToolModule,
60
+ serviceAccountModule,
35
61
  searchTableModule,
36
62
  tableModule,
63
+ taskModule,
37
64
  cloudLinkModule,
38
65
  categoryModule,
39
66
  connectorModule,
40
67
  ...aiProviderModules,
41
68
  groupModule,
69
+ phoneProviderModule,
70
+ phoneServiceModule,
42
71
  roleModule,
43
72
  userModule,
44
73
  ];
@@ -8,13 +8,13 @@
8
8
  */
9
9
  import type { DeployableEntity } from "../engine/entity.js";
10
10
  import type { FromTfContext } from "../engine/pull/context.js";
11
- import type { ChildResourceScope, TfBlock } from "../engine/tf/index.js";
12
- export type KindId = "org" | "app" | "element" | "field" | "access-policy" | "agent" | "agent-tool" | "agent-a2a-skill" | "automation" | "file-reader" | "skill" | "skill-tool" | "view" | "managed-view-order" | "search-table" | "table" | "cloud-link" | "category" | "connector" | "ai-provider-anthropic" | "ai-provider-bedrock" | "ai-provider-custom" | "ai-provider-deepgram" | "ai-provider-elevenlab" | "ai-provider-gemini" | "ai-provider-openai" | "ai-provider-snowflake" | "ai-provider-xai" | "ai-provider-managed" | "group" | "role" | "user";
11
+ import type { ChildResourceScope, TfBlock, TfValue } from "../engine/tf/index.js";
12
+ export type KindId = "org" | "app" | "element" | "field" | "access-policy" | "agent" | "agent-tool" | "agent-a2a-skill" | "automation" | "approval-chain" | "file-reader" | "visual-flow" | "skill" | "skill-tool" | "view" | "managed-view-order" | "record-create-form" | "dynamic-layout" | "dashboard" | "dashboard-widget" | "datamine" | "automation-value-references" | "organization" | "permission-template" | "service-account" | "stored-function" | "task" | "widget" | "relationship" | "search-table" | "table" | "cloud-link" | "category" | "connector" | "ai-provider-anthropic" | "ai-provider-bedrock" | "ai-provider-custom" | "ai-provider-deepgram" | "ai-provider-elevenlab" | "ai-provider-gemini" | "ai-provider-openai" | "ai-provider-snowflake" | "ai-provider-xai" | "ai-provider-managed" | "group" | "phone-provider" | "phone-service" | "role" | "user";
13
13
  /** @deprecated Use {@link KindId}. */
14
14
  export type EntityKindId = KindId;
15
15
  export type StreamFacet = {
16
16
  readonly role: "streamRoot";
17
- readonly exportVerb: "apps" | "org" | "elements";
17
+ readonly exportVerb: "apps" | "org" | "elements" | "tasks" | "tables";
18
18
  } | {
19
19
  readonly role: "streamMember";
20
20
  } | {
@@ -76,8 +76,8 @@ export type ResourceFacet = {
76
76
  /** How a resource type belonging to this kind participates in stream partition. */
77
77
  export type StreamMatch = "extract" | "family" | "reported";
78
78
  /** Catalog kinds used by org identity data facets. */
79
- export type DataFacetCatalogKind = "cloudLink" | "category" | "connector" | "group" | "aiProvider";
80
- export type OrgIdentityBag = "cloudLinks" | "categories" | "connectors" | "groups" | "aiProviders";
79
+ export type DataFacetCatalogKind = "cloudLink" | "category" | "connector" | "group" | "phoneProvider" | "aiProvider";
80
+ export type OrgIdentityBag = "cloudLinks" | "categories" | "connectors" | "groups" | "phoneProviders" | "aiProviders";
81
81
  /**
82
82
  * Kind can be materialized as a data lookup / interface (not adopted), or
83
83
  * {@link NO_DATA} when it does not participate.
@@ -86,6 +86,8 @@ export type DataFacet = {
86
86
  readonly participates: false;
87
87
  } | {
88
88
  readonly participates: true;
89
+ /** Data-source type when it differs from, or coexists with, a polymorphic resource facet. */
90
+ readonly resourceType?: string;
89
91
  readonly lookupAttr: string;
90
92
  readonly referencedByBuild: boolean;
91
93
  readonly catalogKind?: DataFacetCatalogKind;
@@ -153,6 +155,8 @@ export interface CatalogRenderResult {
153
155
  * (e.g. `triggerParameterRef` nested under an automation).
154
156
  */
155
157
  readonly extraFactories?: readonly string[];
158
+ /** This entry uses a variant factory instead of this kind's default factory. */
159
+ readonly omitsDefaultFactory?: boolean;
156
160
  }
157
161
  export type CatalogFacet = {
158
162
  readonly participates: false;
@@ -195,6 +199,12 @@ export declare const NO_CATALOG: CatalogFacet;
195
199
  export interface StreamExtractContext extends FromTfContext {
196
200
  readonly appTfLabel: string;
197
201
  readonly appRefName: string;
202
+ /** Actual stream-root kind; app and element children share the same namespace shape. */
203
+ readonly parentScope: ChildResourceScope | "table";
204
+ readonly foreignFieldRefsById?: ReadonlyMap<string, {
205
+ readonly ownerRefName: string;
206
+ readonly fieldKey: string;
207
+ }>;
198
208
  }
199
209
  export interface OwnFileExtractResult {
200
210
  readonly items: readonly unknown[];
@@ -207,6 +217,8 @@ export interface PrintedOwnFile {
207
217
  }
208
218
  export interface PrintOwnFileOptions {
209
219
  readonly appRefName: string;
220
+ /** The owning stream root; required for typed app/element authoring output. */
221
+ readonly parentScope: ChildResourceScope | "table";
210
222
  readonly orgImportPath: string;
211
223
  /**
212
224
  * Set by `edk clone app --target-root` when the destination org differs
@@ -250,6 +262,23 @@ export interface PrintOwnFileOptions {
250
262
  * prints `catalog.<refName>` instead of the literal stub.
251
263
  */
252
264
  readonly foreignElementRefNames?: ReadonlyMap<string, string>;
265
+ /**
266
+ * Live field id → pulled catalog identity. Recursive pull populates this
267
+ * from each dependency export's import blocks so a root export that can
268
+ * only spell a foreign field as a UUID can still print a typed token.
269
+ */
270
+ readonly foreignFieldRefsById?: ReadonlyMap<string, {
271
+ readonly ownerRefName: string;
272
+ readonly fieldKey: string;
273
+ }>;
274
+ /**
275
+ * `JSON.stringify([aspect display name, search-table display name])` →
276
+ * pulled catalog identity. Names are scoped by aspect to avoid collisions.
277
+ */
278
+ readonly foreignSearchTableRefsByName?: ReadonlyMap<string, {
279
+ readonly ownerRefName: string;
280
+ readonly tableKey: string;
281
+ }>;
253
282
  }
254
283
  export interface BuildFieldMetadata {
255
284
  readonly name: string;
@@ -260,16 +289,20 @@ export interface BuildFieldMetadata {
260
289
  export interface BuildChildContext {
261
290
  readonly appRefName: string;
262
291
  readonly appTfLabel: string;
292
+ /** Actual stream-root kind; required by children valid under both apps and elements. */
293
+ readonly parentScope?: ChildResourceScope | "table";
263
294
  readonly orgRefs: unknown;
264
295
  readonly diagnostics: string[];
265
296
  readonly fieldAddresses?: ReadonlyMap<string, string>;
266
297
  readonly fieldNames?: ReadonlyMap<string, string>;
267
298
  readonly fieldMetadata?: ReadonlyMap<string, BuildFieldMetadata>;
268
- /** Every app/element stream root in this build, by refName (see `ToTfContext.workspaceAspects`). */
299
+ /** Every app/element/table stream root in this build, by refName (see `ToTfContext.workspaceAspects`). */
269
300
  readonly workspaceAspects?: ReadonlyMap<string, {
270
- readonly kind: ChildResourceScope;
301
+ readonly kind: ChildResourceScope | "table";
271
302
  readonly tfLabel: string;
272
303
  }>;
304
+ /** The current app/element/table entity, forwarded for owner-local reference resolution. */
305
+ readonly streamRootEntity?: DeployableEntity;
273
306
  /**
274
307
  * Every own-file child entity discovered for THIS bag under the current
275
308
  * app (self included), before any of them are emitted — e.g. every
@@ -285,6 +318,16 @@ export interface BuildChildContext {
285
318
  * cross-sibling disambiguation instead of emitting a colliding address.
286
319
  */
287
320
  readonly siblingEntities?: readonly DeployableEntity[];
321
+ /**
322
+ * The build's shared `locals.tf` attrs map, mutated in place — lets an
323
+ * own-file child (e.g. an automation referencing a foreign field) push a
324
+ * locals contribution of its own, the same way `orgRefs` lets it push a
325
+ * `data.tf` contribution. No child wrote into this before issue #353
326
+ * (cross-app PICKLIST option-label resolution); every stream root's own
327
+ * `appendLocals` (field/locals.ts, app/locals.ts) remains the primary
328
+ * source and keeps writing into the very same object.
329
+ */
330
+ readonly localsAttrs?: Record<string, TfValue>;
288
331
  }
289
332
  /** Result of extracting a stream-root kind (app, element) from a partitioned export. */
290
333
  export interface StreamRootExtractResult {
@@ -378,6 +421,11 @@ export interface EntityKindModule {
378
421
  readonly fromType: string;
379
422
  readonly toType: string;
380
423
  }[];
424
+ readonly resolvedDataReferences?: readonly {
425
+ readonly attribute: string;
426
+ readonly nestedAttribute: string;
427
+ readonly dataType: string;
428
+ }[];
381
429
  };
382
430
  }
383
431
  export declare function implementedResourceTypes(resource: ResourceFacet): readonly string[];
@@ -2,6 +2,6 @@ export declare const SDK_PACKAGE_NAME: "@elementumai/edk";
2
2
  export declare const TRANSITIONAL_SDK_PACKAGE_NAME: "@elementum/edk";
3
3
  export declare const LEGACY_SDK_PACKAGE_NAME: "@elementumltd/edk";
4
4
  export declare const LEGACY_SDK_REGISTRY_SCOPE: "@elementumltd:registry";
5
- export declare const SDK_PUBLIC_SUBPATHS: readonly ["app", "elements", "core", "core/filters", "automations", "agents", "agents/skills", "flows", "flows/activities", "searchTables", "fileReaders", "approvalChains", "tables", "catalog"];
5
+ export declare const SDK_PUBLIC_SUBPATHS: readonly ["app", "elements", "core", "core/filters", "automations", "agents", "agents/skills", "visualFlows", "searchTables", "fileReaders", "approvalChains", "approvalProcesses", "tables", "tasks", "organization", "catalog"];
6
6
  export type SdkPackageSubpath = (typeof SDK_PUBLIC_SUBPATHS)[number];
7
7
  export declare function sdkPackageSpecifier<T extends SdkPackageSubpath>(subpath: T): `${typeof SDK_PACKAGE_NAME}/${T}`;
@@ -10,12 +10,14 @@ export const SDK_PUBLIC_SUBPATHS = [
10
10
  "automations",
11
11
  "agents",
12
12
  "agents/skills",
13
- "flows",
14
- "flows/activities",
13
+ "visualFlows",
15
14
  "searchTables",
16
15
  "fileReaders",
17
16
  "approvalChains",
17
+ "approvalProcesses",
18
18
  "tables",
19
+ "tasks",
20
+ "organization",
19
21
  "catalog",
20
22
  ];
21
23
  export function sdkPackageSpecifier(subpath) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@elementumai/edk",
3
- "version": "0.8.2-alpha.6",
4
- "description": "Elementum Development Kit — statically typed SDK for building Elementum automations, agents, and flows",
3
+ "version": "0.9.2",
4
+ "description": "Elementum Development Kit — statically typed SDK for building Elementum apps, automations, and agents",
5
5
  "type": "module",
6
6
  "license": "SEE LICENSE IN LICENSE",
7
7
  "repository": {
@@ -45,13 +45,9 @@
45
45
  "types": "./dist-sdk/src/entities/skill/index.d.ts",
46
46
  "import": "./dist-sdk/src/entities/skill/index.js"
47
47
  },
48
- "./flows": {
49
- "types": "./dist-sdk/src/entities/flow/index.d.ts",
50
- "import": "./dist-sdk/src/entities/flow/index.js"
51
- },
52
- "./flows/activities": {
53
- "types": "./dist-sdk/src/entities/flow/activities/index.d.ts",
54
- "import": "./dist-sdk/src/entities/flow/activities/index.js"
48
+ "./visualFlows": {
49
+ "types": "./dist-sdk/src/entities/visual-flow/index.d.ts",
50
+ "import": "./dist-sdk/src/entities/visual-flow/index.js"
55
51
  },
56
52
  "./searchTables": {
57
53
  "types": "./dist-sdk/src/entities/search-table/index.d.ts",
@@ -65,10 +61,22 @@
65
61
  "types": "./dist-sdk/src/entities/approval-chain/index.d.ts",
66
62
  "import": "./dist-sdk/src/entities/approval-chain/index.js"
67
63
  },
64
+ "./approvalProcesses": {
65
+ "types": "./dist-sdk/src/entities/approval-chain/index.d.ts",
66
+ "import": "./dist-sdk/src/entities/approval-chain/index.js"
67
+ },
68
68
  "./tables": {
69
69
  "types": "./dist-sdk/src/entities/table/index.d.ts",
70
70
  "import": "./dist-sdk/src/entities/table/index.js"
71
71
  },
72
+ "./tasks": {
73
+ "types": "./dist-sdk/src/entities/task/index.d.ts",
74
+ "import": "./dist-sdk/src/entities/task/index.js"
75
+ },
76
+ "./organization": {
77
+ "types": "./dist-sdk/src/entities/organization/index.d.ts",
78
+ "import": "./dist-sdk/src/entities/organization/index.js"
79
+ },
72
80
  "./catalog": {
73
81
  "types": "./dist-sdk/src/catalog/index.d.ts",
74
82
  "import": "./dist-sdk/src/catalog/index.js"
@@ -97,24 +105,30 @@
97
105
  "agents/skills": [
98
106
  "dist-sdk/src/entities/skill/index.d.ts"
99
107
  ],
100
- "flows": [
101
- "dist-sdk/src/entities/flow/index.d.ts"
102
- ],
103
- "flows/activities": [
104
- "dist-sdk/src/entities/flow/activities/index.d.ts"
105
- ],
106
108
  "searchTables": [
107
109
  "dist-sdk/src/entities/search-table/index.d.ts"
108
110
  ],
111
+ "visualFlows": [
112
+ "dist-sdk/src/entities/visual-flow/index.d.ts"
113
+ ],
109
114
  "fileReaders": [
110
115
  "dist-sdk/src/entities/file-reader/index.d.ts"
111
116
  ],
112
117
  "approvalChains": [
113
118
  "dist-sdk/src/entities/approval-chain/index.d.ts"
114
119
  ],
120
+ "approvalProcesses": [
121
+ "dist-sdk/src/entities/approval-chain/index.d.ts"
122
+ ],
115
123
  "tables": [
116
124
  "dist-sdk/src/entities/table/index.d.ts"
117
125
  ],
126
+ "tasks": [
127
+ "dist-sdk/src/entities/task/index.d.ts"
128
+ ],
129
+ "organization": [
130
+ "dist-sdk/src/entities/organization/index.d.ts"
131
+ ],
118
132
  "catalog": [
119
133
  "dist-sdk/src/catalog/index.d.ts"
120
134
  ]
@@ -152,6 +166,7 @@
152
166
  "prepack": "npm run build:sdk",
153
167
  "pack:dry-run": "npm pack --dry-run",
154
168
  "pack:consumer": "npm run build:sdk && tsx src/scripts/test-package-consumer.ts",
169
+ "release:local-sdk": "bash release/verify-local-sdk-prepare.sh",
155
170
  "test": "tsx src/scripts/test.ts",
156
171
  "test:unit": "tsc --noEmit -p tsconfig.typecheck-tests.json && vitest run",
157
172
  "check:parity": "tsx src/scripts/check-provider-parity.ts",
@@ -1,61 +0,0 @@
1
- /**
2
- * Access-policy filter helpers — build the platform's wire `Filter` shape.
3
- *
4
- * Unlike automation's filter DSL (`entities/automation/filter.ts`), an access
5
- * policy's filter has no trigger/task context to reference — it is always a
6
- * plain row-level-security predicate over the OWNING app/element's own
7
- * fields (confirmed by the frozen provider schema: `elementum_access_policy`
8
- * carries `object_id` + `filter` + principal lists, nothing else). So the
9
- * left-hand side of every operator is always a `FieldRef` catalog token —
10
- * there is no `Ref`/`leftValue` row-less mode to support, and no user-directory
11
- * field scope either (that's a distinct concept used elsewhere, e.g. approval
12
- * chains — access policies filter the aspect's own records, never a fixed
13
- * user-directory attribute).
14
- *
15
- * Operator/value-type coverage matches what `entities/automation/from-tf.ts`'s
16
- * `decodeFilter` can round-trip (true/false/and/or/is_null/in/between/eq/gt/
17
- * gte/lt/lte/like; text/number/boolean/null/current_user/field values) — this
18
- * repo has no wider working filter-grammar implementation to match.
19
- */
20
- import type { FieldRef } from "../../catalog/index.js";
21
- import type { LikeMode } from "../shared/filters/index.js";
22
- /** A wire filter (embeds `FieldRef` tokens at `field` positions). */
23
- export type AccessPolicyFilter = Record<string, unknown>;
24
- type Primitive = string | number | boolean | null;
25
- /**
26
- * Marker produced by {@link currentUser} — compares against the acting
27
- * user's id/email/domain rather than a literal value.
28
- */
29
- export interface CurrentUserFilterValue {
30
- readonly __kind: "currentUser";
31
- readonly currentUserType: "id" | "email" | "domain";
32
- }
33
- export type AccessPolicyFilterValue = Primitive | FieldRef | CurrentUserFilterValue;
34
- /** Compare against the current (acting) user — id by default. */
35
- export declare function currentUser(type?: "id" | "email" | "domain"): CurrentUserFilterValue;
36
- /** Match every record (the minimal valid filter — the default when a policy has none configured). */
37
- export declare function whereTrue(): AccessPolicyFilter;
38
- /** Match no record. */
39
- export declare function whereFalse(): AccessPolicyFilter;
40
- export declare function eq(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
41
- export declare function neq(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
42
- export declare function gt(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
43
- export declare function gte(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
44
- export declare function lt(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
45
- export declare function lte(field: FieldRef, v: AccessPolicyFilterValue): AccessPolicyFilter;
46
- export declare function like(field: FieldRef, v: string, options?: {
47
- readonly not?: boolean;
48
- readonly caseInsensitive?: boolean;
49
- readonly mode?: LikeMode;
50
- }): AccessPolicyFilter;
51
- export declare function isNull(field: FieldRef, options?: {
52
- readonly not?: boolean;
53
- }): AccessPolicyFilter;
54
- export declare function isNotNull(field: FieldRef): AccessPolicyFilter;
55
- export declare function isIn(field: FieldRef, values: readonly AccessPolicyFilterValue[]): AccessPolicyFilter;
56
- export declare function between(field: FieldRef, low: AccessPolicyFilterValue, high: AccessPolicyFilterValue, options?: {
57
- readonly not?: boolean;
58
- }): AccessPolicyFilter;
59
- export declare function and(...children: AccessPolicyFilter[]): AccessPolicyFilter;
60
- export declare function or(...children: AccessPolicyFilter[]): AccessPolicyFilter;
61
- export {};
@@ -1,83 +0,0 @@
1
- /** Compare against the current (acting) user — id by default. */
2
- export function currentUser(type = "id") {
3
- return { __kind: "currentUser", currentUserType: type };
4
- }
5
- function isCurrentUserValue(value) {
6
- return typeof value === "object" && value !== null && value.__kind === "currentUser";
7
- }
8
- function isFieldValue(value) {
9
- return typeof value === "object" && value !== null && value.__kind === "field";
10
- }
11
- /** Map a filter value to the platform's `Value` wire shape. */
12
- function value(v) {
13
- if (isCurrentUserValue(v))
14
- return { type: "CURRENT_USER", currentUserType: v.currentUserType };
15
- if (isFieldValue(v))
16
- return { type: "FIELD", value: v };
17
- if (v === null)
18
- return { type: "NULL" };
19
- if (typeof v === "number")
20
- return { type: "NUMBER", value: v };
21
- if (typeof v === "boolean")
22
- return { type: "BOOLEAN", value: v };
23
- return { type: "TEXT", value: v };
24
- }
25
- /** Match every record (the minimal valid filter — the default when a policy has none configured). */
26
- export function whereTrue() {
27
- return { type: "TRUE" };
28
- }
29
- /** Match no record. */
30
- export function whereFalse() {
31
- return { type: "FALSE" };
32
- }
33
- export function eq(field, v) {
34
- return { type: "EQUALS", field, value: value(v) };
35
- }
36
- export function neq(field, v) {
37
- return { type: "EQUALS", field, value: value(v), not: true };
38
- }
39
- export function gt(field, v) {
40
- return { type: "GREATER_THAN", field, value: value(v) };
41
- }
42
- export function gte(field, v) {
43
- return { type: "GREATER_THAN_EQUALS", field, value: value(v) };
44
- }
45
- export function lt(field, v) {
46
- return { type: "LESS_THAN", field, value: value(v) };
47
- }
48
- export function lte(field, v) {
49
- return { type: "LESS_THAN_EQUALS", field, value: value(v) };
50
- }
51
- export function like(field, v, options) {
52
- return {
53
- type: "LIKE",
54
- field,
55
- value: value(v),
56
- ...(options?.not ? { not: true } : {}),
57
- ...(options?.caseInsensitive !== undefined ? { caseInsensitive: options.caseInsensitive } : {}),
58
- ...(options?.mode ? { mode: options.mode } : {}),
59
- };
60
- }
61
- export function isNull(field, options) {
62
- return { type: "IS_NULL", field, ...(options?.not ? { not: true } : {}) };
63
- }
64
- export function isNotNull(field) {
65
- return isNull(field, { not: true });
66
- }
67
- export function isIn(field, values) {
68
- return { type: "IN", field, values: values.map((v) => value(v)) };
69
- }
70
- export function between(field, low, high, options) {
71
- return {
72
- type: "BETWEEN",
73
- field,
74
- values: [value(low), value(high)],
75
- ...(options?.not ? { not: true } : {}),
76
- };
77
- }
78
- export function and(...children) {
79
- return { type: "AND", children };
80
- }
81
- export function or(...children) {
82
- return { type: "OR", children };
83
- }
@@ -1,24 +0,0 @@
1
- import type { GroupRef } from "../../core/types/group.js";
2
- import type { UserRef } from "../../core/types/user.js";
3
- export interface ApprovalUserStep {
4
- readonly kind: "user";
5
- readonly ref: UserRef;
6
- /** Server step id — present only on pulled chains; round-trips on update. */
7
- readonly id?: string;
8
- }
9
- export interface ApprovalGroupStep {
10
- readonly kind: "group";
11
- readonly ref: GroupRef;
12
- readonly approvalsRequired: number;
13
- readonly denialsRequired: number;
14
- readonly id?: string;
15
- }
16
- export type ApprovalStep = ApprovalUserStep | ApprovalGroupStep;
17
- export declare function userStep(user: UserRef, options?: {
18
- id?: string;
19
- }): ApprovalUserStep;
20
- export declare function groupStep(group: GroupRef, options: {
21
- approvalsRequired: number;
22
- denialsRequired: number;
23
- id?: string;
24
- }): ApprovalGroupStep;
@@ -1,20 +0,0 @@
1
- /**
2
- * v2 approval-chain steps. Parallel to v1 `src/approvalChains/steps.ts`. A step
3
- * targets a user or group by **raw id** (`UserRef`/`GroupRef`) — users and
4
- * groups are org-directory entities the EDK never manages and that don't live
5
- * in v2 state, so they're id-by-value, not catalog tokens.
6
- */
7
- import { EdkValidationError } from "../../../elementum-entity-client/errors.js";
8
- export function userStep(user, options) {
9
- return { kind: "user", ref: user, ...(options?.id != null ? { id: options.id } : {}) };
10
- }
11
- export function groupStep(group, options) {
12
- const { approvalsRequired, denialsRequired, id } = options;
13
- if (approvalsRequired < 0 || denialsRequired < 0) {
14
- throw new EdkValidationError(`groupStep: approvalsRequired and denialsRequired must be >= 0 (got ${approvalsRequired}, ${denialsRequired}).`);
15
- }
16
- if (approvalsRequired === 0 && denialsRequired === 0) {
17
- throw new EdkValidationError("groupStep: at least one of approvalsRequired or denialsRequired must be > 0.");
18
- }
19
- return { kind: "group", ref: group, approvalsRequired, denialsRequired, ...(id != null ? { id } : {}) };
20
- }
@@ -1,15 +0,0 @@
1
- import type { AgentRef } from "../../../catalog/index.js";
2
- import type { FlowInputRefV2 } from "./input-refs.js";
3
- import { type PromptTemplate } from "./prompt-template.js";
4
- import type { FlowActivityDefV2 } from "./types.js";
5
- export interface AgentActivityConfig {
6
- /** The agent that handles this step (resolved to an id at deploy). */
7
- readonly agent: AgentRef;
8
- /** Display name for this activity in the flow. */
9
- readonly name: string;
10
- /** Input mapping passed to the agent as conversation context. */
11
- readonly inputs?: Record<string, FlowInputRefV2>;
12
- /** Initial user message — a plain string or a `promptTemplate(...)`. */
13
- readonly prompt?: string | PromptTemplate;
14
- }
15
- export declare function agentActivity(config: AgentActivityConfig): FlowActivityDefV2;
@@ -1,29 +0,0 @@
1
- /**
2
- * agentActivity — an AGENT step in a v2 flow. References an agent by token;
3
- * optional `inputs` (passed to the agent as context) and `prompt` (initial user
4
- * message) serialize into `configuration`.
5
- */
6
- import { EdkValidationError } from "../../../../elementum-entity-client/errors.js";
7
- import { isPromptTemplate, literalPrompt, validatePromptSegments, } from "./prompt-template.js";
8
- export function agentActivity(config) {
9
- if (!config.name || config.name.trim() === "") {
10
- throw new EdkValidationError("agentActivity requires a non-empty name.");
11
- }
12
- const configuration = {};
13
- if (config.inputs && Object.keys(config.inputs).length > 0)
14
- configuration.inputs = config.inputs;
15
- if (config.prompt != null) {
16
- const prompt = typeof config.prompt === "string" ? literalPrompt(config.prompt) : config.prompt;
17
- if (!isPromptTemplate(prompt)) {
18
- throw new EdkValidationError(`agentActivity "${config.name}": prompt must be a string or promptTemplate(...).`);
19
- }
20
- validatePromptSegments(prompt.segments);
21
- configuration.prompt = prompt;
22
- }
23
- return {
24
- activityType: "AGENT",
25
- name: config.name,
26
- reference: config.agent,
27
- ...(Object.keys(configuration).length > 0 ? { configuration } : {}),
28
- };
29
- }
@@ -1,9 +0,0 @@
1
- import type { ApprovalChainRef } from "../../../catalog/index.js";
2
- import type { FlowActivityDefV2 } from "./types.js";
3
- export interface ApprovalActivityConfig {
4
- /** The approval chain that gates this step (resolved to an id at deploy). */
5
- readonly approvalChain: ApprovalChainRef;
6
- /** Display name for this activity in the flow. */
7
- readonly name: string;
8
- }
9
- export declare function approvalActivity(config: ApprovalActivityConfig): FlowActivityDefV2;