@epilot/sdk 2.1.0-rc.1 → 2.1.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 (359) hide show
  1. package/definitions/app.json +38 -0
  2. package/definitions/automation.json +2 -37
  3. package/definitions/blueprint-manifest-runtime.json +1 -1
  4. package/definitions/blueprint-manifest.json +115 -1
  5. package/definitions/customer-portal-runtime.json +1 -1
  6. package/definitions/customer-portal.json +279 -42
  7. package/definitions/data-management.json +10 -0
  8. package/definitions/email-template.json +25 -3
  9. package/definitions/entity.json +205 -3
  10. package/definitions/erp-integration-runtime.json +1 -1
  11. package/definitions/erp-integration.json +472 -13
  12. package/definitions/journey.json +257 -12
  13. package/definitions/kanban.json +630 -78
  14. package/definitions/organization-runtime.json +1 -1
  15. package/definitions/organization.json +614 -51
  16. package/definitions/workflow.json +40 -0
  17. package/dist/README-VG67PX4R.js +7 -0
  18. package/dist/README-W4B35MRN.cjs +7 -0
  19. package/dist/_index-AMVZBT2K.cjs +99 -0
  20. package/dist/_index-S6LFD3ER.js +99 -0
  21. package/dist/access-token-6BJDZSFE.cjs +7 -0
  22. package/dist/access-token-GSQZLDXR.js +7 -0
  23. package/dist/address-HA4RMRNQ.cjs +7 -0
  24. package/dist/address-QVJUGMOG.js +7 -0
  25. package/dist/address-suggestions-74244BAJ.js +7 -0
  26. package/dist/address-suggestions-IUQMYF27.cjs +7 -0
  27. package/dist/ai-agents-IZWFEUSH.js +7 -0
  28. package/dist/ai-agents-PWHKNRCX.cjs +7 -0
  29. package/dist/apis/access-token.cjs +10 -8
  30. package/dist/apis/access-token.js +5 -3
  31. package/dist/apis/address-suggestions.cjs +10 -8
  32. package/dist/apis/address-suggestions.js +5 -3
  33. package/dist/apis/address.cjs +10 -8
  34. package/dist/apis/address.js +5 -3
  35. package/dist/apis/ai-agents.cjs +10 -8
  36. package/dist/apis/ai-agents.js +5 -3
  37. package/dist/apis/app.cjs +10 -8
  38. package/dist/apis/app.js +5 -3
  39. package/dist/apis/audit-logs.cjs +10 -8
  40. package/dist/apis/audit-logs.js +5 -3
  41. package/dist/apis/automation.cjs +10 -8
  42. package/dist/apis/automation.js +5 -3
  43. package/dist/apis/billing.cjs +10 -8
  44. package/dist/apis/billing.js +5 -3
  45. package/dist/apis/blueprint-manifest.cjs +10 -8
  46. package/dist/apis/blueprint-manifest.js +5 -3
  47. package/dist/apis/consent.cjs +10 -8
  48. package/dist/apis/consent.js +5 -3
  49. package/dist/apis/customer-portal.cjs +10 -8
  50. package/dist/apis/customer-portal.js +5 -3
  51. package/dist/apis/dashboard.cjs +10 -8
  52. package/dist/apis/dashboard.js +5 -3
  53. package/dist/apis/data-management.cjs +10 -8
  54. package/dist/apis/data-management.js +5 -3
  55. package/dist/apis/deduplication.cjs +10 -8
  56. package/dist/apis/deduplication.js +5 -3
  57. package/dist/apis/design.cjs +10 -8
  58. package/dist/apis/design.js +5 -3
  59. package/dist/apis/document.cjs +10 -8
  60. package/dist/apis/document.js +5 -3
  61. package/dist/apis/email-settings.cjs +10 -8
  62. package/dist/apis/email-settings.js +5 -3
  63. package/dist/apis/email-template.cjs +10 -8
  64. package/dist/apis/email-template.js +5 -3
  65. package/dist/apis/entity-mapping.cjs +10 -8
  66. package/dist/apis/entity-mapping.js +5 -3
  67. package/dist/apis/entity.cjs +10 -8
  68. package/dist/apis/entity.js +5 -3
  69. package/dist/apis/environments.cjs +10 -8
  70. package/dist/apis/environments.js +5 -3
  71. package/dist/apis/erp-integration.cjs +10 -8
  72. package/dist/apis/erp-integration.js +5 -3
  73. package/dist/apis/event-catalog.cjs +10 -8
  74. package/dist/apis/event-catalog.js +5 -3
  75. package/dist/apis/file.cjs +10 -8
  76. package/dist/apis/file.js +5 -3
  77. package/dist/apis/iban.cjs +10 -8
  78. package/dist/apis/iban.js +5 -3
  79. package/dist/apis/journey.cjs +10 -8
  80. package/dist/apis/journey.js +5 -3
  81. package/dist/apis/kanban.cjs +10 -8
  82. package/dist/apis/kanban.js +5 -3
  83. package/dist/apis/message.cjs +10 -8
  84. package/dist/apis/message.js +5 -3
  85. package/dist/apis/metering.cjs +10 -8
  86. package/dist/apis/metering.js +5 -3
  87. package/dist/apis/notes.cjs +10 -8
  88. package/dist/apis/notes.js +5 -3
  89. package/dist/apis/notification.cjs +10 -8
  90. package/dist/apis/notification.js +5 -3
  91. package/dist/apis/organization.cjs +10 -8
  92. package/dist/apis/organization.d.cts +2 -2
  93. package/dist/apis/organization.d.ts +2 -2
  94. package/dist/apis/organization.js +5 -3
  95. package/dist/apis/partner-directory.cjs +10 -8
  96. package/dist/apis/partner-directory.js +5 -3
  97. package/dist/apis/permissions.cjs +10 -8
  98. package/dist/apis/permissions.js +5 -3
  99. package/dist/apis/pricing-tier.cjs +10 -8
  100. package/dist/apis/pricing-tier.js +5 -3
  101. package/dist/apis/pricing.cjs +10 -8
  102. package/dist/apis/pricing.js +5 -3
  103. package/dist/apis/purpose.cjs +10 -8
  104. package/dist/apis/purpose.js +5 -3
  105. package/dist/apis/sandbox.cjs +10 -8
  106. package/dist/apis/sandbox.js +5 -3
  107. package/dist/apis/submission.cjs +10 -8
  108. package/dist/apis/submission.js +5 -3
  109. package/dist/apis/targeting.cjs +10 -8
  110. package/dist/apis/targeting.js +5 -3
  111. package/dist/apis/template-variables.cjs +10 -8
  112. package/dist/apis/template-variables.js +5 -3
  113. package/dist/apis/user.cjs +10 -8
  114. package/dist/apis/user.js +5 -3
  115. package/dist/apis/validation-rules.cjs +10 -8
  116. package/dist/apis/validation-rules.js +5 -3
  117. package/dist/apis/webhooks.cjs +10 -8
  118. package/dist/apis/webhooks.js +5 -3
  119. package/dist/apis/workflow-definition.cjs +10 -8
  120. package/dist/apis/workflow-definition.js +5 -3
  121. package/dist/apis/workflow.cjs +10 -8
  122. package/dist/apis/workflow.js +5 -3
  123. package/dist/app-IKHWU222.cjs +7 -0
  124. package/dist/app-VLM3SWKA.js +7 -0
  125. package/dist/audit-logs-5VXHOQ7S.js +7 -0
  126. package/dist/audit-logs-D2LFUA2R.cjs +7 -0
  127. package/dist/automation-3HGCK725.cjs +7 -0
  128. package/dist/automation-72VGEJCY.js +7 -0
  129. package/dist/billing-DUWDISHP.cjs +7 -0
  130. package/dist/billing-IPALEAG2.js +7 -0
  131. package/dist/blueprint-manifest-CXSCRQ5X.js +7 -0
  132. package/dist/blueprint-manifest-SHNZPK5O.cjs +7 -0
  133. package/dist/{chunk-6J7CIOKR.js → chunk-2HOJWFQ4.js} +1 -1
  134. package/dist/{chunk-BDIJHJOG.js → chunk-372VUPHN.js} +1 -1
  135. package/dist/{chunk-Q5TESEDZ.cjs → chunk-3HJEWWPS.cjs} +2 -2
  136. package/dist/{chunk-ID6BXIOZ.js → chunk-3N67SSL3.js} +1 -1
  137. package/dist/chunk-3XEP56SV.cjs +204 -0
  138. package/dist/{chunk-7KFKA3AH.cjs → chunk-3ZZ57K3S.cjs} +2 -2
  139. package/dist/{chunk-CVSQT5PV.cjs → chunk-4SWC43JO.cjs} +2 -2
  140. package/dist/{chunk-O3R6C3WW.js → chunk-4VFQTSJQ.js} +1 -1
  141. package/dist/{chunk-LXAJ722U.js → chunk-57QIBYDN.js} +1 -1
  142. package/dist/{chunk-SPZSDRM6.cjs → chunk-5SNJAD6F.cjs} +2 -2
  143. package/dist/{chunk-OI2M6FSB.js → chunk-73H6TVKN.js} +1 -1
  144. package/dist/{chunk-BB7WFIE2.cjs → chunk-A6JOROUC.cjs} +2 -2
  145. package/dist/{chunk-SHPXCOTN.cjs → chunk-AJKH25H2.cjs} +3 -3
  146. package/dist/{chunk-DBNEZWK2.cjs → chunk-ARWMTXJV.cjs} +2 -2
  147. package/dist/{chunk-7BPPP4M2.js → chunk-B3ZGAG7B.js} +1 -1
  148. package/dist/{chunk-5WN2YXNU.cjs → chunk-BH5ZXK4J.cjs} +2 -2
  149. package/dist/{chunk-JM6HKPSC.cjs → chunk-BWFXLUK5.cjs} +2 -2
  150. package/dist/{chunk-V56ZCL54.js → chunk-C6UTZEHH.js} +1 -1
  151. package/dist/{chunk-ZPCMZO2O.js → chunk-CPKBR34V.js} +1 -1
  152. package/dist/{chunk-UTQY2DSM.js → chunk-CWSHYFVZ.js} +1 -1
  153. package/dist/{chunk-5YVVQBA2.js → chunk-DJKSULPK.js} +1 -1
  154. package/dist/{chunk-XLOXC52O.js → chunk-DNJ54L2G.js} +1 -1
  155. package/dist/{chunk-YXPUCBVK.cjs → chunk-DY2D2IW5.cjs} +2 -2
  156. package/dist/{chunk-Z5LLUUFD.cjs → chunk-E26ZO7QM.cjs} +2 -2
  157. package/dist/{chunk-RNKZDJOY.js → chunk-EBCHCYUO.js} +1 -1
  158. package/dist/{chunk-4MO4WLKA.cjs → chunk-EPAIOB5U.cjs} +2 -2
  159. package/dist/{chunk-UX2IZQNM.cjs → chunk-EQZMT2HF.cjs} +2 -2
  160. package/dist/{chunk-U52A2DMK.cjs → chunk-F376L6PP.cjs} +2 -2
  161. package/dist/{chunk-TBBLLEB2.cjs → chunk-F472YLJG.cjs} +2 -2
  162. package/dist/{chunk-W3MM2BSK.cjs → chunk-FXOX3X7E.cjs} +2 -2
  163. package/dist/{chunk-E4IFBCNM.cjs → chunk-G2REP2VZ.cjs} +2 -2
  164. package/dist/{chunk-CFGXI3FX.js → chunk-GLO477NZ.js} +1 -1
  165. package/dist/{chunk-PBNPZ7UX.js → chunk-H4VSK4KF.js} +1 -1
  166. package/dist/{chunk-33TQRYMY.js → chunk-HPSGM6QP.js} +1 -1
  167. package/dist/{chunk-RQKN4WTW.cjs → chunk-HPYHWTTA.cjs} +2 -2
  168. package/dist/{chunk-5RXE7X63.js → chunk-IH4CMOML.js} +2 -2
  169. package/dist/{chunk-VD5TBK2T.cjs → chunk-IMT3IE5M.cjs} +2 -2
  170. package/dist/{chunk-DIP442PL.js → chunk-IP2WWEOU.js} +1 -1
  171. package/dist/{chunk-FCLW3FLF.js → chunk-IS2VB342.js} +1 -1
  172. package/dist/{chunk-UNHWLNE4.js → chunk-ITX53XAZ.js} +1 -1
  173. package/dist/{chunk-KU2XF4TS.cjs → chunk-JXBXDTFG.cjs} +2 -2
  174. package/dist/{chunk-Y4YQEDR3.js → chunk-K62XK7KU.js} +1 -1
  175. package/dist/chunk-KA3TGFJP.js +14 -0
  176. package/dist/{chunk-IXRDP4VP.js → chunk-KBOVBUBM.js} +1 -1
  177. package/dist/{chunk-MKZGM4A6.js → chunk-KPGC2D6E.js} +1 -1
  178. package/dist/{chunk-ZAPA4RPI.js → chunk-KSXTBGIV.js} +1 -1
  179. package/dist/{chunk-PLBIQ2Y7.cjs → chunk-LCIJ4TJ4.cjs} +2 -2
  180. package/dist/{chunk-TUAAE3UC.cjs → chunk-LQOLYXGQ.cjs} +2 -2
  181. package/dist/{chunk-6ADJEPMJ.js → chunk-LSIWCIQV.js} +1 -1
  182. package/dist/{chunk-CBRWUULQ.js → chunk-MHNSZ4HE.js} +1 -1
  183. package/dist/{chunk-WOOKHE7Y.cjs → chunk-MKX4CKAB.cjs} +2 -2
  184. package/dist/{chunk-N2P26AAD.js → chunk-MRTAFRO7.js} +1 -1
  185. package/dist/{chunk-YGULLD73.js → chunk-MRZ7LGKZ.js} +1 -1
  186. package/dist/{chunk-CLMZ2EXW.js → chunk-MSASBR2Y.js} +1 -1
  187. package/dist/{chunk-KEJRWMXR.cjs → chunk-NAWLLC3T.cjs} +2 -2
  188. package/dist/chunk-NJK5F5TF.cjs +21 -0
  189. package/dist/{chunk-HBPCJRZX.cjs → chunk-NLSZVGHK.cjs} +2 -2
  190. package/dist/{chunk-CK36RZXR.js → chunk-O4LRVGOY.js} +1 -1
  191. package/dist/chunk-OG2DMGU6.cjs +14 -0
  192. package/dist/{chunk-TIJGLQKO.js → chunk-OGQKJTXF.js} +1 -1
  193. package/dist/{chunk-UE4XPL43.js → chunk-PETLAONH.js} +1 -1
  194. package/dist/{chunk-MK4ZGXVE.cjs → chunk-PVSS2WPM.cjs} +2 -2
  195. package/dist/{chunk-ONN5COYQ.cjs → chunk-PXITFTJA.cjs} +2 -2
  196. package/dist/{chunk-ZAXYMQ2B.cjs → chunk-QDVPPRWI.cjs} +2 -2
  197. package/dist/{chunk-IPFHV2FV.cjs → chunk-QKERXNJJ.cjs} +2 -2
  198. package/dist/{chunk-ZDJ3J6Z6.cjs → chunk-QLML3IP5.cjs} +2 -2
  199. package/dist/{chunk-YFHQYQII.js → chunk-QVAJ5JP4.js} +1 -1
  200. package/dist/{chunk-S2QF6HG2.cjs → chunk-RD7E4OSJ.cjs} +2 -2
  201. package/dist/{chunk-XIB2G42L.cjs → chunk-RWSA3LXE.cjs} +2 -2
  202. package/dist/{chunk-R6WNZVTA.cjs → chunk-RXSS67VI.cjs} +2 -2
  203. package/dist/{chunk-UXVV3BSC.cjs → chunk-S3ZNESMC.cjs} +2 -2
  204. package/dist/{chunk-YNPRF4BX.js → chunk-S7NDMDRX.js} +1 -1
  205. package/dist/{chunk-HO7KACZZ.cjs → chunk-SK3VYIZ6.cjs} +2 -2
  206. package/dist/{chunk-CX3KG7D2.cjs → chunk-SMGHAG5C.cjs} +2 -2
  207. package/dist/{chunk-D5FJ26GG.js → chunk-T46LODOF.js} +1 -1
  208. package/dist/{chunk-Y4ZMNMYI.js → chunk-TIJWJVKZ.js} +1 -1
  209. package/dist/{chunk-EIILOQ6X.js → chunk-TLWCYLNA.js} +1 -1
  210. package/dist/{chunk-JX45ME2Z.js → chunk-TRJLYZHD.js} +1 -1
  211. package/dist/{chunk-RNBO3DEN.js → chunk-UKKJMCNH.js} +1 -1
  212. package/dist/chunk-ULBEEHG4.js +204 -0
  213. package/dist/{chunk-UDO4JYVU.cjs → chunk-VGTUK3QD.cjs} +2 -2
  214. package/dist/{chunk-4JPVFLVU.js → chunk-VQ7R36AC.js} +1 -1
  215. package/dist/{chunk-IPDIEZBN.cjs → chunk-VVQB5W7U.cjs} +2 -2
  216. package/dist/{chunk-HKZQ56AS.cjs → chunk-VVVATFGK.cjs} +2 -2
  217. package/dist/{chunk-URRL33D5.cjs → chunk-WMTYO5OX.cjs} +2 -2
  218. package/dist/{chunk-U4BMKRG6.js → chunk-WOSSSFXB.js} +1 -1
  219. package/dist/{chunk-OBQIS3KU.js → chunk-WOXXNKTE.js} +1 -1
  220. package/dist/{chunk-WAKSLH7V.cjs → chunk-XKI2OAYV.cjs} +2 -2
  221. package/dist/{chunk-5Y2KLUU6.cjs → chunk-XR4QF6KQ.cjs} +2 -2
  222. package/dist/{chunk-6BERHKDQ.cjs → chunk-XYHTQ523.cjs} +2 -2
  223. package/dist/{chunk-XD6XML3Z.cjs → chunk-XZYZLSUO.cjs} +2 -2
  224. package/dist/chunk-YPSWSI3M.js +21 -0
  225. package/dist/{chunk-4K3MX2J6.js → chunk-YYBIU5BQ.js} +1 -1
  226. package/dist/{chunk-HSGQSTVK.js → chunk-YZA5WZUS.js} +1 -1
  227. package/dist/{chunk-GGBSLAVO.cjs → chunk-Z4LUE424.cjs} +2 -2
  228. package/dist/{chunk-NSOHW3R6.js → chunk-ZV6XYUXS.js} +1 -1
  229. package/dist/consent-CS2ZBZX4.cjs +7 -0
  230. package/dist/consent-NNYHF2N4.js +7 -0
  231. package/dist/customer-portal-D3SLPAHZ.js +7 -0
  232. package/dist/customer-portal-UR3GN4VU.cjs +7 -0
  233. package/dist/dashboard-UHYR5RTY.cjs +7 -0
  234. package/dist/dashboard-UTPGXFW5.js +7 -0
  235. package/dist/data-management-QH2IJ5QV.js +7 -0
  236. package/dist/data-management-TEFRLGSU.cjs +7 -0
  237. package/dist/deduplication-ECVAZVVA.cjs +7 -0
  238. package/dist/deduplication-GYIST22B.js +7 -0
  239. package/dist/design-KUVXMFFK.cjs +7 -0
  240. package/dist/design-YKBXRW5C.js +7 -0
  241. package/dist/document-CY2A2OE7.js +7 -0
  242. package/dist/document-RYQ7MF6U.cjs +7 -0
  243. package/dist/email-settings-TQ5GGDYG.js +7 -0
  244. package/dist/email-settings-TQC34GST.cjs +7 -0
  245. package/dist/email-template-M2VVL4TI.cjs +7 -0
  246. package/dist/email-template-WYROV3UG.js +7 -0
  247. package/dist/entity-FA6PZX6S.js +7 -0
  248. package/dist/entity-IX5NSHPX.cjs +7 -0
  249. package/dist/entity-mapping-7J3IAGKQ.js +7 -0
  250. package/dist/entity-mapping-ZNMFCUKK.cjs +7 -0
  251. package/dist/environments-E3X6NYGX.js +7 -0
  252. package/dist/environments-P2JS4F5N.cjs +7 -0
  253. package/dist/erp-integration-EP2XFEH5.js +7 -0
  254. package/dist/erp-integration-NNV72VFI.cjs +7 -0
  255. package/dist/event-catalog-C45ISVMP.cjs +7 -0
  256. package/dist/event-catalog-D7VJ7WRS.js +7 -0
  257. package/dist/file-UOWBTDIU.cjs +7 -0
  258. package/dist/file-XSN3NAVZ.js +7 -0
  259. package/dist/iban-24GHLFDB.cjs +7 -0
  260. package/dist/iban-LDKYDVQV.js +7 -0
  261. package/dist/index.cjs +107 -100
  262. package/dist/index.d.cts +17 -2
  263. package/dist/index.d.ts +17 -2
  264. package/dist/index.js +58 -51
  265. package/dist/journey-7CKX67M7.js +7 -0
  266. package/dist/journey-EUZ6MVHG.cjs +7 -0
  267. package/dist/kanban-CHTH2ZSY.cjs +7 -0
  268. package/dist/kanban-HI6LL5WY.js +7 -0
  269. package/dist/message-3XZLJR6R.cjs +7 -0
  270. package/dist/message-ZNMCS5YH.js +7 -0
  271. package/dist/metering-DZNZPPY6.cjs +7 -0
  272. package/dist/metering-KOSCPPKB.js +7 -0
  273. package/dist/notes-3AO5GXIT.js +7 -0
  274. package/dist/notes-MPWOQC5J.cjs +7 -0
  275. package/dist/notification-PZOCUYD5.cjs +7 -0
  276. package/dist/notification-VWDZRSFZ.js +7 -0
  277. package/dist/organization-RARYYG2E.cjs +7 -0
  278. package/dist/organization-ZERPH2IH.js +7 -0
  279. package/dist/{organization.d-Bd2Hmk8v.d.cts → organization.d-DqwnNxMg.d.cts} +34 -7
  280. package/dist/{organization.d-Bd2Hmk8v.d.ts → organization.d-DqwnNxMg.d.ts} +34 -7
  281. package/dist/partner-directory-2XMPQWWX.js +7 -0
  282. package/dist/partner-directory-WHNTKQ5E.cjs +7 -0
  283. package/dist/permissions-4T3GFNB4.js +7 -0
  284. package/dist/permissions-FGBIJNN7.cjs +7 -0
  285. package/dist/pricing-4Z4TOETA.cjs +7 -0
  286. package/dist/pricing-C65DTZSX.js +7 -0
  287. package/dist/pricing-tier-NI35WOUP.cjs +7 -0
  288. package/dist/pricing-tier-VUOFK5Q7.js +7 -0
  289. package/dist/purpose-AKOEUHZ4.cjs +7 -0
  290. package/dist/purpose-RBRV3AQZ.js +7 -0
  291. package/dist/sandbox-2KN4X66E.cjs +7 -0
  292. package/dist/sandbox-L2SOOGGR.js +7 -0
  293. package/dist/submission-7BISSPO6.js +7 -0
  294. package/dist/submission-Q24BU4GS.cjs +7 -0
  295. package/dist/targeting-EYGYZD6M.cjs +7 -0
  296. package/dist/targeting-GEJTJN5Z.js +7 -0
  297. package/dist/template-variables-OAYS2E3G.cjs +1148 -0
  298. package/dist/template-variables-VKDJJZUT.js +1148 -0
  299. package/dist/user-EIEOI3OG.js +7 -0
  300. package/dist/user-NJJ7XVKB.cjs +7 -0
  301. package/dist/validation-rules-P6F5P73P.js +7 -0
  302. package/dist/validation-rules-VDU3CIZV.cjs +7 -0
  303. package/dist/webhooks-I7JWU34X.cjs +7 -0
  304. package/dist/webhooks-WPLEHVPX.js +7 -0
  305. package/dist/workflow-3LLURW3H.js +7 -0
  306. package/dist/workflow-RAGQDYXT.cjs +7 -0
  307. package/dist/workflow-definition-B6ELOZUR.cjs +7 -0
  308. package/dist/workflow-definition-D24CRCK2.js +7 -0
  309. package/docs/access-token.md +440 -0
  310. package/docs/address-suggestions.md +256 -0
  311. package/docs/address.md +284 -0
  312. package/docs/ai-agents.md +1891 -0
  313. package/docs/app.md +3388 -0
  314. package/docs/audit-logs.md +242 -0
  315. package/docs/automation.md +4044 -0
  316. package/docs/billing.md +783 -0
  317. package/docs/blueprint-manifest.md +3234 -0
  318. package/docs/consent.md +213 -0
  319. package/docs/customer-portal.md +11399 -0
  320. package/docs/dashboard.md +640 -0
  321. package/docs/data-management.md +883 -0
  322. package/docs/deduplication.md +135 -0
  323. package/docs/design.md +1273 -0
  324. package/docs/document.md +590 -0
  325. package/docs/email-settings.md +1544 -0
  326. package/docs/email-template.md +1197 -0
  327. package/docs/entity-mapping.md +2864 -0
  328. package/docs/entity.md +9595 -0
  329. package/docs/environments.md +259 -0
  330. package/docs/erp-integration.md +4572 -0
  331. package/docs/event-catalog.md +835 -0
  332. package/docs/file.md +1453 -0
  333. package/docs/iban.md +61 -0
  334. package/docs/journey.md +2268 -0
  335. package/docs/kanban.md +882 -0
  336. package/docs/message.md +2122 -0
  337. package/docs/metering.md +1431 -0
  338. package/docs/notes.md +670 -0
  339. package/docs/notification.md +1207 -0
  340. package/docs/organization.md +733 -0
  341. package/docs/partner-directory.md +1197 -0
  342. package/docs/permissions.md +1047 -0
  343. package/docs/pricing-tier.md +81 -0
  344. package/docs/pricing.md +5923 -0
  345. package/docs/purpose.md +283 -0
  346. package/docs/sandbox.md +389 -0
  347. package/docs/submission.md +195 -0
  348. package/docs/targeting.md +959 -0
  349. package/docs/template-variables.md +1141 -0
  350. package/docs/user.md +2555 -0
  351. package/docs/validation-rules.md +1597 -0
  352. package/docs/webhooks.md +996 -0
  353. package/docs/workflow-definition.md +3842 -0
  354. package/docs/workflow.md +4465 -0
  355. package/package.json +3 -2
  356. package/dist/chunk-GMBRXWMD.cjs +0 -14
  357. package/dist/chunk-L43U5IO3.js +0 -14
  358. package/dist/chunk-XE25WERA.js +0 -125
  359. package/dist/chunk-XEQMAKGA.cjs +0 -125
