get_token_feeds
Get all indicator feeds for a token, including feed names (EMA, RSI, Bollinger, Volatility across timeframes), reliability stats, and data source count.
Instructions
Get all available indicator feeds for a specific token.
Shows every feed name (EMA, RSI, Bollinger, Volatility across all timeframes), the token's reliability stats, and data source count. Feed names are what you pass to the on-chain oracle to request data.
Args: engine_id: Token engine ID (e.g., 'bitcoin', 'solana', 'bittensor', 'aave', 'pol'). Use list_tokens() to see all available IDs.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| engine_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- src/pythia_oracle_mcp/server.py:198-249 (handler)The 'get_token_feeds' tool handler function. It retrieves all available indicator feeds for a specific token by engine_id, fetches live data from feed-status.json, looks up the token, groups feeds by indicator type (EMA, RSI, Bollinger, Volatility), and returns a formatted report.
@mcp.tool() async def get_token_feeds(engine_id: str) -> str: """Get all available indicator feeds for a specific token. Shows every feed name (EMA, RSI, Bollinger, Volatility across all timeframes), the token's reliability stats, and data source count. Feed names are what you pass to the on-chain oracle to request data. Args: engine_id: Token engine ID (e.g., 'bitcoin', 'solana', 'bittensor', 'aave', 'pol'). Use list_tokens() to see all available IDs. """ data = await _fetch_data() tokens = data.get("tokens", []) token = next((t for t in tokens if t["engine_id"] == engine_id), None) if not token: available = sorted(t["engine_id"] for t in tokens) return ( f"No token found for '{engine_id}'.\n\n" f"Available: {', '.join(available)}" ) feed_names = token.get("feed_names", []) lines = [ f"{token['symbol']} ({token['name']}) — {token.get('pair', '?')}", f"Status: {token.get('status', '?')} | " f"30d uptime: {token.get('uptime_30d', '?')}% | " f"Data sources: {token.get('sources', '?')}", f"Category: {token.get('category', '?')} | " f"Ecosystem: {token.get('ecosystem', '?')}", f"\n{len(feed_names)} indicator feeds available:\n", ] # Group by indicator type groups: dict[str, list[str]] = {} for name in sorted(feed_names): # Strip token prefix to get indicator part suffix = name[len(engine_id) + 1:] cat = suffix.split("_")[0] groups.setdefault(cat, []).append(suffix) for cat, feeds in sorted(groups.items()): lines.append(f" {cat}:") for feed in feeds: lines.append(f" {engine_id}_{feed}") lines.append("") lines.append("To request any feed on-chain, pass the full feed name") lines.append("(e.g., 'bitcoin_RSI_1H_14') to the Pythia consumer contract.") lines.append(f"\nUse get_integration_guide() for Solidity code.") return "\n".join(lines) - src/pythia_oracle_mcp/server.py:198-198 (registration)The @mcp.tool() decorator registers 'get_token_feeds' as an MCP tool on the FastMCP instance.
@mcp.tool()