deepline 0.3.551 → 0.3.553

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 (324) hide show
  1. package/dist/bundling-sources/sdk/src/client-core.ts +130 -12
  2. package/dist/bundling-sources/sdk/src/compat.ts +239 -87
  3. package/dist/bundling-sources/sdk/src/config.ts +113 -2
  4. package/dist/bundling-sources/sdk/src/errors.ts +2 -0
  5. package/dist/bundling-sources/sdk/src/http-core.ts +124 -10
  6. package/dist/bundling-sources/sdk/src/index.ts +2 -0
  7. package/dist/bundling-sources/sdk/src/integrations.ts +6 -4
  8. package/dist/bundling-sources/sdk/src/play.ts +3 -0
  9. package/dist/bundling-sources/sdk/src/plays/run-request.ts +1 -1
  10. package/dist/bundling-sources/sdk/src/release.ts +1 -1
  11. package/dist/bundling-sources/sdk/src/runs/watch-polling.ts +66 -30
  12. package/dist/bundling-sources/sdk/src/tool-calls.ts +2 -1
  13. package/dist/bundling-sources/sdk/src/tool-failure-hint.ts +104 -0
  14. package/dist/bundling-sources/sdk/src/types.ts +9 -1
  15. package/dist/bundling-sources/shared_libs/integration-contracts/billing-entitlements.ts +4 -2
  16. package/dist/bundling-sources/shared_libs/integration-contracts/billing-plan-skus.ts +25 -0
  17. package/dist/bundling-sources/shared_libs/monitors/action-actor.ts +2 -0
  18. package/dist/bundling-sources/shared_libs/monitors/billing/credit-recovery.ts +58 -4
  19. package/dist/bundling-sources/shared_libs/monitors/billing/policy-builders.ts +8 -0
  20. package/dist/bundling-sources/shared_libs/monitors/billing/pricing.ts +11 -0
  21. package/dist/bundling-sources/shared_libs/monitors/billing/types.ts +13 -0
  22. package/dist/bundling-sources/shared_libs/monitors/deactivation-reasons.ts +103 -5
  23. package/dist/bundling-sources/shared_libs/monitors/fleets/converge-admission.ts +133 -0
  24. package/dist/bundling-sources/shared_libs/monitors/fleets/fence-attention.ts +165 -0
  25. package/dist/bundling-sources/shared_libs/monitors/fleets/fence-release.ts +726 -0
  26. package/dist/bundling-sources/shared_libs/monitors/fleets/fence-walk.ts +274 -0
  27. package/dist/bundling-sources/shared_libs/monitors/fleets/issues.ts +1 -0
  28. package/dist/bundling-sources/shared_libs/monitors/fleets/limits.ts +28 -0
  29. package/dist/bundling-sources/shared_libs/monitors/fleets/provider-bulk-wait.ts +126 -0
  30. package/dist/bundling-sources/shared_libs/monitors/fleets/shared-payload.ts +189 -0
  31. package/dist/bundling-sources/shared_libs/monitors/http-error-response.ts +28 -0
  32. package/dist/bundling-sources/shared_libs/monitors/inbound-publish-key.ts +4 -0
  33. package/dist/bundling-sources/shared_libs/monitors/inventory-counter-errors.ts +25 -0
  34. package/dist/bundling-sources/shared_libs/monitors/org-monitor-limits.ts +65 -0
  35. package/dist/bundling-sources/shared_libs/monitors/package.json +11 -0
  36. package/dist/bundling-sources/shared_libs/monitors/provider-callback-verification.ts +152 -1
  37. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-batch-operation.ts +6 -0
  38. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-capability.ts +390 -10
  39. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-errors.ts +34 -0
  40. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-identity-claims.ts +66 -30
  41. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-state.ts +30 -0
  42. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-upstream-identity.ts +80 -13
  43. package/dist/bundling-sources/shared_libs/monitors/provider-resource-failure.ts +26 -3
  44. package/dist/bundling-sources/shared_libs/monitors/signal-radars/inbound-dead-letter.ts +41 -13
  45. package/dist/bundling-sources/shared_libs/monitors/signal-radars/raw-receipt-causes.ts +219 -0
  46. package/dist/bundling-sources/shared_libs/monitors/snitcher-ip2company.ts +21 -10
  47. package/dist/bundling-sources/shared_libs/monitors/starter-templates.ts +13 -0
  48. package/dist/bundling-sources/shared_libs/monitors/tamradar-countries.ts +285 -0
  49. package/dist/bundling-sources/shared_libs/monitors/tracking-provider-guidance.ts +6 -0
  50. package/dist/bundling-sources/shared_libs/monitors/tracking-provider-integrations.ts +13 -0
  51. package/dist/bundling-sources/shared_libs/observability/dlq.ts +1 -1
  52. package/dist/bundling-sources/shared_libs/observability/log-metadata.ts +5 -3
  53. package/dist/bundling-sources/shared_libs/observability/queue-health.ts +10 -1
  54. package/dist/bundling-sources/shared_libs/observability/queue-item-connectors.ts +1 -0
  55. package/dist/bundling-sources/shared_libs/observability/redaction.ts +24 -1
  56. package/dist/bundling-sources/shared_libs/observability/scheduled-jobs.json +312 -41
  57. package/dist/bundling-sources/shared_libs/observability/scheduled-work-manual.ts +1 -2
  58. package/dist/bundling-sources/shared_libs/play-data-plane/preview-r2-oidc.ts +188 -0
  59. package/dist/bundling-sources/shared_libs/play-data-plane/r2.ts +170 -16
  60. package/dist/bundling-sources/shared_libs/play-data-plane/runtime-sheet-storage-contract.ts +5 -0
  61. package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +68 -2
  62. package/dist/bundling-sources/shared_libs/play-runtime/context.ts +568 -26
  63. package/dist/bundling-sources/shared_libs/play-runtime/ctx-fetch-caller-deadline.ts +200 -0
  64. package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +6 -0
  65. package/dist/bundling-sources/shared_libs/play-runtime/deployment/runtime-topology.ts +21 -1
  66. package/dist/bundling-sources/shared_libs/play-runtime/durable-call-cache.ts +3 -2
  67. package/dist/bundling-sources/shared_libs/play-runtime/durable-runs-rollout.ts +14 -2
  68. package/dist/bundling-sources/shared_libs/play-runtime/durable-summary-events.ts +70 -2
  69. package/dist/bundling-sources/shared_libs/play-runtime/durable-tool-identity.ts +3 -3
  70. package/dist/bundling-sources/shared_libs/play-runtime/execution-capabilities.ts +16 -0
  71. package/dist/bundling-sources/shared_libs/play-runtime/experiment-switches.ts +92 -16
  72. package/dist/bundling-sources/shared_libs/play-runtime/fixture-behavior.ts +1 -0
  73. package/dist/bundling-sources/shared_libs/play-runtime/governor/policy.ts +7 -1
  74. package/dist/bundling-sources/shared_libs/play-runtime/internal-bootstrap-token.ts +62 -0
  75. package/dist/bundling-sources/shared_libs/play-runtime/map-memory-limits.ts +74 -3
  76. package/dist/bundling-sources/shared_libs/play-runtime/output-size-limits.ts +31 -3
  77. package/dist/bundling-sources/shared_libs/play-runtime/play-http-request.ts +6 -0
  78. package/dist/bundling-sources/shared_libs/play-runtime/protocol.ts +8 -0
  79. package/dist/bundling-sources/shared_libs/play-runtime/query-result-dataset.ts +19 -0
  80. package/dist/bundling-sources/shared_libs/play-runtime/resource-governor.ts +39 -2
  81. package/dist/bundling-sources/shared_libs/play-runtime/run-failure.ts +9 -1
  82. package/dist/bundling-sources/shared_libs/play-runtime/run-identity.ts +33 -0
  83. package/dist/bundling-sources/shared_libs/play-runtime/run-ledger-projection-contract.ts +24 -0
  84. package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +300 -57
  85. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-payload-transport.ts +87 -6
  86. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/modal.ts +241 -10
  87. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/early-sandbox-egress.ts +161 -14
  88. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/early-sandbox.ts +16 -3
  89. package/dist/bundling-sources/shared_libs/play-runtime/runtime-api-compression.ts +37 -0
  90. package/dist/bundling-sources/shared_libs/play-runtime/runtime-api-paths.ts +9 -0
  91. package/dist/bundling-sources/shared_libs/play-runtime/runtime-api.ts +298 -46
  92. package/dist/bundling-sources/shared_libs/play-runtime/runtime-authority.ts +13 -0
  93. package/dist/bundling-sources/shared_libs/play-runtime/runtime-constants.ts +39 -0
  94. package/dist/bundling-sources/shared_libs/play-runtime/runtime-operation-contract.ts +62 -1
  95. package/dist/bundling-sources/shared_libs/play-runtime/runtime-scheduler-topology.ts +36 -0
  96. package/dist/bundling-sources/shared_libs/play-runtime/runtime-sheet-row-transition.ts +36 -0
  97. package/dist/bundling-sources/shared_libs/play-runtime/runtime-speed-profile.ts +206 -2
  98. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-pool.ts +42 -0
  99. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-runtime-worker.ts +185 -64
  100. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-worker-slot-ledger.ts +157 -0
  101. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/early-sandbox-lane.ts +110 -2
  102. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/early-sandbox-listener-hint.ts +323 -0
  103. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/executor-attempt-standing.ts +72 -0
  104. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/integration-operation-value-storage.ts +23 -4
  105. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-rate-state.ts +32 -10
  106. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-workspace-purge.ts +199 -0
  107. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +632 -66
  108. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/run-ledger-outbox-recovery.ts +517 -16
  109. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-api-origin.ts +1 -1
  110. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-receipt-value-storage.ts +9 -0
  111. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-worker-wake.ts +599 -2
  112. package/dist/bundling-sources/shared_libs/play-runtime/secret-resolution-retry-policy.ts +26 -1
  113. package/dist/bundling-sources/shared_libs/play-runtime/startup-read-tool-ids.ts +60 -0
  114. package/dist/bundling-sources/shared_libs/play-runtime/test-runtime-seams.ts +51 -0
  115. package/dist/bundling-sources/shared_libs/play-runtime/tool-call-retry-facts.ts +2 -0
  116. package/dist/bundling-sources/shared_libs/play-runtime/tool-execute-retry-policy.ts +113 -3
  117. package/dist/bundling-sources/shared_libs/play-runtime/tool-http-errors.ts +5 -7
  118. package/dist/bundling-sources/shared_libs/play-runtime/tool-result.ts +37 -7
  119. package/dist/bundling-sources/shared_libs/play-runtime/work-receipt-storage-contract.ts +2 -0
  120. package/dist/bundling-sources/shared_libs/play-runtime/workflow-executor-auth.ts +3 -0
  121. package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +40 -5
  122. package/dist/bundling-sources/shared_libs/plays/deploy/api-client.ts +3 -0
  123. package/dist/bundling-sources/shared_libs/plays/deploy/control-plane-types.ts +16 -0
  124. package/dist/bundling-sources/shared_libs/plays/deploy/run-deployment.ts +10 -41
  125. package/dist/bundling-sources/shared_libs/plays/extension-bridge.ts +33 -0
  126. package/dist/bundling-sources/shared_libs/plays/row-identity.ts +18 -1
  127. package/dist/bundling-sources/shared_libs/plays/tool-execution-error.ts +108 -0
  128. package/dist/bundling-sources/shared_libs/plays/trigger-config-contract.ts +14 -0
  129. package/dist/bundling-sources/shared_libs/product-notifications/catalog.ts +171 -0
  130. package/dist/bundling-sources/shared_libs/product-notifications/events.ts +27 -1
  131. package/dist/bundling-sources/shared_libs/security/email-blacklist.ts +9 -24
  132. package/dist/bundling-sources/shared_libs/security/secret-redaction.ts +178 -5
  133. package/dist/bundling-sources/shared_libs/security/signup-email-dns-screen.ts +148 -0
  134. package/dist/bundling-sources/shared_libs/tool-execution-error.ts +108 -0
  135. package/dist/cli/{auth-E7BH4GMJ.mjs → auth-I3QAU4RV.mjs} +8 -7
  136. package/dist/cli/auth-MQCN7WGZ.js +44 -0
  137. package/dist/cli/{billing-OXKU462W.mjs → billing-3IC54OQQ.mjs} +202 -59
  138. package/dist/cli/{billing-DNQAZGX7.js → billing-YGFFVAIC.js} +302 -159
  139. package/dist/cli/{chunk-COGREZAO.js → chunk-2B5B5KAW.js} +210 -128
  140. package/dist/cli/{chunk-UBKA33KY.mjs → chunk-2MGZAI54.mjs} +17 -0
  141. package/dist/cli/{chunk-T2B5BVZE.js → chunk-3NTP2OSG.js} +13 -13
  142. package/dist/cli/{chunk-FOTGUFVK.mjs → chunk-45OAVGU6.mjs} +5 -5
  143. package/dist/cli/{chunk-54EEYLTF.js → chunk-4747TPLV.js} +3 -3
  144. package/dist/cli/{chunk-CLRAANWH.mjs → chunk-4BFTDNHU.mjs} +1 -1
  145. package/dist/cli/{chunk-BGBJV26E.mjs → chunk-4HYNMXXF.mjs} +4 -4
  146. package/dist/cli/{chunk-5S6PHKRV.mjs → chunk-4SMCFQ23.mjs} +1 -1
  147. package/dist/cli/{chunk-VWLHRZFG.mjs → chunk-55F6HNOY.mjs} +5 -5
  148. package/dist/cli/{chunk-LX35AXTN.mjs → chunk-5TYLSS4Q.mjs} +6 -6
  149. package/dist/cli/{chunk-VTGG2RT3.js → chunk-6NE3RRRY.js} +1 -1
  150. package/dist/cli/{chunk-EITMD3A5.js → chunk-6VLFQZK6.js} +8 -8
  151. package/dist/cli/{chunk-MNSTCJMX.mjs → chunk-72V4PDH5.mjs} +18 -18
  152. package/dist/cli/{chunk-ZCDKE4UH.js → chunk-74RES4DS.js} +5 -5
  153. package/dist/cli/{chunk-WKBHUB6R.js → chunk-7GEMELKI.js} +366 -320
  154. package/dist/cli/{chunk-C4CUZH57.js → chunk-7O6J6A7P.js} +1871 -92
  155. package/dist/cli/{chunk-7RSIFA72.js → chunk-7SERLBNR.js} +161 -53
  156. package/dist/cli/{chunk-3G6QZACZ.js → chunk-7YRJ5UC4.js} +21 -21
  157. package/dist/cli/{chunk-I4VKGNAQ.mjs → chunk-A7DLBE5K.mjs} +136 -54
  158. package/dist/cli/{chunk-GGB3JYCW.mjs → chunk-AGICYWGN.mjs} +299 -69
  159. package/dist/cli/{chunk-44KSACJW.mjs → chunk-AGIQDA2T.mjs} +12 -12
  160. package/dist/cli/{chunk-PACD5DGC.js → chunk-AGLR6QVN.js} +255 -109
  161. package/dist/cli/{chunk-NURW5XH4.mjs → chunk-ASB47RXJ.mjs} +1 -1
  162. package/dist/cli/{chunk-4OMAGJ6U.js → chunk-BVDKFS2T.js} +2 -2
  163. package/dist/cli/{chunk-LPJPCGT3.js → chunk-CACFJODG.js} +190 -134
  164. package/dist/cli/{chunk-GVYLCCKN.mjs → chunk-CAEBJOYU.mjs} +1 -1
  165. package/dist/cli/{chunk-XDVT3GOM.js → chunk-CFJFUVX2.js} +18 -1
  166. package/dist/cli/{chunk-POLUE7D5.js → chunk-DP2VH7CO.js} +12 -12
  167. package/dist/cli/{chunk-D6M5HFBB.mjs → chunk-DP64MD6U.mjs} +1 -1
  168. package/dist/cli/{chunk-W425ERWN.mjs → chunk-DZA7RFGL.mjs} +5 -5
  169. package/dist/cli/{chunk-R7J7CJPZ.js → chunk-E2G2DNAB.js} +4 -1
  170. package/dist/cli/{chunk-GGGAEVCX.mjs → chunk-E7WZOX2A.mjs} +22 -18
  171. package/dist/cli/{chunk-44I675YK.js → chunk-FM7LPUPA.js} +41 -41
  172. package/dist/cli/{chunk-2UXDHFSF.mjs → chunk-GAVZ4EOD.mjs} +1 -1
  173. package/dist/cli/{chunk-Z2FIOG3V.js → chunk-HEBO3XNZ.js} +27 -31
  174. package/dist/cli/{chunk-6PWJKMFQ.mjs → chunk-HSJ6X2AQ.mjs} +4 -4
  175. package/dist/cli/{chunk-UPMRIVZB.js → chunk-HVI55MTK.js} +61 -10
  176. package/dist/cli/{chunk-KWSH5T7K.js → chunk-IH6GDNKW.js} +21 -21
  177. package/dist/cli/{chunk-3KYBDAR3.js → chunk-IMX7J4DU.js} +8 -8
  178. package/dist/cli/{chunk-HEHVGEZV.mjs → chunk-INEMTYMT.mjs} +8 -8
  179. package/dist/cli/{chunk-5VVSEU67.js → chunk-IUOGII7D.js} +6 -7
  180. package/dist/cli/{chunk-MXGA6JFI.mjs → chunk-JJGWHITQ.mjs} +5 -5
  181. package/dist/cli/{chunk-QM6Y6S4E.js → chunk-JLGP5XAJ.js} +5 -5
  182. package/dist/cli/{chunk-V6SCP4B7.mjs → chunk-LFOERUQY.mjs} +69 -3
  183. package/dist/cli/{chunk-BBTKAASQ.js → chunk-LFQJW4S2.js} +42 -1
  184. package/dist/cli/{chunk-ZMNGZ6XS.mjs → chunk-LH5PZKER.mjs} +80 -24
  185. package/dist/cli/{chunk-MR5LTVHD.js → chunk-LRDHPOZW.js} +69 -69
  186. package/dist/cli/{chunk-5LUF4LAR.mjs → chunk-LRZGS6RZ.mjs} +3 -0
  187. package/dist/cli/{chunk-SL6MYJYM.js → chunk-MJTVX4QK.js} +35 -35
  188. package/dist/cli/{chunk-UDXULACQ.js → chunk-MLABYI4M.js} +90 -24
  189. package/dist/cli/{chunk-S7IZWGUA.mjs → chunk-NDNHYONK.mjs} +17 -21
  190. package/dist/cli/{chunk-4D3WIZST.mjs → chunk-OTV2UUKW.mjs} +164 -18
  191. package/dist/cli/{chunk-XYE5XPGF.js → chunk-Q6Z6N3A7.js} +18 -18
  192. package/dist/cli/{chunk-7WQNWJQW.mjs → chunk-QG6JIWUL.mjs} +151 -43
  193. package/dist/cli/{chunk-3T65J5RG.mjs → chunk-QI5S5HWB.mjs} +2 -2
  194. package/dist/cli/{chunk-CBV7AKWM.js → chunk-R6DZ6NQ2.js} +5 -5
  195. package/dist/cli/{chunk-PM7MO62Y.mjs → chunk-RMNOZKRI.mjs} +3 -3
  196. package/dist/cli/{chunk-NMWGZD6Y.js → chunk-RTV4RF7N.js} +36 -36
  197. package/dist/cli/{chunk-CQ6JYQSW.js → chunk-SBH4CKPN.js} +11 -11
  198. package/dist/cli/{chunk-BIIJATTX.mjs → chunk-SG3LUONJ.mjs} +3 -3
  199. package/dist/cli/{chunk-2WFPHBR4.js → chunk-TFEXSHPM.js} +22 -18
  200. package/dist/cli/{chunk-5IL7SC45.mjs → chunk-TN4TY6TT.mjs} +6 -7
  201. package/dist/cli/{chunk-WEHCBH5R.mjs → chunk-UEVKMZLR.mjs} +54 -3
  202. package/dist/cli/{chunk-RE5MJBEV.mjs → chunk-UVQJYV76.mjs} +2 -2
  203. package/dist/cli/{chunk-FSIVF2SI.mjs → chunk-VZGLIK5U.mjs} +1 -1
  204. package/dist/cli/{chunk-W2ZWQUHT.js → chunk-WOCHZCUJ.js} +2 -2
  205. package/dist/cli/{chunk-ZDQFBJPO.js → chunk-XLIHTJVM.js} +348 -118
  206. package/dist/cli/{chunk-2ZYRBMQM.js → chunk-Y6SP3JMI.js} +22 -22
  207. package/dist/cli/{chunk-PPSDCN6C.js → chunk-YUA6HA6D.js} +2 -2
  208. package/dist/cli/{chunk-JL2OTMSG.mjs → chunk-Z3A2S3QM.mjs} +41 -0
  209. package/dist/cli/{chunk-E64HFB4L.mjs → chunk-Z6XPSHKM.mjs} +87 -41
  210. package/dist/cli/{chunk-7DOQ3OEX.mjs → chunk-Z7AOIHFE.mjs} +1870 -91
  211. package/dist/cli/command-docs.js +3 -3
  212. package/dist/cli/command-docs.mjs +2 -2
  213. package/dist/cli/concurrent-runs-help-CFJH4KXV.js +22 -0
  214. package/dist/cli/{concurrent-runs-help-C6L6I5OR.mjs → concurrent-runs-help-DNV2X5AZ.mjs} +9 -8
  215. package/dist/cli/{csv-QMF4FWE7.js → csv-SA6ELJY6.js} +16 -15
  216. package/dist/cli/{csv-SYSDXFEM.mjs → csv-ZXZGHWOM.mjs} +7 -6
  217. package/dist/cli/{db-Q7HURWRZ.mjs → db-A54SP6AD.mjs} +16 -16
  218. package/dist/cli/{db-YSHPPA4H.js → db-JHFEIQBU.js} +43 -43
  219. package/dist/cli/describe-PHQ33AGS.mjs +50 -0
  220. package/dist/cli/describe-RHJ4XRFI.js +50 -0
  221. package/dist/cli/describe-core.d.mts +3 -3
  222. package/dist/cli/describe-core.d.ts +3 -3
  223. package/dist/cli/describe-core.js +6 -6
  224. package/dist/cli/describe-core.mjs +5 -5
  225. package/dist/cli/{executions-G7U3VUXN.mjs → executions-HL2M2DFU.mjs} +10 -10
  226. package/dist/cli/{executions-MWBC5TAW.js → executions-TLFZRHBJ.js} +12 -12
  227. package/dist/cli/{feedback-SD55OY6H.js → feedback-5UEX5UZK.js} +17 -16
  228. package/dist/cli/{feedback-GMHIFLBJ.mjs → feedback-QMBTNXVG.mjs} +9 -8
  229. package/dist/cli/git-4JWOOHBG.js +26 -0
  230. package/dist/cli/{git-HPE45OPD.mjs → git-LKGXVIVC.mjs} +8 -7
  231. package/dist/cli/index.js +170 -158
  232. package/dist/cli/index.mjs +60 -48
  233. package/dist/cli/{integrations-HFKVBY6G.js → integrations-6RUTLMN7.js} +23 -27
  234. package/dist/cli/{integrations-2W4MGIQR.mjs → integrations-FGGRVUJ7.mjs} +15 -19
  235. package/dist/cli/{legacy-noops-SXVNDEXN.js → legacy-noops-J3Z7QRWZ.js} +12 -11
  236. package/dist/cli/{legacy-noops-GZYKNU2Z.mjs → legacy-noops-YIPRMVXZ.mjs} +9 -8
  237. package/dist/cli/{mcp-PJRHQHHU.js → mcp-6LWFP7RW.js} +121 -48
  238. package/dist/cli/{mcp-BWA6KULG.mjs → mcp-CHDYFO7F.mjs} +100 -27
  239. package/dist/cli/{monitors-K2WSI6CR.js → monitors-STM6A7OU.js} +221 -186
  240. package/dist/cli/{monitors-SYQKCATO.mjs → monitors-UGRY2BXI.mjs} +58 -23
  241. package/dist/cli/org-3SYOUQCX.mjs +2289 -0
  242. package/dist/cli/org-ZOBSNSIB.js +2289 -0
  243. package/dist/cli/outcomes-H4YYAT5X.js +2865 -0
  244. package/dist/cli/outcomes-Z3P2JE67.mjs +2865 -0
  245. package/dist/cli/{play-SZXY2F2S.js → play-SM4CW2GS.js} +1116 -846
  246. package/dist/cli/{play-TTMABJEI.mjs → play-SN5YWLS7.mjs} +375 -105
  247. package/dist/cli/{providers-GQIOMRQO.mjs → providers-WZ4YBR5Y.mjs} +10 -10
  248. package/dist/cli/{providers-YDHCTZAF.js → providers-WZARYMCF.js} +13 -13
  249. package/dist/cli/{quickstart-PHSSMKCA.mjs → quickstart-2575BNKA.mjs} +7 -6
  250. package/dist/cli/{quickstart-BNYOXQXG.js → quickstart-PS4YHQJ6.js} +9 -8
  251. package/dist/cli/{run-GFIAZXVL.js → run-FLZ6OTM7.js} +51 -51
  252. package/dist/cli/{run-74C3C75C.mjs → run-ZUHCZOJS.mjs} +31 -31
  253. package/dist/cli/run-identity-LMLFMACS.js +31 -0
  254. package/dist/cli/{run-identity-MRNCEGV2.mjs → run-identity-MAZ7ANH5.mjs} +9 -3
  255. package/dist/cli/{search-3SWUB7KX.mjs → search-HLPPKQEO.mjs} +11 -11
  256. package/dist/cli/search-JJWVHR3N.js +32 -0
  257. package/dist/cli/{search-output-K2SWHVHQ.mjs → search-output-PDAXNOGP.mjs} +9 -8
  258. package/dist/cli/{search-output-6JF3S4TP.js → search-output-RXJLU36B.js} +12 -11
  259. package/dist/cli/{secrets-2M4XWEKE.mjs → secrets-CGELYQ3H.mjs} +11 -11
  260. package/dist/cli/{secrets-2SAKLH2H.js → secrets-QJNG7G2Y.js} +20 -20
  261. package/dist/cli/sessions-DHTBT2GN.js +23 -0
  262. package/dist/cli/{sessions-A64BCXTO.mjs → sessions-ELMWVR4M.mjs} +9 -8
  263. package/dist/cli/{settings-HV64WIJF.js → settings-44I44P5F.js} +89 -89
  264. package/dist/cli/{settings-SVGEC3FI.mjs → settings-RR3LZXL7.mjs} +16 -16
  265. package/dist/cli/{setup-EDC3NEJ3.mjs → setup-KGWRWH4B.mjs} +20 -19
  266. package/dist/cli/{setup-FHXOLQGQ.js → setup-KTEYOCJO.js} +60 -59
  267. package/dist/cli/skills-EPZPEXI2.js +37 -0
  268. package/dist/cli/{skills-3HGHZMXB.mjs → skills-FPRID2I5.mjs} +10 -9
  269. package/dist/cli/tools-IGQQ5TML.js +57 -0
  270. package/dist/cli/{tools-P2QS6A6Q.mjs → tools-PI4WMDLY.mjs} +23 -23
  271. package/dist/cli/update-4RNCVYGE.js +37 -0
  272. package/dist/cli/{update-552BYQM4.mjs → update-VJOJAZ7B.mjs} +14 -11
  273. package/dist/cli/{views-PA25NAE3.js → views-NTUOLNQU.js} +62 -64
  274. package/dist/cli/{views-LD5HXJYY.mjs → views-OVPSINZO.mjs} +47 -49
  275. package/dist/cli/{workflow-FIDBUQV6.js → workflow-2UDYDM6F.js} +23 -23
  276. package/dist/cli/{workflow-LDYFGBYP.mjs → workflow-7OEFNXZC.mjs} +13 -13
  277. package/dist/{client-DuDFiJDU.d.mts → client-B8f7RNF8.d.mts} +1 -1
  278. package/dist/{client-t9HZAkFD.d.ts → client-C5TgXmJQ.d.ts} +1 -1
  279. package/dist/{client-core-DydMQOft.d.mts → client-core-SLLGBTht.d.mts} +285 -23
  280. package/dist/{client-core-CJRzLanv.d.ts → client-core-p0sOxnkl.d.ts} +285 -23
  281. package/dist/{compiler-manifest-BqwVrOri.d.mts → compiler-manifest-D_zZEh9Q.d.mts} +70 -5
  282. package/dist/{compiler-manifest-BqwVrOri.d.ts → compiler-manifest-D_zZEh9Q.d.ts} +70 -5
  283. package/dist/{errors-BU8FB99X.d.mts → errors-CZCrBFrQ.d.mts} +1 -1
  284. package/dist/{errors-DfVN_FUG.d.ts → errors-DsUkLrdZ.d.ts} +1 -1
  285. package/dist/{index-BGnvtYGc.d.ts → index-B6RTOZGC.d.ts} +1 -1
  286. package/dist/{index-DjZgwpGw.d.mts → index-DeOVrEmX.d.mts} +1 -1
  287. package/dist/index.d.mts +7 -7
  288. package/dist/index.d.ts +7 -7
  289. package/dist/index.js +66 -55
  290. package/dist/index.mjs +25 -14
  291. package/dist/install-integrity.json +162 -142
  292. package/dist/plays/bundle-play-file.d.mts +3 -3
  293. package/dist/plays/bundle-play-file.d.ts +3 -3
  294. package/dist/plays/bundle-play-file.mjs +23 -4
  295. package/dist/plays/csv-data-input.js +3 -3
  296. package/dist/plays/csv-data-input.mjs +2 -2
  297. package/dist/plays/play-description.d.mts +2 -2
  298. package/dist/plays/play-description.d.ts +2 -2
  299. package/dist/plays/run-request.d.mts +2 -2
  300. package/dist/plays/run-request.d.ts +2 -2
  301. package/dist/plays/run-request.js +4 -4
  302. package/dist/plays/run-request.mjs +3 -3
  303. package/dist/release.d.mts +1 -1
  304. package/dist/release.d.ts +1 -1
  305. package/dist/release.js +2 -2
  306. package/dist/release.mjs +1 -1
  307. package/dist/server.d.mts +4 -4
  308. package/dist/server.d.ts +4 -4
  309. package/dist/server.js +15 -13
  310. package/dist/server.mjs +9 -7
  311. package/package.json +1 -1
  312. package/dist/cli/auth-B4PI7GVY.js +0 -43
  313. package/dist/cli/concurrent-runs-help-JEFQZTJI.js +0 -21
  314. package/dist/cli/describe-PXTSBJTL.js +0 -50
  315. package/dist/cli/describe-YGMQBV44.mjs +0 -50
  316. package/dist/cli/git-I3JV7IGH.js +0 -25
  317. package/dist/cli/org-5KD7X7IA.mjs +0 -1282
  318. package/dist/cli/org-YQ2CR32B.js +0 -1282
  319. package/dist/cli/run-identity-G257GQED.js +0 -25
  320. package/dist/cli/search-2RRRF4LW.js +0 -32
  321. package/dist/cli/sessions-SBH27JNW.js +0 -22
  322. package/dist/cli/skills-Y3SRLOYD.js +0 -36
  323. package/dist/cli/tools-OFYPUPUV.js +0 -57
  324. package/dist/cli/update-SOUSCLB7.js +0 -34
