Skip to main content
Glama

zora_explore_top_gainers

Discover coins with the highest market cap increase over the last 24 hours on the Zora Coins ecosystem. Use this tool to identify trending assets and analyze market movements on Base mainnet.

Instructions

Coins with highest market cap delta over last 24h.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
countNo
afterNo

Implementation Reference

  • src/index.ts:290-296 (registration)
    Registers the 'zora_explore_top_gainers' tool with the MCP server using the exploreTool helper function, specifying the handler from CoinsSDK.getCoinsTopGainers, title, and description.
    exploreTool( "zora_explore_top_gainers", // @ts-expect-error - TypeScript can't resolve barrel exports properly CoinsSDK.getCoinsTopGainers, "Top gainers (24h)", "Coins with highest market cap delta over last 24h." );
  • The core handler function for the tool (shared with other explore tools), which invokes the underlying SDK function (CoinsSDK.getCoinsTopGainers) with pagination parameters and returns a formatted text response.
    async ({ after, count }) => { const resp = await fn({ after, count }); return { content: [{ type: "text", text: json(resp) }] }; }
  • Defines the input schema for the tool, including optional pagination parameters 'after' and 'count'.
    title, description, inputSchema: { count: z.number().int().min(1).max(100).optional(), after: z.string().optional(), }, },
  • The exploreTool helper function that registers paginated query tools like zora_explore_top_gainers with schema, handler wrapper, and server registration.
    function exploreTool( name: string, fn: (args: { after?: string; count?: number }) => Promise<unknown>, title: string, description: string ) { server.registerTool( name, { title, description, inputSchema: { count: z.number().int().min(1).max(100).optional(), after: z.string().optional(), }, }, async ({ after, count }) => { const resp = await fn({ after, count }); return { content: [{ type: "text", text: json(resp) }] }; } ); }
  • Utility function used in the handler to format responses as pretty-printed JSON, handling bigints.
    function json(data: unknown): string { return JSON.stringify( data, (_k, v) => (typeof v === "bigint" ? v.toString() : v), 2 ); }

Latest Blog Posts

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/r4topunk/zora-coins-mcp-server'

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