deepline 0.3.514 → 0.3.516

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 (180) hide show
  1. package/dist/bundling-sources/sdk/src/errors.ts +1 -0
  2. package/dist/bundling-sources/sdk/src/http-core.ts +9 -4
  3. package/dist/bundling-sources/sdk/src/index.ts +1 -0
  4. package/dist/bundling-sources/sdk/src/release.ts +1 -1
  5. package/dist/bundling-sources/shared_libs/play-runtime/context.ts +30 -15
  6. package/dist/bundling-sources/shared_libs/play-runtime/durable-runs-rollout.ts +6 -1
  7. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-pool.ts +71 -1
  8. package/dist/bundling-sources/shared_libs/play-runtime/secret-redaction.ts +20 -7
  9. package/dist/bundling-sources/shared_libs/play-runtime/tool-http-errors.ts +3 -1
  10. package/dist/bundling-sources/shared_libs/plays/tool-execution-error.ts +45 -0
  11. package/dist/bundling-sources/shared_libs/tool-execution-error.ts +45 -0
  12. package/dist/cli/{artifacts-GNFL5LY4.mjs → artifacts-G56FISIE.mjs} +9 -9
  13. package/dist/cli/{artifacts-OZRO4LHT.js → artifacts-KMWS32R5.js} +21 -21
  14. package/dist/cli/auth-6EIEZ3UE.js +43 -0
  15. package/dist/cli/{auth-53EDAX7Y.mjs → auth-RSS7MOBV.mjs} +7 -7
  16. package/dist/cli/{billing-ZMX2V5X3.mjs → billing-2ALO3XEG.mjs} +10 -10
  17. package/dist/cli/{billing-B6V3FELL.js → billing-RCC6WBIZ.js} +93 -93
  18. package/dist/cli/{chunk-753MZFDF.mjs → chunk-2YEFJHAF.mjs} +3 -3
  19. package/dist/cli/{chunk-BBDWIUJA.js → chunk-4IIK6GIY.js} +17 -17
  20. package/dist/cli/{chunk-DMBCJFGY.mjs → chunk-5NU37KME.mjs} +2 -2
  21. package/dist/cli/{chunk-Z5WO6IBV.mjs → chunk-6ADGVZRX.mjs} +21 -6
  22. package/dist/cli/{chunk-RNSHCJME.js → chunk-6Y3DDRRN.js} +30 -30
  23. package/dist/cli/{chunk-NXT52SIV.js → chunk-6ZLL5GDN.js} +2 -2
  24. package/dist/cli/{chunk-QSFAUGFK.js → chunk-72L5HQ3J.js} +5 -5
  25. package/dist/cli/{chunk-DLYWOHO4.mjs → chunk-72MFP7V4.mjs} +1 -1
  26. package/dist/cli/{chunk-MF7ZVWJK.js → chunk-7R2V5Z6O.js} +41 -41
  27. package/dist/cli/{chunk-W3TN352L.mjs → chunk-C2SR3X7Y.mjs} +4 -4
  28. package/dist/cli/{chunk-76M3DL5G.mjs → chunk-C72J6JE3.mjs} +1 -1
  29. package/dist/cli/{chunk-RMRZ4BC4.mjs → chunk-CA24C3XL.mjs} +4 -4
  30. package/dist/cli/{chunk-2RCZCWPO.js → chunk-CKEZXNMV.js} +6 -6
  31. package/dist/cli/{chunk-C24VEYSP.js → chunk-D4OZSC3C.js} +8 -4
  32. package/dist/cli/{chunk-EVTD3ELD.mjs → chunk-E7ZM2ZRD.mjs} +5 -5
  33. package/dist/cli/{chunk-MJIS4XAZ.mjs → chunk-EYWP5JPU.mjs} +4 -4
  34. package/dist/cli/{chunk-TG4IMWAL.js → chunk-FIIBDWAO.js} +55 -55
  35. package/dist/cli/{chunk-7MJYZ33I.mjs → chunk-GJYLC4JB.mjs} +1 -1
  36. package/dist/cli/{chunk-7MBI2OLW.mjs → chunk-H6BSB2YJ.mjs} +1 -1
  37. package/dist/cli/{chunk-N4TR6QRI.mjs → chunk-HT675XNR.mjs} +1 -1
  38. package/dist/cli/{chunk-IZJGOMCW.mjs → chunk-HY6KAW5H.mjs} +5 -5
  39. package/dist/cli/{chunk-ILITNKGM.mjs → chunk-J4VMWSQK.mjs} +7 -7
  40. package/dist/cli/{chunk-TZS4G7CS.js → chunk-JB6FEEDQ.js} +2 -2
  41. package/dist/cli/{chunk-6FYGFIXD.mjs → chunk-JPLEDOEW.mjs} +2 -2
  42. package/dist/cli/{chunk-7ZCXQDOQ.mjs → chunk-LCKAG5RL.mjs} +2 -2
  43. package/dist/cli/{chunk-RVMV4MXO.mjs → chunk-LWUFEX26.mjs} +3 -3
  44. package/dist/cli/{chunk-FPWOEK7G.js → chunk-LZROM6VQ.js} +2 -2
  45. package/dist/cli/{chunk-RLVSWAWB.js → chunk-N6Q5SDGA.js} +62 -51
  46. package/dist/cli/{chunk-A6QCMBGL.js → chunk-NRO3NTVO.js} +5 -5
  47. package/dist/cli/{chunk-VLIDBQYL.js → chunk-P6AADORO.js} +3 -3
  48. package/dist/cli/{chunk-55WBE4UK.js → chunk-PKKSXXZ5.js} +26 -26
  49. package/dist/cli/{chunk-G6PUQQJP.js → chunk-PMS3LQ6B.js} +5 -5
  50. package/dist/cli/{chunk-JC3ABOZP.js → chunk-PPYJXP4Z.js} +38 -23
  51. package/dist/cli/{chunk-6SSISVXD.mjs → chunk-PVVWKOEB.mjs} +8 -7
  52. package/dist/cli/{chunk-DBBLPDXK.mjs → chunk-Q47MAAHI.mjs} +1 -1
  53. package/dist/cli/{chunk-2CTTSNFE.js → chunk-QG3MRMU5.js} +58 -57
  54. package/dist/cli/{chunk-53F6JDQ3.mjs → chunk-QG4LIOGI.mjs} +2 -2
  55. package/dist/cli/{chunk-4QF2K7TM.mjs → chunk-QNHHZ63P.mjs} +1 -1
  56. package/dist/cli/{chunk-A253CMOI.js → chunk-QUSYG3VP.js} +8 -8
  57. package/dist/cli/{chunk-T4NQ2ZOH.js → chunk-QX7WDG4V.js} +11 -11
  58. package/dist/cli/{chunk-MQK5SY5N.js → chunk-RB3OR32I.js} +16 -16
  59. package/dist/cli/{chunk-RFN7OKT2.mjs → chunk-RB5EMAWD.mjs} +1 -1
  60. package/dist/cli/{chunk-WP3ULMRU.js → chunk-RLI6FDQM.js} +6 -6
  61. package/dist/cli/{chunk-TMQUMILM.js → chunk-RVHUW4TN.js} +2 -2
  62. package/dist/cli/{chunk-DIAWYWT5.js → chunk-SQWET4SL.js} +18 -1
  63. package/dist/cli/{chunk-OZDT2CZW.mjs → chunk-STR5LXK4.mjs} +1 -1
  64. package/dist/cli/{chunk-ALJJRZNJ.js → chunk-T2N3B7IQ.js} +8 -8
  65. package/dist/cli/{chunk-OQ4JV3IW.js → chunk-TZNQRKDF.js} +1 -1
  66. package/dist/cli/{chunk-CUMA6DE2.js → chunk-UW5QWTUG.js} +19 -19
  67. package/dist/cli/{chunk-G6A7CGFV.mjs → chunk-V46UBZBJ.mjs} +6 -3
  68. package/dist/cli/{chunk-R5PJ6XZI.js → chunk-VIZJIBI4.js} +10 -10
  69. package/dist/cli/{chunk-Y2RIMVEM.js → chunk-W5I53WQ4.js} +112 -112
  70. package/dist/cli/{chunk-H7L5MS5E.mjs → chunk-WCQ7JGDV.mjs} +4 -4
  71. package/dist/cli/{chunk-7KD4IYLA.js → chunk-WE223LFR.js} +19 -19
  72. package/dist/cli/{chunk-H53YG6QG.mjs → chunk-X2YP36YP.mjs} +1 -1
  73. package/dist/cli/{chunk-LV2DGEJ3.js → chunk-XEQBYK4B.js} +16 -13
  74. package/dist/cli/{chunk-5LBXLQRW.js → chunk-YS7AI7R6.js} +108 -108
  75. package/dist/cli/{chunk-HJ5B67S3.mjs → chunk-YXGTO5XA.mjs} +8 -4
  76. package/dist/cli/{chunk-54IH5U3I.mjs → chunk-Z3KLCDCB.mjs} +23 -12
  77. package/dist/cli/{chunk-6OIRN4PC.mjs → chunk-ZFRN3B2R.mjs} +2 -2
  78. package/dist/cli/{chunk-EO52BKGA.mjs → chunk-ZMCQP4EU.mjs} +11 -11
  79. package/dist/cli/{chunk-HBL4PM5Q.mjs → chunk-ZPGGW27Q.mjs} +17 -0
  80. package/dist/cli/command-docs.js +2 -2
  81. package/dist/cli/command-docs.mjs +1 -1
  82. package/dist/cli/{csv-2BLYUV2G.js → csv-RPR64UBS.js} +15 -15
  83. package/dist/cli/{csv-ONKAMLL4.mjs → csv-YXK5TB47.mjs} +6 -6
  84. package/dist/cli/{db-YKT6LEQ3.js → db-KO3JCGRG.js} +36 -36
  85. package/dist/cli/{db-4GVSGAXL.mjs → db-UQYILAMF.mjs} +9 -9
  86. package/dist/cli/describe-BPX3U2BF.js +50 -0
  87. package/dist/cli/describe-P2OK5X2S.mjs +50 -0
  88. package/dist/cli/describe-core.d.mts +3 -3
  89. package/dist/cli/describe-core.d.ts +3 -3
  90. package/dist/cli/describe-core.js +4 -4
  91. package/dist/cli/describe-core.mjs +3 -3
  92. package/dist/cli/{executions-VFCU5NGH.js → executions-5Z7H7HV3.js} +11 -11
  93. package/dist/cli/{executions-7OSL25KJ.mjs → executions-IQCRQXVA.mjs} +9 -9
  94. package/dist/cli/{feedback-ERTOLEC4.js → feedback-EDZJDARP.js} +12 -12
  95. package/dist/cli/{feedback-RPZELEA5.mjs → feedback-ZO6A4HTV.mjs} +7 -7
  96. package/dist/cli/{git-XKRQZ4A6.mjs → git-OBXSILWM.mjs} +7 -7
  97. package/dist/cli/git-Y34J73QC.js +25 -0
  98. package/dist/cli/index.js +150 -150
  99. package/dist/cli/index.mjs +46 -46
  100. package/dist/cli/{legacy-noops-MZCFS2FQ.mjs → legacy-noops-4UJM3FMN.mjs} +8 -8
  101. package/dist/cli/{legacy-noops-HG3M5HGZ.js → legacy-noops-HKXU2EU6.js} +11 -11
  102. package/dist/cli/{monitors-MESMMU5P.js → monitors-7EP3Q2DX.js} +110 -110
  103. package/dist/cli/{monitors-GBO5XAEZ.mjs → monitors-ZXF2KCW7.mjs} +10 -10
  104. package/dist/cli/{org-DJRNWIPO.mjs → org-EDHCUR6V.mjs} +9 -9
  105. package/dist/cli/{org-EZPREEWH.js → org-GFGOTUWP.js} +75 -75
  106. package/dist/cli/{pages-36BHVOFL.mjs → pages-EGEWMPJN.mjs} +9 -9
  107. package/dist/cli/{pages-ACI7VV6I.js → pages-TLFQQL5S.js} +21 -21
  108. package/dist/cli/{play-SUSVQHX5.mjs → play-NBO3MPDL.mjs} +22 -22
  109. package/dist/cli/{play-KCLLAGWR.js → play-XDHJY5R4.js} +392 -392
  110. package/dist/cli/{providers-MV2YW3J5.mjs → providers-NXJ7WPNH.mjs} +9 -9
  111. package/dist/cli/{providers-YFO3EFLK.js → providers-RU6BGEDM.js} +12 -12
  112. package/dist/cli/{quickstart-MATFTZVQ.js → quickstart-4ZZBMZPF.js} +8 -8
  113. package/dist/cli/{quickstart-KMXU2T3Z.mjs → quickstart-YBNDPNAR.mjs} +6 -6
  114. package/dist/cli/{run-UW5FM64G.js → run-374CTJBV.js} +46 -46
  115. package/dist/cli/{run-YRYVGUCJ.mjs → run-LX52KVZM.mjs} +27 -27
  116. package/dist/cli/{search-WF3Q3I5X.mjs → search-EH6JPV62.mjs} +11 -11
  117. package/dist/cli/search-YS4DHSQC.js +33 -0
  118. package/dist/cli/{search-output-BG743WAM.js → search-output-NATLJOWW.js} +9 -9
  119. package/dist/cli/{search-output-THOAHTCU.mjs → search-output-XIQERUHF.mjs} +7 -7
  120. package/dist/cli/{secrets-EOGBWN44.js → secrets-A3UXDE5V.js} +18 -18
  121. package/dist/cli/{secrets-LM7OTAUE.mjs → secrets-VRJQFUKF.mjs} +9 -9
  122. package/dist/cli/sessions-5TTH5FGZ.mjs +18 -0
  123. package/dist/cli/sessions-EXII5VOV.js +18 -0
  124. package/dist/cli/{settings-OWE3EEG7.js → settings-LX5EGLVT.js} +89 -89
  125. package/dist/cli/{settings-JXTFX5G2.mjs → settings-VRGFTOTJ.mjs} +16 -16
  126. package/dist/cli/{setup-FG37SKMB.mjs → setup-FXP5Y3Y6.mjs} +12 -12
  127. package/dist/cli/{setup-Z5BEQKA7.js → setup-QL4YWKOR.js} +52 -52
  128. package/dist/cli/skills-5L4CYX3V.js +37 -0
  129. package/dist/cli/{skills-UGNCBZTJ.mjs → skills-ET4PMBJE.mjs} +10 -10
  130. package/dist/cli/tools-5V77VIUA.js +57 -0
  131. package/dist/cli/{tools-J3PKLQSL.mjs → tools-WPL3NZAA.mjs} +20 -20
  132. package/dist/cli/update-G5RSSWM5.js +35 -0
  133. package/dist/cli/{update-GGZ2XTMZ.mjs → update-OCAHAKL2.mjs} +12 -12
  134. package/dist/cli/{workflow-AUZCSCZP.js → workflow-CWO3XL4O.js} +20 -20
  135. package/dist/cli/{workflow-C66BBXHH.mjs → workflow-NPZ2RLQG.mjs} +10 -10
  136. package/dist/{client-CmlKSBXd.d.ts → client-CQSPuqxh.d.ts} +1 -1
  137. package/dist/{client-By7bUS8h.d.mts → client-K1g4ab5Y.d.mts} +1 -1
  138. package/dist/{client-core-BZ3tpY_J.d.mts → client-core-BksGf5Gd.d.mts} +1 -1
  139. package/dist/{client-core-BM0mKhgp.d.ts → client-core-BlaqOlQ7.d.ts} +1 -1
  140. package/dist/{compiler-manifest-BeURaD5Y.d.mts → compiler-manifest-BliMS7ax.d.mts} +14 -1
  141. package/dist/{compiler-manifest-BeURaD5Y.d.ts → compiler-manifest-BliMS7ax.d.ts} +14 -1
  142. package/dist/{errors-kBuT4kGK.d.mts → errors-BZ6Zq1cz.d.mts} +1 -1
  143. package/dist/{errors-BoPXPrSy.d.ts → errors-xfNscfS1.d.ts} +1 -1
  144. package/dist/{index-DC7oRAAC.d.mts → index-DbvCg4zg.d.mts} +1 -1
  145. package/dist/{index-D0crdGM1.d.ts → index-FGdQv8J8.d.ts} +1 -1
  146. package/dist/index.d.mts +7 -7
  147. package/dist/index.d.ts +7 -7
  148. package/dist/index.js +13 -13
  149. package/dist/index.mjs +9 -9
  150. package/dist/install-integrity.json +126 -126
  151. package/dist/plays/bundle-play-file.d.mts +3 -3
  152. package/dist/plays/bundle-play-file.d.ts +3 -3
  153. package/dist/plays/bundle-play-file.mjs +1 -1
  154. package/dist/plays/csv-data-input.js +3 -3
  155. package/dist/plays/csv-data-input.mjs +2 -2
  156. package/dist/plays/play-description.d.mts +2 -2
  157. package/dist/plays/play-description.d.ts +2 -2
  158. package/dist/plays/run-request.d.mts +2 -2
  159. package/dist/plays/run-request.d.ts +2 -2
  160. package/dist/plays/run-request.js +3 -3
  161. package/dist/plays/run-request.mjs +2 -2
  162. package/dist/release.d.mts +1 -1
  163. package/dist/release.d.ts +1 -1
  164. package/dist/release.js +2 -2
  165. package/dist/release.mjs +1 -1
  166. package/dist/server.d.mts +4 -4
  167. package/dist/server.d.ts +4 -4
  168. package/dist/server.js +12 -12
  169. package/dist/server.mjs +6 -6
  170. package/package.json +1 -1
  171. package/dist/cli/auth-SM5GLO45.js +0 -43
  172. package/dist/cli/describe-KPGQP4LH.js +0 -50
  173. package/dist/cli/describe-PRT2WQMS.mjs +0 -50
  174. package/dist/cli/git-U353JURQ.js +0 -25
  175. package/dist/cli/search-4ZQOFG7G.js +0 -33
  176. package/dist/cli/sessions-GDSJ72XI.js +0 -18
  177. package/dist/cli/sessions-SP2JL27H.mjs +0 -18
  178. package/dist/cli/skills-SIX5OTNX.js +0 -37
  179. package/dist/cli/tools-EZOV37MQ.js +0 -57
  180. package/dist/cli/update-ISU7YN34.js +0 -35
