@vm0/cli 9.178.0 → 9.180.0
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/{chunk-DPEOZVW6.js → chunk-ETF2LZ4O.js} +648 -379
- package/{chunk-DPEOZVW6.js.map → chunk-ETF2LZ4O.js.map} +1 -1
- package/index.js +9 -9
- package/package.json +1 -1
- package/zero.js +149 -21
- package/zero.js.map +1 -1
package/index.js
CHANGED
|
@@ -67,7 +67,7 @@ import {
|
|
|
67
67
|
source_default,
|
|
68
68
|
volumeConfigSchema,
|
|
69
69
|
withErrorHandler
|
|
70
|
-
} from "./chunk-
|
|
70
|
+
} from "./chunk-ETF2LZ4O.js";
|
|
71
71
|
import {
|
|
72
72
|
__toESM,
|
|
73
73
|
init_esm_shims
|
|
@@ -400,7 +400,7 @@ function getConfigPath() {
|
|
|
400
400
|
return join(os.homedir(), ".vm0", "config.json");
|
|
401
401
|
}
|
|
402
402
|
var infoCommand = new Command().name("info").description("Display environment and debug information").action(async () => {
|
|
403
|
-
console.log(source_default.bold(`VM0 CLI v${"9.
|
|
403
|
+
console.log(source_default.bold(`VM0 CLI v${"9.180.0"}`));
|
|
404
404
|
console.log();
|
|
405
405
|
const config = await loadConfig();
|
|
406
406
|
const hasEnvToken = !!process.env.VM0_TOKEN;
|
|
@@ -4293,7 +4293,7 @@ var composeCommand = new Command().name("compose").description("Create or update
|
|
|
4293
4293
|
options.autoUpdate = false;
|
|
4294
4294
|
}
|
|
4295
4295
|
if (options.autoUpdate !== false) {
|
|
4296
|
-
await startSilentUpgrade("9.
|
|
4296
|
+
await startSilentUpgrade("9.180.0");
|
|
4297
4297
|
}
|
|
4298
4298
|
try {
|
|
4299
4299
|
let result;
|
|
@@ -4395,7 +4395,7 @@ var mainRunCommand = new Command().name("run").description("Run an agent").argum
|
|
|
4395
4395
|
withErrorHandler(
|
|
4396
4396
|
async (identifier, prompt, options) => {
|
|
4397
4397
|
if (options.autoUpdate !== false) {
|
|
4398
|
-
await startSilentUpgrade("9.
|
|
4398
|
+
await startSilentUpgrade("9.180.0");
|
|
4399
4399
|
}
|
|
4400
4400
|
const { name, version } = parseIdentifier(identifier);
|
|
4401
4401
|
let composeId;
|
|
@@ -6192,13 +6192,13 @@ var upgradeCommand = new Command().name("upgrade").description("Upgrade vm0 CLI
|
|
|
6192
6192
|
if (latestVersion === null) {
|
|
6193
6193
|
throw new Error("Could not check for updates. Please try again later.");
|
|
6194
6194
|
}
|
|
6195
|
-
if (latestVersion === "9.
|
|
6196
|
-
console.log(source_default.green(`\u2713 Already up to date (${"9.
|
|
6195
|
+
if (latestVersion === "9.180.0") {
|
|
6196
|
+
console.log(source_default.green(`\u2713 Already up to date (${"9.180.0"})`));
|
|
6197
6197
|
return;
|
|
6198
6198
|
}
|
|
6199
6199
|
console.log(
|
|
6200
6200
|
source_default.yellow(
|
|
6201
|
-
`Current version: ${"9.
|
|
6201
|
+
`Current version: ${"9.180.0"} -> Latest version: ${latestVersion}`
|
|
6202
6202
|
)
|
|
6203
6203
|
);
|
|
6204
6204
|
console.log();
|
|
@@ -6225,7 +6225,7 @@ var upgradeCommand = new Command().name("upgrade").description("Upgrade vm0 CLI
|
|
|
6225
6225
|
const success = await performUpgrade(packageManager);
|
|
6226
6226
|
if (success) {
|
|
6227
6227
|
console.log(
|
|
6228
|
-
source_default.green(`\u2713 Upgraded from ${"9.
|
|
6228
|
+
source_default.green(`\u2713 Upgraded from ${"9.180.0"} to ${latestVersion}`)
|
|
6229
6229
|
);
|
|
6230
6230
|
return;
|
|
6231
6231
|
}
|
|
@@ -6292,7 +6292,7 @@ var whoamiCommand = new Command().name("whoami").description("Show current ident
|
|
|
6292
6292
|
|
|
6293
6293
|
// src/index.ts
|
|
6294
6294
|
var program = new Command();
|
|
6295
|
-
program.name("vm0").description("VM0 CLI - Build and run agents with natural language").version("9.
|
|
6295
|
+
program.name("vm0").description("VM0 CLI - Build and run agents with natural language").version("9.180.0");
|
|
6296
6296
|
program.addCommand(authCommand);
|
|
6297
6297
|
program.addCommand(infoCommand);
|
|
6298
6298
|
program.addCommand(composeCommand);
|
package/package.json
CHANGED
package/zero.js
CHANGED
|
@@ -11,6 +11,7 @@ import {
|
|
|
11
11
|
InvalidArgumentError,
|
|
12
12
|
MODEL_PROVIDER_TYPES,
|
|
13
13
|
Option,
|
|
14
|
+
callZeroBanking,
|
|
14
15
|
callZeroMaps,
|
|
15
16
|
completeGithubFileUpload,
|
|
16
17
|
completeHostedSite,
|
|
@@ -61,11 +62,11 @@ import {
|
|
|
61
62
|
getConnectorAuthMethod,
|
|
62
63
|
getConnectorAuthMethodScopeDiff,
|
|
63
64
|
getConnectorEnvBindingEntries,
|
|
64
|
-
getConnectorEnvNamesForSecret,
|
|
65
65
|
getConnectorFirewall,
|
|
66
66
|
getConnectorGenerationTypes,
|
|
67
|
-
|
|
67
|
+
getConnectorStoredSecretDisplayInfo,
|
|
68
68
|
getDefaultAuthMethod,
|
|
69
|
+
getDiagnosticConnectorTypeForRuntimeEnvName,
|
|
69
70
|
getGithubInstallation,
|
|
70
71
|
getSecretsForAuthMethod,
|
|
71
72
|
getSelectableProviderTypes,
|
|
@@ -148,7 +149,7 @@ import {
|
|
|
148
149
|
upsertZeroOrgModelProvider,
|
|
149
150
|
withErrorHandler,
|
|
150
151
|
zeroAgentCustomSkillNameSchema
|
|
151
|
-
} from "./chunk-
|
|
152
|
+
} from "./chunk-ETF2LZ4O.js";
|
|
152
153
|
import {
|
|
153
154
|
__toESM,
|
|
154
155
|
init_esm_shims
|
|
@@ -2905,14 +2906,14 @@ How connectors work:
|
|
|
2905
2906
|
console.log(` Relative path: ${urlLookup.relativePath}`);
|
|
2906
2907
|
console.log(` Environment name: ${envName}`);
|
|
2907
2908
|
} else {
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
)
|
|
2911
|
-
if (!connectorType) {
|
|
2909
|
+
envName = opts.envName;
|
|
2910
|
+
const resolvedConnectorType = getDiagnosticConnectorTypeForRuntimeEnvName(envName);
|
|
2911
|
+
if (!resolvedConnectorType) {
|
|
2912
2912
|
throw new Error(
|
|
2913
2913
|
`Unknown environment name: ${envName} \u2014 not managed by any connector`
|
|
2914
2914
|
);
|
|
2915
2915
|
}
|
|
2916
|
+
connectorType = resolvedConnectorType;
|
|
2916
2917
|
console.log(
|
|
2917
2918
|
`${envName} is managed by the ${CONNECTOR_TYPES[connectorType].label} connector (type: ${connectorType}).`
|
|
2918
2919
|
);
|
|
@@ -4501,7 +4502,7 @@ var listCommand8 = new Command().name("list").alias("ls").description("List all
|
|
|
4501
4502
|
if (secret.type === "model-provider") {
|
|
4502
4503
|
typeIndicator = source_default.dim(" [model-provider]");
|
|
4503
4504
|
} else if (secret.type === "connector") {
|
|
4504
|
-
const derived =
|
|
4505
|
+
const derived = getConnectorStoredSecretDisplayInfo(secret.name);
|
|
4505
4506
|
if (derived) {
|
|
4506
4507
|
typeIndicator = source_default.dim(` [${derived.connectorLabel} connector]`);
|
|
4507
4508
|
derivedLine = source_default.dim(
|
|
@@ -4511,7 +4512,7 @@ var listCommand8 = new Command().name("list").alias("ls").description("List all
|
|
|
4511
4512
|
typeIndicator = source_default.dim(" [connector]");
|
|
4512
4513
|
}
|
|
4513
4514
|
} else if (secret.type === "user") {
|
|
4514
|
-
const derived =
|
|
4515
|
+
const derived = getConnectorStoredSecretDisplayInfo(secret.name);
|
|
4515
4516
|
if (derived) {
|
|
4516
4517
|
typeIndicator = source_default.dim(` [${derived.connectorLabel} connector]`);
|
|
4517
4518
|
derivedLine = source_default.dim(
|
|
@@ -10001,6 +10002,30 @@ var RESOURCE_REGISTRY = [
|
|
|
10001
10002
|
path: "illustration-template/iberian-vignette"
|
|
10002
10003
|
}
|
|
10003
10004
|
},
|
|
10005
|
+
{
|
|
10006
|
+
id: "image-style:cozy-parlor",
|
|
10007
|
+
kind: "image-style",
|
|
10008
|
+
name: "Cozy Parlor",
|
|
10009
|
+
description: "Hand-painted watercolor + ink-line scene \u2014 one anthropomorphic animal in a quiet domestic interior, clean cool-white paper, neutral palette with one hot accent pop.",
|
|
10010
|
+
desc: "Hand-painted watercolor + brushy black ink line on clean cool-white paper (no amber tint). ONE anthropomorphic animal mid-quiet-activity in a domestic interior. Closed-crescent-eye smile, minimal facial features, expression through posture. At least two patterned surfaces per piece. Cool/neutral palette lead (sage, slate-blue, cornflower, lavender, mint, dove-gray) with a single hot accent pop (cherry-red, mustard, magenta-pink) on one object. Six dials per brief \u2014 cast, activity, palette family, pattern motif stack, hot accent object, and complexity (L1/L2/L3). Trigger when user says /cozy-parlor, asks for a 'cozy parlor illustration', a 'watercolor animal scene', a 'picture-book interior', or a new piece in this neutral-palette watercolor style.",
|
|
10011
|
+
source: {
|
|
10012
|
+
repo: VM0_SKILLS_REPO,
|
|
10013
|
+
ref: VM0_SKILLS_REF,
|
|
10014
|
+
path: "illustration-template/cozy-parlor"
|
|
10015
|
+
}
|
|
10016
|
+
},
|
|
10017
|
+
{
|
|
10018
|
+
id: "image-style:crowd-ink",
|
|
10019
|
+
kind: "image-style",
|
|
10020
|
+
name: "Crowd Ink",
|
|
10021
|
+
description: "Hand-drawn editorial crowd illustration \u2014 sketchy black ink contours over flat 3-color spot fills on pure white, scene-as-metaphor composition.",
|
|
10022
|
+
desc: 'Hand-drawn editorial crowd illustration style \u2014 confident sketchy black ink contour lines with slightly irregular weight, flat 3-color spot fills sitting under or beside the ink lines (edges allowed to misregister slightly), on a PURE WHITE background (never cream). Fine-line backdrop drawn lighter than the foreground figures, scattered atmospheric marks in negative space (birds / leaves / steam / confetti / dots), and a scene-as-metaphor composition with a cast that varies per piece. Six dials per brief \u2014 palette (tested families: urban editorial / cool transit / warm natural / cozy interior), scene metaphor, complexity (L2 small group of 3\u20135 / L3 full crowd of 8\u201310), cast, backdrop, atmospheric motif. Trigger when the user says /crowd-ink, asks for a "crowd-ink illustration", "editorial crowd scene", "hand-drawn ink-and-spot-color illustration", "New-Yorker-style crowd vignette", or briefs with palette + scene metaphor + complexity level.',
|
|
10023
|
+
source: {
|
|
10024
|
+
repo: VM0_SKILLS_REPO,
|
|
10025
|
+
ref: VM0_SKILLS_REF,
|
|
10026
|
+
path: "illustration-template/crowd-ink"
|
|
10027
|
+
}
|
|
10028
|
+
},
|
|
10004
10029
|
{
|
|
10005
10030
|
id: "image-style:ink-storefront",
|
|
10006
10031
|
kind: "image-style",
|
|
@@ -11373,7 +11398,7 @@ var reportCommand = createArtifactGenerateCommand({
|
|
|
11373
11398
|
description: "Generate an HTML report from a prompt",
|
|
11374
11399
|
usageCommand: "zero generate report",
|
|
11375
11400
|
examples: ` Generate report: zero generate report --prompt "A Q2 usage report for the API team"
|
|
11376
|
-
|
|
11401
|
+
Custom site slug: zero generate report --site-slug api-usage-q2 --prompt "A Q2 usage report"
|
|
11377
11402
|
Show choices: zero generate report`,
|
|
11378
11403
|
details: standardDetails("report"),
|
|
11379
11404
|
artifactRules: [
|
|
@@ -11390,7 +11415,7 @@ var docsDesignCommand = createArtifactGenerateCommand({
|
|
|
11390
11415
|
description: "Generate a documentation design from a prompt",
|
|
11391
11416
|
usageCommand: "zero generate docs-design",
|
|
11392
11417
|
examples: ` Generate docs design: zero generate docs-design --prompt "Docs for adding artifact targets"
|
|
11393
|
-
|
|
11418
|
+
Custom site slug: zero generate docs-design --site-slug artifact-target-docs --prompt "Artifact target docs"
|
|
11394
11419
|
Show choices: zero generate docs-design`,
|
|
11395
11420
|
details: standardDetails("docs-design"),
|
|
11396
11421
|
artifactRules: [
|
|
@@ -11407,7 +11432,7 @@ var posterCommand = createArtifactGenerateCommand({
|
|
|
11407
11432
|
description: "Generate an HTML poster from a prompt",
|
|
11408
11433
|
usageCommand: "zero generate poster",
|
|
11409
11434
|
examples: ` Generate poster: zero generate poster --prompt "A launch poster for artifact targets"
|
|
11410
|
-
|
|
11435
|
+
Custom site slug: zero generate poster --site-slug artifact-poster --prompt "A launch poster"
|
|
11411
11436
|
Show choices: zero generate poster`,
|
|
11412
11437
|
details: standardDetails("poster"),
|
|
11413
11438
|
artifactRules: [
|
|
@@ -11424,7 +11449,7 @@ var dashboardDesignCommand = createArtifactGenerateCommand({
|
|
|
11424
11449
|
description: "Generate a dashboard design from a prompt",
|
|
11425
11450
|
usageCommand: "zero generate dashboard-design",
|
|
11426
11451
|
examples: ` Generate dash design: zero generate dashboard-design --prompt "An ops dashboard for generation runs"
|
|
11427
|
-
|
|
11452
|
+
Custom site slug: zero generate dashboard-design --site-slug generation-ops --prompt "A generation ops dashboard"
|
|
11428
11453
|
Show choices: zero generate dashboard-design`,
|
|
11429
11454
|
details: standardDetails("dashboard-design"),
|
|
11430
11455
|
artifactRules: [
|
|
@@ -11441,7 +11466,7 @@ var mobileAppDesignCommand = createArtifactGenerateCommand({
|
|
|
11441
11466
|
description: "Generate a mobile app design prototype from a prompt",
|
|
11442
11467
|
usageCommand: "zero generate mobile-app-design",
|
|
11443
11468
|
examples: ` Generate mobile UI: zero generate mobile-app-design --prompt "A mobile review screen for generation artifacts"
|
|
11444
|
-
|
|
11469
|
+
Custom site slug: zero generate mobile-app-design --site-slug generation-mobile-review --prompt "A mobile review screen"
|
|
11445
11470
|
Show choices: zero generate mobile-app-design`,
|
|
11446
11471
|
details: standardDetails("mobile-app-design"),
|
|
11447
11472
|
artifactRules: [
|
|
@@ -11575,7 +11600,10 @@ ${formatRegistryListing(templates, "presentation templates")}`;
|
|
|
11575
11600
|
"Use a fixed 1920x1080 slide canvas and scale it uniformly for smaller viewports.",
|
|
11576
11601
|
"Use one section per slide and keep repeated elements in consistent positions.",
|
|
11577
11602
|
"Make keyboard navigation work with ArrowLeft, ArrowRight, Home, and End.",
|
|
11578
|
-
"Keep slide text readable from across a room; avoid memo-like walls of text."
|
|
11603
|
+
"Keep slide text readable from across a room; avoid memo-like walls of text.",
|
|
11604
|
+
"Before laying out slides, establish the deck's arc: the opening problem or question, how it develops, and what conclusion lands; every slide should serve a clear narrative role in that arc.",
|
|
11605
|
+
"Vary slide forms across the deck \u2014 full-bleed statement, evidence with data, pull quote, section break, summary \u2014 and avoid defaulting every slide to title-plus-bullets.",
|
|
11606
|
+
"Each slide carries one idea; prefer a single strong statement over a list, and never exceed three bullets on any slide."
|
|
11579
11607
|
]
|
|
11580
11608
|
});
|
|
11581
11609
|
console.log(packet.instructions);
|
|
@@ -11591,7 +11619,7 @@ var presentationCommand = createPresentationGenerateCommand({
|
|
|
11591
11619
|
examples: ` Generate deck: zero generate presentation --prompt "A strategy deck for reducing support volume"
|
|
11592
11620
|
Pipe prompt: cat brief.txt | zero generate presentation
|
|
11593
11621
|
Pick slide count: zero generate presentation --slides 10 --prompt "A product launch narrative"
|
|
11594
|
-
|
|
11622
|
+
Custom site slug: zero generate presentation --site-slug api-migration-plan --prompt "API migration plan"
|
|
11595
11623
|
Show choices: zero generate presentation`
|
|
11596
11624
|
});
|
|
11597
11625
|
|
|
@@ -12256,7 +12284,7 @@ Examples:
|
|
|
12256
12284
|
Generate site: zero generate website --prompt "A launch site for a developer observability tool"
|
|
12257
12285
|
Pick template: zero generate website --template saas-landing --prompt "Launch site for a billing API"
|
|
12258
12286
|
Pick design system: zero generate website --design-system stripe --prompt "Pricing page for a SaaS"
|
|
12259
|
-
|
|
12287
|
+
Custom site slug: zero generate website --site-slug api-migration-demo --prompt "An internal migration microsite"
|
|
12260
12288
|
Pipe prompt: cat brief.txt | zero generate website
|
|
12261
12289
|
Show choices: zero generate website
|
|
12262
12290
|
|
|
@@ -12786,6 +12814,7 @@ async function publishStaticSite(options) {
|
|
|
12786
12814
|
});
|
|
12787
12815
|
const prepared = await prepareHostedSite({
|
|
12788
12816
|
site: options.site,
|
|
12817
|
+
...options.slugSuffix !== void 0 && { slugSuffix: options.slugSuffix },
|
|
12789
12818
|
spaFallback: Boolean(options.spaFallback),
|
|
12790
12819
|
files: scan.files.map((file) => {
|
|
12791
12820
|
return {
|
|
@@ -12837,15 +12866,17 @@ function formatBytes(bytes) {
|
|
|
12837
12866
|
if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(1)} KB`;
|
|
12838
12867
|
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
12839
12868
|
}
|
|
12840
|
-
var zeroHostCommand = new Command().name("host").description("Publish a built static site and print its public URL").argument("<dir>", "Static build directory, for example ./dist").requiredOption("--site <slug>", "Public site slug, e.g. my-product-demo").option("--spa", "Serve unknown HTML navigation paths from index.html").option("--json", "Output only the final result as JSON").addHelpText(
|
|
12869
|
+
var zeroHostCommand = new Command().name("host").description("Publish a built static site and print its public URL").argument("<dir>", "Static build directory, for example ./dist").requiredOption("--site <slug>", "Public site slug, e.g. my-product-demo").option("--slug-suffix <suffix>", "Reuse a generated site URL suffix").option("--spa", "Serve unknown HTML navigation paths from index.html").option("--json", "Output only the final result as JSON").addHelpText(
|
|
12841
12870
|
"after",
|
|
12842
12871
|
`
|
|
12843
12872
|
Examples:
|
|
12844
12873
|
Publish a Vite build: zero host ./dist --site my-product-demo --spa
|
|
12874
|
+
Redeploy a URL: zero host ./dist --site my-product-demo --slug-suffix a1b2c3d4 --spa
|
|
12845
12875
|
Machine readable: zero host ./dist --site my-product-demo --spa --json
|
|
12846
12876
|
|
|
12847
12877
|
Notes:
|
|
12848
12878
|
- Authenticates via ZERO_TOKEN (requires host:write capability)
|
|
12879
|
+
- Reusing both --site and --slug-suffix keeps the same URL
|
|
12849
12880
|
- The directory must include index.html
|
|
12850
12881
|
- Local HTML/CSS asset references must point at files inside the directory`
|
|
12851
12882
|
).action(
|
|
@@ -12853,6 +12884,7 @@ Notes:
|
|
|
12853
12884
|
const result = await publishStaticSite({
|
|
12854
12885
|
dir,
|
|
12855
12886
|
site: options.site,
|
|
12887
|
+
slugSuffix: options.slugSuffix,
|
|
12856
12888
|
spaFallback: Boolean(options.spa),
|
|
12857
12889
|
onProgress: options.json ? void 0 : (progress) => {
|
|
12858
12890
|
if (progress.phase === "preparing") {
|
|
@@ -13054,6 +13086,99 @@ Notes:
|
|
|
13054
13086
|
- Use --fields essentials for place details unless pro fields are required`
|
|
13055
13087
|
);
|
|
13056
13088
|
|
|
13089
|
+
// src/commands/zero/banking/index.ts
|
|
13090
|
+
init_esm_shims();
|
|
13091
|
+
function parseLimit5(value) {
|
|
13092
|
+
const parsed = Number(value);
|
|
13093
|
+
if (!Number.isInteger(parsed) || parsed < 1 || parsed > 1e3) {
|
|
13094
|
+
throw new InvalidArgumentError("limit must be between 1 and 1000");
|
|
13095
|
+
}
|
|
13096
|
+
return parsed;
|
|
13097
|
+
}
|
|
13098
|
+
function parseDateOnly(value) {
|
|
13099
|
+
if (!/^\d{4}-\d{2}-\d{2}$/.test(value)) {
|
|
13100
|
+
throw new InvalidArgumentError("date must be formatted as YYYY-MM-DD");
|
|
13101
|
+
}
|
|
13102
|
+
return value;
|
|
13103
|
+
}
|
|
13104
|
+
function renderBankingResponse(label, response) {
|
|
13105
|
+
console.log(source_default.green(`\u2713 ${label}`));
|
|
13106
|
+
console.log(source_default.dim(` Provider: ${response.provider}`));
|
|
13107
|
+
if (response.accounts) {
|
|
13108
|
+
console.log(JSON.stringify(response.accounts, null, 2));
|
|
13109
|
+
return;
|
|
13110
|
+
}
|
|
13111
|
+
if (response.balance) {
|
|
13112
|
+
console.log(JSON.stringify(response.balance, null, 2));
|
|
13113
|
+
return;
|
|
13114
|
+
}
|
|
13115
|
+
console.log(JSON.stringify(response.transactions ?? [], null, 2));
|
|
13116
|
+
}
|
|
13117
|
+
async function runBankingRequest(label, operation, payload, options) {
|
|
13118
|
+
const response = await callZeroBanking(operation, payload);
|
|
13119
|
+
if (options.json) {
|
|
13120
|
+
console.log(JSON.stringify(response));
|
|
13121
|
+
return;
|
|
13122
|
+
}
|
|
13123
|
+
renderBankingResponse(label, response);
|
|
13124
|
+
}
|
|
13125
|
+
var accountsCommand = new Command().name("accounts").description("List enabled banking accounts").option("--json", "Print the raw banking response as JSON").action(
|
|
13126
|
+
withErrorHandler(async (options) => {
|
|
13127
|
+
await runBankingRequest(
|
|
13128
|
+
"Banking accounts loaded",
|
|
13129
|
+
"accounts",
|
|
13130
|
+
{},
|
|
13131
|
+
options
|
|
13132
|
+
);
|
|
13133
|
+
})
|
|
13134
|
+
);
|
|
13135
|
+
var balancesCommand = new Command().name("balances").description("Read an enabled account balance").requiredOption("--account-id <id>", "Enabled provider account ID").option("--json", "Print the raw banking response as JSON").action(
|
|
13136
|
+
withErrorHandler(async (options) => {
|
|
13137
|
+
await runBankingRequest(
|
|
13138
|
+
"Banking balance loaded",
|
|
13139
|
+
"balances",
|
|
13140
|
+
{ accountId: options.accountId },
|
|
13141
|
+
options
|
|
13142
|
+
);
|
|
13143
|
+
})
|
|
13144
|
+
);
|
|
13145
|
+
var transactionsCommand = new Command().name("transactions").description("Read transactions for an enabled account").requiredOption("--account-id <id>", "Enabled provider account ID").requiredOption(
|
|
13146
|
+
"--from <date>",
|
|
13147
|
+
"Start date, formatted as YYYY-MM-DD",
|
|
13148
|
+
parseDateOnly
|
|
13149
|
+
).requiredOption(
|
|
13150
|
+
"--to <date>",
|
|
13151
|
+
"End date, formatted as YYYY-MM-DD",
|
|
13152
|
+
parseDateOnly
|
|
13153
|
+
).option("--limit <n>", "Maximum transactions to return", parseLimit5, 100).option("--json", "Print the raw banking response as JSON").action(
|
|
13154
|
+
withErrorHandler(async (options) => {
|
|
13155
|
+
await runBankingRequest(
|
|
13156
|
+
"Banking transactions loaded",
|
|
13157
|
+
"transactions",
|
|
13158
|
+
{
|
|
13159
|
+
accountId: options.accountId,
|
|
13160
|
+
from: options.from,
|
|
13161
|
+
to: options.to,
|
|
13162
|
+
limit: options.limit
|
|
13163
|
+
},
|
|
13164
|
+
options
|
|
13165
|
+
);
|
|
13166
|
+
})
|
|
13167
|
+
);
|
|
13168
|
+
var zeroBankingCommand = new Command().name("banking").description("Use managed zero banking services").addCommand(accountsCommand).addCommand(balancesCommand).addCommand(transactionsCommand).addHelpText(
|
|
13169
|
+
"after",
|
|
13170
|
+
`
|
|
13171
|
+
Examples:
|
|
13172
|
+
List accounts: zero banking accounts --json
|
|
13173
|
+
Get balance: zero banking balances --account-id <id> --json
|
|
13174
|
+
Get transactions: zero banking transactions --account-id <id> --from 2026-01-01 --to 2026-01-31 --json
|
|
13175
|
+
|
|
13176
|
+
Notes:
|
|
13177
|
+
- Authenticates via ZERO_TOKEN (requires banking:read capability)
|
|
13178
|
+
- Finicity credentials and app tokens stay on the vm0 API server
|
|
13179
|
+
- Access is limited to accounts enabled for the current agent`
|
|
13180
|
+
);
|
|
13181
|
+
|
|
13057
13182
|
// src/commands/zero/model/index.ts
|
|
13058
13183
|
init_esm_shims();
|
|
13059
13184
|
|
|
@@ -13213,7 +13338,8 @@ var COMMAND_CAPABILITY_MAP = {
|
|
|
13213
13338
|
generate: null,
|
|
13214
13339
|
web: null,
|
|
13215
13340
|
host: "host:write",
|
|
13216
|
-
maps: "maps:read"
|
|
13341
|
+
maps: "maps:read",
|
|
13342
|
+
banking: "banking:read"
|
|
13217
13343
|
};
|
|
13218
13344
|
var DEFAULT_COMMANDS = [
|
|
13219
13345
|
zeroOrgCommand,
|
|
@@ -13242,7 +13368,8 @@ var DEFAULT_COMMANDS = [
|
|
|
13242
13368
|
generateCommand,
|
|
13243
13369
|
zeroWebCommand,
|
|
13244
13370
|
zeroHostCommand,
|
|
13245
|
-
zeroMapsCommand
|
|
13371
|
+
zeroMapsCommand,
|
|
13372
|
+
zeroBankingCommand
|
|
13246
13373
|
];
|
|
13247
13374
|
function shouldHideCommand(name, payload) {
|
|
13248
13375
|
if (!payload) return false;
|
|
@@ -13284,6 +13411,7 @@ function buildZeroHelpText(payload = decodeZeroTokenPayload()) {
|
|
|
13284
13411
|
...shouldHideCommand("maps", payload) ? [] : [
|
|
13285
13412
|
' Get directions? zero maps directions --origin "SFO" --destination "Mountain View" --json'
|
|
13286
13413
|
],
|
|
13414
|
+
...shouldHideCommand("banking", payload) ? [] : [" Read bank data? zero banking accounts --json"],
|
|
13287
13415
|
" Check your identity? zero whoami"
|
|
13288
13416
|
];
|
|
13289
13417
|
return `
|
|
@@ -13301,7 +13429,7 @@ function registerZeroCommands(prog, commands) {
|
|
|
13301
13429
|
var program = new Command();
|
|
13302
13430
|
program.name("zero").description(
|
|
13303
13431
|
"Zero CLI \u2014 interact with the zero platform from inside the sandbox"
|
|
13304
|
-
).version("9.
|
|
13432
|
+
).version("9.180.0").addHelpText("after", () => {
|
|
13305
13433
|
return buildZeroHelpText();
|
|
13306
13434
|
});
|
|
13307
13435
|
if (process.argv[1]?.endsWith("zero.js") || process.argv[1]?.endsWith("zero.ts") || process.argv[1]?.endsWith("zero")) {
|