@paybond/kit 0.11.10 → 0.12.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/README.md +2 -2
- package/completion-presets/catalog.json +374 -3
- package/completion-presets/catalog.sha256 +1 -1
- package/dist/agent/facade.js +13 -0
- package/dist/agent/guarded-agent.d.ts +1 -1
- package/dist/agent/guarded-agent.js +19 -0
- package/dist/agent/index.d.ts +2 -1
- package/dist/agent/index.js +1 -0
- package/dist/agent/instrument.d.ts +6 -0
- package/dist/agent/instrument.js +6 -0
- package/dist/agent/interceptor.d.ts +9 -0
- package/dist/agent/interceptor.js +177 -1
- package/dist/agent/receipt-client.d.ts +49 -0
- package/dist/agent/receipt-client.js +45 -0
- package/dist/agent/registry.js +1 -0
- package/dist/agent/run.d.ts +2 -0
- package/dist/agent/run.js +52 -0
- package/dist/agent/types.d.ts +70 -0
- package/dist/agent-receipt-external-attestations.d.ts +29 -0
- package/dist/agent-receipt-external-attestations.js +124 -0
- package/dist/agent-receipt.d.ts +134 -0
- package/dist/agent-receipt.js +580 -0
- package/dist/agent-recognition.d.ts +25 -0
- package/dist/agent-recognition.js +36 -0
- package/dist/audit/exports.d.ts +72 -0
- package/dist/audit/exports.js +185 -0
- package/dist/audit/index.d.ts +3 -0
- package/dist/audit/index.js +3 -0
- package/dist/audit/verify.d.ts +8 -0
- package/dist/audit/verify.js +113 -0
- package/dist/audit/wire.d.ts +54 -0
- package/dist/audit/wire.js +80 -0
- package/dist/cli/agent/demo-loaders.d.ts +2 -0
- package/dist/cli/agent/demo-loaders.js +24 -0
- package/dist/cli/agent/production-evidence.d.ts +11 -0
- package/dist/cli/agent/production-evidence.js +17 -0
- package/dist/cli/audit-export.d.ts +2 -7
- package/dist/cli/audit-export.js +2 -120
- package/dist/cli/command-spec.js +43 -10
- package/dist/cli/commands/agent.d.ts +3 -0
- package/dist/cli/commands/agent.js +143 -1
- package/dist/cli/commands/discovery.js +39 -36
- package/dist/cli/commands/workflows.js +116 -18
- package/dist/cli/help.d.ts +1 -1
- package/dist/cli/help.js +12 -8
- package/dist/cli/intents-harbor-mutation.d.ts +18 -0
- package/dist/cli/intents-harbor-mutation.js +33 -0
- package/dist/cli/paybond.d.ts +9 -0
- package/dist/cli/paybond.js +23 -0
- package/dist/cli/redact.js +3 -0
- package/dist/cloudflare-agents/config.d.ts +24 -0
- package/dist/cloudflare-agents/config.js +23 -0
- package/dist/cloudflare-agents/index.d.ts +3 -0
- package/dist/cloudflare-agents/index.js +3 -0
- package/dist/cloudflare-agents/peer.d.ts +9 -0
- package/dist/cloudflare-agents/peer.js +20 -0
- package/dist/cloudflare-agents/sandbox-demo.d.ts +36 -0
- package/dist/cloudflare-agents/sandbox-demo.js +89 -0
- package/dist/completion-catalog-digest.d.ts +1 -1
- package/dist/completion-catalog-digest.js +1 -1
- package/dist/completion-init.js +8 -3
- package/dist/dev/offline-gateway.d.ts +2 -1
- package/dist/dev/offline-gateway.js +34 -3
- package/dist/dev/x402-fund-mock.d.ts +28 -0
- package/dist/dev/x402-fund-mock.js +124 -0
- package/dist/index.d.ts +125 -9
- package/dist/index.js +264 -17
- package/dist/init.js +113 -2
- package/dist/mastra/config.d.ts +30 -0
- package/dist/mastra/config.js +58 -0
- package/dist/mastra/index.d.ts +2 -0
- package/dist/mastra/index.js +2 -0
- package/dist/mastra/peer.d.ts +11 -0
- package/dist/mastra/peer.js +24 -0
- package/dist/mastra/sandbox-demo.d.ts +36 -0
- package/dist/mastra/sandbox-demo.js +87 -0
- package/dist/mcp/index.d.ts +1 -0
- package/dist/mcp/index.js +1 -0
- package/dist/mcp/sandbox-demo.d.ts +38 -0
- package/dist/mcp/sandbox-demo.js +112 -0
- package/dist/mcp-receipt-resource.d.ts +10 -0
- package/dist/mcp-receipt-resource.js +32 -0
- package/dist/mcp-server.d.ts +6 -0
- package/dist/mcp-server.js +124 -1
- package/dist/mpp-commercial.d.ts +19 -0
- package/dist/mpp-commercial.js +34 -0
- package/dist/mpp-funding.d.ts +71 -0
- package/dist/mpp-funding.js +192 -0
- package/dist/payment-transport.d.ts +30 -0
- package/dist/payment-transport.js +56 -0
- package/dist/policy/init.js +2 -0
- package/dist/policy/intent-spec.js +2 -0
- package/dist/principal-intent.d.ts +1 -1
- package/dist/principal-intent.js +4 -1
- package/dist/project-init.js +8 -0
- package/dist/template-init.d.ts +2 -2
- package/dist/template-init.js +6 -2
- package/dist/x402-funding.d.ts +52 -0
- package/dist/x402-funding.js +124 -0
- package/package.json +20 -2
- package/templates/manifest.json +28 -9
- package/templates/openai-shopping-agent/package-lock.json +16 -8
- package/templates/openai-shopping-agent/package.json +1 -1
- package/templates/paybond-aws-operator/package-lock.json +13 -5
- package/templates/paybond-aws-operator/package.json +1 -1
- package/templates/paybond-claude-agents-demo/package-lock.json +16 -8
- package/templates/paybond-claude-agents-demo/package.json +1 -1
- package/templates/paybond-invoice-agent/requirements.txt +1 -1
- package/templates/paybond-mastra-travel-agent/.env.example +3 -0
- package/templates/paybond-mastra-travel-agent/.github/workflows/smoke.yml +20 -0
- package/templates/paybond-mastra-travel-agent/LICENSE +201 -0
- package/templates/paybond-mastra-travel-agent/README.md +29 -0
- package/templates/paybond-mastra-travel-agent/package-lock.json +3377 -0
- package/templates/paybond-mastra-travel-agent/package.json +22 -0
- package/templates/paybond-mastra-travel-agent/paybond.policy.yaml +22 -0
- package/templates/paybond-mastra-travel-agent/src/index.ts +22 -0
- package/templates/paybond-mastra-travel-agent/src/paybond.config.ts +51 -0
- package/templates/paybond-mastra-travel-agent/tsconfig.json +13 -0
- package/templates/paybond-mcp-coding-agent/package-lock.json +13 -5
- package/templates/paybond-mcp-coding-agent/package.json +1 -1
- package/templates/paybond-openai-agents-demo/package-lock.json +16 -8
- package/templates/paybond-openai-agents-demo/package.json +1 -1
- package/templates/paybond-procurement-agent/package-lock.json +13 -5
- package/templates/paybond-procurement-agent/package.json +1 -1
- package/templates/paybond-travel-agent/package-lock.json +16 -8
- package/templates/paybond-travel-agent/package.json +1 -1
- package/templates/paybond-vercel-shopping-agent/package-lock.json +13 -5
- package/templates/paybond-vercel-shopping-agent/package.json +1 -1
package/dist/cli/audit-export.js
CHANGED
|
@@ -1,120 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import { spawn } from "node:child_process";
|
|
4
|
-
import { verify as ed25519Verify } from "@noble/ed25519";
|
|
5
|
-
import { ensureEd25519Sha512Sync } from "../ed25519-sync.js";
|
|
6
|
-
import { CliError } from "./types.js";
|
|
7
|
-
export const MANIFEST_CORE_FIELD_ORDER = [
|
|
8
|
-
"schema_version",
|
|
9
|
-
"kind",
|
|
10
|
-
"tenant_realm_id",
|
|
11
|
-
"job_id",
|
|
12
|
-
"generated_at_rfc3339",
|
|
13
|
-
"gateway_build_version",
|
|
14
|
-
"score_model_version",
|
|
15
|
-
"disclosure_tier",
|
|
16
|
-
"redaction_profile",
|
|
17
|
-
"checkpoint_last_ledger_seq",
|
|
18
|
-
"export_filter",
|
|
19
|
-
"artifacts",
|
|
20
|
-
];
|
|
21
|
-
export function buildManifestCore(manifest) {
|
|
22
|
-
const core = {};
|
|
23
|
-
for (const key of MANIFEST_CORE_FIELD_ORDER) {
|
|
24
|
-
if (key === "checkpoint_last_ledger_seq") {
|
|
25
|
-
if (!(key in manifest)) {
|
|
26
|
-
continue;
|
|
27
|
-
}
|
|
28
|
-
const value = manifest[key];
|
|
29
|
-
if (value === 0 || value === null) {
|
|
30
|
-
continue;
|
|
31
|
-
}
|
|
32
|
-
core[key] = value;
|
|
33
|
-
continue;
|
|
34
|
-
}
|
|
35
|
-
if (key in manifest) {
|
|
36
|
-
core[key] = manifest[key];
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
return core;
|
|
40
|
-
}
|
|
41
|
-
export function manifestCoreBytes(manifest) {
|
|
42
|
-
const core = buildManifestCore(manifest);
|
|
43
|
-
return new TextEncoder().encode(JSON.stringify(core));
|
|
44
|
-
}
|
|
45
|
-
function hexToBytes(hex) {
|
|
46
|
-
const normalized = hex.trim();
|
|
47
|
-
const out = new Uint8Array(normalized.length / 2);
|
|
48
|
-
for (let i = 0; i < out.length; i += 1) {
|
|
49
|
-
out[i] = Number.parseInt(normalized.slice(i * 2, i * 2 + 2), 16);
|
|
50
|
-
}
|
|
51
|
-
return out;
|
|
52
|
-
}
|
|
53
|
-
function bytesToHex(bytes) {
|
|
54
|
-
return Array.from(bytes)
|
|
55
|
-
.map((byte) => byte.toString(16).padStart(2, "0"))
|
|
56
|
-
.join("");
|
|
57
|
-
}
|
|
58
|
-
export function verifyAuditManifest(manifest) {
|
|
59
|
-
const coreBytes = manifestCoreBytes(manifest);
|
|
60
|
-
const digest = createHash("sha256").update(coreBytes).digest();
|
|
61
|
-
const expected = String(manifest.signed_payload_sha256_hex ?? "").trim().toLowerCase();
|
|
62
|
-
if (bytesToHex(new Uint8Array(digest)) !== expected) {
|
|
63
|
-
return false;
|
|
64
|
-
}
|
|
65
|
-
const signatureHex = String(manifest.ed25519_signature_hex ?? "").trim();
|
|
66
|
-
const publicKeyHex = String(manifest.signing_public_key_ed25519_hex ?? "").trim();
|
|
67
|
-
if (!signatureHex || !publicKeyHex) {
|
|
68
|
-
return false;
|
|
69
|
-
}
|
|
70
|
-
ensureEd25519Sha512Sync();
|
|
71
|
-
return ed25519Verify(hexToBytes(signatureHex), digest, hexToBytes(publicKeyHex));
|
|
72
|
-
}
|
|
73
|
-
export function auditVerifyResult(manifest, path) {
|
|
74
|
-
return {
|
|
75
|
-
verified: verifyAuditManifest(manifest),
|
|
76
|
-
manifest_kind: String(manifest.kind ?? ""),
|
|
77
|
-
tenant_realm_id: String(manifest.tenant_realm_id ?? ""),
|
|
78
|
-
job_id: String(manifest.job_id ?? ""),
|
|
79
|
-
path,
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
export async function readManifestFromBundle(bundlePath, cwd) {
|
|
83
|
-
if (bundlePath.endsWith(".zip")) {
|
|
84
|
-
const result = await new Promise((resolvePromise) => {
|
|
85
|
-
const child = spawn("unzip", ["-p", bundlePath, "manifest.json"], { cwd });
|
|
86
|
-
let stdout = "";
|
|
87
|
-
let stderr = "";
|
|
88
|
-
child.stdout.on("data", (chunk) => {
|
|
89
|
-
stdout += String(chunk);
|
|
90
|
-
});
|
|
91
|
-
child.stderr.on("data", (chunk) => {
|
|
92
|
-
stderr += String(chunk);
|
|
93
|
-
});
|
|
94
|
-
child.on("close", (code) => resolvePromise({ code, stdout, stderr }));
|
|
95
|
-
child.on("error", () => resolvePromise({ code: 127, stdout: "", stderr: "unzip not found" }));
|
|
96
|
-
});
|
|
97
|
-
if (result.code !== 0 || !result.stdout.trim()) {
|
|
98
|
-
throw new CliError(result.stderr.trim() || "unable to read manifest.json from ZIP bundle", {
|
|
99
|
-
category: "validation",
|
|
100
|
-
code: "cli.audit.bundle_read_failed",
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
return result.stdout;
|
|
104
|
-
}
|
|
105
|
-
const manifestPath = bundlePath.endsWith("manifest.json")
|
|
106
|
-
? bundlePath
|
|
107
|
-
: `${bundlePath.replace(/\/+$/, "")}/manifest.json`;
|
|
108
|
-
return readFile(manifestPath, "utf8");
|
|
109
|
-
}
|
|
110
|
-
export async function verifyAuditBundleLocal(path, cwd) {
|
|
111
|
-
const manifestRaw = await readManifestFromBundle(path, cwd);
|
|
112
|
-
const manifest = JSON.parse(manifestRaw);
|
|
113
|
-
if (!manifest || typeof manifest !== "object" || Array.isArray(manifest)) {
|
|
114
|
-
throw new CliError("manifest.json must be a JSON object", {
|
|
115
|
-
category: "validation",
|
|
116
|
-
code: "cli.audit.invalid_manifest",
|
|
117
|
-
});
|
|
118
|
-
}
|
|
119
|
-
return auditVerifyResult(manifest, path);
|
|
120
|
-
}
|
|
1
|
+
/** @deprecated Import from `../audit/verify.js` instead. */
|
|
2
|
+
export { auditVerifyResult, buildManifestCore, manifestCoreBytes, readManifestFromBundle, verifyAuditBundleLocal, verifyAuditManifest, MANIFEST_CORE_FIELD_ORDER, } from "../audit/verify.js";
|
package/dist/cli/command-spec.js
CHANGED
|
@@ -73,7 +73,11 @@ export const COMMAND_PATHS = [
|
|
|
73
73
|
"agent demo langgraph smoke",
|
|
74
74
|
"agent demo generic smoke",
|
|
75
75
|
"agent demo claude-agents smoke",
|
|
76
|
+
"agent demo crewai smoke",
|
|
76
77
|
"agent demo openai-agents smoke",
|
|
78
|
+
"agent demo mastra smoke",
|
|
79
|
+
"agent demo cloudflare-agents smoke",
|
|
80
|
+
"agent demo mcp smoke",
|
|
77
81
|
"audit exports list",
|
|
78
82
|
"audit exports get",
|
|
79
83
|
"audit exports verify",
|
|
@@ -292,10 +296,12 @@ export const COMMAND_EXAMPLES = {
|
|
|
292
296
|
"paybond signal fraud --did did:example:alice"
|
|
293
297
|
],
|
|
294
298
|
"receipts get": [
|
|
295
|
-
"paybond receipts get receipt-123"
|
|
299
|
+
"paybond receipts get receipt-123",
|
|
300
|
+
"paybond receipts get sha256:abc... --kind agent --format json"
|
|
296
301
|
],
|
|
297
302
|
"receipts verify": [
|
|
298
|
-
"paybond receipts verify receipt-123"
|
|
303
|
+
"paybond receipts verify receipt-123",
|
|
304
|
+
"paybond receipts verify sha256:abc... --kind agent --format json"
|
|
299
305
|
],
|
|
300
306
|
"mandates verify": [
|
|
301
307
|
"paybond mandates verify --body mandate.json"
|
|
@@ -312,7 +318,10 @@ export const COMMAND_EXAMPLES = {
|
|
|
312
318
|
"init agent-middleware": [
|
|
313
319
|
"paybond init agent-middleware",
|
|
314
320
|
"paybond init agent-middleware --framework claude-agents --out paybond-claude-agents.ts",
|
|
315
|
-
"paybond init agent-middleware --framework
|
|
321
|
+
"paybond init agent-middleware --framework mastra --out paybond-mastra.ts",
|
|
322
|
+
"paybond init agent-middleware --framework cloudflare-agents --out paybond-cloudflare-agents.ts",
|
|
323
|
+
"paybond init agent-middleware --framework mcp --out paybond-mcp.ts",
|
|
324
|
+
"paybond init agent-middleware --framework crewai --out paybond_crewai.py"
|
|
316
325
|
],
|
|
317
326
|
"agent run bind": [
|
|
318
327
|
"paybond agent run bind --policy-file paybond.policy.yaml --format json",
|
|
@@ -361,9 +370,21 @@ export const COMMAND_EXAMPLES = {
|
|
|
361
370
|
"agent demo claude-agents smoke": [
|
|
362
371
|
"paybond agent demo claude-agents smoke --operation paid-tool --requested-spend-cents 100 --evidence-preset cost_and_completion --format json"
|
|
363
372
|
],
|
|
373
|
+
"agent demo crewai smoke": [
|
|
374
|
+
"paybond agent demo crewai smoke --operation procurement.submit_po --requested-spend-cents 12000 --evidence-preset cost_and_completion --format json"
|
|
375
|
+
],
|
|
364
376
|
"agent demo openai-agents smoke": [
|
|
365
377
|
"paybond agent demo openai-agents smoke --operation paid-tool --requested-spend-cents 100 --evidence-preset cost_and_completion --format json"
|
|
366
378
|
],
|
|
379
|
+
"agent demo mastra smoke": [
|
|
380
|
+
"paybond agent demo mastra smoke --operation paid-tool --requested-spend-cents 100 --evidence-preset cost_and_completion --format json"
|
|
381
|
+
],
|
|
382
|
+
"agent demo cloudflare-agents smoke": [
|
|
383
|
+
"paybond agent demo cloudflare-agents smoke --operation paid-tool --requested-spend-cents 100 --evidence-preset cost_and_completion --format json"
|
|
384
|
+
],
|
|
385
|
+
"agent demo mcp smoke": [
|
|
386
|
+
"paybond agent demo mcp smoke --operation paid-tool --requested-spend-cents 100 --evidence-preset cost_and_completion --format json"
|
|
387
|
+
],
|
|
367
388
|
"audit exports list": [
|
|
368
389
|
"paybond audit exports list --format json"
|
|
369
390
|
],
|
|
@@ -503,7 +524,10 @@ export const COMPLETIONS = {
|
|
|
503
524
|
"ach_vendor_webhook",
|
|
504
525
|
"x402_paid_api_ok",
|
|
505
526
|
"x402_delivery_receipt",
|
|
506
|
-
"x402_cost_and_completion"
|
|
527
|
+
"x402_cost_and_completion",
|
|
528
|
+
"x402_saas_api_purchase",
|
|
529
|
+
"x402_travel_booking",
|
|
530
|
+
"invoice_payment_confirmed"
|
|
507
531
|
],
|
|
508
532
|
"policy preview preset": [
|
|
509
533
|
"api_response_ok",
|
|
@@ -519,7 +543,10 @@ export const COMPLETIONS = {
|
|
|
519
543
|
"ach_vendor_webhook",
|
|
520
544
|
"x402_paid_api_ok",
|
|
521
545
|
"x402_delivery_receipt",
|
|
522
|
-
"x402_cost_and_completion"
|
|
546
|
+
"x402_cost_and_completion",
|
|
547
|
+
"x402_saas_api_purchase",
|
|
548
|
+
"x402_travel_booking",
|
|
549
|
+
"invoice_payment_confirmed"
|
|
523
550
|
],
|
|
524
551
|
"guardrails bootstrap completion-preset": [
|
|
525
552
|
"api_response_ok",
|
|
@@ -535,7 +562,10 @@ export const COMPLETIONS = {
|
|
|
535
562
|
"ach_vendor_webhook",
|
|
536
563
|
"x402_paid_api_ok",
|
|
537
564
|
"x402_delivery_receipt",
|
|
538
|
-
"x402_cost_and_completion"
|
|
565
|
+
"x402_cost_and_completion",
|
|
566
|
+
"x402_saas_api_purchase",
|
|
567
|
+
"x402_travel_booking",
|
|
568
|
+
"invoice_payment_confirmed"
|
|
539
569
|
]
|
|
540
570
|
};
|
|
541
571
|
export const COMPLETION_PRESET_IDS = [
|
|
@@ -552,7 +582,10 @@ export const COMPLETION_PRESET_IDS = [
|
|
|
552
582
|
"ach_vendor_webhook",
|
|
553
583
|
"x402_paid_api_ok",
|
|
554
584
|
"x402_delivery_receipt",
|
|
555
|
-
"x402_cost_and_completion"
|
|
585
|
+
"x402_cost_and_completion",
|
|
586
|
+
"x402_saas_api_purchase",
|
|
587
|
+
"x402_travel_booking",
|
|
588
|
+
"invoice_payment_confirmed"
|
|
556
589
|
];
|
|
557
590
|
export const WORKFLOWS = [
|
|
558
591
|
{
|
|
@@ -614,7 +647,7 @@ export const WORKFLOWS = [
|
|
|
614
647
|
];
|
|
615
648
|
export const DOCS_BASE_URL = "https://docs.paybond.ai/kit";
|
|
616
649
|
export const COMPLETION_SCRIPTS = {
|
|
617
|
-
"bash": "# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n_paybond_completion() {\n local cur prev words cword\n COMPREPLY=()\n cur=\"${COMP_WORDS[COMP_CWORD]}\"\n prev=\"${COMP_WORDS[COMP_CWORD-1]}\"\n\n if [[ $COMP_CWORD -eq 1 ]]; then\n COMPREPLY=($(compgen -W \"onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\" -- \"$cur\"))\n return 0\n fi\n\n case \"${COMP_WORDS[1]}\" in\n init) COMPREPLY=($(compgen -W \"guardrail completion agent-middleware\" -- \"$cur\")) ;;\n mcp) COMPREPLY=($(compgen -W \"serve install verify-config tools\" -- \"$cur\")) ;;\n dev) COMPREPLY=($(compgen -W \"smoke trace loop up\" -- \"$cur\")) ;;\n config) COMPREPLY=($(compgen -W \"get set unset list\" -- \"$cur\")) ;;\n keys) COMPREPLY=($(compgen -W \"list create rotate revoke\" -- \"$cur\")) ;;\n intents) COMPREPLY=($(compgen -W \"list get create fund evidence settlement-confirm\" -- \"$cur\")) ;;\n guardrails) COMPREPLY=($(compgen -W \"bootstrap evidence\" -- \"$cur\")) ;;\n spend) COMPREPLY=($(compgen -W \"authorize\" -- \"$cur\")) ;;\n signal) COMPREPLY=($(compgen -W \"reputation portfolio fraud\" -- \"$cur\")) ;;\n receipts) COMPREPLY=($(compgen -W \"get verify\" -- \"$cur\")) ;;\n mandates) COMPREPLY=($(compgen -W \"verify import\" -- \"$cur\")) ;;\n a2a) COMPREPLY=($(compgen -W \"card contracts\" -- \"$cur\")) ;;\n policy) COMPREPLY=($(compgen -W \"init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\" -- \"$cur\")) ;;\n agent) COMPREPLY=($(compgen -W \"run tool registry sandbox production\" -- \"$cur\")) ;;\n audit) COMPREPLY=($(compgen -W \"exports\" -- \"$cur\")) ;;\n completion) COMPREPLY=($(compgen -W \"bash zsh fish\" -- \"$cur\")) ;;\n init completion preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\" -- \"$cur\")) ;;\n policy preview preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\" -- \"$cur\")) ;;\n guardrails bootstrap completion-preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\" -- \"$cur\")) ;;\n *) ;;\n esac\n}\ncomplete -F _paybond_completion paybond\n",
|
|
618
|
-
"zsh": "#compdef paybond\n# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n\n_paybond() {\n local -a commands\n commands=(\n 'onboarding' 'help' 'examples' 'completion' 'login' 'init' 'mcp' 'doctor' 'dev' 'version' 'diagnose' 'config' 'whoami' 'keys' 'intents' 'guardrails' 'spend' 'signal' 'receipts' 'mandates' 'a2a' 'policy' 'audit' 'agent'\n )\n _arguments -C \\\n '(--gateway)--gateway[Gateway base URL]:url:' \\\n '(--env-file)--env-file[Local secrets file]:path:_files' \\\n '(--format)--format[Output format]:(table json)' \\\n '(--color)--color[Color mode]:(auto always never)' \\\n '--no-color[Disable color output]' \\\n '1: :->command' \\\n '*::arg:->args'\n\n case $state in\n command)\n _describe -t commands 'paybond commands' commands\n ;;\n args)\n case $words[1] in\n 'init:subcommand:(guardrail completion agent-middleware)'\n 'mcp:subcommand:(serve install verify-config tools)'\n 'dev:subcommand:(smoke trace loop up)'\n 'config:subcommand:(get set unset list)'\n 'keys:subcommand:(list create rotate revoke)'\n 'intents:subcommand:(list get create fund evidence settlement-confirm)'\n 'guardrails:subcommand:(bootstrap evidence)'\n 'spend:subcommand:(authorize)'\n 'signal:subcommand:(reputation portfolio fraud)'\n 'receipts:subcommand:(get verify)'\n 'mandates:subcommand:(verify import)'\n 'a2a:subcommand:(card contracts)'\n 'policy:subcommand:(init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence)'\n 'agent:subcommand:(run tool registry sandbox production)'\n 'audit:subcommand:(exports)'\n 'completion:subcommand:(bash zsh fish)'\n 'init completion preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion)'\n 'policy preview preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion)'\n 'guardrails bootstrap completion-preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion)'\n esac\n ;;\n esac\n}\n\ncompdef _paybond paybond\n",
|
|
619
|
-
"fish": "# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion\ncomplete -c paybond -f\ncomplete -c paybond -l gateway -d 'Gateway base URL'\ncomplete -c paybond -l env-file -d 'Local secrets file' -r\ncomplete -c paybond -l format -d 'Output format' -xa 'table json'\ncomplete -c paybond -l color -d 'Color mode' -xa 'auto always never'\ncomplete -c paybond -l no-color -d 'Disable color output'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'onboarding'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'help'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'examples'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'completion'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'login'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'init'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'mcp'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'doctor'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'dev'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'version'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'diagnose'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'config'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'whoami'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'keys'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'intents'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'guardrails'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'spend'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'signal'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'receipts'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'mandates'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'a2a'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'policy'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'audit'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'agent'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'guardrail'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'agent-middleware'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'serve'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'install'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'verify-config'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'tools'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'smoke'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'trace'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'loop'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'up'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'set'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'unset'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'create'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'rotate'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'revoke'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'create'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'fund'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'settlement-confirm'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails' -a 'bootstrap'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails' -a 'evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from spend' -a 'authorize'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'reputation'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'portfolio'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'fraud'\ncomplete -c paybond -n '__fish_seen_subcommand_from receipts' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from receipts' -a 'verify'\ncomplete -c paybond -n '__fish_seen_subcommand_from mandates' -a 'verify'\ncomplete -c paybond -n '__fish_seen_subcommand_from mandates' -a 'import'\ncomplete -c paybond -n '__fish_seen_subcommand_from a2a' -a 'card'\ncomplete -c paybond -n '__fish_seen_subcommand_from a2a' -a 'contracts'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'init'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'validate-tools'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'templates'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'preview'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'import-mcp-receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'import-x402-receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'validate-evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'run'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'tool'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'registry'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'sandbox'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'production'\ncomplete -c paybond -n '__fish_seen_subcommand_from audit' -a 'exports'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'bash'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'zsh'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'fish'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_cost_and_completion'\n"
|
|
650
|
+
"bash": "# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n_paybond_completion() {\n local cur prev words cword\n COMPREPLY=()\n cur=\"${COMP_WORDS[COMP_CWORD]}\"\n prev=\"${COMP_WORDS[COMP_CWORD-1]}\"\n\n if [[ $COMP_CWORD -eq 1 ]]; then\n COMPREPLY=($(compgen -W \"onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\" -- \"$cur\"))\n return 0\n fi\n\n case \"${COMP_WORDS[1]}\" in\n init) COMPREPLY=($(compgen -W \"guardrail completion agent-middleware\" -- \"$cur\")) ;;\n mcp) COMPREPLY=($(compgen -W \"serve install verify-config tools\" -- \"$cur\")) ;;\n dev) COMPREPLY=($(compgen -W \"smoke trace loop up\" -- \"$cur\")) ;;\n config) COMPREPLY=($(compgen -W \"get set unset list\" -- \"$cur\")) ;;\n keys) COMPREPLY=($(compgen -W \"list create rotate revoke\" -- \"$cur\")) ;;\n intents) COMPREPLY=($(compgen -W \"list get create fund evidence settlement-confirm\" -- \"$cur\")) ;;\n guardrails) COMPREPLY=($(compgen -W \"bootstrap evidence\" -- \"$cur\")) ;;\n spend) COMPREPLY=($(compgen -W \"authorize\" -- \"$cur\")) ;;\n signal) COMPREPLY=($(compgen -W \"reputation portfolio fraud\" -- \"$cur\")) ;;\n receipts) COMPREPLY=($(compgen -W \"get verify\" -- \"$cur\")) ;;\n mandates) COMPREPLY=($(compgen -W \"verify import\" -- \"$cur\")) ;;\n a2a) COMPREPLY=($(compgen -W \"card contracts\" -- \"$cur\")) ;;\n policy) COMPREPLY=($(compgen -W \"init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\" -- \"$cur\")) ;;\n agent) COMPREPLY=($(compgen -W \"run tool registry sandbox production\" -- \"$cur\")) ;;\n audit) COMPREPLY=($(compgen -W \"exports\" -- \"$cur\")) ;;\n completion) COMPREPLY=($(compgen -W \"bash zsh fish\" -- \"$cur\")) ;;\n init completion preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\" -- \"$cur\")) ;;\n policy preview preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\" -- \"$cur\")) ;;\n guardrails bootstrap completion-preset) COMPREPLY=($(compgen -W \"api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\" -- \"$cur\")) ;;\n *) ;;\n esac\n}\ncomplete -F _paybond_completion paybond\n",
|
|
651
|
+
"zsh": "#compdef paybond\n# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n\n_paybond() {\n local -a commands\n commands=(\n 'onboarding' 'help' 'examples' 'completion' 'login' 'init' 'mcp' 'doctor' 'dev' 'version' 'diagnose' 'config' 'whoami' 'keys' 'intents' 'guardrails' 'spend' 'signal' 'receipts' 'mandates' 'a2a' 'policy' 'audit' 'agent'\n )\n _arguments -C \\\n '(--gateway)--gateway[Gateway base URL]:url:' \\\n '(--env-file)--env-file[Local secrets file]:path:_files' \\\n '(--format)--format[Output format]:(table json)' \\\n '(--color)--color[Color mode]:(auto always never)' \\\n '--no-color[Disable color output]' \\\n '1: :->command' \\\n '*::arg:->args'\n\n case $state in\n command)\n _describe -t commands 'paybond commands' commands\n ;;\n args)\n case $words[1] in\n 'init:subcommand:(guardrail completion agent-middleware)'\n 'mcp:subcommand:(serve install verify-config tools)'\n 'dev:subcommand:(smoke trace loop up)'\n 'config:subcommand:(get set unset list)'\n 'keys:subcommand:(list create rotate revoke)'\n 'intents:subcommand:(list get create fund evidence settlement-confirm)'\n 'guardrails:subcommand:(bootstrap evidence)'\n 'spend:subcommand:(authorize)'\n 'signal:subcommand:(reputation portfolio fraud)'\n 'receipts:subcommand:(get verify)'\n 'mandates:subcommand:(verify import)'\n 'a2a:subcommand:(card contracts)'\n 'policy:subcommand:(init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence)'\n 'agent:subcommand:(run tool registry sandbox production)'\n 'audit:subcommand:(exports)'\n 'completion:subcommand:(bash zsh fish)'\n 'init completion preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed)'\n 'policy preview preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed)'\n 'guardrails bootstrap completion-preset:subcommand:(api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed)'\n esac\n ;;\n esac\n}\n\ncompdef _paybond paybond\n",
|
|
652
|
+
"fish": "# Generated by kit/cli-parity/generate.mjs — do not edit by hand.\n# # top_level: onboarding help examples completion login init mcp doctor dev version diagnose config whoami keys intents guardrails spend signal receipts mandates a2a policy audit agent\n# init: guardrail completion agent-middleware\n# mcp: serve install verify-config tools\n# dev: smoke trace loop up\n# config: get set unset list\n# keys: list create rotate revoke\n# intents: list get create fund evidence settlement-confirm\n# guardrails: bootstrap evidence\n# spend: authorize\n# signal: reputation portfolio fraud\n# receipts: get verify\n# mandates: verify import\n# a2a: card contracts\n# policy: init validate-tools templates preview import-mcp-receipt import-x402-receipt validate-evidence\n# agent: run tool registry sandbox production\n# audit: exports\n# completion: bash zsh fish\n# init completion preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# policy preview preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\n# guardrails bootstrap completion-preset: api_response_ok webhook_confirmed artifact_attested cost_and_completion sandbox_permissive stripe_charge vendor_webhook_confirmed stripe_webhook_payment ach_paid_api_ok ach_travel_booking ach_vendor_webhook x402_paid_api_ok x402_delivery_receipt x402_cost_and_completion x402_saas_api_purchase x402_travel_booking invoice_payment_confirmed\ncomplete -c paybond -f\ncomplete -c paybond -l gateway -d 'Gateway base URL'\ncomplete -c paybond -l env-file -d 'Local secrets file' -r\ncomplete -c paybond -l format -d 'Output format' -xa 'table json'\ncomplete -c paybond -l color -d 'Color mode' -xa 'auto always never'\ncomplete -c paybond -l no-color -d 'Disable color output'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'onboarding'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'help'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'examples'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'completion'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'login'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'init'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'mcp'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'doctor'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'dev'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'version'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'diagnose'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'config'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'whoami'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'keys'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'intents'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'guardrails'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'spend'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'signal'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'receipts'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'mandates'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'a2a'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'policy'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'audit'\ncomplete -c paybond -n '__fish_use_subcommand' -a 'agent'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'guardrail'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from init' -a 'agent-middleware'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'serve'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'install'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'verify-config'\ncomplete -c paybond -n '__fish_seen_subcommand_from mcp' -a 'tools'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'smoke'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'trace'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'loop'\ncomplete -c paybond -n '__fish_seen_subcommand_from dev' -a 'up'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'set'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'unset'\ncomplete -c paybond -n '__fish_seen_subcommand_from config' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'create'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'rotate'\ncomplete -c paybond -n '__fish_seen_subcommand_from keys' -a 'revoke'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'list'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'create'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'fund'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from intents' -a 'settlement-confirm'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails' -a 'bootstrap'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails' -a 'evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from spend' -a 'authorize'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'reputation'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'portfolio'\ncomplete -c paybond -n '__fish_seen_subcommand_from signal' -a 'fraud'\ncomplete -c paybond -n '__fish_seen_subcommand_from receipts' -a 'get'\ncomplete -c paybond -n '__fish_seen_subcommand_from receipts' -a 'verify'\ncomplete -c paybond -n '__fish_seen_subcommand_from mandates' -a 'verify'\ncomplete -c paybond -n '__fish_seen_subcommand_from mandates' -a 'import'\ncomplete -c paybond -n '__fish_seen_subcommand_from a2a' -a 'card'\ncomplete -c paybond -n '__fish_seen_subcommand_from a2a' -a 'contracts'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'init'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'validate-tools'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'templates'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'preview'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'import-mcp-receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'import-x402-receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy' -a 'validate-evidence'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'run'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'tool'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'registry'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'sandbox'\ncomplete -c paybond -n '__fish_seen_subcommand_from agent' -a 'production'\ncomplete -c paybond -n '__fish_seen_subcommand_from audit' -a 'exports'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'bash'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'zsh'\ncomplete -c paybond -n '__fish_seen_subcommand_from completion' -a 'fish'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_saas_api_purchase'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'x402_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from init completion preset' -a 'invoice_payment_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_saas_api_purchase'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'x402_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from policy preview preset' -a 'invoice_payment_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'api_response_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'artifact_attested'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'sandbox_permissive'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'stripe_charge'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'vendor_webhook_confirmed'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'stripe_webhook_payment'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'ach_vendor_webhook'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_paid_api_ok'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_delivery_receipt'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_cost_and_completion'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_saas_api_purchase'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'x402_travel_booking'\ncomplete -c paybond -n '__fish_seen_subcommand_from guardrails bootstrap completion-preset' -a 'invoice_payment_confirmed'\n"
|
|
620
653
|
};
|
|
@@ -13,6 +13,9 @@ export declare function handleAgentProductionAttachSmoke(ctx: CliContext, argv:
|
|
|
13
13
|
export declare function handleAgentDemoVercelAiSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
14
14
|
export declare function handleAgentDemoLanggraphSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
15
15
|
export declare function handleAgentDemoGenericSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
16
|
+
export declare function handleAgentDemoMastraSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
17
|
+
export declare function handleAgentDemoCloudflareAgentsSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
16
18
|
export declare function handleAgentDemoClaudeAgentsSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
19
|
+
export declare function handleAgentDemoMcpSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
17
20
|
export declare function handleAgentDemoOpenAIAgentsSmoke(ctx: CliContext, argv: string[]): Promise<CommandResult>;
|
|
18
21
|
export declare function handleAgent(ctx: CliContext, group: string, subcommand: string, argv: string[]): Promise<CommandResult>;
|
|
@@ -4,7 +4,8 @@ import { PaybondAgentRun } from "../../agent/run.js";
|
|
|
4
4
|
import { PaybondAutoEvidenceSubmitError, PaybondToolRegistryValidationError, PaybondUnregisteredSideEffectingToolError, } from "../../agent/types.js";
|
|
5
5
|
import { resolveCliGatewayErrorMessage } from "../http-error-message.js";
|
|
6
6
|
import { runGenericSandboxDemo } from "../../agent/generic-sandbox-demo.js";
|
|
7
|
-
import {
|
|
7
|
+
import { runMcpSandboxDemo } from "../../mcp/sandbox-demo.js";
|
|
8
|
+
import { loadRunClaudeAgentsSandboxDemo, loadRunCloudflareAgentsSandboxDemo, loadRunLangGraphSandboxDemo, loadRunMastraSandboxDemo, loadRunOpenAIAgentsSandboxDemo, loadRunVercelAiSandboxDemo, } from "../agent/demo-loaders.js";
|
|
8
9
|
import { buildSmokeRegistry, loadAgentRegistryFile, validateAgentRegistryDocument, } from "../../agent/registry-file.js";
|
|
9
10
|
import { createPaybondToolRegistry } from "../../agent/registry.js";
|
|
10
11
|
import { devTraceStepsFromEvents, devTraceUrl, findDevTraceEventForRun, resolveDevTraceSink, recordSmokeTraceEvent, } from "../../dev/trace-buffer.js";
|
|
@@ -1128,6 +1129,80 @@ export async function handleAgentDemoGenericSmoke(ctx, argv) {
|
|
|
1128
1129
|
};
|
|
1129
1130
|
});
|
|
1130
1131
|
}
|
|
1132
|
+
export async function handleAgentDemoMastraSmoke(ctx, argv) {
|
|
1133
|
+
const productionFlag = consumeBooleanFlag(argv, "--production");
|
|
1134
|
+
const operationFlag = consumeFlag(productionFlag.rest, "--operation");
|
|
1135
|
+
const spendFlag = consumeFlag(operationFlag.rest, "--requested-spend-cents");
|
|
1136
|
+
const presetFlag = consumeFlag(spendFlag.rest, "--evidence-preset");
|
|
1137
|
+
if (!operationFlag.value || !spendFlag.value || !presetFlag.value) {
|
|
1138
|
+
throw agentCliError("agent demo mastra smoke requires --operation, --requested-spend-cents, and --evidence-preset", { code: "cli.usage.missing_args", category: "usage" });
|
|
1139
|
+
}
|
|
1140
|
+
const requestedSpendCents = parseRequiredNonNegativeInt(spendFlag.value, "--requested-spend-cents");
|
|
1141
|
+
return withPaybondAgentCli(ctx, productionFlag.present, async (session) => {
|
|
1142
|
+
const runMastraSandboxDemo = await loadRunMastraSandboxDemo();
|
|
1143
|
+
const demo = await runMastraSandboxDemo({
|
|
1144
|
+
paybond: session.paybond,
|
|
1145
|
+
operation: operationFlag.value,
|
|
1146
|
+
requestedSpendCents,
|
|
1147
|
+
evidencePreset: presetFlag.value,
|
|
1148
|
+
});
|
|
1149
|
+
if (!demo.authorization.allow) {
|
|
1150
|
+
throw agentCliError("Mastra sandbox demo authorization did not pass", {
|
|
1151
|
+
code: "cli.agent.authorization_denied",
|
|
1152
|
+
exitCode: 3,
|
|
1153
|
+
category: "forbidden",
|
|
1154
|
+
details: { authorization: demo.authorization },
|
|
1155
|
+
});
|
|
1156
|
+
}
|
|
1157
|
+
if (!demo.execute.tool_result) {
|
|
1158
|
+
throw agentCliError("Mastra sandbox demo did not produce a paid tool result", {
|
|
1159
|
+
code: "cli.agent.tool_execute_failed",
|
|
1160
|
+
details: { execute: demo.execute },
|
|
1161
|
+
});
|
|
1162
|
+
}
|
|
1163
|
+
return {
|
|
1164
|
+
data: demo,
|
|
1165
|
+
warnings: session.warnings,
|
|
1166
|
+
};
|
|
1167
|
+
});
|
|
1168
|
+
}
|
|
1169
|
+
export async function handleAgentDemoCloudflareAgentsSmoke(ctx, argv) {
|
|
1170
|
+
const productionFlag = consumeBooleanFlag(argv, "--production");
|
|
1171
|
+
const operationFlag = consumeFlag(productionFlag.rest, "--operation");
|
|
1172
|
+
const spendFlag = consumeFlag(operationFlag.rest, "--requested-spend-cents");
|
|
1173
|
+
const presetFlag = consumeFlag(spendFlag.rest, "--evidence-preset");
|
|
1174
|
+
if (!operationFlag.value || !spendFlag.value || !presetFlag.value) {
|
|
1175
|
+
throw agentCliError("agent demo cloudflare-agents smoke requires --operation, --requested-spend-cents, and --evidence-preset", { code: "cli.usage.missing_args", category: "usage" });
|
|
1176
|
+
}
|
|
1177
|
+
const requestedSpendCents = parseRequiredNonNegativeInt(spendFlag.value, "--requested-spend-cents");
|
|
1178
|
+
return withPaybondAgentCli(ctx, productionFlag.present, async (session) => {
|
|
1179
|
+
const runCloudflareAgentsSandboxDemo = await loadRunCloudflareAgentsSandboxDemo();
|
|
1180
|
+
const demo = await runCloudflareAgentsSandboxDemo({
|
|
1181
|
+
paybond: session.paybond,
|
|
1182
|
+
operation: operationFlag.value,
|
|
1183
|
+
requestedSpendCents,
|
|
1184
|
+
evidencePreset: presetFlag.value,
|
|
1185
|
+
});
|
|
1186
|
+
if (!demo.authorization.allow) {
|
|
1187
|
+
throw agentCliError("Cloudflare Agents sandbox demo authorization did not pass", {
|
|
1188
|
+
code: "cli.agent.authorization_denied",
|
|
1189
|
+
exitCode: 3,
|
|
1190
|
+
category: "forbidden",
|
|
1191
|
+
details: { authorization: demo.authorization },
|
|
1192
|
+
});
|
|
1193
|
+
}
|
|
1194
|
+
if (!demo.execute.tool_result) {
|
|
1195
|
+
throw agentCliError("Cloudflare Agents sandbox demo did not produce a paid tool result", {
|
|
1196
|
+
code: "cli.agent.tool_execute_failed",
|
|
1197
|
+
details: { execute: demo.execute },
|
|
1198
|
+
});
|
|
1199
|
+
}
|
|
1200
|
+
return {
|
|
1201
|
+
data: demo,
|
|
1202
|
+
warnings: session.warnings,
|
|
1203
|
+
};
|
|
1204
|
+
});
|
|
1205
|
+
}
|
|
1131
1206
|
export async function handleAgentDemoClaudeAgentsSmoke(ctx, argv) {
|
|
1132
1207
|
const productionFlag = consumeBooleanFlag(argv, "--production");
|
|
1133
1208
|
const runtimeFlag = consumeFlag(productionFlag.rest, "--runtime");
|
|
@@ -1170,6 +1245,46 @@ export async function handleAgentDemoClaudeAgentsSmoke(ctx, argv) {
|
|
|
1170
1245
|
};
|
|
1171
1246
|
});
|
|
1172
1247
|
}
|
|
1248
|
+
export async function handleAgentDemoMcpSmoke(ctx, argv) {
|
|
1249
|
+
const productionFlag = consumeBooleanFlag(argv, "--production");
|
|
1250
|
+
const operationFlag = consumeFlag(productionFlag.rest, "--operation");
|
|
1251
|
+
const spendFlag = consumeFlag(operationFlag.rest, "--requested-spend-cents");
|
|
1252
|
+
const presetFlag = consumeFlag(spendFlag.rest, "--evidence-preset");
|
|
1253
|
+
if (!operationFlag.value || !spendFlag.value || !presetFlag.value) {
|
|
1254
|
+
throw agentCliError("agent demo mcp smoke requires --operation, --requested-spend-cents, and --evidence-preset", { code: "cli.usage.missing_args", category: "usage" });
|
|
1255
|
+
}
|
|
1256
|
+
const requestedSpendCents = parseRequiredNonNegativeInt(spendFlag.value, "--requested-spend-cents");
|
|
1257
|
+
return withPaybondAgentCli(ctx, productionFlag.present, async (session) => {
|
|
1258
|
+
const demo = await runMcpSandboxDemo({
|
|
1259
|
+
paybond: session.paybond,
|
|
1260
|
+
apiKey: session.apiKey,
|
|
1261
|
+
gatewayBaseUrl: ctx.globals.gateway,
|
|
1262
|
+
operation: operationFlag.value,
|
|
1263
|
+
requestedSpendCents,
|
|
1264
|
+
evidencePreset: presetFlag.value,
|
|
1265
|
+
});
|
|
1266
|
+
if (!demo.authorization.allow) {
|
|
1267
|
+
throw agentCliError("MCP sandbox demo authorization did not pass", {
|
|
1268
|
+
code: "cli.agent.authorization_denied",
|
|
1269
|
+
exitCode: 3,
|
|
1270
|
+
category: "forbidden",
|
|
1271
|
+
details: { authorization: demo.authorization },
|
|
1272
|
+
});
|
|
1273
|
+
}
|
|
1274
|
+
if (!demo.evidence.submitted) {
|
|
1275
|
+
throw agentCliError("MCP sandbox demo did not submit evidence", {
|
|
1276
|
+
code: "cli.agent.evidence_failed",
|
|
1277
|
+
exitCode: 5,
|
|
1278
|
+
category: "gateway",
|
|
1279
|
+
details: { tool_result: demo.tool_result },
|
|
1280
|
+
});
|
|
1281
|
+
}
|
|
1282
|
+
return {
|
|
1283
|
+
data: demo,
|
|
1284
|
+
warnings: session.warnings,
|
|
1285
|
+
};
|
|
1286
|
+
});
|
|
1287
|
+
}
|
|
1173
1288
|
export async function handleAgentDemoOpenAIAgentsSmoke(ctx, argv) {
|
|
1174
1289
|
const productionFlag = consumeBooleanFlag(argv, "--production");
|
|
1175
1290
|
const operationFlag = consumeFlag(productionFlag.rest, "--operation");
|
|
@@ -1351,6 +1466,33 @@ export async function handleAgent(ctx, group, subcommand, argv) {
|
|
|
1351
1466
|
}
|
|
1352
1467
|
return handleAgentDemoOpenAIAgentsSmoke(ctx, argv.slice(1));
|
|
1353
1468
|
}
|
|
1469
|
+
if (group === "demo" && subcommand === "mcp") {
|
|
1470
|
+
if (argv[0] !== "smoke") {
|
|
1471
|
+
throw agentCliError("agent demo mcp requires smoke subcommand", {
|
|
1472
|
+
code: "cli.usage.unknown_command",
|
|
1473
|
+
category: "usage",
|
|
1474
|
+
});
|
|
1475
|
+
}
|
|
1476
|
+
return handleAgentDemoMcpSmoke(ctx, argv.slice(1));
|
|
1477
|
+
}
|
|
1478
|
+
if (group === "demo" && subcommand === "mastra") {
|
|
1479
|
+
if (argv[0] !== "smoke") {
|
|
1480
|
+
throw agentCliError("agent demo mastra requires smoke subcommand", {
|
|
1481
|
+
code: "cli.usage.unknown_command",
|
|
1482
|
+
category: "usage",
|
|
1483
|
+
});
|
|
1484
|
+
}
|
|
1485
|
+
return handleAgentDemoMastraSmoke(ctx, argv.slice(1));
|
|
1486
|
+
}
|
|
1487
|
+
if (group === "demo" && subcommand === "cloudflare-agents") {
|
|
1488
|
+
if (argv[0] !== "smoke") {
|
|
1489
|
+
throw agentCliError("agent demo cloudflare-agents requires smoke subcommand", {
|
|
1490
|
+
code: "cli.usage.unknown_command",
|
|
1491
|
+
category: "usage",
|
|
1492
|
+
});
|
|
1493
|
+
}
|
|
1494
|
+
return handleAgentDemoCloudflareAgentsSmoke(ctx, argv.slice(1));
|
|
1495
|
+
}
|
|
1354
1496
|
throw agentCliError(`unknown agent subcommand: agent ${group} ${subcommand}`, {
|
|
1355
1497
|
code: "cli.usage.unknown_command",
|
|
1356
1498
|
category: "usage",
|