@@ -20,7 +20,7 @@ var _chunkE4CABWXLjs = require('./chunk-E4CABWXL.js');
20
20
 
21
21
 
22
22
 
23
- var _chunkRNSHCJMEjs = require('./chunk-RNSHCJME.js');
23
+ var _chunk6Y3DDRRNjs = require('./chunk-6Y3DDRRN.js');
24
24
 
25
25
 
26
26
 
@@ -31,16 +31,16 @@ var _chunkNMU3VR5Ujs = require('./chunk-NMU3VR5U.js');
31
31
 
32
32
 
33
33
 
34
- var _chunk2CTTSNFEjs = require('./chunk-2CTTSNFE.js');
34
+ var _chunkQG3MRMU5js = require('./chunk-QG3MRMU5.js');
35
35
 
36
36
 
37
- var _chunkALJJRZNJjs = require('./chunk-ALJJRZNJ.js');
37
+ var _chunkT2N3B7IQjs = require('./chunk-T2N3B7IQ.js');
38
38
 
39
39
 
40
40
 
41
41
 
42
42
 
43
- var _chunkDIAWYWT5js = require('./chunk-DIAWYWT5.js');
43
+ var _chunkSQWET4SLjs = require('./chunk-SQWET4SL.js');
44
44
 
45
45
  // src/pagination.ts