package/dist/index.js CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
 
5
5
 
6
- var _chunkZCDKE4UHjs = require('./cli/chunk-ZCDKE4UH.js');
6
+ var _chunk74RES4DSjs = require('./cli/chunk-74RES4DS.js');
7
7
 
8
8
 
9
9
 
@@ -12,7 +12,7 @@ var _chunkZCDKE4UHjs = require('./cli/chunk-ZCDKE4UH.js');
12
12
  var _chunkHGFFYVXNjs = require('./cli/chunk-HGFFYVXN.js');
13
13
 
14
14
 
15
- var _chunkQM6Y6S4Ejs = require('./cli/chunk-QM6Y6S4E.js');
15
+ var _chunkJLGP5XAJjs = require('./cli/chunk-JLGP5XAJ.js');
16
16
 
17
17
 
18
18
 
@@ -37,19 +37,15 @@ var _chunkVKKVSFRDjs = require('./cli/chunk-VKKVSFRD.js');
37
37
 
38
38
 
39
39
 
40
- var _chunkLPJPCGT3js = require('./cli/chunk-LPJPCGT3.js');
40
+ var _chunkCACFJODGjs = require('./cli/chunk-CACFJODG.js');
41
41
 
42
42
 
43
43
  var _chunk4WAM6TLDjs = require('./cli/chunk-4WAM6TLD.js');
