list_latest_dex_tokens
Retrieve tokens with completed DexScreener profiles — description, website, socials — as an early feed of newly launched, promoted tokens. Verify prices via pair data before using.
Instructions
List the latest tokens that have set up a profile on DexScreener.
A profile means the project has filled in description / website / socials on DexScreener — typically a sign of a newly-launched but at least somewhat promoted token. Useful as an early-signal feed for "what's new today?"
NOTE: a profile does not imply legitimacy or liquidity. Cross-check with
get_dex_token_pairs(token_address, ...) before quoting prices.
Args: limit: Max tokens to return (the API itself returns up to ~30).
Returns:
Array of token-profile objects with chainId, tokenAddress, url,
description, icon, and a links array of websites/socials.
On API failure returns {"error": "..."}.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No |
Implementation Reference
- coin_mcp/dexscreener.py:228-250 (handler)The async function 'list_latest_dex_tokens' executes the tool logic: calls DexScreener's /token-profiles/latest/v1 API, checks for errors, and returns up to `limit` items. Decorated with @mcp.tool() which registers it as an MCP tool.
async def list_latest_dex_tokens(limit: int = 20) -> Any: """List the latest tokens that have set up a profile on DexScreener. A profile means the project has filled in description / website / socials on DexScreener — typically a sign of a newly-launched but at least somewhat promoted token. Useful as an early-signal feed for "what's new today?" NOTE: a profile does not imply legitimacy or liquidity. Cross-check with `get_dex_token_pairs(token_address, ...)` before quoting prices. Args: limit: Max tokens to return (the API itself returns up to ~30). Returns: Array of token-profile objects with `chainId`, `tokenAddress`, `url`, `description`, `icon`, and a `links` array of websites/socials. On API failure returns `{"error": "..."}`. """ resp = await _http_get(f"{DEXSCREENER_BASE}/token-profiles/latest/v1") if is_error(resp): return resp items = resp if isinstance(resp, list) else [] return items[: max(0, limit)] - coin_mcp/dexscreener.py:227-227 (registration)The @mcp.tool() decorator on the function registers 'list_latest_dex_tokens' with the FastMCP server as an MCP tool.
@mcp.tool() - coin_mcp/core.py:35-36 (helper)The DEXSCREENER_BASE constant defines the API base URL used by list_latest_dex_tokens to construct the full endpoint URL.
DEXSCREENER_BASE = "https://api.dexscreener.com" - coin_mcp/core.py:206-217 (helper)The _http_get helper function handles HTTP GET requests, used by list_latest_dex_tokens to fetch data from the DexScreener API.
async def _http_get( url: str, params: dict[str, Any] | None = None, headers: dict[str, str] | None = None, ) -> Any: """GET a URL and return JSON, or a structured error dict on failure. Delegates to the in-process TTL cache so repeated identical requests don't re-hit the network. See `coin_mcp.cache` for routing rules. """ from . import cache # local import to avoid circular dependency at module load return await cache.cached_http_get(url, params=params, headers=headers) - coin_mcp/dexscreener.py:238-244 (schema)The docstring/Args section defines the input schema (limit: int = 20) and the return schema (array of token-profile objects).
Args: limit: Max tokens to return (the API itself returns up to ~30). Returns: Array of token-profile objects with `chainId`, `tokenAddress`, `url`, `description`, `icon`, and a `links` array of websites/socials. On API failure returns `{"error": "..."}`.