How do I connect an AI agent to Cartroute?
Pick the fastest path your agent supports. None of them needs an account to try: without a key, search, product, price-history and coupon calls are free for 10 calls a day per IP. For more, one API call creates an account with 200 free credits.
1. Just fetch a URL (no key, no setup)
Any agent that can make an HTTP request, including browsing assistants, can search Amazon, Best Buy and eBay with one GET. Without a key, results come from recent searches and the products Cartroute re-checks daily; with a free key every search is a fresh lookup at the retailers. Add format=md for a compact Markdown answer instead of JSON.
curl "https://cart-route.com/api/v1/search?q=sony+wh-1000xm6" # Markdown, for agents that read text curl "https://cart-route.com/api/v1/search?q=sony+wh-1000xm6&format=md" # Same thing as a web page a browsing assistant can open https://cart-route.com/search?q=sony+wh-1000xm6&format=md
Responses carry an anonymous block with the calls left today. Filters: max_price, condition=new|used, retailers=amazon,bestbuy, sort=price_asc. Full list: search reference.
2. Add the MCP server (Claude, Cursor, VS Code, ChatGPT)
One remote server, seven tools, Streamable HTTP at https://cart-route.com/mcp. It works without a key; add Authorization: Bearer cr_live_... later for more calls.
claude mcp add --transport http cartroute https://cart-route.com/mcp
# with a key, for more than 10 calls a day
claude mcp add --transport http cartroute https://cart-route.com/mcp \
--header "Authorization: Bearer $CARTROUTE_API_KEY"
# Claude.ai and Claude Desktop
Settings → Connectors → Add custom connector
Name: Cartroute
URL: https://cart-route.com/mcp
# ChatGPT, where custom connectors are enabled (developer mode)
Settings → Connectors → Create
Name: Cartroute
MCP server URL: https://cart-route.com/mcp
Authentication: none (or an API key for more calls)
# Windsurf, Cline, Zed and other clients with a JSON config { "mcpServers": { "cartroute": { "url": "https://cart-route.com/mcp" } } }
Tools: search_products, get_product, get_price_history, find_coupons, list_retailers, list_categories, get_account. Details: MCP guide.
3. Load ready-made tools for function calling
GET https://cart-route.com/api/v1/tools returns the same seven tools as OpenAI, Anthropic and Gemini tool schemas, plus how to execute each one over HTTP. Pass them straight to the model.
import anthropic, requests tools = requests.get("https://cart-route.com/api/v1/tools?format=anthropic").json() client = anthropic.Anthropic() msg = client.messages.create( model="claude-opus-5", max_tokens=2048, tools=tools, messages=[{"role": "user", "content": "Where is the Sony WH-1000XM6 cheapest?"}], )
from openai import OpenAI import requests tools = requests.get("https://cart-route.com/api/v1/tools?format=openai").json() resp = OpenAI().chat.completions.create( model="gpt-5", tools=tools, messages=[{"role": "user", "content": "Where is the Sony WH-1000XM6 cheapest?"}], )
import requests spec = requests.get("https://cart-route.com/api/v1/tools").json()["execute"] def run_tool(name, args, api_key=None): e = spec[name] url, params = e["url"], {} for k, v in args.items(): if k in e["path_params"]: url = url.replace("{" + k + "}", str(v)) else: params[e["arguments_to_query"].get(k, k)] = ",".join(v) if isinstance(v, list) else v headers = {"Authorization": f"Bearer {api_key}"} if api_key else {} return requests.get(url, params=params, headers=headers, timeout=30).json()
4. Frameworks and no-code tools
from agents import Agent, Runner from agents.mcp import MCPServerStreamableHttp async with MCPServerStreamableHttp(params={"url": "https://cart-route.com/mcp"}) as cartroute: agent = Agent(name="Shopper", mcp_servers=[cartroute], instructions="Find the cheapest place to buy what the user asks for.") result = await Runner.run(agent, "Cheapest Sony WH-1000XM6?")
from langchain_mcp_adapters.client import MultiServerMCPClient client = MultiServerMCPClient({ "cartroute": {"url": "https://cart-route.com/mcp", "transport": "streamable_http"}, }) tools = await client.get_tools() # pass to create_react_agent(...) or any tool-calling model
HTTP Request step
Method: GET
URL: https://cart-route.com/api/v1/search
Query: q = {{ the product }} format = md (optional)
Header: Authorization = Bearer cr_live_... (optional, for more calls)
5. Get a key in one call (for more than 10 calls a day)
An agent can create an account for its user and receive a working key with 100 credits right away (100 more when the email is confirmed). Or sign up on the website.
curl -X POST "https://cart-route.com/api/v1/accounts" -H "Content-Type: application/json" -d '{
"email": "[email protected]", "password": "at-least-12-characters",
"full_name": "Your Name", "accept_terms": true
}'
# → 201 { "api_key": "cr_live_...", "credits_remaining": 100, ... }
Machine-readable descriptions
- OpenAPI 3.1: every endpoint and field, importable as GPT Actions or into any HTTP tool builder.
- Tool definitions for OpenAI, Anthropic and Gemini.
- MCP server card and API catalog (RFC 9727).
- llms.txt and llms-full.txt for coding agents.