44
- require('./cli/chunk-SL6MYJYM.js');
44
+ require('./cli/chunk-MJTVX4QK.js');
45
45
  require('./cli/chunk-PMH4GLMD.js');
46
46
 
47
47
 
48
48
 
49
- var _chunkXDVT3GOMjs = require('./cli/chunk-XDVT3GOM.js');
50
-
51
-
52
-
53
49
 
54
50
 
55
51
 
@@ -69,18 +65,18 @@ var _chunkU2LVWCTDjs = require('./cli/chunk-U2LVWCTD.js');
69
65
 
70
66
 
71
67
 
72
- var _chunkUDXULACQjs = require('./cli/chunk-UDXULACQ.js');
68
+ var _chunkMLABYI4Mjs = require('./cli/chunk-MLABYI4M.js');
73
69
 
74
70
 
75
71
 
76
- var _chunkPACD5DGCjs = require('./cli/chunk-PACD5DGC.js');
72
+ var _chunkAGLR6QVNjs = require('./cli/chunk-AGLR6QVN.js');
77
73
 
78
74
 
79
75
 
80
76
 
81
77
 
82
78
 
83
- var _chunkEITMD3A5js = require('./cli/chunk-EITMD3A5.js');
79
+ var _chunk6VLFQZK6js = require('./cli/chunk-6VLFQZK6.js');
84
80
  require('./cli/chunk-XNYIZMNQ.js');
