@yamo/mcp-server 1.0.1 → 1.0.5

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 (2) hide show
  1. package/README.md +141 -9
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,7 +1,17 @@
1
- # 🤖 YAMO Chain MCP Server (v1.0.0 - Protocol v0.4)
1
+ # 🤖 YAMO Chain MCP Server [![npm version](https://badge.fury.io/js/@yamo%2Fmcp-server.svg)](https://www.npmjs.com/package/@yamo/mcp-server)
2
2
 
3
3
  This MCP Server acts as a bridge, allowing LLMs to interact with the YAMO Blockchain. It is now powered by `@yamo/core` for robust IPFS handling.
4
4
 
5
+ ## 📦 Installation
6
+
7
+ ```bash
8
+ # Global installation (recommended)
9
+ npm install -g @yamo/mcp-server
10
+
11
+ # Or use npx (no installation needed)
12
+ npx @yamo/mcp-server
13
+ ```
14
+
5
15
  ## 🧰 Tools Provided
6
16
 
7
17
  ### `yamo_submit_block`
@@ -15,22 +25,144 @@ Verifies if a specific hash matches the immutable record.
15
25
 
16
26
  ## ⚙️ Configuration
17
27
 
28
+ ### Option 1: Claude Desktop Integration (Recommended)
29
+
18
30
  Add to your Claude Desktop config (`claude_desktop_config.json`):
19
31
 
