MCP & agents
Remote and local MCP, Claude Code, ChatGPT actions.
Remote MCP server
The hosted server speaks MCP over Streamable HTTP. Point any MCP host at it with your key in the Authorization header — nothing to install.
/api/mcp{
"mcpServers": {
"car-image": {
"url": "https://car-imgs.vercel.app/api/mcp",
"headers": {
"Authorization": "Bearer ${CAR_IMAGE_API_KEY}"
}
}
}
}Endpoint: https://car-imgs.vercel.app/api/mcp. Most hosts expand ${CAR_IMAGE_API_KEY} from your environment; if yours does not, keep the config file out of version control.
Tools
| Tool | Cost | Description |
|---|---|---|
get_car_image | 1 credit | Return an image (bytes as image content, or a signed URL) plus usage metadata for a make/model/year/view/color. |
create_car_image_urls | 1 credit per URL | Mint up to 50 signed URLs with a TTL and optional use cap, for embedding in a page or document. |
search_vehicles | free | Search the catalog for makes and models; returns available years so the agent can pick a valid one. |
resolve_vehicle | free | Turn a natural-language phrase ("blue 2022 bmw m3 side profile") into exact request parameters. |
list_image_options | free | Valid views (with yaw degrees), preset colors, size presets and formats. |
get_account | free | Credit balance, auto-reload state and pricing — call it before large batches. |
rate_image | free | Report a good or bad render with a reason; feeds the quality loop. |
describe_api | free | A compact description of endpoints, costs and rules for agents that were not given these docs. |
Tool errors carry the same status, detail and request_id as the REST API, so the agent can follow the error reference.
Claude Code
One command adds the hosted server to Claude Code — nothing to install and nothing to keep up to date:
claude mcp add --transport http car-image https://car-imgs.vercel.app/api/mcp --header "Authorization: Bearer $CAR_IMAGE_API_KEY"Export CAR_IMAGE_API_KEY in the shell you start Claude Code from (or run npx @meterapp/car-image login to get a key), then ask for "a side view of a 2024 Porsche 911 in red". Run /mcp to confirm the eight tools above are connected.
For a project-scoped setup instead, commit the .mcp.json from the Remote (HTTP) tab above — npx @meterapp/car-image agent-config --host claude-code prints both forms.
ChatGPT actions
Create a custom GPT, add an action and import the OpenAPI document from https://car-imgs.vercel.app/openapi.json. Choose Bearer authentication and paste a key with images:read. The schema declares every endpoint, parameter and problem response, so the action works without editing.
Machine-readable docs
- /llms.txt — a compact guide to the API and its rules.
- /agents.md — setup and safety behavior for autonomous agents.
- /openapi.json — OpenAPI 3.1 with typed schemas.
- /errors.md — the error reference as Markdown.
Rules for autonomous agents
- Do not retry a 402. Ask the human to approve a credit purchase.
- Respect 429 and its Retry-After header; back off with jitter.
- A capped delivery URL returns 410 after its last use; mint a new URL.
- A 502 is refunded but consumes the delivery URL — mint a new one before retrying.
- Never present images as OEM photography; they are catalog-bounded generated renders.
- Never move a key into a URL, a prompt or a tool result.