elfa_trending
Analyze trending cryptocurrency tokens with timeframes, chains, and limits using sentiment data and technical analysis tools to monitor token performance.
Instructions
Alias to /v2/aggregations/trending-tokens (timeframe, chain, limit, cursor).
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chain | No | ||
| cursor | No | ||
| limit | No | ||
| timeframe | No |
Implementation Reference
- mcp-server.js:296-301 (registration)Registration of the 'elfa_trending' MCP tool, including name, description, input schema (timeframe, chain, limit, cursor), 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:185-187 (handler)Handler function for the 'elfa_trending' tool. It is an alias that delegates to the 'elfa_trending_tokens' handler."elfa_trending": async (args, meta) => { return toolHandlers["elfa_trending_tokens"](args, meta); },
- mcp-server.js:189-196 (handler)Handler for 'elfa_trending_tokens' (invoked by 'elfa_trending'), constructs query parameters and calls the generic elfa_query tool to fetch from ELFA API /v2/aggregations/trending-tokens."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:303-308 (registration)Registration of the 'elfa_trending_tokens' MCP tool, which implements the core logic delegated by 'elfa_trending'.{ name:"elfa_trending_tokens", description:"Trending tokens aggregation. Params: timeframe, chain, limit, cursor.", inputSchema:{ type:"object", properties:{ timeframe:{type:"string"}, chain:{type:"string"}, limit:{type:"number"}, cursor:{type:"string"} }}, annotations:{ title:"ELFA: Trending Tokens", readOnlyHint:true, openWorldHint:true }
- mcp-server.js:170-182 (helper)Generic 'elfa_query' handler used by 'elfa_trending_tokens' to proxy requests to the ELFA API, including progress notifications."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 }) }; },