vapi-network 0.7.0 → 0.8.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 CHANGED
@@ -41,6 +41,7 @@ Turn on encrypted cloud backup with `vapi backup --cloud`; only the owner can ap
41
41
  | Call | Discover, check, publish and pay for x402 APIs. | [docs/call.md](./docs/call.md) |
42
42
  | Router | Use vAPI Router for model access and balance. | [docs/router.md](./docs/router.md) |
43
43
  | Agents | Run capped local agents with dedicated wallets and profiles. | [docs/agents.md](./docs/agents.md) |
44
+ | Swarms | Group capped local agents around a treasury and capital policy. | [docs/swarms.md](./docs/swarms.md) |
44
45
  | MCP | Use namespaced payment tools from an MCP client. | [docs/mcp.md](./docs/mcp.md) |
45
46
  | SDK | Use Call, vAPI Router and local agents behind one wallet-bound API. | [docs/sdk.md](./docs/sdk.md) |
46
47
  | Vault | Manage the owner wallet, device vault, accounts and spend caps. | [docs/wallets.md](./docs/wallets.md) |
@@ -48,7 +49,40 @@ Turn on encrypted cloud backup with `vapi backup --cloud`; only the owner can ap
48
49
 
49
50
  Wallets and custody are in [docs/wallets.md](./docs/wallets.md), and account transfers are in [docs/sending.md](./docs/sending.md). Configuration, funding, networks and bug reports are in [docs/configuration.md](./docs/configuration.md).
50
51
 
51
- The MCP server registers `vapi.status`, `vapi.accounts`, `vapi.siblings`, `accounts.add`, `accounts.caps`, `accounts.send`, `auth.link`, `auth.status`, `router.models`, `router.usage`, `router.chat`, `router.buy`, `call.search`, `call.inspect`, `call.pay`, `wallet.address`, `wallet.balance`, `wallet.accounts`, `wallet.list`, `wallet.use`, `wallet.fund`, `receipts.list`, `receipts.stats`, `support.report`; inputs and results are in [docs/mcp.md](./docs/mcp.md).
52
+ The MCP server registers `vapi.status`, `vapi.accounts`, `vapi.siblings`, `accounts.add`, `accounts.caps`, `accounts.send`, `auth.link`, `auth.status`, `router.models`, `router.usage`, `router.chat`, `router.buy`, `call.search`, `call.inspect`, `call.pay`, `call.read`, `swarm.setup`, `swarm.add`, `swarm.leave`, `swarm.fund`, `swarm.rebalance`, `swarm.status`, `swarm.dissolve`, `wallet.address`, `wallet.balance`, `wallet.accounts`, `wallet.list`, `wallet.use`, `wallet.fund`, `receipts.list`, `receipts.stats`, `support.report`, `swarm.run`, `swarm.allocate`, `swarm.delegate`, `swarm.runs`; inputs and results are in [docs/mcp.md](./docs/mcp.md).
53
+
54
+ ### Swarms
55
+
56
+ Swarms keep a treasury and capped member accounts on this machine. Setup is safe to rerun; the owner approves account links and funds the treasury.
57
+ A deposit arriving at the treasury after dissolve stays on the treasury account, which is kept on this device.
58
+
59
+ - `swarm.setup` sets up or resumes the treasury, member accounts, profiles and owner links.
60
+ - `swarm.add` adds or resumes one member.
61
+ - `swarm.leave` sweeps one member to the treasury and removes it from the swarm.
62
+ - `swarm.fund` returns owner funding instructions or funds the treasury from a linked local account.
63
+ - `swarm.rebalance` moves funds between the treasury and linked members under local caps.
64
+ - `swarm.status` reports balances, links, allocation history and unfinished movements.
65
+ - `swarm.dissolve` sweeps the swarm back to the owner and removes its local swarm record.
66
+ - `swarm.run` runs the lead, which may delegate one level deep using treasury-funded budgets bounded by a per-run draw (default $2.00), or runs every member independently on its own capital.
67
+ - `swarm.run` accepts `detach: true` to start in the background, and `swarm.runs` lists a swarm's runs with status.
68
+ - `swarm.allocate` and `swarm.delegate` are agent-only operations and are refused outside a swarm run; their optional `requestId` input makes retries idempotent.
69
+
70
+ MCP always declines approval prompts during swarm runs.
71
+
72
+ CLI commands:
73
+
74
+ - `vapi swarm create <name>` creates or resumes a local swarm and can fund it after linking.
75
+ - `vapi swarm add <name> <role>` adds or resumes one member.
76
+ - `vapi swarm remove <name> <member>` sweeps one member to the treasury and removes it.
77
+ - `vapi swarm fund <name> <usd>` prints owner funding instructions or funds from a local account.
78
+ - `vapi swarm rebalance <name>` moves capital toward the swarm's configured targets.
79
+ - `vapi swarm status <name>` reports balances, links, allocation history and unfinished movements.
80
+ - `vapi swarm dissolve <name>` sweeps the swarm to the owner and removes its swarm record.
81
+ - `vapi swarm run <name> "<task>"` runs the lead or every eligible member with per-run budget and treasury-draw limits.
82
+ - `vapi swarm run <name> "<task>" --detach [--runtime local]` starts the run in the background.
83
+ - `vapi swarm runs <name>` lists background runs and their status.
84
+ - `vapi swarm stop <name> [<runId>|--all] [--confirm-worker-stopped]` stops one or all running local processes for the swarm. The confirmation flag clears one stale start only after you verify its worker is gone.
85
+ - `vapi agent run <name> "<task>" --detach` starts one agent run in the background.
52
86
 
