deepline 0.3.367 → 0.3.368
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/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/types.ts +5 -0
- package/dist/cli/auth-NJ6RE6XQ.js +33 -0
- package/dist/cli/{auth-2DHYG3WZ.mjs → auth-RUWM7VTH.mjs} +4 -4
- package/dist/cli/{billing-YBTOTHXM.js → billing-PLBQKLDK.js} +73 -73
- package/dist/cli/{billing-VFBFBOO5.mjs → billing-WSS57VQY.mjs} +4 -4
- package/dist/cli/{chunk-MXJEKMHU.js → chunk-27QA6Q4G.js} +224 -224
- package/dist/cli/{chunk-MKRADCZK.js → chunk-2YOKZW46.js} +26 -26
- package/dist/cli/{chunk-CRRVBNZD.js → chunk-7AWSYT7H.js} +117 -9
- package/dist/cli/{chunk-HEWGTHI2.mjs → chunk-7PQTQSJY.mjs} +111 -3
- package/dist/cli/{chunk-LDSBBKSM.mjs → chunk-A2OLR6DK.mjs} +2 -2
- package/dist/cli/{chunk-LJIWLZHS.js → chunk-AUWKAVXB.js} +54 -146
- package/dist/cli/{chunk-XPIZKTYZ.js → chunk-BKEYQHJ2.js} +50 -50
- package/dist/cli/{chunk-KJFND3YT.js → chunk-DZOEDNSU.js} +9 -9
- package/dist/cli/{chunk-GXRUBTXZ.mjs → chunk-ENGMDXHN.mjs} +2 -2
- package/dist/cli/{chunk-OCX5D2WI.mjs → chunk-EZUGGC5A.mjs} +1 -1
- package/dist/cli/{chunk-GD2VVYGB.mjs → chunk-GHZUH33K.mjs} +1 -1
- package/dist/cli/{chunk-3BZR22CZ.js → chunk-GJO4H3NN.js} +60 -60
- package/dist/cli/{chunk-R2HHZLOP.js → chunk-GTC2KAZQ.js} +4 -4
- package/dist/cli/{chunk-5NVMNFCG.js → chunk-HZT2Y7WB.js} +15 -15
- package/dist/cli/{chunk-6DRGO4CB.mjs → chunk-IG7OYVS7.mjs} +6 -6
- package/dist/cli/{chunk-3Y3N7WQO.mjs → chunk-LEZWRLB3.mjs} +1 -1
- package/dist/cli/{chunk-Z35CB3I5.js → chunk-NZHVJB2W.js} +2 -2
- package/dist/cli/{chunk-BBQ5IWRX.mjs → chunk-OTI7CDLE.mjs} +10 -102
- package/dist/cli/{chunk-3ZO2O2LE.mjs → chunk-PU53IS6H.mjs} +2 -2
- package/dist/cli/{chunk-K4V4FX76.mjs → chunk-S3MDB6SI.mjs} +1 -1
- package/dist/cli/{chunk-B7JTGFDS.js → chunk-S4Y7B2O3.js} +1 -1
- package/dist/cli/{chunk-D7SELX66.js → chunk-SNENR3BL.js} +6 -6
- package/dist/cli/{chunk-JNQECSK5.mjs → chunk-THO6F53F.mjs} +1 -1
- package/dist/cli/{chunk-W2LUUB3U.mjs → chunk-XUMWO4ST.mjs} +4 -4
- package/dist/cli/{chunk-AVSPBILZ.js → chunk-YCJMDCTH.js} +8 -8
- package/dist/cli/{chunk-DIDYT2TH.mjs → chunk-ZS2YQ4YK.mjs} +2 -2
- package/dist/cli/{client-F6SEXBBG.mjs → client-JJEEIOIL.mjs} +3 -3
- package/dist/cli/client-UPKWYV32.js +20 -0
- package/dist/cli/{csv-DC3MLBOC.mjs → csv-75D36YRA.mjs} +3 -3
- package/dist/cli/{csv-4AB42QFI.js → csv-EPNNU27J.js} +12 -12
- package/dist/cli/{db-JAQHMLUY.mjs → db-6HYSGMLN.mjs} +4 -4
- package/dist/cli/{db-M3URDTLR.js → db-SWNKJUU5.js} +29 -29
- package/dist/cli/{describe-RYXCBLJG.mjs → describe-N2KSBPOR.mjs} +8 -8
- package/dist/cli/{describe-AVXUIRDK.js → describe-XMUHTICA.js} +15 -15
- package/dist/cli/{executions-DYDW4WY3.js → executions-3ESWUDHH.js} +6 -6
- package/dist/cli/{executions-XPY5FKOS.mjs → executions-WHSG2JGN.mjs} +4 -4
- package/dist/cli/{feedback-ZOI3GFAC.mjs → feedback-2VHTJXU7.mjs} +3 -3
- package/dist/cli/{feedback-HMP2ZYNW.js → feedback-CGZE7L7A.js} +7 -7
- package/dist/cli/{git-K35PB25D.mjs → git-IG4J5OUT.mjs} +4 -4
- package/dist/cli/git-WPEOAE72.js +23 -0
- package/dist/cli/index.js +82 -82
- package/dist/cli/index.mjs +32 -32
- package/dist/cli/{legacy-noops-PKGJRS75.mjs → legacy-noops-7WXL7PB3.mjs} +4 -4
- package/dist/cli/{legacy-noops-QNNMKQDW.js → legacy-noops-QF7S6JJB.js} +7 -7
- package/dist/cli/{monitors-MUMWTBID.js → monitors-6XYT53X6.js} +85 -85
- package/dist/cli/{monitors-JMNBMRSQ.mjs → monitors-QS4QFORU.mjs} +4 -4
- package/dist/cli/{org-AQPMMPQE.mjs → org-5IGU7FES.mjs} +4 -4
- package/dist/cli/{org-2QL6AY6G.js → org-NLR3D3M7.js} +64 -64
- package/dist/cli/play-3ECRZYD5.js +153 -0
- package/dist/cli/{play-AITTTWYK.mjs → play-JVENSY4T.mjs} +7 -7
- package/dist/cli/{providers-LRCYLIQA.mjs → providers-RSVO5U4E.mjs} +4 -4
- package/dist/cli/{providers-BGTPNAOA.js → providers-T4GCIOTW.js} +7 -7
- package/dist/cli/{quickstart-WMAUXWKW.js → quickstart-IHAG5QZ6.js} +5 -5
- package/dist/cli/{quickstart-3II563Z7.mjs → quickstart-ZDFOKNYW.mjs} +3 -3
- package/dist/cli/search-RYLADJUK.js +26 -0
- package/dist/cli/{search-J6ELRZNH.mjs → search-ZGEYJSMF.mjs} +5 -5
- package/dist/cli/{secrets-HDBB2647.js → secrets-DVTEZCPE.js} +13 -13
- package/dist/cli/{secrets-L7LOTLZB.mjs → secrets-OQZRZBP6.mjs} +4 -4
- package/dist/cli/{sessions-7DMN24LF.mjs → sessions-XM7PFJL2.mjs} +4 -4
- package/dist/cli/{sessions-ZO3WB3EF.js → sessions-XYEG53JJ.js} +5 -5
- package/dist/cli/{settings-OVUM5BLZ.js → settings-NWEBQOX4.js} +74 -74
- package/dist/cli/{settings-USHCF4YD.mjs → settings-TKXYRYYH.mjs} +7 -7
- package/dist/cli/{setup-FZQ7HDL4.mjs → setup-3UD5TDRJ.mjs} +6 -6
- package/dist/cli/{setup-W77Y5ALX.js → setup-JRU6VGFQ.js} +41 -41
- package/dist/cli/{skills-A2LR3RAP.mjs → skills-GLLMNOCY.mjs} +4 -4
- package/dist/cli/skills-PZQDJJWN.js +28 -0
- package/dist/cli/{tools-FX7G7KX5.mjs → tools-VXXAMH2X.mjs} +6 -6
- package/dist/cli/tools-WYXBAUMT.js +40 -0
- package/dist/cli/{update-EODE5FHU.mjs → update-UCGMUUDQ.mjs} +6 -6
- package/dist/cli/update-WM6SOME3.js +28 -0
- package/dist/cli/{workflow-7352UH6L.mjs → workflow-BGGKNZTG.mjs} +5 -5
- package/dist/cli/{workflow-JEY4ESZA.js → workflow-G2UU7WTU.js} +15 -15
- package/dist/{client-BmKft6Pr.d.mts → client-CjHv4K6D.d.mts} +8 -0
- package/dist/{client-Bra0Nc2D.d.ts → client-rTuhNN-x.d.ts} +8 -0
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +6 -6
- package/dist/index.mjs +3 -3
- package/dist/install-integrity.json +76 -76
- package/dist/plays/run-request.d.mts +1 -1
- package/dist/plays/run-request.d.ts +1 -1
- 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-I2E45QZK.js +0 -33
- package/dist/cli/client-VWGJIUGH.js +0 -20
- package/dist/cli/git-TJEM2U4K.js +0 -23
- package/dist/cli/play-YO52D4YP.js +0 -153
- package/dist/cli/search-FQ5NSE7R.js +0 -26
- package/dist/cli/skills-GLKEZPFV.js +0 -28
- package/dist/cli/tools-HBNJ3WP3.js +0 -40
- package/dist/cli/update-A2TZZO2S.js +0 -28
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkSNENR3BLjs = require('./chunk-SNENR3BL.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
@@ -25,7 +25,7 @@ var _chunkD7SELX66js = require('./chunk-D7SELX66.js');
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var _chunkGTC2KAZQjs = require('./chunk-GTC2KAZQ.js');
|
|
29
29
|
|
|
30
30
|
// src/cli/commands/auth.ts
|
|
31
31
|
|
|
@@ -52,7 +52,7 @@ function statusBannerLine(value) {
|
|
|
52
52
|
return `Service notice: ${banner.message}`;
|
|
53
53
|
}
|
|
54
54
|
function envFilePath(baseUrl) {
|
|
55
|
-
return
|
|
55
|
+
return _chunkGTC2KAZQjs.hostEnvFilePath.call(void 0, baseUrl);
|
|
56
56
|
}
|
|
57
57
|
function normalizeAuthScope(value) {
|
|
58
58
|
if (!value || value === "global") return "global";
|
|
@@ -65,7 +65,7 @@ function parseAuthScope(args) {
|
|
|
65
65
|
}
|
|
66
66
|
function pendingClaimPath(baseUrl, scope) {
|
|
67
67
|
if (scope === "folder") {
|
|
68
|
-
const target =
|
|
68
|
+
const target = _chunkGTC2KAZQjs.resolveProjectPinTarget.call(void 0, );
|
|
69
69
|
if (!target.ok) {
|
|
70
70
|
throw new Error(
|
|
71
71
|
`Cowork project folder is ambiguous. Candidate folders: ${target.candidates.join(
|
|
@@ -75,10 +75,10 @@ function pendingClaimPath(baseUrl, scope) {
|
|
|
75
75
|
}
|
|
76
76
|
return _path.join.call(void 0, target.dir, ".deepline", "setup", "pending-auth.json");
|
|
77
77
|
}
|
|
78
|
-
return `${
|
|
78
|
+
return `${_chunkGTC2KAZQjs.hostConfigDirPath.call(void 0, baseUrl)}/pending-auth.json`;
|
|
79
79
|
}
|
|
80
80
|
function legacyPendingClaimTokenPath(baseUrl) {
|
|
81
|
-
return `${
|
|
81
|
+
return `${_chunkGTC2KAZQjs.hostConfigDirPath.call(void 0, baseUrl)}/pending-claim-token`;
|
|
82
82
|
}
|
|
83
83
|
function savePendingClaim(baseUrl, claim) {
|
|
84
84
|
const filePath = pendingClaimPath(baseUrl, claim.scope);
|
|
@@ -180,21 +180,21 @@ function parseRegisterWaitMode(args) {
|
|
|
180
180
|
function shouldWaitForRegisterClaim(mode) {
|
|
181
181
|
if (mode === "yes") return true;
|
|
182
182
|
if (mode === "no") return false;
|
|
183
|
-
return
|
|
183
|
+
return _chunkGTC2KAZQjs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
184
184
|
}
|
|
185
185
|
function saveEnvValues(values, baseUrl, scope) {
|
|
186
186
|
const filtered = {
|
|
187
|
-
...values[
|
|
188
|
-
...values[
|
|
189
|
-
...values[
|
|
190
|
-
...Object.prototype.hasOwnProperty.call(values,
|
|
187
|
+
...values[_chunkGTC2KAZQjs.HOST_URL_ENV] ? { [_chunkGTC2KAZQjs.HOST_URL_ENV]: values[_chunkGTC2KAZQjs.HOST_URL_ENV] } : {},
|
|
188
|
+
...values[_chunkGTC2KAZQjs.API_KEY_ENV] ? { [_chunkGTC2KAZQjs.API_KEY_ENV]: values[_chunkGTC2KAZQjs.API_KEY_ENV] } : {},
|
|
189
|
+
...values[_chunkGTC2KAZQjs.ACTIVE_ORG_ID_ENV] ? { [_chunkGTC2KAZQjs.ACTIVE_ORG_ID_ENV]: values[_chunkGTC2KAZQjs.ACTIVE_ORG_ID_ENV] } : {},
|
|
190
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkGTC2KAZQjs.ACTIVE_ORG_NAME_ENV) ? { [_chunkGTC2KAZQjs.ACTIVE_ORG_NAME_ENV]: values[_chunkGTC2KAZQjs.ACTIVE_ORG_NAME_ENV] } : {},
|
|
191
191
|
// An explicit empty list must reach the store: it clears a stale line.
|
|
192
|
-
...Object.prototype.hasOwnProperty.call(values,
|
|
192
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkGTC2KAZQjs.FEATURES_ENV) ? { [_chunkGTC2KAZQjs.FEATURES_ENV]: values[_chunkGTC2KAZQjs.FEATURES_ENV] } : {}
|
|
193
193
|
};
|
|
194
194
|
if (scope === "folder") {
|
|
195
|
-
|
|
195
|
+
_chunkGTC2KAZQjs.saveProjectDeeplineEnvValues.call(void 0, filtered);
|
|
196
196
|
} else {
|
|
197
|
-
|
|
197
|
+
_chunkGTC2KAZQjs.saveHostEnvValues.call(void 0, baseUrl, filtered);
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
200
|
function activeOrgEnvValues(data) {
|
|
@@ -202,21 +202,21 @@ function activeOrgEnvValues(data) {
|
|
|
202
202
|
if (!orgId) return {};
|
|
203
203
|
const orgName = typeof data.org_name === "string" ? data.org_name.trim() : "";
|
|
204
204
|
return {
|
|
205
|
-
[
|
|
206
|
-
[
|
|
207
|
-
...
|
|
205
|
+
[_chunkGTC2KAZQjs.ACTIVE_ORG_ID_ENV]: orgId,
|
|
206
|
+
[_chunkGTC2KAZQjs.ACTIVE_ORG_NAME_ENV]: orgName,
|
|
207
|
+
..._chunkGTC2KAZQjs.featureEnvValues.call(void 0, data)
|
|
208
208
|
};
|
|
209
209
|
}
|
|
210
210
|
async function httpJson(method, url, apiKey, body, timeoutMs = AUTH_HTTP_TIMEOUT_MS) {
|
|
211
211
|
const headers = {
|
|
212
212
|
"Content-Type": "application/json",
|
|
213
|
-
"User-Agent": `deepline-ts-sdk/${
|
|
213
|
+
"User-Agent": `deepline-ts-sdk/${_chunkGTC2KAZQjs.SDK_VERSION}`,
|
|
214
214
|
"X-Deepline-Client-Family": "sdk",
|
|
215
215
|
"X-Deepline-CLI-Family": "sdk",
|
|
216
|
-
"X-Deepline-Agent-Runtime":
|
|
217
|
-
"X-Deepline-CLI-Version":
|
|
218
|
-
"X-Deepline-SDK-Version":
|
|
219
|
-
"X-Deepline-API-Contract":
|
|
216
|
+
"X-Deepline-Agent-Runtime": _chunkGTC2KAZQjs.detectAgentRuntime.call(void 0, ),
|
|
217
|
+
"X-Deepline-CLI-Version": _chunkGTC2KAZQjs.SDK_VERSION,
|
|
218
|
+
"X-Deepline-SDK-Version": _chunkGTC2KAZQjs.SDK_VERSION,
|
|
219
|
+
"X-Deepline-API-Contract": _chunkGTC2KAZQjs.SDK_API_CONTRACT
|
|
220
220
|
};
|
|
221
221
|
if (apiKey) headers["Authorization"] = `Bearer ${apiKey}`;
|
|
222
222
|
const bypassToken = _optionalChain([process, 'access', _7 => _7.env, 'access', _8 => _8.VERCEL_PROTECTION_BYPASS_TOKEN, 'optionalAccess', _9 => _9.trim, 'call', _10 => _10()]);
|
|
@@ -254,7 +254,7 @@ async function httpJson(method, url, apiKey, body, timeoutMs = AUTH_HTTP_TIMEOUT
|
|
|
254
254
|
throw lastError instanceof Error ? lastError : new Error(String(lastError));
|
|
255
255
|
}
|
|
256
256
|
async function reportSetupCompleted(input) {
|
|
257
|
-
const apiKey = input.authScope === "folder" ?
|
|
257
|
+
const apiKey = input.authScope === "folder" ? _chunkGTC2KAZQjs.resolveProjectApiKeyForBaseUrl.call(void 0, input.baseUrl) : _chunkGTC2KAZQjs.resolveGlobalApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
258
258
|
if (!apiKey) return;
|
|
259
259
|
try {
|
|
260
260
|
await httpJson(
|
|
@@ -351,7 +351,7 @@ async function printClaimSuccessBanner(baseUrl, apiKey, statusData) {
|
|
|
351
351
|
}
|
|
352
352
|
}
|
|
353
353
|
async function handleRegister(args) {
|
|
354
|
-
const baseUrl =
|
|
354
|
+
const baseUrl = _chunkGTC2KAZQjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
355
355
|
let orgName = "";
|
|
356
356
|
let orgId = "";
|
|
357
357
|
let agentName = "";
|
|
@@ -406,19 +406,19 @@ async function handleRegister(args) {
|
|
|
406
406
|
});
|
|
407
407
|
saveEnvValues(
|
|
408
408
|
{
|
|
409
|
-
[
|
|
409
|
+
[_chunkGTC2KAZQjs.HOST_URL_ENV]: baseUrl
|
|
410
410
|
},
|
|
411
411
|
baseUrl,
|
|
412
412
|
authScope
|
|
413
413
|
);
|
|
414
414
|
}
|
|
415
415
|
if (claimUrl) {
|
|
416
|
-
const shouldOpen = waitMode !== "no" &&
|
|
416
|
+
const shouldOpen = waitMode !== "no" && _chunkGTC2KAZQjs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
417
417
|
console.log(
|
|
418
418
|
shouldOpen ? " Opening approval page in your browser." : " Open this approval page in your browser:"
|
|
419
419
|
);
|
|
420
420
|
console.log(` ${claimUrl}`);
|
|
421
|
-
if (shouldOpen)
|
|
421
|
+
if (shouldOpen) _chunkSNENR3BLjs.openInBrowser.call(void 0, claimUrl);
|
|
422
422
|
}
|
|
423
423
|
if (data.cli_message) {
|
|
424
424
|
console.log(String(data.cli_message));
|
|
@@ -461,8 +461,8 @@ async function handleRegister(args) {
|
|
|
461
461
|
if (apiKey) {
|
|
462
462
|
saveEnvValues(
|
|
463
463
|
{
|
|
464
|
-
[
|
|
465
|
-
[
|
|
464
|
+
[_chunkGTC2KAZQjs.HOST_URL_ENV]: baseUrl,
|
|
465
|
+
[_chunkGTC2KAZQjs.API_KEY_ENV]: apiKey,
|
|
466
466
|
...activeOrgEnvValues(statusData)
|
|
467
467
|
},
|
|
468
468
|
baseUrl,
|
|
@@ -484,7 +484,7 @@ async function handleRegister(args) {
|
|
|
484
484
|
}
|
|
485
485
|
}
|
|
486
486
|
async function handleWait(args) {
|
|
487
|
-
const baseUrl =
|
|
487
|
+
const baseUrl = _chunkGTC2KAZQjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
488
488
|
let timeoutSeconds = 300;
|
|
489
489
|
let requestedScope;
|
|
490
490
|
if (args.includes("--auth-scope")) {
|
|
@@ -508,7 +508,7 @@ async function handleWait(args) {
|
|
|
508
508
|
const authScope = resumed.scope;
|
|
509
509
|
const claimToken = _nullishCoalesce(_optionalChain([pendingClaim, 'optionalAccess', _11 => _11.claimToken]), () => ( ""));
|
|
510
510
|
if (!pendingClaim) {
|
|
511
|
-
const scopedApiKey = authScope === "folder" ?
|
|
511
|
+
const scopedApiKey = authScope === "folder" ? _chunkGTC2KAZQjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkGTC2KAZQjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
512
512
|
if (scopedApiKey) {
|
|
513
513
|
console.log("Already connected.");
|
|
514
514
|
return EXIT_OK;
|
|
@@ -551,8 +551,8 @@ async function handleWait(args) {
|
|
|
551
551
|
if (apiKey) {
|
|
552
552
|
saveEnvValues(
|
|
553
553
|
{
|
|
554
|
-
[
|
|
555
|
-
[
|
|
554
|
+
[_chunkGTC2KAZQjs.HOST_URL_ENV]: baseUrl,
|
|
555
|
+
[_chunkGTC2KAZQjs.API_KEY_ENV]: apiKey,
|
|
556
556
|
...activeOrgEnvValues(data)
|
|
557
557
|
},
|
|
558
558
|
baseUrl,
|
|
@@ -576,8 +576,8 @@ async function handleWait(args) {
|
|
|
576
576
|
return EXIT_AUTH;
|
|
577
577
|
}
|
|
578
578
|
async function authStatusLine(timeoutMs = 3e3) {
|
|
579
|
-
const baseUrl =
|
|
580
|
-
const apiKey =
|
|
579
|
+
const baseUrl = _chunkGTC2KAZQjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
580
|
+
const apiKey = _chunkGTC2KAZQjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
581
581
|
if (!apiKey) return `Auth: not connected (${baseUrl})`;
|
|
582
582
|
try {
|
|
583
583
|
const { status, data } = await httpJson(
|
|
@@ -600,9 +600,9 @@ async function authStatusLine(timeoutMs = 3e3) {
|
|
|
600
600
|
}
|
|
601
601
|
}
|
|
602
602
|
async function handleStatus(args) {
|
|
603
|
-
const baseUrl =
|
|
603
|
+
const baseUrl = _chunkGTC2KAZQjs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
604
604
|
const reveal = args.includes("--reveal");
|
|
605
|
-
const jsonOutput =
|
|
605
|
+
const jsonOutput = _chunkSNENR3BLjs.argsWantJson.call(void 0, args);
|
|
606
606
|
const hasExplicitAuthScope = args.includes("--auth-scope");
|
|
607
607
|
let authScope = null;
|
|
608
608
|
if (hasExplicitAuthScope) {
|
|
@@ -642,14 +642,14 @@ async function handleStatus(args) {
|
|
|
642
642
|
};
|
|
643
643
|
hostLines.push(`Host: ${baseUrl} (unreachable)`);
|
|
644
644
|
}
|
|
645
|
-
const apiKey = authScope === "folder" ?
|
|
645
|
+
const apiKey = authScope === "folder" ? _chunkGTC2KAZQjs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : authScope === "global" ? _chunkGTC2KAZQjs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkGTC2KAZQjs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
646
646
|
if (!apiKey) {
|
|
647
647
|
const { claim: pendingClaim } = resolvePendingAuthClaimForResume(
|
|
648
648
|
baseUrl,
|
|
649
649
|
_nullishCoalesce(authScope, () => ( void 0))
|
|
650
650
|
);
|
|
651
651
|
if (pendingClaim) {
|
|
652
|
-
|
|
652
|
+
_chunkSNENR3BLjs.printCommandEnvelope.call(void 0,
|
|
653
653
|
{
|
|
654
654
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
655
655
|
status: "pending",
|
|
@@ -670,7 +670,7 @@ async function handleStatus(args) {
|
|
|
670
670
|
);
|
|
671
671
|
return EXIT_OK;
|
|
672
672
|
}
|
|
673
|
-
|
|
673
|
+
_chunkSNENR3BLjs.printCommandEnvelope.call(void 0,
|
|
674
674
|
{
|
|
675
675
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
676
676
|
status: "not connected",
|
|
@@ -703,7 +703,7 @@ async function handleStatus(args) {
|
|
|
703
703
|
}
|
|
704
704
|
);
|
|
705
705
|
if (status === 401 || status === 403) {
|
|
706
|
-
|
|
706
|
+
_chunkSNENR3BLjs.printCommandEnvelope.call(void 0,
|
|
707
707
|
{
|
|
708
708
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
709
709
|
status: "unauthorized",
|
|
@@ -730,7 +730,7 @@ async function handleStatus(args) {
|
|
|
730
730
|
console.error(`Auth status error (status ${status}).`);
|
|
731
731
|
return EXIT_SERVER;
|
|
732
732
|
}
|
|
733
|
-
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (
|
|
733
|
+
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (_chunkGTC2KAZQjs.getResolvedProjectAuthSource.call(void 0, baseUrl, apiKey) ? "folder" : "global")));
|
|
734
734
|
clearSatisfiedPendingClaim(
|
|
735
735
|
baseUrl,
|
|
736
736
|
resolvedAuthScope,
|
|
@@ -758,28 +758,28 @@ async function handleStatus(args) {
|
|
|
758
758
|
if (apiKeyResp) {
|
|
759
759
|
saveEnvValues(
|
|
760
760
|
{
|
|
761
|
-
[
|
|
762
|
-
[
|
|
761
|
+
[_chunkGTC2KAZQjs.HOST_URL_ENV]: baseUrl,
|
|
762
|
+
[_chunkGTC2KAZQjs.API_KEY_ENV]: apiKeyResp,
|
|
763
763
|
...activeOrgEnvValues(data)
|
|
764
764
|
},
|
|
765
765
|
baseUrl,
|
|
766
766
|
resolvedAuthScope
|
|
767
767
|
);
|
|
768
768
|
if (resolvedAuthScope === "folder") {
|
|
769
|
-
const target =
|
|
769
|
+
const target = _chunkGTC2KAZQjs.resolveProjectPinTarget.call(void 0, );
|
|
770
770
|
savedApiKeyPath = target.ok ? _path.join.call(void 0, target.dir, ".env.deepline") : null;
|
|
771
771
|
} else {
|
|
772
772
|
savedApiKeyPath = envFilePath(baseUrl);
|
|
773
773
|
}
|
|
774
774
|
}
|
|
775
|
-
} else if (resolvedAuthScope === "folder" ||
|
|
776
|
-
saveEnvValues(
|
|
775
|
+
} else if (resolvedAuthScope === "folder" || _chunkGTC2KAZQjs.storedHostApiKey.call(void 0, baseUrl) === apiKey) {
|
|
776
|
+
saveEnvValues(_chunkGTC2KAZQjs.featureEnvValues.call(void 0, data), baseUrl, resolvedAuthScope);
|
|
777
777
|
}
|
|
778
|
-
|
|
778
|
+
_chunkSNENR3BLjs.printCommandEnvelope.call(void 0,
|
|
779
779
|
{
|
|
780
780
|
...payload,
|
|
781
|
-
...
|
|
782
|
-
command_context:
|
|
781
|
+
..._chunkGTC2KAZQjs.detectAgentRuntime.call(void 0, ) !== "unknown" ? {
|
|
782
|
+
command_context: _chunkGTC2KAZQjs.resolveCliCommandContext.call(void 0,
|
|
783
783
|
{ baseUrl, apiKey },
|
|
784
784
|
resolvedAuthScope
|
|
785
785
|
)
|
|
@@ -21,7 +21,7 @@ var _chunkLA46MMTLjs = require('./chunk-LA46MMTL.js');
|
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _chunkGTC2KAZQjs = require('./chunk-GTC2KAZQ.js');
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
@@ -167,7 +167,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
167
167
|
if (error instanceof _chunk7P5AA3SNjs.DeeplineError && (_optionalChain([error, 'access', _2 => _2.code, 'optionalAccess', _3 => _3.startsWith, 'call', _4 => _4("NETWORK_")]) || // Older API readers return PostgreSQL errors as HTTP 400, including
|
|
168
168
|
// lost connections and explicitly unknown transaction resolution.
|
|
169
169
|
/^08[A-Z0-9]{3}$/.test(_nullishCoalesce(error.code, () => ( ""))) || ["57P01", "57P02", "57P03"].includes(_nullishCoalesce(error.code, () => ( ""))) || error.statusCode === 408 || (_nullishCoalesce(error.statusCode, () => ( 0))) >= 500)) {
|
|
170
|
-
throw new (0,
|
|
170
|
+
throw new (0, _chunkGTC2KAZQjs.CustomerDbQueryOutcomeUnknownError)(
|
|
171
171
|
error,
|
|
172
172
|
plan.request.body.operation_key
|
|
173
173
|
);
|
|
@@ -175,7 +175,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
175
175
|
throw error;
|
|
176
176
|
}
|
|
177
177
|
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) {
|
|
178
|
-
throw new (0,
|
|
178
|
+
throw new (0, _chunkGTC2KAZQjs.CustomerDbQueryOutcomeUnknownError)(
|
|
179
179
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
180
180
|
"The SQL response did not contain a valid result.",
|
|
181
181
|
200,
|
|
@@ -186,7 +186,7 @@ async function queryCustomerDatabase(http, input) {
|
|
|
186
186
|
}
|
|
187
187
|
const operation = result.operation;
|
|
188
188
|
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))) {
|
|
189
|
-
throw new (0,
|
|
189
|
+
throw new (0, _chunkGTC2KAZQjs.CustomerDbQueryOutcomeUnknownError)(
|
|
190
190
|
new (0, _chunk7P5AA3SNjs.DeeplineError)(
|
|
191
191
|
"The server did not confirm the original atomic SQL operation.",
|
|
192
192
|
200,
|
|
@@ -2910,8 +2910,8 @@ function runtimeSelectionHeaders(runtime) {
|
|
|
2910
2910
|
}
|
|
2911
2911
|
const receivers = _optionalChain([process, 'access', _104 => _104.env, 'access', _105 => _105.DEEPLINE_RUNTIME_RETAINED_PIPELINE_RECEIVERS, 'optionalAccess', _106 => _106.trim, 'call', _107 => _107()]);
|
|
2912
2912
|
return {
|
|
2913
|
-
[
|
|
2914
|
-
...receivers ? { [
|
|
2913
|
+
[_chunkGTC2KAZQjs.RUNTIME_ENVIRONMENT_TOKEN_HEADER]: token,
|
|
2914
|
+
...receivers ? { [_chunkGTC2KAZQjs.RETAINED_PIPELINE_RECEIVERS_HEADER]: receivers } : {}
|
|
2915
2915
|
};
|
|
2916
2916
|
}
|
|
2917
2917
|
function isolatedCiRuntimeEventReadHeaders() {
|
|
@@ -2927,7 +2927,7 @@ function isolatedCiRuntimeEventReadHeaders() {
|
|
|
2927
2927
|
"RUNTIME_EVENT_INTERNAL_TOKEN_REQUIRED"
|
|
2928
2928
|
);
|
|
2929
2929
|
}
|
|
2930
|
-
return { [
|
|
2930
|
+
return { [_chunkGTC2KAZQjs.COORDINATOR_INTERNAL_TOKEN_HEADER]: token };
|
|
2931
2931
|
}
|
|
2932
2932
|
function normalizeTestPolicyOverrides(value, source) {
|
|
2933
2933
|
if (value && typeof value === "object" && !Array.isArray(value)) {
|
|
@@ -3217,8 +3217,8 @@ var DeeplineClient = (_class = class _DeeplineClient {
|
|
|
3217
3217
|
* @throws {@link ConfigError} if no API key can be resolved from any source.
|
|
3218
3218
|
*/
|
|
3219
3219
|
constructor(options) {
|
|
3220
|
-
this.config =
|
|
3221
|
-
this.http = new (0,
|
|
3220
|
+
this.config = _chunkGTC2KAZQjs.resolveConfig.call(void 0, options);
|
|
3221
|
+
this.http = new (0, _chunkGTC2KAZQjs.HttpClient)(this.config);
|
|
3222
3222
|
this.toolCalls = new ToolCalls(
|
|
3223
3223
|
this.http,
|
|
3224
3224
|
this.config.timeout,
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-GAMFK2ZP.mjs";
|
|
4
4
|
import {
|
|
5
5
|
printCommandEnvelope
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-S3MDB6SI.mjs";
|
|
7
7
|
import {
|
|
8
8
|
DEFAULT_SKILL_AGENTS,
|
|
9
9
|
KNOWN_SKILL_AGENTS,
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
sdkCliStateDirPath,
|
|
23
23
|
skillsAgentPathSegment,
|
|
24
24
|
writeSdkSkillsLocalVersion
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-EZUGGC5A.mjs";
|
|
26
26
|
import {
|
|
27
27
|
DeeplineError
|
|
28
28
|
} from "./chunk-NXGCO4JB.mjs";
|
|
@@ -49,7 +49,7 @@ var SDK_RELEASE = {
|
|
|
49
49
|
// getters keep their established compatibility behavior.
|
|
50
50
|
// 0.3.1 deprecated the legacy `deepline enrich` command in favor of Plays.
|
|
51
51
|
// 0.3.90 is the first deliberately versioned SDK release for API v3.
|
|
52
|
-
version: "0.3.
|
|
52
|
+
version: "0.3.368",
|
|
53
53
|
updateSummary: "Play grep now returns concise results with the matched fields and terms. Automatic CLI updates are enabled by default; use `deepline settings autoupdate off` to opt out, `deepline settings autoupdate on` to re-enable updates, or `deepline settings autoupdate pin <version>` to hold an exact release.",
|
|
54
54
|
packageCapabilities: {
|
|
55
55
|
updatePreferences: 1
|