finance
CoinGecko MCP Integration for Vercel AI SDK
Connect CoinGecko to Vercel AI SDK through the local KosmoKrator MCP gateway with scoped tools, credentials, and write policy.
Connect CoinGecko to Vercel AI SDK
Use KosmoKrator as a local integration gateway for Vercel AI SDK agents and scripts.
Create an MCP client that starts or connects to the KosmoKrator gateway for the selected integration. The gateway is local, scoped to this integration, and starts with
--write=deny so Vercel AI SDK can inspect read-capable tools without receiving write access by default.
CoinGecko MCP Config for Vercel AI SDK
Prefer CLI JSON calls when a workflow only needs one deterministic integration operation.
{
"mcpServers": {
"kosmokrator-coingecko": {
"type": "stdio",
"command": "kosmo",
"args": [
"mcp:serve",
"--integration=coingecko",
"--write=deny"
]
}
}
} Run the Gateway Manually
kosmokrator mcp:serve --integration=coingecko --write=deny Why Use KosmoKrator Here
Expose only CoinGecko instead of a broad multi-service tool list.
Reuse credentials already configured for the KosmoKrator CLI and Lua runtime.
Start read-only, then opt into ask or allow for trusted workspaces.
CoinGecko Tools Visible to Vercel AI SDK
Vercel AI SDK sees stable MCP tool names generated from the CoinGecko integration catalog.
| MCP tool | Source function | Type | Description |
|---|---|---|---|
integration__coingecko__coingecko_global | coingecko.coingecko_global | Read | Get overall crypto market statistics — total market cap, BTC dominance, active cryptocurrencies, trading volume, and more. |
integration__coingecko__coingecko_history | coingecko.coingecko_history | Read | Get historical price, volume, and market cap chart data for a cryptocurrency over a time period. Returns timestamped data points with summary statistics. |
integration__coingecko__coingecko_info | coingecko.coingecko_info | Read | Get a full coin profile — description, categories, links (website, whitepaper, social), and current market data snapshot. Use `coingecko_search_coins` first to find the coin ID. |
integration__coingecko__coingecko_markets | coingecko.coingecko_markets | Read | Get top cryptocurrencies ranked by market cap with full market data (price, volume, ATH, supply, price changes). Supports filtering by category or specific coin IDs. |
integration__coingecko__coingecko_ohlc | coingecko.coingecko_ohlc | Read | Get OHLC (Open/High/Low/Close) candlestick data for a cryptocurrency for technical analysis. |
integration__coingecko__coingecko_price | coingecko.coingecko_price | Read | Get current price for one or more cryptocurrencies (by CoinGecko ID). Includes 24h change, volume, and market cap. Use `coingecko_search_coins` first to find coin IDs. |
integration__coingecko__coingecko_search_coins | coingecko.coingecko_search_coins | Read | Find cryptocurrencies by name or ticker symbol (e.g. "bitcoin", "ETH", "solana"). Returns matching coin IDs which are needed for other CoinGecko tools. |
integration__coingecko__coingecko_trending | coingecko.coingecko_trending | Read | Get the top trending cryptocurrencies in the last 24 hours based on search activity on CoinGecko. |