32
+ **With Global Installation:**
33
+ ```json
34
+ {
35
+ "mcpServers": {
36
+ "yamo-chain": {
37
+ "command": "yamo-mcp-server",
38
+ "env": {
39
+ "CONTRACT_ADDRESS": "0x3c9440fa8d604E732233ea17095e14be1a53b015",
40
+ "RPC_URL": "https://ethereum-sepolia-rpc.publicnode.com",
41
+ "PRIVATE_KEY": "0xYOUR_PRIVATE_KEY",
42
+ "USE_REAL_IPFS": "false",
43
+ "PINATA_JWT": "optional_if_using_real_ipfs"
44
+ }
45
+ }
46
+ }
47
+ }
48
+ ```
49
+
50
+ **With npx (no installation):**
20
51
  ```json
21
52
  {
22
53
  "mcpServers": {
23
54
  "yamo-chain": {
24
- "command": "node",
25
- "args": ["/absolute/path/to/yamo/packages/mcp-server/dist/index.js"],
55
+ "command": "npx",
56
+ "args": ["@yamo/mcp-server"],
26
57
  "env": {
27
- "CONTRACT_ADDRESS": "0xe7f1...",
28
- "RPC_URL": "http://127.0.0.1:8545",
29
- "PRIVATE_KEY": "0x...",
30
- "USE_REAL_IPFS": "true",
31
- "PINATA_JWT": "eyJ..."
58
+ "CONTRACT_ADDRESS": "0x3c9440fa8d604E732233ea17095e14be1a53b015",
59
+ "RPC_URL": "https://ethereum-sepolia-rpc.publicnode.com",
60
+ "PRIVATE_KEY": "0xYOUR_PRIVATE_KEY",
61
+ "USE_REAL_IPFS": "false"
32
62
  }
33
63
  }
34
64
  }
35
65
  }
36
- ```
66
+ ```
67
+
68
+ ### Option 2: Standalone Usage
69
+
70
+ Set environment variables and run:
71
+
72
+ ```bash
73
+ export CONTRACT_ADDRESS=0x3c9440fa8d604E732233ea17095e14be1a53b015
74
+ export RPC_URL=https://ethereum-sepolia-rpc.publicnode.com
75
+ export PRIVATE_KEY=0xYOUR_PRIVATE_KEY
76
+
77
+ # With global install
78
+ yamo-mcp-server
79
+
80
+ # Or with npx
81
+ npx @yamo/mcp-server
82
+ ```
83
+
84
+ ## 🌐 Networks
85
+
86
+ ### Sepolia Testnet (Production - Recommended)
87
+
88
+ **Configuration:**
89
+ - Contract: `0x3c9440fa8d604E732233ea17095e14be1a53b015`
90
+ - RPC: `https://ethereum-sepolia-rpc.publicnode.com`
91
+
92
+ **Requirements:**
93
+ - ✅ Wallet with Sepolia ETH for gas
94
+ - ✅ Public RPC endpoint (no API key needed)
95
+
96
+ ### Local Development
97
+
98
+ **Configuration:**
99
+ - Contract: Deploy using `@yamo/contracts`
100
+ - RPC: `http://127.0.0.1:8545`
101
+
102
+ **Requirements:**
103
+ - ⚠️ Local Hardhat node must be running: `npx hardhat node`
104
+ - ⚠️ Contract must be deployed locally
105
+ - ⚠️ Wallet must be funded with local ETH
106
+
107
+ ## 💰 Wallet Setup
108
+
109
+ ### 1. Generate a Wallet
110
+
111
+ If you don't have a private key:
112
+ ```bash
113
+ node -e "const ethers = require('ethers'); const w = ethers.Wallet.createRandom(); console.log('Address:', w.address); console.log('Private Key:', w.privateKey);"
114
+ ```
115
+
116
+ ### 2. Get Sepolia ETH (Testnet Only)
117
+
118
+ Your wallet needs Sepolia ETH for gas. Use your **wallet address** (not private key) with these faucets:
119
+
120
+ **Alchemy Faucet** (Fastest - 0.5 ETH):
121
+ - https://www.alchemy.com/faucets/ethereum-sepolia
122
+ - Sign in with Google/GitHub
123
+
124
+ **PoW Faucet** (No login - 0.05-0.1 ETH):
125
+ - https://sepolia-faucet.pk910.de/
126
+ - Mine for ~5 minutes
127
+
128
+ **Google Cloud Faucet** (0.05 ETH):
129
+ - https://cloud.google.com/application/web3/faucet/ethereum/sepolia
130
+
131
+ ### 3. Check Your Balance
132
+
133
+ ```bash
134
+ # Replace with your wallet address
135
+ curl -X POST https://ethereum-sepolia-rpc.publicnode.com \
136
+ -H "Content-Type: application/json" \
137
+ -d '{"jsonrpc":"2.0","method":"eth_getBalance","params":["0xYOUR_ADDRESS","latest"],"id":1}'
138
+ ```
139
+
140
+ If result is `"0x0"`, you need more ETH!
141
+
142
+ ## ⚠️ Common Issues
143
+
144
+ ### "Sender doesn't have enough funds"
145
+
146
+ **Problem:** Your wallet has 0 ETH or insufficient balance
147
+
148
+ **Solution:**
149
+ 1. Check you're using **Sepolia RPC**, not localhost
150
+ 2. Verify your wallet address has Sepolia ETH (see faucets above)
151
+ 3. Make sure `PRIVATE_KEY` matches the funded wallet
152
+
153
+ ### "Connection refused" or "ECONNREFUSED"
154
+
155
+ **Problem:** RPC_URL points to `http://127.0.0.1:8545` but no local node running
156
+
157
+ **Solution:**
158
+ - **For Sepolia:** Change RPC to `https://ethereum-sepolia-rpc.publicnode.com`
159
+ - **For Local:** Start Hardhat node: `cd packages/contracts && npx hardhat node`
160
+
161
+ ### Balance shows 0 but I have ETH
162
+
163
+ **Problem:** Wrong network - you might have mainnet ETH, not Sepolia ETH
164
+
165
+ **Solution:**
166
+ 1. Verify RPC is Sepolia: `https://ethereum-sepolia-rpc.publicnode.com`
167
+ 2. Check balance on Sepolia: https://sepolia.etherscan.io/
168
+ 3. Get Sepolia testnet ETH from faucets (see above)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yamo/mcp-server",
3
- "version": "1.0.1",
3
+ "version": "1.0.5",
4
4
  "description": "YAMO Protocol v0.4 - Model Context Protocol server for AI agents",
5
5
  "main": "dist/index.js",
6
6
  "type": "commonjs",