46
46
  async function* iterateCursorPages(fetchPage) {
@@ -74,7 +74,7 @@ function requireBillingIdempotencyKey(value) {
74
74
  }
75
75
  }
76
76
  if (!valid) {
77
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
77
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
78
78
  "Billing idempotencyKey must contain 1\u2013200 characters with no leading or trailing whitespace and be valid HTTP header text.",
79
79
  void 0,
80
80
  "INVALID_BILLING_IDEMPOTENCY_KEY"
@@ -86,23 +86,23 @@ function requireBillingIdempotencyKey(value) {
86
86
  // src/db/query.ts
87
87
  function planCustomerDbQuery(input, maxRetries = 3) {
88
88
  if (typeof input.sql !== "string" || !input.sql.trim())
89
- throw new (0, _chunkDIAWYWT5js.DeeplineError)("sql must not be empty.", 400, "INVALID_SQL");
89
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)("sql must not be empty.", 400, "INVALID_SQL");
90
90
  if (input.operationKey !== void 0 && typeof input.operationKey !== "string")
91
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
91
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
92
92
  "operationKey must be a string containing 1\u2013512 characters.",
93
93
  400,
94
94
  "INVALID_OPERATION_KEY"
95
95
  );
96
96
  const operationKey = input.operationKey;
97
97
  if (operationKey !== void 0 && (!operationKey.trim() || operationKey.length > 512)) {
98
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
98
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
99
99
  "operationKey must contain 1\u2013512 characters.",
100
100
  400,
101
101
  "INVALID_OPERATION_KEY"
102
102
  );
103
103
  }
104
104
  if (input.maxRows !== void 0 && (!Number.isSafeInteger(input.maxRows) || input.maxRows < 1 || input.maxRows > 1e3)) {
105
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
105
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
106
106
  "maxRows must be a whole number from 1 to 1000.",
107
107
  400,
108
108
  "INVALID_MAX_ROWS"
@@ -144,10 +144,10 @@ async function queryCustomerDatabase(http, input, maxRetries) {
144
144
  }
145
145
  );
