paralith-mcp 0.0.0-stage → 0.1.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 +43 -2
- package/dist/chains.json +113 -0
- package/dist/client.mjs +10256 -0
- package/dist/graph.json +37 -0
- package/dist/http.mjs +1753 -0
- package/dist/server.mjs +1727 -0
- package/dist/wallet-slot.mjs +5 -0
- package/package.json +48 -4
package/README.md
CHANGED
|
@@ -1,3 +1,44 @@
|
|
|
1
|
-
#
|
|
1
|
+
# paralith-mcp
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
MCP server for the Paralith protocol: an AI with one 24-word phrase plays Rune
|
|
4
|
+
Realm, trades on both order books, moves Rune, and bridges PUSD on Base,
|
|
5
|
+
Solana and Sui. Public docs: `products/orderbook/app/src/docs/pages/ai/mcp.md`
|
|
6
|
+
(served at docs.paralithmarkets.com/ai/mcp).
|
|
7
|
+
|
|
8
|
+
## Use
|
|
9
|
+
|
|
10
|
+
Read-only, no install: connect your MCP client to `https://mcp.paralithmarkets.com/mcp`.
|
|
11
|
+
|
|
12
|
+
To play, trade and bridge, run it locally with a phrase made for the agent (Node 20+):
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
claude mcp add paralith --env PARALITH_MNEMONIC_FILE=/path/to/agent-phrase.txt -- npx -y paralith-mcp@latest
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Other clients: command `npx`, args `["-y", "paralith-mcp@latest"]`, env `PARALITH_MNEMONIC_FILE`.
|
|
19
|
+
Everything deployed is TEST-prefixed; chain gas is real. Tools: https://docs.paralithmarkets.com/ai/tools
|
|
20
|
+
|
|
21
|
+
## Develop
|
|
22
|
+
|
|
23
|
+
Hosted endpoint: `cpdeploy paralith-mono --env mcp` (`.cipherplay/deploy.mcp.env`).
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
npm install
|
|
27
|
+
npm run build # bundle clients + servers into dist/ against the recorded deployment, regenerate the tool reference page
|
|
28
|
+
PARALITH_MNEMONIC_FILE=phrase.txt node scripts/call.mjs # list tools
|
|
29
|
+
PARALITH_MNEMONIC_FILE=phrase.txt node scripts/call.mjs wallet '{}' # call one over real stdio
|
|
30
|
+
npm test # also fails if dist/ or the tool reference is stale
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
- `src/server.mjs`: stdio entry. No phrase means read-only.
|
|
34
|
+
- `src/http.mjs`: hosted read-only endpoint, `POST /mcp`, `GET /health`.
|
|
35
|
+
- `src/build.mjs`: `buildServer()` and the account tools.
|
|
36
|
+
- `src/keys.mjs`: phrase to AO/Base/Solana/Sui signers.
|
|
37
|
+
- `src/game.mjs`, `exchange.mjs`, `vaults.mjs`, `bridge.mjs`, `dao.mjs`: the tools. Game and venue verbs come
|
|
38
|
+
from the shipped client bundle (`backend/native/swarm/build-client.mjs`), never
|
|
39
|
+
reimplemented. Bridge chain calls mirror `products/bridge/testwallets/e2e.mjs`.
|
|
40
|
+
- `src/views.mjs`: compact replies (`full: true` returns raw records).
|
|
41
|
+
- `scripts/tools-doc.mjs`: writes the docs' tool reference (`ai/tools.md`) from the registered tools.
|
|
42
|
+
- `scripts/vault-keeper.mjs`: cranks vaults that need it; report-only unless `--crank` (signs with the phrase). Run `--crank --watch` wherever the venue is operated.
|
|
43
|
+
|
|
44
|
+
`dist/` is committed: the hosted image runs it as is. Re-run `npm run build` after every deploy, commit, and redeploy `mcp` and `docs`.
|
package/dist/chains.json
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
{
|
|
2
|
+
"network": "mainnet",
|
|
3
|
+
"base": {
|
|
4
|
+
"chainId": 8453,
|
|
5
|
+
"rpc": "https://mainnet.base.org",
|
|
6
|
+
"explorer": "https://basescan.org",
|
|
7
|
+
"bridge": "0xCE13574d0Ca4A0dE9c5E5039fD2E9F6ec2593409",
|
|
8
|
+
"deployBlock": 52295541,
|
|
9
|
+
"tokens": [
|
|
10
|
+
{
|
|
11
|
+
"address": "0x405c70597266BefB0504389E333F10785B7919a9",
|
|
12
|
+
"symbol": "TEST-USDC",
|
|
13
|
+
"decimals": 6,
|
|
14
|
+
"faucet": true
|
|
15
|
+
}
|
|
16
|
+
]
|
|
17
|
+
},
|
|
18
|
+
"solana": {
|
|
19
|
+
"cluster": "mainnet-beta",
|
|
20
|
+
"rpc": "https://api.mainnet-beta.solana.com",
|
|
21
|
+
"explorer": "https://solscan.io",
|
|
22
|
+
"programId": "thXGuX413NPvD7zPrSv658UmVEwdki2Tu3zhbU6LoiM",
|
|
23
|
+
"deployed": true,
|
|
24
|
+
"tokens": [
|
|
25
|
+
{
|
|
26
|
+
"mint": "2oJf5PQxWYjLfPQ5yTBt5XE34F1zoP1fHCeFwoPcrdDn",
|
|
27
|
+
"symbol": "TEST-USDC",
|
|
28
|
+
"decimals": 6,
|
|
29
|
+
"tokenProgram": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb",
|
|
30
|
+
"faucet": true
|
|
31
|
+
}
|
|
32
|
+
],
|
|
33
|
+
"programIndex": 4
|
|
34
|
+
},
|
|
35
|
+
"sui": {
|
|
36
|
+
"network": "mainnet",
|
|
37
|
+
"rpc": "https://fullnode.mainnet.sui.io:443",
|
|
38
|
+
"graphql": "https://graphql.mainnet.sui.io/graphql",
|
|
39
|
+
"explorer": "https://suivision.xyz",
|
|
40
|
+
"package": "0x43e8e6eea948b92358e799d9f27042ce9d77cf160ad2736ab0f5fd852d1ffa24",
|
|
41
|
+
"originalPackage": "0x43e8e6eea948b92358e799d9f27042ce9d77cf160ad2736ab0f5fd852d1ffa24",
|
|
42
|
+
"bridge": "0x63e9050c72530fb577379f6b9d979aba3b84afeb83833cbe47a6972443fcd300",
|
|
43
|
+
"faucet": "0x24cdc90a23c129fe3afcc2bbb5c8bd0a63f10dad06ca6c04e03c41eb1e955ac3",
|
|
44
|
+
"tokens": [
|
|
45
|
+
{
|
|
46
|
+
"type": "0x43e8e6eea948b92358e799d9f27042ce9d77cf160ad2736ab0f5fd852d1ffa24::test_usdc::TEST_USDC",
|
|
47
|
+
"symbol": "TEST-USDC",
|
|
48
|
+
"decimals": 6,
|
|
49
|
+
"faucet": true
|
|
50
|
+
}
|
|
51
|
+
],
|
|
52
|
+
"adminCap": "0xbfade5103b48bde0bdb5dcc0b016bb9571a93f79895de542e8853f522166d404",
|
|
53
|
+
"deployed": true,
|
|
54
|
+
"upgradeCap": "0xa1fb1dc179dcdc0579dca5b50a8d1162c1a3c40f531fb723f21de206c1ca78cd"
|
|
55
|
+
},
|
|
56
|
+
"relayers": {
|
|
57
|
+
"base": "0xDaaefC6Fe9C820DB57E9be7C0b566800de11ac22",
|
|
58
|
+
"solana": "9eVvxEPKgpQ4Y2BZV8BWVAeRHWWfSEJy3vrM2AFNzdQ2",
|
|
59
|
+
"sui": "0x46bd8f40263f6e056262f82f13c61d0849d813a030cde4c5bd6a8dd768144e9f",
|
|
60
|
+
"ao": "z2OMYtbWHqNZY01ehkN0tsepznlrZQW-6dXPQO5lxDM"
|
|
61
|
+
},
|
|
62
|
+
"deploy": {
|
|
63
|
+
"sui": {
|
|
64
|
+
"id": "0x43e8e6eea948b92358e799d9f27042ce9d77cf160ad2736ab0f5fd852d1ffa24",
|
|
65
|
+
"version": "sha256:a1fa3e2c74ded1733922a0055ed98b964223253daa25386a1adcec5e84e1b280",
|
|
66
|
+
"localHash": "sha256:a1fa3e2c74ded1733922a0055ed98b964223253daa25386a1adcec5e84e1b280",
|
|
67
|
+
"deployedAt": "2026-10-07T13:59:55.943Z",
|
|
68
|
+
"tx": "2ENtda5acLVU3RyTfTC4U9n56C9F4wNJfhPK8fZq7FtB",
|
|
69
|
+
"action": "FRESH"
|
|
70
|
+
},
|
|
71
|
+
"pusd": {
|
|
72
|
+
"id": "sXuny0tvUizug41AHbbvWfDcjkqK0MEjrWSBTQwp3ac",
|
|
73
|
+
"version": "sha256:4371b32bcc00fd14e85e740ac0f09d41bb6192509bee171d83594c901185eabc",
|
|
74
|
+
"localHash": "sha256:4371b32bcc00fd14e85e740ac0f09d41bb6192509bee171d83594c901185eabc",
|
|
75
|
+
"deployedAt": "2026-10-09T21:40:48.119Z",
|
|
76
|
+
"tx": "sXuny0tvUizug41AHbbvWfDcjkqK0MEjrWSBTQwp3ac",
|
|
77
|
+
"action": "FRESH"
|
|
78
|
+
},
|
|
79
|
+
"base": {
|
|
80
|
+
"id": "0xCE13574d0Ca4A0dE9c5E5039fD2E9F6ec2593409",
|
|
81
|
+
"version": "0x85ba7d3498f2cf2c87849ee1d4966867465431d233837f1158964dece0af9028",
|
|
82
|
+
"localHash": "0x85ba7d3498f2cf2c87849ee1d4966867465431d233837f1158964dece0af9028",
|
|
83
|
+
"deployedAt": "2026-10-07T13:41:12.236Z",
|
|
84
|
+
"tx": "0xb07dcc2967c1f803f7177ce99359f235319771fa0037982d983d1fd586bfdfef",
|
|
85
|
+
"action": "FRESH"
|
|
86
|
+
},
|
|
87
|
+
"solana": {
|
|
88
|
+
"id": "thXGuX413NPvD7zPrSv658UmVEwdki2Tu3zhbU6LoiM",
|
|
89
|
+
"version": "sha256:3ab07b185fa24f3da2a57352b9e2eed5f37475752cb2258d182d8a61afab7d2b",
|
|
90
|
+
"localHash": "sha256:3ab07b185fa24f3da2a57352b9e2eed5f37475752cb2258d182d8a61afab7d2b",
|
|
91
|
+
"deployedAt": "2026-10-07T13:59:36.619Z",
|
|
92
|
+
"tx": "4gzQJeXcj6WZyhTP1djC95LVAsEiH78gVcNBk57KESYkwzWqRNDkkGgotQwENYEXfzqZpfRFcmysrBoHh44TMxz1",
|
|
93
|
+
"action": "FRESH"
|
|
94
|
+
},
|
|
95
|
+
"lastRun": {
|
|
96
|
+
"at": "2026-10-09T21:41:00.279Z",
|
|
97
|
+
"startedAt": "2026-10-09T19:17:15.931Z",
|
|
98
|
+
"steps": [
|
|
99
|
+
{
|
|
100
|
+
"component": "pusd",
|
|
101
|
+
"action": "FRESH",
|
|
102
|
+
"status": "done",
|
|
103
|
+
"tx": "sXuny0tvUizug41AHbbvWfDcjkqK0MEjrWSBTQwp3ac"
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
"component": "tokens",
|
|
107
|
+
"action": "CONFIGURE",
|
|
108
|
+
"status": "done"
|
|
109
|
+
}
|
|
110
|
+
]
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|