@vultisig/cli 0.9.0 → 0.11.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/CHANGELOG.md +16 -0
- package/README.md +146 -1
- package/dist/index.js +15 -9
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @vultisig/cli
|
|
2
2
|
|
|
3
|
+
## 0.11.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`5286b98`](https://github.com/vultisig/vultisig-sdk/commit/5286b98d19692acd216a2c95d5a7a903217bef36)]:
|
|
8
|
+
- @vultisig/sdk@0.11.0
|
|
9
|
+
- @vultisig/rujira@7.0.0
|
|
10
|
+
|
|
11
|
+
## 0.10.0
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies [[`67dc6ce`](https://github.com/vultisig/vultisig-sdk/commit/67dc6ceaa1b318144cfbe3812ddecb14b108eba4)]:
|
|
16
|
+
- @vultisig/sdk@0.10.0
|
|
17
|
+
- @vultisig/rujira@6.0.0
|
|
18
|
+
|
|
3
19
|
## 0.9.0
|
|
4
20
|
|
|
5
21
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Vultisig CLI
|
|
2
2
|
|
|
3
|
-
Command-line wallet for Vultisig - secure multi-party computation (MPC) wallet management across 40+ blockchains.
|
|
3
|
+
Command-line wallet for Vultisig - secure multi-party computation (MPC) wallet management across 40+ blockchains. Designed for both human and AI agent use.
|
|
4
4
|
|
|
5
5
|
> **Tip:** Use `vsig` as a shorthand alias for `vultisig` - all commands work with both!
|
|
6
6
|
|
|
@@ -584,6 +584,151 @@ vultisig sign --chain sui --bytes "<base64-tx-bytes>" -o json > sig.json
|
|
|
584
584
|
vultisig broadcast --chain sui --raw-tx '{"unsignedTx":"<base64-tx-bytes>","signature":"<base64-signature-from-sig.json>"}'
|
|
585
585
|
```
|
|
586
586
|
|
|
587
|
+
### AI Agent Integration
|
|
588
|
+
|
|
589
|
+
The CLI has first-class support for AI coding agents (Claude Code, Cursor, Opencode, etc.).
|
|
590
|
+
|
|
591
|
+
#### Non-Interactive Vault Creation
|
|
592
|
+
|
|
593
|
+
When running in a non-TTY environment (pipes, scripts, AI agents), the CLI **automatically** uses two-step mode — no interactive OTP prompt that would hang your agent:
|
|
594
|
+
|
|
595
|
+
```bash
|
|
596
|
+
# Agent runs this — auto-detects non-TTY, skips interactive prompt
|
|
597
|
+
vultisig create fast --name "Agent Wallet" --password "$VAULT_PASSWORD" --email agent@example.com
|
|
598
|
+
|
|
599
|
+
# Returns immediately with vault ID (pending verification)
|
|
600
|
+
# Vault ID: 023118...
|
|
601
|
+
|
|
602
|
+
# Verify later when you have the email code
|
|
603
|
+
vultisig verify 023118... --code 123456
|
|
604
|
+
```
|
|
605
|
+
|
|
606
|
+
You can also force two-step mode explicitly:
|
|
607
|
+
|
|
608
|
+
```bash
|
|
609
|
+
# Force two-step even in a TTY
|
|
610
|
+
vultisig create fast --name "Agent Wallet" --password "$VAULT_PASSWORD" --email agent@example.com --two-step
|
|
611
|
+
|
|
612
|
+
# JSON output for machine parsing
|
|
613
|
+
vultisig create fast --name "Agent Wallet" --password "$VAULT_PASSWORD" --email agent@example.com --two-step -o json
|
|
614
|
+
```
|
|
615
|
+
|
|
616
|
+
JSON output for two-step create:
|
|
617
|
+
```json
|
|
618
|
+
{
|
|
619
|
+
"vaultId": "023118...",
|
|
620
|
+
"status": "pending_verification",
|
|
621
|
+
"message": "Vault created. Verify with email OTP to activate.",
|
|
622
|
+
"verifyCommand": "vultisig verify 023118... --code <OTP>",
|
|
623
|
+
"resendCommand": "vultisig verify 023118... --resend --email agent@example.com --password ..."
|
|
624
|
+
}
|
|
625
|
+
```
|
|
626
|
+
|
|
627
|
+
#### Agent Ask (One-Shot Mode)
|
|
628
|
+
|
|
629
|
+
Send a single natural-language message and get a structured response. Designed for AI-to-AI communication:
|
|
630
|
+
|
|
631
|
+
```bash
|
|
632
|
+
# Simple query
|
|
633
|
+
vultisig agent ask "What is my ETH balance?" --password "$VAULT_PASSWORD"
|
|
634
|
+
|
|
635
|
+
# Execute a transaction
|
|
636
|
+
vultisig agent ask "Send 0.01 ETH to 0x742d..." --password "$VAULT_PASSWORD"
|
|
637
|
+
|
|
638
|
+
# Continue a conversation (multi-turn)
|
|
639
|
+
vultisig agent ask "Now swap it to USDC" --session abc123 --password "$VAULT_PASSWORD"
|
|
640
|
+
|
|
641
|
+
# JSON output (for parsing)
|
|
642
|
+
vultisig agent ask "Check my portfolio" --password "$VAULT_PASSWORD" --json
|
|
643
|
+
```
|
|
644
|
+
|
|
645
|
+
**Text output (default):**
|
|
646
|
+
```
|
|
647
|
+
session:abc123-def456
|
|
648
|
+
|
|
649
|
+
Your ETH balance is 1.5 ETH ($3,750.00 USD).
|
|
650
|
+
|
|
651
|
+
tx:ethereum:0x9f8e7d6c...
|
|
652
|
+
explorer:https://etherscan.io/tx/0x9f8e7d6c...
|
|
653
|
+
```
|
|
654
|
+
|
|
655
|
+
**JSON output (`--json`):**
|
|
656
|
+
```json
|
|
657
|
+
{
|
|
658
|
+
"session_id": "abc123-def456",
|
|
659
|
+
"response": "Your ETH balance is 1.5 ETH ($3,750.00 USD).",
|
|
660
|
+
"tool_calls": [
|
|
661
|
+
{ "action": "getBalance", "success": true, "data": { "chain": "ethereum", "balance": "1.5" } }
|
|
662
|
+
],
|
|
663
|
+
"transactions": [
|
|
664
|
+
{ "hash": "0x9f8e7d6c...", "chain": "ethereum", "explorerUrl": "https://etherscan.io/tx/0x9f8e7d6c..." }
|
|
665
|
+
]
|
|
666
|
+
}
|
|
667
|
+
```
|
|
668
|
+
|
|
669
|
+
**Agent ask options:**
|
|
670
|
+
- `--session <id>` - Continue an existing conversation
|
|
671
|
+
- `--backend-url <url>` - Agent backend URL (default: https://abe.vultisig.com)
|
|
672
|
+
- `--password <password>` - Vault password for signing
|
|
673
|
+
- `--verbose` - Show tool calls and debug info on stderr
|
|
674
|
+
- `--json` - Output structured JSON
|
|
675
|
+
|
|
676
|
+
#### Agent Chat (Interactive/Pipe Mode)
|
|
677
|
+
|
|
678
|
+
For interactive TUI or piped agent-to-agent communication:
|
|
679
|
+
|
|
680
|
+
```bash
|
|
681
|
+
# Interactive TUI with chat interface
|
|
682
|
+
vultisig agent
|
|
683
|
+
|
|
684
|
+
# Pipe mode for agent-to-agent (NDJSON)
|
|
685
|
+
vultisig agent --via-agent --password "$VAULT_PASSWORD"
|
|
686
|
+
```
|
|
687
|
+
|
|
688
|
+
**Agent chat options:**
|
|
689
|
+
- `--via-agent` - NDJSON pipe mode for agent-to-agent communication (24h password cache)
|
|
690
|
+
- `--verbose` - Show detailed tool call parameters
|
|
691
|
+
- `--backend-url <url>` - Agent backend URL
|
|
692
|
+
- `--password <password>` - Vault password
|
|
693
|
+
- `--password-ttl <ms>` - Password cache TTL (default: 5min, 24h for `--via-agent`)
|
|
694
|
+
- `--session-id <id>` - Resume an existing session
|
|
695
|
+
|
|
696
|
+
#### Session Management
|
|
697
|
+
|
|
698
|
+
```bash
|
|
699
|
+
# List chat sessions for current vault
|
|
700
|
+
vultisig agent sessions list
|
|
701
|
+
|
|
702
|
+
# Delete a session
|
|
703
|
+
vultisig agent sessions delete abc123
|
|
704
|
+
```
|
|
705
|
+
|
|
706
|
+
#### Agent Command Summary
|
|
707
|
+
|
|
708
|
+
| Command | Description |
|
|
709
|
+
|---------|-------------|
|
|
710
|
+
| `agent ask <message>` | One-shot: send message, get response, exit |
|
|
711
|
+
| `agent` | Interactive TUI chat interface |
|
|
712
|
+
| `agent --via-agent` | NDJSON pipe mode for agent-to-agent |
|
|
713
|
+
| `agent sessions list` | List chat sessions |
|
|
714
|
+
| `agent sessions delete <id>` | Delete a session |
|
|
715
|
+
|
|
716
|
+
#### Environment Variables for Automation
|
|
717
|
+
|
|
718
|
+
```bash
|
|
719
|
+
# Pre-select vault (no --vault flag needed)
|
|
720
|
+
VULTISIG_VAULT=MyWallet
|
|
721
|
+
|
|
722
|
+
# Vault password (avoids --password flag)
|
|
723
|
+
VAULT_PASSWORD=mypassword
|
|
724
|
+
|
|
725
|
+
# Multiple vault passwords
|
|
726
|
+
VAULT_PASSWORDS="Vault1:pass1 Vault2:pass2"
|
|
727
|
+
|
|
728
|
+
# Suppress spinners and info messages
|
|
729
|
+
VULTISIG_SILENT=1
|
|
730
|
+
```
|
|
731
|
+
|
|
587
732
|
### Settings
|
|
588
733
|
|
|
589
734
|
| Command | Description |
|
package/dist/index.js
CHANGED
|
@@ -6426,6 +6426,12 @@ var AgentSession = class {
|
|
|
6426
6426
|
ui.onSuggestions(suggestions);
|
|
6427
6427
|
},
|
|
6428
6428
|
onTxReady: (tx) => {
|
|
6429
|
+
const txData = tx?.swap_tx || tx?.send_tx || tx?.tx;
|
|
6430
|
+
if (txData?.status === "error" || txData?.error) {
|
|
6431
|
+
if (this.config.verbose) process.stderr.write(`[session] skipping error tx_ready: ${txData.error || "unknown error"}
|
|
6432
|
+
`);
|
|
6433
|
+
return;
|
|
6434
|
+
}
|
|
6429
6435
|
this.executor.storeServerTransaction(tx);
|
|
6430
6436
|
if (this.config.password) {
|
|
6431
6437
|
this.executor.setPassword(this.config.password);
|
|
@@ -6950,7 +6956,7 @@ function summarizeData(data) {
|
|
|
6950
6956
|
async function executeAgent(ctx2, options) {
|
|
6951
6957
|
const vault = await ctx2.ensureActiveVault();
|
|
6952
6958
|
const config = {
|
|
6953
|
-
backendUrl: options.backendUrl || process.env.VULTISIG_AGENT_URL || "
|
|
6959
|
+
backendUrl: options.backendUrl || process.env.VULTISIG_AGENT_URL || "https://abe.vultisig.com",
|
|
6954
6960
|
vaultName: vault.name,
|
|
6955
6961
|
password: options.password,
|
|
6956
6962
|
viaAgent: options.viaAgent,
|
|
@@ -6990,7 +6996,7 @@ async function executeAgentAsk(ctx2, message, options) {
|
|
|
6990
6996
|
try {
|
|
6991
6997
|
const vault = await ctx2.ensureActiveVault();
|
|
6992
6998
|
const config = {
|
|
6993
|
-
backendUrl: options.backendUrl || process.env.VULTISIG_AGENT_URL || "
|
|
6999
|
+
backendUrl: options.backendUrl || process.env.VULTISIG_AGENT_URL || "https://abe.vultisig.com",
|
|
6994
7000
|
vaultName: vault.name,
|
|
6995
7001
|
password: options.password,
|
|
6996
7002
|
sessionId: options.session,
|
|
@@ -7045,7 +7051,7 @@ tx:${tx.chain}:${tx.hash}
|
|
|
7045
7051
|
}
|
|
7046
7052
|
async function executeAgentSessionsList(ctx2, options) {
|
|
7047
7053
|
const vault = await ctx2.ensureActiveVault();
|
|
7048
|
-
const backendUrl = options.backendUrl || process.env.VULTISIG_AGENT_URL || "
|
|
7054
|
+
const backendUrl = options.backendUrl || process.env.VULTISIG_AGENT_URL || "https://abe.vultisig.com";
|
|
7049
7055
|
const client = await createAuthenticatedClient(backendUrl, vault, options.password);
|
|
7050
7056
|
const publicKey = vault.publicKeys.ecdsa;
|
|
7051
7057
|
const PAGE_SIZE = 100;
|
|
@@ -7092,7 +7098,7 @@ async function executeAgentSessionsList(ctx2, options) {
|
|
|
7092
7098
|
}
|
|
7093
7099
|
async function executeAgentSessionsDelete(ctx2, sessionId, options) {
|
|
7094
7100
|
const vault = await ctx2.ensureActiveVault();
|
|
7095
|
-
const backendUrl = options.backendUrl || process.env.VULTISIG_AGENT_URL || "
|
|
7101
|
+
const backendUrl = options.backendUrl || process.env.VULTISIG_AGENT_URL || "https://abe.vultisig.com";
|
|
7096
7102
|
const client = await createAuthenticatedClient(backendUrl, vault, options.password);
|
|
7097
7103
|
const publicKey = vault.publicKeys.ecdsa;
|
|
7098
7104
|
await client.deleteConversation(sessionId, publicKey);
|
|
@@ -8522,7 +8528,7 @@ var cachedVersion = null;
|
|
|
8522
8528
|
function getVersion() {
|
|
8523
8529
|
if (cachedVersion) return cachedVersion;
|
|
8524
8530
|
if (true) {
|
|
8525
|
-
cachedVersion = "0.
|
|
8531
|
+
cachedVersion = "0.11.0";
|
|
8526
8532
|
return cachedVersion;
|
|
8527
8533
|
}
|
|
8528
8534
|
try {
|
|
@@ -9525,7 +9531,7 @@ rujiraCmd.command("withdraw <asset> <amount> <l1Address>").description("Withdraw
|
|
|
9525
9531
|
}
|
|
9526
9532
|
)
|
|
9527
9533
|
);
|
|
9528
|
-
var agentCmd = program.command("agent").description("AI-powered chat interface for wallet operations").option("--via-agent", "Use NDJSON pipe mode for agent-to-agent communication").option("--verbose", "Show detailed tool call parameters and debug output").option("--backend-url <url>", "Agent backend URL (default:
|
|
9534
|
+
var agentCmd = program.command("agent").description("AI-powered chat interface for wallet operations").option("--via-agent", "Use NDJSON pipe mode for agent-to-agent communication").option("--verbose", "Show detailed tool call parameters and debug output").option("--backend-url <url>", "Agent backend URL (default: https://abe.vultisig.com)").option("--password <password>", "Vault password for signing operations").option("--password-ttl <ms>", "Password cache TTL in milliseconds (default: 300000, 86400000/24h for --via-agent)").option("--session-id <id>", "Resume an existing session").action(async (options) => {
|
|
9529
9535
|
const MAX_TTL = 864e5;
|
|
9530
9536
|
let passwordTTL;
|
|
9531
9537
|
if (options.passwordTtl) {
|
|
@@ -9546,7 +9552,7 @@ var agentCmd = program.command("agent").description("AI-powered chat interface f
|
|
|
9546
9552
|
sessionId: options.sessionId
|
|
9547
9553
|
});
|
|
9548
9554
|
});
|
|
9549
|
-
agentCmd.command("ask <message>").description("Send a single message and get the response (for AI agent integration)").option("--session <id>", "Continue an existing conversation").option("--backend-url <url>", "Agent backend URL (default:
|
|
9555
|
+
agentCmd.command("ask <message>").description("Send a single message and get the response (for AI agent integration)").option("--session <id>", "Continue an existing conversation").option("--backend-url <url>", "Agent backend URL (default: https://abe.vultisig.com)").option("--password <password>", "Vault password for signing operations").option("--verbose", "Show tool calls and debug info on stderr").option("--json", "Output structured JSON instead of text").action(
|
|
9550
9556
|
async (message, options) => {
|
|
9551
9557
|
const parentOpts = agentCmd.opts();
|
|
9552
9558
|
const context = await init(
|
|
@@ -9562,7 +9568,7 @@ agentCmd.command("ask <message>").description("Send a single message and get the
|
|
|
9562
9568
|
}
|
|
9563
9569
|
);
|
|
9564
9570
|
var sessionsCmd = agentCmd.command("sessions").description("Manage agent chat sessions");
|
|
9565
|
-
sessionsCmd.command("list").description("List chat sessions for the current vault").option("--backend-url <url>", "Agent backend URL (default:
|
|
9571
|
+
sessionsCmd.command("list").description("List chat sessions for the current vault").option("--backend-url <url>", "Agent backend URL (default: https://abe.vultisig.com)").option("--password <password>", "Vault password for authentication").action(
|
|
9566
9572
|
withExit(async (options) => {
|
|
9567
9573
|
const parentOpts = agentCmd.opts();
|
|
9568
9574
|
const context = await init(program.opts().vault, options.password || parentOpts.password);
|
|
@@ -9572,7 +9578,7 @@ sessionsCmd.command("list").description("List chat sessions for the current vaul
|
|
|
9572
9578
|
});
|
|
9573
9579
|
})
|
|
9574
9580
|
);
|
|
9575
|
-
sessionsCmd.command("delete <id>").description("Delete a chat session").option("--backend-url <url>", "Agent backend URL (default:
|
|
9581
|
+
sessionsCmd.command("delete <id>").description("Delete a chat session").option("--backend-url <url>", "Agent backend URL (default: https://abe.vultisig.com)").option("--password <password>", "Vault password for authentication").action(
|
|
9576
9582
|
withExit(async (id, options) => {
|
|
9577
9583
|
const parentOpts = agentCmd.opts();
|
|
9578
9584
|
const context = await init(program.opts().vault, options.password || parentOpts.password);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vultisig/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Command-line wallet for Vultisig - multi-chain MPC wallet management",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -53,8 +53,8 @@
|
|
|
53
53
|
"@cosmjs/proto-signing": "^0.38.1",
|
|
54
54
|
"@cosmjs/stargate": "^0.38.1",
|
|
55
55
|
"@noble/hashes": "^2.0.1",
|
|
56
|
-
"@vultisig/rujira": "^
|
|
57
|
-
"@vultisig/sdk": "^0.
|
|
56
|
+
"@vultisig/rujira": "^7.0.0",
|
|
57
|
+
"@vultisig/sdk": "^0.11.0",
|
|
58
58
|
"chalk": "^5.6.2",
|
|
59
59
|
"cli-table3": "^0.6.5",
|
|
60
60
|
"commander": "^14.0.3",
|