@waiaas/adapter-ripple 2.13.0 → 2.14.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.
Files changed (3) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +229 -0
  3. package/package.json +7 -7
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 WAIaaS Contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,229 @@
1
+ # WAIaaS
2
+
3
+ **Wallet-as-a-Service for AI Agents**
4
+
5
+ [![npm downloads](https://img.shields.io/npm/dt/@waiaas/core)](https://www.npmjs.com/package/@waiaas/core)
6
+ [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
7
+ [![Node.js](https://img.shields.io/badge/Node.js-22_LTS-green.svg)](https://nodejs.org/)
8
+ [![Tests](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/minhoyoo-iotrust/8eaa6e6fa868042de1a47f1b600df0f6/raw/waiaas-test-badge.json)](#)
9
+ [![MCP Server](https://glama.ai/mcp/servers/minhoyoo-iotrust/WAIaaS/badges/score.svg)](https://glama.ai/mcp/servers/minhoyoo-iotrust/WAIaaS)
10
+
11
+ A self-hosted wallet daemon that lets AI agents perform on-chain transactions securely -- while the owner keeps full control of funds.
12
+
13
+ ## The Problem
14
+
15
+ AI agents that need to transact on-chain face an impossible choice: hold private keys (and risk total loss if compromised) or depend on a centralized custodian (single point of failure, trust dependency).
16
+
17
+ WAIaaS bridges the gap -- agents handle small transactions instantly, large amounts require owner approval, and everything runs on your machine with no third-party dependency.
18
+
19
+ ## How It Works
20
+
21
+ WAIaaS is a local daemon that sits between your AI agent and the blockchain:
22
+
23
+ - **3-tier authentication** -- Separate roles for the daemon operator (masterAuth), fund owner (ownerAuth), and AI agent (sessionAuth)
24
+ - **4-tier policy engine** -- Transactions are auto-classified by USD value into INSTANT / NOTIFY / DELAY / APPROVAL tiers
25
+ - **12 policy types** -- Cumulative spend limits, token allowlists, contract whitelists, approved spenders, and more
26
+ - **Defense in depth** -- Kill Switch, AutoStop engine, audit logging, 4-channel notifications
27
+
28
+ See [Security Model](docs/security-model.md) for full details.
29
+
30
+ ## Architecture
31
+
32
+ ```mermaid
33
+ graph LR
34
+ subgraph Interfaces
35
+ SDK["TypeScript SDK"]
36
+ MCP["MCP Server"]
37
+ CLI["CLI"]
38
+ Admin["Admin UI"]
39
+ Skills["Skill Files"]
40
+ WalletSDK["Wallet SDK"]
41
+ end
42
+
43
+ subgraph Daemon
44
+ API["API Layer<br>(Hono + Middleware)"]
45
+ Services["Service Layer<br>(Policy, Notifications, Kill Switch)"]
46
+ Pipeline["Transaction Pipeline<br>(6-stage + 8-state)"]
47
+ Infra["Infrastructure<br>(SQLite, Keystore, Config)"]
48
+ end
49
+
50
+ subgraph Blockchain
51
+ Solana["Solana"]
52
+ EVM["EVM Chains"]
53
+ end
54
+
55
+ SDK & MCP & CLI & Admin & Skills & WalletSDK --> API
56
+ API --> Services --> Pipeline --> Infra
57
+ Infra --> Solana & EVM
58
+ ```
59
+
60
+ **12 packages** in a monorepo:
61
+
62
+ - **@waiaas/core** — Shared types, Zod schemas, enums, and interfaces
63
+ - **@waiaas/daemon** — Self-hosted wallet daemon (Hono HTTP server)
64
+ - **@waiaas/adapter-solana** — Solana chain adapter (SPL / Token-2022)
65
+ - **@waiaas/adapter-evm** — EVM chain adapter (ERC-20 via viem)
66
+ - **@waiaas/actions** — DeFi Action Providers (Jupiter, 0x, LI.FI, Lido, Jito)
67
+ - **@waiaas/sdk** — TypeScript client library
68
+ - **@waiaas/mcp** — Model Context Protocol server for AI agents
69
+ - **@waiaas/cli** — Command-line interface
70
+ - **@waiaas/admin** — Preact-based Admin Web UI
71
+ - **@waiaas/wallet-sdk** — Wallet Signing SDK for wallet app integration
72
+ - **@waiaas/push-relay** — Push Relay Server (daemon → Pushwoosh/FCM native push)
73
+ - **@waiaas/skills** — Pre-built `.skill.md` instruction files for AI agents
74
+
75
+ See [Architecture](docs/architecture.md) for the full technical deep-dive.
76
+
77
+ ## Quick Start
78
+
79
+ ```bash
80
+ npm install -g @waiaas/cli
81
+ waiaas init # Create data directory + config.toml
82
+ waiaas start # Start daemon (sets master password on first run)
83
+ waiaas quickset --mode mainnet # Create wallets + MCP sessions in one step
84
+ ```
85
+
86
+ The `quickset` command does everything you need to get started:
87
+
88
+ 1. Creates **Solana Mainnet + EVM Ethereum Mainnet** wallets automatically
89
+ 2. Issues **MCP session tokens** for each wallet
90
+ 3. Outputs a **Claude Desktop MCP config** snippet -- just copy and paste
91
+
92
+ > We recommend configuring spending limits and registering an owner wallet for high-value transaction approval. For testing, use `waiaas quickset --mode testnet` to create Solana Devnet + EVM Sepolia wallets instead.
93
+
94
+ ### Admin UI
95
+
96
+ After starting the daemon, manage everything from the admin panel at `http://127.0.0.1:3100/admin` (masterAuth required).
97
+
98
+ ## Connect Your AI Agent
99
+
100
+ After quickset, choose one of two integration paths:
101
+
102
+ ### Path A: MCP (Claude Desktop / Claude Code)
103
+
104
+ For AI agents that support the [Model Context Protocol](https://modelcontextprotocol.io):
105
+
106
+ ```bash
107
+ # quickset already printed the MCP config JSON -- paste it into
108
+ # ~/Library/Application Support/Claude/claude_desktop_config.json
109
+ # Or auto-register with all wallets:
110
+ waiaas mcp setup --all
111
+ ```
112
+
113
+ The daemon runs as an MCP server. Your agent calls wallet tools directly -- send tokens, check balances, manage policies -- all through the MCP protocol.
114
+
115
+ ### Path B: Skill Files (Any AI Agent)
116
+
117
+ For agents that don't support MCP, or when you prefer REST API integration:
118
+
119
+ ```bash
120
+ npx @waiaas/skills add all
121
+ ```
122
+
123
+ This adds `.skill.md` instruction files to your project. Include them in your agent's context and it learns the WAIaaS API automatically. Available skills: `setup`, `quickstart`, `wallet`, `transactions`, `policies`, `admin`, `actions`, `x402`.
124
+
125
+ ### Agent Self-Setup (Auto-Provision)
126
+
127
+ AI agents can set up WAIaaS fully autonomously with no human interaction:
128
+
129
+ ```bash
130
+ npm install -g @waiaas/cli
131
+ waiaas init --auto-provision # Generates random master password → recovery.key
132
+ waiaas start # No password prompt
133
+ waiaas quickset # Creates wallets + sessions automatically
134
+ waiaas set-master # (Later) Harden password, then delete recovery.key
135
+ ```
136
+
137
+ The `--auto-provision` flag generates a cryptographically random master password and saves it to `~/.waiaas/recovery.key`. All subsequent CLI commands read it automatically. See the [Agent Self-Setup Guide](docs/agent-guides/agent-self-setup.md) for the complete flow.
138
+
139
+ For manual setup with human-guided password entry, install skills and follow `waiaas-setup/SKILL.md`:
140
+
141
+ ```bash
142
+ npx @waiaas/skills add all
143
+ ```
144
+
145
+ ## Alternative: Docker
146
+
147
+ ```bash
148
+ git clone https://github.com/minho-yoo/waiaas.git && cd waiaas
149
+ docker compose up -d
150
+ ```
151
+
152
+ The daemon listens on `http://127.0.0.1:3100`.
153
+
154
+ ## Using the SDK
155
+
156
+ ```typescript
157
+ import { WAIaaSClient } from '@waiaas/sdk';
158
+
159
+ const client = new WAIaaSClient({
160
+ baseUrl: 'http://127.0.0.1:3100',
161
+ sessionToken: process.env.WAIAAS_SESSION_TOKEN,
162
+ });
163
+
164
+ const balance = await client.getBalance();
165
+ console.log(`Balance: ${balance.balance} ${balance.symbol}`);
166
+
167
+ const tx = await client.sendToken({
168
+ to: 'recipient-address...',
169
+ amount: '0.1',
170
+ });
171
+ console.log(`Transaction: ${tx.id}`);
172
+ ```
173
+
174
+ ## Admin UI
175
+
176
+ Access the admin panel at `http://127.0.0.1:3100/admin` with your master password:
177
+
178
+ - **Dashboard** -- System overview, wallet balances, recent transactions
179
+ - **Wallets** -- Create, manage, and monitor wallets across chains; RPC endpoints, balance monitoring, and WalletConnect settings
180
+ - **Sessions** -- Issue and revoke agent session tokens; session lifetime and rate limit settings
181
+ - **Policies** -- Configure 12 policy types with visual form editors; default deny and tier settings
182
+ - **Notifications** -- Channel status and delivery logs; Telegram, Discord, and Slack settings
183
+ - **Security** -- Kill Switch emergency controls, AutoStop protection rules, JWT rotation
184
+ - **System** -- API keys, display currency, price oracle, rate limits, log level, and daemon shutdown
185
+
186
+ Features include settings search (Ctrl+K / Cmd+K) and unsaved changes protection.
187
+
188
+ Enabled by default (`admin_ui = true` in config.toml).
189
+
190
+ ## Supported Networks
191
+
192
+ | Chain | Environment | Networks |
193
+ |-------|-------------|----------|
194
+ | Solana | mainnet | mainnet |
195
+ | Solana | testnet | devnet, testnet |
196
+ | EVM | mainnet | ethereum-mainnet, polygon-mainnet, arbitrum-mainnet, optimism-mainnet, base-mainnet |
197
+ | EVM | testnet | ethereum-sepolia, polygon-amoy, arbitrum-sepolia, optimism-sepolia, base-sepolia |
198
+
199
+ 13 networks total (Solana 3 + EVM 10).
200
+
201
+ ## Features
202
+
203
+ - **Self-hosted local daemon** -- No central server; keys never leave your machine
204
+ - **Multi-chain** -- Solana (SPL / Token-2022) and EVM (ERC-20) via `IChainAdapter`
205
+ - **Token, contract, and DeFi** -- Native transfers, token transfers, contract calls, approve, batch transactions, Action Provider plugins (Jupiter Swap, etc.)
206
+ - **USD policy evaluation** -- Price oracles (CoinGecko / Pyth / Chainlink) evaluate all transactions in USD
207
+ - **x402 payments** -- Automatic HTTP 402 payment handling with EIP-3009 signatures
208
+ - **Multiple interfaces** -- REST API, TypeScript SDK, Python SDK, MCP server, CLI, Admin Web UI, Tauri Desktop, Telegram Bot
209
+ - **Skill files** -- Pre-built instruction files that teach AI agents how to use the API
210
+
211
+ ## Documentation
212
+
213
+ | Document | Description |
214
+ |----------|-------------|
215
+ | [Architecture](docs/architecture.md) | System overview, package structure, pipeline, chain adapters |
216
+ | [Security Model](docs/security-model.md) | Authentication, policy engine, Kill Switch, AutoStop |
217
+ | [Deployment Guide](docs/deployment.md) | Docker, npm, configuration reference |
218
+ | [API Reference](docs/api-reference.md) | REST API endpoints and authentication |
219
+ | [Agent Self-Setup Guide](docs/agent-guides/agent-self-setup.md) | Fully autonomous setup with auto-provision |
220
+ | [Agent Skills Integration](docs/agent-guides/agent-skills-integration.md) | Universal guide for 27+ AI agent platforms |
221
+ | [Claude Code Integration](docs/agent-guides/claude-code-integration.md) | Skill files + MCP server setup for Claude Code |
222
+ | [OpenClaw Integration](docs/agent-guides/openclaw-integration.md) | Quick setup for OpenClaw bot |
223
+ | [Wallet SDK Integration](docs/wallet-sdk-integration.md) | Integration guide for wallet developers |
224
+ | [Why WAIaaS?](docs/why-waiaas/) | Background on AI agent wallet security |
225
+ | [Contributing](CONTRIBUTING.md) | Development setup, code style, testing, PR guidelines |
226
+
227
+ ## License
228
+
229
+ [MIT](LICENSE) -- Copyright (c) 2026 WAIaaS Contributors
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@waiaas/adapter-ripple",
3
- "version": "2.13.0",
3
+ "version": "2.14.0",
4
4
  "description": "WAIaaS Ripple chain adapter - XRP Ledger native transfer support",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -27,6 +27,11 @@
27
27
  "files": [
28
28
  "dist"
29
29
  ],
30
+ "dependencies": {
31
+ "xrpl": "^4.1.0",
32
+ "ripple-keypairs": "^2.0.0",
33
+ "@waiaas/core": "2.14.0"
34
+ },
30
35
  "scripts": {
31
36
  "build": "tsc -p tsconfig.build.json",
32
37
  "test": "vitest run",
@@ -38,10 +43,5 @@
38
43
  "lint": "eslint src/",
39
44
  "typecheck": "tsc --noEmit",
40
45
  "clean": "rm -rf dist"
41
- },
42
- "dependencies": {
43
- "@waiaas/core": "workspace:*",
44
- "xrpl": "^4.1.0",
45
- "ripple-keypairs": "^2.0.0"
46
46
  }
47
- }
47
+ }