deepline 0.3.502 → 0.3.504

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 (211) hide show
  1. package/dist/bundling-sources/sdk/src/client-core.ts +26 -0
  2. package/dist/bundling-sources/sdk/src/index.ts +1 -0
  3. package/dist/bundling-sources/sdk/src/release.ts +1 -1
  4. package/dist/bundling-sources/sdk/src/types.ts +9 -0
  5. package/dist/bundling-sources/shared_libs/monitors/http-error-response.ts +35 -0
  6. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-batch-operation.ts +1 -1
  7. package/dist/bundling-sources/shared_libs/monitors/provider-monitor-public-aliases.ts +13 -0
  8. package/dist/bundling-sources/shared_libs/monitors/starter-templates.ts +0 -8
  9. package/dist/bundling-sources/shared_libs/observability/dlq.ts +174 -0
  10. package/dist/bundling-sources/shared_libs/observability/queue-health.ts +9 -0
  11. package/dist/bundling-sources/shared_libs/observability/queue-item-connectors.ts +1 -0
  12. package/dist/bundling-sources/shared_libs/observability/scheduled-jobs.json +18 -0
  13. package/dist/bundling-sources/shared_libs/play-runtime/activity-observation.ts +20 -0
  14. package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +62 -2
  15. package/dist/bundling-sources/shared_libs/play-runtime/context.ts +667 -62
  16. package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +55 -0
  17. package/dist/bundling-sources/shared_libs/play-runtime/durable-receipt-execution.ts +20 -2
  18. package/dist/bundling-sources/shared_libs/play-runtime/durable-runs-rollout.ts +46 -0
  19. package/dist/bundling-sources/shared_libs/play-runtime/execution-gateway-invocation-fence.ts +80 -4
  20. package/dist/bundling-sources/shared_libs/play-runtime/fixture-egress-fetch.ts +95 -0
  21. package/dist/bundling-sources/shared_libs/play-runtime/freshness-receipt-execution.ts +292 -45
  22. package/dist/bundling-sources/shared_libs/play-runtime/internal-bootstrap-token.ts +15 -0
  23. package/dist/bundling-sources/shared_libs/play-runtime/launch-identity.ts +3 -0
  24. package/dist/bundling-sources/shared_libs/play-runtime/play-http-request.ts +7 -3
  25. package/dist/bundling-sources/shared_libs/play-runtime/play-runtime-semantics.ts +31 -1
  26. package/dist/bundling-sources/shared_libs/play-runtime/post-code-recovery-policy.ts +231 -0
  27. package/dist/bundling-sources/shared_libs/play-runtime/protocol.ts +4 -0
  28. package/dist/bundling-sources/shared_libs/play-runtime/run-ending-event.ts +55 -0
  29. package/dist/bundling-sources/shared_libs/play-runtime/run-ledger.ts +126 -0
  30. package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +38 -1
  31. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-launch-transport.ts +2 -9
  32. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-lifecycle.ts +51 -19
  33. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/local-process.ts +9 -4
  34. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/modal.ts +2 -0
  35. package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/runtime-sandbox-reconciliation.ts +2 -0
  36. package/dist/bundling-sources/shared_libs/play-runtime/runtime-actions.ts +12 -1
  37. package/dist/bundling-sources/shared_libs/play-runtime/runtime-authority.ts +3 -0
  38. package/dist/bundling-sources/shared_libs/play-runtime/runtime-incident-drills.ts +42 -0
  39. package/dist/bundling-sources/shared_libs/play-runtime/runtime-operation-contract.ts +7 -0
  40. package/dist/bundling-sources/shared_libs/play-runtime/runtime-receipt-store-adapter.ts +26 -1
  41. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backend.ts +13 -0
  42. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-deadline-reconciliation.ts +53 -0
  43. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-runtime-worker.ts +631 -19
  44. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/durable-run-inventory.ts +719 -0
  45. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/durable-run-sql.ts +206 -0
  46. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/latest-cache-result.ts +83 -0
  47. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +1432 -157
  48. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/receipt-gateway.ts +61 -0
  49. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-event-search.ts +29 -8
  50. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-queue-health.ts +27 -2
  51. package/dist/bundling-sources/shared_libs/play-runtime/test-runtime-seams.ts +45 -0
  52. package/dist/bundling-sources/shared_libs/play-runtime/tool-cache-policy.ts +18 -0
  53. package/dist/bundling-sources/shared_libs/play-runtime/tool-execute-retry-policy.ts +129 -14
  54. package/dist/bundling-sources/shared_libs/play-runtime/workflow-executor-auth.ts +2 -0
  55. package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +10 -1
  56. package/dist/cli/{auth-EFHLOVG4.mjs → auth-3L5AA5AX.mjs} +5 -5
  57. package/dist/cli/auth-UPK4IIIN.js +43 -0
  58. package/dist/cli/{billing-Q5XKEYPP.mjs → billing-E7EASVPO.mjs} +19 -12
  59. package/dist/cli/{billing-SKT2VE34.js → billing-HOGXVE2V.js} +92 -85
  60. package/dist/cli/{chunk-L5CTJY74.mjs → chunk-22OCKCYS.mjs} +2 -2
  61. package/dist/cli/{chunk-YWOQYYYS.mjs → chunk-2ABRDH3B.mjs} +2 -2
  62. package/dist/cli/{chunk-IL666WJE.js → chunk-2W77YCKH.js} +5 -5
  63. package/dist/cli/{chunk-2MVIS2UI.mjs → chunk-3MLFFWDM.mjs} +2 -2
  64. package/dist/cli/{chunk-HMZF2CSP.mjs → chunk-4CC67XH5.mjs} +2 -2
  65. package/dist/cli/{chunk-NXVYLX3F.mjs → chunk-5CHBIJIM.mjs} +10 -6
  66. package/dist/cli/chunk-5LUF4LAR.mjs +209 -0
  67. package/dist/cli/{chunk-JL6H4H3G.js → chunk-5Z6EULD5.js} +6 -6
  68. package/dist/cli/{chunk-32YQBJON.js → chunk-67OI26OE.js} +7 -7
  69. package/dist/cli/{chunk-LA3UYRVZ.js → chunk-6JNBMTCZ.js} +1 -1
  70. package/dist/cli/{chunk-DYHTXGLX.js → chunk-6SMR7LU7.js} +2 -2
  71. package/dist/cli/{chunk-OFBLT2LQ.mjs → chunk-7F4OEHQK.mjs} +1 -1
  72. package/dist/cli/{chunk-DRBD4IYQ.mjs → chunk-7MJYZ33I.mjs} +2 -6
  73. package/dist/cli/{chunk-UOANF3DR.js → chunk-7P2QVMBP.js} +26 -7
  74. package/dist/cli/{chunk-GINKIZ7S.js → chunk-A6LA42JY.js} +16 -16
  75. package/dist/cli/{chunk-FVM4PS5Q.js → chunk-BN5VKY4X.js} +25 -12
  76. package/dist/cli/{chunk-Z2H7OQ6E.mjs → chunk-BTWUNKKX.mjs} +2 -2
  77. package/dist/cli/{chunk-R5F7JXT4.mjs → chunk-BX45XMXZ.mjs} +2 -2
  78. package/dist/cli/{chunk-NKLM4J4X.mjs → chunk-DEAJVQEG.mjs} +1 -1
  79. package/dist/cli/{chunk-JFBJLNBI.js → chunk-FISP4LCK.js} +53 -53
  80. package/dist/cli/{chunk-OEUMXKR5.js → chunk-FTRVCIGC.js} +26 -26
  81. package/dist/cli/{chunk-YL2CCF6T.mjs → chunk-GGBXNQCR.mjs} +4 -4
  82. package/dist/cli/{chunk-YPTZJ7LO.js → chunk-GJ2DA35C.js} +100 -17
  83. package/dist/cli/{chunk-2S2F6YSI.js → chunk-GRAGUYIE.js} +41 -41
  84. package/dist/cli/{chunk-2JS3H6H6.mjs → chunk-HUX5DZO6.mjs} +3 -3
  85. package/dist/cli/{chunk-4CCMD7QM.mjs → chunk-IGNQKOWT.mjs} +32 -15
  86. package/dist/cli/{chunk-WKFAX2K7.js → chunk-IPAMOMGP.js} +21 -21
  87. package/dist/cli/{chunk-SAW3FBCA.mjs → chunk-ITJ7NB2D.mjs} +6 -0
  88. package/dist/cli/{chunk-Q3NM6ZL3.js → chunk-JPR2546F.js} +23 -21
  89. package/dist/cli/{chunk-X5MGQ7UT.js → chunk-KCKAFTPY.js} +10 -10
  90. package/dist/cli/{chunk-TAK3MVXY.js → chunk-KGUGNEKL.js} +284 -267
  91. package/dist/cli/{chunk-OVZOMSH2.js → chunk-LHXYCZYO.js} +8 -8
  92. package/dist/cli/{chunk-QOJBRCAS.js → chunk-MJTK6Q3G.js} +3 -3
  93. package/dist/cli/{chunk-MYUISF3P.mjs → chunk-MLMWM5DV.mjs} +5 -5
  94. package/dist/cli/{chunk-JO5FFSR7.js → chunk-NTLBZUHD.js} +6 -0
  95. package/dist/cli/{chunk-MP5QY4A2.mjs → chunk-NZ7Z7WNM.mjs} +2 -2
  96. package/dist/cli/{chunk-HIVRCTDR.mjs → chunk-OX2D6BG4.mjs} +20 -1
  97. package/dist/cli/{chunk-YDXEXVBV.js → chunk-QKKU2FH4.js} +7 -7
  98. package/dist/cli/{chunk-3KEZVGGV.mjs → chunk-QOLX2O2S.mjs} +4 -4
  99. package/dist/cli/{chunk-JFUXUSKB.mjs → chunk-R2VZVHJP.mjs} +15 -2
  100. package/dist/cli/chunk-R7J7CJPZ.js +209 -0
  101. package/dist/cli/{chunk-XMKUJ44Z.js → chunk-SMSQVRHE.js} +5 -5
  102. package/dist/cli/{chunk-54QXWK3C.mjs → chunk-SVFTZTCI.mjs} +1 -1
  103. package/dist/cli/{chunk-FWDAEWCD.js → chunk-TMQUMILM.js} +19 -23
  104. package/dist/cli/{chunk-TFFJ2PRN.mjs → chunk-UFYJTRSF.mjs} +98 -15
  105. package/dist/cli/{chunk-EUWRKWT4.js → chunk-UJMBG5JU.js} +5 -4
  106. package/dist/cli/{chunk-DKAMCJIT.js → chunk-USTJEEND.js} +17 -13
  107. package/dist/cli/{chunk-AJL2Q6IQ.js → chunk-UXQQPMYO.js} +2 -2
  108. package/dist/cli/{chunk-7ZYSXSJJ.mjs → chunk-VJVJWZ6I.mjs} +5 -5
  109. package/dist/cli/{chunk-JLYDLK6X.js → chunk-WBIDPDKJ.js} +3 -3
  110. package/dist/cli/{chunk-QNELA7SX.js → chunk-WZSFIJMG.js} +53 -53
  111. package/dist/cli/{chunk-NZXB27TP.mjs → chunk-XHZSPMNC.mjs} +4 -4
  112. package/dist/cli/{chunk-W5CHE5Q2.mjs → chunk-Y6XKCEPK.mjs} +1 -1
  113. package/dist/cli/{chunk-4WTC5SSN.mjs → chunk-Y7VEHKID.mjs} +10 -8
  114. package/dist/cli/{chunk-3MJSWVQ2.mjs → chunk-YOQ2NNDO.mjs} +2 -1
  115. package/dist/cli/{chunk-ZNB6GR3P.mjs → chunk-Z6FXUDIL.mjs} +1 -1
  116. package/dist/cli/command-docs.d.mts +2 -1
  117. package/dist/cli/command-docs.d.ts +2 -1
  118. package/dist/cli/command-docs.js +6 -2
  119. package/dist/cli/command-docs.mjs +5 -1
  120. package/dist/cli/{csv-OXGSCV75.js → csv-2XWGPITO.js} +13 -13
  121. package/dist/cli/{csv-6AEPKKCO.mjs → csv-433JEHLQ.mjs} +4 -4
  122. package/dist/cli/{db-K3KRK4CZ.mjs → db-K747DH43.mjs} +6 -6
  123. package/dist/cli/{db-6NVHDUZY.js → db-PJJMD4VH.js} +27 -27
  124. package/dist/cli/describe-OYS7LZJD.js +49 -0
  125. package/dist/cli/{describe-P3ZJS7TQ.mjs → describe-VEDDYW4P.mjs} +20 -20
  126. package/dist/cli/describe-core.d.mts +8 -4
  127. package/dist/cli/describe-core.d.ts +8 -4
  128. package/dist/cli/describe-core.js +4 -4
  129. package/dist/cli/describe-core.mjs +3 -3
  130. package/dist/cli/{executions-2C2FFG52.js → executions-HM5T72H6.js} +8 -8
  131. package/dist/cli/{executions-I7XW6WWK.mjs → executions-JWRX3XCT.mjs} +6 -6
  132. package/dist/cli/{feedback-47B57A5Y.js → feedback-34UG4BO3.js} +8 -8
  133. package/dist/cli/{feedback-RSTNBJAI.mjs → feedback-MNSIA63Y.mjs} +4 -4
  134. package/dist/cli/git-5YQJSJFR.js +25 -0
  135. package/dist/cli/{git-3G5AFKBT.mjs → git-ZKEOXV3A.mjs} +5 -5
  136. package/dist/cli/index.js +144 -142
  137. package/dist/cli/index.mjs +44 -42
  138. package/dist/cli/{legacy-noops-NQ262TKL.mjs → legacy-noops-5M4T4ZVT.mjs} +5 -5
  139. package/dist/cli/{legacy-noops-P665PBG4.js → legacy-noops-YXSI4FVU.js} +8 -8
  140. package/dist/cli/{monitors-KUPZODZS.mjs → monitors-C65OC4AW.mjs} +7 -7
  141. package/dist/cli/{monitors-IPWAD7LS.js → monitors-O25GDOYE.js} +95 -95
  142. package/dist/cli/{org-WFC3N672.js → org-2GSPLY2A.js} +72 -72
  143. package/dist/cli/{org-ZCQGEM3L.mjs → org-ZRMG5NS2.mjs} +6 -6
  144. package/dist/cli/{pages-N5BNC67L.js → pages-45DPADK6.js} +18 -18
  145. package/dist/cli/{pages-VE66IU7B.mjs → pages-TZZUFBRO.mjs} +6 -6
  146. package/dist/cli/{play-EIMDIAJB.mjs → play-3D7HH273.mjs} +138 -226
  147. package/dist/cli/{play-NKIRJSKX.js → play-RCGMND6X.js} +454 -542
  148. package/dist/cli/{providers-XU3AGY2F.js → providers-3N3ECMTY.js} +9 -9
  149. package/dist/cli/{providers-KDTJ63ED.mjs → providers-PSAKV6CJ.mjs} +6 -6
  150. package/dist/cli/{quickstart-TXFXUODF.mjs → quickstart-2A35SMGC.mjs} +4 -4
  151. package/dist/cli/{quickstart-OSCHOSXU.js → quickstart-6R6AIXM6.js} +6 -6
  152. package/dist/cli/{run-ODGML35U.mjs → run-F3TLDGUO.mjs} +25 -25
  153. package/dist/cli/{run-ET2KVTPK.js → run-F6ZXTASZ.js} +44 -44
  154. package/dist/cli/{search-DK67K6PR.mjs → search-CZLCY3D2.mjs} +7 -7
  155. package/dist/cli/search-R5VEWJO2.js +32 -0
  156. package/dist/cli/{search-output-6SOKQTCW.mjs → search-output-MQTSTLN5.mjs} +5 -5
  157. package/dist/cli/{search-output-KXP4FA62.js → search-output-R5XDNILW.js} +7 -7
  158. package/dist/cli/{secrets-C6SYTMU7.mjs → secrets-D3GF4B2Z.mjs} +6 -6
  159. package/dist/cli/{secrets-WPS6NMNK.js → secrets-DCJYHDSY.js} +15 -15
  160. package/dist/cli/{sessions-PXVOH34X.mjs → sessions-QGEQ2UYZ.mjs} +5 -5
  161. package/dist/cli/{sessions-IP562J5Z.js → sessions-Z4JYJSDP.js} +6 -6
  162. package/dist/cli/{settings-FBUQGYVJ.mjs → settings-G7QEXA4N.mjs} +11 -11
  163. package/dist/cli/{settings-SUDUIVMY.js → settings-UVXXAT4A.js} +78 -78
  164. package/dist/cli/{setup-I5H6IOEY.js → setup-5I42W7D4.js} +49 -49
  165. package/dist/cli/{setup-JSIMTR73.mjs → setup-QHJU3DUI.mjs} +9 -9
  166. package/dist/cli/{skills-FJQ3LX6N.mjs → skills-5LRF4UKX.mjs} +7 -7
  167. package/dist/cli/skills-FB6TV52O.js +36 -0
  168. package/dist/cli/tools-L2364RPA.js +56 -0
  169. package/dist/cli/{tools-IGBK4BVE.mjs → tools-PUT6STVG.mjs} +18 -18
  170. package/dist/cli/{update-7MTT6F5K.mjs → update-CJ2GA64X.mjs} +9 -9
  171. package/dist/cli/update-ESYJGYVZ.js +34 -0
  172. package/dist/cli/{workflow-PM2J2OU3.mjs → workflow-HVEWRTXD.mjs} +7 -7
  173. package/dist/cli/{workflow-UX3ZX6BQ.js → workflow-O67MEBCP.js} +17 -17
  174. package/dist/{client-Bn8FwKGO.d.ts → client-CIwenMFS.d.ts} +1 -1
  175. package/dist/{client-CfNRmjLK.d.mts → client-DYAfJpaN.d.mts} +1 -1
  176. package/dist/{client-core-B91EV0WS.d.ts → client-core-CRjtyMAI.d.ts} +25 -2
  177. package/dist/{client-core-BG8Cgrmk.d.mts → client-core-DlzP8vEs.d.mts} +25 -2
  178. package/dist/{compiler-manifest-DlXDyndN.d.mts → compiler-manifest-DaJrA2KV.d.mts} +1 -1
  179. package/dist/{compiler-manifest-DlXDyndN.d.ts → compiler-manifest-DaJrA2KV.d.ts} +1 -1
  180. package/dist/{errors-BtriA2ld.d.mts → errors-BKnSYueU.d.mts} +1 -1
  181. package/dist/{errors-DmcLykM7.d.ts → errors-KLga4bLr.d.ts} +1 -1
  182. package/dist/{index-DI0sR_fX.d.mts → index-C-8AFpWy.d.mts} +1 -1
  183. package/dist/{index--Jw-slHY.d.ts → index-C5nAZ-VS.d.ts} +1 -1
  184. package/dist/index.d.mts +7 -7
  185. package/dist/index.d.ts +7 -7
  186. package/dist/index.js +9 -9
  187. package/dist/index.mjs +6 -6
  188. package/dist/install-integrity.json +125 -116
  189. package/dist/plays/bundle-play-file.d.mts +3 -3
  190. package/dist/plays/bundle-play-file.d.ts +3 -3
  191. package/dist/plays/bundle-play-file.mjs +12 -5
  192. package/dist/plays/play-description.d.mts +2 -2
  193. package/dist/plays/play-description.d.ts +2 -2
  194. package/dist/plays/run-request.d.mts +2 -2
  195. package/dist/plays/run-request.d.ts +2 -2
  196. package/dist/release.d.mts +1 -1
  197. package/dist/release.d.ts +1 -1
  198. package/dist/release.js +2 -2
  199. package/dist/release.mjs +1 -1
  200. package/dist/server.d.mts +4 -4
  201. package/dist/server.d.ts +4 -4
  202. package/dist/server.js +5 -5
  203. package/dist/server.mjs +3 -3
  204. package/package.json +1 -1
  205. package/dist/cli/auth-VM3IKP5F.js +0 -43
  206. package/dist/cli/describe-JOUAXXPE.js +0 -49
  207. package/dist/cli/git-OPKIC6JQ.js +0 -25
  208. package/dist/cli/search-6U54Y3OK.js +0 -32
  209. package/dist/cli/skills-VHININXC.js +0 -36
  210. package/dist/cli/tools-XMBMHVKF.js +0 -56
  211. package/dist/cli/update-H7JVW43I.js +0 -34
