deepline 0.3.407 → 0.3.408
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.
- package/dist/bundling-sources/sdk/src/client.ts +2 -0
- package/dist/bundling-sources/sdk/src/play.ts +13 -0
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/types.ts +23 -0
- package/dist/bundling-sources/shared_libs/play-runtime/admission-timings.ts +64 -0
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +11 -1
- package/dist/bundling-sources/shared_libs/play-runtime/modal-runtime-config.ts +1 -4
- package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +2 -0
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/local-process.ts +15 -6
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +188 -45
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/run-ledger-outbox-recovery.ts +22 -4
- package/dist/bundling-sources/shared_libs/play-runtime/tool-http-errors.ts +10 -4
- package/dist/bundling-sources/shared_libs/play-runtime/tool-result.ts +72 -0
- package/dist/bundling-sources/shared_libs/play-runtime/webhook-receipt-source-commit-retry.ts +90 -0
- package/dist/bundling-sources/shared_libs/play-runtime/worker-api-types.ts +5 -0
- package/dist/bundling-sources/shared_libs/plays/tool-result-types.ts +6 -0
- package/dist/cli/auth-3GB2K636.js +40 -0
- package/dist/cli/{auth-WURWNNLE.mjs → auth-UVD3CUBB.mjs} +4 -4
- package/dist/cli/{billing-BP3E6WIM.mjs → billing-BZVTXXLM.mjs} +23 -16
- package/dist/cli/{billing-2QJGXGJX.js → billing-BZVYAF6T.js} +92 -85
- package/dist/cli/{chunk-Y6CX4QPR.js → chunk-2XXXFPTD.js} +67 -67
- package/dist/cli/{chunk-RZLXVHNO.js → chunk-3ZB6IIA7.js} +26 -26
- package/dist/cli/{chunk-BKC6VMYZ.mjs → chunk-4CFULMRB.mjs} +73 -4
- package/dist/cli/{chunk-6JZZNP5G.mjs → chunk-4QFT5LGV.mjs} +2 -2
- package/dist/cli/{chunk-H6EWQFPQ.js → chunk-4RNDKFNQ.js} +2 -2
- package/dist/cli/{chunk-GAMFK2ZP.mjs → chunk-67RWR34T.mjs} +10 -3
- package/dist/cli/{chunk-KUQAU5MG.js → chunk-AUMD2VXP.js} +6 -6
- package/dist/cli/{chunk-IY6GKJ4O.js → chunk-BRJUESQV.js} +50 -50
- package/dist/cli/{chunk-7LKYHZVB.js → chunk-D6FFBSM5.js} +1 -1
- package/dist/cli/{chunk-AYHLUHE5.js → chunk-E3PJF6YP.js} +6 -2
- package/dist/cli/{chunk-G6U74WNM.js → chunk-ECVLPS67.js} +15 -15
- package/dist/cli/{chunk-QJBJZVG6.js → chunk-HQY2SG3K.js} +15 -8
- package/dist/cli/{chunk-P7HOTKOK.mjs → chunk-I3DHIXVJ.mjs} +4 -4
- package/dist/cli/{chunk-L25GBGQU.mjs → chunk-IOHRWLQE.mjs} +6 -6
- package/dist/cli/{chunk-UFFSOV6I.mjs → chunk-IWBXJDZA.mjs} +2 -2
- package/dist/cli/{chunk-URWF7NGQ.js → chunk-J5PTX66Y.js} +28 -14
- package/dist/cli/{chunk-J67NU4MQ.mjs → chunk-LOYISF7S.mjs} +1 -1
- package/dist/cli/{chunk-4TV43THC.mjs → chunk-MJELBQBU.mjs} +4 -4
- package/dist/cli/{chunk-WJYPBHTE.js → chunk-OSFWFV72.js} +11 -4
- package/dist/cli/{chunk-ZI2ZNDJK.mjs → chunk-PYZZMAJQ.mjs} +28 -14
- package/dist/cli/{chunk-G4LJS2RE.js → chunk-Q3LFI3VH.js} +8 -8
- package/dist/cli/{chunk-D2ZRMZKF.js → chunk-Q3PUHXOY.js} +99 -30
- package/dist/cli/{chunk-THHM4DPE.js → chunk-QUAQX3FQ.js} +4 -4
- package/dist/cli/{chunk-RMZAOYDN.js → chunk-RWCY6YI2.js} +53 -53
- package/dist/cli/{chunk-ZBCTXQ3P.mjs → chunk-SD7MXAJA.mjs} +1 -1
- package/dist/cli/{chunk-UFS752TU.mjs → chunk-SJVVBWRL.mjs} +5 -1
- package/dist/cli/{chunk-QJAX7QN7.mjs → chunk-URACNNLO.mjs} +2 -2
- package/dist/cli/{chunk-WXLOW623.mjs → chunk-WPAB4DCU.mjs} +14 -7
- package/dist/cli/{chunk-UPEOEYZ3.mjs → chunk-WTT6CLED.mjs} +1 -1
- package/dist/cli/{chunk-N6OAMAO5.mjs → chunk-XXLXOUUU.mjs} +1 -1
- package/dist/cli/{chunk-XT6GG3QO.mjs → chunk-YMOFWHGO.mjs} +3 -3
- package/dist/cli/{chunk-SOQIPKF2.js → chunk-ZBABPK6Y.js} +8 -8
- package/dist/cli/command-docs.js +2 -2
- package/dist/cli/command-docs.mjs +1 -1
- package/dist/cli/{csv-N6KYTG7L.mjs → csv-WPSXG6ZZ.mjs} +3 -3
- package/dist/cli/{csv-7E5BE23B.js → csv-XLGLHJ6P.js} +12 -12
- package/dist/cli/{db-4VLZP33O.js → db-5PTNJG4X.js} +25 -25
- package/dist/cli/{db-XMBJNVBD.mjs → db-ABS57ABJ.mjs} +4 -4
- package/dist/cli/{describe-4I6EIVXD.js → describe-EZS6PQXA.js} +11 -11
- package/dist/cli/{describe-WERH4TD2.mjs → describe-PVWQJ2PB.mjs} +7 -7
- package/dist/cli/describe-core.d.mts +2 -2
- package/dist/cli/describe-core.d.ts +2 -2
- package/dist/cli/{executions-W7TWJRBK.js → executions-FNTAFQ7Y.js} +6 -6
- package/dist/cli/{executions-JWQXE7G6.mjs → executions-OKJGATQZ.mjs} +4 -4
- package/dist/cli/{feedback-FMGRC6KO.js → feedback-6YBOMSUA.js} +7 -7
- package/dist/cli/{feedback-OEJFX4F7.mjs → feedback-W27HDMRR.mjs} +3 -3
- package/dist/cli/git-YKUXXJOR.js +24 -0
- package/dist/cli/{git-IVC4KHXX.mjs → git-YOOUEL6M.mjs} +4 -4
- package/dist/cli/index.js +204 -127
- package/dist/cli/index.mjs +124 -47
- package/dist/cli/{legacy-noops-X3BQ7MUK.js → legacy-noops-2VZ7XT6C.js} +7 -7
- package/dist/cli/{legacy-noops-LT36CLWZ.mjs → legacy-noops-V6OKW7VR.mjs} +4 -4
- package/dist/cli/{monitors-DLIIAVLW.js → monitors-FBWGVIUS.js} +84 -84
- package/dist/cli/{monitors-MNLCELF7.mjs → monitors-P2YYWTWT.mjs} +4 -4
- package/dist/cli/{org-CYHDEW7P.js → org-3XUSVX5T.js} +64 -64
- package/dist/cli/{org-QV5LMUPT.mjs → org-DVMG6H3C.mjs} +4 -4
- package/dist/cli/{play-5Z4ROZ3P.mjs → play-GNC5CQAS.mjs} +70 -18
- package/dist/cli/{play-MEFXC2QA.js → play-YG5L4BWQ.js} +345 -293
- package/dist/cli/{providers-2MKUNFBQ.js → providers-7PSWG2OV.js} +7 -7
- package/dist/cli/{providers-FJLYSHB3.mjs → providers-JR33SLWL.mjs} +4 -4
- package/dist/cli/{quickstart-ULWXKAOT.js → quickstart-FDVZ5BL3.js} +5 -5
- package/dist/cli/{quickstart-PQO3OQRT.mjs → quickstart-VUOBQYIQ.mjs} +3 -3
- package/dist/cli/{search-KGAAXMDG.mjs → search-JZYLO33K.mjs} +5 -5
- package/dist/cli/search-PPPYC5OZ.js +30 -0
- package/dist/cli/{secrets-PD5I3KAF.mjs → secrets-3MCYBT4I.mjs} +4 -4
- package/dist/cli/{secrets-X2VGG2PO.js → secrets-VS266FVA.js} +13 -13
- package/dist/cli/{sessions-3WVEU4PE.mjs → sessions-ELLLT23E.mjs} +4 -4
- package/dist/cli/{sessions-R3XAKTBQ.js → sessions-TEHEWW7O.js} +5 -5
- package/dist/cli/{settings-ZIDO3IP6.js → settings-7364NMMA.js} +75 -75
- package/dist/cli/{settings-645RSFQX.mjs → settings-PZCKAFII.mjs} +8 -8
- package/dist/cli/{setup-LISKIJKP.mjs → setup-A7GQ4KIA.mjs} +7 -7
- package/dist/cli/{setup-LH5HOZ3D.js → setup-PMWYLCT6.js} +42 -42
- package/dist/cli/skills-SYS7VRRK.js +29 -0
- package/dist/cli/{skills-VVQJHLSF.mjs → skills-WS6BIFPQ.mjs} +5 -5
- package/dist/cli/{tools-Y3LOMXFT.mjs → tools-BR4DOZA2.mjs} +7 -7
- package/dist/cli/{tools-FTPJCNAM.js → tools-KK4BKVQR.js} +8 -8
- package/dist/cli/update-2IV5JTX2.js +29 -0
- package/dist/cli/{update-DOBNQNJI.mjs → update-D2B7UNFT.mjs} +7 -7
- package/dist/cli/{workflow-LGENKZBV.js → workflow-6ODTCYXU.js} +15 -15
- package/dist/cli/{workflow-ZMAA5VCN.mjs → workflow-PQXC2R47.mjs} +5 -5
- package/dist/{client-IrPHUE5J.d.ts → client-BcvhDfJJ.d.ts} +26 -2
- package/dist/{client-6rEB46Lv.d.mts → client-Z9Pye1Wm.d.mts} +26 -2
- package/dist/{compiler-manifest-BHnXE43X.d.ts → compiler-manifest-Ycx-hoAr.d.mts} +2 -0
- package/dist/{compiler-manifest-BHnXE43X.d.mts → compiler-manifest-Ycx-hoAr.d.ts} +2 -0
- package/dist/{index-Da_Y8z5e.d.mts → index-CZXgiN3E.d.mts} +1 -1
- package/dist/{index-SODb2ROS.d.ts → index-NPG5pqxQ.d.ts} +1 -1
- package/dist/index.d.mts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +26 -9
- package/dist/index.mjs +23 -6
- package/dist/install-integrity.json +86 -84
- package/dist/plays/bundle-play-file.d.mts +3 -3
- package/dist/plays/bundle-play-file.d.ts +3 -3
- package/dist/plays/play-description.d.mts +2 -2
- package/dist/plays/play-description.d.ts +2 -2
- package/dist/plays/run-request.d.mts +2 -2
- package/dist/plays/run-request.d.ts +2 -2
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/package.json +1 -1
- package/dist/cli/auth-4JTX6AGM.js +0 -40
- package/dist/cli/git-OFXE7G4X.js +0 -24
- package/dist/cli/search-ANKSJ224.js +0 -30
- package/dist/cli/skills-WLHYSVQA.js +0 -29
- package/dist/cli/update-A622H2DZ.js +0 -29
|
@@ -1,4 +1,8 @@
|
|
|
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; }
|
|
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
|
+
|
|
3
|
+
var _chunkQ3PUHXOYjs = require('./chunk-Q3PUHXOY.js');
|
|
4
|
+
|
|
5
|
+
// src/cli/compatibility-catalog.ts
|
|
2
6
|
var readers = /* @__PURE__ */ new WeakMap();
|
|
3
7
|
function registerCompatibilityCatalog(command, read) {
|
|
4
8
|
readers.set(command, read);
|
|
@@ -11,6 +15,9 @@ function compatibilityCatalog(command) {
|
|
|
11
15
|
var _crypto = require('crypto');
|
|
12
16
|
var TOOL_EXECUTE_PROGRESS_INTERVAL_MS = 15e3;
|
|
13
17
|
var activeToolExecuteCommand = null;
|
|
18
|
+
function progressLine(line) {
|
|
19
|
+
if (!_chunkQ3PUHXOYjs.isJsonOutputMode.call(void 0, )) console.error(line);
|
|
20
|
+
}
|
|
14
21
|
function beginToolExecuteCommand() {
|
|
15
22
|
if (activeToolExecuteCommand) return activeToolExecuteCommand.invocationId;
|
|
16
23
|
const invocationId = _crypto.randomUUID.call(void 0, );
|
|
@@ -18,7 +25,7 @@ function beginToolExecuteCommand() {
|
|
|
18
25
|
invocationId,
|
|
19
26
|
startedAt: performance.now()
|
|
20
27
|
};
|
|
21
|
-
|
|
28
|
+
progressLine(`[tools execute ${invocationId}] started`);
|
|
22
29
|
return invocationId;
|
|
23
30
|
}
|
|
24
31
|
function getToolExecuteInvocationId() {
|
|
@@ -29,9 +36,9 @@ async function runToolExecuteStage(stage, action) {
|
|
|
29
36
|
if (!command) return action();
|
|
30
37
|
const startedAt = performance.now();
|
|
31
38
|
const elapsedMs = () => Math.round(performance.now() - startedAt);
|
|
32
|
-
|
|
39
|
+
progressLine(`[tools execute ${command.invocationId}] ${stage} started`);
|
|
33
40
|
const progressTimer = setInterval(() => {
|
|
34
|
-
|
|
41
|
+
progressLine(
|
|
35
42
|
`[tools execute ${command.invocationId}] ${stage} still running (${elapsedMs()}ms)`
|
|
36
43
|
);
|
|
37
44
|
}, TOOL_EXECUTE_PROGRESS_INTERVAL_MS);
|
|
@@ -39,17 +46,17 @@ async function runToolExecuteStage(stage, action) {
|
|
|
39
46
|
try {
|
|
40
47
|
const result = await action();
|
|
41
48
|
if (result === false) {
|
|
42
|
-
|
|
49
|
+
progressLine(
|
|
43
50
|
`[tools execute ${command.invocationId}] ${stage} failed after ${elapsedMs()}ms`
|
|
44
51
|
);
|
|
45
52
|
} else {
|
|
46
|
-
|
|
53
|
+
progressLine(
|
|
47
54
|
`[tools execute ${command.invocationId}] ${stage} completed in ${elapsedMs()}ms`
|
|
48
55
|
);
|
|
49
56
|
}
|
|
50
57
|
return result;
|
|
51
58
|
} catch (error) {
|
|
52
|
-
|
|
59
|
+
progressLine(
|
|
53
60
|
`[tools execute ${command.invocationId}] ${stage} failed after ${elapsedMs()}ms`
|
|
54
61
|
);
|
|
55
62
|
throw error;
|
|
@@ -60,7 +67,7 @@ async function runToolExecuteStage(stage, action) {
|
|
|
60
67
|
function finishToolExecuteCommand() {
|
|
61
68
|
const command = activeToolExecuteCommand;
|
|
62
69
|
if (!command) return;
|
|
63
|
-
|
|
70
|
+
progressLine(
|
|
64
71
|
`[tools execute ${command.invocationId}] finished in ${Math.round(performance.now() - command.startedAt)}ms`
|
|
65
72
|
);
|
|
66
73
|
activeToolExecuteCommand = null;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
npmSupportsAllowScripts,
|
|
3
3
|
readNpmVersion
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-XXLXOUUU.mjs";
|
|
5
5
|
import {
|
|
6
6
|
resolveShellSpawn,
|
|
7
7
|
runSkillsCommand
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-MJELBQBU.mjs";
|
|
9
9
|
import {
|
|
10
10
|
printCommandEnvelope
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-4CFULMRB.mjs";
|
|
12
12
|
import {
|
|
13
13
|
autoDetectBaseUrl
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-SD7MXAJA.mjs";
|
|
15
15
|
|
|
16
16
|
// src/cli/commands/update.ts
|
|
17
17
|
import { spawn, spawnSync } from "child_process";
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
recentSearchRef,
|
|
7
7
|
registerDeprecatedSearchCommand
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-YMOFWHGO.mjs";
|
|
9
9
|
import {
|
|
10
10
|
arrayField,
|
|
11
11
|
formatModelDescription,
|
|
@@ -45,7 +45,7 @@ import {
|
|
|
45
45
|
import {
|
|
46
46
|
DeeplineClient,
|
|
47
47
|
validateExecutionIdempotencyKey
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-LOYISF7S.mjs";
|
|
49
49
|
import {
|
|
50
50
|
stableStringify
|
|
51
51
|
} from "./chunk-UBKA33KY.mjs";
|
|
@@ -54,7 +54,7 @@ import {
|
|
|
54
54
|
getToolExecuteInvocationId,
|
|
55
55
|
registerCompatibilityCatalog,
|
|
56
56
|
runToolExecuteStage
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-WPAB4DCU.mjs";
|
|
58
58
|
import {
|
|
59
59
|
printCommandEnvelope,
|
|
60
60
|
printCompactJson,
|
|
@@ -62,11 +62,11 @@ import {
|
|
|
62
62
|
printJsonError,
|
|
63
63
|
renderCommandEnvelopeText,
|
|
64
64
|
shouldEmitJson
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-4CFULMRB.mjs";
|
|
66
66
|
import {
|
|
67
67
|
resolveConfig,
|
|
68
68
|
sdkCliStateDirPath
|
|
69
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-SD7MXAJA.mjs";
|
|
70
70
|
import {
|
|
71
71
|
DeeplineError
|
|
72
72
|
} from "./chunk-NXGCO4JB.mjs";
|
|
@@ -941,7 +941,7 @@ Examples:
|
|
|
941
941
|
process.exitCode = await narrowView();
|
|
942
942
|
return;
|
|
943
943
|
}
|
|
944
|
-
const { describeAnything } = await import("./describe-
|
|
944
|
+
const { describeAnything } = await import("./describe-PVWQJ2PB.mjs");
|
|
945
945
|
process.exitCode = await describeAnything(
|
|
946
946
|
toolId,
|
|
947
947
|
{
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
argsWantJson,
|
|
3
3
|
openInBrowser,
|
|
4
4
|
printCommandEnvelope
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-4CFULMRB.mjs";
|
|
6
6
|
import {
|
|
7
7
|
ACTIVE_ORG_ID_ENV,
|
|
8
8
|
ACTIVE_ORG_NAME_ENV,
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
saveHostEnvValues,
|
|
26
26
|
saveProjectDeeplineEnvValues,
|
|
27
27
|
storedHostApiKey
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-SD7MXAJA.mjs";
|
|
29
29
|
|
|
30
30
|
// src/cli/commands/auth.ts
|
|
31
31
|
import {
|
|
@@ -2,14 +2,17 @@
|
|
|
2
2
|
var CONVENTIONS = `
|
|
3
3
|
[[cli:
|
|
4
4
|
Conventions (apply to every command):
|
|
5
|
-
Output mode: readable text by default. --json
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
Output mode: readable text by default. Add --json for machine-readable
|
|
6
|
+
output: stdout is one JSON document, including errors and notices;
|
|
7
|
+
stderr stays empty. tools execute is the exception: it prints JSON;
|
|
8
|
+
--output-format csv prints a readable summary and writes the rows to a
|
|
9
|
+
CSV file.
|
|
10
|
+
Streams: without --json, stdout carries only the command result. Progress,
|
|
11
|
+
update notices, skills-sync notes, and warnings go to stderr.
|
|
12
|
+
Piping JSON: pass --json only when a program parses the output. Under
|
|
13
|
+
--json, usage errors are {ok:false,error:{code,message,details.help}}
|
|
14
|
+
and notices (update available, skills, auth) arrive in notices[];
|
|
15
|
+
| head and | tail cut the document.
|
|
13
16
|
JSON envelope: most payloads include render.sections[].lines (the human
|
|
14
17
|
summary as text), next.* (exact follow-up commands; run commands name
|
|
15
18
|
them actions.*Cmd), and command_context.
|
|
@@ -269,13 +272,18 @@ When:
|
|
|
269
272
|
reports a balance or insufficient-credits error.
|
|
270
273
|
[[cli:
|
|
271
274
|
Input:
|
|
272
|
-
No arguments. Prints
|
|
273
|
-
|
|
275
|
+
No arguments. Prints the posted balance, spendable credits and pending
|
|
276
|
+
spending. --verbose adds exposure details; --json returns the full record.
|
|
274
277
|
]]
|
|
275
278
|
[[cli:
|
|
276
279
|
Output (JSON):
|
|
277
280
|
balance (Deepline credits), balance_display, rough_usd_balance,
|
|
278
|
-
balance_status,
|
|
281
|
+
balance_status, posted_balance_credits, pending_spend_credits,
|
|
282
|
+
spendable_balance_credits, spendable_balance_status and render.sections.
|
|
283
|
+
The three credit amounts come from the same admission snapshot. Spendable
|
|
284
|
+
credits subtract pending spending; a partial exposure diagnostic is not
|
|
285
|
+
spendable capacity. Null/unavailable means complete capacity could not be read.
|
|
286
|
+
Spending limits can still block a funded call. The balance includes other activity
|
|
279
287
|
in the workspace, so a before and after difference does not isolate one
|
|
280
288
|
command; use billing usage for that.
|
|
281
289
|
]]
|
|
@@ -485,7 +493,8 @@ When:
|
|
|
485
493
|
[[cli:
|
|
486
494
|
Input:
|
|
487
495
|
The tool id. Prints readable text by default; read that
|
|
488
|
-
form and pass --json only for a program
|
|
496
|
+
form and pass --json only for a program; stdout is then one JSON
|
|
497
|
+
document. --pricing-only, --schema-only,
|
|
489
498
|
--examples-only, --getters-only print one section. --out <path> saves the
|
|
490
499
|
output to a file. get is an alias of describe, and deepline describe <id>
|
|
491
500
|
is the same read for a tool, a play, or a monitor type.
|
|
@@ -815,6 +824,7 @@ When:
|
|
|
815
824
|
Input:
|
|
816
825
|
The play reference from search (prebuilt/... or <workspace>/...).
|
|
817
826
|
--compact shortens schemas. --json prints JSON.
|
|
827
|
+
To parse the output, add --json; stdout is then one JSON document.
|
|
818
828
|
]]
|
|
819
829
|
[[cli:
|
|
820
830
|
Output (JSON):
|
|
@@ -943,7 +953,8 @@ Output (JSON, printed when the run ends):
|
|
|
943
953
|
exact follow-up commands: getRunCmd, getFullRunCmd, getBillingCmd,
|
|
944
954
|
getLogsCmd, exportDatasetCmds[], queryTableSqlCmds[]. Rows are not in this
|
|
945
955
|
payload. Progress lines are printed while it waits; the JSON is the last
|
|
946
|
-
thing printed.
|
|
956
|
+
thing printed. To parse it, add --json: progress is suppressed and stdout
|
|
957
|
+
is one JSON document.
|
|
947
958
|
]]
|
|
948
959
|
[[mcp:
|
|
949
960
|
Output:
|
|
@@ -1168,6 +1179,7 @@ Input:
|
|
|
1168
1179
|
billing and timeline (large). --log-failed attaches the failure log window.
|
|
1169
1180
|
--input prints the original input (may contain customer data). --json
|
|
1170
1181
|
prints JSON; --json run.status,datasets.name selects fields.
|
|
1182
|
+
To parse the output (also with --full), add --json; stdout is then one JSON document.
|
|
1171
1183
|
]]
|
|
1172
1184
|
[[cli:
|
|
1173
1185
|
Output (JSON):
|
|
@@ -1254,6 +1266,7 @@ Input:
|
|
|
1254
1266
|
returned more than one (default: the returned dataset, usually
|
|
1255
1267
|
result.rows). --metadata-out <path.json> writes the export metadata. --json
|
|
1256
1268
|
prints the receipt as JSON; it does not change the file format.
|
|
1269
|
+
To parse the receipt, add --json; stdout is then one JSON document.
|
|
1257
1270
|
]]
|
|
1258
1271
|
Output (JSON):
|
|
1259
1272
|
csv_path or json_path (absolute), source, rowCount, columns[] (the CSV
|
|
@@ -1343,7 +1356,8 @@ Input:
|
|
|
1343
1356
|
Output:
|
|
1344
1357
|
Log lines (human) or a JSON envelope; with --out, the file path. Follow
|
|
1345
1358
|
next.logs for the next page of events, and pass nextCursor to --cursor for
|
|
1346
|
-
older text logs.
|
|
1359
|
+
older text logs. To parse the output, add --json; stdout is then one JSON
|
|
1360
|
+
document.
|
|
1347
1361
|
]]
|
|
1348
1362
|
Cost:
|
|
1349
1363
|
Free.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getActiveCliProgress
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-67RWR34T.mjs";
|
|
4
4
|
import {
|
|
5
5
|
printCommandEnvelope
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-4CFULMRB.mjs";
|
|
7
7
|
import {
|
|
8
8
|
DEFAULT_SKILL_AGENTS,
|
|
9
9
|
KNOWN_SKILL_AGENTS,
|
|
@@ -22,13 +22,13 @@ import {
|
|
|
22
22
|
sdkCliStateDirPath,
|
|
23
23
|
skillsAgentPathSegment,
|
|
24
24
|
writeSdkSkillsLocalVersion
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-SD7MXAJA.mjs";
|
|
26
26
|
import {
|
|
27
27
|
DeeplineError
|
|
28
28
|
} from "./chunk-NXGCO4JB.mjs";
|
|
29
29
|
import {
|
|
30
30
|
SDK_RELEASE
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-WTT6CLED.mjs";
|
|
32
32
|
|
|
33
33
|
// src/cli/commands/skills.ts
|
|
34
34
|
import { spawn as spawn2 } from "child_process";
|
|
@@ -1,9 +1,10 @@
|
|
|
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
|
|
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
|
+
|
|
3
|
+
var _chunkQ3PUHXOYjs = require('./chunk-Q3PUHXOY.js');
|
|
4
|
+
|
|
5
|
+
// src/cli/progress.ts
|
|
2
6
|
var _worker_threads = require('worker_threads');
|
|
3
7
|
var CliProgress = (_class = class {
|
|
4
|
-
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);
|
|
5
|
-
this.enabled = enabled;
|
|
6
|
-
}
|
|
7
8
|
__init() {this.lastMessage = null}
|
|
8
9
|
__init2() {this.interactive = Boolean(process.stderr.isTTY)}
|
|
9
10
|
__init3() {this.grey = "\x1B[90m"}
|
|
@@ -11,6 +12,11 @@ var CliProgress = (_class = class {
|
|
|
11
12
|
__init5() {this.dim = "\x1B[2m"}
|
|
12
13
|
__init6() {this.reset = "\x1B[0m"}
|
|
13
14
|
__init7() {this.worker = null}
|
|
15
|
+
|
|
16
|
+
// --json output is one JSON document: progress never renders under it.
|
|
17
|
+
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);
|
|
18
|
+
this.enabled = enabled && !_chunkQ3PUHXOYjs.isJsonOutputMode.call(void 0, );
|
|
19
|
+
}
|
|
14
20
|
phase(message) {
|
|
15
21
|
if (!this.enabled || this.lastMessage === message) {
|
|
16
22
|
return;
|
|
@@ -34,6 +40,7 @@ var CliProgress = (_class = class {
|
|
|
34
40
|
this.settle("\u2717");
|
|
35
41
|
}
|
|
36
42
|
writeLogLine(line) {
|
|
43
|
+
if (_chunkQ3PUHXOYjs.isJsonOutputMode.call(void 0, )) return;
|
|
37
44
|
if (!this.enabled) {
|
|
38
45
|
process.stderr.write(`${line}
|
|
39
46
|
`);
|
|
@@ -2,14 +2,17 @@
|
|
|
2
2
|
var CONVENTIONS = `
|
|
3
3
|
[[cli:
|
|
4
4
|
Conventions (apply to every command):
|
|
5
|
-
Output mode: readable text by default. --json
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
Output mode: readable text by default. Add --json for machine-readable
|
|
6
|
+
output: stdout is one JSON document, including errors and notices;
|
|
7
|
+
stderr stays empty. tools execute is the exception: it prints JSON;
|
|
8
|
+
--output-format csv prints a readable summary and writes the rows to a
|
|
9
|
+
CSV file.
|
|
10
|
+
Streams: without --json, stdout carries only the command result. Progress,
|
|
11
|
+
update notices, skills-sync notes, and warnings go to stderr.
|
|
12
|
+
Piping JSON: pass --json only when a program parses the output. Under
|
|
13
|
+
--json, usage errors are {ok:false,error:{code,message,details.help}}
|
|
14
|
+
and notices (update available, skills, auth) arrive in notices[];
|
|
15
|
+
| head and | tail cut the document.
|
|
13
16
|
JSON envelope: most payloads include render.sections[].lines (the human
|
|
14
17
|
summary as text), next.* (exact follow-up commands; run commands name
|
|
15
18
|
them actions.*Cmd), and command_context.
|
|
@@ -269,13 +272,18 @@ When:
|
|
|
269
272
|
reports a balance or insufficient-credits error.
|
|
270
273
|
[[cli:
|
|
271
274
|
Input:
|
|
272
|
-
No arguments. Prints
|
|
273
|
-
|
|
275
|
+
No arguments. Prints the posted balance, spendable credits and pending
|
|
276
|
+
spending. --verbose adds exposure details; --json returns the full record.
|
|
274
277
|
]]
|
|
275
278
|
[[cli:
|
|
276
279
|
Output (JSON):
|
|
277
280
|
balance (Deepline credits), balance_display, rough_usd_balance,
|
|
278
|
-
balance_status,
|
|
281
|
+
balance_status, posted_balance_credits, pending_spend_credits,
|
|
282
|
+
spendable_balance_credits, spendable_balance_status and render.sections.
|
|
283
|
+
The three credit amounts come from the same admission snapshot. Spendable
|
|
284
|
+
credits subtract pending spending; a partial exposure diagnostic is not
|
|
285
|
+
spendable capacity. Null/unavailable means complete capacity could not be read.
|
|
286
|
+
Spending limits can still block a funded call. The balance includes other activity
|
|
279
287
|
in the workspace, so a before and after difference does not isolate one
|
|
280
288
|
command; use billing usage for that.
|
|
281
289
|
]]
|
|
@@ -485,7 +493,8 @@ When:
|
|
|
485
493
|
[[cli:
|
|
486
494
|
Input:
|
|
487
495
|
The tool id. Prints readable text by default; read that
|
|
488
|
-
form and pass --json only for a program
|
|
496
|
+
form and pass --json only for a program; stdout is then one JSON
|
|
497
|
+
document. --pricing-only, --schema-only,
|
|
489
498
|
--examples-only, --getters-only print one section. --out <path> saves the
|
|
490
499
|
output to a file. get is an alias of describe, and deepline describe <id>
|
|
491
500
|
is the same read for a tool, a play, or a monitor type.
|
|
@@ -815,6 +824,7 @@ When:
|
|
|
815
824
|
Input:
|
|
816
825
|
The play reference from search (prebuilt/... or <workspace>/...).
|
|
817
826
|
--compact shortens schemas. --json prints JSON.
|
|
827
|
+
To parse the output, add --json; stdout is then one JSON document.
|
|
818
828
|
]]
|
|
819
829
|
[[cli:
|
|
820
830
|
Output (JSON):
|
|
@@ -943,7 +953,8 @@ Output (JSON, printed when the run ends):
|
|
|
943
953
|
exact follow-up commands: getRunCmd, getFullRunCmd, getBillingCmd,
|
|
944
954
|
getLogsCmd, exportDatasetCmds[], queryTableSqlCmds[]. Rows are not in this
|
|
945
955
|
payload. Progress lines are printed while it waits; the JSON is the last
|
|
946
|
-
thing printed.
|
|
956
|
+
thing printed. To parse it, add --json: progress is suppressed and stdout
|
|
957
|
+
is one JSON document.
|
|
947
958
|
]]
|
|
948
959
|
[[mcp:
|
|
949
960
|
Output:
|
|
@@ -1168,6 +1179,7 @@ Input:
|
|
|
1168
1179
|
billing and timeline (large). --log-failed attaches the failure log window.
|
|
1169
1180
|
--input prints the original input (may contain customer data). --json
|
|
1170
1181
|
prints JSON; --json run.status,datasets.name selects fields.
|
|
1182
|
+
To parse the output (also with --full), add --json; stdout is then one JSON document.
|
|
1171
1183
|
]]
|
|
1172
1184
|
[[cli:
|
|
1173
1185
|
Output (JSON):
|
|
@@ -1254,6 +1266,7 @@ Input:
|
|
|
1254
1266
|
returned more than one (default: the returned dataset, usually
|
|
1255
1267
|
result.rows). --metadata-out <path.json> writes the export metadata. --json
|
|
1256
1268
|
prints the receipt as JSON; it does not change the file format.
|
|
1269
|
+
To parse the receipt, add --json; stdout is then one JSON document.
|
|
1257
1270
|
]]
|
|
1258
1271
|
Output (JSON):
|
|
1259
1272
|
csv_path or json_path (absolute), source, rowCount, columns[] (the CSV
|
|
@@ -1343,7 +1356,8 @@ Input:
|
|
|
1343
1356
|
Output:
|
|
1344
1357
|
Log lines (human) or a JSON envelope; with --out, the file path. Follow
|
|
1345
1358
|
next.logs for the next page of events, and pass nextCursor to --cursor for
|
|
1346
|
-
older text logs.
|
|
1359
|
+
older text logs. To parse the output, add --json; stdout is then one JSON
|
|
1360
|
+
document.
|
|
1347
1361
|
]]
|
|
1348
1362
|
Cost:
|
|
1349
1363
|
Free.
|
|
@@ -3,15 +3,15 @@
|
|
|
3
3
|
var _chunkZM2YPJQJjs = require('./chunk-ZM2YPJQJ.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkAUMD2VXPjs = require('./chunk-AUMD2VXP.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkQ3PUHXOYjs = require('./chunk-Q3PUHXOY.js');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _chunkQUAQX3FQjs = require('./chunk-QUAQX3FQ.js');
|
|
15
15
|
|
|
16
16
|
// src/cli/commands/search.ts
|
|
17
17
|
var _commander = require('commander');
|
|
@@ -21,7 +21,7 @@ var _fs = require('fs');
|
|
|
21
21
|
var _path = require('path');
|
|
22
22
|
var SEARCH_REF_TTL_MS = 15 * 6e4;
|
|
23
23
|
function lastSearchPath() {
|
|
24
|
-
return _path.join.call(void 0,
|
|
24
|
+
return _path.join.call(void 0, _chunkQUAQX3FQjs.sdkCliStateDirPath.call(void 0, _chunkQUAQX3FQjs.resolveConfig.call(void 0, ).baseUrl), "last-search.json");
|
|
25
25
|
}
|
|
26
26
|
function rememberSearchRef(searchRef) {
|
|
27
27
|
try {
|
|
@@ -167,7 +167,7 @@ function searchRow(item) {
|
|
|
167
167
|
}
|
|
168
168
|
function renderSearchResults(result) {
|
|
169
169
|
if (result.results.length === 0)
|
|
170
|
-
return
|
|
170
|
+
return _chunkQ3PUHXOYjs.renderCommandEnvelopeText.call(void 0, result);
|
|
171
171
|
const rows = result.results.map(searchRow);
|
|
172
172
|
const kinds = new Set(rows.map((row) => row.kind));
|
|
173
173
|
const onlyTools = kinds.size === 1 && kinds.has("tool");
|
|
@@ -198,7 +198,7 @@ function renderSearchResults(result) {
|
|
|
198
198
|
actions: _optionalChain([render, 'optionalAccess', _11 => _11.actions])
|
|
199
199
|
};
|
|
200
200
|
const followUps = _optionalChain([remaining, 'access', _12 => _12.sections, 'optionalAccess', _13 => _13.length]) || _optionalChain([remaining, 'access', _14 => _14.actions, 'optionalAccess', _15 => _15.length]) ? `
|
|
201
|
-
${
|
|
201
|
+
${_chunkQ3PUHXOYjs.renderCommandEnvelopeText.call(void 0, { render: remaining })}` : "";
|
|
202
202
|
const notes = rows.flatMap(
|
|
203
203
|
(row) => row.notes.map((note) => ` ${row.id}: ${note}`)
|
|
204
204
|
);
|
|
@@ -275,7 +275,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
275
275
|
console.error(USAGE);
|
|
276
276
|
return 1;
|
|
277
277
|
}
|
|
278
|
-
const { search_ref: searchRef, ...result } = await new (0,
|
|
278
|
+
const { search_ref: searchRef, ...result } = await new (0, _chunkAUMD2VXPjs.DeeplineClient)().search({
|
|
279
279
|
query,
|
|
280
280
|
types,
|
|
281
281
|
exclude,
|
|
@@ -289,7 +289,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
289
289
|
});
|
|
290
290
|
if (searchRef) rememberSearchRef(searchRef);
|
|
291
291
|
pointAtDescribe(result);
|
|
292
|
-
|
|
292
|
+
_chunkQ3PUHXOYjs.printCommandEnvelope.call(void 0, result, {
|
|
293
293
|
json: options.json === true,
|
|
294
294
|
text: renderSearchResults(result)
|
|
295
295
|
});
|