elfa_trending
Identify trending cryptocurrency tokens by analyzing market sentiment and technical indicators across specified timeframes and blockchains.
Instructions
Alias to /v2/aggregations/trending-tokens (timeframe, chain, limit, cursor).
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| timeframe | No | ||
| chain | No | ||
| limit | No | ||
| cursor | No |
Implementation Reference
- mcp-server.js:185-196 (handler)Handler for the 'elfa_trending' tool (lines 185-187: alias) and the delegated 'elfa_trending_tokens' handler (189-196), which constructs query parameters and calls the generic 'elfa_query' tool to fetch from ELFA's /v2/aggregations/trending-tokens endpoint."elfa_trending": async (args, meta) => { return toolHandlers["elfa_trending_tokens"](args, meta); }, "elfa_trending_tokens": async (args, meta) => { const query = {}; if (args && args.timeframe !== undefined) query.timeframe = args.timeframe; // "24h","7d","30d" if (args && args.chain !== undefined) query.chain = args.chain; if (args && args.limit !== undefined) query.limit = args.limit; if (args && args.cursor !== undefined) query.cursor = args.cursor; return toolHandlers["elfa_query"]({ path: "/v2/aggregations/trending-tokens", method: "GET", query }, meta); },
- mcp-server.js:296-302 (registration)Registration of the 'elfa_trending' tool in the tools list, including description, input schema, and annotations.{ name:"elfa_trending", description:"Alias to /v2/aggregations/trending-tokens (timeframe, chain, limit, cursor).", inputSchema:{ type:"object", properties:{ timeframe:{type:"string"}, chain:{type:"string"}, limit:{type:"number"}, cursor:{type:"string"} }}, annotations:{ title:"ELFA: Trending (Alias)", readOnlyHint:true, openWorldHint:true } },
- mcp-server.js:298-300 (schema)Input schema definition for the 'elfa_trending' tool parameters: timeframe (string), chain (string), limit (number), cursor (string).inputSchema:{ type:"object", properties:{ timeframe:{type:"string"}, chain:{type:"string"}, limit:{type:"number"}, cursor:{type:"string"} }},
- mcp-server.js:170-182 (helper)Generic 'elfa_query' helper handler used by 'elfa_trending_tokens' to proxy requests to ELFA API endpoints using elfaFetch."elfa_query": async (args, meta) => { const path = args && args.path; if (!path || typeof path !== "string") return { content: textContent({ error:true, message:"Missing required 'path' (string)" }), isError:true }; const method = (args.method || "GET").toUpperCase(); const query = args.query || undefined; const body = args.body || undefined; progressNotify(meta && meta.progressToken, 1, 3, "Calling ELFA"); const { ok, status, data } = await elfaFetch(path, { method, query, body }); progressNotify(meta && meta.progressToken, 2, 3, "Formatting result"); if (!ok) return { content: textContent({ error:true, status, data }), isError:true, _meta:{ status } }; progressNotify(meta && meta.progressToken, 3, 3, "Done"); return { content: textContent({ ok:true, status, data }) }; },