Skip to main content
Glama

Binal Digital Twin MCP Server

by binal182
test-mcp.js•1.22 kB
const https = require('http'); // Test the MCP server const testMcpServer = async () => { const postData = JSON.stringify({ method: 'tools/call', params: { name: 'search_binal_knowledge', arguments: { query: 'tell me about yourself' } } }); const options = { hostname: 'localhost', port: 3000, path: '/api/mcp', method: 'POST', headers: { 'Content-Type': 'application/json', 'Content-Length': Buffer.byteLength(postData) } }; return new Promise((resolve, reject) => { const req = https.request(options, (res) => { let data = ''; res.on('data', (chunk) => { data += chunk; }); res.on('end', () => { try { const result = JSON.parse(data); resolve(result); } catch (e) { resolve(data); } }); }); req.on('error', (e) => { reject(e); }); req.write(postData); req.end(); }); }; // Run the test testMcpServer() .then((result) => { console.log('MCP Server Response:'); console.log(JSON.stringify(result, null, 2)); }) .catch((error) => { console.error('Error testing MCP server:', error); });

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/binal182/binal-mcpserver'

If you have feedback or need assistance with the MCP directory API, please join our Discord server