146
146
  } catch (error) {
147
- if (error instanceof _chunkDIAWYWT5js.DeeplineError && (_optionalChain([error, 'access', _ => _.code, 'optionalAccess', _2 => _2.startsWith, 'call', _3 => _3("NETWORK_")]) || // Older API readers return PostgreSQL errors as HTTP 400, including
147
+ if (error instanceof _chunkSQWET4SLjs.DeeplineError && (_optionalChain([error, 'access', _ => _.code, 'optionalAccess', _2 => _2.startsWith, 'call', _3 => _3("NETWORK_")]) || // Older API readers return PostgreSQL errors as HTTP 400, including
148
148
  // lost connections and explicitly unknown transaction resolution.
149
149
  /^08[A-Z0-9]{3}$/.test(_nullishCoalesce(error.code, () => ( ""))) || ["57P01", "57P02", "57P03"].includes(_nullishCoalesce(error.code, () => ( ""))) || error.statusCode === 408 || (_nullishCoalesce(error.statusCode, () => ( 0))) >= 500)) {
150
- throw new (0, _chunkALJJRZNJjs.CustomerDbQueryOutcomeUnknownError)(
150
+ throw new (0, _chunkT2N3B7IQjs.CustomerDbQueryOutcomeUnknownError)(
151
151
  error,
152
152
  plan.request.body.operation_key
153
153
  );
@@ -155,8 +155,8 @@ async function queryCustomerDatabase(http, input, maxRetries) {
155
155
  throw error;
156
156
  }
157
157
  if (!result || typeof result !== "object" || Array.isArray(result) || typeof result.command !== "string" || !Array.isArray(result.columns) || !Array.isArray(result.rows) || typeof result.truncated !== "boolean" || result.row_count !== null && (!Number.isSafeInteger(result.row_count) || result.row_count < 0) || !Number.isSafeInteger(result.row_count_returned) || result.row_count_returned < 0) {
158
- throw new (0, _chunkALJJRZNJjs.CustomerDbQueryOutcomeUnknownError)(
159
- new (0, _chunkDIAWYWT5js.DeeplineError)(
158
+ throw new (0, _chunkT2N3B7IQjs.CustomerDbQueryOutcomeUnknownError)(
159
+ new (0, _chunkSQWET4SLjs.DeeplineError)(
160
160
  "The SQL response did not contain a valid result.",
161
161
  200,
162
162
  "CUSTOMER_DB_QUERY_RESPONSE_INVALID"
@@ -166,8 +166,8 @@ async function queryCustomerDatabase(http, input, maxRetries) {
166
166
  }
167
167
  const operation = result.operation;
168
168
  if (input.operationKey !== void 0 && (!operation || operation.operation_key !== input.operationKey || !Number.isSafeInteger(operation.completed_at_ms) || operation.completed_at_ms < 0 || !["executed", "operation_recovery"].includes(operation.source))) {
169
- throw new (0, _chunkALJJRZNJjs.CustomerDbQueryOutcomeUnknownError)(
170
- new (0, _chunkDIAWYWT5js.DeeplineError)(
169
+ throw new (0, _chunkT2N3B7IQjs.CustomerDbQueryOutcomeUnknownError)(
170
+ new (0, _chunkSQWET4SLjs.DeeplineError)(
171
171
  "The server did not confirm the original atomic SQL operation.",
172
172
  200,
173
173
  "CUSTOMER_DB_OPERATION_ACK_INVALID"
@@ -424,7 +424,7 @@ function usesExtendedBetterContactLauncherBudget(toolId) {
424
424
  var CLI_INVOCATION_ID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;
425
425
  function validateCliInvocationId(value) {
426
426
  if (!CLI_INVOCATION_ID_PATTERN.test(value)) {
427
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
427
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
428
428
  "CLI invocation IDs must be UUID v4 values.",
429
429
  void 0,
430
430
  "CLI_INVOCATION_ID_INVALID"
@@ -440,7 +440,7 @@ var RAW_V2_EXECUTE_RESPONSE_CONTRACT = _chunkE4CABWXLjs.RAW_V2_TOOL_RESPONSE_CON
440
440
  var DEFAULT_EXECUTION_RECOVERY_TIMEOUT_MS = 15 * 60 * 1e3;
441
441
  function validateExecutionIdempotencyKey(key) {
442
442
  if (typeof key !== "string" || key.length < 1 || key.length > 200 || !/^[A-Za-z0-9._:-]+$/.test(key)) {
443
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
443
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
444
444
  "Execution idempotency keys must be 1\u2013200 ASCII letters, digits, dots, underscores, colons, or hyphens.",
445
445
  void 0,
446
446
  "IDEMPOTENCY_KEY_INVALID"
@@ -453,20 +453,20 @@ function getExecutionRecoveryState(value) {
453
453
  return state === "running" || state === "completed" || state === "outcome_unknown" ? state : null;
454
454
  }
455
455
  function isRecoverableExecutionAttemptError(error) {
456
- if (error instanceof _chunkDIAWYWT5js.ToolExecutionError) {
456
+ if (error instanceof _chunkSQWET4SLjs.ToolExecutionError) {
457
457
  return error.code === "EXECUTION_IN_PROGRESS" || error.origin === "deepline" && error.category === "network" && error.networkScope === "client_to_deepline";
458
458
  }
459
- return error instanceof _chunkDIAWYWT5js.DeeplineError && (error.code === "EXECUTION_IN_PROGRESS" || _optionalChain([error, 'access', _9 => _9.code, 'optionalAccess', _10 => _10.startsWith, 'call', _11 => _11("NETWORK_")]) === true && error.statusCode === void 0);
459
+ return error instanceof _chunkSQWET4SLjs.DeeplineError && (error.code === "EXECUTION_IN_PROGRESS" || _optionalChain([error, 'access', _9 => _9.code, 'optionalAccess', _10 => _10.startsWith, 'call', _11 => _11("NETWORK_")]) === true && error.statusCode === void 0);
460
460
  }
461
461
  function isRecoverableExecutionLookupError(error) {
462
462
  if (isRecoverableExecutionAttemptError(error)) return true;
463
- return error instanceof _chunkDIAWYWT5js.DeeplineError && (error.statusCode === 429 || error.statusCode !== void 0 && error.statusCode >= 500);
463
+ return error instanceof _chunkSQWET4SLjs.DeeplineError && (error.statusCode === 429 || error.statusCode !== void 0 && error.statusCode >= 500);
464
464
  }
465
465
  function timeoutWithinRecoveryBudget(requestTimeoutMs, defaultRequestTimeoutMs, remainingMs) {
466
466
  return Math.min(_nullishCoalesce(requestTimeoutMs, () => ( defaultRequestTimeoutMs)), remainingMs);
467
467
  }
468
468
  function executionRecoveryError(input) {
469
- return new (0, _chunkDIAWYWT5js.ToolExecutionError)(input.message, {
469
+ return new (0, _chunkSQWET4SLjs.ToolExecutionError)(input.message, {
470
470
  toolId: input.toolId,
471
471
  provider: null,
472
472
  operation: input.toolId,
@@ -574,7 +574,7 @@ var ToolCalls = class {
574
574
  if (idempotencyKey !== void 0) {
575
575
  validateExecutionIdempotencyKey(idempotencyKey);
576
576
  if (_optionalChain([options, 'optionalAccess', _16 => _16.recoveryTimeoutMs]) !== void 0 && (!Number.isFinite(options.recoveryTimeoutMs) || options.recoveryTimeoutMs < 0)) {
577
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
577
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
578
578
  "recoveryTimeoutMs must be a finite, non-negative number.",
579
579
  void 0,
580
580
  "IDEMPOTENCY_KEY_INVALID"
@@ -591,8 +591,8 @@ var ToolCalls = class {
591
591
  const headers = {
592
592
  [EXECUTE_RESPONSE_CONTRACT_HEADER]: RAW_V2_EXECUTE_RESPONSE_CONTRACT,
593
593
  ...isApifySync ? { "X-Deepline-Apify-Sync-Response-Budget": "extended-v1" } : {},
594
- [_chunkDIAWYWT5js.TOOL_EXECUTION_ERROR_SCHEMA_HEADER]: String(
595
- _chunkDIAWYWT5js.TOOL_EXECUTION_ERROR_SCHEMA_VERSION
594
+ [_chunkSQWET4SLjs.TOOL_EXECUTION_ERROR_SCHEMA_HEADER]: String(
595
+ _chunkSQWET4SLjs.TOOL_EXECUTION_ERROR_SCHEMA_VERSION
596
596
  ),
597
597
  ..._optionalChain([options, 'optionalAccess', _20 => _20.includeToolMetadata]) ? { [INCLUDE_TOOL_METADATA_HEADER]: "true" } : {},
598
598
  [EXECUTE_RESPONSE_INTENT_HEADER]: _nullishCoalesce(_optionalChain([options, 'optionalAccess', _21 => _21.responseIntent]), () => ( "raw")),
@@ -605,7 +605,7 @@ var ToolCalls = class {
605
605
  if (!lastResponse) return;
606
606
  if (failure) {
607
607
  const { error } = failure;
608
- if (isRecoverableExecutionAttemptError(error) || !(error instanceof _chunkDIAWYWT5js.DeeplineError) || error.statusCode === void 0 || error.statusCode !== lastResponse.httpStatus || error.code === "EXECUTION_OUTCOME_UNKNOWN")
608
+ if (isRecoverableExecutionAttemptError(error) || !(error instanceof _chunkSQWET4SLjs.DeeplineError) || error.statusCode === void 0 || error.statusCode !== lastResponse.httpStatus || error.code === "EXECUTION_OUTCOME_UNKNOWN")
609
609
  return;
610
610
  }
611
611
  const body = lastResponse.body;
@@ -652,7 +652,7 @@ var ToolCalls = class {
652
652
  idempotencyKey,
653
653
  onResponse: (response2) => {
654
654
  lastResponse = null;
655
- atomicToolsSupported = response2.headers.get(_chunk2CTTSNFEjs.ATOMIC_TOOL_EXECUTE_SUPPORTED_HEADER) === "true";
655
+ atomicToolsSupported = response2.headers.get(_chunkQG3MRMU5js.ATOMIC_TOOL_EXECUTE_SUPPORTED_HEADER) === "true";
656
656
  recoverySupported = response2.headers.get("X-Deepline-Idempotency-Supported") === "true";
657
657
  if (_optionalChain([options, 'optionalAccess', _30 => _30.onServerTiming])) {
658
658
  try {
@@ -675,8 +675,8 @@ var ToolCalls = class {
675
675
  return await post();
676
676
  } catch (error) {
677
677
  if (atomicToolOnly) {
678
- if (!atomicToolsSupported && !recoverySupported && !(error instanceof _chunkDIAWYWT5js.ToolExecutionError) && error instanceof _chunkDIAWYWT5js.DeeplineError && (error.statusCode === 404 || error.statusCode === 405)) {
679
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
678
+ if (!atomicToolsSupported && !recoverySupported && !(error instanceof _chunkSQWET4SLjs.ToolExecutionError) && error instanceof _chunkSQWET4SLjs.DeeplineError && (error.statusCode === 404 || error.statusCode === 405)) {
679
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
680
680
  "This server does not support atomic tool execution.",
681
681
  error.statusCode,
682
682
  "ATOMIC_TOOL_EXECUTE_UNSUPPORTED"
@@ -684,7 +684,7 @@ var ToolCalls = class {
684
684
  }
685
685
  throw error;
686
686
  }
687
- if (useLegacyEndpoint || recoverySupported || !(error instanceof _chunkDIAWYWT5js.DeeplineError) || error.statusCode !== 404 && error.statusCode !== 405)
687
+ if (useLegacyEndpoint || recoverySupported || !(error instanceof _chunkSQWET4SLjs.DeeplineError) || error.statusCode !== 404 && error.statusCode !== 405)
688
688
  throw error;
689
689
  lastResponse = null;
690
690
  await this.lookupExecutionByKey(
@@ -773,7 +773,7 @@ var ToolCalls = class {
773
773
  recoveryDeadline = Date.now() + recoveryTimeoutMs;
774
774
  }
775
775
  } catch (error) {
776
- if (idempotencyKey && error instanceof _chunkDIAWYWT5js.DeeplineError && error.code === "EXECUTION_OUTCOME_UNKNOWN") {
776
+ if (idempotencyKey && error instanceof _chunkSQWET4SLjs.DeeplineError && error.code === "EXECUTION_OUTCOME_UNKNOWN") {
777
777
  throw executionRecoveryError({
778
778
  toolId,
779
779
  idempotencyKey,
@@ -808,7 +808,7 @@ var ToolCalls = class {
808
808
  validateExecutionIdempotencyKey(idempotencyKey);
809
809
  const result = await this.lookupExecutionByKey(idempotencyKey);
810
810
  if (!result) {
811
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
811
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
812
812
  `No execution exists for idempotency key ${idempotencyKey}.`,
813
813
  404,
814
814
  "EXECUTION_NOT_FOUND"
@@ -834,7 +834,7 @@ var ToolCalls = class {
834
834
  }
835
835
  );
836
836
  if (!supported) {
837
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
837
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
838
838
  "This Deepline server does not support recoverable tool executions; no tool was dispatched.",
839
839
  422,
840
840
  "IDEMPOTENCY_NOT_SUPPORTED"
@@ -977,7 +977,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
977
977
  if (request.runtime !== void 0) {
978
978
  const runtime = normalizePlayRunRuntimeSelection(request.runtime);
979
979
  if (!runtime) {
980
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
980
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
981
981
  'runtime must be { environment: "preview", namespace, backend?: "daytona" | "modal", sandboxPlacementPolicy?: "policy_name@1" } with namespace matching ^[a-z][a-z0-9-]{0,30}$, or { environment: "native", sandboxPlacementPolicy: "policy_name@1" }.',
982
982
  void 0,
983
983
  "INVALID_RUNTIME_SELECTION"
@@ -1002,7 +1002,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
1002
1002
  present.push("DEEPLINE_RUNTIME_GATEWAY_PROFILE");
1003
1003
  }
1004
1004
  const isPlural = present.length > 1;
1005
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1005
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1006
1006
  [
1007
1007
  `Incomplete play runtime selection: ${present.join(" and ")} ${isPlural ? "are" : "is"} set but DEEPLINE_RUNTIME_ENVIRONMENT is not.`,
1008
1008
  "Preview routing requires DEEPLINE_RUNTIME_ENVIRONMENT=preview together with DEEPLINE_RUNTIME_NAMESPACE; the token alone authorizes nothing.",
@@ -1017,7 +1017,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
1017
1017
  }
1018
1018
  const selectedGatewayProfile2 = configuredGatewayProfile ? normalizeRuntimeGatewayProfileId(configuredGatewayProfile) : void 0;
1019
1019
  if (configuredGatewayProfile && !selectedGatewayProfile2) {
1020
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1020
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1021
1021
  `DEEPLINE_RUNTIME_GATEWAY_PROFILE must be a supported versioned gateway profile id such as vercel_app@1. Received "${configuredGatewayProfile}".`,
1022
1022
  void 0,
1023
1023
  "INVALID_RUNTIME_GATEWAY_PROFILE"
@@ -1027,7 +1027,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
1027
1027
  if (configured === "native") {
1028
1028
  const sandboxPlacementPolicy = configuredPlacementPolicy ? normalizePlayRuntimeSandboxPlacementPolicy(configuredPlacementPolicy) : void 0;
1029
1029
  if (configuredNamespace || configuredPlacementPolicy && !sandboxPlacementPolicy || !sandboxPlacementPolicy && !selectedGatewayProfile2) {
1030
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1030
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1031
1031
  "DEEPLINE_RUNTIME_ENVIRONMENT=native requires DEEPLINE_RUNTIME_SANDBOX_PLACEMENT_POLICY (such as modal_only@1) and/or DEEPLINE_RUNTIME_GATEWAY_PROFILE (such as vercel_app@1), and no DEEPLINE_RUNTIME_NAMESPACE.",
1032
1032
  void 0,
1033
1033
  "INVALID_RUNTIME_ENVIRONMENT"
@@ -1044,7 +1044,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
1044
1044
  }
1045
1045
  const environment = normalizePlayRuntimeEnvironment(configured);
1046
1046
  if (!environment) {
1047
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1047
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1048
1048
  `DEEPLINE_RUNTIME_ENVIRONMENT must be preview or native. Received "${configured}". Omit it to use the app-native runtime.`,
1049
1049
  void 0,
1050
1050
  "INVALID_RUNTIME_ENVIRONMENT"
@@ -1052,7 +1052,7 @@ function resolvePlayRunRuntimeSelection(request, env) {
1052
1052
  }
1053
1053
  const namespace = normalizePlayRuntimeNamespace(configuredNamespace);
1054
1054
  if (!namespace) {
1055
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1055
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1056
1056
  "DEEPLINE_RUNTIME_NAMESPACE is required for preview and must match ^[a-z][a-z0-9-]{0,30}$.",
1057
1057
  void 0,
1058
1058
  "INVALID_RUNTIME_NAMESPACE"
@@ -1061,14 +1061,14 @@ function resolvePlayRunRuntimeSelection(request, env) {
1061
1061
  const configuredBackendValue = _optionalChain([env, 'access', _49 => _49.DEEPLINE_PLAY_RUNNER_BACKEND, 'optionalAccess', _50 => _50.trim, 'call', _51 => _51()]);
1062
1062
  const configuredBackend = configuredBackendValue === "daytona" || configuredBackendValue === "modal" ? configuredBackendValue : void 0;
1063
1063
  if (configuredBackendValue && !configuredBackend) {
1064
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1064
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1065
1065
  `DEEPLINE_PLAY_RUNNER_BACKEND must be daytona or modal for preview runtime selection. Received "${configuredBackendValue}".`,
1066
1066
  void 0,
1067
1067
  "INVALID_RUNTIME_BACKEND"
1068
1068
  );
1069
1069
  }
1070
1070
  if (configuredPlacementPolicy && !normalizePlayRuntimeSandboxPlacementPolicy(configuredPlacementPolicy)) {
1071
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1071
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1072
1072
  `DEEPLINE_RUNTIME_SANDBOX_PLACEMENT_POLICY must be a versioned placement policy id such as daytona_only@1. Received "${configuredPlacementPolicy}".`,
1073
1073
  void 0,
1074
1074
  "INVALID_RUNTIME_SANDBOX_PLACEMENT_POLICY"
@@ -1099,7 +1099,7 @@ function runtimeSelectionHeaders(runtime, env) {
1099
1099
  if (!runtime || runtime.environment === "native") return void 0;
1100
1100
  const token = _optionalChain([env, 'access', _52 => _52.DEEPLINE_RUNTIME_ENVIRONMENT_TOKEN, 'optionalAccess', _53 => _53.trim, 'call', _54 => _54()]);
1101
1101
  if (!token) {
1102
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1102
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1103
1103
  "DEEPLINE_RUNTIME_ENVIRONMENT_TOKEN is required for explicit preview runtime selection.",
1104
1104
  void 0,
1105
1105
  "RUNTIME_ENVIRONMENT_TOKEN_REQUIRED"
@@ -1107,15 +1107,15 @@ function runtimeSelectionHeaders(runtime, env) {
1107
1107
  }
1108
1108
  const receivers = _optionalChain([env, 'access', _55 => _55.DEEPLINE_RUNTIME_RETAINED_PIPELINE_RECEIVERS, 'optionalAccess', _56 => _56.trim, 'call', _57 => _57()]);
1109
1109
  return {
1110
- [_chunk2CTTSNFEjs.RUNTIME_ENVIRONMENT_TOKEN_HEADER]: token,
1111
- ...receivers ? { [_chunk2CTTSNFEjs.RETAINED_PIPELINE_RECEIVERS_HEADER]: receivers } : {}
1110
+ [_chunkQG3MRMU5js.RUNTIME_ENVIRONMENT_TOKEN_HEADER]: token,
1111
+ ...receivers ? { [_chunkQG3MRMU5js.RETAINED_PIPELINE_RECEIVERS_HEADER]: receivers } : {}
1112
1112
  };
1113
1113
  }
1114
1114
  function normalizeTestPolicyOverrides(value, source) {
1115
1115
  if (value && typeof value === "object" && !Array.isArray(value)) {
1116
1116
  return value;
1117
1117
  }
1118
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1118
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1119
1119
  `${source} must be a JSON object.`,
1120
1120
  void 0,
1121
1121
  "INVALID_TEST_POLICY_OVERRIDES"
@@ -1130,7 +1130,7 @@ function parseEnvTestPolicyOverrides(env) {
1130
1130
  parsed = JSON.parse(trimmed);
1131
1131
  } catch (error) {
1132
1132
  const detail = error instanceof Error ? ` ${error.message}` : "";
1133
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
1133
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
1134
1134
  `DEEPLINE_TEST_POLICY_OVERRIDES must be valid JSON.${detail}`,
1135
1135
  void 0,
1136
1136
  "INVALID_TEST_POLICY_OVERRIDES"
@@ -1142,10 +1142,10 @@ function isRecord2(value) {
1142
1142
  return Boolean(value && typeof value === "object" && !Array.isArray(value));
1143
1143
  }
1144
1144
  function normalizePlayStatus(raw) {
1145
- const runPackage = _chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, raw) ? raw : _chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, raw.package) ? raw.package : null;
1145
+ const runPackage = _chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, raw) ? raw : _chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, raw.package) ? raw.package : null;
1146
1146
  const packageRun = _optionalChain([runPackage, 'optionalAccess', _60 => _60.run]);
1147
1147
  const rawStatus = typeof raw.status === "string" ? raw.status : typeof _optionalChain([packageRun, 'optionalAccess', _61 => _61.status]) === "string" ? packageRun.status : null;
1148
- const status = _chunkRNSHCJMEjs.decodePlayRunPublicStatus.call(void 0, rawStatus);
1148
+ const status = _chunk6Y3DDRRNjs.decodePlayRunPublicStatus.call(void 0, rawStatus);
1149
1149
  if (!status) {
1150
1150
  throw new Error(
1151
1151
  `Invalid play run lifecycle status in API response: ${JSON.stringify(rawStatus)}.`
@@ -1176,10 +1176,10 @@ var PlayClient = class {
1176
1176
  async startPlayRun(request, options) {
1177
1177
  const resolved = resolveStartPlayRunRequest(request, this.environment);
1178
1178
  const headers = runtimeSelectionHeaders(resolved.runtime, this.environment);
1179
- return _chunkRNSHCJMEjs.startPlayRun.call(void 0,
1179
+ return _chunk6Y3DDRRNjs.startPlayRun.call(void 0,
1180
1180
  this.http,
1181
1181
  resolved.request,
1182
- _optionalChain([options, 'optionalAccess', _65 => _65.cliAdmission]) ? { ...headers, "X-Deepline-API-Major": String(_chunk2CTTSNFEjs.SDK_API_MAJOR) } : headers,
1182
+ _optionalChain([options, 'optionalAccess', _65 => _65.cliAdmission]) ? { ...headers, "X-Deepline-API-Major": String(_chunkQG3MRMU5js.SDK_API_MAJOR) } : headers,
1183
1183
  options
1184
1184
  );
1185
1185
  }
@@ -1453,13 +1453,13 @@ function stripLeadingTimestamp(line) {
1453
1453
 
1454
1454
  // src/runs/read-errors.ts
1455
1455
  function isTransientPlayRunReadError(error) {
1456
- if (error instanceof _chunkDIAWYWT5js.DeeplineError && error.code === "PLAY_START_OUTCOME_UNKNOWN") {
1456
+ if (error instanceof _chunkSQWET4SLjs.DeeplineError && error.code === "PLAY_START_OUTCOME_UNKNOWN") {
1457
1457
  return false;
1458
1458
  }
1459
- if (error instanceof _chunkDIAWYWT5js.DeeplineError && error.code === "PLAY_STREAM_NETWORK_ABORTED") {
1459
+ if (error instanceof _chunkSQWET4SLjs.DeeplineError && error.code === "PLAY_STREAM_NETWORK_ABORTED") {
1460
1460
  return true;
1461
1461
  }
1462
- if (error instanceof _chunkDIAWYWT5js.DeeplineError && typeof error.statusCode === "number") {
1462
+ if (error instanceof _chunkSQWET4SLjs.DeeplineError && typeof error.statusCode === "number") {
1463
1463
  return error.statusCode >= 500 && error.statusCode < 600;
1464
1464
  }
1465
1465
  const text = error instanceof Error ? error.message : String(error);
@@ -2729,7 +2729,7 @@ var TERMINAL_STATUS_BY_EVENT_TYPE = {
2729
2729
 
2730
2730
  // ../play-runtime/run-snapshot-stream.ts
2731
2731
  function isTerminalPlayRunLiveStatus(status) {
2732
- return _chunkRNSHCJMEjs.isTerminalPlayRunLifecycleStatus.call(void 0, status);
2732
+ return _chunk6Y3DDRRNjs.isTerminalPlayRunLifecycleStatus.call(void 0, status);
2733
2733
  }
2734
2734
  function makeRunStreamEvent(input) {
2735
2735
  return {
@@ -3177,7 +3177,7 @@ async function* watchRunEvents(options) {
3177
3177
 
3178
3178
  // src/client-core.ts
3179
3179
  function invalidToolDiscoveryResponse() {
3180
- return new (0, _chunkDIAWYWT5js.DeeplineError)(
3180
+ return new (0, _chunkSQWET4SLjs.DeeplineError)(
3181
3181
  "The server returned an invalid tool discovery response.",
3182
3182
  502,
3183
3183
  "INVALID_TOOL_DISCOVERY_RESPONSE"
@@ -3254,19 +3254,19 @@ function isolatedCiRuntimeEventReadHeaders(env) {
3254
3254
  }
3255
3255
  const token = _optionalChain([env, 'access', _137 => _137.DEEPLINE_INTERNAL_TOKEN, 'optionalAccess', _138 => _138.trim, 'call', _139 => _139()]);
3256
3256
  if (!token) {
3257
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
3257
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
3258
3258
  "DEEPLINE_INTERNAL_TOKEN is required for isolated CI runtime event reads.",
3259
3259
  void 0,
3260
3260
  "RUNTIME_EVENT_INTERNAL_TOKEN_REQUIRED"
3261
3261
  );
3262
3262
  }
3263
- return { [_chunk2CTTSNFEjs.COORDINATOR_INTERNAL_TOKEN_HEADER]: token };
3263
+ return { [_chunkQG3MRMU5js.COORDINATOR_INTERNAL_TOKEN_HEADER]: token };
3264
3264
  }
3265
3265
  function sleep(ms) {
3266
3266
  return new Promise((resolve) => setTimeout(resolve, ms));
3267
3267
  }
3268
3268
  function isTransientCompileManifestError(error) {
3269
- if (error instanceof _chunkDIAWYWT5js.DeeplineError && typeof error.statusCode === "number") {
3269
+ if (error instanceof _chunkSQWET4SLjs.DeeplineError && typeof error.statusCode === "number") {
3270
3270
  return error.statusCode === 408 || error.statusCode === 425 || error.statusCode === 499 || error.statusCode >= 500 && error.statusCode < 600;
3271
3271
  }
3272
3272
  const message = error instanceof Error ? error.message : String(error);
@@ -3277,7 +3277,7 @@ function isTransientCompileManifestError(error) {
3277
3277
  function requireCompileManifestResponse(response, playName) {
3278
3278
  const compilerManifest = _optionalChain([response, 'optionalAccess', _140 => _140.compilerManifest]);
3279
3279
  if (!compilerManifest || typeof compilerManifest !== "object" || Array.isArray(compilerManifest)) {
3280
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
3280
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
3281
3281
  `Compile manifest response did not include compilerManifest for ${playName}.`,
3282
3282
  502,
3283
3283
  "API_RESPONSE_INVALID",
@@ -3391,7 +3391,7 @@ function playLiveRunStatus(event) {
3391
3391
  return null;
3392
3392
  }
3393
3393
  const payload = getPlayLiveEventPayload(event);
3394
- return _nullishCoalesce(_chunkRNSHCJMEjs.decodePlayRunPublicStatus.call(void 0, payload.status), () => ( (_chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, payload) ? _chunkRNSHCJMEjs.decodePlayRunPublicStatus.call(void 0, payload.run.status) : null)));
3394
+ return _nullishCoalesce(_chunk6Y3DDRRNjs.decodePlayRunPublicStatus.call(void 0, payload.status), () => ( (_chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, payload) ? _chunk6Y3DDRRNjs.decodePlayRunPublicStatus.call(void 0, payload.run.status) : null)));
3395
3395
  }
3396
3396
  function appendPlayLiveLogLines(state, payload) {
3397
3397
  const lines = readStringArray(payload.lines);
@@ -3423,7 +3423,7 @@ function updatePlayLiveStatusState(state, event) {
3423
3423
  if (event.type !== "play.run.snapshot" && event.type !== "play.run.status" && event.type !== "play.run.final_status") {
3424
3424
  return null;
3425
3425
  }
3426
- const runId = typeof payload.runId === "string" && payload.runId ? payload.runId : _chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, payload) ? payload.run.id : state.runId;
3426
+ const runId = typeof payload.runId === "string" && payload.runId ? payload.runId : _chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, payload) ? payload.run.id : state.runId;
3427
3427
  const status = _nullishCoalesce(playLiveRunStatus(event), () => ( state.status));
3428
3428
  const progressPayload = isRecord3(payload.progress) ? payload.progress : {};
3429
3429
  if (event.type === "play.run.final_status" && state.logs.length === 0 && state.lastLogSeq === 0) {
@@ -3436,7 +3436,7 @@ function updatePlayLiveStatusState(state, event) {
3436
3436
  }
3437
3437
  if ("result" in payload) {
3438
3438
  state.result = payload.result;
3439
- } else if (_chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, payload)) {
3439
+ } else if (_chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, payload)) {
3440
3440
  state.result = payload;
3441
3441
  }
3442
3442
  if (typeof payload.error === "string" && payload.error.trim()) {
@@ -3449,7 +3449,7 @@ function updatePlayLiveStatusState(state, event) {
3449
3449
  ...payload,
3450
3450
  runId,
3451
3451
  status,
3452
- ..._chunkRNSHCJMEjs.isPlayRunPackage.call(void 0, payload) ? { package: payload, outputs: payload.outputs } : {},
3452
+ ..._chunk6Y3DDRRNjs.isPlayRunPackage.call(void 0, payload) ? { package: payload, outputs: payload.outputs } : {},
3453
3453
  progress: {
3454
3454
  ...progressRecord,
3455
3455
  status: typeof progressRecord.status === "string" ? progressRecord.status : status,
@@ -3903,7 +3903,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
3903
3903
  async listToolsInCategory(category, options) {
3904
3904
  const normalizedCategory = category.trim();
3905
3905
  if (!normalizedCategory || category.includes(",")) {
3906
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
3906
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
3907
3907
  "Provide one non-empty tool category.",
3908
3908
  400,
3909
3909
  "INVALID_TOOL_CATEGORY"
@@ -4137,7 +4137,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4137
4137
  */
4138
4138
  async preparePlayRunAdmission(request, options) {
4139
4139
  const resolved = resolveStartPlayRunRequest(request, this.environment);
4140
- const prepared = await _chunkRNSHCJMEjs.preparePlayRunAdmission.call(void 0,
4140
+ const prepared = await _chunk6Y3DDRRNjs.preparePlayRunAdmission.call(void 0,
4141
4141
  this.http,
4142
4142
  resolved.request,
4143
4143
  _optionalChain([options, 'optionalAccess', _187 => _187.onSubmission]),
@@ -4150,7 +4150,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4150
4150
  );
4151
4151
  const headers = _optionalChain([options, 'optionalAccess', _188 => _188.cliAdmission]) ? {
4152
4152
  ...runtimeHeaders,
4153
- "X-Deepline-API-Major": String(_chunk2CTTSNFEjs.SDK_API_MAJOR)
4153
+ "X-Deepline-API-Major": String(_chunkQG3MRMU5js.SDK_API_MAJOR)
4154
4154
  } : runtimeHeaders;
4155
4155
  const http = this.http;
4156
4156
  let submitted = false;
@@ -4158,7 +4158,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4158
4158
  ...prepared,
4159
4159
  async start(startOptions) {
4160
4160
  if (submitted && !prepared.supportsCallerIntent) {
4161
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4161
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4162
4162
  "This server has not enabled caller-owned admission recovery. Do not retry an ambiguous start.",
4163
4163
  409,
4164
4164
  "PLAY_RUN_ADMISSION_RECOVERY_UNSUPPORTED"
@@ -4166,7 +4166,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4166
4166
  }
4167
4167
  if (submitted) {
4168
4168
  if (!_optionalChain([options, 'optionalAccess', _189 => _189.callerIntentV2])) {
4169
- await _chunkRNSHCJMEjs.preparePlayRunAdmission.call(void 0,
4169
+ await _chunk6Y3DDRRNjs.preparePlayRunAdmission.call(void 0,
4170
4170
  http,
4171
4171
  JSON.parse(bodyJson),
4172
4172
  void 0,
@@ -4176,7 +4176,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4176
4176
  }
4177
4177
  submitted = true;
4178
4178
  try {
4179
- return await _chunkRNSHCJMEjs.submitPreparedPlayRunAdmission.call(void 0,
4179
+ return await _chunk6Y3DDRRNjs.submitPreparedPlayRunAdmission.call(void 0,
4180
4180
  http,
4181
4181
  JSON.parse(bodyJson),
4182
4182
  prepared.workflowId,
@@ -4189,7 +4189,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4189
4189
  }
4190
4190
  );
4191
4191
  } catch (error) {
4192
- if (error instanceof _chunkRNSHCJMEjs.CliPlayAdmissionUnsupportedError || error instanceof _chunkRNSHCJMEjs.CliPlayAdmissionCallerIntentV2UnsupportedError) {
4192
+ if (error instanceof _chunk6Y3DDRRNjs.CliPlayAdmissionUnsupportedError || error instanceof _chunk6Y3DDRRNjs.CliPlayAdmissionCallerIntentV2UnsupportedError) {
4193
4193
  submitted = false;
4194
4194
  }
4195
4195
  throw error;
@@ -4197,7 +4197,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4197
4197
  },
4198
4198
  async *startStream(streamOptions) {
4199
4199
  if (submitted && !prepared.supportsCallerIntent) {
4200
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4200
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4201
4201
  "This server has not enabled caller-owned admission recovery. Do not retry an ambiguous start.",
4202
4202
  409,
4203
4203
  "PLAY_RUN_ADMISSION_RECOVERY_UNSUPPORTED"
@@ -4205,7 +4205,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4205
4205
  }
4206
4206
  if (submitted) {
4207
4207
  if (!_optionalChain([options, 'optionalAccess', _197 => _197.callerIntentV2])) {
4208
- await _chunkRNSHCJMEjs.preparePlayRunAdmission.call(void 0,
4208
+ await _chunk6Y3DDRRNjs.preparePlayRunAdmission.call(void 0,
4209
4209
  http,
4210
4210
  JSON.parse(bodyJson),
4211
4211
  void 0,
@@ -4214,7 +4214,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4214
4214
  }
4215
4215
  }
4216
4216
  submitted = true;
4217
- const streamPath = _optionalChain([options, 'optionalAccess', _199 => _199.callerIntentV2]) ? _chunkRNSHCJMEjs.CLI_PLAY_RUN_CALLER_INTENT_V2_START_STREAM_PATH : _optionalChain([options, 'optionalAccess', _200 => _200.cliAdmission]) ? _chunkRNSHCJMEjs.CLI_PLAY_RUN_START_STREAM_PATH : _chunkRNSHCJMEjs.PLAY_RUN_START_STREAM_PATH;
4217
+ const streamPath = _optionalChain([options, 'optionalAccess', _199 => _199.callerIntentV2]) ? _chunk6Y3DDRRNjs.CLI_PLAY_RUN_CALLER_INTENT_V2_START_STREAM_PATH : _optionalChain([options, 'optionalAccess', _200 => _200.cliAdmission]) ? _chunk6Y3DDRRNjs.CLI_PLAY_RUN_START_STREAM_PATH : _chunk6Y3DDRRNjs.PLAY_RUN_START_STREAM_PATH;
4218
4218
  let cliAdmissionSupported = false;
4219
4219
  try {
4220
4220
  for await (const event of http.streamSse(streamPath, {
@@ -4225,22 +4225,22 @@ var DeeplineClient = (_class = class _DeeplineClient {
4225
4225
  exactUrlOnly: true,
4226
4226
  ..._optionalChain([options, 'optionalAccess', _202 => _202.cliAdmission]) ? {
4227
4227
  onResponse: (response) => {
4228
- cliAdmissionSupported = response.headers.get(_chunkRNSHCJMEjs.CLI_PLAY_RUN_SUPPORTED_HEADER) === "true";
4228
+ cliAdmissionSupported = response.headers.get(_chunk6Y3DDRRNjs.CLI_PLAY_RUN_SUPPORTED_HEADER) === "true";
4229
4229
  }
4230
4230
  } : {}
4231
4231
  })) {
4232
4232
  if (event.scope === "play") yield event;
4233
4233
  }
4234
4234
  } catch (error) {
4235
- if (_optionalChain([options, 'optionalAccess', _203 => _203.cliAdmission]) && !cliAdmissionSupported && error instanceof _chunkDIAWYWT5js.DeeplineError && (error.statusCode === 404 || error.statusCode === 405)) {
4235
+ if (_optionalChain([options, 'optionalAccess', _203 => _203.cliAdmission]) && !cliAdmissionSupported && error instanceof _chunkSQWET4SLjs.DeeplineError && (error.statusCode === 404 || error.statusCode === 405)) {
4236
4236
  if (options.callerIntentV2) {
4237
4237
  submitted = false;
4238
- throw new (0, _chunkRNSHCJMEjs.CliPlayAdmissionCallerIntentV2UnsupportedError)(
4238
+ throw new (0, _chunk6Y3DDRRNjs.CliPlayAdmissionCallerIntentV2UnsupportedError)(
4239
4239
  error.statusCode
4240
4240
  );
4241
4241
  }
4242
4242
  submitted = false;
4243
- throw new (0, _chunkRNSHCJMEjs.CliPlayAdmissionUnsupportedError)(error.statusCode);
4243
+ throw new (0, _chunk6Y3DDRRNjs.CliPlayAdmissionUnsupportedError)(error.statusCode);
4244
4244
  }
4245
4245
  throw error;
4246
4246
  }
@@ -4253,7 +4253,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4253
4253
  * @internal
4254
4254
  */
4255
4255
  async prefetchPlayRunAdmissionCapability(options) {
4256
- return _chunkRNSHCJMEjs.readPlayRunAdmissionCapability.call(void 0, this.http, options);
4256
+ return _chunk6Y3DDRRNjs.readPlayRunAdmissionCapability.call(void 0, this.http, options);
4257
4257
  }
4258
4258
  /**
4259
4259
  * Submit a play run through the legacy event response.
@@ -4527,7 +4527,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4527
4527
  * ```
4528
4528
  */
4529
4529
  async stagePlayFiles(files) {
4530
- return _chunkRNSHCJMEjs.stagePlayFiles.call(void 0, this.http, files);
4530
+ return _chunk6Y3DDRRNjs.stagePlayFiles.call(void 0, this.http, files);
4531
4531
  }
4532
4532
  /**
4533
4533
  * Mint short-lived presigned upload targets for staged play files.
@@ -4536,7 +4536,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4536
4536
  * For other files, the server returns a presigned PUT URL. Upload the file body to that URL.
4537
4537
  */
4538
4538
  async mintStagedPlayFileUploads(files) {
4539
- return _chunkRNSHCJMEjs.mintStagedPlayFileUploads.call(void 0, this.http, files);
4539
+ return _chunk6Y3DDRRNjs.mintStagedPlayFileUploads.call(void 0, this.http, files);
4540
4540
  }
4541
4541
  /**
4542
4542
  * Resolve staged play files by content hash without uploading bytes.
@@ -4647,18 +4647,18 @@ var DeeplineClient = (_class = class _DeeplineClient {
4647
4647
  }
4648
4648
  })) {
4649
4649
  _optionalChain([options, 'optionalAccess', _241 => _241.onEvent, 'optionalCall', _242 => _242(event)]);
4650
- if (_chunkRNSHCJMEjs.isTerminalPlayRunLifecycleStatus.call(void 0, playLiveRunStatus(event))) {
4650
+ if (_chunk6Y3DDRRNjs.isTerminalPlayRunLifecycleStatus.call(void 0, playLiveRunStatus(event))) {
4651
4651
  terminalObserved = true;
4652
4652
  }
4653
4653
  }
4654
4654
  if (_optionalChain([options, 'optionalAccess', _243 => _243.signal, 'optionalAccess', _244 => _244.aborted])) {
4655
- throw new (0, _chunkDIAWYWT5js.DeeplineError)("Run watch aborted.", void 0, "ABORTED");
4655
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)("Run watch aborted.", void 0, "ABORTED");
4656
4656
  }
4657
4657
  const refreshed = await _asyncNullishCoalesce(terminalStatus, async () => ( await this.getRunStatus(runId)));
4658
- if (terminalObserved || _chunkRNSHCJMEjs.isTerminalPlayRunLifecycleStatus.call(void 0, refreshed.status)) {
4658
+ if (terminalObserved || _chunk6Y3DDRRNjs.isTerminalPlayRunLifecycleStatus.call(void 0, refreshed.status)) {
4659
4659
  return refreshed;
4660
4660
  }
4661
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4661
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4662
4662
  `Run watch for ${runId} ended before a terminal status.`,
4663
4663
  void 0,
4664
4664
  "PLAY_WATCH_ENDED"
@@ -4835,7 +4835,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
4835
4835
  { headers: { "x-deepline-run-status": "1" } }
4836
4836
  );
4837
4837
  if (_optionalChain([options, 'optionalAccess', _250 => _250.configuration]) === true && !Object.hasOwn(response, "contract")) {
4838
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4838
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4839
4839
  "This server does not support recorded configuration reads.",
4840
4840
  void 0,
4841
4841
  "RUN_CONFIGURATION_UNAVAILABLE"
@@ -4886,14 +4886,14 @@ var DeeplineClient = (_class = class _DeeplineClient {
4886
4886
  async getRunChildren(parentRunId, options) {
4887
4887
  const launchKey = options.launchKey.trim();
4888
4888
  if (!launchKey) {
4889
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4889
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4890
4890
  "runs.children requires a nonempty launchKey.",
4891
4891
  void 0,
4892
4892
  "INVALID_CHILD_RUN_LAUNCH_KEY"
4893
4893
  );
4894
4894
  }
4895
4895
  if (options.limit !== void 0 && (!Number.isInteger(options.limit) || options.limit < 1 || options.limit > 50)) {
4896
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
4896
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
4897
4897
  "runs.children limit must be an integer from 1 to 50.",
4898
4898
  void 0,
4899
4899
  "INVALID_CHILD_RUN_PAGE_LIMIT"
@@ -5042,7 +5042,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
5042
5042
  async rerun(runId, options) {
5043
5043
  const idempotencyKey = _optionalChain([options, 'optionalAccess', _264 => _264.idempotencyKey, 'optionalAccess', _265 => _265.trim, 'call', _266 => _266()]);
5044
5044
  if (_optionalChain([options, 'optionalAccess', _267 => _267.idempotencyKey]) !== void 0 && !idempotencyKey) {
5045
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5045
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5046
5046
  "runs.rerun idempotencyKey must not be empty.",
5047
5047
  void 0,
5048
5048
  "INVALID_IDEMPOTENCY_KEY"
@@ -5078,14 +5078,14 @@ var DeeplineClient = (_class = class _DeeplineClient {
5078
5078
  */
5079
5079
  async getRunLogs(runId, options) {
5080
5080
  if (_optionalChain([options, 'optionalAccess', _269 => _269.all]) === true && options.failed === true) {
5081
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5081
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5082
5082
  "runs.logs cannot combine all and failed views.",
5083
5083
  void 0,
5084
5084
  "INVALID_RUN_LOG_VIEW"
5085
5085
  );
5086
5086
  }
5087
5087
  if (_optionalChain([options, 'optionalAccess', _270 => _270.cursor]) !== void 0 && options.failed === true) {
5088
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5088
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5089
5089
  "runs.logs cannot combine failed with cursor.",
5090
5090
  void 0,
5091
5091
  "INVALID_RUN_LOG_VIEW"
@@ -5235,7 +5235,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
5235
5235
  if (selection !== void 0) {
5236
5236
  const runtime = normalizePlayRuntimeSelection(selection);
5237
5237
  if (!runtime) {
5238
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5238
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5239
5239
  "Run event queries require a valid Preview runtime selection.",
5240
5240
  void 0,
5241
5241
  "INVALID_RUNTIME_SELECTION"
@@ -5292,7 +5292,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
5292
5292
  if (options.runtime !== void 0) {
5293
5293
  const runtime = normalizePlayRuntimeSelection(options.runtime);
5294
5294
  if (!runtime) {
5295
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5295
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5296
5296
  "runs.searchEvents runtime must be a valid Preview selection.",
5297
5297
  void 0,
5298
5298
  "INVALID_RUNTIME_SELECTION"
@@ -5361,7 +5361,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
5361
5361
  )
5362
5362
  ];
5363
5363
  if (_optionalChain([result, 'access', _288 => _288.scope, 'optionalAccess', _289 => _289.kind]) !== "run" || confirmedRunId !== requestedRunId || foreignRowRunIds.length > 0) {
5364
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5364
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5365
5365
  `Run-scoped dataset export was not confirmed for ${requestedRunId}; no rows were returned to the caller. Update Deepline, then retry the same export command. Do not rerun the play.`,
5366
5366
  void 0,
5367
5367
  "RUN_EXPORT_SCOPE_MISMATCH",
@@ -5416,7 +5416,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
5416
5416
  }
5417
5417
  );
5418
5418
  if (dryRun && !isStopAllPlayRunsDryRunResult(result)) {
5419
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
5419
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
5420
5420
  "This Deepline server does not support runs stop-all --dry-run and performed a real stop-all. Update the server before using --dry-run.",
5421
5421
  void 0,
5422
5422
  "STOP_ALL_DRY_RUN_UNSUPPORTED"
@@ -6154,7 +6154,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6154
6154
  if (event.type !== "play.run.status" || status.status !== previousStatus) {
6155
6155
  _optionalChain([options, 'optionalAccess', _343 => _343.onProgress, 'optionalCall', _344 => _344(status)]);
6156
6156
  }
6157
- if (_chunkRNSHCJMEjs.isTerminalPlayRunLifecycleStatus.call(void 0, status.status)) {
6157
+ if (_chunk6Y3DDRRNjs.isTerminalPlayRunLifecycleStatus.call(void 0, status.status)) {
6158
6158
  terminalObserved = status;
6159
6159
  }
6160
6160
  }
@@ -6174,7 +6174,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6174
6174
  ).catch(() => terminalObserved);
6175
6175
  return playRunResultFromStatus(finalStatus, start, workflowId);
6176
6176
  }
6177
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6177
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6178
6178
  `Run watch for ${workflowId} ended before the run reached a terminal state.`,
6179
6179
  void 0,
6180
6180
  "PLAY_RUN_STREAM_ENDED",
@@ -6202,7 +6202,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6202
6202
  async getBillingUsageEvent(requestId) {
6203
6203
  const normalizedRequestId = requestId.trim();
6204
6204
  if (normalizedRequestId.length === 0 || normalizedRequestId.length > 200 || normalizedRequestId !== requestId) {
6205
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6205
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6206
6206
  "Usage request_id must contain 1\u2013200 characters with no leading or trailing whitespace.",
6207
6207
  void 0,
6208
6208
  "INVALID_USAGE_REQUEST_ID"
@@ -6213,7 +6213,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6213
6213
  );
6214
6214
  const event = _optionalChain([response, 'access', _347 => _347.entries, 'optionalAccess', _348 => _348[0]]);
6215
6215
  if (!event) {
6216
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6216
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6217
6217
  "No usage event was found for this request_id.",
6218
6218
  void 0,
6219
6219
  "USAGE_EVENT_NOT_FOUND"
@@ -6227,7 +6227,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6227
6227
  */
6228
6228
  async getBillingUsageEvents(options = {}) {
6229
6229
  const invalid = (message) => {
6230
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6230
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6231
6231
  message,
6232
6232
  void 0,
6233
6233
  "INVALID_USAGE_EVENTS_OPTIONS"
@@ -6285,14 +6285,14 @@ var DeeplineClient = (_class = class _DeeplineClient {
6285
6285
  if (options.requestId !== void 0) {
6286
6286
  const requestId = options.requestId.trim();
6287
6287
  if (requestId.length === 0 || requestId.length > 200 || requestId !== options.requestId) {
6288
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6288
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6289
6289
  "Usage request_id must contain 1\u2013200 characters with no leading or trailing whitespace.",
6290
6290
  void 0,
6291
6291
  "INVALID_USAGE_REQUEST_ID"
6292
6292
  );
6293
6293
  }
6294
6294
  if (options.runId !== void 0 || options.cursor !== void 0 || options.offset !== void 0) {
6295
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6295
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6296
6296
  "requestId cannot be combined with runId, cursor, or offset.",
6297
6297
  void 0,
6298
6298
  "INVALID_USAGE_FILTERS"
@@ -6456,7 +6456,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6456
6456
  /** Recover only the original workspace, credit amount, and purchase key; never charge. */
6457
6457
  async recoverTargetBillingCreditPurchase(options) {
6458
6458
  if (typeof options.idempotencyKey !== "string") {
6459
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6459
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6460
6460
  "The original billing idempotencyKey is required.",
6461
6461
  void 0,
6462
6462
  "INVALID_BILLING_IDEMPOTENCY_KEY"
@@ -6466,14 +6466,14 @@ var DeeplineClient = (_class = class _DeeplineClient {
6466
6466
  options.idempotencyKey
6467
6467
  );
6468
6468
  if (!Number.isSafeInteger(options.credits) || options.credits <= 0) {
6469
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6469
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6470
6470
  "credits must be a positive safe integer.",
6471
6471
  void 0,
6472
6472
  "INVALID_CREDITS"
6473
6473
  );
6474
6474
  }
6475
6475
  if (typeof options.orgId !== "string" || !options.orgId.trim() || options.orgId !== options.orgId.trim()) {
6476
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6476
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6477
6477
  "The original orgId is required without surrounding whitespace.",
6478
6478
  void 0,
6479
6479
  "INVALID_ORG_ID"
@@ -6590,7 +6590,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6590
6590
  async submitMonitorBatch(options) {
6591
6591
  const idempotencyKey = options.idempotencyKey.trim();
6592
6592
  if (!idempotencyKey) {
6593
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6593
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6594
6594
  "Monitor batch idempotencyKey is required.",
6595
6595
  void 0,
6596
6596
  "INVALID_MONITOR_BATCH_IDEMPOTENCY_KEY"
@@ -6598,7 +6598,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6598
6598
  }
6599
6599
  if (options.kind === "deploy") {
6600
6600
  if (!options.manifestNdjson.trim()) {
6601
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6601
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6602
6602
  "Monitor batch deploy requires a non-empty NDJSON manifest.",
6603
6603
  void 0,
6604
6604
  "INVALID_MONITOR_BATCH_MANIFEST"
@@ -6644,7 +6644,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6644
6644
  async getMonitorBatch(operationId, options) {
6645
6645
  const runId = operationId.trim();
6646
6646
  if (!runId) {
6647
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6647
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6648
6648
  "Monitor batch operation id is required.",
6649
6649
  void 0,
6650
6650
  "INVALID_MONITOR_BATCH_OPERATION_ID"
@@ -6822,7 +6822,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6822
6822
  }
6823
6823
  async testMonitorWebhook(key, payload, options) {
6824
6824
  if (_optionalChain([options, 'optionalAccess', _379 => _379.dispatch]) === true || _optionalChain([options, 'optionalAccess', _380 => _380.validationOnly]) === false) {
6825
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6825
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6826
6826
  "Monitor tests are validation-only and cannot dispatch events.",
6827
6827
  void 0,
6828
6828
  "MONITOR_TEST_DISPATCH_NOT_SUPPORTED"
@@ -6877,7 +6877,7 @@ var DeeplineClient = (_class = class _DeeplineClient {
6877
6877
  /** Delete a deployed monitor and its upstream provider resource. `dryRun` returns the delete plan. Prefer `client.monitors.delete(...)`. */
6878
6878
  async deleteMonitor(key, options) {
6879
6879
  if (_optionalChain([options, 'optionalAccess', _381 => _381.localOnly]) === true) {
6880
- throw new (0, _chunkDIAWYWT5js.DeeplineError)(
6880
+ throw new (0, _chunkSQWET4SLjs.DeeplineError)(
6881
6881
  "localOnly monitor deletion is no longer supported. Monitor deletion always deprovisions the upstream provider resource.",
6882
6882
  void 0,
6883
6883
  "MONITOR_LOCAL_ONLY_DELETE_NOT_SUPPORTED"