53
87
  #### Deprecated tool aliases
54
88
 
@@ -82,7 +116,15 @@ Every wallet command takes `--account <name>`, falls back to `VAPI_WALLET`, then
82
116
  | `vapi accounts restore <name>` | `--json` | Restores an account from `wallets/.trash/` |
83
117
  | `vapi accounts caps <name>` | `--per-call <usd>`, `--per-day <usd>`, `--ceiling <usd\|off>`, `--json` | Sets the account's spend caps and automatic Base USDC ceiling |
84
118
  | `vapi accounts distribute <amount>` | `--from <account>`, `--to <a,b,c>`, `--network <base\|arc>`, `--json` | Splits USDC across linked local accounts and records resumable legs |
85
- | `vapi accounts distribute --resume <id>` | `--json` | Continues an unfinished distribution without replacing its recorded nonces |
119
+ | `vapi accounts distribute --resume <id>` | `--replace-expired-restored`, `--bind-legacy-addresses`, `--json` | Continues an unfinished distribution; unsafe restored or legacy address replacement requires its terminal-only review flag |
120
+ | `vapi accounts distribute --cancel <id>` | `--replace-expired-restored`, `--json` | Cancels eligible legs without signing; restored legs require terminal-only review and signed legs require proven expiry |
121
+ | `vapi swarm create <name>` | `--agents`/`--roles`, `--fund`/`--from`, `--strategy`/`--targets`, `--caps`/`--treasury-caps`, `--network`, `--model`, `--no-wait`, `--json` | Creates or resumes a treasury, member accounts, profiles and owner links |
122
+ | `vapi swarm add <name> <role>` | `--json` | Adds or resumes one member |
123
+ | `vapi swarm remove <name> <member>` | `--json` | Sweeps a member to the treasury and removes it from the swarm |
124
+ | `vapi swarm fund <name> <usd>` | `--from <account>`, `--json` | Prints owner funding instructions or funds the treasury from a local account |
125
+ | `vapi swarm rebalance <name>` | `--targets <role=usd,...>`, `--json` | Moves funds between the treasury and linked members under local caps |
126
+ | `vapi swarm status <name>` | `--json` | Reports balances, links, allocation history and unfinished movements |
127
+ | `vapi swarm dissolve <name>` | `--json` | Sweeps the swarm back to the owner and removes its local swarm record |
86
128
  | `vapi send <amount>` | `--from <account>`, `--to <account\|owner\|0x…>`, `--network <base\|arc>`, `--resume <nonce>`, `--json` | Sends USDC to the owner or another active account; vAPI pays gas |
87
129
  | `vapi wallet list` | - | Name, address, default marker, caps in USD, unlocked, label |
88
130
  | `vapi wallet create <name>` | `--networks <base,arc,solana>`, `--label <text>` | A new wallet, with its own phrase, caps and passphrase |
@@ -102,9 +144,9 @@ Every wallet command takes `--account <name>`, falls back to `VAPI_WALLET`, then
102
144
  | `vapi receipts` | `--limit <n>`, `--wallet <name>`, `--all-wallets` | The local append-only call ledger, newest last |
103
145
  | `vapi receipts export` | `--format <json\|csv>`, `--range <24h\|7d\|30d>`, `--wallet <name>`, `--all-wallets` | Raw receipts for a spreadsheet or dashboard |
104
146
  | `vapi stats` | `--range <24h\|7d\|30d>`, `--wallet <name>`, `--all-wallets` | Spend, outcomes, latency percentiles and top services |
105
- | `vapi sweep [<address>]` | `--network <caip2>`, `--wallet <name>` | Moves USDC to an address, or to the linked owner when omitted |
147
+ | `vapi sweep [<address>]` | `--network <caip2>`, `--wallet <name>` | Moves USDC to an address, or to the linked owner when omitted; open movement legs block it |
106
148
  | `vapi agent create <name>` | `--model <id>`, `--instructions <file>`, `--call-budget <usd>`, `--max-per-call <usd>`, `--router-budget <usd>`, `--approve-above <usd>`, `--include-unverified`, `--max-steps <n>` | Creates a capped local agent wallet, profile and owner link |
107
- | `vapi agent run <name> "<task>"` | None | Runs the named agent on this machine |
149
+ | `vapi agent run <name> "<task>"` | `--budget <usd>` | Runs the named agent on this machine with an optional hard budget across Call and Router top-ups |
108
150
  | `vapi agent list` | None | Lists profiles, links and today's Call and Router budgets |
109
151
  | `vapi agent pause <name>` | None | Stops future runs until the agent is resumed |
110
152
  | `vapi agent resume <name>` | None | Allows a paused agent to run again |