@inkeep/agents-cli 0.0.0-dev-20251216202428 → 0.0.0-dev-20251217003520
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/index.js +94 -159
- package/package.json +6 -4
package/dist/index.js
CHANGED
|
@@ -26508,8 +26508,8 @@ ${lanes.join("\n")}
|
|
|
26508
26508
|
return isJSDocImplementsTag(node.parent) || isJSDocAugmentsTag(node.parent) || isHeritageClause(node.parent) && !isExpressionWithTypeArgumentsInClassExtendsClause(node);
|
|
26509
26509
|
}
|
|
26510
26510
|
function forEachReturnStatement(body2, visitor) {
|
|
26511
|
-
return
|
|
26512
|
-
function
|
|
26511
|
+
return traverse2(body2);
|
|
26512
|
+
function traverse2(node) {
|
|
26513
26513
|
switch (node.kind) {
|
|
26514
26514
|
case 254:
|
|
26515
26515
|
return visitor(node);
|
|
@@ -26528,19 +26528,19 @@ ${lanes.join("\n")}
|
|
|
26528
26528
|
case 257:
|
|
26529
26529
|
case 259:
|
|
26530
26530
|
case 300:
|
|
26531
|
-
return forEachChild(node,
|
|
26531
|
+
return forEachChild(node, traverse2);
|
|
26532
26532
|
}
|
|
26533
26533
|
}
|
|
26534
26534
|
}
|
|
26535
26535
|
function forEachYieldExpression(body2, visitor) {
|
|
26536
|
-
return
|
|
26537
|
-
function
|
|
26536
|
+
return traverse2(body2);
|
|
26537
|
+
function traverse2(node) {
|
|
26538
26538
|
switch (node.kind) {
|
|
26539
26539
|
case 230:
|
|
26540
26540
|
visitor(node);
|
|
26541
26541
|
const operand = node.expression;
|
|
26542
26542
|
if (operand) {
|
|
26543
|
-
|
|
26543
|
+
traverse2(operand);
|
|
26544
26544
|
}
|
|
26545
26545
|
return;
|
|
26546
26546
|
case 267:
|
|
@@ -26551,11 +26551,11 @@ ${lanes.join("\n")}
|
|
|
26551
26551
|
default:
|
|
26552
26552
|
if (isFunctionLike(node)) {
|
|
26553
26553
|
if (node.name && node.name.kind === 168) {
|
|
26554
|
-
|
|
26554
|
+
traverse2(node.name.expression);
|
|
26555
26555
|
return;
|
|
26556
26556
|
}
|
|
26557
26557
|
} else if (!isPartOfTypeNode(node)) {
|
|
26558
|
-
forEachChild(node,
|
|
26558
|
+
forEachChild(node, traverse2);
|
|
26559
26559
|
}
|
|
26560
26560
|
}
|
|
26561
26561
|
}
|
|
@@ -77021,11 +77021,11 @@ ${lanes.join("\n")}
|
|
|
77021
77021
|
if (links.flags & 512) {
|
|
77022
77022
|
links.containsArgumentsReference = true;
|
|
77023
77023
|
} else {
|
|
77024
|
-
links.containsArgumentsReference =
|
|
77024
|
+
links.containsArgumentsReference = traverse2(declaration.body);
|
|
77025
77025
|
}
|
|
77026
77026
|
}
|
|
77027
77027
|
return links.containsArgumentsReference;
|
|
77028
|
-
function
|
|
77028
|
+
function traverse2(node) {
|
|
77029
77029
|
if (!node) return false;
|
|
77030
77030
|
switch (node.kind) {
|
|
77031
77031
|
case 80:
|
|
@@ -77034,14 +77034,14 @@ ${lanes.join("\n")}
|
|
|
77034
77034
|
case 175:
|
|
77035
77035
|
case 178:
|
|
77036
77036
|
case 179:
|
|
77037
|
-
return node.name.kind === 168 &&
|
|
77037
|
+
return node.name.kind === 168 && traverse2(node.name);
|
|
77038
77038
|
case 212:
|
|
77039
77039
|
case 213:
|
|
77040
|
-
return
|
|
77040
|
+
return traverse2(node.expression);
|
|
77041
77041
|
case 304:
|
|
77042
|
-
return
|
|
77042
|
+
return traverse2(node.initializer);
|
|
77043
77043
|
default:
|
|
77044
|
-
return !nodeStartsNewLexicalEnvironment(node) && !isPartOfTypeNode(node) && !!forEachChild(node,
|
|
77044
|
+
return !nodeStartsNewLexicalEnvironment(node) && !isPartOfTypeNode(node) && !!forEachChild(node, traverse2);
|
|
77045
77045
|
}
|
|
77046
77046
|
}
|
|
77047
77047
|
}
|
|
@@ -220910,6 +220910,16 @@ var init_format_messages = __esm({
|
|
|
220910
220910
|
}
|
|
220911
220911
|
});
|
|
220912
220912
|
|
|
220913
|
+
// ../packages/agents-core/src/utils/json-parser.ts
|
|
220914
|
+
import destr from "destr";
|
|
220915
|
+
import traverse from "traverse";
|
|
220916
|
+
var init_json_parser = __esm({
|
|
220917
|
+
"../packages/agents-core/src/utils/json-parser.ts"() {
|
|
220918
|
+
"use strict";
|
|
220919
|
+
init_esm_shims();
|
|
220920
|
+
}
|
|
220921
|
+
});
|
|
220922
|
+
|
|
220913
220923
|
// ../node_modules/.pnpm/@modelcontextprotocol+sdk@1.24.3_zod@4.1.13/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-compat.js
|
|
220914
220924
|
import * as z3rt from "zod/v3";
|
|
220915
220925
|
import * as z4mini from "zod/v4-mini";
|
|
@@ -223444,7 +223454,7 @@ var require_json_schema_traverse = __commonJS({
|
|
|
223444
223454
|
"../node_modules/.pnpm/json-schema-traverse@1.0.0/node_modules/json-schema-traverse/index.js"(exports, module2) {
|
|
223445
223455
|
"use strict";
|
|
223446
223456
|
init_esm_shims();
|
|
223447
|
-
var
|
|
223457
|
+
var traverse2 = module2.exports = function(schema, opts, cb) {
|
|
223448
223458
|
if (typeof opts == "function") {
|
|
223449
223459
|
cb = opts;
|
|
223450
223460
|
opts = {};
|
|
@@ -223456,7 +223466,7 @@ var require_json_schema_traverse = __commonJS({
|
|
|
223456
223466
|
};
|
|
223457
223467
|
_traverse(opts, pre, post, schema, "", schema);
|
|
223458
223468
|
};
|
|
223459
|
-
|
|
223469
|
+
traverse2.keywords = {
|
|
223460
223470
|
additionalItems: true,
|
|
223461
223471
|
items: true,
|
|
223462
223472
|
contains: true,
|
|
@@ -223467,20 +223477,20 @@ var require_json_schema_traverse = __commonJS({
|
|
|
223467
223477
|
then: true,
|
|
223468
223478
|
else: true
|
|
223469
223479
|
};
|
|
223470
|
-
|
|
223480
|
+
traverse2.arrayKeywords = {
|
|
223471
223481
|
items: true,
|
|
223472
223482
|
allOf: true,
|
|
223473
223483
|
anyOf: true,
|
|
223474
223484
|
oneOf: true
|
|
223475
223485
|
};
|
|
223476
|
-
|
|
223486
|
+
traverse2.propsKeywords = {
|
|
223477
223487
|
$defs: true,
|
|
223478
223488
|
definitions: true,
|
|
223479
223489
|
properties: true,
|
|
223480
223490
|
patternProperties: true,
|
|
223481
223491
|
dependencies: true
|
|
223482
223492
|
};
|
|
223483
|
-
|
|
223493
|
+
traverse2.skipKeywords = {
|
|
223484
223494
|
default: true,
|
|
223485
223495
|
enum: true,
|
|
223486
223496
|
const: true,
|
|
@@ -223506,16 +223516,16 @@ var require_json_schema_traverse = __commonJS({
|
|
|
223506
223516
|
for (var key in schema) {
|
|
223507
223517
|
var sch = schema[key];
|
|
223508
223518
|
if (Array.isArray(sch)) {
|
|
223509
|
-
if (key in
|
|
223519
|
+
if (key in traverse2.arrayKeywords) {
|
|
223510
223520
|
for (var i3 = 0; i3 < sch.length; i3++)
|
|
223511
223521
|
_traverse(opts, pre, post, sch[i3], jsonPtr + "/" + key + "/" + i3, rootSchema, jsonPtr, key, schema, i3);
|
|
223512
223522
|
}
|
|
223513
|
-
} else if (key in
|
|
223523
|
+
} else if (key in traverse2.propsKeywords) {
|
|
223514
223524
|
if (sch && typeof sch == "object") {
|
|
223515
223525
|
for (var prop in sch)
|
|
223516
223526
|
_traverse(opts, pre, post, sch[prop], jsonPtr + "/" + key + "/" + escapeJsonPtr(prop), rootSchema, jsonPtr, key, schema, prop);
|
|
223517
223527
|
}
|
|
223518
|
-
} else if (key in
|
|
223528
|
+
} else if (key in traverse2.keywords || opts.allKeys && !(key in traverse2.skipKeywords)) {
|
|
223519
223529
|
_traverse(opts, pre, post, sch, jsonPtr + "/" + key, rootSchema, jsonPtr, key, schema);
|
|
223520
223530
|
}
|
|
223521
223531
|
}
|
|
@@ -223537,7 +223547,7 @@ var require_resolve = __commonJS({
|
|
|
223537
223547
|
exports.getSchemaRefs = exports.resolveUrl = exports.normalizeId = exports._getFullPath = exports.getFullPath = exports.inlineRef = void 0;
|
|
223538
223548
|
var util_1 = require_util2();
|
|
223539
223549
|
var equal = require_fast_deep_equal();
|
|
223540
|
-
var
|
|
223550
|
+
var traverse2 = require_json_schema_traverse();
|
|
223541
223551
|
var SIMPLE_INLINED = /* @__PURE__ */ new Set([
|
|
223542
223552
|
"type",
|
|
223543
223553
|
"format",
|
|
@@ -223633,7 +223643,7 @@ var require_resolve = __commonJS({
|
|
|
223633
223643
|
const pathPrefix = getFullPath(uriResolver, schId, false);
|
|
223634
223644
|
const localRefs = {};
|
|
223635
223645
|
const schemaRefs = /* @__PURE__ */ new Set();
|
|
223636
|
-
|
|
223646
|
+
traverse2(schema, { allKeys: true }, (sch, jsonPtr, _3, parentJsonPtr) => {
|
|
223637
223647
|
if (parentJsonPtr === void 0)
|
|
223638
223648
|
return;
|
|
223639
223649
|
const fullPath = pathPrefix + jsonPtr;
|
|
@@ -247123,6 +247133,7 @@ var init_utils4 = __esm({
|
|
|
247123
247133
|
init_error();
|
|
247124
247134
|
init_execution();
|
|
247125
247135
|
init_format_messages();
|
|
247136
|
+
init_json_parser();
|
|
247126
247137
|
init_logger();
|
|
247127
247138
|
init_mcp_client();
|
|
247128
247139
|
init_model_factory();
|
|
@@ -259919,9 +259930,9 @@ var require_ms = __commonJS({
|
|
|
259919
259930
|
}
|
|
259920
259931
|
});
|
|
259921
259932
|
|
|
259922
|
-
// ../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
259933
|
+
// ../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/common.js
|
|
259923
259934
|
var require_common = __commonJS({
|
|
259924
|
-
"../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
259935
|
+
"../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/common.js"(exports, module2) {
|
|
259925
259936
|
"use strict";
|
|
259926
259937
|
init_esm_shims();
|
|
259927
259938
|
function setup(env3) {
|
|
@@ -260098,9 +260109,9 @@ var require_common = __commonJS({
|
|
|
260098
260109
|
}
|
|
260099
260110
|
});
|
|
260100
260111
|
|
|
260101
|
-
// ../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260112
|
+
// ../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/browser.js
|
|
260102
260113
|
var require_browser = __commonJS({
|
|
260103
|
-
"../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260114
|
+
"../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/browser.js"(exports, module2) {
|
|
260104
260115
|
"use strict";
|
|
260105
260116
|
init_esm_shims();
|
|
260106
260117
|
exports.formatArgs = formatArgs;
|
|
@@ -260270,45 +260281,37 @@ var require_browser = __commonJS({
|
|
|
260270
260281
|
}
|
|
260271
260282
|
});
|
|
260272
260283
|
|
|
260273
|
-
// ../node_modules/.pnpm/has-flag@
|
|
260284
|
+
// ../node_modules/.pnpm/has-flag@3.0.0/node_modules/has-flag/index.js
|
|
260274
260285
|
var require_has_flag = __commonJS({
|
|
260275
|
-
"../node_modules/.pnpm/has-flag@
|
|
260286
|
+
"../node_modules/.pnpm/has-flag@3.0.0/node_modules/has-flag/index.js"(exports, module2) {
|
|
260276
260287
|
"use strict";
|
|
260277
260288
|
init_esm_shims();
|
|
260278
|
-
module2.exports = (flag, argv
|
|
260289
|
+
module2.exports = (flag, argv) => {
|
|
260290
|
+
argv = argv || process.argv;
|
|
260279
260291
|
const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
|
|
260280
|
-
const
|
|
260281
|
-
const
|
|
260282
|
-
return
|
|
260292
|
+
const pos = argv.indexOf(prefix + flag);
|
|
260293
|
+
const terminatorPos = argv.indexOf("--");
|
|
260294
|
+
return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos);
|
|
260283
260295
|
};
|
|
260284
260296
|
}
|
|
260285
260297
|
});
|
|
260286
260298
|
|
|
260287
|
-
// ../node_modules/.pnpm/supports-color@
|
|
260299
|
+
// ../node_modules/.pnpm/supports-color@5.5.0/node_modules/supports-color/index.js
|
|
260288
260300
|
var require_supports_color = __commonJS({
|
|
260289
|
-
"../node_modules/.pnpm/supports-color@
|
|
260301
|
+
"../node_modules/.pnpm/supports-color@5.5.0/node_modules/supports-color/index.js"(exports, module2) {
|
|
260290
260302
|
"use strict";
|
|
260291
260303
|
init_esm_shims();
|
|
260292
260304
|
var os3 = __require("os");
|
|
260293
|
-
var tty = __require("tty");
|
|
260294
260305
|
var hasFlag = require_has_flag();
|
|
260295
|
-
var
|
|
260296
|
-
var
|
|
260297
|
-
if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false")
|
|
260298
|
-
|
|
260306
|
+
var env3 = process.env;
|
|
260307
|
+
var forceColor;
|
|
260308
|
+
if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false")) {
|
|
260309
|
+
forceColor = false;
|
|
260299
260310
|
} else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) {
|
|
260300
|
-
|
|
260311
|
+
forceColor = true;
|
|
260301
260312
|
}
|
|
260302
|
-
|
|
260303
|
-
|
|
260304
|
-
if (env3.FORCE_COLOR === "true") {
|
|
260305
|
-
return 1;
|
|
260306
|
-
}
|
|
260307
|
-
if (env3.FORCE_COLOR === "false") {
|
|
260308
|
-
return 0;
|
|
260309
|
-
}
|
|
260310
|
-
return env3.FORCE_COLOR.length === 0 ? 1 : Math.min(Number.parseInt(env3.FORCE_COLOR, 10), 3);
|
|
260311
|
-
}
|
|
260313
|
+
if ("FORCE_COLOR" in env3) {
|
|
260314
|
+
forceColor = env3.FORCE_COLOR.length === 0 || parseInt(env3.FORCE_COLOR, 10) !== 0;
|
|
260312
260315
|
}
|
|
260313
260316
|
function translateLevel(level) {
|
|
260314
260317
|
if (level === 0) {
|
|
@@ -260321,39 +260324,29 @@ var require_supports_color = __commonJS({
|
|
|
260321
260324
|
has16m: level >= 3
|
|
260322
260325
|
};
|
|
260323
260326
|
}
|
|
260324
|
-
function supportsColor(
|
|
260325
|
-
|
|
260326
|
-
if (noFlagForceColor !== void 0) {
|
|
260327
|
-
flagForceColor = noFlagForceColor;
|
|
260328
|
-
}
|
|
260329
|
-
const forceColor = sniffFlags ? flagForceColor : noFlagForceColor;
|
|
260330
|
-
if (forceColor === 0) {
|
|
260327
|
+
function supportsColor(stream4) {
|
|
260328
|
+
if (forceColor === false) {
|
|
260331
260329
|
return 0;
|
|
260332
260330
|
}
|
|
260333
|
-
if (
|
|
260334
|
-
|
|
260335
|
-
return 3;
|
|
260336
|
-
}
|
|
260337
|
-
if (hasFlag("color=256")) {
|
|
260338
|
-
return 2;
|
|
260339
|
-
}
|
|
260331
|
+
if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) {
|
|
260332
|
+
return 3;
|
|
260340
260333
|
}
|
|
260341
|
-
if (
|
|
260342
|
-
return
|
|
260334
|
+
if (hasFlag("color=256")) {
|
|
260335
|
+
return 2;
|
|
260343
260336
|
}
|
|
260344
|
-
|
|
260345
|
-
|
|
260346
|
-
return min;
|
|
260337
|
+
if (stream4 && !stream4.isTTY && forceColor !== true) {
|
|
260338
|
+
return 0;
|
|
260347
260339
|
}
|
|
260340
|
+
const min = forceColor ? 1 : 0;
|
|
260348
260341
|
if (process.platform === "win32") {
|
|
260349
260342
|
const osRelease = os3.release().split(".");
|
|
260350
|
-
if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
|
|
260343
|
+
if (Number(process.versions.node.split(".")[0]) >= 8 && Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
|
|
260351
260344
|
return Number(osRelease[2]) >= 14931 ? 3 : 2;
|
|
260352
260345
|
}
|
|
260353
260346
|
return 1;
|
|
260354
260347
|
}
|
|
260355
260348
|
if ("CI" in env3) {
|
|
260356
|
-
if (["TRAVIS", "CIRCLECI", "APPVEYOR", "GITLAB_CI"
|
|
260349
|
+
if (["TRAVIS", "CIRCLECI", "APPVEYOR", "GITLAB_CI"].some((sign) => sign in env3) || env3.CI_NAME === "codeship") {
|
|
260357
260350
|
return 1;
|
|
260358
260351
|
}
|
|
260359
260352
|
return min;
|
|
@@ -260365,7 +260358,7 @@ var require_supports_color = __commonJS({
|
|
|
260365
260358
|
return 3;
|
|
260366
260359
|
}
|
|
260367
260360
|
if ("TERM_PROGRAM" in env3) {
|
|
260368
|
-
const version =
|
|
260361
|
+
const version = parseInt((env3.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
|
|
260369
260362
|
switch (env3.TERM_PROGRAM) {
|
|
260370
260363
|
case "iTerm.app":
|
|
260371
260364
|
return version >= 3 ? 3 : 2;
|
|
@@ -260382,26 +260375,26 @@ var require_supports_color = __commonJS({
|
|
|
260382
260375
|
if ("COLORTERM" in env3) {
|
|
260383
260376
|
return 1;
|
|
260384
260377
|
}
|
|
260378
|
+
if (env3.TERM === "dumb") {
|
|
260379
|
+
return min;
|
|
260380
|
+
}
|
|
260385
260381
|
return min;
|
|
260386
260382
|
}
|
|
260387
|
-
function getSupportLevel(stream4
|
|
260388
|
-
const level = supportsColor(stream4
|
|
260389
|
-
streamIsTTY: stream4 && stream4.isTTY,
|
|
260390
|
-
...options
|
|
260391
|
-
});
|
|
260383
|
+
function getSupportLevel(stream4) {
|
|
260384
|
+
const level = supportsColor(stream4);
|
|
260392
260385
|
return translateLevel(level);
|
|
260393
260386
|
}
|
|
260394
260387
|
module2.exports = {
|
|
260395
260388
|
supportsColor: getSupportLevel,
|
|
260396
|
-
stdout: getSupportLevel(
|
|
260397
|
-
stderr: getSupportLevel(
|
|
260389
|
+
stdout: getSupportLevel(process.stdout),
|
|
260390
|
+
stderr: getSupportLevel(process.stderr)
|
|
260398
260391
|
};
|
|
260399
260392
|
}
|
|
260400
260393
|
});
|
|
260401
260394
|
|
|
260402
|
-
// ../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260395
|
+
// ../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/node.js
|
|
260403
260396
|
var require_node = __commonJS({
|
|
260404
|
-
"../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260397
|
+
"../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/node.js"(exports, module2) {
|
|
260405
260398
|
"use strict";
|
|
260406
260399
|
init_esm_shims();
|
|
260407
260400
|
var tty = __require("tty");
|
|
@@ -260575,9 +260568,9 @@ var require_node = __commonJS({
|
|
|
260575
260568
|
}
|
|
260576
260569
|
});
|
|
260577
260570
|
|
|
260578
|
-
// ../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260571
|
+
// ../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/index.js
|
|
260579
260572
|
var require_src = __commonJS({
|
|
260580
|
-
"../node_modules/.pnpm/debug@4.4.3_supports-color@
|
|
260573
|
+
"../node_modules/.pnpm/debug@4.4.3_supports-color@5.5.0/node_modules/debug/src/index.js"(exports, module2) {
|
|
260581
260574
|
"use strict";
|
|
260582
260575
|
init_esm_shims();
|
|
260583
260576
|
if (typeof process === "undefined" || process.type === "renderer" || process.browser === true || process.__nwjs) {
|
|
@@ -263641,13 +263634,6 @@ var init_types4 = __esm({
|
|
|
263641
263634
|
});
|
|
263642
263635
|
|
|
263643
263636
|
// ../node_modules/.pnpm/@nangohq+node@0.69.14/node_modules/@nangohq/node/dist/index.js
|
|
263644
|
-
var dist_exports = {};
|
|
263645
|
-
__export(dist_exports, {
|
|
263646
|
-
Nango: () => Nango,
|
|
263647
|
-
SyncConfigType: () => SyncConfigType,
|
|
263648
|
-
getUserAgent: () => getUserAgent,
|
|
263649
|
-
prodHost: () => prodHost
|
|
263650
|
-
});
|
|
263651
263637
|
import crypto6 from "crypto";
|
|
263652
263638
|
import https2 from "https";
|
|
263653
263639
|
var prodHost, defaultHttpsAgent, Nango;
|
|
@@ -264528,27 +264514,6 @@ var init_dist12 = __esm({
|
|
|
264528
264514
|
});
|
|
264529
264515
|
|
|
264530
264516
|
// ../packages/agents-core/src/credential-stores/nango-store.ts
|
|
264531
|
-
function isNangoAvailable() {
|
|
264532
|
-
try {
|
|
264533
|
-
__require.resolve("@nangohq/node");
|
|
264534
|
-
return true;
|
|
264535
|
-
} catch {
|
|
264536
|
-
return false;
|
|
264537
|
-
}
|
|
264538
|
-
}
|
|
264539
|
-
async function loadNangoModule() {
|
|
264540
|
-
if (nangoModule) {
|
|
264541
|
-
return nangoModule;
|
|
264542
|
-
}
|
|
264543
|
-
try {
|
|
264544
|
-
nangoModule = await Promise.resolve().then(() => (init_dist12(), dist_exports));
|
|
264545
|
-
return nangoModule;
|
|
264546
|
-
} catch {
|
|
264547
|
-
throw new Error(
|
|
264548
|
-
"Nango is not installed. To use Nango credential store, install it with: npm install @nangohq/node @nangohq/types"
|
|
264549
|
-
);
|
|
264550
|
-
}
|
|
264551
|
-
}
|
|
264552
264517
|
function parseCredentialKey(key) {
|
|
264553
264518
|
try {
|
|
264554
264519
|
const parsed = JSON.parse(key);
|
|
@@ -264568,11 +264533,6 @@ function isSupportedAuthMode(mode) {
|
|
|
264568
264533
|
return SUPPORTED_AUTH_MODES.includes(mode);
|
|
264569
264534
|
}
|
|
264570
264535
|
function createNangoCredentialStore(id, config) {
|
|
264571
|
-
if (!isNangoAvailable()) {
|
|
264572
|
-
throw new Error(
|
|
264573
|
-
"Nango is not installed. To use Nango credential store, install it with: npm install @nangohq/node @nangohq/types"
|
|
264574
|
-
);
|
|
264575
|
-
}
|
|
264576
264536
|
const nangoSecretKey = config?.secretKey || process.env.NANGO_SECRET_KEY;
|
|
264577
264537
|
if (!nangoSecretKey || nangoSecretKey === "your_nango_secret_key" || nangoSecretKey.includes("mock")) {
|
|
264578
264538
|
throw new Error(
|
|
@@ -264585,16 +264545,16 @@ function createNangoCredentialStore(id, config) {
|
|
|
264585
264545
|
secretKey: nangoSecretKey
|
|
264586
264546
|
});
|
|
264587
264547
|
}
|
|
264588
|
-
var logger18,
|
|
264548
|
+
var logger18, CredentialKeySchema, SUPPORTED_AUTH_MODES, NangoCredentialStore;
|
|
264589
264549
|
var init_nango_store = __esm({
|
|
264590
264550
|
"../packages/agents-core/src/credential-stores/nango-store.ts"() {
|
|
264591
264551
|
"use strict";
|
|
264592
264552
|
init_esm_shims();
|
|
264593
264553
|
init_dist4();
|
|
264554
|
+
init_dist12();
|
|
264594
264555
|
init_types();
|
|
264595
264556
|
init_logger();
|
|
264596
264557
|
logger18 = getLogger("nango-credential-store");
|
|
264597
|
-
nangoModule = null;
|
|
264598
264558
|
CredentialKeySchema = z.object({
|
|
264599
264559
|
connectionId: z.string().min(1, "connectionId must be a non-empty string"),
|
|
264600
264560
|
providerConfigKey: z.string().min(1, "providerConfigKey must be a non-empty string"),
|
|
@@ -264616,24 +264576,14 @@ var init_nango_store = __esm({
|
|
|
264616
264576
|
id;
|
|
264617
264577
|
type = CredentialStoreType.nango;
|
|
264618
264578
|
nangoConfig;
|
|
264619
|
-
nangoClient
|
|
264579
|
+
nangoClient;
|
|
264620
264580
|
constructor(id, config) {
|
|
264621
264581
|
this.id = id;
|
|
264622
264582
|
this.nangoConfig = config;
|
|
264623
|
-
|
|
264624
|
-
/**
|
|
264625
|
-
* Initialize Nango client lazily
|
|
264626
|
-
*/
|
|
264627
|
-
async getNangoClient() {
|
|
264628
|
-
if (this.nangoClient) {
|
|
264629
|
-
return this.nangoClient;
|
|
264630
|
-
}
|
|
264631
|
-
const { Nango: Nango2 } = await loadNangoModule();
|
|
264632
|
-
this.nangoClient = new Nango2({
|
|
264583
|
+
this.nangoClient = new Nango({
|
|
264633
264584
|
secretKey: this.nangoConfig.secretKey,
|
|
264634
264585
|
host: this.nangoConfig.apiUrl
|
|
264635
264586
|
});
|
|
264636
|
-
return this.nangoClient;
|
|
264637
264587
|
}
|
|
264638
264588
|
getAccessToken(credentials) {
|
|
264639
264589
|
const { type } = credentials;
|
|
@@ -264721,8 +264671,7 @@ var init_nango_store = __esm({
|
|
|
264721
264671
|
*/
|
|
264722
264672
|
async fetchNangoIntegration(uniqueKey) {
|
|
264723
264673
|
try {
|
|
264724
|
-
const
|
|
264725
|
-
const response = await nangoClient.getIntegration(
|
|
264674
|
+
const response = await this.nangoClient.getIntegration(
|
|
264726
264675
|
{ uniqueKey },
|
|
264727
264676
|
{ include: ["credentials"] }
|
|
264728
264677
|
);
|
|
@@ -264764,8 +264713,7 @@ var init_nango_store = __esm({
|
|
|
264764
264713
|
try {
|
|
264765
264714
|
let integration;
|
|
264766
264715
|
try {
|
|
264767
|
-
const
|
|
264768
|
-
const response2 = await nangoClient.createIntegration({
|
|
264716
|
+
const response2 = await this.nangoClient.createIntegration({
|
|
264769
264717
|
provider,
|
|
264770
264718
|
unique_key: uniqueKey,
|
|
264771
264719
|
display_name: displayName
|
|
@@ -264831,8 +264779,7 @@ var init_nango_store = __esm({
|
|
|
264831
264779
|
providerConfigKey
|
|
264832
264780
|
}) {
|
|
264833
264781
|
try {
|
|
264834
|
-
const
|
|
264835
|
-
const nangoConnection = await nangoClient.getConnection(providerConfigKey, connectionId);
|
|
264782
|
+
const nangoConnection = await this.nangoClient.getConnection(providerConfigKey, connectionId);
|
|
264836
264783
|
const tokenAndCredentials = this.getAccessToken(nangoConnection.credentials) ?? {};
|
|
264837
264784
|
const credentialData = {
|
|
264838
264785
|
...tokenAndCredentials,
|
|
@@ -264929,8 +264876,7 @@ var init_nango_store = __esm({
|
|
|
264929
264876
|
return false;
|
|
264930
264877
|
}
|
|
264931
264878
|
const { connectionId, providerConfigKey } = parsedKey;
|
|
264932
|
-
|
|
264933
|
-
await nangoClient.deleteConnection(providerConfigKey, connectionId);
|
|
264879
|
+
await this.nangoClient.deleteConnection(providerConfigKey, connectionId);
|
|
264934
264880
|
return true;
|
|
264935
264881
|
} catch (error) {
|
|
264936
264882
|
logger18.error(
|
|
@@ -264948,12 +264894,6 @@ var init_nango_store = __esm({
|
|
|
264948
264894
|
* Check if the credential store is available and functional
|
|
264949
264895
|
*/
|
|
264950
264896
|
async checkAvailability() {
|
|
264951
|
-
if (!isNangoAvailable()) {
|
|
264952
|
-
return {
|
|
264953
|
-
available: false,
|
|
264954
|
-
reason: "Nango is not installed. Install with: npm install @nangohq/node @nangohq/types"
|
|
264955
|
-
};
|
|
264956
|
-
}
|
|
264957
264897
|
if (!this.nangoConfig.secretKey) {
|
|
264958
264898
|
return {
|
|
264959
264899
|
available: false,
|
|
@@ -264978,17 +264918,13 @@ var init_nango_store = __esm({
|
|
|
264978
264918
|
function createDefaultCredentialStores() {
|
|
264979
264919
|
const stores = [];
|
|
264980
264920
|
stores.push(new InMemoryCredentialStore("memory-default"));
|
|
264981
|
-
if (process.env.NANGO_SECRET_KEY
|
|
264982
|
-
|
|
264983
|
-
|
|
264984
|
-
|
|
264985
|
-
|
|
264986
|
-
|
|
264987
|
-
|
|
264988
|
-
);
|
|
264989
|
-
} catch (error) {
|
|
264990
|
-
console.warn("Failed to create Nango store:", error instanceof Error ? error.message : error);
|
|
264991
|
-
}
|
|
264921
|
+
if (process.env.NANGO_SECRET_KEY) {
|
|
264922
|
+
stores.push(
|
|
264923
|
+
createNangoCredentialStore(DEFAULT_NANGO_STORE_ID, {
|
|
264924
|
+
apiUrl: process.env.NANGO_SERVER_URL || "https://api.nango.dev",
|
|
264925
|
+
secretKey: process.env.NANGO_SECRET_KEY
|
|
264926
|
+
})
|
|
264927
|
+
);
|
|
264992
264928
|
}
|
|
264993
264929
|
try {
|
|
264994
264930
|
stores.push(createKeyChainStore("keychain-default"));
|
|
@@ -265020,8 +264956,7 @@ __export(credential_stores_exports, {
|
|
|
265020
264956
|
NangoCredentialStore: () => NangoCredentialStore,
|
|
265021
264957
|
createDefaultCredentialStores: () => createDefaultCredentialStores,
|
|
265022
264958
|
createKeyChainStore: () => createKeyChainStore,
|
|
265023
|
-
createNangoCredentialStore: () => createNangoCredentialStore
|
|
265024
|
-
isNangoAvailable: () => isNangoAvailable
|
|
264959
|
+
createNangoCredentialStore: () => createNangoCredentialStore
|
|
265025
264960
|
});
|
|
265026
264961
|
var init_credential_stores = __esm({
|
|
265027
264962
|
"../packages/agents-core/src/credential-stores/index.ts"() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inkeep/agents-cli",
|
|
3
|
-
"version": "0.0.0-dev-
|
|
3
|
+
"version": "0.0.0-dev-20251217003520",
|
|
4
4
|
"description": "Inkeep CLI tool",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
"cli-table3": "^0.6.3",
|
|
38
38
|
"commander": "^14.0.0",
|
|
39
39
|
"degit": "^2.8.4",
|
|
40
|
+
"destr": "^2.0.3",
|
|
40
41
|
"dotenv": "^17.2.1",
|
|
41
42
|
"drizzle-orm": "^0.44.5",
|
|
42
43
|
"find-up": "^7.0.0",
|
|
@@ -48,12 +49,13 @@
|
|
|
48
49
|
"pg": "^8.16.3",
|
|
49
50
|
"pino": "^9.11.0",
|
|
50
51
|
"recast": "^0.23.0",
|
|
52
|
+
"traverse": "^0.6.10",
|
|
51
53
|
"ts-morph": "^26.0.0",
|
|
52
54
|
"tsx": "^4.20.5",
|
|
53
55
|
"open": "^10.2.0",
|
|
54
56
|
"yaml": "^2.7.0",
|
|
55
|
-
"@inkeep/agents-core": "^0.0.0-dev-
|
|
56
|
-
"@inkeep/agents-sdk": "^0.0.0-dev-
|
|
57
|
+
"@inkeep/agents-core": "^0.0.0-dev-20251217003520",
|
|
58
|
+
"@inkeep/agents-sdk": "^0.0.0-dev-20251217003520"
|
|
57
59
|
},
|
|
58
60
|
"devDependencies": {
|
|
59
61
|
"@types/degit": "^2.8.6",
|
|
@@ -66,7 +68,7 @@
|
|
|
66
68
|
"vitest": "^3.2.4"
|
|
67
69
|
},
|
|
68
70
|
"peerDependencies": {
|
|
69
|
-
"@inkeep/agents-manage-ui": "0.0.0-dev-
|
|
71
|
+
"@inkeep/agents-manage-ui": "0.0.0-dev-20251217003520",
|
|
70
72
|
"zod": "^4.1.11"
|
|
71
73
|
},
|
|
72
74
|
"publishConfig": {
|