@ton/mcp 0.1.13 → 0.1.15-alpha.1

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 (72) hide show
  1. package/README.md +218 -23
  2. package/dist/cli.js +21208 -25445
  3. package/dist/contracts/agentic_wallet/AgenticWallet.source.d.ts +11 -0
  4. package/dist/contracts/agentic_wallet/AgenticWallet.source.d.ts.map +1 -0
  5. package/dist/contracts/agentic_wallet/AgenticWalletAdapter.d.ts +62 -0
  6. package/dist/contracts/agentic_wallet/AgenticWalletAdapter.d.ts.map +1 -0
  7. package/dist/contracts/agentic_wallet/actions.d.ts.map +1 -0
  8. package/dist/contracts/agentic_wallet/index.d.ts +10 -0
  9. package/dist/contracts/agentic_wallet/index.d.ts.map +1 -0
  10. package/dist/factory.d.ts +13 -34
  11. package/dist/factory.d.ts.map +1 -1
  12. package/dist/http-mode.d.ts +25 -0
  13. package/dist/http-mode.d.ts.map +1 -0
  14. package/dist/index.cjs +99024 -103135
  15. package/dist/index.d.ts +8 -1
  16. package/dist/index.d.ts.map +1 -1
  17. package/dist/index.js +99021 -103136
  18. package/dist/registry/config.d.ts +202 -0
  19. package/dist/registry/config.d.ts.map +1 -0
  20. package/dist/runtime/wallet-runtime.d.ts +35 -0
  21. package/dist/runtime/wallet-runtime.d.ts.map +1 -0
  22. package/dist/serverless.cjs +19249 -23360
  23. package/dist/serverless.d.ts.map +1 -1
  24. package/dist/serverless.js +19250 -23361
  25. package/dist/services/AgenticOnboardingService.d.ts +51 -0
  26. package/dist/services/AgenticOnboardingService.d.ts.map +1 -0
  27. package/dist/services/AgenticSetupSessionManager.d.ts +82 -0
  28. package/dist/services/AgenticSetupSessionManager.d.ts.map +1 -0
  29. package/dist/services/McpWalletService.d.ts +64 -0
  30. package/dist/services/McpWalletService.d.ts.map +1 -1
  31. package/dist/services/WalletRegistryService.d.ts +99 -0
  32. package/dist/services/WalletRegistryService.d.ts.map +1 -0
  33. package/dist/tools/address-tools.d.ts +119 -0
  34. package/dist/tools/address-tools.d.ts.map +1 -0
  35. package/dist/tools/agentic-onboarding-tools.d.ts +120 -0
  36. package/dist/tools/agentic-onboarding-tools.d.ts.map +1 -0
  37. package/dist/tools/agentic-tools.d.ts +71 -0
  38. package/dist/tools/agentic-tools.d.ts.map +1 -0
  39. package/dist/tools/dns-tools.d.ts.map +1 -1
  40. package/dist/tools/index.d.ts +4 -0
  41. package/dist/tools/index.d.ts.map +1 -1
  42. package/dist/tools/sanitize.d.ts +44 -0
  43. package/dist/tools/sanitize.d.ts.map +1 -0
  44. package/dist/tools/transfer-tools.d.ts +8 -8
  45. package/dist/tools/transfer-tools.d.ts.map +1 -1
  46. package/dist/tools/wallet-management-tools.d.ts +249 -0
  47. package/dist/tools/wallet-management-tools.d.ts.map +1 -0
  48. package/dist/types/config.d.ts +3 -3
  49. package/dist/types/config.d.ts.map +1 -1
  50. package/dist/utils/address.d.ts +15 -0
  51. package/dist/utils/address.d.ts.map +1 -0
  52. package/dist/utils/agentic.d.ts +61 -0
  53. package/dist/utils/agentic.d.ts.map +1 -0
  54. package/dist/utils/math.d.ts +9 -0
  55. package/dist/utils/math.d.ts.map +1 -0
  56. package/dist/utils/private-key.d.ts +14 -0
  57. package/dist/utils/private-key.d.ts.map +1 -0
  58. package/dist/utils/ton-client.d.ts +14 -0
  59. package/dist/utils/ton-client.d.ts.map +1 -0
  60. package/llms.txt +141 -5
  61. package/package.json +2 -2
  62. package/skills/SKILL.md +59 -7
  63. package/dist/contracts/w5_ownable/WalletOwnable.d.ts +0 -87
  64. package/dist/contracts/w5_ownable/WalletOwnable.d.ts.map +0 -1
  65. package/dist/contracts/w5_ownable/WalletOwnable.source.d.ts +0 -11
  66. package/dist/contracts/w5_ownable/WalletOwnable.source.d.ts.map +0 -1
  67. package/dist/contracts/w5_ownable/WalletOwnableAdapter.d.ts +0 -111
  68. package/dist/contracts/w5_ownable/WalletOwnableAdapter.d.ts.map +0 -1
  69. package/dist/contracts/w5_ownable/actions.d.ts.map +0 -1
  70. package/dist/contracts/w5_ownable/index.d.ts +0 -12
  71. package/dist/contracts/w5_ownable/index.d.ts.map +0 -1
  72. /package/dist/contracts/{w5_ownable → agentic_wallet}/actions.d.ts +0 -0
