deepline 0.3.395 → 0.3.396
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/plays/play-description.ts +1 -1
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/observability/scheduled-jobs.json +1 -1
- package/dist/cli/{auth-NMQXZRS7.mjs → auth-3LTD62VL.mjs} +4 -4
- package/dist/cli/auth-562JPKOM.js +39 -0
- package/dist/cli/{billing-5MVXZRS6.mjs → billing-DP7ZAJBO.mjs} +5 -5
- package/dist/cli/{billing-Z4JTGUU3.js → billing-PA5OXEM5.js} +76 -76
- package/dist/cli/{chunk-BLYL3KOC.mjs → chunk-23GAA3YO.mjs} +1 -1
- package/dist/cli/{chunk-LZLBR2SF.js → chunk-2VOLOWYZ.js} +1087 -1056
- package/dist/cli/{chunk-EFLQHJZ6.mjs → chunk-3T4MCB5R.mjs} +1026 -995
- package/dist/cli/{chunk-VB6KECLU.mjs → chunk-5WNJF2T3.mjs} +102 -36
- package/dist/cli/{chunk-UKU6JM3S.js → chunk-772W2SAU.js} +8 -8
- package/dist/cli/{chunk-K5T3EN6D.js → chunk-7Z66NHUC.js} +26 -26
- package/dist/cli/{chunk-WCCKMLHL.mjs → chunk-AUYXWELC.mjs} +2 -2
- package/dist/cli/{chunk-PZ5BZ76S.js → chunk-AVHLATII.js} +50 -50
- package/dist/cli/{chunk-MYIBHORT.js → chunk-DC6LTULT.js} +2 -2
- package/dist/cli/{chunk-5VCZ3WRH.mjs → chunk-EIMG75BT.mjs} +1 -0
- package/dist/cli/{chunk-TO2MWPGR.js → chunk-GNN4MY5X.js} +1 -1
- package/dist/cli/{chunk-OCSG6X67.mjs → chunk-I4T4XAA2.mjs} +4 -4
- package/dist/cli/{chunk-ZWH2TFA7.mjs → chunk-JCN4DHF7.mjs} +2 -2
- package/dist/cli/{chunk-R4XZO6Z5.js → chunk-KAEZNPUM.js} +23 -8
- package/dist/cli/{chunk-DRM3CMHL.js → chunk-KXMNM4AQ.js} +2 -1
- package/dist/cli/{chunk-3TRY7KAC.mjs → chunk-LOGGNW4H.mjs} +2 -2
- package/dist/cli/{chunk-RDXFGPJU.js → chunk-LWERJUKN.js} +218 -218
- package/dist/cli/{chunk-UCXK2DS4.js → chunk-ME6XRFLY.js} +15 -15
- package/dist/cli/{chunk-G4IWGRMK.mjs → chunk-MR6XCBQJ.mjs} +2 -2
- package/dist/cli/{chunk-BON3DRC6.mjs → chunk-NHB5YUCS.mjs} +1 -1
- package/dist/cli/{chunk-ZMVJSS6N.js → chunk-NSOTASOP.js} +101 -35
- package/dist/cli/{chunk-7XAM7KDW.mjs → chunk-QHGPA362.mjs} +18 -3
- package/dist/cli/{chunk-VYLJJQ7Y.js → chunk-RMTASUAK.js} +65 -65
- package/dist/cli/{chunk-HRWUQJ4K.js → chunk-RTO5QZWT.js} +6 -6
- package/dist/cli/{chunk-7MVWUXOD.mjs → chunk-TLQ3FZOC.mjs} +3 -3
- package/dist/cli/{chunk-56IFFVIB.js → chunk-V7UP2F4U.js} +4 -4
- package/dist/cli/{chunk-6D7A2FSL.mjs → chunk-VE3U3SQC.mjs} +1 -1
- package/dist/cli/{chunk-36ML3YKA.js → chunk-WQJJNIMQ.js} +13 -13
- package/dist/cli/{chunk-47M6HPGP.mjs → chunk-XKZXO7D3.mjs} +1 -1
- package/dist/cli/{csv-SVOD5UBH.mjs → csv-RLRR74RQ.mjs} +3 -3
- package/dist/cli/{csv-HTS5ZYQ4.js → csv-TF576S77.js} +12 -12
- package/dist/cli/{db-7AP4P52N.js → db-FDBJUTFO.js} +30 -30
- package/dist/cli/{db-7QLNI3Q4.mjs → db-XORGNBIC.mjs} +5 -5
- package/dist/cli/{describe-DBRY5BNK.mjs → describe-6O2ENKTP.mjs} +86 -68
- package/dist/cli/{describe-YKOE54ZO.js → describe-EFWNECHI.js} +100 -82
- package/dist/cli/{executions-GRQXTB2P.js → executions-SFYAXPF4.js} +7 -7
- package/dist/cli/{executions-QNZTPNG4.mjs → executions-YPP7WR77.mjs} +5 -5
- package/dist/cli/{feedback-ZOLA2KY7.js → feedback-5UZFYMGB.js} +7 -7
- package/dist/cli/{feedback-JMCSR624.mjs → feedback-RBGA5ARU.mjs} +3 -3
- package/dist/cli/git-5LDY5ZID.js +23 -0
- package/dist/cli/{git-LJGL2IHS.mjs → git-IRSAJEK2.mjs} +4 -4
- package/dist/cli/index.js +94 -94
- package/dist/cli/index.mjs +38 -38
- package/dist/cli/{legacy-noops-YSCIR2SD.js → legacy-noops-CVAOQY2F.js} +7 -7
- package/dist/cli/{legacy-noops-F23PKVBN.mjs → legacy-noops-NA7N6ZOU.mjs} +4 -4
- package/dist/cli/{monitors-WMZ6HJZX.js → monitors-4OMRXCXP.js} +86 -86
- package/dist/cli/{monitors-S4LOEL7W.mjs → monitors-ILZ2XHYG.mjs} +5 -5
- package/dist/cli/{org-U3WA2NQM.mjs → org-QDDXAE3J.mjs} +5 -5
- package/dist/cli/{org-PFHM5ZLY.js → org-YGNJDD2X.js} +65 -65
- package/dist/cli/{chunk-4KLCLLTO.js → play-L535H26U.js} +266 -323
- package/dist/cli/{chunk-XMAPE2KH.mjs → play-VT6OHB2D.mjs} +72 -129
- package/dist/cli/{providers-XYMHLKCA.js → providers-GPZ6PQAL.js} +8 -8
- package/dist/cli/{providers-QBBRFBOH.mjs → providers-KG4W5MPK.mjs} +5 -5
- package/dist/cli/{quickstart-5JTDGISY.mjs → quickstart-2JDGTXIG.mjs} +3 -3
- package/dist/cli/{quickstart-IYGD6ZY3.js → quickstart-UI27S5LO.js} +5 -5
- package/dist/cli/search-MGWROZ33.js +28 -0
- package/dist/cli/{search-X6W6GRHS.mjs → search-PW3RAUX7.mjs} +6 -6
- package/dist/cli/{secrets-N55B67H6.mjs → secrets-HNOMK5A2.mjs} +5 -5
- package/dist/cli/{secrets-UHG6OQFD.js → secrets-WFAXOUZE.js} +14 -14
- package/dist/cli/{sessions-57L5MGHN.js → sessions-366KROUA.js} +5 -5
- package/dist/cli/{sessions-JTRSTDSS.mjs → sessions-XLX3E5UO.mjs} +4 -4
- package/dist/cli/{settings-ATX4U5AS.js → settings-GADAG2UK.js} +75 -75
- package/dist/cli/{settings-Q24HRAQI.mjs → settings-YNZ4YKCH.mjs} +8 -8
- package/dist/cli/{setup-77ZWLVHT.mjs → setup-PSEHIUXO.mjs} +6 -6
- package/dist/cli/{setup-EJCNOUCE.js → setup-R5YO7GT6.js} +41 -41
- package/dist/cli/skills-JF2LPEGM.js +28 -0
- package/dist/cli/{skills-XIS5AWQI.mjs → skills-LTQBP6CZ.mjs} +4 -4
- package/dist/cli/tools-CP2PEFRN.js +34 -0
- package/dist/cli/{tools-WCKLYEGQ.mjs → tools-UAXDWU63.mjs} +11 -19
- package/dist/cli/update-HZHZOU6C.js +28 -0
- package/dist/cli/{update-UT5WANMV.mjs → update-SMNIBIMS.mjs} +6 -6
- package/dist/cli/{workflow-226QYUN2.js → workflow-AOQVZHMD.js} +16 -16
- package/dist/cli/{workflow-ZMX3L4ML.mjs → workflow-IKGMBGF6.mjs} +6 -6
- package/dist/{client-CivP-PAI.d.ts → client-Bgis7F6-.d.ts} +2 -1
- package/dist/{client-hdFtwhTm.d.mts → client-DiGl8ska.d.mts} +2 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +11 -11
- package/dist/index.mjs +9 -9
- package/dist/install-integrity.json +78 -80
- package/dist/plays/play-description.d.mts +1 -1
- package/dist/plays/play-description.d.ts +1 -1
- package/dist/plays/play-description.js +4 -2
- package/dist/plays/play-description.mjs +3 -1
- 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-UYCOBAL5.js +0 -39
- package/dist/cli/git-EJQLRK27.js +0 -23
- package/dist/cli/play-AGSECQFN.mjs +0 -159
- package/dist/cli/play-BR2LWGXK.js +0 -159
- package/dist/cli/search-ZVSYH5GY.js +0 -28
- package/dist/cli/skills-SPXUBLII.js +0 -28
- package/dist/cli/tools-DBHUUZJX.js +0 -42
- package/dist/cli/update-VSNFXRHJ.js +0 -28
- package/dist/cli/{chunk-KZZC33PY.mjs → chunk-H5KLUGY7.mjs} +214 -214
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkRTO5QZWTjs = require('./chunk-RTO5QZWT.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
@@ -25,7 +25,7 @@ var _chunkHRWUQJ4Kjs = require('./chunk-HRWUQJ4K.js');
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var _chunkV7UP2F4Ujs = require('./chunk-V7UP2F4U.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 _chunkV7UP2F4Ujs.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 = _chunkV7UP2F4Ujs.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 `${_chunkV7UP2F4Ujs.hostConfigDirPath.call(void 0, baseUrl)}/pending-auth.json`;
|
|
79
79
|
}
|
|
80
80
|
function legacyPendingClaimTokenPath(baseUrl) {
|
|
81
|
-
return `${
|
|
81
|
+
return `${_chunkV7UP2F4Ujs.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 _chunkV7UP2F4Ujs.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[_chunkV7UP2F4Ujs.HOST_URL_ENV] ? { [_chunkV7UP2F4Ujs.HOST_URL_ENV]: values[_chunkV7UP2F4Ujs.HOST_URL_ENV] } : {},
|
|
188
|
+
...values[_chunkV7UP2F4Ujs.API_KEY_ENV] ? { [_chunkV7UP2F4Ujs.API_KEY_ENV]: values[_chunkV7UP2F4Ujs.API_KEY_ENV] } : {},
|
|
189
|
+
...values[_chunkV7UP2F4Ujs.ACTIVE_ORG_ID_ENV] ? { [_chunkV7UP2F4Ujs.ACTIVE_ORG_ID_ENV]: values[_chunkV7UP2F4Ujs.ACTIVE_ORG_ID_ENV] } : {},
|
|
190
|
+
...Object.prototype.hasOwnProperty.call(values, _chunkV7UP2F4Ujs.ACTIVE_ORG_NAME_ENV) ? { [_chunkV7UP2F4Ujs.ACTIVE_ORG_NAME_ENV]: values[_chunkV7UP2F4Ujs.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, _chunkV7UP2F4Ujs.FEATURES_ENV) ? { [_chunkV7UP2F4Ujs.FEATURES_ENV]: values[_chunkV7UP2F4Ujs.FEATURES_ENV] } : {}
|
|
193
193
|
};
|
|
194
194
|
if (scope === "folder") {
|
|
195
|
-
|
|
195
|
+
_chunkV7UP2F4Ujs.saveProjectDeeplineEnvValues.call(void 0, filtered);
|
|
196
196
|
} else {
|
|
197
|
-
|
|
197
|
+
_chunkV7UP2F4Ujs.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
|
+
[_chunkV7UP2F4Ujs.ACTIVE_ORG_ID_ENV]: orgId,
|
|
206
|
+
[_chunkV7UP2F4Ujs.ACTIVE_ORG_NAME_ENV]: orgName,
|
|
207
|
+
..._chunkV7UP2F4Ujs.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/${_chunkV7UP2F4Ujs.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": _chunkV7UP2F4Ujs.detectAgentRuntime.call(void 0, ),
|
|
217
|
+
"X-Deepline-CLI-Version": _chunkV7UP2F4Ujs.SDK_VERSION,
|
|
218
|
+
"X-Deepline-SDK-Version": _chunkV7UP2F4Ujs.SDK_VERSION,
|
|
219
|
+
"X-Deepline-API-Contract": _chunkV7UP2F4Ujs.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()]);
|
|
@@ -262,7 +262,7 @@ async function readStatusBanner(baseUrl) {
|
|
|
262
262
|
return _optionalChain([response, 'optionalAccess', _11 => _11.status]) === 200 ? _nullishCoalesce(response.data.banner, () => ( null)) : null;
|
|
263
263
|
}
|
|
264
264
|
async function reportSetupCompleted(input) {
|
|
265
|
-
const apiKey = input.authScope === "folder" ?
|
|
265
|
+
const apiKey = input.authScope === "folder" ? _chunkV7UP2F4Ujs.resolveProjectApiKeyForBaseUrl.call(void 0, input.baseUrl) : _chunkV7UP2F4Ujs.resolveGlobalApiKeyForBaseUrl.call(void 0, input.baseUrl);
|
|
266
266
|
if (!apiKey) return;
|
|
267
267
|
try {
|
|
268
268
|
await httpJson(
|
|
@@ -359,7 +359,7 @@ async function printClaimSuccessBanner(baseUrl, apiKey, statusData) {
|
|
|
359
359
|
}
|
|
360
360
|
}
|
|
361
361
|
async function handleRegister(args) {
|
|
362
|
-
const baseUrl =
|
|
362
|
+
const baseUrl = _chunkV7UP2F4Ujs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
363
363
|
let orgName = "";
|
|
364
364
|
let orgId = "";
|
|
365
365
|
let agentName = "";
|
|
@@ -414,19 +414,19 @@ async function handleRegister(args) {
|
|
|
414
414
|
});
|
|
415
415
|
saveEnvValues(
|
|
416
416
|
{
|
|
417
|
-
[
|
|
417
|
+
[_chunkV7UP2F4Ujs.HOST_URL_ENV]: baseUrl
|
|
418
418
|
},
|
|
419
419
|
baseUrl,
|
|
420
420
|
authScope
|
|
421
421
|
);
|
|
422
422
|
}
|
|
423
423
|
if (claimUrl) {
|
|
424
|
-
const shouldOpen = waitMode !== "no" &&
|
|
424
|
+
const shouldOpen = waitMode !== "no" && _chunkV7UP2F4Ujs.detectAgentRuntime.call(void 0, ) !== "claude_cowork";
|
|
425
425
|
console.log(
|
|
426
426
|
shouldOpen ? " Opening approval page in your browser." : " Open this approval page in your browser:"
|
|
427
427
|
);
|
|
428
428
|
console.log(` ${claimUrl}`);
|
|
429
|
-
if (shouldOpen)
|
|
429
|
+
if (shouldOpen) _chunkRTO5QZWTjs.openInBrowser.call(void 0, claimUrl);
|
|
430
430
|
}
|
|
431
431
|
if (data.cli_message) {
|
|
432
432
|
console.log(String(data.cli_message));
|
|
@@ -469,8 +469,8 @@ async function handleRegister(args) {
|
|
|
469
469
|
if (apiKey) {
|
|
470
470
|
saveEnvValues(
|
|
471
471
|
{
|
|
472
|
-
[
|
|
473
|
-
[
|
|
472
|
+
[_chunkV7UP2F4Ujs.HOST_URL_ENV]: baseUrl,
|
|
473
|
+
[_chunkV7UP2F4Ujs.API_KEY_ENV]: apiKey,
|
|
474
474
|
...activeOrgEnvValues(statusData)
|
|
475
475
|
},
|
|
476
476
|
baseUrl,
|
|
@@ -492,7 +492,7 @@ async function handleRegister(args) {
|
|
|
492
492
|
}
|
|
493
493
|
}
|
|
494
494
|
async function handleWait(args) {
|
|
495
|
-
const baseUrl =
|
|
495
|
+
const baseUrl = _chunkV7UP2F4Ujs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
496
496
|
let timeoutSeconds = 300;
|
|
497
497
|
let requestedScope;
|
|
498
498
|
if (args.includes("--auth-scope")) {
|
|
@@ -516,7 +516,7 @@ async function handleWait(args) {
|
|
|
516
516
|
const authScope = resumed.scope;
|
|
517
517
|
const claimToken = _nullishCoalesce(_optionalChain([pendingClaim, 'optionalAccess', _12 => _12.claimToken]), () => ( ""));
|
|
518
518
|
if (!pendingClaim) {
|
|
519
|
-
const scopedApiKey = authScope === "folder" ?
|
|
519
|
+
const scopedApiKey = authScope === "folder" ? _chunkV7UP2F4Ujs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkV7UP2F4Ujs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
520
520
|
if (scopedApiKey) {
|
|
521
521
|
console.log("Already connected.");
|
|
522
522
|
return EXIT_OK;
|
|
@@ -559,8 +559,8 @@ async function handleWait(args) {
|
|
|
559
559
|
if (apiKey) {
|
|
560
560
|
saveEnvValues(
|
|
561
561
|
{
|
|
562
|
-
[
|
|
563
|
-
[
|
|
562
|
+
[_chunkV7UP2F4Ujs.HOST_URL_ENV]: baseUrl,
|
|
563
|
+
[_chunkV7UP2F4Ujs.API_KEY_ENV]: apiKey,
|
|
564
564
|
...activeOrgEnvValues(data)
|
|
565
565
|
},
|
|
566
566
|
baseUrl,
|
|
@@ -584,8 +584,8 @@ async function handleWait(args) {
|
|
|
584
584
|
return EXIT_AUTH;
|
|
585
585
|
}
|
|
586
586
|
async function authStatusLine(timeoutMs = 3e3) {
|
|
587
|
-
const baseUrl =
|
|
588
|
-
const apiKey =
|
|
587
|
+
const baseUrl = _chunkV7UP2F4Ujs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
588
|
+
const apiKey = _chunkV7UP2F4Ujs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
589
589
|
if (!apiKey) return `Auth: not connected (${baseUrl})`;
|
|
590
590
|
try {
|
|
591
591
|
const { status, data } = await httpJson(
|
|
@@ -608,9 +608,9 @@ async function authStatusLine(timeoutMs = 3e3) {
|
|
|
608
608
|
}
|
|
609
609
|
}
|
|
610
610
|
async function handleStatus(args) {
|
|
611
|
-
const baseUrl =
|
|
611
|
+
const baseUrl = _chunkV7UP2F4Ujs.autoDetectBaseUrl.call(void 0, ).replace(/\/$/, "");
|
|
612
612
|
const reveal = args.includes("--reveal");
|
|
613
|
-
const jsonOutput =
|
|
613
|
+
const jsonOutput = _chunkRTO5QZWTjs.argsWantJson.call(void 0, args);
|
|
614
614
|
const hasExplicitAuthScope = args.includes("--auth-scope");
|
|
615
615
|
let authScope = null;
|
|
616
616
|
if (hasExplicitAuthScope) {
|
|
@@ -651,14 +651,14 @@ async function handleStatus(args) {
|
|
|
651
651
|
};
|
|
652
652
|
hostLines.push(`Host: ${baseUrl} (unreachable)`);
|
|
653
653
|
}
|
|
654
|
-
const apiKey = authScope === "folder" ?
|
|
654
|
+
const apiKey = authScope === "folder" ? _chunkV7UP2F4Ujs.resolveProjectApiKeyForBaseUrl.call(void 0, baseUrl) : authScope === "global" ? _chunkV7UP2F4Ujs.resolveGlobalApiKeyForBaseUrl.call(void 0, baseUrl) : _chunkV7UP2F4Ujs.resolveApiKeyForBaseUrl.call(void 0, baseUrl);
|
|
655
655
|
if (!apiKey) {
|
|
656
656
|
const { claim: pendingClaim } = resolvePendingAuthClaimForResume(
|
|
657
657
|
baseUrl,
|
|
658
658
|
_nullishCoalesce(authScope, () => ( void 0))
|
|
659
659
|
);
|
|
660
660
|
if (pendingClaim) {
|
|
661
|
-
|
|
661
|
+
_chunkRTO5QZWTjs.printCommandEnvelope.call(void 0,
|
|
662
662
|
{
|
|
663
663
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
664
664
|
status: "pending",
|
|
@@ -679,7 +679,7 @@ async function handleStatus(args) {
|
|
|
679
679
|
);
|
|
680
680
|
return EXIT_OK;
|
|
681
681
|
}
|
|
682
|
-
|
|
682
|
+
_chunkRTO5QZWTjs.printCommandEnvelope.call(void 0,
|
|
683
683
|
{
|
|
684
684
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
685
685
|
status: "not connected",
|
|
@@ -712,7 +712,7 @@ async function handleStatus(args) {
|
|
|
712
712
|
}
|
|
713
713
|
);
|
|
714
714
|
if (status === 401 || status === 403) {
|
|
715
|
-
|
|
715
|
+
_chunkRTO5QZWTjs.printCommandEnvelope.call(void 0,
|
|
716
716
|
{
|
|
717
717
|
..._nullishCoalesce(hostStatusPayload, () => ( { host: baseUrl })),
|
|
718
718
|
status: "unauthorized",
|
|
@@ -739,7 +739,7 @@ async function handleStatus(args) {
|
|
|
739
739
|
console.error(`Auth status error (status ${status}).`);
|
|
740
740
|
return EXIT_SERVER;
|
|
741
741
|
}
|
|
742
|
-
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (
|
|
742
|
+
const resolvedAuthScope = _nullishCoalesce(authScope, () => ( (_chunkV7UP2F4Ujs.getResolvedProjectAuthSource.call(void 0, baseUrl, apiKey) ? "folder" : "global")));
|
|
743
743
|
clearSatisfiedPendingClaim(
|
|
744
744
|
baseUrl,
|
|
745
745
|
resolvedAuthScope,
|
|
@@ -767,28 +767,28 @@ async function handleStatus(args) {
|
|
|
767
767
|
if (apiKeyResp) {
|
|
768
768
|
saveEnvValues(
|
|
769
769
|
{
|
|
770
|
-
[
|
|
771
|
-
[
|
|
770
|
+
[_chunkV7UP2F4Ujs.HOST_URL_ENV]: baseUrl,
|
|
771
|
+
[_chunkV7UP2F4Ujs.API_KEY_ENV]: apiKeyResp,
|
|
772
772
|
...activeOrgEnvValues(data)
|
|
773
773
|
},
|
|
774
774
|
baseUrl,
|
|
775
775
|
resolvedAuthScope
|
|
776
776
|
);
|
|
777
777
|
if (resolvedAuthScope === "folder") {
|
|
778
|
-
const target =
|
|
778
|
+
const target = _chunkV7UP2F4Ujs.resolveProjectPinTarget.call(void 0, );
|
|
779
779
|
savedApiKeyPath = target.ok ? _path.join.call(void 0, target.dir, ".env.deepline") : null;
|
|
780
780
|
} else {
|
|
781
781
|
savedApiKeyPath = envFilePath(baseUrl);
|
|
782
782
|
}
|
|
783
783
|
}
|
|
784
|
-
} else if (resolvedAuthScope === "folder" ||
|
|
785
|
-
saveEnvValues(
|
|
784
|
+
} else if (resolvedAuthScope === "folder" || _chunkV7UP2F4Ujs.storedHostApiKey.call(void 0, baseUrl) === apiKey) {
|
|
785
|
+
saveEnvValues(_chunkV7UP2F4Ujs.featureEnvValues.call(void 0, data), baseUrl, resolvedAuthScope);
|
|
786
786
|
}
|
|
787
|
-
|
|
787
|
+
_chunkRTO5QZWTjs.printCommandEnvelope.call(void 0,
|
|
788
788
|
{
|
|
789
789
|
...payload,
|
|
790
|
-
...
|
|
791
|
-
command_context:
|
|
790
|
+
..._chunkV7UP2F4Ujs.detectAgentRuntime.call(void 0, ) !== "unknown" ? {
|
|
791
|
+
command_context: _chunkV7UP2F4Ujs.resolveCliCommandContext.call(void 0,
|
|
792
792
|
{ baseUrl, apiKey },
|
|
793
793
|
resolvedAuthScope
|
|
794
794
|
)
|
|
@@ -1,6 +1,6 @@
|
|
|
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
|
-
var
|
|
3
|
+
var _chunkRMTASUAKjs = require('./chunk-RMTASUAK.js');
|
|
4
4
|
|
|
5
5
|
// src/cli/npm-script-policy.ts
|
|
6
6
|
var _child_process = require('child_process');
|
|
@@ -13,7 +13,7 @@ function npmSupportsAllowScripts(version) {
|
|
|
13
13
|
}
|
|
14
14
|
function readNpmVersion(env) {
|
|
15
15
|
try {
|
|
16
|
-
const plan =
|
|
16
|
+
const plan = _chunkRMTASUAKjs.resolveShellSpawn.call(void 0, "npm", ["--version"], process.platform, env);
|
|
17
17
|
const result = _child_process.spawnSync.call(void 0, plan.command, plan.args, {
|
|
18
18
|
encoding: "utf8",
|
|
19
19
|
env,
|
|
@@ -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.396",
|
|
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,
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
npmSupportsAllowScripts,
|
|
3
3
|
readNpmVersion
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-23GAA3YO.mjs";
|
|
5
5
|
import {
|
|
6
6
|
resolveShellSpawn,
|
|
7
7
|
runSkillsCommand
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-TLQ3FZOC.mjs";
|
|
9
9
|
import {
|
|
10
10
|
printCommandEnvelope
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-XKZXO7D3.mjs";
|
|
12
12
|
import {
|
|
13
13
|
autoDetectBaseUrl
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-VE3U3SQC.mjs";
|
|
15
15
|
|
|
16
16
|
// src/cli/commands/update.ts
|
|
17
17
|
import { spawn, spawnSync } from "child_process";
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
argsWantJson,
|
|
3
3
|
openInBrowser,
|
|
4
4
|
printCommandEnvelope
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-XKZXO7D3.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-VE3U3SQC.mjs";
|
|
29
29
|
|
|
30
30
|
// src/cli/commands/auth.ts
|
|
31
31
|
import {
|
|
@@ -1,14 +1,14 @@
|
|
|
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
|
-
var
|
|
3
|
+
var _chunkWQJJNIMQjs = require('./chunk-WQJJNIMQ.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkRTO5QZWTjs = require('./chunk-RTO5QZWT.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkV7UP2F4Ujs = require('./chunk-V7UP2F4U.js');
|
|
12
12
|
|
|
13
13
|
// src/cli/commands/search.ts
|
|
14
14
|
var _commander = require('commander');
|
|
@@ -18,7 +18,7 @@ var _fs = require('fs');
|
|
|
18
18
|
var _path = require('path');
|
|
19
19
|
var SEARCH_REF_TTL_MS = 15 * 6e4;
|
|
20
20
|
function lastSearchPath() {
|
|
21
|
-
return _path.join.call(void 0,
|
|
21
|
+
return _path.join.call(void 0, _chunkV7UP2F4Ujs.sdkCliStateDirPath.call(void 0, _chunkV7UP2F4Ujs.resolveConfig.call(void 0, ).baseUrl), "last-search.json");
|
|
22
22
|
}
|
|
23
23
|
function rememberSearchRef(searchRef) {
|
|
24
24
|
try {
|
|
@@ -238,6 +238,11 @@ function rateLimitDisplay(item) {
|
|
|
238
238
|
);
|
|
239
239
|
return tightest ? `${tightest.requestsPerWindow}/${_nullishCoalesce(RATE_WINDOW_UNITS[tightest.windowMs], () => ( `${tightest.windowMs / 1e3}s`))}` : "\u2014";
|
|
240
240
|
}
|
|
241
|
+
function failureRateDisplay(rate) {
|
|
242
|
+
if (typeof rate !== "number") return "\u2014";
|
|
243
|
+
const percent = Math.round(rate * 100);
|
|
244
|
+
return percent === 0 && rate > 0 ? "<1%" : `${percent}%`;
|
|
245
|
+
}
|
|
241
246
|
function searchRow(item) {
|
|
242
247
|
const { cost, notes } = pricingDisplay(item);
|
|
243
248
|
const observedMax = item.billingSource === "own_provider_credentials" ? "" : observedMaxText(item.pricing);
|
|
@@ -253,13 +258,16 @@ function searchRow(item) {
|
|
|
253
258
|
kind: item.kind,
|
|
254
259
|
cost,
|
|
255
260
|
rateLimit: rateLimitDisplay(item),
|
|
261
|
+
// Production share of errored or rate-limited calls; absent when too few
|
|
262
|
+
// calls or orgs used the tool to say.
|
|
263
|
+
failureRate: failureRateDisplay(item.failureRate),
|
|
256
264
|
summary: clipSummary(_nullishCoalesce(item.description, () => ( ""))),
|
|
257
265
|
notes
|
|
258
266
|
};
|
|
259
267
|
}
|
|
260
268
|
function renderSearchResults(result) {
|
|
261
269
|
if (result.results.length === 0)
|
|
262
|
-
return
|
|
270
|
+
return _chunkRTO5QZWTjs.renderCommandEnvelopeText.call(void 0, result);
|
|
263
271
|
const rows = result.results.map(searchRow);
|
|
264
272
|
const kinds = new Set(rows.map((row) => row.kind));
|
|
265
273
|
const onlyTools = kinds.size === 1 && kinds.has("tool");
|
|
@@ -274,6 +282,13 @@ function renderSearchResults(result) {
|
|
|
274
282
|
alignment: "right"
|
|
275
283
|
}
|
|
276
284
|
] : [],
|
|
285
|
+
...rows.some((row) => row.failureRate !== "\u2014") ? [
|
|
286
|
+
{
|
|
287
|
+
header: "FAILURES",
|
|
288
|
+
value: (row) => row.failureRate,
|
|
289
|
+
alignment: "right"
|
|
290
|
+
}
|
|
291
|
+
] : [],
|
|
277
292
|
{ header: "SUMMARY", value: (row) => row.summary }
|
|
278
293
|
];
|
|
279
294
|
const render = result.render;
|
|
@@ -283,7 +298,7 @@ function renderSearchResults(result) {
|
|
|
283
298
|
actions: _optionalChain([render, 'optionalAccess', _11 => _11.actions])
|
|
284
299
|
};
|
|
285
300
|
const followUps = _optionalChain([remaining, 'access', _12 => _12.sections, 'optionalAccess', _13 => _13.length]) || _optionalChain([remaining, 'access', _14 => _14.actions, 'optionalAccess', _15 => _15.length]) ? `
|
|
286
|
-
${
|
|
301
|
+
${_chunkRTO5QZWTjs.renderCommandEnvelopeText.call(void 0, { render: remaining })}` : "";
|
|
287
302
|
const notes = rows.flatMap(
|
|
288
303
|
(row) => row.notes.map((note) => ` ${row.id}: ${note}`)
|
|
289
304
|
);
|
|
@@ -360,7 +375,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
360
375
|
console.error(USAGE);
|
|
361
376
|
return 1;
|
|
362
377
|
}
|
|
363
|
-
const { search_ref: searchRef, ...result } = await new (0,
|
|
378
|
+
const { search_ref: searchRef, ...result } = await new (0, _chunkWQJJNIMQjs.DeeplineClient)().search({
|
|
364
379
|
query,
|
|
365
380
|
types,
|
|
366
381
|
exclude,
|
|
@@ -374,7 +389,7 @@ async function runSearch(queryInput, options, types, exclude = []) {
|
|
|
374
389
|
});
|
|
375
390
|
if (searchRef) rememberSearchRef(searchRef);
|
|
376
391
|
pointAtDescribe(result);
|
|
377
|
-
|
|
392
|
+
_chunkRTO5QZWTjs.printCommandEnvelope.call(void 0, result, {
|
|
378
393
|
json: options.json === true,
|
|
379
394
|
text: renderSearchResults(result)
|
|
380
395
|
});
|
|
@@ -126,4 +126,5 @@ function describePlayDetail(detail, options = {}) {
|
|
|
126
126
|
|
|
127
127
|
|
|
128
128
|
|
|
129
|
-
|
|
129
|
+
|
|
130
|
+
exports.CSV_HEADER_MATCHING_NOTE = CSV_HEADER_MATCHING_NOTE; exports.playInputExampleArgs = playInputExampleArgs; exports.cloneEditStarter = cloneEditStarter; exports.describePlayListItem = describePlayListItem; exports.describePlayDetail = describePlayDetail;
|
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
getAuthedHttpClient,
|
|
3
3
|
openInBrowser,
|
|
4
4
|
printCommandEnvelope
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-XKZXO7D3.mjs";
|
|
6
6
|
import {
|
|
7
7
|
resolveBaseUrlOnly
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-VE3U3SQC.mjs";
|
|
9
9
|
|
|
10
10
|
// src/cli/commands/git.ts
|
|
11
11
|
function shellQuote(value) {
|