Data & API Tools¶
get_cryptocurrency_price¶
Fetches the current USD price of any cryptocurrency via the CoinGecko free API โ no API key required.
@mcp.tool()
def get_cryptocurrency_price(crypto: str) -> str:
"""Fetch the current USD price of a cryptocurrency via CoinGecko."""
Parameters
| Name | Type | Description |
|---|---|---|
crypto |
str |
CoinGecko coin ID, e.g. bitcoin, ethereum, solana |
Example prompts
What's the current price of Bitcoin?
Get me Ethereum and Solana prices
Compare the prices of bitcoin, ethereum, and dogecoin
Find coin IDs
Use coingecko.com/en/coins to find the exact ID for any coin.
perform_web_search¶
Searches the web using a configurable LLM provider (Perplexity, OpenAI, or any OpenAI-compatible API).
@mcp.tool()
def perform_web_search(query: str) -> str:
"""Search the web using a configurable LLM provider."""
Parameters
| Name | Type | Description |
|---|---|---|
query |
str |
Any question or search query |
Provider configuration
WEB_SEARCH_PROVIDER |
Default model | Notes |
|---|---|---|
perplexity |
sonar-pro |
Requires PERPLEXITY_API_KEY |
openai |
gpt-4o-mini |
Requires OPENAI_API_KEY |
| custom | Set via WEB_SEARCH_MODEL |
Set WEB_SEARCH_BASE_URL too |
Example prompts