@@ -0,0 +1,1891 @@
1
+ # AI Agents API - OpenAPI 3.0
2
+
3
+ - **Base URL:** `https://ai-agents.sls.epilot.io`
4
+ - **Full API Docs:** [https://docs.epilot.io/api/ai-agents](https://docs.epilot.io/api/ai-agents)
5
+
6
+ ## Usage
7
+
8
+ ```ts
9
+ import { epilot } from '@epilot/sdk'
10
+
11
+ epilot.authorize(() => '<token>')
12
+ const { data } = await epilot.aiAgents.createAgent(...)
13
+ ```
14
+
15
+ ### Tree-shakeable import
16
+
17
+ ```ts
18
+ import { getClient, authorize } from '@epilot/sdk/ai-agents'
19
+
20
+ const aiAgentsClient = getClient()
21
+ authorize(aiAgentsClient, () => '<token>')
22
+ const { data } = await aiAgentsClient.createAgent(...)
23
+ ```
24
+
25
+ ## Operations
26
+
27
+ **Agents Configuration**
28
+ - [`createAgent`](#createagent)
29
+ - [`listAgents`](#listagents)
30
+ - [`getAgentById`](#getagentbyid)
31
+ - [`updateAgentById`](#updateagentbyid)
32
+ - [`deleteAgentById`](#deleteagentbyid)
33
+
34
+ **Agent Execution**
35
+ - [`executeAgent`](#executeagent)
36
+ - [`listExecutions`](#listexecutions)
37
+ - [`getExecution`](#getexecution)
38
+ - [`cancelExecution`](#cancelexecution)
39
+ - [`getExecutionTrace`](#getexecutiontrace)
40
+ - [`approveExecution`](#approveexecution)
41
+ - [`rejectExecution`](#rejectexecution)
42
+
43
+ **Schemas**
44
+ - [`AgentId`](#agentid)
45
+ - [`CreateAgentRequest`](#createagentrequest)
46
+ - [`UpdateAgentRequest`](#updateagentrequest)
47
+ - [`AgentDefinition`](#agentdefinition)
48
+ - [`ListAgentsResponse`](#listagentsresponse)
49
+ - [`ListExecutionsResponse`](#listexecutionsresponse)
50
+ - [`ApproveExecutionRequest`](#approveexecutionrequest)
51
+ - [`RejectExecutionRequest`](#rejectexecutionrequest)
52
+ - [`ExecuteAgentRequest`](#executeagentrequest)
53
+ - [`ExecutionResponse`](#executionresponse)
54
+ - [`ExecutionTrace`](#executiontrace)
55
+ - [`ExecutionIteration`](#executioniteration)
56
+ - [`PendingAction`](#pendingaction)
57
+ - [`ExecutionError`](#executionerror)
58
+ - [`ExecutionMetrics`](#executionmetrics)
59
+ - [`ToolPreview`](#toolpreview)
60
+ - [`PreviewActionType`](#previewactiontype)
61
+ - [`PreviewEntity`](#previewentity)
62
+ - [`PreviewChange`](#previewchange)
63
+ - [`PreviewValue`](#previewvalue)
64
+ - [`ToolDefinition`](#tooldefinition)
65
+ - [`SkillCategory`](#skillcategory)
66
+ - [`AgentSource`](#agentsource)
67
+ - [`SkillAvailability`](#skillavailability)
68
+ - [`ExecutionContext`](#executioncontext)
69
+ - [`ExecutionPattern`](#executionpattern)
70
+ - [`ExecutionMode`](#executionmode)
71
+ - [`ExecutionStatus`](#executionstatus)
72
+ - [`ParameterType`](#parametertype)
73
+ - [`InputParameterDefinition`](#inputparameterdefinition)
74
+ - [`InputParametersSchema`](#inputparametersschema)
75
+ - [`ModelConfig`](#modelconfig)
76
+ - [`Error`](#error)
77
+
78
+ ### `createAgent`
79
+
80
+ Create Agent definition
81
+
82
+ `POST /v1/agents`
83
+
84
+ ```ts
85
+ const { data } = await client.createAgent(
86
+ null,
87
+ {
88
+ name: 'Email Reply Generator',
89
+ description: 'string',
90
+ category: 'message',
91
+ icon: 'mail-reply',
92
+ system_prompt: 'string',
93
+ tools: ['entity.search', 'message.draft'],
94
+ model_config: {
95
+ model_id: 'anthropic.claude-3-5-sonnet-20241022-v2:0',
96
+ temperature: 0.7,
97
+ max_tokens: 4096
98
+ },
99
+ max_iterations: 10,
100
+ execution_pattern: 'direct',
101
+ execution_mode: 'automatic',
102
+ output_schema: {},
103
+ input_parameters_schema: {
104
+ type: 'object',
105
+ parameters: [
106
+ {
107
+ name: 'target_schema',
108
+ label: 'Target Schema',
109
+ type: 'entity-schema',
110
+ description: 'Entity type to create'
111
+ },
112
+ {
113
+ name: 'confidence_threshold',
114
+ label: 'Confidence Threshold',
115
+ type: 'number',
116
+ minimum: 0,
117
+ maximum: 1,
118
+ default: 0.8
119
+ },
120
+ /* ... 1 more */
121
+ ],
122
+ required: ['target_schema']
123
+ }
124
+ },
125
+ )
126
+ ```
127
+
128
+ <details>
129
+ <summary>Response</summary>
130
+
131
+ ```json
132
+ {
133
+ "agent_id": "skill:email-categorizer",
134
+ "org_id": "string",
135
+ "name": "string",
136
+ "description": "string",
137
+ "category": "message",
138
+ "icon": "string",
139
+ "source": "system",
140
+ "availability": ["flows", "copilot"],
141
+ "allowed_entity_schemas": ["message"],
142
+ "system_prompt": "string",
143
+ "tools": ["string"],
144
+ "model_config": {
145
+ "model_id": "anthropic.claude-3-5-sonnet-20241022-v2:0",
146
+ "temperature": 0.7,
147
+ "max_tokens": 4096
148
+ },
149
+ "max_iterations": 0,
150
+ "execution_pattern": "direct",
151
+ "execution_mode": "automatic",
152
+ "output_schema": {},
153
+ "input_parameters_schema": {
154
+ "type": "object",
155
+ "parameters": [
156
+ {
157
+ "name": "target_schema",
158
+ "label": "Target Schema",
159
+ "type": "entity-schema",
160
+ "description": "Entity type to create"
161
+ },
162
+ {
163
+ "name": "confidence_threshold",
164
+ "label": "Confidence Threshold",
165
+ "type": "number",
166
+ "minimum": 0,
167
+ "maximum": 1,
168
+ "default": 0.8
169
+ }
170
+ ],
171
+ "required": ["target_schema"]
172
+ },
173
+ "version": 0,
174
+ "created_at": "1970-01-01T00:00:00.000Z",
175
+ "updated_at": "1970-01-01T00:00:00.000Z",
176
+ "created_by": "string"
177
+ }
178
+ ```
179
+
180
+ </details>
181
+
182
+ ---
183
+
184
+ ### `listAgents`
185
+
186
+ List all agent configurations
187
+
188
+ `GET /v1/agents`
189
+
190
+ ```ts
191
+ const { data } = await client.listAgents({
192
+ source: 'example',
193
+ availability: 'example',
194
+ entity_schema: 'example',
195
+ })
196
+ ```
197
+
198
+ <details>
199
+ <summary>Response</summary>
200
+
201
+ ```json
202
+ {
203
+ "agents": [
204
+ {
205
+ "agent_id": "skill:email-categorizer",
206
+ "org_id": "string",
207
+ "name": "string",
208
+ "description": "string",
209
+ "category": "message",
210
+ "icon": "string",
211
+ "source": "system",
212
+ "availability": ["flows", "copilot"],
213
+ "allowed_entity_schemas": ["message"],
214
+ "system_prompt": "string",
215
+ "tools": ["string"],
216
+ "model_config": {
217
+ "model_id": "anthropic.claude-3-5-sonnet-20241022-v2:0",
218
+ "temperature": 0.7,
219
+ "max_tokens": 4096
220
+ },
221
+ "max_iterations": 0,
222
+ "execution_pattern": "direct",
223
+ "execution_mode": "automatic",
224
+ "output_schema": {},
225
+ "input_parameters_schema": {
226
+ "type": "object",
227
+ "parameters": [
228
+ {
229
+ "name": "target_schema",
230
+ "label": "Target Schema",
231
+ "type": "entity-schema",
232
+ "description": "Entity type to create"
233
+ },
234
+ {
235
+ "name": "confidence_threshold",
236
+ "label": "Confidence Threshold",
237
+ "type": "number",
238
+ "minimum": 0,
239
+ "maximum": 1,
240
+ "default": 0.8
241
+ }
242
+ ],
243
+ "required": ["target_schema"]
244
+ },
245
+ "version": 0,
246
+ "created_at": "1970-01-01T00:00:00.000Z",
247
+ "updated_at": "1970-01-01T00:00:00.000Z",
248
+ "created_by": "string"
249
+ }
250
+ ],
251
+ "next_cursor": "string"
252
+ }
253
+ ```
254
+
255
+ </details>
256
+
257
+ ---
258
+
259
+ ### `getAgentById`
260
+
261
+ Get the agent configuration by ID
262
+
263
+ `GET /v1/agents/{agent_id}`
264
+
265
+ ```ts
266
+ const { data } = await client.getAgentById({
267
+ agent_id: 'example',
268
+ })
269
+ ```
270
+
271
+ <details>
272
+ <summary>Response</summary>
273
+
274
+ ```json
275
+ {
276
+ "agent_id": "skill:email-categorizer",
277
+ "org_id": "string",
278
+ "name": "string",
279
+ "description": "string",
280
+ "category": "message",
281
+ "icon": "string",
282
+ "source": "system",
283
+ "availability": ["flows", "copilot"],
284
+ "allowed_entity_schemas": ["message"],
285
+ "system_prompt": "string",
286
+ "tools": ["string"],
287
+ "model_config": {
288
+ "model_id": "anthropic.claude-3-5-sonnet-20241022-v2:0",
289
+ "temperature": 0.7,
290
+ "max_tokens": 4096
291
+ },
292
+ "max_iterations": 0,
293
+ "execution_pattern": "direct",
294
+ "execution_mode": "automatic",
295
+ "output_schema": {},
296
+ "input_parameters_schema": {
297
+ "type": "object",
298
+ "parameters": [
299
+ {
300
+ "name": "target_schema",
301
+ "label": "Target Schema",
302
+ "type": "entity-schema",
303
+ "description": "Entity type to create"
304
+ },
305
+ {
306
+ "name": "confidence_threshold",
307
+ "label": "Confidence Threshold",
308
+ "type": "number",
309
+ "minimum": 0,
310
+ "maximum": 1,
311
+ "default": 0.8
312
+ }
313
+ ],
314
+ "required": ["target_schema"]
315
+ },
316
+ "version": 0,
317
+ "created_at": "1970-01-01T00:00:00.000Z",
318
+ "updated_at": "1970-01-01T00:00:00.000Z",
319
+ "created_by": "string"
320
+ }
321
+ ```
322
+
323
+ </details>
324
+
325
+ ---
326
+
327
+ ### `updateAgentById`
328
+
329
+ Update the agent configuration by ID
330
+
331
+ `PUT /v1/agents/{agent_id}`
332
+
333
+ ```ts
334
+ const { data } = await client.updateAgentById(
335
+ {
336
+ agent_id: 'example',
337
+ },
338
+ {
339
+ name: 'string',
340
+ description: 'string',
341
+ category: 'message',
342
+ icon: 'string',
343
+ system_prompt: 'string',
344
+ tools: ['string'],
345
+ model_config: {
346
+ model_id: 'anthropic.claude-3-5-sonnet-20241022-v2:0',
347
+ temperature: 0.7,
348
+ max_tokens: 4096
349
+ },
350
+ max_iterations: 1,
351
+ execution_pattern: 'direct',
352
+ execution_mode: 'automatic',
353
+ output_schema: {},
354
+ input_parameters_schema: {
355
+ type: 'object',
356
+ parameters: [
357
+ {
358
+ name: 'target_schema',
359
+ label: 'Target Schema',
360
+ type: 'entity-schema',
361
+ description: 'Entity type to create'
362
+ },
363
+ {
364
+ name: 'confidence_threshold',
365
+ label: 'Confidence Threshold',
366
+ type: 'number',
367
+ minimum: 0,
368
+ maximum: 1,
369
+ default: 0.8
370
+ },
371
+ /* ... 1 more */
372
+ ],
373
+ required: ['target_schema']
374
+ }
375
+ },
376
+ )
377
+ ```
378
+
379
+ <details>
380
+ <summary>Response</summary>
381
+
382
+ ```json
383
+ {
384
+ "agent_id": "skill:email-categorizer",
385
+ "org_id": "string",
386
+ "name": "string",
387
+ "description": "string",
388
+ "category": "message",
389
+ "icon": "string",
390
+ "source": "system",
391
+ "availability": ["flows", "copilot"],
392
+ "allowed_entity_schemas": ["message"],
393
+ "system_prompt": "string",
394
+ "tools": ["string"],
395
+ "model_config": {
396
+ "model_id": "anthropic.claude-3-5-sonnet-20241022-v2:0",
397
+ "temperature": 0.7,
398
+ "max_tokens": 4096
399
+ },
400
+ "max_iterations": 0,
401
+ "execution_pattern": "direct",
402
+ "execution_mode": "automatic",
403
+ "output_schema": {},
404
+ "input_parameters_schema": {
405
+ "type": "object",
406
+ "parameters": [
407
+ {
408
+ "name": "target_schema",
409
+ "label": "Target Schema",
410
+ "type": "entity-schema",
411
+ "description": "Entity type to create"
412
+ },
413
+ {
414
+ "name": "confidence_threshold",
415
+ "label": "Confidence Threshold",
416
+ "type": "number",
417
+ "minimum": 0,
418
+ "maximum": 1,
419
+ "default": 0.8
420
+ }
421
+ ],
422
+ "required": ["target_schema"]
423
+ },
424
+ "version": 0,
425
+ "created_at": "1970-01-01T00:00:00.000Z",
426
+ "updated_at": "1970-01-01T00:00:00.000Z",
427
+ "created_by": "string"
428
+ }
429
+ ```
430
+
431
+ </details>
432
+
433
+ ---
434
+
435
+ ### `deleteAgentById`
436
+
437
+ Delete the agent configuration by ID
438
+
439
+ `DELETE /v1/agents/{agent_id}`
440
+
441
+ ```ts
442
+ const { data } = await client.deleteAgentById({
443
+ agent_id: 'example',
444
+ })
445
+ ```
446
+
447
+ ---
448
+
449
+ ### `executeAgent`
450
+
451
+ Execute an agent
452
+
453
+ `POST /v1/agents/{agent_id}/execute`
454
+
455
+ ```ts
456
+ const { data } = await client.executeAgent(
457
+ {
458
+ agent_id: 'example',
459
+ },
460
+ {
461
+ input: {
462
+ entity_id: 'string',
463
+ entity_schema: 'string',
464
+ workflow_id: 'string',
465
+ workflow_execution_id: 'string',
466
+ task_id: 'string',
467
+ custom_data: {},
468
+ flow_context: [
469
+ {
470
+ entity_id: 'string',
471
+ entity_schema: 'string'
472
+ }
473
+ ]
474
+ },
475
+ parameters: {},
476
+ execution_mode_override: 'automatic',
477
+ execution_context: 'flows',
478
+ callback_url: 'https://example.com/path',
479
+ timeout_ms: 30000
480
+ },
481
+ )
482
+ ```
483
+
484
+ <details>
485
+ <summary>Response</summary>
486
+
487
+ ```json
488
+ {
489
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
490
+ "agent_id": "skill:email-categorizer",
491
+ "agent_source": "system",
492
+ "agent_name": "string",
493
+ "execution_context": "flows",
494
+ "org_id": "string",
495
+ "status": "pending",
496
+ "input": {},
497
+ "parameters": {},
498
+ "result": {
499
+ "response": "string",
500
+ "structured_output": {}
501
+ },
502
+ "error": {
503
+ "code": "TIMEOUT",
504
+ "message": "string",
505
+ "details": {}
506
+ },
507
+ "pending_action": {
508
+ "tool": "string",
509
+ "input": {},
510
+ "description": "string",
511
+ "preview": {
512
+ "action": {
513
+ "type": "move",
514
+ "verb": "Move Thread"
515
+ },
516
+ "source": {
517
+ "type": "inbox",
518
+ "id": "string",
519
+ "name": "Support Inbox",
520
+ "schema": "string",
521
+ "icon": "string",
522
+ "url": "string"
523
+ },
524
+ "target": {
525
+ "type": "inbox",
526
+ "id": "string",
527
+ "name": "Support Inbox",
528
+ "schema": "string",
529
+ "icon": "string",
530
+ "url": "string"
531
+ },
532
+ "changes": [
533
+ {
534
+ "field": "string",
535
+ "label": "string",
536
+ "from": {
537
+ "type": "text",
538
+ "value": {},
539
+ "values": ["string"],
540
+ "id": "string",
541
+ "name": "string",
542
+ "schema": "string",
543
+ "color": "success"
544
+ },
545
+ "to": {
546
+ "type": "text",
547
+ "value": {},
548
+ "values": ["string"],
549
+ "id": "string",
550
+ "name": "string",
551
+ "schema": "string",
552
+ "color": "success"
553
+ }
554
+ }
555
+ ],
556
+ "metadata": {},
557
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
558
+ }
559
+ },
560
+ "metrics": {
561
+ "total_tokens": 0,
562
+ "input_tokens": 0,
563
+ "output_tokens": 0,
564
+ "total_cost_usd": 0,
565
+ "duration_ms": 0,
566
+ "iteration_count": 0
567
+ },
568
+ "started_at": "1970-01-01T00:00:00.000Z",
569
+ "completed_at": "1970-01-01T00:00:00.000Z"
570
+ }
571
+ ```
572
+
573
+ </details>
574
+
575
+ ---
576
+
577
+ ### `listExecutions`
578
+
579
+ List executions
580
+
581
+ `GET /v1/executions`
582
+
583
+ ```ts
584
+ const { data } = await client.listExecutions({
585
+ agent_id: 'example',
586
+ status: 'example',
587
+ limit: 1,
588
+ })
589
+ ```
590
+
591
+ <details>
592
+ <summary>Response</summary>
593
+
594
+ ```json
595
+ {
596
+ "executions": [
597
+ {
598
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
599
+ "agent_id": "skill:email-categorizer",
600
+ "agent_source": "system",
601
+ "agent_name": "string",
602
+ "execution_context": "flows",
603
+ "org_id": "string",
604
+ "status": "pending",
605
+ "input": {},
606
+ "parameters": {},
607
+ "result": {
608
+ "response": "string",
609
+ "structured_output": {}
610
+ },
611
+ "error": {
612
+ "code": "TIMEOUT",
613
+ "message": "string",
614
+ "details": {}
615
+ },
616
+ "pending_action": {
617
+ "tool": "string",
618
+ "input": {},
619
+ "description": "string",
620
+ "preview": {
621
+ "action": {
622
+ "type": "move",
623
+ "verb": "Move Thread"
624
+ },
625
+ "source": {
626
+ "type": "inbox",
627
+ "id": "string",
628
+ "name": "Support Inbox",
629
+ "schema": "string",
630
+ "icon": "string",
631
+ "url": "string"
632
+ },
633
+ "target": {
634
+ "type": "inbox",
635
+ "id": "string",
636
+ "name": "Support Inbox",
637
+ "schema": "string",
638
+ "icon": "string",
639
+ "url": "string"
640
+ },
641
+ "changes": [
642
+ {
643
+ "field": "string",
644
+ "label": "string",
645
+ "from": {
646
+ "type": "text",
647
+ "value": {},
648
+ "values": ["string"],
649
+ "id": "string",
650
+ "name": "string",
651
+ "schema": "string",
652
+ "color": "success"
653
+ },
654
+ "to": {
655
+ "type": "text",
656
+ "value": {},
657
+ "values": ["string"],
658
+ "id": "string",
659
+ "name": "string",
660
+ "schema": "string",
661
+ "color": "success"
662
+ }
663
+ }
664
+ ],
665
+ "metadata": {},
666
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
667
+ }
668
+ },
669
+ "metrics": {
670
+ "total_tokens": 0,
671
+ "input_tokens": 0,
672
+ "output_tokens": 0,
673
+ "total_cost_usd": 0,
674
+ "duration_ms": 0,
675
+ "iteration_count": 0
676
+ },
677
+ "started_at": "1970-01-01T00:00:00.000Z",
678
+ "completed_at": "1970-01-01T00:00:00.000Z"
679
+ }
680
+ ],
681
+ "next_cursor": "string"
682
+ }
683
+ ```
684
+
685
+ </details>
686
+
687
+ ---
688
+
689
+ ### `getExecution`
690
+
691
+ Get execution by ID
692
+
693
+ `GET /v1/executions/{execution_id}`
694
+
695
+ ```ts
696
+ const { data } = await client.getExecution({
697
+ execution_id: 'example',
698
+ })
699
+ ```
700
+
701
+ <details>
702
+ <summary>Response</summary>
703
+
704
+ ```json
705
+ {
706
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
707
+ "agent_id": "skill:email-categorizer",
708
+ "agent_source": "system",
709
+ "agent_name": "string",
710
+ "execution_context": "flows",
711
+ "org_id": "string",
712
+ "status": "pending",
713
+ "input": {},
714
+ "parameters": {},
715
+ "result": {
716
+ "response": "string",
717
+ "structured_output": {}
718
+ },
719
+ "error": {
720
+ "code": "TIMEOUT",
721
+ "message": "string",
722
+ "details": {}
723
+ },
724
+ "pending_action": {
725
+ "tool": "string",
726
+ "input": {},
727
+ "description": "string",
728
+ "preview": {
729
+ "action": {
730
+ "type": "move",
731
+ "verb": "Move Thread"
732
+ },
733
+ "source": {
734
+ "type": "inbox",
735
+ "id": "string",
736
+ "name": "Support Inbox",
737
+ "schema": "string",
738
+ "icon": "string",
739
+ "url": "string"
740
+ },
741
+ "target": {
742
+ "type": "inbox",
743
+ "id": "string",
744
+ "name": "Support Inbox",
745
+ "schema": "string",
746
+ "icon": "string",
747
+ "url": "string"
748
+ },
749
+ "changes": [
750
+ {
751
+ "field": "string",
752
+ "label": "string",
753
+ "from": {
754
+ "type": "text",
755
+ "value": {},
756
+ "values": ["string"],
757
+ "id": "string",
758
+ "name": "string",
759
+ "schema": "string",
760
+ "color": "success"
761
+ },
762
+ "to": {
763
+ "type": "text",
764
+ "value": {},
765
+ "values": ["string"],
766
+ "id": "string",
767
+ "name": "string",
768
+ "schema": "string",
769
+ "color": "success"
770
+ }
771
+ }
772
+ ],
773
+ "metadata": {},
774
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
775
+ }
776
+ },
777
+ "metrics": {
778
+ "total_tokens": 0,
779
+ "input_tokens": 0,
780
+ "output_tokens": 0,
781
+ "total_cost_usd": 0,
782
+ "duration_ms": 0,
783
+ "iteration_count": 0
784
+ },
785
+ "started_at": "1970-01-01T00:00:00.000Z",
786
+ "completed_at": "1970-01-01T00:00:00.000Z"
787
+ }
788
+ ```
789
+
790
+ </details>
791
+
792
+ ---
793
+
794
+ ### `cancelExecution`
795
+
796
+ Cancel execution
797
+
798
+ `DELETE /v1/executions/{execution_id}`
799
+
800
+ ```ts
801
+ const { data } = await client.cancelExecution({
802
+ execution_id: 'example',
803
+ })
804
+ ```
805
+
806
+ <details>
807
+ <summary>Response</summary>
808
+
809
+ ```json
810
+ {
811
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
812
+ "agent_id": "skill:email-categorizer",
813
+ "agent_source": "system",
814
+ "agent_name": "string",
815
+ "execution_context": "flows",
816
+ "org_id": "string",
817
+ "status": "pending",
818
+ "input": {},
819
+ "parameters": {},
820
+ "result": {
821
+ "response": "string",
822
+ "structured_output": {}
823
+ },
824
+ "error": {
825
+ "code": "TIMEOUT",
826
+ "message": "string",
827
+ "details": {}
828
+ },
829
+ "pending_action": {
830
+ "tool": "string",
831
+ "input": {},
832
+ "description": "string",
833
+ "preview": {
834
+ "action": {
835
+ "type": "move",
836
+ "verb": "Move Thread"
837
+ },
838
+ "source": {
839
+ "type": "inbox",
840
+ "id": "string",
841
+ "name": "Support Inbox",
842
+ "schema": "string",
843
+ "icon": "string",
844
+ "url": "string"
845
+ },
846
+ "target": {
847
+ "type": "inbox",
848
+ "id": "string",
849
+ "name": "Support Inbox",
850
+ "schema": "string",
851
+ "icon": "string",
852
+ "url": "string"
853
+ },
854
+ "changes": [
855
+ {
856
+ "field": "string",
857
+ "label": "string",
858
+ "from": {
859
+ "type": "text",
860
+ "value": {},
861
+ "values": ["string"],
862
+ "id": "string",
863
+ "name": "string",
864
+ "schema": "string",
865
+ "color": "success"
866
+ },
867
+ "to": {
868
+ "type": "text",
869
+ "value": {},
870
+ "values": ["string"],
871
+ "id": "string",
872
+ "name": "string",
873
+ "schema": "string",
874
+ "color": "success"
875
+ }
876
+ }
877
+ ],
878
+ "metadata": {},
879
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
880
+ }
881
+ },
882
+ "metrics": {
883
+ "total_tokens": 0,
884
+ "input_tokens": 0,
885
+ "output_tokens": 0,
886
+ "total_cost_usd": 0,
887
+ "duration_ms": 0,
888
+ "iteration_count": 0
889
+ },
890
+ "started_at": "1970-01-01T00:00:00.000Z",
891
+ "completed_at": "1970-01-01T00:00:00.000Z"
892
+ }
893
+ ```
894
+
895
+ </details>
896
+
897
+ ---
898
+
899
+ ### `getExecutionTrace`
900
+
901
+ Get execution trace/iterations
902
+
903
+ `GET /v1/executions/{execution_id}/trace`
904
+
905
+ ```ts
906
+ const { data } = await client.getExecutionTrace({
907
+ execution_id: 'example',
908
+ })
909
+ ```
910
+
911
+ <details>
912
+ <summary>Response</summary>
913
+
914
+ ```json
915
+ {
916
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
917
+ "iterations": [
918
+ {
919
+ "iteration_index": 0,
920
+ "thought": "string",
921
+ "action": {
922
+ "tool": "string",
923
+ "input": {}
924
+ },
925
+ "observation": {},
926
+ "timestamp": "1970-01-01T00:00:00.000Z",
927
+ "tokens_used": 0,
928
+ "latency_ms": 0
929
+ }
930
+ ],
931
+ "total_iterations": 0
932
+ }
933
+ ```
934
+
935
+ </details>
936
+
937
+ ---
938
+
939
+ ### `approveExecution`
940
+
941
+ Approve pending action
942
+
943
+ `POST /v1/executions/{execution_id}/approve`
944
+
945
+ ```ts
946
+ const { data } = await client.approveExecution(
947
+ {
948
+ execution_id: 'example',
949
+ },
950
+ {
951
+ reason: 'string'
952
+ },
953
+ )
954
+ ```
955
+
956
+ <details>
957
+ <summary>Response</summary>
958
+
959
+ ```json
960
+ {
961
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
962
+ "agent_id": "skill:email-categorizer",
963
+ "agent_source": "system",
964
+ "agent_name": "string",
965
+ "execution_context": "flows",
966
+ "org_id": "string",
967
+ "status": "pending",
968
+ "input": {},
969
+ "parameters": {},
970
+ "result": {
971
+ "response": "string",
972
+ "structured_output": {}
973
+ },
974
+ "error": {
975
+ "code": "TIMEOUT",
976
+ "message": "string",
977
+ "details": {}
978
+ },
979
+ "pending_action": {
980
+ "tool": "string",
981
+ "input": {},
982
+ "description": "string",
983
+ "preview": {
984
+ "action": {
985
+ "type": "move",
986
+ "verb": "Move Thread"
987
+ },
988
+ "source": {
989
+ "type": "inbox",
990
+ "id": "string",
991
+ "name": "Support Inbox",
992
+ "schema": "string",
993
+ "icon": "string",
994
+ "url": "string"
995
+ },
996
+ "target": {
997
+ "type": "inbox",
998
+ "id": "string",
999
+ "name": "Support Inbox",
1000
+ "schema": "string",
1001
+ "icon": "string",
1002
+ "url": "string"
1003
+ },
1004
+ "changes": [
1005
+ {
1006
+ "field": "string",
1007
+ "label": "string",
1008
+ "from": {
1009
+ "type": "text",
1010
+ "value": {},
1011
+ "values": ["string"],
1012
+ "id": "string",
1013
+ "name": "string",
1014
+ "schema": "string",
1015
+ "color": "success"
1016
+ },
1017
+ "to": {
1018
+ "type": "text",
1019
+ "value": {},
1020
+ "values": ["string"],
1021
+ "id": "string",
1022
+ "name": "string",
1023
+ "schema": "string",
1024
+ "color": "success"
1025
+ }
1026
+ }
1027
+ ],
1028
+ "metadata": {},
1029
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
1030
+ }
1031
+ },
1032
+ "metrics": {
1033
+ "total_tokens": 0,
1034
+ "input_tokens": 0,
1035
+ "output_tokens": 0,
1036
+ "total_cost_usd": 0,
1037
+ "duration_ms": 0,
1038
+ "iteration_count": 0
1039
+ },
1040
+ "started_at": "1970-01-01T00:00:00.000Z",
1041
+ "completed_at": "1970-01-01T00:00:00.000Z"
1042
+ }
1043
+ ```
1044
+
1045
+ </details>
1046
+
1047
+ ---
1048
+
1049
+ ### `rejectExecution`
1050
+
1051
+ Reject pending action
1052
+
1053
+ `POST /v1/executions/{execution_id}/reject`
1054
+
1055
+ ```ts
1056
+ const { data } = await client.rejectExecution(
1057
+ {
1058
+ execution_id: 'example',
1059
+ },
1060
+ {
1061
+ reason: 'string'
1062
+ },
1063
+ )
1064
+ ```
1065
+
1066
+ <details>
1067
+ <summary>Response</summary>
1068
+
1069
+ ```json
1070
+ {
1071
+ "execution_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
1072
+ "agent_id": "skill:email-categorizer",
1073
+ "agent_source": "system",
1074
+ "agent_name": "string",
1075
+ "execution_context": "flows",
1076
+ "org_id": "string",
1077
+ "status": "pending",
1078
+ "input": {},
1079
+ "parameters": {},
1080
+ "result": {
1081
+ "response": "string",
1082
+ "structured_output": {}
1083
+ },
1084
+ "error": {
1085
+ "code": "TIMEOUT",
1086
+ "message": "string",
1087
+ "details": {}
1088
+ },
1089
+ "pending_action": {
1090
+ "tool": "string",
1091
+ "input": {},
1092
+ "description": "string",
1093
+ "preview": {
1094
+ "action": {
1095
+ "type": "move",
1096
+ "verb": "Move Thread"
1097
+ },
1098
+ "source": {
1099
+ "type": "inbox",
1100
+ "id": "string",
1101
+ "name": "Support Inbox",
1102
+ "schema": "string",
1103
+ "icon": "string",
1104
+ "url": "string"
1105
+ },
1106
+ "target": {
1107
+ "type": "inbox",
1108
+ "id": "string",
1109
+ "name": "Support Inbox",
1110
+ "schema": "string",
1111
+ "icon": "string",
1112
+ "url": "string"
1113
+ },
1114
+ "changes": [
1115
+ {
1116
+ "field": "string",
1117
+ "label": "string",
1118
+ "from": {
1119
+ "type": "text",
1120
+ "value": {},
1121
+ "values": ["string"],
1122
+ "id": "string",
1123
+ "name": "string",
1124
+ "schema": "string",
1125
+ "color": "success"
1126
+ },
1127
+ "to": {
1128
+ "type": "text",
1129
+ "value": {},
1130
+ "values": ["string"],
1131
+ "id": "string",
1132
+ "name": "string",
1133
+ "schema": "string",
1134
+ "color": "success"
1135
+ }
1136
+ }
1137
+ ],
1138
+ "metadata": {},
1139
+ "summary": "This email discusses solar panel installation and should be handled by the Service team."
1140
+ }
1141
+ },
1142
+ "metrics": {
1143
+ "total_tokens": 0,
1144
+ "input_tokens": 0,
1145
+ "output_tokens": 0,
1146
+ "total_cost_usd": 0,
1147
+ "duration_ms": 0,
1148
+ "iteration_count": 0
1149
+ },
1150
+ "started_at": "1970-01-01T00:00:00.000Z",
1151
+ "completed_at": "1970-01-01T00:00:00.000Z"
1152
+ }
1153
+ ```
1154
+
1155
+ </details>
1156
+
1157
+ ---
1158
+
1159
+ ## Schemas
1160
+
1161
+ ### `AgentId`
1162
+
1163
+ Agent identifier. Can be either:
1164
+ - System skill ID (prefixed): "skill:email-categorizer", "skill:email-labeler"
1165
+ - Custom agent UUID: "0336a235-9417-4dd8-894c-fe81285bba75"
1166
+
1167
+
1168
+ ```ts
1169
+ type AgentId = string
1170
+ ```
1171
+
1172
+ ### `CreateAgentRequest`
1173
+
1174
+ ```ts
1175
+ type CreateAgentRequest = {
1176
+ name: string
1177
+ description?: string
1178
+ category?: "message" | "entity" | "document" | "classification" | "custom"
1179
+ icon?: string
1180
+ system_prompt: string
1181
+ tools?: string[]
1182
+ model_config?: {
1183
+ model_id?: string
1184
+ temperature?: number
1185
+ max_tokens?: number
1186
+ }
1187
+ max_iterations?: number
1188
+ execution_pattern: "direct" | "react"
1189
+ execution_mode?: "automatic" | "approval" | "draft"
1190
+ output_schema?: object
1191
+ input_parameters_schema?: {
1192
+ type: "object"
1193
+ parameters: Array<{
1194
+ name: { ... }
1195
+ label: { ... }
1196
+ type: { ... }
1197
+ description?: { ... }
1198
+ default?: { ... }
1199
+ multi?: { ... }
1200
+ dependsOn?: { ... }
1201
+ visibleWhen?: { ... }
1202
+ enum?: { ... }
1203
+ minimum?: { ... }
1204
+ maximum?: { ... }
1205
+ step?: { ... }
1206
+ minLength?: { ... }
1207
+ maxLength?: { ... }
1208
+ schemaFilter?: { ... }
1209
+ attributeTypeFilter?: { ... }
1210
+ }>
1211
+ required?: string[]
1212
+ }
1213
+ }
1214
+ ```
1215
+
1216
+ ### `UpdateAgentRequest`
1217
+
1218
+ ```ts
1219
+ type UpdateAgentRequest = {
1220
+ name?: string
1221
+ description?: string
1222
+ category?: "message" | "entity" | "document" | "classification" | "custom"
1223
+ icon?: string
1224
+ system_prompt?: string
1225
+ tools?: string[]
1226
+ model_config?: {
1227
+ model_id?: string
1228
+ temperature?: number
1229
+ max_tokens?: number
1230
+ }
1231
+ max_iterations?: number
1232
+ execution_pattern?: "direct" | "react"
1233
+ execution_mode?: "automatic" | "approval" | "draft"
1234
+ output_schema?: object
1235
+ input_parameters_schema?: {
1236
+ type: "object"
1237
+ parameters: Array<{
1238
+ name: { ... }
1239
+ label: { ... }
1240
+ type: { ... }
1241
+ description?: { ... }
1242
+ default?: { ... }
1243
+ multi?: { ... }
1244
+ dependsOn?: { ... }
1245
+ visibleWhen?: { ... }
1246
+ enum?: { ... }
1247
+ minimum?: { ... }
1248
+ maximum?: { ... }
1249
+ step?: { ... }
1250
+ minLength?: { ... }
1251
+ maxLength?: { ... }
1252
+ schemaFilter?: { ... }
1253
+ attributeTypeFilter?: { ... }
1254
+ }>
1255
+ required?: string[]
1256
+ }
1257
+ }
1258
+ ```
1259
+
1260
+ ### `AgentDefinition`
1261
+
1262
+ ```ts
1263
+ type AgentDefinition = {
1264
+ agent_id?: string
1265
+ org_id?: string
1266
+ name?: string
1267
+ description?: string
1268
+ category?: "message" | "entity" | "document" | "classification" | "custom"
1269
+ icon?: string
1270
+ source?: "system" | "custom"
1271
+ availability?: "flows" | "copilot" | "all"[]
1272
+ allowed_entity_schemas?: string[]
1273
+ system_prompt?: string
1274
+ tools?: string[]
1275
+ model_config?: {
1276
+ model_id?: string
1277
+ temperature?: number
1278
+ max_tokens?: number
1279
+ }
1280
+ max_iterations?: number
1281
+ execution_pattern?: "direct" | "react"
1282
+ execution_mode?: "automatic" | "approval" | "draft"
1283
+ output_schema?: object
1284
+ input_parameters_schema?: {
1285
+ type: "object"
1286
+ parameters: Array<{
1287
+ name: { ... }
1288
+ label: { ... }
1289
+ type: { ... }
1290
+ description?: { ... }
1291
+ default?: { ... }
1292
+ multi?: { ... }
1293
+ dependsOn?: { ... }
1294
+ visibleWhen?: { ... }
1295
+ enum?: { ... }
1296
+ minimum?: { ... }
1297
+ maximum?: { ... }
1298
+ step?: { ... }
1299
+ minLength?: { ... }
1300
+ maxLength?: { ... }
1301
+ schemaFilter?: { ... }
1302
+ attributeTypeFilter?: { ... }
1303
+ }>
1304
+ required?: string[]
1305
+ }
1306
+ version?: number
1307
+ created_at?: string // date-time
1308
+ updated_at?: string // date-time
1309
+ created_by?: string
1310
+ }
1311
+ ```
1312
+
1313
+ ### `ListAgentsResponse`
1314
+
1315
+ ```ts
1316
+ type ListAgentsResponse = {
1317
+ agents?: Array<{
1318
+ agent_id?: string
1319
+ org_id?: string
1320
+ name?: string
1321
+ description?: string
1322
+ category?: "message" | "entity" | "document" | "classification" | "custom"
1323
+ icon?: string
1324
+ source?: "system" | "custom"
1325
+ availability?: "flows" | "copilot" | "all"[]
1326
+ allowed_entity_schemas?: string[]
1327
+ system_prompt?: string
1328
+ tools?: string[]
1329
+ model_config?: {
1330
+ model_id?: { ... }
1331
+ temperature?: { ... }
1332
+ max_tokens?: { ... }
1333
+ }
1334
+ max_iterations?: number
1335
+ execution_pattern?: "direct" | "react"
1336
+ execution_mode?: "automatic" | "approval" | "draft"
1337
+ output_schema?: object
1338
+ input_parameters_schema?: {
1339
+ type: { ... }
1340
+ parameters: { ... }
1341
+ required?: { ... }
1342
+ }
1343
+ version?: number
1344
+ created_at?: string // date-time
1345
+ updated_at?: string // date-time
1346
+ created_by?: string
1347
+ }>
1348
+ next_cursor?: string
1349
+ }
1350
+ ```
1351
+
1352
+ ### `ListExecutionsResponse`
1353
+
1354
+ ```ts
1355
+ type ListExecutionsResponse = {
1356
+ executions?: Array<{
1357
+ execution_id?: string // uuid
1358
+ agent_id?: string
1359
+ agent_source?: "system" | "custom"
1360
+ agent_name?: string
1361
+ execution_context?: "flows" | "copilot" | "api"
1362
+ org_id?: string
1363
+ status?: "pending" | "running" | "waiting_approval" | "completed" | "failed" | "cancelled"
1364
+ input?: object
1365
+ parameters?: object
1366
+ result?: {
1367
+ response?: { ... }
1368
+ structured_output?: { ... }
1369
+ }
1370
+ error?: {
1371
+ code?: { ... }
1372
+ message?: { ... }
1373
+ details?: { ... }
1374
+ }
1375
+ pending_action?: {
1376
+ tool?: { ... }
1377
+ input?: { ... }
1378
+ description?: { ... }
1379
+ preview?: { ... }
1380
+ }
1381
+ metrics?: {
1382
+ total_tokens?: { ... }
1383
+ input_tokens?: { ... }
1384
+ output_tokens?: { ... }
1385
+ total_cost_usd?: { ... }
1386
+ duration_ms?: { ... }
1387
+ iteration_count?: { ... }
1388
+ }
1389
+ started_at?: string // date-time
1390
+ completed_at?: string // date-time
1391
+ }>
1392
+ next_cursor?: string
1393
+ }
1394
+ ```
1395
+
1396
+ ### `ApproveExecutionRequest`
1397
+
1398
+ ```ts
1399
+ type ApproveExecutionRequest = {
1400
+ reason?: string
1401
+ }
1402
+ ```
1403
+
1404
+ ### `RejectExecutionRequest`
1405
+
1406
+ ```ts
1407
+ type RejectExecutionRequest = {
1408
+ reason: string
1409
+ }
1410
+ ```
1411
+
1412
+ ### `ExecuteAgentRequest`
1413
+
1414
+ ```ts
1415
+ type ExecuteAgentRequest = {
1416
+ input?: {
1417
+ entity_id?: string
1418
+ entity_schema?: string
1419
+ workflow_id?: string
1420
+ workflow_execution_id?: string
1421
+ task_id?: string
1422
+ custom_data?: Record<string, unknown>
1423
+ flow_context?: Array<{
1424
+ entity_id: { ... }
1425
+ entity_schema: { ... }
1426
+ }>
1427
+ }
1428
+ parameters?: Record<string, unknown>
1429
+ execution_mode_override?: "automatic" | "approval" | "draft"
1430
+ execution_context?: "flows" | "copilot" | "api"
1431
+ callback_url?: string // uri
1432
+ timeout_ms?: number
1433
+ }
1434
+ ```
1435
+
1436
+ ### `ExecutionResponse`
1437
+
1438
+ ```ts
1439
+ type ExecutionResponse = {
1440
+ execution_id?: string // uuid
1441
+ agent_id?: string
1442
+ agent_source?: "system" | "custom"
1443
+ agent_name?: string
1444
+ execution_context?: "flows" | "copilot" | "api"
1445
+ org_id?: string
1446
+ status?: "pending" | "running" | "waiting_approval" | "completed" | "failed" | "cancelled"
1447
+ input?: object
1448
+ parameters?: object
1449
+ result?: {
1450
+ response?: string
1451
+ structured_output?: object
1452
+ }
1453
+ error?: {
1454
+ code?: "TIMEOUT" | "MAX_ITERATIONS_EXCEEDED" | "TOOL_EXECUTION_FAILED" | "LLM_ERROR" | "INVALID_OUTPUT" | "REJECTED" | "INTERNAL_ERROR"
1455
+ message?: string
1456
+ details?: object
1457
+ }
1458
+ pending_action?: {
1459
+ tool?: string
1460
+ input?: object
1461
+ description?: string
1462
+ preview?: {
1463
+ action?: { ... }
1464
+ source?: { ... }
1465
+ target?: { ... }
1466
+ changes?: { ... }
1467
+ metadata?: { ... }
1468
+ summary?: { ... }
1469
+ }
1470
+ }
1471
+ metrics?: {
1472
+ total_tokens?: number
1473
+ input_tokens?: number
1474
+ output_tokens?: number
1475
+ total_cost_usd?: number
1476
+ duration_ms?: number
1477
+ iteration_count?: number
1478
+ }
1479
+ started_at?: string // date-time
1480
+ completed_at?: string // date-time
1481
+ }
1482
+ ```
1483
+
1484
+ ### `ExecutionTrace`
1485
+
1486
+ ```ts
1487
+ type ExecutionTrace = {
1488
+ execution_id?: string // uuid
1489
+ iterations?: Array<{
1490
+ iteration_index?: number
1491
+ thought?: string
1492
+ action?: {
1493
+ tool?: { ... }
1494
+ input?: { ... }
1495
+ }
1496
+ observation?: object
1497
+ timestamp?: string // date-time
1498
+ tokens_used?: number
1499
+ latency_ms?: number
1500
+ }>
1501
+ total_iterations?: number
1502
+ }
1503
+ ```
1504
+
1505
+ ### `ExecutionIteration`
1506
+
1507
+ ```ts
1508
+ type ExecutionIteration = {
1509
+ iteration_index?: number
1510
+ thought?: string
1511
+ action?: {
1512
+ tool?: string
1513
+ input?: object
1514
+ }
1515
+ observation?: object
1516
+ timestamp?: string // date-time
1517
+ tokens_used?: number
1518
+ latency_ms?: number
1519
+ }
1520
+ ```
1521
+
1522
+ ### `PendingAction`
1523
+
1524
+ Action waiting for approval (when status=waiting_approval)
1525
+
1526
+ ```ts
1527
+ type PendingAction = {
1528
+ tool?: string
1529
+ input?: object
1530
+ description?: string
1531
+ preview?: {
1532
+ action?: {
1533
+ type: { ... }
1534
+ verb: { ... }
1535
+ }
1536
+ source?: {
1537
+ type?: { ... }
1538
+ id?: { ... }
1539
+ name?: { ... }
1540
+ schema?: { ... }
1541
+ icon?: { ... }
1542
+ url?: { ... }
1543
+ }
1544
+ target?: {
1545
+ type?: { ... }
1546
+ id?: { ... }
1547
+ name?: { ... }
1548
+ schema?: { ... }
1549
+ icon?: { ... }
1550
+ url?: { ... }
1551
+ }
1552
+ changes?: Array<{
1553
+ field?: { ... }
1554
+ label?: { ... }
1555
+ from?: { ... }
1556
+ to?: { ... }
1557
+ }>
1558
+ metadata?: Record<string, {
1559
+ type: { ... }
1560
+ value?: { ... }
1561
+ values?: { ... }
1562
+ id?: { ... }
1563
+ name?: { ... }
1564
+ schema?: { ... }
1565
+ color?: { ... }
1566
+ }>
1567
+ summary?: string
1568
+ }
1569
+ }
1570
+ ```
1571
+
1572
+ ### `ExecutionError`
1573
+
1574
+ ```ts
1575
+ type ExecutionError = {
1576
+ code?: "TIMEOUT" | "MAX_ITERATIONS_EXCEEDED" | "TOOL_EXECUTION_FAILED" | "LLM_ERROR" | "INVALID_OUTPUT" | "REJECTED" | "INTERNAL_ERROR"
1577
+ message?: string
1578
+ details?: object
1579
+ }
1580
+ ```
1581
+
1582
+ ### `ExecutionMetrics`
1583
+
1584
+ ```ts
1585
+ type ExecutionMetrics = {
1586
+ total_tokens?: number
1587
+ input_tokens?: number
1588
+ output_tokens?: number
1589
+ total_cost_usd?: number
1590
+ duration_ms?: number
1591
+ iteration_count?: number
1592
+ }
1593
+ ```
1594
+
1595
+ ### `ToolPreview`
1596
+
1597
+ Structured preview data for approval UI. Provides a generic format that any tool can populate.
1598
+
1599
+ ```ts
1600
+ type ToolPreview = {
1601
+ action?: {
1602
+ type: "move" | "create" | "update" | "delete" | "apply" | "send" | "link" | "unlink"
1603
+ verb: string
1604
+ }
1605
+ source?: {
1606
+ type?: string
1607
+ id?: string
1608
+ name?: string
1609
+ schema?: string
1610
+ icon?: string
1611
+ url?: string
1612
+ }
1613
+ target?: {
1614
+ type?: string
1615
+ id?: string
1616
+ name?: string
1617
+ schema?: string
1618
+ icon?: string
1619
+ url?: string
1620
+ }
1621
+ changes?: Array<{
1622
+ field?: string
1623
+ label?: string
1624
+ from?: {
1625
+ type: { ... }
1626
+ value?: { ... }
1627
+ values?: { ... }
1628
+ id?: { ... }
1629
+ name?: { ... }
1630
+ schema?: { ... }
1631
+ color?: { ... }
1632
+ }
1633
+ to?: {
1634
+ type: { ... }
1635
+ value?: { ... }
1636
+ values?: { ... }
1637
+ id?: { ... }
1638
+ name?: { ... }
1639
+ schema?: { ... }
1640
+ color?: { ... }
1641
+ }
1642
+ }>
1643
+ metadata?: Record<string, {
1644
+ type: "text" | "number" | "boolean" | "list" | "entity" | "badge"
1645
+ value?: unknown
1646
+ values?: string[]
1647
+ id?: string
1648
+ name?: string
1649
+ schema?: string
1650
+ color?: "success" | "warning" | "error" | "info"
1651
+ }>
1652
+ summary?: string
1653
+ }
1654
+ ```
1655
+
1656
+ ### `PreviewActionType`
1657
+
1658
+ Type of action being previewed
1659
+
1660
+ ```ts
1661
+ type PreviewActionType = "move" | "create" | "update" | "delete" | "apply" | "send" | "link" | "unlink"
1662
+ ```
1663
+
1664
+ ### `PreviewEntity`
1665
+
1666
+ Entity reference for preview display
1667
+
1668
+ ```ts
1669
+ type PreviewEntity = {
1670
+ type?: string
1671
+ id?: string
1672
+ name?: string
1673
+ schema?: string
1674
+ icon?: string
1675
+ url?: string
1676
+ }
1677
+ ```
1678
+
1679
+ ### `PreviewChange`
1680
+
1681
+ A single field change in the preview
1682
+
1683
+ ```ts
1684
+ type PreviewChange = {
1685
+ field?: string
1686
+ label?: string
1687
+ from?: {
1688
+ type: "text" | "number" | "boolean" | "list" | "entity" | "badge"
1689
+ value?: unknown
1690
+ values?: string[]
1691
+ id?: string
1692
+ name?: string
1693
+ schema?: string
1694
+ color?: "success" | "warning" | "error" | "info"
1695
+ }
1696
+ to?: {
1697
+ type: "text" | "number" | "boolean" | "list" | "entity" | "badge"
1698
+ value?: unknown
1699
+ values?: string[]
1700
+ id?: string
1701
+ name?: string
1702
+ schema?: string
1703
+ color?: "success" | "warning" | "error" | "info"
1704
+ }
1705
+ }
1706
+ ```
1707
+
1708
+ ### `PreviewValue`
1709
+
1710
+ Typed value for preview display
1711
+
1712
+ ```ts
1713
+ type PreviewValue = {
1714
+ type: "text" | "number" | "boolean" | "list" | "entity" | "badge"
1715
+ value?: unknown
1716
+ values?: string[]
1717
+ id?: string
1718
+ name?: string
1719
+ schema?: string
1720
+ color?: "success" | "warning" | "error" | "info"
1721
+ }
1722
+ ```
1723
+
1724
+ ### `ToolDefinition`
1725
+
1726
+ ```ts
1727
+ type ToolDefinition = {
1728
+ tool_id?: string
1729
+ name?: string
1730
+ description?: string
1731
+ category?: "entity" | "email" | "taxonomy" | "rag" | "workflow"
1732
+ parameters?: object
1733
+ returns?: object
1734
+ requires_approval?: boolean
1735
+ enabled?: boolean
1736
+ }
1737
+ ```
1738
+
1739
+ ### `SkillCategory`
1740
+
1741
+ ```ts
1742
+ type SkillCategory = "message" | "entity" | "document" | "classification" | "custom"
1743
+ ```
1744
+
1745
+ ### `AgentSource`
1746
+
1747
+ - system: Pre-built by epilot (system skills)
1748
+ - custom: Created by organization
1749
+
1750
+
1751
+ ```ts
1752
+ type AgentSource = "system" | "custom"
1753
+ ```
1754
+
1755
+ ### `SkillAvailability`
1756
+
1757
+ Where the skill/agent is available:
1758
+ - flows: Available in workflow automations
1759
+ - copilot: Available as a sub-agent in copilot
1760
+ - all: Available everywhere
1761
+
1762
+
1763
+ ```ts
1764
+ type SkillAvailability = "flows" | "copilot" | "all"
1765
+ ```
1766
+
1767
+ ### `ExecutionContext`
1768
+
1769
+ Where the execution was triggered from:
1770
+ - flows: Triggered from workflow automation
1771
+ - copilot: Triggered from copilot assistant
1772
+ - api: Direct API call
1773
+
1774
+
1775
+ ```ts
1776
+ type ExecutionContext = "flows" | "copilot" | "api"
1777
+ ```
1778
+
1779
+ ### `ExecutionPattern`
1780
+
1781
+ - direct: Single LLM call, no tools
1782
+ - react: Multi-step reasoning with tool use
1783
+
1784
+
1785
+ ```ts
1786
+ type ExecutionPattern = "direct" | "react"
1787
+ ```
1788
+
1789
+ ### `ExecutionMode`
1790
+
1791
+ - automatic: Execute without human intervention
1792
+ - approval: Pause for human approval before tool execution
1793
+ - draft: Execute but mark output as draft for review
1794
+
1795
+
1796
+ ```ts
1797
+ type ExecutionMode = "automatic" | "approval" | "draft"
1798
+ ```
1799
+
1800
+ ### `ExecutionStatus`
1801
+
1802
+ ```ts
1803
+ type ExecutionStatus = "pending" | "running" | "waiting_approval" | "completed" | "failed" | "cancelled"
1804
+ ```
1805
+
1806
+ ### `ParameterType`
1807
+
1808
+ Base types:
1809
+ - text: Text input field
1810
+ - textarea: Multi-line text input field
1811
+ - number: Numeric input field
1812
+ - boolean: Toggle switch
1813
+ - select: Dropdown selection (requires enum array)
1814
+
1815
+ Custom types (domain-specific):
1816
+ - entity-schema: Entity schema selector (fetches from Entity API)
1817
+ - entity-attribute
1818
+
1819
+ ```ts
1820
+ type ParameterType = "text" | "textarea" | "number" | "boolean" | "select" | "entity-schema" | "entity-attribute" | "entity-id" | "taxonomy" | "taxonomy-classification" | "shared-inbox" | "label"
1821
+ ```
1822
+
1823
+ ### `InputParameterDefinition`
1824
+
1825
+ ```ts
1826
+ type InputParameterDefinition = {
1827
+ name: string
1828
+ label: string
1829
+ type: "text" | "textarea" | "number" | "boolean" | "select" | "entity-schema" | "entity-attribute" | "entity-id" | "taxonomy" | "taxonomy-classification" | "shared-inbox" | "label"
1830
+ description?: string
1831
+ default?: unknown
1832
+ multi?: boolean
1833
+ dependsOn?: string
1834
+ visibleWhen?: Record<string, unknown[]>
1835
+ enum?: string[]
1836
+ minimum?: number
1837
+ maximum?: number
1838
+ step?: number
1839
+ minLength?: number
1840
+ maxLength?: number
1841
+ schemaFilter?: string[]
1842
+ attributeTypeFilter?: string[]
1843
+ }
1844
+ ```
1845
+
1846
+ ### `InputParametersSchema`
1847
+
1848
+ ```ts
1849
+ type InputParametersSchema = {
1850
+ type: "object"
1851
+ parameters: Array<{
1852
+ name: string
1853
+ label: string
1854
+ type: "text" | "textarea" | "number" | "boolean" | "select" | "entity-schema" | "entity-attribute" | "entity-id" | "taxonomy" | "taxonomy-classification" | "shared-inbox" | "label"
1855
+ description?: string
1856
+ default?: unknown
1857
+ multi?: boolean
1858
+ dependsOn?: string
1859
+ visibleWhen?: Record<string, unknown[]>
1860
+ enum?: string[]
1861
+ minimum?: number
1862
+ maximum?: number
1863
+ step?: number
1864
+ minLength?: number
1865
+ maxLength?: number
1866
+ schemaFilter?: string[]
1867
+ attributeTypeFilter?: string[]
1868
+ }>
1869
+ required?: string[]
1870
+ }
1871
+ ```
1872
+
1873
+ ### `ModelConfig`
1874
+
1875
+ ```ts
1876
+ type ModelConfig = {
1877
+ model_id?: string
1878
+ temperature?: number
1879
+ max_tokens?: number
1880
+ }
1881
+ ```
1882
+
1883
+ ### `Error`
1884
+
1885
+ ```ts
1886
+ type Error = {
1887
+ error?: string
1888
+ message?: string
1889
+ details?: object
1890
+ }
1891
+ ```