@agentlayer.tech/wallet 0.1.35 → 0.1.37
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/.openclaw/extensions/agent-wallet/openclaw.plugin.json +1 -1
- package/.openclaw/extensions/agent-wallet/package.json +1 -1
- package/CHANGELOG.md +17 -0
- package/README.md +8 -0
- package/VERSION +1 -1
- package/agent-wallet/agent_wallet/__init__.py +1 -1
- package/agent-wallet/agent_wallet/providers/wdk_evm_local.py +4 -2
- package/agent-wallet/openclaw.plugin.json +1 -1
- package/agent-wallet/pyproject.toml +1 -1
- package/agent-wallet/skills/wallet-operator/SKILL.md +21 -9
- package/bin/openclaw-agent-wallet.mjs +14 -0
- package/claude-code/plugins/agent-wallet/.claude-plugin/plugin.json +1 -1
- package/claude-code/plugins/agent-wallet/scripts/run_mcp.sh +14 -7
- package/codex/plugins/agent-wallet/.codex-plugin/plugin.json +1 -1
- package/codex/plugins/agent-wallet/scripts/run_mcp.sh +3 -2
- package/hermes/plugins/agent_wallet/plugin.yaml +1 -1
- package/package.json +1 -1
- package/wdk-btc-wallet/package.json +1 -1
- package/wdk-evm-wallet/package.json +1 -1
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "agent-wallet",
|
|
3
3
|
"name": "Agent Wallet",
|
|
4
4
|
"description": "Official OpenClaw plugin bridge for the agent-wallet backends, including Solana, local BTC, and local EVM.",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.37",
|
|
6
6
|
"contracts": {
|
|
7
7
|
"tools": [
|
|
8
8
|
"close_empty_token_accounts",
|
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## v0.1.37 - 2026-06-05
|
|
6
|
+
|
|
7
|
+
- Fixed the Claude Code / Codex MCP bridge failing to start with
|
|
8
|
+
`MCP error -32000: Connection closed` when the plugin is run through a
|
|
9
|
+
marketplace symlink. run_mcp.sh resolved PLUGIN_ROOT with a logical `pwd`, so
|
|
10
|
+
the symlink stayed in the path and the sibling-codex fallback (`../../../codex`)
|
|
11
|
+
collapsed lexically into a non-existent path. The launcher now resolves paths
|
|
12
|
+
physically (`pwd -P`), keeping the `..` arithmetic consistent with the real
|
|
13
|
+
layout, with a regression test that drives the launcher through a symlink.
|
|
14
|
+
|
|
15
|
+
## v0.1.36 - 2026-06-03
|
|
16
|
+
|
|
17
|
+
- Installer no longer pins a redundant `OPENCLAW_HOME` into the version-controlled
|
|
18
|
+
bundle `.mcp.json` when the install home is the default `~/.openclaw`
|
|
19
|
+
(run_mcp.sh already derives it). Any stale pin is removed so the tracked file
|
|
20
|
+
self-heals to a clean state; non-default homes still pin as before.
|
|
21
|
+
|
|
5
22
|
## v0.1.35 - 2026-06-03
|
|
6
23
|
|
|
7
24
|
- Hardened the Codex / Claude Code MCP wallet bridge:
|
package/README.md
CHANGED
|
@@ -6,10 +6,18 @@
|
|
|
6
6
|
[](https://docs.agent-layer.tech/)
|
|
7
7
|
[](https://github.com/lopushok9/Agent-Layer/blob/main/LICENSE)
|
|
8
8
|
|
|
9
|
+
For Openclaw:
|
|
10
|
+
|
|
9
11
|
```bash
|
|
10
12
|
npx @agentlayer.tech/wallet install --yes
|
|
11
13
|
```
|
|
12
14
|
|
|
15
|
+
For Codex:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npx @agentlayer.tech/wallet install --yes && npx @agentlayer.tech/wallet codex install --yes
|
|
19
|
+
```
|
|
20
|
+
|
|
13
21
|
For Hermes:
|
|
14
22
|
|
|
15
23
|
```bash
|
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.1.
|
|
1
|
+
0.1.37
|
|
@@ -13,7 +13,7 @@ from agent_wallet.config import resolve_evm_wallet_password, resolve_openclaw_ho
|
|
|
13
13
|
from agent_wallet.wallet_layer.base import WalletBackendError
|
|
14
14
|
|
|
15
15
|
LOCAL_WDK_EVM_HOSTS = {"127.0.0.1", "localhost", "::1"}
|
|
16
|
-
|
|
16
|
+
LONG_RUNNING_POST_PATHS = {
|
|
17
17
|
"/v1/evm/aave/supply/send",
|
|
18
18
|
"/v1/evm/aave/withdraw/send",
|
|
19
19
|
"/v1/evm/aave/borrow/send",
|
|
@@ -24,7 +24,9 @@ LONG_RUNNING_SEND_PATHS = {
|
|
|
24
24
|
"/v1/evm/lido/request_withdrawal_steth/send",
|
|
25
25
|
"/v1/evm/lido/request_withdrawal_wsteth/send",
|
|
26
26
|
"/v1/evm/lido/claim_withdrawal/send",
|
|
27
|
+
"/v1/evm/swap/quote",
|
|
27
28
|
"/v1/evm/swap/send",
|
|
29
|
+
"/v1/evm/lifi/quote",
|
|
28
30
|
"/v1/evm/lifi/send",
|
|
29
31
|
"/v1/evm/transfer/send",
|
|
30
32
|
"/v1/evm/token-transfer/send",
|
|
@@ -72,7 +74,7 @@ def _load_local_token() -> str:
|
|
|
72
74
|
def _timeout_for_path(path: str) -> float:
|
|
73
75
|
normalized = str(path or "").strip()
|
|
74
76
|
base_timeout = float(settings.http_timeout)
|
|
75
|
-
if normalized in
|
|
77
|
+
if normalized in LONG_RUNNING_POST_PATHS:
|
|
76
78
|
return max(base_timeout, LONG_RUNNING_SEND_TIMEOUT_SECONDS)
|
|
77
79
|
return base_timeout
|
|
78
80
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "agent-wallet",
|
|
3
3
|
"name": "Agent Wallet",
|
|
4
4
|
"description": "Plugin-friendly wallet backend for OpenClaw agents with safe wallet tools and runtime instructions across Solana, local BTC, and local EVM.",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.37",
|
|
6
6
|
"skills": ["skills/wallet-operator"],
|
|
7
7
|
"configSchema": {
|
|
8
8
|
"type": "object",
|
|
@@ -12,12 +12,13 @@ Use this skill before calling OpenClaw wallet tools. It is the routing guide for
|
|
|
12
12
|
1. Start with `get_wallet_capabilities` when the active chain, signing support, or available tools are unclear.
|
|
13
13
|
2. Use `get_wallet_address` before asking for deposits or confirming a recipient/source wallet.
|
|
14
14
|
3. Use `get_wallet_balance` before spending, swapping, bridging, staking, lending, or claiming.
|
|
15
|
-
4.
|
|
16
|
-
5. `
|
|
17
|
-
6.
|
|
18
|
-
7.
|
|
19
|
-
8.
|
|
20
|
-
9.
|
|
15
|
+
4. Treat `get_wallet_balance` as the default balance read for the active backend, not as a Solana-only helper. If `get_wallet_capabilities` says `can_get_balance=true`, prefer calling `get_wallet_balance` before assuming a backend lacks native balance support.
|
|
16
|
+
5. Use `preview` first for every write action. For Solana Jupiter swaps, prefer `intent_preview` then `intent_execute` after explicit chat confirmation so execution can refresh the quote inside approved limits. Solana swap intents are normalized by the backend to at least 300 bps slippage, 120 seconds validity, and 3 fresh execution attempts; do not pass a hand-tightened `minimum_output_amount_raw` unless the user explicitly set that floor. Use `prepare` only after explicit user intent. In OpenClaw, use `execute` only after the user explicitly confirms the shown summary in chat; do not ask the user for `/approve`, buttons, popups, or a manual token.
|
|
17
|
+
6. `prepare` returns an execution plan only; it must not return signed transaction bytes.
|
|
18
|
+
7. On mainnet, restate the network and material terms before `execute`; the OpenClaw plugin handles the internal execution authorization after chat confirmation.
|
|
19
|
+
8. If backend is `sign_only`, do not execute; use `prepare` and state that nothing was broadcast.
|
|
20
|
+
9. Never claim a transfer, swap, bridge, stake, claim, deposit, borrow, repay, or withdrawal happened unless the tool result says it was broadcast/confirmed.
|
|
21
|
+
10. Do not use Mayan. Direct Mayan paths were removed. Cross-chain swaps must go through LI.FI with Mayan denied.
|
|
21
22
|
|
|
22
23
|
## Provider Map
|
|
23
24
|
|
|
@@ -46,19 +47,30 @@ Use this skill before calling OpenClaw wallet tools. It is the routing guide for
|
|
|
46
47
|
|
|
47
48
|
- `get_wallet_capabilities`: available chain, backend, send/sign support.
|
|
48
49
|
- `get_wallet_address`: active wallet address.
|
|
49
|
-
- `get_wallet_balance`: primary balance/portfolio summary
|
|
50
|
-
-
|
|
50
|
+
- `get_wallet_balance`: primary balance/portfolio summary for the active backend.
|
|
51
|
+
- Solana: native SOL plus discovered SPL assets and USD values when available.
|
|
52
|
+
- EVM: native ETH balance plus discovered ERC-20 assets and USD values when available.
|
|
53
|
+
- If the user asks for an EVM wallet balance, try this first before falling back to token-specific reads.
|
|
54
|
+
- `get_wallet_portfolio`: detailed Solana portfolio holdings. Do not assume this works on every backend; `wdk_evm_local` may reject portfolio lookup even when `get_wallet_balance` works.
|
|
51
55
|
- `get_solana_token_prices`: prices by Solana mint.
|
|
52
56
|
- `get_lifi_supported_chains`: supported LI.FI subset.
|
|
53
57
|
- `get_lifi_quote`: read-only LI.FI quote/status surface; use when user asks for indicative cross-chain quote outside the write flow.
|
|
54
58
|
- `get_lifi_transfer_status`: check LI.FI bridge status after a cross-chain source transaction.
|
|
55
59
|
- `get_evm_network`: active EVM network and supported EVM swap networks.
|
|
56
|
-
- `get_evm_token_balance`: ERC-20 balance by `token_address`, optional `network`.
|
|
60
|
+
- `get_evm_token_balance`: ERC-20 balance by `token_address`, optional `network`. This is not the native ETH balance reader; use it for a specific token contract such as USDC or WETH.
|
|
57
61
|
- `get_evm_token_metadata`: ERC-20 metadata by `token_address`, optional `network`.
|
|
58
62
|
- `get_evm_fee_rates`: EVM fee suggestions.
|
|
59
63
|
- `get_evm_transaction_receipt`: EVM receipt by `tx_hash`.
|
|
60
64
|
- `get_btc_transfer_history`, `get_btc_fee_rates`, `get_btc_max_spendable`: BTC read helpers.
|
|
61
65
|
|
|
66
|
+
## Balance Routing
|
|
67
|
+
|
|
68
|
+
- Solana wallet balance request: use `get_wallet_balance`.
|
|
69
|
+
- EVM wallet balance request: use `get_wallet_balance` first for native ETH and discovered ERC-20 holdings.
|
|
70
|
+
- EVM specific token balance request: use `get_evm_token_balance` with a concrete ERC-20 `token_address`.
|
|
71
|
+
- EVM native transfer sizing: use `get_wallet_balance` for available ETH, then `get_evm_fee_rates` if the user needs fee context.
|
|
72
|
+
- If the tool descriptions and runtime capabilities seem inconsistent, prefer a direct read call over guessing from descriptions alone.
|
|
73
|
+
|
|
62
74
|
## Transfer Commands
|
|
63
75
|
|
|
64
76
|
- SOL transfer: `transfer_sol`
|
|
@@ -1617,6 +1617,20 @@ function pinHomeIntoMcpFile(mcpPath, env = process.env) {
|
|
|
1617
1617
|
const entry = (doc.mcpServers || {})["agent-wallet"];
|
|
1618
1618
|
if (!entry) return { pinned: false, reason: "no agent-wallet server entry", path: mcpPath };
|
|
1619
1619
|
const home = resolveOpenclawHome(env);
|
|
1620
|
+
// When the install home is the default ~/.openclaw, run_mcp.sh already derives
|
|
1621
|
+
// it (`${OPENCLAW_HOME:-"$HOME/.openclaw"}`), so pinning is redundant and would
|
|
1622
|
+
// dirty version-controlled bundle files. Skip it — and drop any stale pin so the
|
|
1623
|
+
// file self-heals back to a clean, distributable state.
|
|
1624
|
+
const defaultHome = path.resolve(expandHome("~/.openclaw"));
|
|
1625
|
+
if (home === defaultHome) {
|
|
1626
|
+
if (entry.env && "OPENCLAW_HOME" in entry.env) {
|
|
1627
|
+
delete entry.env.OPENCLAW_HOME;
|
|
1628
|
+
if (Object.keys(entry.env).length === 0) delete entry.env;
|
|
1629
|
+
writeJsonFile(mcpPath, doc);
|
|
1630
|
+
return { pinned: false, reason: "home is default; removed redundant pin", path: mcpPath };
|
|
1631
|
+
}
|
|
1632
|
+
return { pinned: false, reason: "home is default; run_mcp.sh derives it", path: mcpPath };
|
|
1633
|
+
}
|
|
1620
1634
|
entry.env = { ...(entry.env || {}), OPENCLAW_HOME: home };
|
|
1621
1635
|
writeJsonFile(mcpPath, doc);
|
|
1622
1636
|
return { pinned: true, openclaw_home: home, path: mcpPath };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agent-wallet",
|
|
3
3
|
"displayName": "Agent Wallet",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.37",
|
|
5
5
|
"description": "Claude Code bridge for the existing AgentLayer wallet runtime. Connects to Solana, Bitcoin, and EVM wallets without creating a new one.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "AgentLayer"
|
|
@@ -1,14 +1,21 @@
|
|
|
1
1
|
#!/bin/sh
|
|
2
2
|
set -eu
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
# Resolve to PHYSICAL paths (pwd -P). Claude Code runs this plugin through a
|
|
5
|
+
# marketplace symlink (~/.claude/agentlayer-local/plugins/agent-wallet -> the real
|
|
6
|
+
# plugin dir). With a logical pwd, the symlink stays in PLUGIN_ROOT and the
|
|
7
|
+
# "../../../codex" sibling math below collapses lexically into a non-existent path
|
|
8
|
+
# (e.g. ~/.claude/codex), so `cd` fails and the server dies with -32000. Resolving
|
|
9
|
+
# the symlink up front keeps the `..` arithmetic consistent with the real layout.
|
|
10
|
+
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)
|
|
11
|
+
PLUGIN_ROOT=$(CDPATH= cd -- "$SCRIPT_DIR/.." && pwd -P)
|
|
6
12
|
OPENCLAW_HOME=${OPENCLAW_HOME:-"$HOME/.openclaw"}
|
|
7
13
|
PACKAGE_ROOT=${AGENT_WALLET_PACKAGE_ROOT:-${OPENCLAW_AGENT_WALLET_PACKAGE_ROOT:-"$OPENCLAW_HOME/agent-wallet-runtime/current/agent-wallet"}}
|
|
8
14
|
|
|
9
|
-
# Resolve server.py.
|
|
10
|
-
#
|
|
11
|
-
#
|
|
15
|
+
# Resolve server.py. The claude-code plugin ships no server.py of its own; it
|
|
16
|
+
# reuses the sibling codex copy (real repo / installed runtime, where claude-code
|
|
17
|
+
# and codex sit side by side), falling back to the codex copy inside the runtime
|
|
18
|
+
# package, which is always present.
|
|
12
19
|
LOCAL_SERVER="$PLUGIN_ROOT/server.py"
|
|
13
20
|
CODEX_SERVER="$PLUGIN_ROOT/../../../codex/plugins/agent-wallet/server.py"
|
|
14
21
|
RUNTIME_CODEX_DIR="$OPENCLAW_HOME/agent-wallet-runtime/current/codex/plugins/agent-wallet"
|
|
@@ -16,9 +23,9 @@ RUNTIME_CODEX_DIR="$OPENCLAW_HOME/agent-wallet-runtime/current/codex/plugins/age
|
|
|
16
23
|
if [ -f "$LOCAL_SERVER" ]; then
|
|
17
24
|
SERVER_PY="$LOCAL_SERVER"
|
|
18
25
|
elif [ -f "$CODEX_SERVER" ]; then
|
|
19
|
-
SERVER_PY=$(CDPATH= cd -- "$PLUGIN_ROOT/../../../codex/plugins/agent-wallet" && pwd)/server.py
|
|
26
|
+
SERVER_PY=$(CDPATH= cd -- "$PLUGIN_ROOT/../../../codex/plugins/agent-wallet" && pwd -P)/server.py
|
|
20
27
|
elif [ -f "$RUNTIME_CODEX_DIR/server.py" ]; then
|
|
21
|
-
SERVER_PY=$(CDPATH= cd -- "$RUNTIME_CODEX_DIR" && pwd)/server.py
|
|
28
|
+
SERVER_PY=$(CDPATH= cd -- "$RUNTIME_CODEX_DIR" && pwd -P)/server.py
|
|
22
29
|
else
|
|
23
30
|
printf '{"error":"agent-wallet server.py not found in plugin, codex sibling, or runtime package.","fix":"npx @agentlayer.tech/wallet install --yes"}\n' >&2
|
|
24
31
|
exit 1
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
#!/bin/sh
|
|
2
2
|
set -eu
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
# Physical paths (pwd -P) so symlinked install layouts resolve to the real dir.
|
|
5
|
+
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)
|
|
6
|
+
PLUGIN_ROOT=$(CDPATH= cd -- "$SCRIPT_DIR/.." && pwd -P)
|
|
6
7
|
OPENCLAW_HOME=${OPENCLAW_HOME:-"$HOME/.openclaw"}
|
|
7
8
|
PACKAGE_ROOT=${AGENT_WALLET_PACKAGE_ROOT:-${OPENCLAW_AGENT_WALLET_PACKAGE_ROOT:-"$OPENCLAW_HOME/agent-wallet-runtime/current/agent-wallet"}}
|
|
8
9
|
|
package/package.json
CHANGED