@inkeep/agents-cli 0.63.2 → 0.64.1
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 +2 -73
- package/dist/index.js.map +1 -1
- package/dist/{agents-cli/package.js → package.js} +1 -1
- package/dist/package.js.map +1 -0
- package/dist/program.js +81 -0
- package/dist/program.js.map +1 -0
- package/dist/utils/version-check.js +1 -1
- package/package.json +6 -5
- package/dist/agents-cli/package.js.map +0 -1
- package/dist/commands/pull-v4/introspect/test-helpers.js +0 -146
- package/dist/commands/pull-v4/introspect/test-helpers.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/array.js +0 -19
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/array.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/base.js +0 -181
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/base.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/character.js +0 -9
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/character.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/css.js +0 -13
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/css.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/json.js +0 -61
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/json.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/line.js +0 -38
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/line.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/sentence.js +0 -32
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/sentence.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/word.js +0 -119
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/word.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/index.js +0 -11
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/patch/create.js +0 -142
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/patch/create.js.map +0 -1
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/util/string.js +0 -64
- package/dist/node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/util/string.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,83 +1,12 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import "./env.js";
|
|
3
3
|
import "./instrumentation.js";
|
|
4
|
-
import {
|
|
5
|
-
import { configGetCommand, configListCommand, configSetCommand } from "./commands/config.js";
|
|
6
|
-
import { devCommand } from "./commands/dev.js";
|
|
7
|
-
import { loginCommand } from "./commands/login.js";
|
|
8
|
-
import { initCommand } from "./commands/init.js";
|
|
9
|
-
import { listAgentsCommand } from "./commands/list-agents.js";
|
|
10
|
-
import { logoutCommand } from "./commands/logout.js";
|
|
11
|
-
import { profileAddCommand, profileCurrentCommand, profileListCommand, profileRemoveCommand, profileUseCommand } from "./commands/profile.js";
|
|
12
|
-
import { PACKAGE_VERSION } from "./utils/version-check.js";
|
|
13
|
-
import { pullV4Command } from "./commands/pull-v4/introspect/index.js";
|
|
14
|
-
import { pushCommand } from "./commands/push.js";
|
|
15
|
-
import { statusCommand } from "./commands/status.js";
|
|
16
|
-
import { updateCommand } from "./commands/update.js";
|
|
17
|
-
import { whoamiCommand } from "./commands/whoami.js";
|
|
4
|
+
import { createProgram } from "./program.js";
|
|
18
5
|
import { getLogger } from "@inkeep/agents-core";
|
|
19
|
-
import { Command, Option } from "commander";
|
|
20
6
|
|
|
21
7
|
//#region src/index.ts
|
|
22
8
|
getLogger("config").updateOptions({ level: "silent" });
|
|
23
|
-
|
|
24
|
-
program.name("inkeep").description("CLI tool for Inkeep Agent Framework").version(PACKAGE_VERSION);
|
|
25
|
-
program.command("add [template]").description("Add a new template to the project").option("--project <template>", "Project template to add").option("--mcp <template>", "MCP template to add").option("--ui [component-id]", "Add UI component(s) to apps/agents-ui/src/ui (omit id to add all)").option("--list", "List available UI components (use with --ui)").option("--target-path <path>", "Target path to add the template to").option("--local-prefix <path_prefix>", "Use local templates from the given path prefix").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for authentication").option("--quiet", "Suppress profile/config logging").action(async (template, options) => {
|
|
26
|
-
await addCommand({
|
|
27
|
-
template,
|
|
28
|
-
...options
|
|
29
|
-
});
|
|
30
|
-
});
|
|
31
|
-
program.command("init [path]").description("Initialize a new Inkeep project (runs cloud onboarding wizard by default)").option("--local", "Use local/self-hosted mode instead of cloud onboarding").option("--no-interactive", "Skip interactive prompts").option("--config <path>", "Path to use as template for new configuration").action(async (path, options) => {
|
|
32
|
-
await initCommand({
|
|
33
|
-
path,
|
|
34
|
-
...options
|
|
35
|
-
});
|
|
36
|
-
});
|
|
37
|
-
const configCommand = program.command("config").description("Manage Inkeep configuration");
|
|
38
|
-
configCommand.command("get [key]").description("Get configuration value(s)").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (key, options) => {
|
|
39
|
-
await configGetCommand(key, { config: options.config || options.configFilePath });
|
|
40
|
-
});
|
|
41
|
-
configCommand.command("set <key> <value>").description("Set a configuration value").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (key, value, options) => {
|
|
42
|
-
await configSetCommand(key, value, { config: options.config || options.configFilePath });
|
|
43
|
-
});
|
|
44
|
-
configCommand.command("list").description("List all configuration values").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (options) => {
|
|
45
|
-
await configListCommand({ config: options.config || options.configFilePath });
|
|
46
|
-
});
|
|
47
|
-
program.command("push").description("Push a project configuration to the backend").option("--project <project-id>", "Project ID or path to project directory").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for remote URLs and authentication").option("--tenant-id <id>", "Override tenant ID").option("--agents-api-url <url>", "Override agents API URL").option("--env <environment>", "Environment to use for credential resolution (e.g., development, production)").option("--json", "Generate project data JSON file instead of pushing to backend").option("--all", "Push all projects found in current directory tree").option("--tag <tag>", "Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)").option("--quiet", "Suppress profile/config logging").option("--force", "Skip conflict detection and push directly to remote").action(pushCommand);
|
|
48
|
-
program.command("pull").description("Pull project configuration with clean, efficient code generation").option("--project <project-id>", "Project ID to pull (or path to project directory). If in project directory, validates against local project ID.").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for remote URLs and authentication").option("--env <environment>", "Environment file to generate (development, staging, production). Defaults to development").option("--json", "Output project data as JSON instead of generating files").option("--debug", "Enable debug logging").option("--verbose", "Enable verbose logging").option("--force", "Force regeneration even if no changes detected").option("--all", "Pull all projects for current tenant").option("--tag <tag>", "Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)").option("--quiet", "Suppress profile/config logging").addOption(new Option("--conflict-strategy <strategy>", "Auto-resolve merge conflicts: ours (keep local) or theirs (accept remote). Skips interactive prompts.").choices(["ours", "theirs"])).action(async (options) => {
|
|
49
|
-
await pullV4Command(options);
|
|
50
|
-
});
|
|
51
|
-
program.command("list-agent").description("List all available agents for a specific project").requiredOption("--project <project-id>", "Project ID to list agent for").option("--tenant-id <tenant-id>", "Tenant ID").option("--agents-api-url <url>", "Agents API URL").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (options) => {
|
|
52
|
-
const config = options.config || options.configFilePath;
|
|
53
|
-
await listAgentsCommand({
|
|
54
|
-
...options,
|
|
55
|
-
config
|
|
56
|
-
});
|
|
57
|
-
});
|
|
58
|
-
program.command("dev").description("Start the Inkeep dashboard server").option("--port <port>", "Port to run the server on", "3000").option("--host <host>", "Host to bind the server to", "localhost").option("--build", "Build the Dashboard UI for production", false).option("--export", "Export the Next.js project source files", false).option("--output-dir <dir>", "Output directory for build files", "./inkeep-dev").option("--path", "Output the path to the Dashboard UI", false).option("--open-browser", "Open the browser", false).action(async (options) => {
|
|
59
|
-
await devCommand({
|
|
60
|
-
port: parseInt(options.port, 10),
|
|
61
|
-
host: options.host,
|
|
62
|
-
build: options.build,
|
|
63
|
-
outputDir: options.outputDir,
|
|
64
|
-
path: options.path,
|
|
65
|
-
export: options.export,
|
|
66
|
-
openBrowser: options.openBrowser
|
|
67
|
-
});
|
|
68
|
-
});
|
|
69
|
-
program.command("update").description("Update @inkeep/agents-cli to the latest version").option("--check", "Check for updates without installing").option("--force", "Force update even if already on latest version").action(updateCommand);
|
|
70
|
-
program.command("login").description("Authenticate with Inkeep Cloud").option("--profile <name>", "Profile to authenticate (defaults to active profile)").action(loginCommand);
|
|
71
|
-
program.command("logout").description("Log out of Inkeep Cloud").option("--profile <name>", "Profile to log out (defaults to active profile)").action(logoutCommand);
|
|
72
|
-
program.command("status").description("Show current profile, authentication state, and remote URLs").option("--profile <name>", "Profile to show status for (defaults to active profile)").action(statusCommand);
|
|
73
|
-
program.command("whoami").description("Display current authentication status (alias for status)").action(whoamiCommand);
|
|
74
|
-
const profileCommand = program.command("profile").description("Manage CLI profiles for connecting to different remotes");
|
|
75
|
-
profileCommand.command("list").description("List all profiles").action(profileListCommand);
|
|
76
|
-
profileCommand.command("add [name]").description("Add a new profile").action(profileAddCommand);
|
|
77
|
-
profileCommand.command("use <name>").description("Set the active profile").action(profileUseCommand);
|
|
78
|
-
profileCommand.command("current").description("Display the active profile details").action(profileCurrentCommand);
|
|
79
|
-
profileCommand.command("remove <name>").description("Remove a profile").action(profileRemoveCommand);
|
|
80
|
-
program.parse();
|
|
9
|
+
createProgram().parse();
|
|
81
10
|
|
|
82
11
|
//#endregion
|
|
83
12
|
export { };
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["#!/usr/bin/env node\nimport './env'; // Load environment files first (needed by instrumentation)\nimport './instrumentation'; // Initialize Langfuse tracing second\n\n// Silence config loading logs for cleaner CLI output\nimport { getLogger } from '@inkeep/agents-core';\n\nconst configLogger = getLogger('config');\nconfigLogger.updateOptions({ level: 'silent' });\n\nimport { Command, Option } from 'commander';\nimport { addCommand } from './commands/add';\nimport { configGetCommand, configListCommand, configSetCommand } from './commands/config';\nimport { devCommand } from './commands/dev';\nimport { initCommand } from './commands/init';\nimport { listAgentsCommand } from './commands/list-agents';\nimport { loginCommand } from './commands/login';\nimport { logoutCommand } from './commands/logout';\nimport {\n profileAddCommand,\n profileCurrentCommand,\n profileListCommand,\n profileRemoveCommand,\n profileUseCommand,\n} from './commands/profile';\nimport { pullV4Command } from './commands/pull-v4/introspect';\nimport { pushCommand } from './commands/push';\nimport { statusCommand } from './commands/status';\nimport { updateCommand } from './commands/update';\nimport { whoamiCommand } from './commands/whoami';\nimport { PACKAGE_VERSION } from './utils/version-check';\n\nconst program = new Command();\n\nprogram.name('inkeep').description('CLI tool for Inkeep Agent Framework').version(PACKAGE_VERSION);\n\nprogram\n .command('add [template]')\n .description('Add a new template to the project')\n .option('--project <template>', 'Project template to add')\n .option('--mcp <template>', 'MCP template to add')\n .option(\n '--ui [component-id]',\n 'Add UI component(s) to apps/agents-ui/src/ui (omit id to add all)'\n )\n .option('--list', 'List available UI components (use with --ui)')\n .option('--target-path <path>', 'Target path to add the template to')\n .option('--local-prefix <path_prefix>', 'Use local templates from the given path prefix')\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for authentication')\n .option('--quiet', 'Suppress profile/config logging')\n .action(async (template, options) => {\n await addCommand({ template, ...options });\n });\n\nprogram\n .command('init [path]')\n .description('Initialize a new Inkeep project (runs cloud onboarding wizard by default)')\n .option('--local', 'Use local/self-hosted mode instead of cloud onboarding')\n .option('--no-interactive', 'Skip interactive prompts')\n .option('--config <path>', 'Path to use as template for new configuration')\n .action(async (path, options) => {\n await initCommand({ path, ...options });\n });\n\nconst configCommand = program.command('config').description('Manage Inkeep configuration');\n\nconfigCommand\n .command('get [key]')\n .description('Get configuration value(s)')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (key, options) => {\n const config = options.config || options.configFilePath;\n await configGetCommand(key, { config });\n });\n\nconfigCommand\n .command('set <key> <value>')\n .description('Set a configuration value')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (key, value, options) => {\n const config = options.config || options.configFilePath;\n await configSetCommand(key, value, { config });\n });\n\nconfigCommand\n .command('list')\n .description('List all configuration values')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (options) => {\n const config = options.config || options.configFilePath;\n await configListCommand({ config });\n });\n\nprogram\n .command('push')\n .description('Push a project configuration to the backend')\n .option('--project <project-id>', 'Project ID or path to project directory')\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for remote URLs and authentication')\n .option('--tenant-id <id>', 'Override tenant ID')\n .option('--agents-api-url <url>', 'Override agents API URL')\n .option(\n '--env <environment>',\n 'Environment to use for credential resolution (e.g., development, production)'\n )\n .option('--json', 'Generate project data JSON file instead of pushing to backend')\n .option('--all', 'Push all projects found in current directory tree')\n .option(\n '--tag <tag>',\n 'Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)'\n )\n .option('--quiet', 'Suppress profile/config logging')\n .option('--force', 'Skip conflict detection and push directly to remote')\n .action(pushCommand);\n\nprogram\n .command('pull')\n .description('Pull project configuration with clean, efficient code generation')\n .option(\n '--project <project-id>',\n 'Project ID to pull (or path to project directory). If in project directory, validates against local project ID.'\n )\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for remote URLs and authentication')\n .option(\n '--env <environment>',\n 'Environment file to generate (development, staging, production). Defaults to development'\n )\n .option('--json', 'Output project data as JSON instead of generating files')\n .option('--debug', 'Enable debug logging')\n .option('--verbose', 'Enable verbose logging')\n .option('--force', 'Force regeneration even if no changes detected')\n .option('--all', 'Pull all projects for current tenant')\n .option(\n '--tag <tag>',\n 'Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)'\n )\n .option('--quiet', 'Suppress profile/config logging')\n .addOption(\n new Option(\n '--conflict-strategy <strategy>',\n 'Auto-resolve merge conflicts: ours (keep local) or theirs (accept remote). Skips interactive prompts.'\n ).choices(['ours', 'theirs'])\n )\n .action(async (options) => {\n await pullV4Command(options);\n });\n\nprogram\n .command('list-agent')\n .description('List all available agents for a specific project')\n .requiredOption('--project <project-id>', 'Project ID to list agent for')\n .option('--tenant-id <tenant-id>', 'Tenant ID')\n .option('--agents-api-url <url>', 'Agents API URL')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (options) => {\n const config = options.config || options.configFilePath;\n await listAgentsCommand({ ...options, config });\n });\n\nprogram\n .command('dev')\n .description('Start the Inkeep dashboard server')\n .option('--port <port>', 'Port to run the server on', '3000')\n .option('--host <host>', 'Host to bind the server to', 'localhost')\n .option('--build', 'Build the Dashboard UI for production', false)\n .option('--export', 'Export the Next.js project source files', false)\n .option('--output-dir <dir>', 'Output directory for build files', './inkeep-dev')\n .option('--path', 'Output the path to the Dashboard UI', false)\n .option('--open-browser', 'Open the browser', false)\n .action(async (options) => {\n await devCommand({\n port: parseInt(options.port, 10),\n host: options.host,\n build: options.build,\n outputDir: options.outputDir,\n path: options.path,\n export: options.export,\n openBrowser: options.openBrowser,\n });\n });\n\nprogram\n .command('update')\n .description('Update @inkeep/agents-cli to the latest version')\n .option('--check', 'Check for updates without installing')\n .option('--force', 'Force update even if already on latest version')\n .action(updateCommand);\n\n// Authentication commands\nprogram\n .command('login')\n .description('Authenticate with Inkeep Cloud')\n .option('--profile <name>', 'Profile to authenticate (defaults to active profile)')\n .action(loginCommand);\n\nprogram\n .command('logout')\n .description('Log out of Inkeep Cloud')\n .option('--profile <name>', 'Profile to log out (defaults to active profile)')\n .action(logoutCommand);\n\nprogram\n .command('status')\n .description('Show current profile, authentication state, and remote URLs')\n .option('--profile <name>', 'Profile to show status for (defaults to active profile)')\n .action(statusCommand);\n\nprogram\n .command('whoami')\n .description('Display current authentication status (alias for status)')\n .action(whoamiCommand);\n\n// Profile management commands\nconst profileCommand = program\n .command('profile')\n .description('Manage CLI profiles for connecting to different remotes');\n\nprofileCommand.command('list').description('List all profiles').action(profileListCommand);\n\nprofileCommand.command('add [name]').description('Add a new profile').action(profileAddCommand);\n\nprofileCommand\n .command('use <name>')\n .description('Set the active profile')\n .action(profileUseCommand);\n\nprofileCommand\n .command('current')\n .description('Display the active profile details')\n .action(profileCurrentCommand);\n\nprofileCommand\n .command('remove <name>')\n .description('Remove a profile')\n .action(profileRemoveCommand);\n\nprogram.parse();\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAOqB,UAAU,SAAS,CAC3B,cAAc,EAAE,OAAO,UAAU,CAAC;AAwB/C,MAAM,UAAU,IAAI,SAAS;AAE7B,QAAQ,KAAK,SAAS,CAAC,YAAY,sCAAsC,CAAC,QAAQ,gBAAgB;AAElG,QACG,QAAQ,iBAAiB,CACzB,YAAY,oCAAoC,CAChD,OAAO,wBAAwB,0BAA0B,CACzD,OAAO,oBAAoB,sBAAsB,CACjD,OACC,uBACA,oEACD,CACA,OAAO,UAAU,+CAA+C,CAChE,OAAO,wBAAwB,qCAAqC,CACpE,OAAO,gCAAgC,iDAAiD,CACxF,OAAO,mBAAmB,6BAA6B,CACvD,OAAO,oBAAoB,oCAAoC,CAC/D,OAAO,WAAW,kCAAkC,CACpD,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ACf,MAAM,SAAS,QAAQ,MAAM,GAAG;EAChC,MAAM,QAAQ;EACd,OAAO,QAAQ;EACf,WAAW,QAAQ;EACnB,MAAM,QAAQ;EACd,QAAQ,QAAQ;EAChB,aAAa,QAAQ;EACtB,CAAC;EACF;AAEJ,QACG,QAAQ,SAAS,CACjB,YAAY,kDAAkD,CAC9D,OAAO,WAAW,uCAAuC,CACzD,OAAO,WAAW,iDAAiD,CACnE,OAAO,cAAc;AAGxB,QACG,QAAQ,QAAQ,CAChB,YAAY,iCAAiC,CAC7C,OAAO,oBAAoB,uDAAuD,CAClF,OAAO,aAAa;AAEvB,QACG,QAAQ,SAAS,CACjB,YAAY,0BAA0B,CACtC,OAAO,oBAAoB,kDAAkD,CAC7E,OAAO,cAAc;AAExB,QACG,QAAQ,SAAS,CACjB,YAAY,8DAA8D,CAC1E,OAAO,oBAAoB,0DAA0D,CACrF,OAAO,cAAc;AAExB,QACG,QAAQ,SAAS,CACjB,YAAY,2DAA2D,CACvE,OAAO,cAAc;AAGxB,MAAM,iBAAiB,QACpB,QAAQ,UAAU,CAClB,YAAY,0DAA0D;AAEzE,eAAe,QAAQ,OAAO,CAAC,YAAY,oBAAoB,CAAC,OAAO,mBAAmB;AAE1F,eAAe,QAAQ,aAAa,CAAC,YAAY,oBAAoB,CAAC,OAAO,kBAAkB;AAE/F,eACG,QAAQ,aAAa,CACrB,YAAY,yBAAyB,CACrC,OAAO,kBAAkB;AAE5B,eACG,QAAQ,UAAU,CAClB,YAAY,qCAAqC,CACjD,OAAO,sBAAsB;AAEhC,eACG,QAAQ,gBAAgB,CACxB,YAAY,mBAAmB,CAC/B,OAAO,qBAAqB;AAE/B,QAAQ,OAAO"}
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["#!/usr/bin/env node\nimport './env'; // Load environment files first (needed by instrumentation)\nimport './instrumentation'; // Initialize Langfuse tracing second\n\n// Silence config loading logs for cleaner CLI output\nimport { getLogger } from '@inkeep/agents-core';\n\nconst configLogger = getLogger('config');\nconfigLogger.updateOptions({ level: 'silent' });\n\nimport { createProgram } from './program';\n\nconst program = createProgram();\nprogram.parse();\n"],"mappings":";;;;;;;AAOqB,UAAU,SAAS,CAC3B,cAAc,EAAE,OAAO,UAAU,CAAC;AAI/B,eAAe,CACvB,OAAO"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"package.js","names":[],"sources":["../package.json"],"sourcesContent":[""],"mappings":""}
|
package/dist/program.js
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { addCommand } from "./commands/add.js";
|
|
2
|
+
import { configGetCommand, configListCommand, configSetCommand } from "./commands/config.js";
|
|
3
|
+
import { devCommand } from "./commands/dev.js";
|
|
4
|
+
import { loginCommand } from "./commands/login.js";
|
|
5
|
+
import { initCommand } from "./commands/init.js";
|
|
6
|
+
import { listAgentsCommand } from "./commands/list-agents.js";
|
|
7
|
+
import { logoutCommand } from "./commands/logout.js";
|
|
8
|
+
import { profileAddCommand, profileCurrentCommand, profileListCommand, profileRemoveCommand, profileUseCommand } from "./commands/profile.js";
|
|
9
|
+
import { PACKAGE_VERSION } from "./utils/version-check.js";
|
|
10
|
+
import { pullV4Command } from "./commands/pull-v4/introspect/index.js";
|
|
11
|
+
import { pushCommand } from "./commands/push.js";
|
|
12
|
+
import { statusCommand } from "./commands/status.js";
|
|
13
|
+
import { updateCommand } from "./commands/update.js";
|
|
14
|
+
import { whoamiCommand } from "./commands/whoami.js";
|
|
15
|
+
import { Command, Option } from "commander";
|
|
16
|
+
|
|
17
|
+
//#region src/program.ts
|
|
18
|
+
function createProgram() {
|
|
19
|
+
const program = new Command();
|
|
20
|
+
program.name("inkeep").description("CLI tool for Inkeep Agent Framework").version(PACKAGE_VERSION);
|
|
21
|
+
program.command("add [template]").description("Add a new template to the project").option("--project <template>", "Project template to add").option("--mcp <template>", "MCP template to add").option("--ui [component-id]", "Add UI component(s) to apps/agents-ui/src/ui (omit id to add all)").option("--list", "List available UI components (use with --ui)").option("--target-path <path>", "Target path to add the template to").option("--local-prefix <path_prefix>", "Use local templates from the given path prefix").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for authentication").option("--quiet", "Suppress profile/config logging").action(async (template, options) => {
|
|
22
|
+
await addCommand({
|
|
23
|
+
template,
|
|
24
|
+
...options
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
program.command("init [path]").description("Initialize a new Inkeep project (runs cloud onboarding wizard by default)").option("--local", "Use local/self-hosted mode instead of cloud onboarding").option("--no-interactive", "Skip interactive prompts").option("--config <path>", "Path to use as template for new configuration").action(async (path, options) => {
|
|
28
|
+
await initCommand({
|
|
29
|
+
path,
|
|
30
|
+
...options
|
|
31
|
+
});
|
|
32
|
+
});
|
|
33
|
+
const configCommand = program.command("config").description("Manage Inkeep configuration");
|
|
34
|
+
configCommand.command("get [key]").description("Get configuration value(s)").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (key, options) => {
|
|
35
|
+
await configGetCommand(key, { config: options.config || options.configFilePath });
|
|
36
|
+
});
|
|
37
|
+
configCommand.command("set <key> <value>").description("Set a configuration value").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (key, value, options) => {
|
|
38
|
+
await configSetCommand(key, value, { config: options.config || options.configFilePath });
|
|
39
|
+
});
|
|
40
|
+
configCommand.command("list").description("List all configuration values").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (options) => {
|
|
41
|
+
await configListCommand({ config: options.config || options.configFilePath });
|
|
42
|
+
});
|
|
43
|
+
program.command("push").description("Push a project configuration to the backend").option("--project <project-id>", "Project ID or path to project directory").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for remote URLs and authentication").option("--tenant-id <id>", "Override tenant ID").option("--agents-api-url <url>", "Override agents API URL").option("--env <environment>", "Environment to use for credential resolution (e.g., development, production)").option("--json", "Generate project data JSON file instead of pushing to backend").option("--all", "Push all projects found in current directory tree").option("--tag <tag>", "Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)").option("--quiet", "Suppress profile/config logging").option("--force", "Skip conflict detection and push directly to remote").action(pushCommand);
|
|
44
|
+
program.command("pull").description("Pull project configuration with clean, efficient code generation").option("--project <project-id>", "Project ID to pull (or path to project directory). If in project directory, validates against local project ID.").option("--config <path>", "Path to configuration file").option("--profile <name>", "Profile to use for remote URLs and authentication").option("--env <environment>", "Environment file to generate (development, staging, production). Defaults to development").option("--json", "Output project data as JSON instead of generating files").option("--debug", "Enable debug logging").option("--verbose", "Enable verbose logging").option("--force", "Force regeneration even if no changes detected").option("--all", "Pull all projects for current tenant").option("--tag <tag>", "Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)").option("--quiet", "Suppress profile/config logging").addOption(new Option("--conflict-strategy <strategy>", "Auto-resolve merge conflicts: ours (keep local) or theirs (accept remote). Skips interactive prompts.").choices(["ours", "theirs"])).action(async (options) => {
|
|
45
|
+
await pullV4Command(options);
|
|
46
|
+
});
|
|
47
|
+
program.command("list-agent").description("List all available agents for a specific project").requiredOption("--project <project-id>", "Project ID to list agent for").option("--tenant-id <tenant-id>", "Tenant ID").option("--agents-api-url <url>", "Agents API URL").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (options) => {
|
|
48
|
+
const config = options.config || options.configFilePath;
|
|
49
|
+
await listAgentsCommand({
|
|
50
|
+
...options,
|
|
51
|
+
config
|
|
52
|
+
});
|
|
53
|
+
});
|
|
54
|
+
program.command("dev").description("Start the Inkeep dashboard server").option("--port <port>", "Port to run the server on", "3000").option("--host <host>", "Host to bind the server to", "localhost").option("--build", "Build the Dashboard UI for production", false).option("--export", "Export the Next.js project source files", false).option("--output-dir <dir>", "Output directory for build files", "./inkeep-dev").option("--path", "Output the path to the Dashboard UI", false).option("--open-browser", "Open the browser", false).action(async (options) => {
|
|
55
|
+
await devCommand({
|
|
56
|
+
port: parseInt(options.port, 10),
|
|
57
|
+
host: options.host,
|
|
58
|
+
build: options.build,
|
|
59
|
+
outputDir: options.outputDir,
|
|
60
|
+
path: options.path,
|
|
61
|
+
export: options.export,
|
|
62
|
+
openBrowser: options.openBrowser
|
|
63
|
+
});
|
|
64
|
+
});
|
|
65
|
+
program.command("update").description("Update @inkeep/agents-cli to the latest version").option("--check", "Check for updates without installing").option("--force", "Force update even if already on latest version").action(updateCommand);
|
|
66
|
+
program.command("login").description("Authenticate with Inkeep Cloud").option("--profile <name>", "Profile to authenticate (defaults to active profile)").action(loginCommand);
|
|
67
|
+
program.command("logout").description("Log out of Inkeep Cloud").option("--profile <name>", "Profile to log out (defaults to active profile)").action(logoutCommand);
|
|
68
|
+
program.command("status").description("Show current profile, authentication state, and remote URLs").option("--profile <name>", "Profile to show status for (defaults to active profile)").action(statusCommand);
|
|
69
|
+
program.command("whoami").description("Display current authentication status (alias for status)").action(whoamiCommand);
|
|
70
|
+
const profileCommand = program.command("profile").description("Manage CLI profiles for connecting to different remotes");
|
|
71
|
+
profileCommand.command("list").description("List all profiles").action(profileListCommand);
|
|
72
|
+
profileCommand.command("add [name]").description("Add a new profile").action(profileAddCommand);
|
|
73
|
+
profileCommand.command("use <name>").description("Set the active profile").action(profileUseCommand);
|
|
74
|
+
profileCommand.command("current").description("Display the active profile details").action(profileCurrentCommand);
|
|
75
|
+
profileCommand.command("remove <name>").description("Remove a profile").action(profileRemoveCommand);
|
|
76
|
+
return program;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
//#endregion
|
|
80
|
+
export { createProgram };
|
|
81
|
+
//# sourceMappingURL=program.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"program.js","names":[],"sources":["../src/program.ts"],"sourcesContent":["import { Command, Option } from 'commander';\nimport { addCommand } from './commands/add';\nimport { configGetCommand, configListCommand, configSetCommand } from './commands/config';\nimport { devCommand } from './commands/dev';\nimport { initCommand } from './commands/init';\nimport { listAgentsCommand } from './commands/list-agents';\nimport { loginCommand } from './commands/login';\nimport { logoutCommand } from './commands/logout';\nimport {\n profileAddCommand,\n profileCurrentCommand,\n profileListCommand,\n profileRemoveCommand,\n profileUseCommand,\n} from './commands/profile';\nimport { pullV4Command } from './commands/pull-v4/introspect';\nimport { pushCommand } from './commands/push';\nimport { statusCommand } from './commands/status';\nimport { updateCommand } from './commands/update';\nimport { whoamiCommand } from './commands/whoami';\nimport { PACKAGE_VERSION } from './utils/version-check';\n\nexport function createProgram(): Command {\n const program = new Command();\n\n program\n .name('inkeep')\n .description('CLI tool for Inkeep Agent Framework')\n .version(PACKAGE_VERSION);\n\n program\n .command('add [template]')\n .description('Add a new template to the project')\n .option('--project <template>', 'Project template to add')\n .option('--mcp <template>', 'MCP template to add')\n .option(\n '--ui [component-id]',\n 'Add UI component(s) to apps/agents-ui/src/ui (omit id to add all)'\n )\n .option('--list', 'List available UI components (use with --ui)')\n .option('--target-path <path>', 'Target path to add the template to')\n .option('--local-prefix <path_prefix>', 'Use local templates from the given path prefix')\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for authentication')\n .option('--quiet', 'Suppress profile/config logging')\n .action(async (template, options) => {\n await addCommand({ template, ...options });\n });\n\n program\n .command('init [path]')\n .description('Initialize a new Inkeep project (runs cloud onboarding wizard by default)')\n .option('--local', 'Use local/self-hosted mode instead of cloud onboarding')\n .option('--no-interactive', 'Skip interactive prompts')\n .option('--config <path>', 'Path to use as template for new configuration')\n .action(async (path, options) => {\n await initCommand({ path, ...options });\n });\n\n const configCommand = program.command('config').description('Manage Inkeep configuration');\n\n configCommand\n .command('get [key]')\n .description('Get configuration value(s)')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (key, options) => {\n const config = options.config || options.configFilePath;\n await configGetCommand(key, { config });\n });\n\n configCommand\n .command('set <key> <value>')\n .description('Set a configuration value')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (key, value, options) => {\n const config = options.config || options.configFilePath;\n await configSetCommand(key, value, { config });\n });\n\n configCommand\n .command('list')\n .description('List all configuration values')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (options) => {\n const config = options.config || options.configFilePath;\n await configListCommand({ config });\n });\n\n program\n .command('push')\n .description('Push a project configuration to the backend')\n .option('--project <project-id>', 'Project ID or path to project directory')\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for remote URLs and authentication')\n .option('--tenant-id <id>', 'Override tenant ID')\n .option('--agents-api-url <url>', 'Override agents API URL')\n .option(\n '--env <environment>',\n 'Environment to use for credential resolution (e.g., development, production)'\n )\n .option('--json', 'Generate project data JSON file instead of pushing to backend')\n .option('--all', 'Push all projects found in current directory tree')\n .option(\n '--tag <tag>',\n 'Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)'\n )\n .option('--quiet', 'Suppress profile/config logging')\n .option('--force', 'Skip conflict detection and push directly to remote')\n .action(pushCommand);\n\n program\n .command('pull')\n .description('Pull project configuration with clean, efficient code generation')\n .option(\n '--project <project-id>',\n 'Project ID to pull (or path to project directory). If in project directory, validates against local project ID.'\n )\n .option('--config <path>', 'Path to configuration file')\n .option('--profile <name>', 'Profile to use for remote URLs and authentication')\n .option(\n '--env <environment>',\n 'Environment file to generate (development, staging, production). Defaults to development'\n )\n .option('--json', 'Output project data as JSON instead of generating files')\n .option('--debug', 'Enable debug logging')\n .option('--verbose', 'Enable verbose logging')\n .option('--force', 'Force regeneration even if no changes detected')\n .option('--all', 'Pull all projects for current tenant')\n .option(\n '--tag <tag>',\n 'Use tagged config file (e.g., --tag prod loads prod.__inkeep.config.ts__)'\n )\n .option('--quiet', 'Suppress profile/config logging')\n .addOption(\n new Option(\n '--conflict-strategy <strategy>',\n 'Auto-resolve merge conflicts: ours (keep local) or theirs (accept remote). Skips interactive prompts.'\n ).choices(['ours', 'theirs'])\n )\n .action(async (options) => {\n await pullV4Command(options);\n });\n\n program\n .command('list-agent')\n .description('List all available agents for a specific project')\n .requiredOption('--project <project-id>', 'Project ID to list agent for')\n .option('--tenant-id <tenant-id>', 'Tenant ID')\n .option('--agents-api-url <url>', 'Agents API URL')\n .option('--config <path>', 'Path to configuration file')\n .option('--config-file-path <path>', 'Path to configuration file (deprecated, use --config)')\n .action(async (options) => {\n const config = options.config || options.configFilePath;\n await listAgentsCommand({ ...options, config });\n });\n\n program\n .command('dev')\n .description('Start the Inkeep dashboard server')\n .option('--port <port>', 'Port to run the server on', '3000')\n .option('--host <host>', 'Host to bind the server to', 'localhost')\n .option('--build', 'Build the Dashboard UI for production', false)\n .option('--export', 'Export the Next.js project source files', false)\n .option('--output-dir <dir>', 'Output directory for build files', './inkeep-dev')\n .option('--path', 'Output the path to the Dashboard UI', false)\n .option('--open-browser', 'Open the browser', false)\n .action(async (options) => {\n await devCommand({\n port: parseInt(options.port, 10),\n host: options.host,\n build: options.build,\n outputDir: options.outputDir,\n path: options.path,\n export: options.export,\n openBrowser: options.openBrowser,\n });\n });\n\n program\n .command('update')\n .description('Update @inkeep/agents-cli to the latest version')\n .option('--check', 'Check for updates without installing')\n .option('--force', 'Force update even if already on latest version')\n .action(updateCommand);\n\n program\n .command('login')\n .description('Authenticate with Inkeep Cloud')\n .option('--profile <name>', 'Profile to authenticate (defaults to active profile)')\n .action(loginCommand);\n\n program\n .command('logout')\n .description('Log out of Inkeep Cloud')\n .option('--profile <name>', 'Profile to log out (defaults to active profile)')\n .action(logoutCommand);\n\n program\n .command('status')\n .description('Show current profile, authentication state, and remote URLs')\n .option('--profile <name>', 'Profile to show status for (defaults to active profile)')\n .action(statusCommand);\n\n program\n .command('whoami')\n .description('Display current authentication status (alias for status)')\n .action(whoamiCommand);\n\n const profileCommand = program\n .command('profile')\n .description('Manage CLI profiles for connecting to different remotes');\n\n profileCommand.command('list').description('List all profiles').action(profileListCommand);\n\n profileCommand.command('add [name]').description('Add a new profile').action(profileAddCommand);\n\n profileCommand\n .command('use <name>')\n .description('Set the active profile')\n .action(profileUseCommand);\n\n profileCommand\n .command('current')\n .description('Display the active profile details')\n .action(profileCurrentCommand);\n\n profileCommand\n .command('remove <name>')\n .description('Remove a profile')\n .action(profileRemoveCommand);\n\n return program;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAsBA,SAAgB,gBAAyB;CACvC,MAAM,UAAU,IAAI,SAAS;AAE7B,SACG,KAAK,SAAS,CACd,YAAY,sCAAsC,CAClD,QAAQ,gBAAgB;AAE3B,SACG,QAAQ,iBAAiB,CACzB,YAAY,oCAAoC,CAChD,OAAO,wBAAwB,0BAA0B,CACzD,OAAO,oBAAoB,sBAAsB,CACjD,OACC,uBACA,oEACD,CACA,OAAO,UAAU,+CAA+C,CAChE,OAAO,wBAAwB,qCAAqC,CACpE,OAAO,gCAAgC,iDAAiD,CACxF,OAAO,mBAAmB,6BAA6B,CACvD,OAAO,oBAAoB,oCAAoC,CAC/D,OAAO,WAAW,kCAAkC,CACpD,OAAO,OAAO,UAAU,YAAY;AACnC,QAAM,WAAW;GAAE;GAAU,GAAG;GAAS,CAAC;GAC1C;AAEJ,SACG,QAAQ,cAAc,CACtB,YAAY,4EAA4E,CACxF,OAAO,WAAW,yDAAyD,CAC3E,OAAO,oBAAoB,2BAA2B,CACtD,OAAO,mBAAmB,gDAAgD,CAC1E,OAAO,OAAO,MAAM,YAAY;AAC/B,QAAM,YAAY;GAAE;GAAM,GAAG;GAAS,CAAC;GACvC;CAEJ,MAAM,gBAAgB,QAAQ,QAAQ,SAAS,CAAC,YAAY,8BAA8B;AAE1F,eACG,QAAQ,YAAY,CACpB,YAAY,6BAA6B,CACzC,OAAO,mBAAmB,6BAA6B,CACvD,OAAO,6BAA6B,wDAAwD,CAC5F,OAAO,OAAO,KAAK,YAAY;AAE9B,QAAM,iBAAiB,KAAK,EAAE,QADf,QAA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0DAA0D,CACrF,OAAO,cAAc;AAExB,SACG,QAAQ,SAAS,CACjB,YAAY,2DAA2D,CACvE,OAAO,cAAc;CAExB,MAAM,iBAAiB,QACpB,QAAQ,UAAU,CAClB,YAAY,0DAA0D;AAEzE,gBAAe,QAAQ,OAAO,CAAC,YAAY,oBAAoB,CAAC,OAAO,mBAAmB;AAE1F,gBAAe,QAAQ,aAAa,CAAC,YAAY,oBAAoB,CAAC,OAAO,kBAAkB;AAE/F,gBACG,QAAQ,aAAa,CACrB,YAAY,yBAAyB,CACrC,OAAO,kBAAkB;AAE5B,gBACG,QAAQ,UAAU,CAClB,YAAY,qCAAqC,CACjD,OAAO,sBAAsB;AAEhC,gBACG,QAAQ,gBAAgB,CACxB,YAAY,mBAAmB,CAC/B,OAAO,qBAAqB;AAE/B,QAAO"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inkeep/agents-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.64.1",
|
|
4
4
|
"description": "Inkeep CLI tool",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"tsx": "^4.20.5",
|
|
40
40
|
"yaml": "^2.7.0",
|
|
41
41
|
"zod": "^4.3.6",
|
|
42
|
-
"@inkeep/agents-core": "^0.
|
|
43
|
-
"@inkeep/agents-sdk": "^0.
|
|
42
|
+
"@inkeep/agents-core": "^0.64.1",
|
|
43
|
+
"@inkeep/agents-sdk": "^0.64.1"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@types/degit": "^2.8.6",
|
|
@@ -77,11 +77,12 @@
|
|
|
77
77
|
"build": "tsdown",
|
|
78
78
|
"cli": "node ./dist/index.js",
|
|
79
79
|
"dev": "pnpm build --watch",
|
|
80
|
-
"test": "node -e \"process.exit(process.env.CI ? 0 : 1)\" && vitest --run --config vitest.config.ci.ts || vitest --run",
|
|
80
|
+
"test": "(node -e \"process.exit(process.env.CI ? 0 : 1)\" && vitest --run --config vitest.config.ci.ts || vitest --run) && vitest --run --config vitest.integration.config.ts",
|
|
81
81
|
"test:debug": "vitest --run --reporter=verbose --no-coverage",
|
|
82
82
|
"test:watch": "vitest",
|
|
83
83
|
"test:coverage": "node -e \"process.exit(process.env.CI ? 0 : 1)\" && vitest --run --coverage --config vitest.config.ci.ts || vitest --run --coverage",
|
|
84
|
-
"test:ci": "vitest --run --config vitest.config.ci.ts",
|
|
84
|
+
"test:ci": "vitest --run --config vitest.config.ci.ts && vitest --run --config vitest.integration.config.ts",
|
|
85
|
+
"test:integration": "vitest --run --config vitest.integration.config.ts",
|
|
85
86
|
"typecheck": "tsc --noEmit --project tsconfig.typecheck.json",
|
|
86
87
|
"typecheck:watch": "tsc --noEmit --watch --project tsconfig.typecheck.json"
|
|
87
88
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"package.js","names":[],"sources":["../../package.json"],"sourcesContent":[""],"mappings":""}
|
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
import { createTwoFilesPatch } from "../../../node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/patch/create.js";
|
|
2
|
-
import "../../../node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/index.js";
|
|
3
|
-
import { join } from "node:path";
|
|
4
|
-
import fs from "node:fs";
|
|
5
|
-
import { tmpdir } from "node:os";
|
|
6
|
-
|
|
7
|
-
//#region src/commands/pull-v4/introspect/test-helpers.ts
|
|
8
|
-
const beforeCredentialContent = `import { credential } from '@inkeep/agents-sdk';
|
|
9
|
-
|
|
10
|
-
const keepMe = () => 'keep-me';
|
|
11
|
-
|
|
12
|
-
export const apiCredentials = credential({
|
|
13
|
-
id: 'api-credentials',
|
|
14
|
-
name: 'Old API Credentials',
|
|
15
|
-
type: 'bearer',
|
|
16
|
-
credentialStoreId: 'main-store'
|
|
17
|
-
});
|
|
18
|
-
`.trimStart();
|
|
19
|
-
function createTestEnvironment() {
|
|
20
|
-
const testDir = join(tmpdir(), `introspect-v4-test-${Date.now()}-${Math.random().toString(36).slice(2, 9)}`);
|
|
21
|
-
fs.mkdirSync(testDir, { recursive: true });
|
|
22
|
-
return {
|
|
23
|
-
testDir,
|
|
24
|
-
projectPaths: {
|
|
25
|
-
projectRoot: testDir,
|
|
26
|
-
agentsDir: join(testDir, "agents"),
|
|
27
|
-
toolsDir: join(testDir, "tools"),
|
|
28
|
-
dataComponentsDir: join(testDir, "data-components"),
|
|
29
|
-
artifactComponentsDir: join(testDir, "artifact-components"),
|
|
30
|
-
statusComponentsDir: join(testDir, "status-components"),
|
|
31
|
-
environmentsDir: join(testDir, "environments"),
|
|
32
|
-
credentialsDir: join(testDir, "credentials"),
|
|
33
|
-
contextConfigsDir: join(testDir, "context-configs"),
|
|
34
|
-
externalAgentsDir: join(testDir, "external-agents"),
|
|
35
|
-
skillsDir: join(testDir, "skills")
|
|
36
|
-
}
|
|
37
|
-
};
|
|
38
|
-
}
|
|
39
|
-
function cleanupTestEnvironment(testDir) {
|
|
40
|
-
fs.rmSync(testDir, {
|
|
41
|
-
recursive: true,
|
|
42
|
-
force: true
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
function getTestPath() {
|
|
46
|
-
return `../__tests__/__snapshots__/introspect/${expect.getState().currentTestName?.split(" > ").at(-1)}`;
|
|
47
|
-
}
|
|
48
|
-
function createProjectFixture() {
|
|
49
|
-
return {
|
|
50
|
-
id: "support-project",
|
|
51
|
-
name: "Support Project",
|
|
52
|
-
description: "Support project for introspect v4 tests",
|
|
53
|
-
models: { base: { model: "gpt-4o-mini" } },
|
|
54
|
-
credentialReferences: { "api-credentials": {
|
|
55
|
-
id: "api-credentials",
|
|
56
|
-
name: "API Credentials",
|
|
57
|
-
type: "memory",
|
|
58
|
-
credentialStoreId: "main-store",
|
|
59
|
-
retrievalParams: { key: "token" }
|
|
60
|
-
} },
|
|
61
|
-
dataComponents: { "customer-profile": {
|
|
62
|
-
id: "customer-profile",
|
|
63
|
-
name: "Customer Profile",
|
|
64
|
-
description: "Customer profile data component",
|
|
65
|
-
props: {
|
|
66
|
-
type: "object",
|
|
67
|
-
properties: {
|
|
68
|
-
fullName: { type: "string" },
|
|
69
|
-
avatarUrl: { type: "string" }
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
render: {
|
|
73
|
-
component: "<img src=\"{{avatarUrl}}\" alt=\"{{fullName}}\" />",
|
|
74
|
-
mockData: {
|
|
75
|
-
fullName: "Ada Lovelace",
|
|
76
|
-
avatarUrl: "https://example.com/avatar.png"
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
} },
|
|
80
|
-
artifactComponents: { "ticket-summary": {
|
|
81
|
-
id: "ticket-summary",
|
|
82
|
-
name: "Ticket Summary",
|
|
83
|
-
props: {
|
|
84
|
-
type: "object",
|
|
85
|
-
properties: { title: { type: "string" } }
|
|
86
|
-
}
|
|
87
|
-
} },
|
|
88
|
-
agents: { "support-agent": {
|
|
89
|
-
id: "support-agent",
|
|
90
|
-
name: "Support Agent",
|
|
91
|
-
defaultSubAgentId: "tier-one",
|
|
92
|
-
subAgents: { "tier-one": {
|
|
93
|
-
id: "tier-one",
|
|
94
|
-
name: "Tier One",
|
|
95
|
-
canUse: []
|
|
96
|
-
} },
|
|
97
|
-
contextConfig: {
|
|
98
|
-
id: "support-context",
|
|
99
|
-
headersSchema: {
|
|
100
|
-
type: "object",
|
|
101
|
-
properties: { user_id: { type: "string" } }
|
|
102
|
-
},
|
|
103
|
-
contextVariables: { userInfo: {
|
|
104
|
-
id: "user-info",
|
|
105
|
-
name: "User Information",
|
|
106
|
-
trigger: "initialization",
|
|
107
|
-
fetchConfig: {
|
|
108
|
-
url: "https://api.example.com/users/${headersSchema.toTemplate(\"user_id\")}",
|
|
109
|
-
method: "GET"
|
|
110
|
-
},
|
|
111
|
-
responseSchema: {
|
|
112
|
-
type: "object",
|
|
113
|
-
properties: { name: { type: "string" } }
|
|
114
|
-
},
|
|
115
|
-
defaultValue: "Unable to fetch user information"
|
|
116
|
-
} }
|
|
117
|
-
},
|
|
118
|
-
triggers: { "github-webhook": {
|
|
119
|
-
id: "github-webhook",
|
|
120
|
-
name: "GitHub Webhook",
|
|
121
|
-
messageTemplate: "New webhook event"
|
|
122
|
-
} },
|
|
123
|
-
statusUpdates: {
|
|
124
|
-
numEvents: 1,
|
|
125
|
-
statusComponents: [{
|
|
126
|
-
id: "tool-summary",
|
|
127
|
-
type: "tool_summary",
|
|
128
|
-
description: "Tool summary status component",
|
|
129
|
-
detailsSchema: {
|
|
130
|
-
type: "object",
|
|
131
|
-
properties: { tool_name: { type: "string" } }
|
|
132
|
-
}
|
|
133
|
-
}]
|
|
134
|
-
}
|
|
135
|
-
} },
|
|
136
|
-
createdAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
137
|
-
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
138
|
-
};
|
|
139
|
-
}
|
|
140
|
-
async function createUnifiedDiff(filePath, before, after) {
|
|
141
|
-
return createTwoFilesPatch(filePath, filePath, before, after, "before", "after", { context: 3 });
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
//#endregion
|
|
145
|
-
export { beforeCredentialContent, cleanupTestEnvironment, createProjectFixture, createTestEnvironment, createUnifiedDiff, getTestPath };
|
|
146
|
-
//# sourceMappingURL=test-helpers.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"test-helpers.js","names":[],"sources":["../../../../src/commands/pull-v4/introspect/test-helpers.ts"],"sourcesContent":["import fs from 'node:fs';\nimport { tmpdir } from 'node:os';\nimport { join } from 'node:path';\nimport type { FullProjectDefinition } from '@inkeep/agents-core';\nimport { createTwoFilesPatch } from 'diff';\nimport type { ProjectPaths } from '../introspect-generator';\n\nexport const beforeCredentialContent = `import { credential } from '@inkeep/agents-sdk';\n\nconst keepMe = () => 'keep-me';\n\nexport const apiCredentials = credential({\n id: 'api-credentials',\n name: 'Old API Credentials',\n type: 'bearer',\n credentialStoreId: 'main-store'\n});\n`.trimStart();\n\nexport function createTestEnvironment(): { testDir: string; projectPaths: ProjectPaths } {\n const testDir = join(\n tmpdir(),\n `introspect-v4-test-${Date.now()}-${Math.random().toString(36).slice(2, 9)}`\n );\n fs.mkdirSync(testDir, { recursive: true });\n\n return {\n testDir,\n projectPaths: {\n projectRoot: testDir,\n agentsDir: join(testDir, 'agents'),\n toolsDir: join(testDir, 'tools'),\n dataComponentsDir: join(testDir, 'data-components'),\n artifactComponentsDir: join(testDir, 'artifact-components'),\n statusComponentsDir: join(testDir, 'status-components'),\n environmentsDir: join(testDir, 'environments'),\n credentialsDir: join(testDir, 'credentials'),\n contextConfigsDir: join(testDir, 'context-configs'),\n externalAgentsDir: join(testDir, 'external-agents'),\n skillsDir: join(testDir, 'skills'),\n },\n };\n}\n\nexport function cleanupTestEnvironment(testDir: string): void {\n fs.rmSync(testDir, { recursive: true, force: true });\n}\n\nexport function getTestPath(): string {\n return `../__tests__/__snapshots__/introspect/${expect.getState().currentTestName?.split(' > ').at(-1)}`;\n}\n\nexport function createProjectFixture(): FullProjectDefinition {\n return {\n id: 'support-project',\n name: 'Support Project',\n description: 'Support project for introspect v4 tests',\n models: {\n base: {\n model: 'gpt-4o-mini',\n },\n },\n credentialReferences: {\n 'api-credentials': {\n id: 'api-credentials',\n name: 'API Credentials',\n type: 'memory',\n credentialStoreId: 'main-store',\n retrievalParams: {\n key: 'token',\n },\n },\n },\n dataComponents: {\n 'customer-profile': {\n id: 'customer-profile',\n name: 'Customer Profile',\n description: 'Customer profile data component',\n props: {\n type: 'object',\n properties: {\n // @ts-expect-error -- fixme\n fullName: { type: 'string' },\n // @ts-expect-error -- fixme\n avatarUrl: { type: 'string' },\n },\n },\n render: {\n component: '<img src=\"{{avatarUrl}}\" alt=\"{{fullName}}\" />',\n mockData: {\n fullName: 'Ada Lovelace',\n avatarUrl: 'https://example.com/avatar.png',\n },\n },\n },\n },\n artifactComponents: {\n 'ticket-summary': {\n id: 'ticket-summary',\n name: 'Ticket Summary',\n props: {\n type: 'object',\n properties: {\n // @ts-expect-error -- fixme\n title: { type: 'string' },\n },\n },\n },\n },\n agents: {\n 'support-agent': {\n id: 'support-agent',\n name: 'Support Agent',\n defaultSubAgentId: 'tier-one',\n subAgents: {\n // @ts-expect-error -- fixme\n 'tier-one': {\n id: 'tier-one',\n name: 'Tier One',\n canUse: [],\n },\n },\n contextConfig: {\n id: 'support-context',\n headersSchema: {\n type: 'object',\n properties: {\n user_id: {\n type: 'string',\n },\n },\n },\n contextVariables: {\n userInfo: {\n id: 'user-info',\n name: 'User Information',\n trigger: 'initialization',\n fetchConfig: {\n // biome-ignore lint/suspicious/noTemplateCurlyInString: snapshot should produce template string\n url: 'https://api.example.com/users/${headersSchema.toTemplate(\"user_id\")}',\n method: 'GET',\n },\n responseSchema: {\n type: 'object',\n properties: {\n name: {\n type: 'string',\n },\n },\n },\n defaultValue: 'Unable to fetch user information',\n },\n },\n },\n triggers: {\n 'github-webhook': {\n id: 'github-webhook',\n name: 'GitHub Webhook',\n messageTemplate: 'New webhook event',\n },\n },\n statusUpdates: {\n numEvents: 1,\n statusComponents: [\n {\n // @ts-expect-error -- fixme\n id: 'tool-summary',\n type: 'tool_summary',\n description: 'Tool summary status component',\n detailsSchema: {\n type: 'object',\n properties: {\n tool_name: {\n type: 'string',\n },\n },\n },\n },\n ],\n },\n },\n },\n createdAt: new Date().toISOString(),\n updatedAt: new Date().toISOString(),\n };\n}\n\nexport async function createUnifiedDiff(\n filePath: string,\n before: string,\n after: string\n): Promise<string> {\n return createTwoFilesPatch(filePath, filePath, before, after, 'before', 'after', {\n context: 3,\n });\n}\n"],"mappings":";;;;;;;AAOA,MAAa,0BAA0B;;;;;;;;;;EAUrC,WAAW;AAEb,SAAgB,wBAAyE;CACvF,MAAM,UAAU,KACd,QAAQ,EACR,sBAAsB,KAAK,KAAK,CAAC,GAAG,KAAK,QAAQ,CAAC,SAAS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EAAE,MAAM,UAAU,EAC1B;IACF;GACF,EACF;EACD,QAAQ,EACN,iBAAiB;GACf,IAAI;GACJ,MAAM;GACN,mBAAmB;GACnB,WAAW,EAET,YAAY;IACV,IAAI;IACJ,MAAM;IACN,QAAQ,EAAE;IACX,EACF;GACD,eAAe;IACb,IAAI;IACJ,eAAe;KACb,MAAM;KACN,YAAY,EACV,SAAS,EACP,MAAM,UACP,EACF;KACF;IACD,kBAAkB,EAChB,UAAU;KACR,IAAI;KACJ,MAAM;KACN,SAAS;KACT,aAAa;MAEX,KAAK;MACL,QAAQ;MACT;KACD,gBAAgB;MACd,MAAM;MACN,YAAY,EACV,MAAM,EACJ,MAAM,UACP,EACF;MACF;KACD,cAAc;KACf,EACF;IACF;GACD,UAAU,EACR,kBAAkB;IAChB,IAAI;IACJ,MAAM;IACN,iBAAiB;IAClB,EACF;GACD,eAAe;IACb,WAAW;IACX,kBAAkB,CAChB;KAEE,IAAI;KACJ,MAAM;KACN,aAAa;KACb,eAAe;MACb,MAAM;MACN,YAAY,EACV,WAAW,EACT,MAAM,UACP,EACF;MACF;KACF,CACF;IACF;GACF,EACF;EACD,4BAAW,IAAI,MAAM,EAAC,aAAa;EACnC,4BAAW,IAAI,MAAM,EAAC,aAAa;EACpC;;AAGH,eAAsB,kBACpB,UACA,QACA,OACiB;AACjB,QAAO,oBAAoB,UAAU,UAAU,QAAQ,OAAO,UAAU,SAAS,EAC/E,SAAS,GACV,CAAC"}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import Diff from "./base.js";
|
|
2
|
-
|
|
3
|
-
//#region ../node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/array.js
|
|
4
|
-
var ArrayDiff = class extends Diff {
|
|
5
|
-
tokenize(value) {
|
|
6
|
-
return value.slice();
|
|
7
|
-
}
|
|
8
|
-
join(value) {
|
|
9
|
-
return value;
|
|
10
|
-
}
|
|
11
|
-
removeEmpty(value) {
|
|
12
|
-
return value;
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
const arrayDiff = new ArrayDiff();
|
|
16
|
-
|
|
17
|
-
//#endregion
|
|
18
|
-
export { };
|
|
19
|
-
//# sourceMappingURL=array.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"array.js","names":[],"sources":["../../../../../../../../../node_modules/.pnpm/diff@8.0.3/node_modules/diff/libesm/diff/array.js"],"sourcesContent":["import Diff from './base.js';\nclass ArrayDiff extends Diff {\n tokenize(value) {\n return value.slice();\n }\n join(value) {\n return value;\n }\n removeEmpty(value) {\n return value;\n }\n}\nexport const arrayDiff = new ArrayDiff();\nexport function diffArrays(oldArr, newArr, options) {\n return arrayDiff.diff(oldArr, newArr, options);\n}\n"],"x_google_ignoreList":[0],"mappings":";;;AACA,IAAM,YAAN,cAAwB,KAAK;CACzB,SAAS,OAAO;AACZ,SAAO,MAAM,OAAO;;CAExB,KAAK,OAAO;AACR,SAAO;;CAEX,YAAY,OAAO;AACf,SAAO;;;AAGf,MAAa,YAAY,IAAI,WAAW"}
|