@@ -1,10 +1,10 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
3
 
4
- var _chunkYDXEXVBVjs = require('./chunk-YDXEXVBV.js');
4
+ var _chunkQKKU2FH4js = require('./chunk-QKKU2FH4.js');
5
5
 
6
6
 
7
- var _chunkEUWRKWT4js = require('./chunk-EUWRKWT4.js');
7
+ var _chunkUJMBG5JUjs = require('./chunk-UJMBG5JU.js');
8
8
 
9
9
  // src/cli/commands/sessions.ts
10
10
 
@@ -139,7 +139,7 @@ function currentSessionFile(agent) {
139
139
  const newestFirst = listSessionFiles(agent).sort(
140
140
  (a, b) => b.mtimeMs - a.mtimeMs
141
141
  );
142
- const sessionId = _chunkEUWRKWT4js.agentSessionIdFromEnvironment.call(void 0,
142
+ const sessionId = _chunkUJMBG5JUjs.agentSessionIdFromEnvironment.call(void 0,
143
143
  process.env,
144
144
  agent === "auto" ? void 0 : agent === "claude" ? "claude_code" : "codex"
145
145
  );
@@ -451,7 +451,7 @@ function buildSessionUploadContent(raw) {
451
451
  return { encodedContent: encoded, needsChunking: true };
452
452
  }
453
453
  async function uploadPayload(path, payload) {
454
- const { http } = _chunkYDXEXVBVjs.getAuthedHttpClient.call(void 0, );
454
+ const { http } = _chunkQKKU2FH4js.getAuthedHttpClient.call(void 0, );
455
455
  return await http.post(path, payload);
456
456
  }
457
457
  async function uploadChunkedSessions(sessions, options) {
@@ -484,7 +484,7 @@ async function uploadChunkedSessions(sessions, options) {
484
484
  ...options.rating ? { rating: options.rating } : {}
485
485
  });
486
486
  const sessionIds = sessions.map((session) => session.sessionId);
487
- _chunkYDXEXVBVjs.printCommandEnvelope.call(void 0,
487
+ _chunkQKKU2FH4js.printCommandEnvelope.call(void 0,
488
488
  {
489
489
  ...response,
490
490
  ok: true,
@@ -516,7 +516,7 @@ async function handleSessionsSend(options) {
516
516
  filename: _path.basename.call(void 0, filePath),
517
517
  ...rating ? { rating } : {}
518
518
  });
519
- _chunkYDXEXVBVjs.printCommandEnvelope.call(void 0,
519
+ _chunkQKKU2FH4js.printCommandEnvelope.call(void 0,
520
520
  {
521
521
  ...response2,
522
522
  ok: true,
@@ -566,7 +566,7 @@ async function handleSessionsSend(options) {
566
566
  ...rating ? { rating } : {}
567
567
  });
568
568
  const sessionIds = built.map((session) => session.sessionId);
569
- _chunkYDXEXVBVjs.printCommandEnvelope.call(void 0,
569
+ _chunkQKKU2FH4js.printCommandEnvelope.call(void 0,
570
570
  {
571
571
  ...response,
572
572
  ok: true,
@@ -674,7 +674,7 @@ ${refreshMeta}
674
674
  </body>
675
675
  </html>`;
676
676
  _fs.writeFileSync.call(void 0, outputPath, html, "utf8");
677
- _chunkYDXEXVBVjs.printCommandEnvelope.call(void 0,
677
+ _chunkQKKU2FH4js.printCommandEnvelope.call(void 0,
678
678
  {
679
679
  ok: true,
680
680
  file: outputPath,
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class;
2
2
 
3
- var _chunkYDXEXVBVjs = require('./chunk-YDXEXVBV.js');
3
+ var _chunkQKKU2FH4js = require('./chunk-QKKU2FH4.js');
4
4
 
5
5
  // src/cli/progress.ts
6
6
  var _worker_threads = require('worker_threads');
@@ -19,7 +19,7 @@ var CliProgress = (_class = class {
19
19
  __init9() {this.quiet = false}
20
20
  // --json output is one JSON document: progress never renders under it.
21
21
  constructor(enabled) {;_class.prototype.__init.call(this);_class.prototype.__init2.call(this);_class.prototype.__init3.call(this);_class.prototype.__init4.call(this);_class.prototype.__init5.call(this);_class.prototype.__init6.call(this);_class.prototype.__init7.call(this);_class.prototype.__init8.call(this);_class.prototype.__init9.call(this);
22
- this.enabled = enabled && !_chunkYDXEXVBVjs.isJsonOutputMode.call(void 0, );
22
+ this.enabled = enabled && !_chunkQKKU2FH4js.isJsonOutputMode.call(void 0, );
23
23
  }
24
24
  setLogWriter(writer) {
25
25
  this.logWriter = writer;
@@ -59,7 +59,7 @@ var CliProgress = (_class = class {
59
59
  this.logWriter(line);
60
60
  return;
61
61
  }
62
- if (_chunkYDXEXVBVjs.isJsonOutputMode.call(void 0, )) return;
62
+ if (_chunkQKKU2FH4js.isJsonOutputMode.call(void 0, )) return;
63
63
  if (!this.enabled) {
64
64
  process.stderr.write(`${line}
65
65
  `);
@@ -4,20 +4,20 @@ import {
4
4
  resolveUpdatePlan,
5
5
  runAutomaticUpdatePlan,
6
6
  shouldRunCliAutoUpdate
7
- } from "./chunk-7ZYSXSJJ.mjs";
7
+ } from "./chunk-VJVJWZ6I.mjs";
8
8
  import {
9
9
  isCiEnvironment
10
- } from "./chunk-NZXB27TP.mjs";
10
+ } from "./chunk-XHZSPMNC.mjs";
11
11
  import {
12
12
  addJsonNotice,
13
13
  isJsonOutputMode
14
- } from "./chunk-2MVIS2UI.mjs";
14
+ } from "./chunk-3MLFFWDM.mjs";
15
15
  import {
16
16
  resolveApiKeyForBaseUrl
17
- } from "./chunk-W5CHE5Q2.mjs";
17
+ } from "./chunk-Y6XKCEPK.mjs";
18
18
  import {
19
19
  SDK_VERSION
20
- } from "./chunk-3MJSWVQ2.mjs";
20
+ } from "./chunk-YOQ2NNDO.mjs";
21
21
 
22
22
  // src/cli/compatibility-catalog.ts
23
23
  var readers = /* @__PURE__ */ new WeakMap();
@@ -673,7 +673,9 @@ function describedLines(described, view) {
673
673
  ...described.cost ? [`Cost: ${described.cost}`] : [],
674
674
  ...described.guidance.map((line) => `Guidance: ${line}`),
675
675
  ...described.rateLimit ? [`Rate limit: ${described.rateLimit}`] : [],
676
+ ...described.credentialStatus === "requires_connection" ? ["Connection: Provider credentials are missing in this workspace."] : [],
676
677
  ...described.byok ? byokLines(described.byok) : [],
678
+ ...described.connectCommand ? [`Get a shareable link: ${described.connectCommand}`] : [],
677
679
  ...featureLines(described.id, _nullishCoalesce(described.features, () => ( []))),
678
680
  ...schemaLines(described, {
679
681
  full: view.fullSchema,
@@ -775,11 +777,15 @@ function describedJson(described, view) {
775
777
  return {
776
778
  kind: described.kind,
777
779
  id: described.id,
780
+ ...described.provider ? { provider: described.provider } : {},
778
781
  ...described.displayName ? { displayName: described.displayName } : {},
779
782
  ...described.description ? { description: described.description } : {},
780
783
  ...described.cost ? { cost: described.cost } : {},
781
784
  ...described.rateLimit ? { rateLimit: described.rateLimit } : {},
782
785
  ...described.byok ? { byok: described.byok } : {},
786
+ ...described.connected !== void 0 ? { connected: described.connected } : {},
787
+ ...described.credentialStatus ? { credentialStatus: described.credentialStatus } : {},
788
+ ...described.connectCommand ? { connectCommand: described.connectCommand } : {},
783
789
  ..._optionalChain([described, 'access', _14 => _14.features, 'optionalAccess', _15 => _15.length]) ? { features: described.features } : {},
784
790
  ...described.guidance.length ? { guidance: described.guidance } : {},
785
791
  ...blocks,
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  getAuthedHttpClient,
3
3
  printCommandEnvelope
4
- } from "./chunk-2MVIS2UI.mjs";
4
+ } from "./chunk-3MLFFWDM.mjs";
5
5
  import {
6
6
  agentSessionIdFromEnvironment
7
- } from "./chunk-3MJSWVQ2.mjs";
7
+ } from "./chunk-YOQ2NNDO.mjs";
8
8
 
9
9
  // src/cli/commands/sessions.ts
10
10
  import {
@@ -31,7 +31,7 @@ import {
31
31
  RETAINED_PIPELINE_RECEIVERS_HEADER,
32
32
  RUNTIME_ENVIRONMENT_TOKEN_HEADER,
33
33
  SDK_API_MAJOR
34
- } from "./chunk-3MJSWVQ2.mjs";
34
+ } from "./chunk-YOQ2NNDO.mjs";
35
35
  import {
36
36
  CustomerDbQueryOutcomeUnknownError
37
37
  } from "./chunk-4QF2K7TM.mjs";
@@ -3535,6 +3535,7 @@ var DeeplineClient = class _DeeplineClient {
3535
3535
  searchEvents: (options) => this.searchRunEvents(options),
3536
3536
  input: (runId) => this.getRunInput(runId),
3537
3537
  rerun: (runId, options) => this.rerun(runId, options),
3538
+ resume: (runId) => this.resumeRun(runId),
3538
3539
  exportDatasetRows: (input) => this.getPlaySheetRows(input),
3539
3540
  rowHistory: (input) => this.getPlayRunRowHistory(input),
3540
3541
  stop: (runId, options) => this.stopRun(runId, options),
@@ -4975,6 +4976,19 @@ var DeeplineClient = class _DeeplineClient {
4975
4976
  { "Idempotency-Key": idempotencyKey || globalThis.crypto.randomUUID() }
4976
4977
  );
4977
4978
  }
4979
+ /**
4980
+ * Continue a failed or cancelled run as the same run. Completed calls are
4981
+ * reused; only work the run had not finished runs. A run can be resumed for
4982
+ * 14 days after it stops. Refusals (still active, last attempt still
4983
+ * finishing, sandbox cleanup pending, window expired) throw a
4984
+ * {@link DeeplineError} with the server's code.
4985
+ */
4986
+ async resumeRun(runId) {
4987
+ return this.http.post(
4988
+ `/api/v2/runs/${encodeURIComponent(runId)}/resume`,
4989
+ {}
4990
+ );
4991
+ }
4978
4992
  /**
4979
4993
  * Read a run's retained text tail (default 200), full retained stream (`all`), or terminal failure window (`failed`, at most 20). These are existing reads; sampling and retention loss cannot be recovered. See [run logs and events](run-events.md) for structured search and payload retrieval.
4980
4994
  *
@@ -5446,6 +5460,11 @@ var DeeplineClient = class _DeeplineClient {
5446
5460
  async getNotificationSettings() {
5447
5461
  return this.http.get("/api/v2/settings/notifications");
5448
5462
  }
5463
+ /** Get the dashboard link where a workspace owner or admin can connect a provider. */
5464
+ async getIntegrationConnectLink(provider) {
5465
+ const params = new URLSearchParams({ provider });
5466
+ return this.http.get(`/api/v2/integrations/connect?${params}`);
5467
+ }
5449
5468
  /** Save provider-owned credential fields without starting an OAuth browser flow. */
5450
5469
  async setIntegrationCredentials(provider, credentials) {
5451
5470
  return this.http.post("/api/v2/integrations/connect", {
@@ -2,10 +2,10 @@
2
2
 
3
3
 
4
4
 
5
- var _chunkJLYDLK6Xjs = require('./chunk-JLYDLK6X.js');
5
+ var _chunkWBIDPDKJjs = require('./chunk-WBIDPDKJ.js');
6
6
 
7
7
 
8
- var _chunkEUWRKWT4js = require('./chunk-EUWRKWT4.js');
8
+ var _chunkUJMBG5JUjs = require('./chunk-UJMBG5JU.js');
9
9
 
10
10
 
11
11
 
@@ -293,8 +293,8 @@ var BROWSER_OPEN_COOLDOWN_MS = 3e4;
293
293
  var SAME_URL_BROWSER_OPEN_COOLDOWN_MS = 5 * 6e4;
294
294
  var defaultBrowserCommandRunner = childProcess;
295
295
  function getAuthedHttpClient() {
296
- const config = _chunkJLYDLK6Xjs.resolveConfig.call(void 0, );
297
- return { config, http: new (0, _chunkJLYDLK6Xjs.HttpClient)(config) };
296
+ const config = _chunkWBIDPDKJjs.resolveConfig.call(void 0, );
297
+ return { config, http: new (0, _chunkWBIDPDKJjs.HttpClient)(config) };
298
298
  }
299
299
  function stableOsUserId() {
300
300
  try {
@@ -634,7 +634,7 @@ function collectLocalEnvInfo() {
634
634
  os: `${process.platform} ${process.arch}`,
635
635
  node_version: process.version,
636
636
  home_dir: homeDir,
637
- agent_runtime: _chunkEUWRKWT4js.detectAgentRuntime.call(void 0, )
637
+ agent_runtime: _chunkUJMBG5JUjs.detectAgentRuntime.call(void 0, )
638
638
  };
639
639
  const env = process.env;
640
640
  const optional = {
@@ -881,9 +881,9 @@ function markdownTableFromRows(rows, preferredColumns = []) {
881
881
  }
882
882
  function withAgentCommandContext(value) {
883
883
  const valueRecord = value !== null && typeof value === "object" && !Array.isArray(value) ? value : null;
884
- return _chunkEUWRKWT4js.detectAgentRuntime.call(void 0, ) !== "unknown" && valueRecord && !Object.prototype.hasOwnProperty.call(valueRecord, "command_context") ? {
884
+ return _chunkUJMBG5JUjs.detectAgentRuntime.call(void 0, ) !== "unknown" && valueRecord && !Object.prototype.hasOwnProperty.call(valueRecord, "command_context") ? {
885
885
  ...valueRecord,
886
- command_context: _chunkJLYDLK6Xjs.resolveCliCommandContext.call(void 0, )
886
+ command_context: _chunkWBIDPDKJjs.resolveCliCommandContext.call(void 0, )
887
887
  } : value;
888
888
  }
889
889
  function printJson(value, fields) {
@@ -3,14 +3,14 @@ import {
3
3
  } from "./chunk-5AEDYVB6.mjs";
4
4
  import {
5
5
  DeeplineClient
6
- } from "./chunk-YWOQYYYS.mjs";
6
+ } from "./chunk-2ABRDH3B.mjs";
7
7
  import {
8
8
  printCommandEnvelope
9
- } from "./chunk-2MVIS2UI.mjs";
9
+ } from "./chunk-3MLFFWDM.mjs";
10
10
  import {
11
11
  resolveConfig,
12
12
  sdkCliStateDirPath
13
- } from "./chunk-W5CHE5Q2.mjs";
13
+ } from "./chunk-Y6XKCEPK.mjs";
14
14
 
15
15
  // src/cli/commands/search.ts
16
16
  import { Option } from "commander";
@@ -133,7 +133,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
133
133
  });
134
134
  if (searchRef) rememberSearchRef(searchRef);
135
135
  pointAtDescribe(result);
136
- const { renderSearchResults } = await import("./search-output-6SOKQTCW.mjs");
136
+ const { renderSearchResults } = await import("./search-output-MQTSTLN5.mjs");
137
137
  printCommandEnvelope(result, {
138
138
  json: options.json === true,
139
139
  text: renderSearchResults(result, summaryWidth)
@@ -2,7 +2,7 @@ import {
2
2
  rateLimitSummary,
3
3
  schemaField,
4
4
  schemaFields
5
- } from "./chunk-SAW3FBCA.mjs";
5
+ } from "./chunk-ITJ7NB2D.mjs";
6
6
  import {
7
7
  playToolListGetterMode
8
8
  } from "./chunk-FR2ILQ4G.mjs";
@@ -395,9 +395,18 @@ function describedTool(tool, requestedToolId) {
395
395
  };
396
396
  });
397
397
  const playReference = isPlayLikeTool(tool) ? playReferenceForTool(tool) : null;
398
+ const { byok } = tool;
399
+ const credentialStatus = stringField(
400
+ tool,
401
+ "credentialStatus",
402
+ "credential_status"
403
+ );
404
+ const provider = stringField(tool, "provider");
405
+ const connectCommand = credentialStatus === "requires_connection" && (!byok || byok.setupUrl) && /^[a-z0-9][a-z0-9_-]*$/.test(provider) ? `deepline tools connect ${provider} --link --json` : void 0;
398
406
  return {
399
407
  kind: "tool",
400
408
  id: String(contract.toolId),
409
+ ...provider ? { provider } : {},
401
410
  displayName,
402
411
  description,
403
412
  cost: [
@@ -418,6 +427,10 @@ function describedTool(tool, requestedToolId) {
418
427
  recordField(contract, "executionMetadata").configuredRateLimits
419
428
  )
420
429
  ),
430
+ ...byok?.required === true ? { byok } : {},
431
+ ...typeof tool.connected === "boolean" ? { connected: tool.connected } : {},
432
+ ...credentialStatus ? { credentialStatus } : {},
433
+ ...connectCommand ? { connectCommand } : {},
421
434
  inputs: schemaFields(inputSchema),
422
435
  outputs: [...lists, ...values].map(({ field }) => field),
423
436
  rawResponse: schemaFields(outputSchema),
@@ -495,7 +508,7 @@ function toolMetadataJsonForDescribe(tool, requestedToolId, seedStarterScript) {
495
508
  deepline_usd_per_credit: _snakeDeeplineUsdPerCredit,
496
509
  deepline_pricing_summary: _snakeDeeplinePricingSummary,
497
510
  deepline_pricing_details: _snakeDeeplinePricingDetails,
498
- // BYOK is shown only on request, via describe --feature byok.
511
+ // The shared description adds BYOK when the tool needs its own credentials.
499
512
  byok: _byok,
500
513
  ...publicTool
501
514
  } = tool;
@@ -0,0 +1,209 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
+
3
+
4
+
5
+
6
+
7
+ var _chunkYGCKMI5Pjs = require('./chunk-YGCKMI5P.js');
8
+
9
+ // ../play-runtime/worker-api-types.ts
10
+ var DAYTONA_COMPUTE_PRICING_USD = {
11
+ vcpuSecond: 14e-6,
12
+ memoryGiBSecond: 45e-7,
13
+ storageGiBSecond: 3e-8,
14
+ includedStorageGiB: 5
15
+ };
16
+ var MODAL_SANDBOX_COMPUTE_PRICING_USD = {
17
+ physicalCoreSecond: 3942e-8,
18
+ memoryGiBSecond: 667e-8
19
+ };
20
+ var MODAL_SANDBOX_CPU_CORES = 0.5;
21
+ function modalSandboxResourcesForPlay(input) {
22
+ return {
23
+ physicalCpuCores: MODAL_SANDBOX_CPU_CORES * input.cpu,
24
+ memoryMiB: input.memoryGiB * 1024
25
+ };
26
+ }
27
+ function roundUsd(amount) {
28
+ return Number(Math.max(0, amount).toFixed(12));
29
+ }
30
+ function sandboxSizeMetadata(cpu, memoryGiB) {
31
+ const entry = Object.entries(_chunkYGCKMI5Pjs.PLAY_SANDBOX_SIZE_LIMITS).find(
32
+ ([, limits]) => limits.cpu === cpu && limits.memoryGiB === memoryGiB
33
+ );
34
+ return entry ? { sandboxSize: entry[0] } : {};
35
+ }
36
+ function runtimeLimitMetadata(maxBillingDurationSeconds, observedWallTimeSeconds) {
37
+ if (typeof maxBillingDurationSeconds !== "number" || !Number.isFinite(maxBillingDurationSeconds) || maxBillingDurationSeconds <= 0) {
38
+ return {};
39
+ }
40
+ return {
41
+ maxBillingDurationSeconds,
42
+ ...typeof observedWallTimeSeconds === "number" && Number.isFinite(observedWallTimeSeconds) ? { observedWallTimeSeconds: Math.max(0, observedWallTimeSeconds) } : {}
43
+ };
44
+ }
45
+ function resolveDaytonaSandboxComputeItem(input) {
46
+ const billableSeconds = Math.max(1, Math.ceil(input.wallTimeSeconds));
47
+ const cpu = Math.max(0, input.cpu);
48
+ const memoryGiB = Math.max(0, input.memoryGiB);
49
+ const billableDiskGiB = Math.max(
50
+ 0,
51
+ input.diskGiB - DAYTONA_COMPUTE_PRICING_USD.includedStorageGiB
52
+ );
53
+ const providerCostUsd = roundUsd(
54
+ billableSeconds * (cpu * DAYTONA_COMPUTE_PRICING_USD.vcpuSecond + memoryGiB * DAYTONA_COMPUTE_PRICING_USD.memoryGiBSecond + billableDiskGiB * DAYTONA_COMPUTE_PRICING_USD.storageGiBSecond)
55
+ );
56
+ return {
57
+ itemId: input.itemId,
58
+ source: _nullishCoalesce(input.source, () => ( "daytona")),
59
+ unit: "sandbox_second",
60
+ units: billableSeconds,
61
+ providerCostUsd,
62
+ metadata: {
63
+ ...sandboxSizeMetadata(cpu, memoryGiB),
64
+ sandboxId: _nullishCoalesce(input.sandboxId, () => ( null)),
65
+ cpu,
66
+ memoryGiB,
67
+ diskGiB: Math.max(0, input.diskGiB),
68
+ billableDiskGiB,
69
+ startedAt: input.startedAt,
70
+ endedAt: input.endedAt,
71
+ ...runtimeLimitMetadata(
72
+ input.maxBillingDurationSeconds,
73
+ input.observedWallTimeSeconds
74
+ )
75
+ }
76
+ };
77
+ }
78
+ function resolveModalSandboxComputeItem(input) {
79
+ const billableSeconds = Math.max(1, Math.ceil(input.wallTimeSeconds));
80
+ const physicalCpuCores = Math.max(0, input.physicalCpuCores);
81
+ const memoryGiB = Math.max(0, input.memoryGiB);
82
+ const providerCostUsd = roundUsd(
83
+ billableSeconds * (physicalCpuCores * MODAL_SANDBOX_COMPUTE_PRICING_USD.physicalCoreSecond + memoryGiB * MODAL_SANDBOX_COMPUTE_PRICING_USD.memoryGiBSecond)
84
+ );
85
+ return {
86
+ itemId: input.itemId,
87
+ source: "modal",
88
+ unit: "sandbox_second",
89
+ units: billableSeconds,
90
+ providerCostUsd,
91
+ metadata: {
92
+ ...sandboxSizeMetadata(
93
+ physicalCpuCores / MODAL_SANDBOX_CPU_CORES,
94
+ memoryGiB
95
+ ),
96
+ sandboxId: _nullishCoalesce(input.sandboxId, () => ( null)),
97
+ physicalCpuCores,
98
+ memoryGiB,
99
+ ...input.memoryLimitGiB === void 0 ? {} : {
100
+ memoryLimitGiB: input.memoryLimitGiB,
101
+ // The Preview evaluation preserves the existing compute price.
102
+ // Sampled burst cost is diagnostic until provider billing can be
103
+ // reconciled; a hard ceiling is never presented as actual usage.
104
+ costBasis: "reserved_resources"
105
+ },
106
+ startedAt: input.startedAt,
107
+ endedAt: input.endedAt,
108
+ ...runtimeLimitMetadata(
109
+ input.maxBillingDurationSeconds,
110
+ input.observedWallTimeSeconds
111
+ )
112
+ }
113
+ };
114
+ }
115
+
116
+ // ../play-runtime/runtime-constants.ts
117
+ var STANDARD_PLAY_RUNTIME_LIMIT_SECONDS = 30 * 60;
118
+ var PLAY_RUNNER_TERMINAL_GRACE_SECONDS = 90;
119
+ var PLAY_RUNNER_STARTUP_GRACE_SECONDS = 4 * 60;
120
+ var SANDBOX_NETWORK_CUT_MAX_MS = 11 * 6e4;
121
+ var RUNNER_GATEWAY_CONNECTION_RETRY_BUDGET_MS = SANDBOX_NETWORK_CUT_MAX_MS + 6e4;
122
+ var PLAY_RUNNER_TIMEOUT_SECONDS = 40 * 60;
123
+ var WORKFLOW_EXECUTOR_TOKEN_TTL_SECONDS = _chunkYGCKMI5Pjs.MAX_PLAY_SANDBOX_RUNTIME_LIMITS.timeoutSeconds + (PLAY_RUNNER_TIMEOUT_SECONDS - STANDARD_PLAY_RUNTIME_LIMIT_SECONDS);
124
+
125
+ // ../billing/compute-pricing-contract.ts
126
+ var COMPUTE_BILLING_MARKUP_MULTIPLIER = 5;
127
+ var DEFAULT_USD_PER_CUSTOMER_CREDIT = 0.1;
128
+ var DEFAULT_PROVIDER_MARKUP_MULTIPLIER = 1.4;
129
+ var MAX_SANDBOX_COMPUTE_BILLING_SECONDS = 60 * 60;
130
+ var PLAY_SANDBOX_COMPUTE_RATE_MULTIPLIERS = {
131
+ standard: 1,
132
+ large: 2.5,
133
+ xlarge: 5
134
+ };
135
+ var MAX_SANDBOX_COMPUTE_PROVIDER_COST_USD = Math.max(
136
+ ...Object.values(_chunkYGCKMI5Pjs.PLAY_SANDBOX_SIZE_LIMITS).flatMap((profile) => {
137
+ const modalResources = modalSandboxResourcesForPlay(profile);
138
+ return [
139
+ resolveDaytonaSandboxComputeItem({
140
+ itemId: "billing-cap",
141
+ wallTimeSeconds: MAX_SANDBOX_COMPUTE_BILLING_SECONDS,
142
+ cpu: profile.cpu,
143
+ memoryGiB: profile.memoryGiB,
144
+ diskGiB: profile.diskGiB
145
+ }).providerCostUsd,
146
+ resolveModalSandboxComputeItem({
147
+ itemId: "billing-cap",
148
+ wallTimeSeconds: MAX_SANDBOX_COMPUTE_BILLING_SECONDS,
149
+ physicalCpuCores: modalResources.physicalCpuCores,
150
+ memoryGiB: profile.memoryGiB
151
+ }).providerCostUsd
152
+ ];
153
+ })
154
+ );
155
+ function roundUpCredits(value) {
156
+ if (!Number.isFinite(value) || value <= 0) return 0;
157
+ return Math.ceil(value * 100) / 100;
158
+ }
159
+ function maximumPlaySandboxBillingSeconds(limits) {
160
+ return Math.min(
161
+ limits.timeoutSeconds + PLAY_RUNNER_TERMINAL_GRACE_SECONDS,
162
+ MAX_SANDBOX_COMPUTE_BILLING_SECONDS
163
+ );
164
+ }
165
+ function estimateDaytonaMaximumComputeCredits(limits) {
166
+ const item = resolveDaytonaSandboxComputeItem({
167
+ itemId: "estimate",
168
+ wallTimeSeconds: maximumPlaySandboxBillingSeconds(limits),
169
+ cpu: limits.cpu,
170
+ memoryGiB: limits.memoryGiB,
171
+ diskGiB: limits.diskGiB
172
+ });
173
+ return roundUpCredits(
174
+ item.providerCostUsd * COMPUTE_BILLING_MARKUP_MULTIPLIER * DEFAULT_PROVIDER_MARKUP_MULTIPLIER / DEFAULT_USD_PER_CUSTOMER_CREDIT
175
+ );
176
+ }
177
+ function estimateModalMaximumComputeCredits(limits, elasticMemory = false) {
178
+ const resources = modalSandboxResourcesForPlay(limits);
179
+ const item = resolveModalSandboxComputeItem({
180
+ itemId: "estimate",
181
+ wallTimeSeconds: maximumPlaySandboxBillingSeconds(limits),
182
+ physicalCpuCores: resources.physicalCpuCores,
183
+ memoryGiB: elasticMemory ? _chunkYGCKMI5Pjs.modalSandboxMemoryLimitGiBForPlay.call(void 0, limits) : limits.memoryGiB
184
+ });
185
+ return roundUpCredits(
186
+ item.providerCostUsd * COMPUTE_BILLING_MARKUP_MULTIPLIER * DEFAULT_PROVIDER_MARKUP_MULTIPLIER / DEFAULT_USD_PER_CUSTOMER_CREDIT
187
+ );
188
+ }
189
+ function estimateMaximumSandboxComputeCredits(limits, elasticMemory = false) {
190
+ return Math.max(
191
+ estimateDaytonaMaximumComputeCredits(limits),
192
+ estimateModalMaximumComputeCredits(limits, elasticMemory)
193
+ );
194
+ }
195
+ function formatNonStandardSandboxRuntimeWarning(limits) {
196
+ const size = _chunkYGCKMI5Pjs.playSandboxSizeForLimits.call(void 0, limits);
197
+ if (!size) return null;
198
+ if (size === "standard" && limits.timeoutSeconds <= _chunkYGCKMI5Pjs.STANDARD_PLAY_SANDBOX_RUNTIME_LIMITS.timeoutSeconds) {
199
+ return null;
200
+ }
201
+ const maximumComputeCredits = estimateMaximumSandboxComputeCredits(limits);
202
+ const quotedTimeout = `${Math.ceil(limits.timeoutSeconds / 60)}m`;
203
+ return `This Play requests the ${size} sandbox for up to ${limits.timeoutSeconds}s (${limits.memoryGiB}GiB memory, ${limits.cpu} CPU, ${limits.diskGiB}GiB disk). Resource-based pricing estimate: ${maximumComputeCredits.toFixed(2)} Deepline credits. Workspace plan pricing can differ. Run deepline billing quote --sandbox-timeout ${quotedTimeout} --sandbox-size ${size} for your workspace's session ceiling.`;
204
+ }
205
+
206
+
207
+
208
+
209
+ exports.PLAY_SANDBOX_COMPUTE_RATE_MULTIPLIERS = PLAY_SANDBOX_COMPUTE_RATE_MULTIPLIERS; exports.formatNonStandardSandboxRuntimeWarning = formatNonStandardSandboxRuntimeWarning;
@@ -1,16 +1,16 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
- var _chunkUOANF3DRjs = require('./chunk-UOANF3DR.js');
3
+ var _chunk7P2QVMBPjs = require('./chunk-7P2QVMBP.js');
4
4
 
5
5
 
6
6
 
7
- var _chunkJLYDLK6Xjs = require('./chunk-JLYDLK6X.js');
7
+ var _chunkWBIDPDKJjs = require('./chunk-WBIDPDKJ.js');
8
8
 
9
9
  // src/client.ts
10
- var DeeplineClient2 = class extends _chunkUOANF3DRjs.DeeplineClient {
10
+ var DeeplineClient2 = class extends _chunk7P2QVMBPjs.DeeplineClient {
11
11
  constructor(options) {
12
- const config = _chunkJLYDLK6Xjs.resolveConfig.call(void 0, options);
13
- super(config, new (0, _chunkJLYDLK6Xjs.HttpClient)(config), _optionalChain([options, 'optionalAccess', _ => _.timeout]));
12
+ const config = _chunkWBIDPDKJjs.resolveConfig.call(void 0, options);
13
+ super(config, new (0, _chunkWBIDPDKJjs.HttpClient)(config), _optionalChain([options, 'optionalAccess', _ => _.timeout]));
14
14
  }
15
15
  };
16
16
 
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  resolveShellSpawn
3
- } from "./chunk-NZXB27TP.mjs";
3
+ } from "./chunk-XHZSPMNC.mjs";
4
4
 
5
5
  // src/cli/npm-script-policy.ts
6
6
  import { spawnSync } from "child_process";