85
81
 
86
82
 
@@ -89,8 +85,13 @@ require('./cli/chunk-XNYIZMNQ.js');
89
85
 
90
86
 
91
87
 
92
- var _chunkBBTKAASQjs = require('./cli/chunk-BBTKAASQ.js');
93
- require('./cli/chunk-VTGG2RT3.js');
88
+
89
+ var _chunkLFQJW4S2js = require('./cli/chunk-LFQJW4S2.js');
90
+
91
+
92
+
93
+ var _chunkCFJFUVX2js = require('./cli/chunk-CFJFUVX2.js');
94
+ require('./cli/chunk-6NE3RRRY.js');
94
95
  require('./cli/chunk-OG64RBAC.js');
95
96
  require('./cli/chunk-COGTRVWW.js');
96
97
 
@@ -1307,7 +1308,7 @@ function buildListAccessors(resolved, lists, toolId, executionDiscriminator) {
1307
1308
  metadata.path,
1308
1309
  datasetDiscriminator
1309
1310
  ),
1310
- datasetId: `tool-list:${_chunkXDVT3GOMjs.sha256Hex.call(void 0,
1311
+ datasetId: `tool-list:${_chunkCFJFUVX2js.sha256Hex.call(void 0,
1311
1312
  `${toolId}:${metadata.path}:${datasetDiscriminator}`
1312
1313
  )}`
1313
1314
  });
@@ -1328,7 +1329,7 @@ function buildListAccessors(resolved, lists, toolId, executionDiscriminator) {
1328
1329
  }
1329
1330
  function listRowsFingerprint(rows) {
1330
1331
  try {
1331
- return _chunkXDVT3GOMjs.sha256Hex.call(void 0,
1332
+ return _chunkCFJFUVX2js.sha256Hex.call(void 0,
1332
1333
  JSON.stringify(
1333
1334
  {
1334
1335
  count: rows.length,
@@ -1338,23 +1339,23 @@ function listRowsFingerprint(rows) {
1338
1339
  )
1339
1340
  ).slice(0, 12);
1340
1341
  } catch (e) {
1341
- return _chunkXDVT3GOMjs.sha256Hex.call(void 0, String(rows.length)).slice(0, 12);
1342
+ return _chunkCFJFUVX2js.sha256Hex.call(void 0, String(rows.length)).slice(0, 12);
1342
1343
  }
1343
1344
  }
1344
1345
  function listTableNamespace(toolId, name, path, discriminator) {
1345
- const raw = `${toolId}_${name || path || "rows"}_${_chunkXDVT3GOMjs.sha256Hex.call(void 0, discriminator).slice(0, 10)}`;
1346
+ const raw = `${toolId}_${name || path || "rows"}_${_chunkCFJFUVX2js.sha256Hex.call(void 0, discriminator).slice(0, 10)}`;
1346
1347
  try {
1347
- return _chunkXDVT3GOMjs.normalizeTableNamespace.call(void 0, raw);
1348
+ return _chunkCFJFUVX2js.normalizeTableNamespace.call(void 0, raw);
1348
1349
  } catch (e2) {
1349
- const hash = _chunkXDVT3GOMjs.sha256Hex.call(void 0, raw).slice(0, 10);
1350
+ const hash = _chunkCFJFUVX2js.sha256Hex.call(void 0, raw).slice(0, 10);
1350
1351
  const leaf = name || path.split(".").filter(Boolean).at(-1) || "rows";
1351
1352
  let prefix = "rows";
1352
1353
  try {
1353
- prefix = _chunkXDVT3GOMjs.normalizeTableNamespace.call(void 0, leaf).slice(0, 52) || "rows";
1354
+ prefix = _chunkCFJFUVX2js.normalizeTableNamespace.call(void 0, leaf).slice(0, 52) || "rows";
1354
1355
  } catch (e3) {
1355
1356
  prefix = "rows";
1356
1357
  }
1357
- return _chunkXDVT3GOMjs.normalizeTableNamespace.call(void 0, `${prefix}_${hash}`);
1358
+ return _chunkCFJFUVX2js.normalizeTableNamespace.call(void 0, `${prefix}_${hash}`);
1358
1359
  }
1359
1360
  }
1360
1361
  function oneValue(values, toolId, name) {
@@ -1801,6 +1802,13 @@ function preservedSerializedListRows(value) {
1801
1802
  }
1802
1803
 
1803
1804
  // ../play-runtime/query-result-dataset.ts
1805
+ function readQueryResultDatasetResultRef(dataset) {
1806
+ const raw = _optionalChain([dataset, 'optionalAccess', _78 => _78.result_ref]);
1807
+ if (typeof raw !== "string") return null;
1808
+ const resultRef = raw.trim();
1809
+ return resultRef && resultRef.length <= QUERY_RESULT_DATASET_RESULT_REF_MAX_LENGTH ? resultRef : null;
1810
+ }
1811
+ var QUERY_RESULT_DATASET_RESULT_REF_MAX_LENGTH = 256;
1804
1812
  var QUERY_RESULT_DATASET_PAGE_SIZE = 1e3;
1805
1813
  function isCustomerDbDatasetTool(toolId) {
1806
1814
  return /^(?:customer_db_)?query_customer_db$/.test(toolId);
@@ -1846,7 +1854,7 @@ function __deeplineRunWithDocflowContext(context, body) {
1846
1854
  return docflowRunContexts.run(context, body);
1847
1855
  }
1848
1856
  function __deeplineCurrentDocflowContext() {
1849
- const context = _nullishCoalesce(_nullishCoalesce(_optionalChain([docflowRunContexts, 'optionalAccess', _78 => _78.getStore, 'call', _79 => _79()]), () => ( _optionalChain([scriptRuns, 'access', _80 => _80.getStore, 'call', _81 => _81(), 'optionalAccess', _82 => _82.context]))), () => ( null));
1857
+ const context = _nullishCoalesce(_nullishCoalesce(_optionalChain([docflowRunContexts, 'optionalAccess', _79 => _79.getStore, 'call', _80 => _80()]), () => ( _optionalChain([scriptRuns, 'access', _81 => _81.getStore, 'call', _82 => _82(), 'optionalAccess', _83 => _83.context]))), () => ( null));
1850
1858
  if (!context) return null;
1851
1859
  let observe;
1852
1860
  try {
@@ -1945,7 +1953,7 @@ var DeeplineStepProgram = (_class3 = class _DeeplineStepProgram {
1945
1953
  "steps().step(name, ...) requires a non-empty step name."
1946
1954
  );
1947
1955
  }
1948
- const stepResolver = _optionalChain([options, 'optionalAccess', _83 => _83.runIf]) && !isConditionalStepResolver(resolver) ? new DeeplineConditionalStepResolver(
1956
+ const stepResolver = _optionalChain([options, 'optionalAccess', _84 => _84.runIf]) && !isConditionalStepResolver(resolver) ? new DeeplineConditionalStepResolver(
1949
1957
  options.runIf,
1950
1958
  resolver,
1951
1959
  null
@@ -1955,9 +1963,9 @@ var DeeplineStepProgram = (_class3 = class _DeeplineStepProgram {
1955
1963
  ...this.steps,
1956
1964
  {
1957
1965
  name,
1958
- ..._optionalChain([options, 'optionalAccess', _84 => _84.recompute]) === true ? { recompute: true } : {},
1959
- ..._optionalChain([options, 'optionalAccess', _85 => _85.recomputeOnError]) === true ? { recomputeOnError: true } : {},
1960
- ...typeof _optionalChain([options, 'optionalAccess', _86 => _86.staleAfterSeconds]) === "number" ? { staleAfterSeconds: options.staleAfterSeconds } : {},
1966
+ ..._optionalChain([options, 'optionalAccess', _85 => _85.recompute]) === true ? { recompute: true } : {},
1967
+ ..._optionalChain([options, 'optionalAccess', _86 => _86.recomputeOnError]) === true ? { recomputeOnError: true } : {},
1968
+ ...typeof _optionalChain([options, 'optionalAccess', _87 => _87.staleAfterSeconds]) === "number" ? { staleAfterSeconds: options.staleAfterSeconds } : {},
1961
1969
  resolver: stepResolver
1962
1970
  }
1963
1971
  ],
@@ -1997,13 +2005,13 @@ var DeeplinePlayJobImpl = class {
1997
2005
  return this.client.getPlayStatus(this.id);
1998
2006
  }
1999
2007
  async tail(options) {
2000
- const intervalMs = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _87 => _87.intervalMs]), () => ( 500));
2001
- const onLog = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _88 => _88.onLog]), () => ( ((line) => console.log(line))));
2008
+ const intervalMs = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _88 => _88.intervalMs]), () => ( 500));
2009
+ const onLog = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _89 => _89.onLog]), () => ( ((line) => console.log(line))));
2002
2010
  const terminalStates = /* @__PURE__ */ new Set(["completed", "failed", "cancelled"]);
2003
2011
  let lastLogIndex = 0;
2004
2012
  while (true) {
2005
2013
  const status = await this.status();
2006
- const logs = _nullishCoalesce(_optionalChain([status, 'access', _89 => _89.progress, 'optionalAccess', _90 => _90.logs]), () => ( []));
2014
+ const logs = _nullishCoalesce(_optionalChain([status, 'access', _90 => _90.progress, 'optionalAccess', _91 => _91.logs]), () => ( []));
2007
2015
  for (let index = lastLogIndex; index < logs.length; index += 1) {
2008
2016
  onLog(logs[index]);
2009
2017
  }
@@ -2015,14 +2023,14 @@ var DeeplinePlayJobImpl = class {
2015
2023
  }
2016
2024
  }
2017
2025
  async get(options) {
2018
- const intervalMs = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _91 => _91.intervalMs]), () => ( 500));
2026
+ const intervalMs = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _92 => _92.intervalMs]), () => ( 500));
2019
2027
  const terminalStates = /* @__PURE__ */ new Set(["completed", "failed", "cancelled"]);
2020
2028
  while (true) {
2021
2029
  const status = await this.status();
2022
2030
  if (terminalStates.has(status.status)) {
2023
2031
  if (status.status !== "completed") {
2024
- throw new (0, _chunkBBTKAASQjs.DeeplineError)(
2025
- _optionalChain([status, 'access', _92 => _92.progress, 'optionalAccess', _93 => _93.error]) || `Play run ${this.id} ended with ${status.status}.`
2032
+ throw new (0, _chunkLFQJW4S2js.DeeplineError)(
2033
+ _optionalChain([status, 'access', _93 => _93.progress, 'optionalAccess', _94 => _94.error]) || `Play run ${this.id} ended with ${status.status}.`
2026
2034
  );
2027
2035
  }
2028
2036
  if (status.package) {
@@ -2053,8 +2061,8 @@ function createNamedPlayHandle(clientFactory, name) {
2053
2061
  const client = clientFactory();
2054
2062
  const started = await client.startPlayRun({
2055
2063
  name,
2056
- ..._optionalChain([options, 'optionalAccess', _94 => _94.revisionId]) ? { revisionId: options.revisionId } : {},
2057
- ..._optionalChain([options, 'optionalAccess', _95 => _95.profile]) ? { profile: options.profile } : {},
2064
+ ..._optionalChain([options, 'optionalAccess', _95 => _95.revisionId]) ? { revisionId: options.revisionId } : {},
2065
+ ..._optionalChain([options, 'optionalAccess', _96 => _96.profile]) ? { profile: options.profile } : {},
2058
2066
  input
2059
2067
  });
2060
2068
  return new DeeplinePlayJobImpl(client, started.workflowId);
@@ -2080,7 +2088,7 @@ var DeeplineContext = class {
2080
2088
  * @param options - Optional SDK client configuration.
2081
2089
  */
2082
2090
  constructor(options) {
2083
- this.client = new (0, _chunkQM6Y6S4Ejs.DeeplineClient)(options);
2091
+ this.client = new (0, _chunkJLGP5XAJjs.DeeplineClient)(options);
2084
2092
  }
2085
2093
  /**
2086
2094
  * Tool operations namespace.
@@ -2345,15 +2353,16 @@ function stableHash(value) {
2345
2353
  function attachSdkQueryResultDatasetResult(toolId, result, options) {
2346
2354
  if (!options || !isQueryResultDatasetTool(toolId)) return result;
2347
2355
  const raw = isRecord2(result.toolResponse.raw) ? result.toolResponse.raw : null;
2348
- const dataset = isRecord2(_optionalChain([raw, 'optionalAccess', _96 => _96.dataset])) ? raw.dataset : null;
2349
- const totalRows = finiteNonNegativeInteger(_optionalChain([dataset, 'optionalAccess', _97 => _97.total_rows]));
2350
- const sql = typeof options.input.sql === "string" ? options.input.sql : typeof options.input.query === "string" ? options.input.query : typeof _optionalChain([raw, 'optionalAccess', _98 => _98.sql]) === "string" ? raw.sql : null;
2356
+ const dataset = isRecord2(_optionalChain([raw, 'optionalAccess', _97 => _97.dataset])) ? raw.dataset : null;
2357
+ const totalRows = finiteNonNegativeInteger(_optionalChain([dataset, 'optionalAccess', _98 => _98.total_rows]));
2358
+ const sql = typeof options.input.sql === "string" ? options.input.sql : typeof options.input.query === "string" ? options.input.query : typeof _optionalChain([raw, 'optionalAccess', _99 => _99.sql]) === "string" ? raw.sql : null;
2351
2359
  if (!dataset || totalRows === null || !sql) {
2352
2360
  return result;
2353
2361
  }
2354
2362
  const datasetLimit = _nullishCoalesce(finitePositiveInteger(dataset.returned_limit), () => ( totalRows));
2355
2363
  const effectiveCount = Math.min(totalRows, datasetLimit);
2356
- const rawRows = rowsFromUnknown(_optionalChain([raw, 'optionalAccess', _99 => _99.rows]));
2364
+ const storedResultRef = readQueryResultDatasetResultRef(dataset);
2365
+ const rawRows = rowsFromUnknown(_optionalChain([raw, 'optionalAccess', _100 => _100.rows]));
2357
2366
  const previewRows = rawRows.slice(0, 25);
2358
2367
  const fetchPage = async (offset, limit) => {
2359
2368
  if (limit <= 0 || offset >= totalRows) return [];
@@ -2365,7 +2374,8 @@ function attachSdkQueryResultDatasetResult(toolId, result, options) {
2365
2374
  limit: datasetLimit,
2366
2375
  offset,
2367
2376
  page_size: Math.min(limit, QUERY_RESULT_DATASET_PAGE_SIZE),
2368
- total_rows: totalRows
2377
+ total_rows: totalRows,
2378
+ ...storedResultRef ? { result_ref: storedResultRef } : {}
2369
2379
  },
2370
2380
  ...isCustomerDbDatasetTool(toolId) ? {
2371
2381
  customer_db_dataset: {
@@ -2377,8 +2387,8 @@ function attachSdkQueryResultDatasetResult(toolId, result, options) {
2377
2387
  } : {}
2378
2388
  }
2379
2389
  });
2380
- const pageRaw = isRecord2(_optionalChain([response, 'access', _100 => _100.toolResponse, 'optionalAccess', _101 => _101.raw])) ? response.toolResponse.raw : null;
2381
- return rowsFromUnknown(_optionalChain([pageRaw, 'optionalAccess', _102 => _102.rows]));
2390
+ const pageRaw = isRecord2(_optionalChain([response, 'access', _101 => _101.toolResponse, 'optionalAccess', _102 => _102.raw])) ? response.toolResponse.raw : null;
2391
+ return rowsFromUnknown(_optionalChain([pageRaw, 'optionalAccess', _103 => _103.rows]));
2382
2392
  };
2383
2393
  const collectRows = async (limit) => {
2384
2394
  const target = Math.min(_nullishCoalesce(limit, () => ( totalRows)), totalRows, datasetLimit);
@@ -2430,10 +2440,10 @@ function attachSdkQueryResultDatasetResult(toolId, result, options) {
2430
2440
  });
2431
2441
  }
2432
2442
  function toolExecutionEnvelopeToResult(fallbackToolId, response, options) {
2433
- const raw = _nullishCoalesce(_optionalChain([response, 'access', _103 => _103.toolResponse, 'optionalAccess', _104 => _104.raw]), () => ( null));
2434
- const rawV2 = _optionalChain([response, 'access', _105 => _105.toolResponse, 'optionalAccess', _106 => _106.rawV2]);
2435
- const view = _optionalChain([response, 'access', _107 => _107.toolResponse, 'optionalAccess', _108 => _108.view]);
2436
- const meta = _optionalChain([response, 'access', _109 => _109.toolResponse, 'optionalAccess', _110 => _110.meta]);
2443
+ const raw = _nullishCoalesce(_optionalChain([response, 'access', _104 => _104.toolResponse, 'optionalAccess', _105 => _105.raw]), () => ( null));
2444
+ const rawV2 = _optionalChain([response, 'access', _106 => _106.toolResponse, 'optionalAccess', _107 => _107.rawV2]);
2445
+ const view = _optionalChain([response, 'access', _108 => _108.toolResponse, 'optionalAccess', _109 => _109.view]);
2446
+ const meta = _optionalChain([response, 'access', _110 => _110.toolResponse, 'optionalAccess', _111 => _111.meta]);
2437
2447
  const metadata = isRecord2(response._metadata) ? response._metadata.tool : null;
2438
2448
  const toolMetadata = isRecord2(metadata) ? metadata : {};
2439
2449
  const result = projectToolResultListGetters(
@@ -2492,11 +2502,11 @@ function definePlay(nameOrConfig, maybeFn, maybeBindings) {
2492
2502
  name: nameOrConfig,
2493
2503
  fn: maybeFn,
2494
2504
  bindings: maybeBindings,
2495
- description: _optionalChain([maybeBindings, 'optionalAccess', _111 => _111.description]),
2505
+ description: _optionalChain([maybeBindings, 'optionalAccess', _112 => _112.description]),
2496
2506
  inputSchema: void 0,
2497
- billing: _optionalChain([maybeBindings, 'optionalAccess', _112 => _112.billing]),
2498
- runtime: _optionalChain([maybeBindings, 'optionalAccess', _113 => _113.runtime]),
2499
- compatibility: _optionalChain([maybeBindings, 'optionalAccess', _114 => _114.compatibility])
2507
+ billing: _optionalChain([maybeBindings, 'optionalAccess', _113 => _113.billing]),
2508
+ runtime: _optionalChain([maybeBindings, 'optionalAccess', _114 => _114.runtime]),
2509
+ compatibility: _optionalChain([maybeBindings, 'optionalAccess', _115 => _115.compatibility])
2500
2510
  } : {
2501
2511
  name: nameOrConfig.id,
2502
2512
  fn: nameOrConfig.run,
@@ -2507,13 +2517,13 @@ function definePlay(nameOrConfig, maybeFn, maybeBindings) {
2507
2517
  description: nameOrConfig.description,
2508
2518
  inputSchema: nameOrConfig.input.schema,
2509
2519
  billing: nameOrConfig.billing,
2510
- runtime: _nullishCoalesce(nameOrConfig.runtime, () => ( _optionalChain([nameOrConfig, 'access', _115 => _115.bindings, 'optionalAccess', _116 => _116.runtime]))),
2511
- compatibility: _nullishCoalesce(nameOrConfig.compatibility, () => ( _optionalChain([nameOrConfig, 'access', _117 => _117.bindings, 'optionalAccess', _118 => _118.compatibility])))
2520
+ runtime: _nullishCoalesce(nameOrConfig.runtime, () => ( _optionalChain([nameOrConfig, 'access', _116 => _116.bindings, 'optionalAccess', _117 => _117.runtime]))),
2521
+ compatibility: _nullishCoalesce(nameOrConfig.compatibility, () => ( _optionalChain([nameOrConfig, 'access', _118 => _118.bindings, 'optionalAccess', _119 => _119.compatibility])))
2512
2522
  };
2513
2523
  const name = config.name;
2514
2524
  const fn = config.fn;
2515
2525
  const bindings = config.bindings;
2516
- const description = _optionalChain([config, 'access', _119 => _119.description, 'optionalAccess', _120 => _120.trim, 'call', _121 => _121()]);
2526
+ const description = _optionalChain([config, 'access', _120 => _120.description, 'optionalAccess', _121 => _121.trim, 'call', _122 => _122()]);
2517
2527
  const billing = config.billing;
2518
2528
  const inputSchema = config.inputSchema;
2519
2529
  const runtime = config.runtime;
@@ -2578,7 +2588,7 @@ function definePlay(nameOrConfig, maybeFn, maybeBindings) {
2578
2588
  writable: false
2579
2589
  });
2580
2590
  const handle = createNamedPlayHandle(
2581
- () => _chunkZCDKE4UHjs.createPlayClient.call(void 0, ),
2591
+ () => _chunk74RES4DSjs.createPlayClient.call(void 0, ),
2582
2592
  name
2583
2593
  );
2584
2594
  for (const key of [
@@ -2744,4 +2754,5 @@ var DEEPLINE_TOOL_CATEGORIES = [
2744
2754
 
2745
2755
 
2746
2756
 
2747
- exports.AuthError = _chunkEITMD3A5js.AuthError; exports.ConfigError = _chunkEITMD3A5js.ConfigError; exports.CtxFetchAmbiguousWriteError = _chunkVKKVSFRDjs.CtxFetchAmbiguousWriteError; exports.CtxFetchHttpError = _chunkVKKVSFRDjs.CtxFetchHttpError; exports.CustomerDbQueryOutcomeUnknownError = _chunkEITMD3A5js.CustomerDbQueryOutcomeUnknownError; exports.DEEPLINE_EXTRACTOR_TARGETS = _chunkBLMB4N63js.DEEPLINE_EXTRACTOR_TARGETS; exports.DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS = _chunkBLMB4N63js.DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS; exports.DEEPLINE_TOOL_CATEGORIES = DEEPLINE_TOOL_CATEGORIES; exports.Deepline = Deepline; exports.DeeplineClient = _chunkQM6Y6S4Ejs.DeeplineClient; exports.DeeplineContext = DeeplineContext; exports.DeeplineError = _chunkBBTKAASQjs.DeeplineError; exports.JOB_CHANGE_STATUS_VALUES = _chunkBLMB4N63js.JOB_CHANGE_STATUS_VALUES; exports.MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG = _chunkWOQO3GV4js.MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG; exports.MONITOR_FLEET_AUTHORING_CONTRACT_EDITION = _chunkWOQO3GV4js.MONITOR_FLEET_AUTHORING_CONTRACT_EDITION; exports.MONITOR_FLEET_DOCUMENTATION = _chunkWOQO3GV4js.MONITOR_FLEET_DOCUMENTATION; exports.MONITOR_FLEET_FRONTIER_MAX_ROWS = _chunkWOQO3GV4js.MONITOR_FLEET_FRONTIER_MAX_ROWS; exports.MONITOR_FLEET_MAX_MEMBERS = _chunkWOQO3GV4js.MONITOR_FLEET_MAX_MEMBERS; exports.MONITOR_JOB_PHASES = _chunkLPJPCGT3js.MONITOR_JOB_PHASES; exports.MONITOR_JOB_RECONCILIATION_STATES = _chunkLPJPCGT3js.MONITOR_JOB_RECONCILIATION_STATES; exports.MONITOR_JOB_STATES = _chunkLPJPCGT3js.MONITOR_JOB_STATES; exports.PHONE_STATUS_VALUES = _chunkBLMB4N63js.PHONE_STATUS_VALUES; exports.PROD_URL = _chunkUDXULACQjs.PROD_URL; exports.ProviderTransientError = _chunkBBTKAASQjs.ProviderTransientError; exports.RateLimitError = _chunkEITMD3A5js.RateLimitError; exports.RunEventQueryInputError = _chunkLPJPCGT3js.RunEventQueryInputError; exports.RunObserveTransportUnavailableError = RunObserveTransportUnavailableError; exports.SDK_API_CONTRACT = _chunkPACD5DGCjs.SDK_API_CONTRACT; exports.SDK_VERSION = _chunkPACD5DGCjs.SDK_VERSION; exports.ToolExecutionError = _chunkBBTKAASQjs.ToolExecutionError; exports.ToolRateLimitError = _chunkEITMD3A5js.ToolRateLimitError; exports.__deeplineCurrentDocflowContext = __deeplineCurrentDocflowContext; exports.__deeplineRunWithDocflowContext = __deeplineRunWithDocflowContext; exports.admitMonitorFleetAuthoringContract = _chunkWOQO3GV4js.admitMonitorFleetAuthoringContract; exports.deepline = deepline; exports.default = deepline; exports.defineInput = defineInput; exports.defineMonitor = defineMonitor; exports.defineMonitorFleet = _chunkWOQO3GV4js.defineMonitorFleet; exports.definePlay = definePlay; exports.defineWorkflow = defineWorkflow; exports.extractSummaryFields = _chunkHGFFYVXNjs.extractSummaryFields; exports.fleetColumn = _chunkWOQO3GV4js.fleetColumn; exports.fleetKey = _chunkWOQO3GV4js.fleetKey; exports.getDefinedPlayMetadata = getDefinedPlayMetadata; exports.getProviderUnavailableReason = _chunkBBTKAASQjs.getProviderUnavailableReason; exports.isDeeplineExtractorTarget = _chunkBLMB4N63js.isDeeplineExtractorTarget; exports.isProviderUnavailable = _chunkBBTKAASQjs.isProviderUnavailable; exports.isProviderWaterfallUnavailableError = _chunkBBTKAASQjs.isProviderWaterfallUnavailableError; exports.isStopAllPlayRunsDryRunResult = _chunkLPJPCGT3js.isStopAllPlayRunsDryRunResult; exports.lintMonitorBatchInput = _chunkU2LVWCTDjs.lintMonitorBatchInput; exports.lintMonitorFleetInput = _chunkWOQO3GV4js.lintMonitorFleetInput; exports.lintMonitorSpecTemplate = _chunkU2LVWCTDjs.lintMonitorSpecTemplate; exports.pinLocalPlayImports = _chunkZCDKE4UHjs.pinLocalPlayImports; exports.planCustomerDbQuery = _chunkLPJPCGT3js.planCustomerDbQuery; exports.planLocalPlayExecution = _chunkZCDKE4UHjs.planLocalPlayExecution; exports.readList = readList; exports.renderMonitorSpecTemplate = _chunkU2LVWCTDjs.renderMonitorSpecTemplate; exports.resolveConfig = _chunkUDXULACQjs.resolveConfig; exports.runIf = runIf; exports.runScriptPlay = runScriptPlay; exports.steps = steps; exports.tryConvertToList = _chunkHGFFYVXNjs.tryConvertToList; exports.validateMonitorFleetDefinition = _chunkWOQO3GV4js.validateMonitorFleetDefinition; exports.writeCsvOutputFile = _chunkHGFFYVXNjs.writeCsvOutputFile; exports.writeJsonOutputFile = _chunkHGFFYVXNjs.writeJsonOutputFile;
2757
+
2758
+ exports.AuthError = _chunk6VLFQZK6js.AuthError; exports.ConfigError = _chunk6VLFQZK6js.ConfigError; exports.CtxFetchAmbiguousWriteError = _chunkVKKVSFRDjs.CtxFetchAmbiguousWriteError; exports.CtxFetchHttpError = _chunkVKKVSFRDjs.CtxFetchHttpError; exports.CustomerDbQueryOutcomeUnknownError = _chunk6VLFQZK6js.CustomerDbQueryOutcomeUnknownError; exports.DEEPLINE_EXTRACTOR_TARGETS = _chunkBLMB4N63js.DEEPLINE_EXTRACTOR_TARGETS; exports.DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS = _chunkBLMB4N63js.DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS; exports.DEEPLINE_TOOL_CATEGORIES = DEEPLINE_TOOL_CATEGORIES; exports.Deepline = Deepline; exports.DeeplineClient = _chunkJLGP5XAJjs.DeeplineClient; exports.DeeplineContext = DeeplineContext; exports.DeeplineError = _chunkLFQJW4S2js.DeeplineError; exports.JOB_CHANGE_STATUS_VALUES = _chunkBLMB4N63js.JOB_CHANGE_STATUS_VALUES; exports.MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG = _chunkWOQO3GV4js.MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG; exports.MONITOR_FLEET_AUTHORING_CONTRACT_EDITION = _chunkWOQO3GV4js.MONITOR_FLEET_AUTHORING_CONTRACT_EDITION; exports.MONITOR_FLEET_DOCUMENTATION = _chunkWOQO3GV4js.MONITOR_FLEET_DOCUMENTATION; exports.MONITOR_FLEET_FRONTIER_MAX_ROWS = _chunkWOQO3GV4js.MONITOR_FLEET_FRONTIER_MAX_ROWS; exports.MONITOR_FLEET_MAX_MEMBERS = _chunkWOQO3GV4js.MONITOR_FLEET_MAX_MEMBERS; exports.MONITOR_JOB_PHASES = _chunkCACFJODGjs.MONITOR_JOB_PHASES; exports.MONITOR_JOB_RECONCILIATION_STATES = _chunkCACFJODGjs.MONITOR_JOB_RECONCILIATION_STATES; exports.MONITOR_JOB_STATES = _chunkCACFJODGjs.MONITOR_JOB_STATES; exports.PHONE_STATUS_VALUES = _chunkBLMB4N63js.PHONE_STATUS_VALUES; exports.PROD_URL = _chunkMLABYI4Mjs.PROD_URL; exports.ProviderRejectedError = _chunkLFQJW4S2js.ProviderRejectedError; exports.ProviderTransientError = _chunkLFQJW4S2js.ProviderTransientError; exports.RateLimitError = _chunk6VLFQZK6js.RateLimitError; exports.RunEventQueryInputError = _chunkCACFJODGjs.RunEventQueryInputError; exports.RunObserveTransportUnavailableError = RunObserveTransportUnavailableError; exports.SDK_API_CONTRACT = _chunkAGLR6QVNjs.SDK_API_CONTRACT; exports.SDK_VERSION = _chunkAGLR6QVNjs.SDK_VERSION; exports.ToolExecutionError = _chunkLFQJW4S2js.ToolExecutionError; exports.ToolRateLimitError = _chunk6VLFQZK6js.ToolRateLimitError; exports.__deeplineCurrentDocflowContext = __deeplineCurrentDocflowContext; exports.__deeplineRunWithDocflowContext = __deeplineRunWithDocflowContext; exports.admitMonitorFleetAuthoringContract = _chunkWOQO3GV4js.admitMonitorFleetAuthoringContract; exports.deepline = deepline; exports.default = deepline; exports.defineInput = defineInput; exports.defineMonitor = defineMonitor; exports.defineMonitorFleet = _chunkWOQO3GV4js.defineMonitorFleet; exports.definePlay = definePlay; exports.defineWorkflow = defineWorkflow; exports.extractSummaryFields = _chunkHGFFYVXNjs.extractSummaryFields; exports.fleetColumn = _chunkWOQO3GV4js.fleetColumn; exports.fleetKey = _chunkWOQO3GV4js.fleetKey; exports.getDefinedPlayMetadata = getDefinedPlayMetadata; exports.getProviderUnavailableReason = _chunkLFQJW4S2js.getProviderUnavailableReason; exports.isDeeplineExtractorTarget = _chunkBLMB4N63js.isDeeplineExtractorTarget; exports.isProviderUnavailable = _chunkLFQJW4S2js.isProviderUnavailable; exports.isProviderWaterfallUnavailableError = _chunkLFQJW4S2js.isProviderWaterfallUnavailableError; exports.isStopAllPlayRunsDryRunResult = _chunkCACFJODGjs.isStopAllPlayRunsDryRunResult; exports.lintMonitorBatchInput = _chunkU2LVWCTDjs.lintMonitorBatchInput; exports.lintMonitorFleetInput = _chunkWOQO3GV4js.lintMonitorFleetInput; exports.lintMonitorSpecTemplate = _chunkU2LVWCTDjs.lintMonitorSpecTemplate; exports.pinLocalPlayImports = _chunk74RES4DSjs.pinLocalPlayImports; exports.planCustomerDbQuery = _chunkCACFJODGjs.planCustomerDbQuery; exports.planLocalPlayExecution = _chunk74RES4DSjs.planLocalPlayExecution; exports.readList = readList; exports.renderMonitorSpecTemplate = _chunkU2LVWCTDjs.renderMonitorSpecTemplate; exports.resolveConfig = _chunkMLABYI4Mjs.resolveConfig; exports.runIf = runIf; exports.runScriptPlay = runScriptPlay; exports.steps = steps; exports.tryConvertToList = _chunkHGFFYVXNjs.tryConvertToList; exports.validateMonitorFleetDefinition = _chunkWOQO3GV4js.validateMonitorFleetDefinition; exports.writeCsvOutputFile = _chunkHGFFYVXNjs.writeCsvOutputFile; exports.writeJsonOutputFile = _chunkHGFFYVXNjs.writeJsonOutputFile;
package/dist/index.mjs CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  createPlayClient,
4
4
  pinLocalPlayImports,
5
5
  planLocalPlayExecution
6
- } from "./cli/chunk-RE5MJBEV.mjs";
6
+ } from "./cli/chunk-UVQJYV76.mjs";
7
7
  import {
8
8
  extractSummaryFields,
9
9
  tryConvertToList,
@@ -12,7 +12,7 @@ import {
12
12
  } from "./cli/chunk-FIVKWNMT.mjs";
13
13
  import {
14
14
  DeeplineClient
15
- } from "./cli/chunk-3T65J5RG.mjs";
15
+ } from "./cli/chunk-QI5S5HWB.mjs";
16
16
  import {
17
17
  DEEPLINE_EXTRACTOR_TARGETS,
18
18
  DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS,
@@ -37,16 +37,12 @@ import {
37
37
  RunEventQueryInputError,
38
38
  isStopAllPlayRunsDryRunResult,
39
39
  planCustomerDbQuery
40
- } from "./cli/chunk-ZMNGZ6XS.mjs";
40
+ } from "./cli/chunk-LH5PZKER.mjs";
41
41
  import {
42
42
  legacyRawFromToolResponseRawV2
43
43
  } from "./cli/chunk-FZHMNK6F.mjs";
44
- import "./cli/chunk-LX35AXTN.mjs";
44
+ import "./cli/chunk-5TYLSS4Q.mjs";
45
45
  import "./cli/chunk-PSX3WHIH.mjs";
46
- import {
47
- normalizeTableNamespace,
48
- sha256Hex
49
- } from "./cli/chunk-UBKA33KY.mjs";
50
46
  import {
51
47
  MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG,
52
48
  MONITOR_FLEET_AUTHORING_CONTRACT_EDITION,
@@ -69,28 +65,33 @@ import {
69
65
  import {
70
66
  PROD_URL,
71
67
  resolveConfig
72
- } from "./cli/chunk-V6SCP4B7.mjs";
68
+ } from "./cli/chunk-LFOERUQY.mjs";
73
69
  import {
74
70
  SDK_API_CONTRACT,
75
71
  SDK_VERSION
76
- } from "./cli/chunk-4D3WIZST.mjs";
72
+ } from "./cli/chunk-OTV2UUKW.mjs";
77
73
  import {
78
74
  AuthError,
79
75
  ConfigError,
80
76
  CustomerDbQueryOutcomeUnknownError,
81
77
  RateLimitError,
82
78
  ToolRateLimitError
83
- } from "./cli/chunk-NURW5XH4.mjs";
79
+ } from "./cli/chunk-ASB47RXJ.mjs";
84
80
  import "./cli/chunk-DLIRSHV6.mjs";
85
81
  import {
86
82
  DeeplineError,
83
+ ProviderRejectedError,
87
84
  ProviderTransientError,
88
85
  ToolExecutionError,
89
86
  getProviderUnavailableReason,
90
87
  isProviderUnavailable,
91
88
  isProviderWaterfallUnavailableError
92
- } from "./cli/chunk-JL2OTMSG.mjs";
93
- import "./cli/chunk-2UXDHFSF.mjs";
89
+ } from "./cli/chunk-Z3A2S3QM.mjs";
90
+ import {
91
+ normalizeTableNamespace,
92
+ sha256Hex
93
+ } from "./cli/chunk-2MGZAI54.mjs";
94
+ import "./cli/chunk-GAVZ4EOD.mjs";
94
95
  import "./cli/chunk-WZYKRD7T.mjs";
95
96
  import "./cli/chunk-KRD6H754.mjs";
96
97
 
@@ -1801,6 +1802,13 @@ function preservedSerializedListRows(value) {
1801
1802
  }
1802
1803
 
1803
1804
  // ../play-runtime/query-result-dataset.ts
1805
+ function readQueryResultDatasetResultRef(dataset) {
1806
+ const raw = dataset?.result_ref;
1807
+ if (typeof raw !== "string") return null;
1808
+ const resultRef = raw.trim();
1809
+ return resultRef && resultRef.length <= QUERY_RESULT_DATASET_RESULT_REF_MAX_LENGTH ? resultRef : null;
1810
+ }
1811
+ var QUERY_RESULT_DATASET_RESULT_REF_MAX_LENGTH = 256;
1804
1812
  var QUERY_RESULT_DATASET_PAGE_SIZE = 1e3;
1805
1813
  function isCustomerDbDatasetTool(toolId) {
1806
1814
  return /^(?:customer_db_)?query_customer_db$/.test(toolId);
@@ -2353,6 +2361,7 @@ function attachSdkQueryResultDatasetResult(toolId, result, options) {
2353
2361
  }
2354
2362
  const datasetLimit = finitePositiveInteger(dataset.returned_limit) ?? totalRows;
2355
2363
  const effectiveCount = Math.min(totalRows, datasetLimit);
2364
+ const storedResultRef = readQueryResultDatasetResultRef(dataset);
2356
2365
  const rawRows = rowsFromUnknown(raw?.rows);
2357
2366
  const previewRows = rawRows.slice(0, 25);
2358
2367
  const fetchPage = async (offset, limit) => {
@@ -2365,7 +2374,8 @@ function attachSdkQueryResultDatasetResult(toolId, result, options) {
2365
2374
  limit: datasetLimit,
2366
2375
  offset,
2367
2376
  page_size: Math.min(limit, QUERY_RESULT_DATASET_PAGE_SIZE),
2368
- total_rows: totalRows
2377
+ total_rows: totalRows,
2378
+ ...storedResultRef ? { result_ref: storedResultRef } : {}
2369
2379
  },
2370
2380
  ...isCustomerDbDatasetTool(toolId) ? {
2371
2381
  customer_db_dataset: {
@@ -2701,6 +2711,7 @@ export {
2701
2711
  MONITOR_JOB_STATES,
2702
2712
  PHONE_STATUS_VALUES,
2703
2713
  PROD_URL,
2714
+ ProviderRejectedError,
2704
2715
  ProviderTransientError,
2705
2716
  RateLimitError,
2706
2717
  RunEventQueryInputError,