package/README.md CHANGED
@@ -8,37 +8,81 @@ A Model Context Protocol (MCP) server for TON blockchain wallet operations. Buil
8
8
  - **Transfers**: Send TON, Jettons, and NFTs to any address
9
9
  - **Swaps**: Get quotes for token swaps via DEX aggregators
10
10
  - **NFTs**: List, inspect, and transfer NFTs
11
- - **DNS**: Resolve `.ton` domains and reverse-lookup addresses
11
+ - **DNS**: Resolve TON DNS-compatible domains and reverse-lookup addresses
12
12
  - **Known Jettons**: Built-in directory of popular tokens
13
- - **Multiple Transports**: Stdio (default), HTTP server, and serverless modes
13
+ - **Agentic Wallets**: Manage agentic wallets. Create, import, or manage your agentic wallets and sub-wallets.
14
+ - **Multiple Transports**: Stdio (default), multi-session HTTP server, and serverless modes
14
15
 
15
16
  ## Quick Start
16
17
 
17
- > **Note:** We currently do not support launch without a mnemonic or private key.
18
+ `@ton/mcp` supports two runtime modes.
19
+
20
+ - **Agentic Wallets mode**: Server starts from local config registry at `~/.config/ton/config.json` or `TON_CONFIG_PATH`
21
+ - **Single-wallet mode**: if `MNEMONIC` or `PRIVATE_KEY` is set, the server starts with one in-memory wallet
22
+
23
+ ### Agentic Wallets mode
24
+
25
+ Self-custody wallets for autonomous agents. Your AI agent gets TON wallet capabilities — transfers, swaps, NFTs. User keeps the master key, agent keeps the operator key.
26
+
27
+ **Learn more about [Agentic Wallets](https://agentic-wallets-dashboard.vercel.app/).**
28
+
29
+ Agentic Wallets mode is the default mode. It allows you to manage agentic wallets and agentic sub-wallets. To create your first agentic wallet, ask your agent to `create agentic wallet` and follow the instructions.
30
+
31
+ ```bash
32
+ # Run as stdio MCP server in agentic mode
33
+ npx @ton/mcp@alpha
34
+
35
+ # Run as HTTP server in agentic mode
36
+ npx @ton/mcp@alpha --http
37
+
38
+ # Run in registry mode with a custom config path
39
+ TON_CONFIG_PATH=/path/to/config.json npx @ton/mcp@alpha
40
+ ```
41
+
42
+ ### Single-wallet mode
43
+
44
+ Single-wallet mode is a mode where the server starts with one in-memory wallet. This mode is useful when you want to manage a single wallet or when you want to use the server for a one-off task.
18
45
 
19
46
  ```bash
20
- # Run as stdio MCP server
21
- MNEMONIC="word1 word2 ..." npx @ton/mcp
47
+ # Run as stdio MCP server with mnemonic
48
+ MNEMONIC="word1 word2 ..." npx @ton/mcp@alpha
22
49
 
23
50
  # Run as HTTP server (port 3000)
24
- MNEMONIC="word1 word2 ..." npx @ton/mcp --http
51
+ MNEMONIC="word1 word2 ..." npx @ton/mcp@alpha --http
25
52
 
26
- # Run as HTTP server on custom port
27
- MNEMONIC="word1 word2 ..." npx @ton/mcp --http 8080
53
+ # Run as HTTP server on custom port and private key
54
+ PRIVATE_KEY="0xyour_private_key" npx @ton/mcp@alpha --http 8080
28
55
  ```
29
56
 
30
57
  ## Usage with MCP Clients
31
58
 
32
59
  ### Claude Desktop / Cursor
33
60
 
34
- Add to your MCP configuration:
61
+ Agentic Wallets mode:
35
62
 
36
63
  ```json
37
64
  {
38
65
  "mcpServers": {
39
66
  "ton": {
40
67
  "command": "npx",
41
- "args": ["-y", "@ton/mcp"],
68
+ "args": ["-y", "@ton/mcp@alpha"],
69
+ "env": {
70
+ "// optional config path": "",
71
+ "TON_CONFIG_PATH": "/absolute/path/to/config.json"
72
+ }
73
+ }
74
+ }
75
+ }
76
+ ```
77
+
78
+ Single-wallet mode:
79
+
80
+ ```json
81
+ {
82
+ "mcpServers": {
83
+ "ton": {
84
+ "command": "npx",
85
+ "args": ["-y", "@ton/mcp@alpha"],
42
86
  "env": {
43
87
  "MNEMONIC": "word1 word2 word3 ...",
44
88
  "PRIVATE_KEY": "0xyour_private_key_here (optional, alternative to MNEMONIC)"
@@ -53,22 +97,33 @@ Add to your MCP configuration:
53
97
  Start the server and point your MCP client to the endpoint:
54
98
 
55
99
  ```bash
56
- MNEMONIC="word1 word2 ..." npx @ton/mcp --http 3000
100
+ npx @ton/mcp@alpha --http 3000
57
101
  # MCP endpoint: http://localhost:3000/mcp
58
102
  ```
59
103
 
104
+ HTTP mode keeps a separate MCP session/transport per client session id, so multiple clients can initialize and reconnect independently.
105
+
60
106
  ## Environment Variables
61
107
 
62
- | Variable | Default | Description |
108
+ | Variable | Default | Description |
63
109
  |-------------------|-----------|-------------------------------------------------------|
64
- | `NETWORK` | `mainnet` | TON network (`mainnet` / `testnet`) |
65
- | `MNEMONIC` | | Space-separated 24-word mnemonic phrase for wallet |
66
- | `PRIVATE_KEY` | | Hex-encoded private key (alternative to mnemonic) |
67
- | `WALLET_VERSION` | `v5r1` | Wallet version to use (`v5r1` or `v4r2`) |
68
- | `TONCENTER_API_KEY`| | API key for Toncenter (optional, for higher rate limits)|
110
+ | `NETWORK` | `mainnet` | TON network (`mainnet` / `testnet`) and default env override target for `TONCENTER_API_KEY` |
111
+ | `MNEMONIC` | | Space-separated 24-word mnemonic phrase for single-wallet mode |
112
+ | `PRIVATE_KEY` | | Hex-encoded private key: 32-byte or 64-byte (alternative to mnemonic) |
113
+ | `WALLET_VERSION` | `v5r1` | Wallet version to use in single-wallet mode (`v5r1`, `v4r2`, or `agentic`) |
114
+ | `AGENTIC_WALLET_ADDRESS` | | Agentic wallet address (required for `WALLET_VERSION=agentic`, unless derived from init params) |
115
+ | `AGENTIC_WALLET_NFT_INDEX` | | Agentic wallet NFT index / subwallet id (`uint256`, optional) |
116
+ | `AGENTIC_COLLECTION_ADDRESS` | `EQByQ19qvWxW7VibSbGEgZiYMqilHY5y1a_eeSL2VaXhfy07` | Agentic collection address override for single-wallet mode |
117
+ | `TONCENTER_API_KEY` | | API key for Toncenter (optional, for higher rate limits) |
118
+ | `TON_CONFIG_PATH` | `~/.config/ton/config.json` | Config path for registry mode |
119
+ | `AGENTIC_CALLBACK_BASE_URL` | | Optional public base URL for agentic onboarding callbacks |
120
+ | `AGENTIC_CALLBACK_HOST` | `127.0.0.1` | Host for the local callback server in stdio mode |
121
+ | `AGENTIC_CALLBACK_PORT` | random free port | Port for the local callback server in stdio mode |
69
122
 
70
123
  ## Available Tools
71
124
 
125
+ In registry mode, wallet-scoped tools below also accept optional `walletSelector`. If omitted, the active wallet is used.
126
+
72
127
  ### Wallet Info
73
128
 
74
129
  #### `get_wallet`
@@ -76,6 +131,24 @@ Get the current wallet address and network information.
76
131
 
77
132
  **Returns:** Wallet address and network (`mainnet` or `testnet`)
78
133
 
134
+ #### `list_wallets` (registry mode only)
135
+ List all wallets stored in the local TON config registry.
136
+
137
+ #### `get_current_wallet` (registry mode only)
138
+ Get the currently active wallet from the local TON config registry.
139
+
140
+ #### `set_active_wallet` (registry mode only)
141
+ Set the active wallet by id, name, or address.
142
+
143
+ **Parameters:**
144
+ - `walletSelector` (required): Wallet id, name, or address
145
+
146
+ #### `remove_wallet` (registry mode only)
147
+ Soft-delete a stored wallet from the local registry. Removed wallets remain in the config file but are hidden from MCP listings and wallet selection.
148
+
149
+ **Parameters:**
150
+ - `walletSelector` (required): Wallet id, name, or address
151
+
79
152
  ### Balance & History
80
153
 
81
154
  #### `get_balance`
@@ -83,6 +156,14 @@ Get the TON balance of the wallet.
83
156
 
84
157
  **Returns:** Balance in TON and nanoTON
85
158
 
159
+ #### `get_balance_by_address`
160
+ Get the TON balance of any address.
161
+
162
+ **Parameters:**
163
+ - `address` (required): TON wallet address
164
+
165
+ **Returns:** Address balance in TON and nanoTON
166
+
86
167
  #### `get_jetton_balance`
87
168
  Get the balance of a specific Jetton in the wallet.
88
169
 
@@ -92,6 +173,20 @@ Get the balance of a specific Jetton in the wallet.
92
173
  #### `get_jettons`
93
174
  List all Jettons held by the wallet with balances and metadata.
94
175
 
176
+ #### `get_jettons_by_address`
177
+ List Jettons held by any address with balances and metadata.
178
+
179
+ **Parameters:**
180
+ - `address` (required): Owner wallet address
181
+ - `limit` (optional): Maximum number of jettons to return (default: 20, max: 100)
182
+ - `offset` (optional): Offset for pagination (default: 0)
183
+
184
+ #### `get_jetton_info`
185
+ Get metadata for a Jetton master contract.
186
+
187
+ **Parameters:**
188
+ - `address` (required): Jetton master contract address
189
+
95
190
  #### `get_transactions`
96
191
  Get recent transaction history for the wallet (TON transfers, Jetton transfers, swaps, etc.).
97
192
 
@@ -109,7 +204,7 @@ Get the status of a transaction by its normalized hash to know if it is pending,
109
204
  ### Transfers
110
205
 
111
206
  #### `send_ton`
112
- Send TON to an address. Amount is in human-readable format (e.g., `"1.5"` means 1.5 TON). Returns `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
207
+ Send TON to an address. Amount is in human-readable format (e.g., `"1.5"` means 1.5 TON). Returns top-level `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
113
208
 
114
209
  **Parameters:**
115
210
  - `toAddress` (required): Recipient TON address
@@ -117,7 +212,7 @@ Send TON to an address. Amount is in human-readable format (e.g., `"1.5"` means
117
212
  - `comment` (optional): Transaction comment/memo
118
213
 
119
214
  #### `send_jetton`
120
- Send Jettons to an address. Amount is in human-readable format. Returns `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
215
+ Send Jettons to an address. Amount is in human-readable format. Returns top-level `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
121
216
 
122
217
  **Parameters:**
123
218
  - `toAddress` (required): Recipient TON address
@@ -126,7 +221,7 @@ Send Jettons to an address. Amount is in human-readable format. Returns `normali
126
221
  - `comment` (optional): Transaction comment/memo
127
222
 
128
223
  #### `send_raw_transaction`
129
- Send a raw transaction with full control over messages. Supports multiple messages. Returns `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
224
+ Send a raw transaction with full control over messages. Supports multiple messages. Returns top-level `normalizedHash`. Default flow: poll `get_transaction_status` until completed or failed; user can skip.
130
225
 
131
226
  **Parameters:**
132
227
  - `messages` (required): Array of messages, each with:
@@ -137,6 +232,16 @@ Send a raw transaction with full control over messages. Supports multiple messag
137
232
  - `validUntil` (optional): Unix timestamp after which the transaction becomes invalid
138
233
  - `fromAddress` (optional): Sender wallet address
139
234
 
235
+ #### `agentic_deploy_subwallet`
236
+ Deploy a new Agentic sub-wallet from the current wallet. Works only with an agentic root wallet that can sign and only when the current wallet is a user-root wallet (`deployedByUser=true`). Returns `normalizedHash`, deployed sub-wallet address, and computed sub-wallet NFT index. NFT metadata is written in onchain TEP-64 format.
237
+
238
+ **Default flow:** Poll `get_transaction_status` with the returned `normalizedHash` until completion.
239
+
240
+ **Parameters:**
241
+ - `operatorPublicKey` (required): New sub-wallet operator public key (`uint256`, decimal or `0x`-prefixed hex)
242
+ - `metadata` (required): Onchain TEP-64 metadata object. Must include at least `name` (non-empty string).
243
+ - `amountTon` (optional): TON amount to attach for deployment in TON units (default: `"0.05"`)
244
+
140
245
  ### Swaps
141
246
 
142
247
  #### `get_swap_quote`
@@ -157,6 +262,14 @@ List all NFTs in the wallet with metadata, collection info, and attributes.
157
262
  - `limit` (optional): Maximum number of NFTs to return (default: 20, max: 100)
158
263
  - `offset` (optional): Offset for pagination (default: 0)
159
264
 
265
+ #### `get_nfts_by_address`
266
+ List NFTs held by any address with metadata, collection info, and attributes.
267
+
268
+ **Parameters:**
269
+ - `address` (required): Owner wallet address
270
+ - `limit` (optional): Maximum number of NFTs to return (default: 20, max: 100)
271
+ - `offset` (optional): Offset for pagination (default: 0)
272
+
160
273
  #### `get_nft`
161
274
  Get detailed information about a specific NFT by its address.
162
275
 
@@ -174,13 +287,13 @@ Transfer an NFT from the wallet to another address. Returns `normalizedHash`. De
174
287
  ### DNS
175
288
 
176
289
  #### `resolve_dns`
177
- Resolve a TON DNS domain (e.g., `"foundation.ton"`) to a wallet address.
290
+ Resolve a TON DNS-compatible domain name (e.g., `"foundation.ton"` or `"viqex.t.me"`) to a wallet address.
178
291
 
179
292
  **Parameters:**
180
293
  - `domain` (required): TON DNS domain to resolve
181
294
 
182
295
  #### `back_resolve_dns`
183
- Reverse-resolve a TON wallet address to its `.ton` domain.
296
+ Reverse-resolve a TON wallet address to its associated DNS domain when available.
184
297
 
185
298
  **Parameters:**
186
299
  - `address` (required): TON wallet address to reverse resolve
@@ -190,16 +303,82 @@ Reverse-resolve a TON wallet address to its `.ton` domain.
190
303
  #### `get_known_jettons`
191
304
  Get a list of known/popular Jettons on TON with their addresses and metadata. Useful for looking up token addresses for swaps or transfers.
192
305
 
306
+ #### `agentic_validate_wallet` (registry mode only)
307
+ Validate an existing agentic wallet address against the expected network and collection.
308
+
309
+ **Parameters:**
310
+ - `address` (required): Agentic wallet address
311
+ - `network` (optional): Network to validate against
312
+ - `collectionAddress` (optional): Collection address override
313
+ - `ownerAddress` (optional): Expected owner address
314
+
315
+ #### `agentic_list_wallets_by_owner` (registry mode only)
316
+ List agentic wallets owned by a given main wallet address.
317
+
318
+ **Parameters:**
319
+ - `ownerAddress` (required): Owner wallet address
320
+ - `network` (optional): Network to query
321
+
322
+ #### `agentic_import_wallet` (registry mode only)
323
+ Import an existing agentic wallet into the local TON config registry, recovering a matching pending key draft when available. Otherwise the wallet is imported read-only until `agentic_rotate_operator_key` is completed.
324
+
325
+ **Parameters:**
326
+ - `address` (required): Agentic wallet address
327
+ - `network` (optional): Network to validate against
328
+ - `name` (optional): Wallet display name
329
+
330
+ #### `agentic_start_root_wallet_setup` (registry mode only)
331
+ Start first-root-agent setup: generate operator keys, persist a pending draft, and return a dashboard URL for the user to create the wallet from their main wallet.
332
+
333
+ **Parameters:**
334
+ - `network` (optional): Network for the new root wallet
335
+ - `name` (optional): Agent display name
336
+ - `source` (optional): Source or description
337
+ - `collectionAddress` (optional): Collection address override
338
+ - `tonDeposit` (optional): TON deposit hint for the dashboard
339
+
340
+ Pending onboarding callback state is persisted in the local config, so the setup can be resumed after MCP transport restarts. In HTTP mode, callback URLs are stable on the MCP server base URL. In stdio mode, use `AGENTIC_CALLBACK_BASE_URL` and/or `AGENTIC_CALLBACK_PORT` if you need a fixed callback endpoint across restarts.
341
+
342
+ #### `agentic_list_pending_root_wallet_setups` (registry mode only)
343
+ List pending root-agent onboarding drafts and their callback/session status.
344
+
345
+ #### `agentic_get_root_wallet_setup` (registry mode only)
346
+ Get one pending root-agent onboarding draft by setup id.
347
+
348
+ **Parameters:**
349
+ - `setupId` (required): Pending setup identifier
350
+
351
+ #### `agentic_complete_root_wallet_setup` (registry mode only)
352
+ Complete root-agent onboarding from callback payload or manually supplied wallet address, then import the resulting wallet and make it active.
353
+
354
+ **Parameters:**
355
+ - `setupId` (required): Pending setup identifier
356
+ - `walletAddress` (optional): Manual wallet address if no callback was received
357
+ - `ownerAddress` (optional): Owner address hint for validation
358
+
359
+ #### `agentic_cancel_root_wallet_setup` (registry mode only)
360
+ Cancel a pending root-agent onboarding draft and remove its pending state.
361
+
362
+ **Parameters:**
363
+ - `setupId` (required): Pending setup identifier
364
+
193
365
  ## Serverless Deployment
194
366
 
195
367
  The package exports a `@ton/mcp/serverless` entry point for deploying as a serverless function (AWS Lambda, Vercel, Cloudflare Workers, etc.). Credentials are passed via request headers instead of environment variables.
196
368
 
369
+ By design, serverless mode:
370
+
371
+ - operates in single-wallet mode only
372
+ - does not use the wallet registry
373
+ - does not expose wallet management and onboarding tools
374
+ - uses standard `v5r1` wallet type
375
+
197
376
  ### Headers
198
377
 
199
378
  | Header | Description |
200
379
  |-----------------|----------------------------------------------------------|
201
380
  | `MNEMONIC` | 24-word mnemonic phrase |
202
- | `PRIVATE_KEY` | Hex-encoded private key (takes priority over `MNEMONIC`) |
381
+ | `PRIVATE_KEY` | Hex-encoded private key: 32-byte seed or 64-byte (takes priority over `MNEMONIC`) |
203
382
  | `NETWORK` | `mainnet` (default) or `testnet` |
204
383
  | `TONCENTER_KEY` | Optional TonCenter API key for higher rate limits |
205
384
 
@@ -249,6 +428,10 @@ pnpm --filter @ton/mcp dev:cli:http
249
428
  # Build
250
429
  pnpm --filter @ton/mcp build
251
430
 
431
+ # Checks
432
+ pnpm --filter @ton/mcp test
433
+ pnpm --filter @ton/mcp typecheck
434
+
252
435
  # Run built version
253
436
  node packages/mcp/dist/cli.js
254
437
  node packages/mcp/dist/cli.js --http 8080
@@ -282,6 +465,18 @@ const wallet = await kit.addWallet(walletAdapter);
282
465
  const server = await createTonWalletMCP({ wallet });
283
466
  ```
284
467
 
468
+ The same factory also supports registry mode:
469
+
470
+ ```typescript
471
+ import { createTonWalletMCP } from '@ton/mcp';
472
+
473
+ const server = await createTonWalletMCP({
474
+ networks: {
475
+ mainnet: { apiKey: process.env.TONCENTER_API_KEY },
476
+ },
477
+ });
478
+ ```
479
+
285
480
  ## License
286
481
 
287
482
  MIT