@taxdao/fintax-mcp 0.2.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 (341) hide show
  1. package/README.md +220 -0
  2. package/dist/app/create-server.d.ts +18 -0
  3. package/dist/app/create-server.js +80 -0
  4. package/dist/app/create-server.js.map +1 -0
  5. package/dist/app/register-tools.d.ts +4 -0
  6. package/dist/app/register-tools.js +18 -0
  7. package/dist/app/register-tools.js.map +1 -0
  8. package/dist/audit/audit-context.d.ts +38 -0
  9. package/dist/audit/audit-context.js +167 -0
  10. package/dist/audit/audit-context.js.map +1 -0
  11. package/dist/audit/audit-sink.d.ts +20 -0
  12. package/dist/audit/audit-sink.js +6 -0
  13. package/dist/audit/audit-sink.js.map +1 -0
  14. package/dist/audit/file-audit-sink.d.ts +6 -0
  15. package/dist/audit/file-audit-sink.js +18 -0
  16. package/dist/audit/file-audit-sink.js.map +1 -0
  17. package/dist/auth/auth-session.d.ts +63 -0
  18. package/dist/auth/auth-session.js +226 -0
  19. package/dist/auth/auth-session.js.map +1 -0
  20. package/dist/auth/credentials.d.ts +6 -0
  21. package/dist/auth/credentials.js +12 -0
  22. package/dist/auth/credentials.js.map +1 -0
  23. package/dist/auth/org-token-provider.d.ts +15 -0
  24. package/dist/auth/org-token-provider.js +62 -0
  25. package/dist/auth/org-token-provider.js.map +1 -0
  26. package/dist/capabilities/capability.d.ts +100 -0
  27. package/dist/capabilities/capability.js +26 -0
  28. package/dist/capabilities/capability.js.map +1 -0
  29. package/dist/capabilities/create-capabilities.d.ts +2 -0
  30. package/dist/capabilities/create-capabilities.js +37 -0
  31. package/dist/capabilities/create-capabilities.js.map +1 -0
  32. package/dist/capabilities/define-capability.d.ts +39 -0
  33. package/dist/capabilities/define-capability.js +64 -0
  34. package/dist/capabilities/define-capability.js.map +1 -0
  35. package/dist/capabilities/definitions/accounting-balances.d.ts +4 -0
  36. package/dist/capabilities/definitions/accounting-balances.js +98 -0
  37. package/dist/capabilities/definitions/accounting-balances.js.map +1 -0
  38. package/dist/capabilities/definitions/accounting-context.d.ts +2 -0
  39. package/dist/capabilities/definitions/accounting-context.js +17 -0
  40. package/dist/capabilities/definitions/accounting-context.js.map +1 -0
  41. package/dist/capabilities/definitions/assets.d.ts +2 -0
  42. package/dist/capabilities/definitions/assets.js +367 -0
  43. package/dist/capabilities/definitions/assets.js.map +1 -0
  44. package/dist/capabilities/definitions/business-documents.d.ts +9 -0
  45. package/dist/capabilities/definitions/business-documents.js +386 -0
  46. package/dist/capabilities/definitions/business-documents.js.map +1 -0
  47. package/dist/capabilities/definitions/dashboard.d.ts +2 -0
  48. package/dist/capabilities/definitions/dashboard.js +153 -0
  49. package/dist/capabilities/definitions/dashboard.js.map +1 -0
  50. package/dist/capabilities/definitions/extended-operation-contracts.d.ts +597 -0
  51. package/dist/capabilities/definitions/extended-operation-contracts.js +1180 -0
  52. package/dist/capabilities/definitions/extended-operation-contracts.js.map +1 -0
  53. package/dist/capabilities/definitions/extended-operations.d.ts +2 -0
  54. package/dist/capabilities/definitions/extended-operations.js +699 -0
  55. package/dist/capabilities/definitions/extended-operations.js.map +1 -0
  56. package/dist/capabilities/definitions/financial-reports.d.ts +2 -0
  57. package/dist/capabilities/definitions/financial-reports.js +100 -0
  58. package/dist/capabilities/definitions/financial-reports.js.map +1 -0
  59. package/dist/capabilities/definitions/fnd-import.d.ts +34 -0
  60. package/dist/capabilities/definitions/fnd-import.js +282 -0
  61. package/dist/capabilities/definitions/fnd-import.js.map +1 -0
  62. package/dist/capabilities/definitions/fund-accounts.d.ts +2 -0
  63. package/dist/capabilities/definitions/fund-accounts.js +188 -0
  64. package/dist/capabilities/definitions/fund-accounts.js.map +1 -0
  65. package/dist/capabilities/definitions/fund-balances.d.ts +2 -0
  66. package/dist/capabilities/definitions/fund-balances.js +84 -0
  67. package/dist/capabilities/definitions/fund-balances.js.map +1 -0
  68. package/dist/capabilities/definitions/journals.d.ts +10 -0
  69. package/dist/capabilities/definitions/journals.js +224 -0
  70. package/dist/capabilities/definitions/journals.js.map +1 -0
  71. package/dist/capabilities/definitions/master-data.d.ts +2 -0
  72. package/dist/capabilities/definitions/master-data.js +451 -0
  73. package/dist/capabilities/definitions/master-data.js.map +1 -0
  74. package/dist/capabilities/definitions/pnl.d.ts +2 -0
  75. package/dist/capabilities/definitions/pnl.js +139 -0
  76. package/dist/capabilities/definitions/pnl.js.map +1 -0
  77. package/dist/capabilities/definitions/reference-data.d.ts +2 -0
  78. package/dist/capabilities/definitions/reference-data.js +169 -0
  79. package/dist/capabilities/definitions/reference-data.js.map +1 -0
  80. package/dist/capabilities/definitions/transaction-drafts.d.ts +2 -0
  81. package/dist/capabilities/definitions/transaction-drafts.js +157 -0
  82. package/dist/capabilities/definitions/transaction-drafts.js.map +1 -0
  83. package/dist/capabilities/definitions/transactions.d.ts +168 -0
  84. package/dist/capabilities/definitions/transactions.js +79 -0
  85. package/dist/capabilities/definitions/transactions.js.map +1 -0
  86. package/dist/capabilities/executor.d.ts +19 -0
  87. package/dist/capabilities/executor.js +134 -0
  88. package/dist/capabilities/executor.js.map +1 -0
  89. package/dist/capabilities/registry.d.ts +7 -0
  90. package/dist/capabilities/registry.js +51 -0
  91. package/dist/capabilities/registry.js.map +1 -0
  92. package/dist/clients/base-client.d.ts +5 -0
  93. package/dist/clients/base-client.js +13 -0
  94. package/dist/clients/base-client.js.map +1 -0
  95. package/dist/clients/http-client.d.ts +29 -0
  96. package/dist/clients/http-client.js +167 -0
  97. package/dist/clients/http-client.js.map +1 -0
  98. package/dist/clients/suite-client.d.ts +5 -0
  99. package/dist/clients/suite-client.js +5 -0
  100. package/dist/clients/suite-client.js.map +1 -0
  101. package/dist/concurrency/lock-manager.d.ts +4 -0
  102. package/dist/concurrency/lock-manager.js +23 -0
  103. package/dist/concurrency/lock-manager.js.map +1 -0
  104. package/dist/config/load-config.d.ts +2 -0
  105. package/dist/config/load-config.js +18 -0
  106. package/dist/config/load-config.js.map +1 -0
  107. package/dist/config/schema.d.ts +24 -0
  108. package/dist/config/schema.js +85 -0
  109. package/dist/config/schema.js.map +1 -0
  110. package/dist/errors/fintax-error.d.ts +24 -0
  111. package/dist/errors/fintax-error.js +21 -0
  112. package/dist/errors/fintax-error.js.map +1 -0
  113. package/dist/errors/normalize-error.d.ts +3 -0
  114. package/dist/errors/normalize-error.js +67 -0
  115. package/dist/errors/normalize-error.js.map +1 -0
  116. package/dist/files/artifact-store.d.ts +17 -0
  117. package/dist/files/artifact-store.js +74 -0
  118. package/dist/files/artifact-store.js.map +1 -0
  119. package/dist/files/input-policy.d.ts +28 -0
  120. package/dist/files/input-policy.js +109 -0
  121. package/dist/files/input-policy.js.map +1 -0
  122. package/dist/files/roots-provider.d.ts +14 -0
  123. package/dist/files/roots-provider.js +47 -0
  124. package/dist/files/roots-provider.js.map +1 -0
  125. package/dist/index.d.ts +2 -0
  126. package/dist/index.js +49 -0
  127. package/dist/index.js.map +1 -0
  128. package/dist/logging/logger.d.ts +3 -0
  129. package/dist/logging/logger.js +13 -0
  130. package/dist/logging/logger.js.map +1 -0
  131. package/dist/policies/idempotency.d.ts +32 -0
  132. package/dist/policies/idempotency.js +155 -0
  133. package/dist/policies/idempotency.js.map +1 -0
  134. package/dist/policies/job-reference.d.ts +16 -0
  135. package/dist/policies/job-reference.js +62 -0
  136. package/dist/policies/job-reference.js.map +1 -0
  137. package/dist/policies/operation-plan.d.ts +27 -0
  138. package/dist/policies/operation-plan.js +99 -0
  139. package/dist/policies/operation-plan.js.map +1 -0
  140. package/dist/policies/redaction.d.ts +2 -0
  141. package/dist/policies/redaction.js +29 -0
  142. package/dist/policies/redaction.js.map +1 -0
  143. package/dist/policies/retry.d.ts +8 -0
  144. package/dist/policies/retry.js +19 -0
  145. package/dist/policies/retry.js.map +1 -0
  146. package/dist/responses/tool-response.d.ts +4 -0
  147. package/dist/responses/tool-response.js +24 -0
  148. package/dist/responses/tool-response.js.map +1 -0
  149. package/dist/schemas/common.d.ts +226 -0
  150. package/dist/schemas/common.js +133 -0
  151. package/dist/schemas/common.js.map +1 -0
  152. package/dist/schemas/domains/accounting-balances.d.ts +497 -0
  153. package/dist/schemas/domains/accounting-balances.js +226 -0
  154. package/dist/schemas/domains/accounting-balances.js.map +1 -0
  155. package/dist/schemas/domains/accounting-context.d.ts +118 -0
  156. package/dist/schemas/domains/accounting-context.js +54 -0
  157. package/dist/schemas/domains/accounting-context.js.map +1 -0
  158. package/dist/schemas/domains/assets.d.ts +2508 -0
  159. package/dist/schemas/domains/assets.js +960 -0
  160. package/dist/schemas/domains/assets.js.map +1 -0
  161. package/dist/schemas/domains/business-documents.d.ts +4406 -0
  162. package/dist/schemas/domains/business-documents.js +1153 -0
  163. package/dist/schemas/domains/business-documents.js.map +1 -0
  164. package/dist/schemas/domains/configuration.d.ts +518 -0
  165. package/dist/schemas/domains/configuration.js +504 -0
  166. package/dist/schemas/domains/configuration.js.map +1 -0
  167. package/dist/schemas/domains/dashboard.d.ts +339 -0
  168. package/dist/schemas/domains/dashboard.js +211 -0
  169. package/dist/schemas/domains/dashboard.js.map +1 -0
  170. package/dist/schemas/domains/extended-operation-results.d.ts +1588 -0
  171. package/dist/schemas/domains/extended-operation-results.js +275 -0
  172. package/dist/schemas/domains/extended-operation-results.js.map +1 -0
  173. package/dist/schemas/domains/extended-operations.d.ts +1061 -0
  174. package/dist/schemas/domains/extended-operations.js +567 -0
  175. package/dist/schemas/domains/extended-operations.js.map +1 -0
  176. package/dist/schemas/domains/extended-query-results.d.ts +1688 -0
  177. package/dist/schemas/domains/extended-query-results.js +337 -0
  178. package/dist/schemas/domains/extended-query-results.js.map +1 -0
  179. package/dist/schemas/domains/financial-reports.d.ts +540 -0
  180. package/dist/schemas/domains/financial-reports.js +206 -0
  181. package/dist/schemas/domains/financial-reports.js.map +1 -0
  182. package/dist/schemas/domains/fnd-import.d.ts +912 -0
  183. package/dist/schemas/domains/fnd-import.js +396 -0
  184. package/dist/schemas/domains/fnd-import.js.map +1 -0
  185. package/dist/schemas/domains/fund-accounts.d.ts +1092 -0
  186. package/dist/schemas/domains/fund-accounts.js +410 -0
  187. package/dist/schemas/domains/fund-accounts.js.map +1 -0
  188. package/dist/schemas/domains/fund-balances.d.ts +476 -0
  189. package/dist/schemas/domains/fund-balances.js +233 -0
  190. package/dist/schemas/domains/fund-balances.js.map +1 -0
  191. package/dist/schemas/domains/journals.d.ts +1619 -0
  192. package/dist/schemas/domains/journals.js +615 -0
  193. package/dist/schemas/domains/journals.js.map +1 -0
  194. package/dist/schemas/domains/master-data.d.ts +2010 -0
  195. package/dist/schemas/domains/master-data.js +799 -0
  196. package/dist/schemas/domains/master-data.js.map +1 -0
  197. package/dist/schemas/domains/pnl.d.ts +837 -0
  198. package/dist/schemas/domains/pnl.js +469 -0
  199. package/dist/schemas/domains/pnl.js.map +1 -0
  200. package/dist/schemas/domains/reference-data.d.ts +227 -0
  201. package/dist/schemas/domains/reference-data.js +144 -0
  202. package/dist/schemas/domains/reference-data.js.map +1 -0
  203. package/dist/schemas/domains/transaction-drafts.d.ts +903 -0
  204. package/dist/schemas/domains/transaction-drafts.js +242 -0
  205. package/dist/schemas/domains/transaction-drafts.js.map +1 -0
  206. package/dist/schemas/domains/transactions.d.ts +910 -0
  207. package/dist/schemas/domains/transactions.js +266 -0
  208. package/dist/schemas/domains/transactions.js.map +1 -0
  209. package/dist/schemas/primitives.d.ts +6 -0
  210. package/dist/schemas/primitives.js +11 -0
  211. package/dist/schemas/primitives.js.map +1 -0
  212. package/dist/schemas/public-input.d.ts +3 -0
  213. package/dist/schemas/public-input.js +524 -0
  214. package/dist/schemas/public-input.js.map +1 -0
  215. package/dist/tools/core-edit/idempotent-write.d.ts +23 -0
  216. package/dist/tools/core-edit/idempotent-write.js +58 -0
  217. package/dist/tools/core-edit/idempotent-write.js.map +1 -0
  218. package/dist/tools/core-edit/save-asset.d.ts +5 -0
  219. package/dist/tools/core-edit/save-asset.js +334 -0
  220. package/dist/tools/core-edit/save-asset.js.map +1 -0
  221. package/dist/tools/core-edit/save-business-document-draft.d.ts +2 -0
  222. package/dist/tools/core-edit/save-business-document-draft.js +128 -0
  223. package/dist/tools/core-edit/save-business-document-draft.js.map +1 -0
  224. package/dist/tools/core-edit/save-fund-account.d.ts +2 -0
  225. package/dist/tools/core-edit/save-fund-account.js +138 -0
  226. package/dist/tools/core-edit/save-fund-account.js.map +1 -0
  227. package/dist/tools/core-edit/save-journal-draft.d.ts +2 -0
  228. package/dist/tools/core-edit/save-journal-draft.js +122 -0
  229. package/dist/tools/core-edit/save-journal-draft.js.map +1 -0
  230. package/dist/tools/core-edit/save-master-data.d.ts +2 -0
  231. package/dist/tools/core-edit/save-master-data.js +153 -0
  232. package/dist/tools/core-edit/save-master-data.js.map +1 -0
  233. package/dist/tools/core-edit/save-transaction-draft.d.ts +2 -0
  234. package/dist/tools/core-edit/save-transaction-draft.js +128 -0
  235. package/dist/tools/core-edit/save-transaction-draft.js.map +1 -0
  236. package/dist/tools/core-read/export-business-documents.d.ts +2 -0
  237. package/dist/tools/core-read/export-business-documents.js +67 -0
  238. package/dist/tools/core-read/export-business-documents.js.map +1 -0
  239. package/dist/tools/core-read/export-journals.d.ts +2 -0
  240. package/dist/tools/core-read/export-journals.js +56 -0
  241. package/dist/tools/core-read/export-journals.js.map +1 -0
  242. package/dist/tools/core-read/export-transactions.d.ts +2 -0
  243. package/dist/tools/core-read/export-transactions.js +67 -0
  244. package/dist/tools/core-read/export-transactions.js.map +1 -0
  245. package/dist/tools/core-read/query-accounting-balances.d.ts +2 -0
  246. package/dist/tools/core-read/query-accounting-balances.js +135 -0
  247. package/dist/tools/core-read/query-accounting-balances.js.map +1 -0
  248. package/dist/tools/core-read/query-accounting-context.d.ts +2 -0
  249. package/dist/tools/core-read/query-accounting-context.js +76 -0
  250. package/dist/tools/core-read/query-accounting-context.js.map +1 -0
  251. package/dist/tools/core-read/query-assets.d.ts +2 -0
  252. package/dist/tools/core-read/query-assets.js +425 -0
  253. package/dist/tools/core-read/query-assets.js.map +1 -0
  254. package/dist/tools/core-read/query-business-documents.d.ts +9 -0
  255. package/dist/tools/core-read/query-business-documents.js +620 -0
  256. package/dist/tools/core-read/query-business-documents.js.map +1 -0
  257. package/dist/tools/core-read/query-dashboard.d.ts +2 -0
  258. package/dist/tools/core-read/query-dashboard.js +144 -0
  259. package/dist/tools/core-read/query-dashboard.js.map +1 -0
  260. package/dist/tools/core-read/query-financial-reports.d.ts +2 -0
  261. package/dist/tools/core-read/query-financial-reports.js +171 -0
  262. package/dist/tools/core-read/query-financial-reports.js.map +1 -0
  263. package/dist/tools/core-read/query-fund-accounts.d.ts +2 -0
  264. package/dist/tools/core-read/query-fund-accounts.js +140 -0
  265. package/dist/tools/core-read/query-fund-accounts.js.map +1 -0
  266. package/dist/tools/core-read/query-fund-balances.d.ts +2 -0
  267. package/dist/tools/core-read/query-fund-balances.js +150 -0
  268. package/dist/tools/core-read/query-fund-balances.js.map +1 -0
  269. package/dist/tools/core-read/query-journals.d.ts +2 -0
  270. package/dist/tools/core-read/query-journals.js +277 -0
  271. package/dist/tools/core-read/query-journals.js.map +1 -0
  272. package/dist/tools/core-read/query-master-data.d.ts +2 -0
  273. package/dist/tools/core-read/query-master-data.js +363 -0
  274. package/dist/tools/core-read/query-master-data.js.map +1 -0
  275. package/dist/tools/core-read/query-pnl.d.ts +2 -0
  276. package/dist/tools/core-read/query-pnl.js +244 -0
  277. package/dist/tools/core-read/query-pnl.js.map +1 -0
  278. package/dist/tools/core-read/query-reference-data.d.ts +2 -0
  279. package/dist/tools/core-read/query-reference-data.js +293 -0
  280. package/dist/tools/core-read/query-reference-data.js.map +1 -0
  281. package/dist/tools/core-read/query-transactions.d.ts +2 -0
  282. package/dist/tools/core-read/query-transactions.js +58 -0
  283. package/dist/tools/core-read/query-transactions.js.map +1 -0
  284. package/dist/tools/create-tools.d.ts +3 -0
  285. package/dist/tools/create-tools.js +88 -0
  286. package/dist/tools/create-tools.js.map +1 -0
  287. package/dist/tools/extended/asset-operation-tools.d.ts +9 -0
  288. package/dist/tools/extended/asset-operation-tools.js +419 -0
  289. package/dist/tools/extended/asset-operation-tools.js.map +1 -0
  290. package/dist/tools/extended/automation-tools.d.ts +7 -0
  291. package/dist/tools/extended/automation-tools.js +333 -0
  292. package/dist/tools/extended/automation-tools.js.map +1 -0
  293. package/dist/tools/extended/configuration-tools.d.ts +14 -0
  294. package/dist/tools/extended/configuration-tools.js +871 -0
  295. package/dist/tools/extended/configuration-tools.js.map +1 -0
  296. package/dist/tools/extended/period-end-tools.d.ts +11 -0
  297. package/dist/tools/extended/period-end-tools.js +480 -0
  298. package/dist/tools/extended/period-end-tools.js.map +1 -0
  299. package/dist/tools/extended/query-output.d.ts +2589 -0
  300. package/dist/tools/extended/query-output.js +610 -0
  301. package/dist/tools/extended/query-output.js.map +1 -0
  302. package/dist/tools/extended/tool-support.d.ts +56 -0
  303. package/dist/tools/extended/tool-support.js +198 -0
  304. package/dist/tools/extended/tool-support.js.map +1 -0
  305. package/dist/tools/extended/workflow-tools.d.ts +10 -0
  306. package/dist/tools/extended/workflow-tools.js +678 -0
  307. package/dist/tools/extended/workflow-tools.js.map +1 -0
  308. package/dist/tools/fnd-import/execute-import.d.ts +2 -0
  309. package/dist/tools/fnd-import/execute-import.js +201 -0
  310. package/dist/tools/fnd-import/execute-import.js.map +1 -0
  311. package/dist/tools/fnd-import/get-import-template.d.ts +2 -0
  312. package/dist/tools/fnd-import/get-import-template.js +66 -0
  313. package/dist/tools/fnd-import/get-import-template.js.map +1 -0
  314. package/dist/tools/fnd-import/get-job-status.d.ts +8 -0
  315. package/dist/tools/fnd-import/get-job-status.js +201 -0
  316. package/dist/tools/fnd-import/get-job-status.js.map +1 -0
  317. package/dist/tools/fnd-import/prepare-import.d.ts +31 -0
  318. package/dist/tools/fnd-import/prepare-import.js +214 -0
  319. package/dist/tools/fnd-import/prepare-import.js.map +1 -0
  320. package/dist/tools/fnd-import/public-import-result.d.ts +18 -0
  321. package/dist/tools/fnd-import/public-import-result.js +35 -0
  322. package/dist/tools/fnd-import/public-import-result.js.map +1 -0
  323. package/dist/tools/tool-definition.d.ts +45 -0
  324. package/dist/tools/tool-definition.js +11 -0
  325. package/dist/tools/tool-definition.js.map +1 -0
  326. package/dist/tools/tool-handler.d.ts +27 -0
  327. package/dist/tools/tool-handler.js +196 -0
  328. package/dist/tools/tool-handler.js.map +1 -0
  329. package/dist/tools/transaction-item.d.ts +225 -0
  330. package/dist/tools/transaction-item.js +109 -0
  331. package/dist/tools/transaction-item.js.map +1 -0
  332. package/dist/transport/draining-transport.d.ts +14 -0
  333. package/dist/transport/draining-transport.js +36 -0
  334. package/dist/transport/draining-transport.js.map +1 -0
  335. package/dist/transport/stdio.d.ts +2 -0
  336. package/dist/transport/stdio.js +5 -0
  337. package/dist/transport/stdio.js.map +1 -0
  338. package/dist/version.d.ts +2 -0
  339. package/dist/version.js +3 -0
  340. package/dist/version.js.map +1 -0
  341. package/package.json +49 -0
