@gala-chain/launchpad-mcp-server 1.2.21 → 1.2.22
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/package.json +2 -2
- package/test-explain.mjs +0 -73
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gala-chain/launchpad-mcp-server",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.22",
|
|
4
4
|
"description": "MCP server for Gala Launchpad SDK with 41 tools - AI agents can interact with Gala Launchpad and learn SDK usage",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"registry": "https://registry.npmjs.org/"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@gala-chain/launchpad-sdk": "^3.7.
|
|
59
|
+
"@gala-chain/launchpad-sdk": "^3.7.7",
|
|
60
60
|
"@modelcontextprotocol/sdk": "^0.5.0",
|
|
61
61
|
"ethers": "^6.15.0",
|
|
62
62
|
"@gala-chain/api": "^2.4.3",
|
package/test-explain.mjs
DELETED
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import { spawn } from 'child_process';
|
|
3
|
-
|
|
4
|
-
const PRIVATE_KEY = '0x1234567890123456789012345678901234567890123456789012345678901234';
|
|
5
|
-
|
|
6
|
-
const serverProcess = spawn('node', ['dist/index.js'], {
|
|
7
|
-
env: { ...process.env, PRIVATE_KEY }
|
|
8
|
-
});
|
|
9
|
-
|
|
10
|
-
let responseBuffer = '';
|
|
11
|
-
|
|
12
|
-
serverProcess.stdout.on('data', (data) => {
|
|
13
|
-
responseBuffer += data.toString();
|
|
14
|
-
|
|
15
|
-
// Try to parse JSON-RPC messages
|
|
16
|
-
const lines = responseBuffer.split('\n');
|
|
17
|
-
responseBuffer = lines.pop(); // Keep incomplete line
|
|
18
|
-
|
|
19
|
-
for (const line of lines) {
|
|
20
|
-
if (!line.trim()) continue;
|
|
21
|
-
try {
|
|
22
|
-
const response = JSON.parse(line);
|
|
23
|
-
if (response.result?.success) {
|
|
24
|
-
console.log('\n✅ explainSdkUsage Tool Response:');
|
|
25
|
-
console.log('Topic:', response.result.data.topic);
|
|
26
|
-
console.log('SDK Version:', response.result.data.sdkVersion);
|
|
27
|
-
console.log('\nExplanation Preview:');
|
|
28
|
-
console.log(response.result.data.explanation.substring(0, 500) + '...\n');
|
|
29
|
-
serverProcess.kill();
|
|
30
|
-
process.exit(0);
|
|
31
|
-
}
|
|
32
|
-
} catch (e) {
|
|
33
|
-
// Ignore parse errors
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
|
|
38
|
-
serverProcess.stderr.on('data', (data) => {
|
|
39
|
-
console.error('Error:', data.toString());
|
|
40
|
-
});
|
|
41
|
-
|
|
42
|
-
// Initialize
|
|
43
|
-
serverProcess.stdin.write(JSON.stringify({
|
|
44
|
-
jsonrpc: '2.0',
|
|
45
|
-
id: 1,
|
|
46
|
-
method: 'initialize',
|
|
47
|
-
params: {
|
|
48
|
-
protocolVersion: '2024-11-05',
|
|
49
|
-
capabilities: {}
|
|
50
|
-
}
|
|
51
|
-
}) + '\n');
|
|
52
|
-
|
|
53
|
-
// Wait a bit then call the tool
|
|
54
|
-
setTimeout(() => {
|
|
55
|
-
serverProcess.stdin.write(JSON.stringify({
|
|
56
|
-
jsonrpc: '2.0',
|
|
57
|
-
id: 2,
|
|
58
|
-
method: 'tools/call',
|
|
59
|
-
params: {
|
|
60
|
-
name: 'gala_launchpad_explain_sdk_usage',
|
|
61
|
-
arguments: {
|
|
62
|
-
topic: 'buy-tokens'
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
}) + '\n');
|
|
66
|
-
}, 1000);
|
|
67
|
-
|
|
68
|
-
// Timeout after 5 seconds
|
|
69
|
-
setTimeout(() => {
|
|
70
|
-
console.error('❌ Test timed out');
|
|
71
|
-
serverProcess.kill();
|
|
72
|
-
process.exit(1);
|
|
73
|
-
}, 5000);
|