Skip to main content
Glama

Hive MCP Server

blockchain.ts1.19 kB
// Blockchain-related tools implementation import client from '../config/client'; import { Response } from '../utils/response'; import { handleError } from '../utils/error'; import { successJson, errorResponse } from '../utils/response'; // Get blockchain properties and statistics export async function getChainProperties( // Using an empty object for the params since the tool doesn't need any inputs _params: Record<string, never> ): Promise<Response> { try { // Fetch global properties const dynamicProps = await client.database.getDynamicGlobalProperties(); const chainProps = await client.database.getChainProperties(); const currentMedianHistoryPrice = await client.database.getCurrentMedianHistoryPrice(); // Format the response const response = { dynamic_properties: dynamicProps, chain_properties: chainProps, current_median_history_price: { base: currentMedianHistoryPrice.base, quote: currentMedianHistoryPrice.quote, }, timestamp: new Date().toISOString(), }; return successJson(response); } catch (error) { return errorResponse(handleError(error, 'get_chain_properties')); } }

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/gluneau/hive-mcp-server'

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