@@ -0,0 +1,333 @@
1
+ import { FinTaxError } from '../../errors/fintax-error.js';
2
+ import { sourceTypesUpstreamSchema } from '../../capabilities/definitions/extended-operation-contracts.js';
3
+ import { createAutoFlowJobId } from '../../policies/job-reference.js';
4
+ import { hashOperationValue } from '../../policies/operation-plan.js';
5
+ import { executePlannedInputSchema, operationPlanOutputSchema, prepareAccountingEventCollectionInputSchema, prepareAccountingFlowRunInputSchema, queryAccountingEventsInputSchema, } from '../../schemas/domains/extended-operations.js';
6
+ import { operationResultSchemas } from '../../schemas/domains/extended-operation-results.js';
7
+ import { queryAccountingEventsOutputSchema } from '../../schemas/domains/extended-query-results.js';
8
+ import { createPublicInputSchema } from '../../schemas/public-input.js';
9
+ import { asRecord, executePlannedOperation, issueOperationPlan, planSummary, querySummary, requiredUpstreamArray, resultSummary, } from './tool-support.js';
10
+ import { accountingEventsQueryOutput } from './query-output.js';
11
+ const readAnnotations = {
12
+ readOnlyHint: true,
13
+ destructiveHint: false,
14
+ idempotentHint: true,
15
+ openWorldHint: false,
16
+ };
17
+ const writeAnnotations = {
18
+ readOnlyHint: false,
19
+ destructiveHint: false,
20
+ idempotentHint: false,
21
+ openWorldHint: false,
22
+ };
23
+ function sourceTypes(raw) {
24
+ return sourceTypesUpstreamSchema.parse(raw).source_types;
25
+ }
26
+ function eventCollectionSnapshot(sourceType, hasEnabledChain, sourceIds) {
27
+ return {
28
+ source_type: sourceType,
29
+ has_enabled_chain: hasEnabledChain,
30
+ source_ids: [...sourceIds],
31
+ };
32
+ }
33
+ function accountingFlowSnapshot(raw) {
34
+ const value = asRecord(raw);
35
+ const flow = asRecord(value.flow);
36
+ const steps = requiredUpstreamArray(value.steps).map(asRecord);
37
+ const loops = requiredUpstreamArray(value.loops).map(asRecord);
38
+ return {
39
+ flow: {
40
+ id: flow.id,
41
+ org_id: flow.org_id,
42
+ current_step: flow.current_step,
43
+ loop_status: flow.loop_status,
44
+ loop_count: flow.loop_count,
45
+ event_collect_mode: flow.event_collect_mode,
46
+ fifo_mode: flow.fifo_mode,
47
+ },
48
+ loop_seq: value.loop_seq,
49
+ steps: steps.map((step) => ({
50
+ id: step.id,
51
+ loop_seq: step.loop_seq,
52
+ step_code: step.step_code,
53
+ step_order: step.step_order,
54
+ status: step.status,
55
+ input_count: step.input_count,
56
+ output_count: step.output_count,
57
+ error_count: step.error_count,
58
+ })),
59
+ loops: loops.map((loop) => ({
60
+ loop_seq: loop.loop_seq,
61
+ loop_status: loop.loop_status,
62
+ loop_end_time: loop.loop_end_time ?? null,
63
+ })),
64
+ };
65
+ }
66
+ function eventCollectionResult(value) {
67
+ const record = asRecord(value);
68
+ const result = asRecord(record.result);
69
+ const failed = requiredUpstreamArray(record.failed);
70
+ const degraded = requiredUpstreamArray(record.degraded);
71
+ return {
72
+ result: {
73
+ input_tx_count: result.input_tx_count,
74
+ output_event_count: result.output_event_count,
75
+ },
76
+ success_count: record.success_count,
77
+ failed_count: record.failed_count,
78
+ deleted_event_count: record.deleted_event_count,
79
+ failed: failed.map((item) => ({ source_id: asRecord(item).source_id })),
80
+ degraded: degraded.map((item) => ({
81
+ source_id: asRecord(item).source_id,
82
+ })),
83
+ };
84
+ }
85
+ function accountingFlowResult(value) {
86
+ const record = asRecord(value);
87
+ return {
88
+ flow_id: record.flow_id,
89
+ loop_seq: record.loop_seq,
90
+ loop_status: record.loop_status,
91
+ current_step: record.current_step,
92
+ fifo_covered_until: record.fifo_covered_until ?? null,
93
+ };
94
+ }
95
+ export const queryAccountingEventsTool = {
96
+ name: 'query_accounting_events',
97
+ title: 'Query Accounting Events',
98
+ description: 'Query accounting-event lists, source lines for a specified event, or conflict-check results for a period range. This Tool is read-only and does not trigger collection, automatic posting, or workflow execution. List periods use YYYY-MM.',
99
+ risk: 'R0',
100
+ exposurePack: 'automation',
101
+ capabilityIds: [
102
+ 'suite.rul.events.list',
103
+ 'suite.rul.events.lines',
104
+ 'suite.rul.events.check',
105
+ ],
106
+ fileAccess: 'none',
107
+ publicInputSchema: createPublicInputSchema(queryAccountingEventsInputSchema),
108
+ inputSchema: queryAccountingEventsInputSchema,
109
+ outputSchema: queryAccountingEventsOutputSchema,
110
+ annotations: readAnnotations,
111
+ async execute(rawInput, context) {
112
+ const input = queryAccountingEventsInputSchema.parse(rawInput);
113
+ if (input.view === 'lines') {
114
+ const raw = await context.callCapability('suite.rul.events.lines', { event_id: input.event_id }, input.context.org_id);
115
+ return accountingEventsQueryOutput({
116
+ view: input.view,
117
+ raw,
118
+ context,
119
+ capabilityId: 'suite.rul.events.lines',
120
+ });
121
+ }
122
+ if (input.view === 'check') {
123
+ const raw = await context.callCapability('suite.rul.events.check', {
124
+ query: {
125
+ ledger_id: input.ledger_id,
126
+ org_id: input.context.org_id,
127
+ period_from: input.period_from,
128
+ period_to: input.period_to,
129
+ },
130
+ }, input.context.org_id);
131
+ return accountingEventsQueryOutput({
132
+ view: input.view,
133
+ raw,
134
+ context,
135
+ capabilityId: 'suite.rul.events.check',
136
+ });
137
+ }
138
+ const raw = await context.callCapability('suite.rul.events.list', {
139
+ query: {
140
+ ledger_id: input.filters.ledger_id,
141
+ period_from: input.filters.period_from,
142
+ period_to: input.filters.period_to,
143
+ event_type: input.filters.event_type,
144
+ search: input.filters.keyword,
145
+ page: input.page,
146
+ page_size: input.page_size,
147
+ },
148
+ }, input.context.org_id);
149
+ return accountingEventsQueryOutput({
150
+ view: input.view,
151
+ raw,
152
+ context,
153
+ capabilityId: 'suite.rul.events.list',
154
+ });
155
+ },
156
+ summarize: querySummary,
157
+ };
158
+ export const prepareAccountingEventCollectionTool = {
159
+ name: 'prepare_accounting_event_collection',
160
+ title: 'Prepare Accounting Event Collection',
161
+ description: 'Verify that the source type is registered and enabled, then bind 1 to 1000 explicit source IDs and an optional strategy scope into a single-use collection plan without creating events. There is no per-ID dry run; the summary represents only the confirmed call scope.',
162
+ risk: 'R0',
163
+ exposurePack: 'automation',
164
+ capabilityIds: ['suite.rul.events.source_types'],
165
+ fileAccess: 'none',
166
+ inputSchema: prepareAccountingEventCollectionInputSchema,
167
+ outputSchema: operationPlanOutputSchema,
168
+ annotations: readAnnotations,
169
+ async execute(rawInput, context) {
170
+ const input = prepareAccountingEventCollectionInputSchema.parse(rawInput);
171
+ const preflight = await context.callCapability('suite.rul.events.source_types', {}, input.context.org_id);
172
+ const selected = sourceTypes(preflight).find((item) => item.source_type === input.source_type);
173
+ if (selected === undefined) {
174
+ throw new FinTaxError('VALIDATION_FAILED', 'The source type is not registered and cannot be collected into accounting events');
175
+ }
176
+ if (selected.has_enabled_chain !== true) {
177
+ throw new FinTaxError('CONFLICT', 'The source type has no enabled strategy chain and cannot be collected into accounting events');
178
+ }
179
+ return issueOperationPlan({
180
+ context,
181
+ executeTool: 'execute_accounting_event_collection',
182
+ targetType: 'accounting_event_collection',
183
+ targetIds: input.source_ids,
184
+ targetVersions: [],
185
+ orgId: input.context.org_id,
186
+ parameters: input,
187
+ preview: eventCollectionSnapshot(selected.source_type, selected.has_enabled_chain, input.source_ids),
188
+ operation: 'rul.events.sourceTypes',
189
+ privatePayload: {
190
+ body: {
191
+ org_id: input.context.org_id,
192
+ source_type: input.source_type,
193
+ source_ids: input.source_ids,
194
+ strategy_keys: input.strategy_keys,
195
+ },
196
+ },
197
+ });
198
+ },
199
+ summarize: planSummary,
200
+ };
201
+ export const executeAccountingEventCollectionTool = {
202
+ name: 'execute_accounting_event_collection',
203
+ title: 'Execute Accounting Event Collection',
204
+ description: 'Consume a user-confirmed plan issued by prepare_accounting_event_collection and create or rebuild accounting events for explicit source IDs. Returns per-batch result summaries and does not start full-period collection.',
205
+ risk: 'R2',
206
+ exposurePack: 'automation',
207
+ capabilityIds: [
208
+ 'suite.rul.events.source_types',
209
+ 'suite.rul.events.collect_by_ids',
210
+ ],
211
+ fileAccess: 'none',
212
+ inputSchema: executePlannedInputSchema,
213
+ outputSchema: operationResultSchemas.execute_accounting_event_collection,
214
+ annotations: writeAnnotations,
215
+ async execute(rawInput, context) {
216
+ const input = executePlannedInputSchema.parse(rawInput);
217
+ return executePlannedOperation({
218
+ toolName: 'execute_accounting_event_collection',
219
+ operationPlanId: input.operation_plan_id,
220
+ confirmationToken: input.confirmation_token,
221
+ idempotencyKey: input.idempotency_key,
222
+ orgId: input.context.org_id,
223
+ capabilityId: 'suite.rul.events.collect_by_ids',
224
+ context,
225
+ sourceOperation: 'rul.events.collectByIds',
226
+ targetType: 'accounting_event_collection',
227
+ outputSchema: operationResultSchemas.execute_accounting_event_collection,
228
+ projectResult: eventCollectionResult,
229
+ validatePlan: async (binding) => {
230
+ const body = asRecord(binding.payload?.body);
231
+ const sourceType = body.source_type;
232
+ const sourceIds = body.source_ids;
233
+ if (typeof sourceType !== 'string' ||
234
+ !Array.isArray(sourceIds) ||
235
+ !sourceIds.every((sourceId) => typeof sourceId === 'string')) {
236
+ throw new FinTaxError('CONFIRMATION_REQUIRED', 'The event-collection plan is incomplete; run the preparation step again');
237
+ }
238
+ const preflight = await context.callCapability('suite.rul.events.source_types', {}, input.context.org_id);
239
+ const selected = sourceTypes(preflight).find((item) => item.source_type === sourceType);
240
+ if (selected === undefined ||
241
+ selected.has_enabled_chain !== true ||
242
+ hashOperationValue(eventCollectionSnapshot(selected.source_type, selected.has_enabled_chain, sourceIds)) !== binding.preview_hash) {
243
+ throw new FinTaxError('CONFIRMATION_REQUIRED', 'The event source type or strategy chain changed; run the preparation step again');
244
+ }
245
+ },
246
+ buildCapabilityInput: (binding) => binding.payload ?? {},
247
+ });
248
+ },
249
+ summarize: resultSummary,
250
+ };
251
+ export const prepareAccountingFlowRunTool = {
252
+ name: 'prepare_accounting_flow_run',
253
+ title: 'Prepare Accounting Flow Run',
254
+ description: 'Read the current steps, loop state, and recent run log for an explicit flow_id and create a single-use run plan without executing the flow. Call execute_accounting_flow only after confirming the complete state snapshot.',
255
+ risk: 'R0',
256
+ exposurePack: 'automation',
257
+ capabilityIds: ['suite.rul.auto_flow.detail'],
258
+ fileAccess: 'none',
259
+ inputSchema: prepareAccountingFlowRunInputSchema,
260
+ outputSchema: operationPlanOutputSchema,
261
+ annotations: readAnnotations,
262
+ async execute(rawInput, context) {
263
+ const input = prepareAccountingFlowRunInputSchema.parse(rawInput);
264
+ const rawSnapshot = await context.callCapability('suite.rul.auto_flow.detail', { flow_id: input.flow_id }, input.context.org_id);
265
+ const snapshot = accountingFlowSnapshot(rawSnapshot);
266
+ return issueOperationPlan({
267
+ context,
268
+ executeTool: 'execute_accounting_flow',
269
+ targetType: 'accounting_flow',
270
+ targetIds: [input.flow_id],
271
+ targetVersions: [],
272
+ orgId: input.context.org_id,
273
+ parameters: input,
274
+ preview: snapshot,
275
+ operation: 'rul.auto_flow.detail',
276
+ privatePayload: { flow_id: input.flow_id },
277
+ });
278
+ },
279
+ summarize: planSummary,
280
+ };
281
+ export const executeAccountingFlowTool = {
282
+ name: 'execute_accounting_flow',
283
+ title: 'Execute Accounting Flow',
284
+ description: 'Consume a user-confirmed plan issued by prepare_accounting_flow_run and run only its bound flow_id. The state snapshot is checked for changes before execution. A successful call returns a job reference that can be queried with get_job_status.',
285
+ risk: 'R3',
286
+ exposurePack: 'automation',
287
+ capabilityIds: ['suite.rul.auto_flow.detail', 'suite.rul.auto_flow.run'],
288
+ fileAccess: 'none',
289
+ inputSchema: executePlannedInputSchema,
290
+ outputSchema: operationResultSchemas.execute_accounting_flow,
291
+ annotations: writeAnnotations,
292
+ async execute(rawInput, context) {
293
+ const input = executePlannedInputSchema.parse(rawInput);
294
+ const binding = context.operationPlans.inspect(input.operation_plan_id, input.confirmation_token, 'execute_accounting_flow');
295
+ return context.withResourceLock(`accounting-flow:${binding.subject_id}`, () => executePlannedOperation({
296
+ toolName: 'execute_accounting_flow',
297
+ operationPlanId: input.operation_plan_id,
298
+ confirmationToken: input.confirmation_token,
299
+ idempotencyKey: input.idempotency_key,
300
+ orgId: input.context.org_id,
301
+ capabilityId: 'suite.rul.auto_flow.run',
302
+ context,
303
+ sourceOperation: 'rul.auto_flow.runLoop',
304
+ targetType: 'accounting_flow',
305
+ outputSchema: operationResultSchemas.execute_accounting_flow,
306
+ projectResult: accountingFlowResult,
307
+ validatePlan: async (plan) => {
308
+ const current = await context.callCapability('suite.rul.auto_flow.detail', { flow_id: plan.payload?.flow_id }, input.context.org_id);
309
+ if (hashOperationValue(accountingFlowSnapshot(current)) !==
310
+ plan.preview_hash) {
311
+ throw new FinTaxError('CONFIRMATION_REQUIRED', 'The accounting-flow state changed; run the preparation step again');
312
+ }
313
+ },
314
+ buildCapabilityInput: (plan) => ({ flow_id: plan.payload?.flow_id }),
315
+ buildJobId: (raw, plan) => {
316
+ const loopSeq = asRecord(raw).loop_seq;
317
+ if (typeof loopSeq !== 'number' || !Number.isInteger(loopSeq)) {
318
+ throw new FinTaxError('UPSTREAM_UNAVAILABLE', 'FinTax did not return a valid accounting-flow job sequence, so the run state cannot be confirmed');
319
+ }
320
+ return createAutoFlowJobId(plan.subject_id, loopSeq);
321
+ },
322
+ }));
323
+ },
324
+ summarize: resultSummary,
325
+ };
326
+ export const automationTools = [
327
+ queryAccountingEventsTool,
328
+ prepareAccountingEventCollectionTool,
329
+ executeAccountingEventCollectionTool,
330
+ prepareAccountingFlowRunTool,
331
+ executeAccountingFlowTool,
332
+ ];
333
+ //# sourceMappingURL=automation-tools.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"automation-tools.js","sourceRoot":"","sources":["../../../src/tools/extended/automation-tools.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,yBAAyB,EAAE,MAAM,gEAAgE,CAAC;AAC3G,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AACtE,OAAO,EACL,yBAAyB,EACzB,yBAAyB,EACzB,2CAA2C,EAC3C,mCAAmC,EACnC,gCAAgC,GACjC,MAAM,8CAA8C,CAAC;AACtD,OAAO,EAAE,sBAAsB,EAAE,MAAM,qDAAqD,CAAC;AAC7F,OAAO,EAAE,iCAAiC,EAAE,MAAM,iDAAiD,CAAC;AACpG,OAAO,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AAExE,OAAO,EACL,QAAQ,EACR,uBAAuB,EACvB,kBAAkB,EAClB,WAAW,EACX,YAAY,EACZ,qBAAqB,EACrB,aAAa,GACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAC;AAEhE,MAAM,eAAe,GAAG;IACtB,YAAY,EAAE,IAAI;IAClB,eAAe,EAAE,KAAK;IACtB,cAAc,EAAE,IAAI;IACpB,aAAa,EAAE,KAAK;CACZ,CAAC;AAEX,MAAM,gBAAgB,GAAG;IACvB,YAAY,EAAE,KAAK;IACnB,eAAe,EAAE,KAAK;IACtB,cAAc,EAAE,KAAK;IACrB,aAAa,EAAE,KAAK;CACZ,CAAC;AAEX,SAAS,WAAW,CAAC,GAAY;IAC/B,OAAO,yBAAyB,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,YAAY,CAAC;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AE;gBACxB,MAAM,OAAO,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC;gBACvC,IAAI,OAAO,OAAO,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;oBAC9D,MAAM,IAAI,WAAW,CACnB,sBAAsB,EACtB,kGAAkG,CACnG,CAAC;gBACJ,CAAC;gBACD,OAAO,mBAAmB,CAAC,IAAI,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;YACvD,CAAC;SACF,CAAC,CACL,CAAC;IACJ,CAAC;IACD,SAAS,EAAE,aAAa;CACzB,CAAC;AAEF,MAAM,CAAC,MAAM,eAAe,GAA8B;IACxD,yBAAyB;IACzB,oCAAoC;IACpC,oCAAoC;IACpC,4BAA4B;IAC5B,yBAAyB;CAC1B,CAAC"}
@@ -0,0 +1,14 @@
1
+ import type { ToolDefinition } from '../tool-definition.js';
2
+ export declare const queryMappingConfigTool: ToolDefinition;
3
+ export declare const saveMappingConfigTool: ToolDefinition;
4
+ export declare const queryAccountingRulesTool: ToolDefinition;
5
+ export declare const saveAccountingRuleTool: ToolDefinition;
6
+ export declare const queryAllocationTool: ToolDefinition;
7
+ export declare const saveAllocationConfigTool: ToolDefinition;
8
+ export declare const previewAllocationTool: ToolDefinition;
9
+ export declare const executeAllocationTool: ToolDefinition;
10
+ export declare const savePnlConfigTool: ToolDefinition;
11
+ export declare const runPnlCalculationTool: ToolDefinition;
12
+ export declare const saveGeneratorConfigTool: ToolDefinition;
13
+ export declare const runGeneratorTool: ToolDefinition;
14
+ export declare const configurationTools: readonly ToolDefinition[];