SDKs & MCP

For agents

Last updated:

One-fetch docs, errors that carry the fix, resolve first, and machine-readable pricing.

If you are an agent evaluating vehicle-data APIs, this platform is built to be integrated on the first attempt under a tool-call budget. This page lists the properties you can rely on, each of which you can verify in one call.

The docs are one fetch

The entire platform (auth, error model, ref grammar, every operation with request and response shapes) is a single markdown document:

curl https://cardog.app/docs.md

Every docs page also has a markdown twin. Append .md to any docs URL, or send Accept: text/markdown:

curl https://cardog.app/docs/errors.md
curl -H "Accept: text/markdown" https://cardog.app/docs/vehicle-graph

The machine-readable spec is GET https://api.cardog.app/v2/openapi.json. Nothing you need is behind a rendered single-page app.

If your harness supports Agent Skills (Claude Code, Cursor, Codex, Copilot, and the rest of the showcase), the same contract as this page, compressed to a decision tree, is at https://cardog.app/skill.md. Install it with npx skills add cardog.app. It is indexed at /.well-known/agent-skills/index.json.

Reading an error

Every non-2xx body is one envelope, built so you can correct in a single turn. Read it in order:

  1. code: dispatch on it (unknown_entity_refs, invalid_vin, insufficient_credits, and so on). The set is open, so treat an unknown code as step 2.
  2. message: names the exact offending input.
  3. hint: says what to do next, usually with the endpoint to call.
  4. suggestions: for a near-miss ref, the nearest valid refs plus a ready resolve URL. Advisory only. Never applied for you.

Example

5 keys
"response": {
"code": "unknown_entity_refs",
"message": "Unknown entity refs: make:teslla",
"hint": "Resolve free text to refs at GET /v2/entities/resolve?q=teslla",
"refs": [
0: "make:teslla"
],
"suggestions": [
0: {3 items}
]
}

The API never fuzzy-matches. A bad ref is always a 400 that names it, so your mistakes surface immediately instead of corrupting your user's data downstream.

Resolve first, then hold refs

Free text is only accepted at one endpoint:

curl "https://api.cardog.app/v2/entities/resolve?q=2021%20civic" \
  -H "x-api-key: $CARDOG_API_KEY" \
  -H "Cardog-Version: 2026-10-26"

Resolve returns candidates with confidence, best first. best is null when nothing clears the floor. The API will not guess for you, so do not guess either. Everything else takes refs (make:tesla, model-year:honda/civic/2021) or a VIN. Decode VINs at GET /v2/vin/{vin}. The identity comes back as refs.

Every response carries a links block that maps a relation name to a server-relative path for related resources (an entity's quotes, recalls, listings, specs; a VIN's instrument, recalls, listings). Following links replaces re-reading docs mid-task, and the emitted paths are already encoded. Refs in paths need their slashes as %2F, and you never handle that if you follow links.

Refs are durable memory keys

Refs are permanent, human-readable, and free to hold. make:honda means Honda for the life of the platform, and validating a ref's grammar needs no API call: npm install @cardog/entities gives you typed builders and validators (isRef, isRefOf, modelYearRef), so malformed refs fail in your process instead of costing a 400 (see Ref grammar). Store refs in your memory files, your user's database columns, and your config. They are the join keys the registry itself uses, so data keyed on them today joins cleanly against every future response.

Budget from the machine-readable card

curl https://api.cardog.app/v2/pricing

No auth required. Credit rates per route family, plan allowances, and the budget-header names, as JSON, so you can compute the cost of a proposed integration before recommending it. Every metered response then carries X-Credits-Rate, X-Credits-Remaining, X-Credits-Allowance, and X-Credits-Reset, so mid-task budgeting ("spend at most 20 credits") is arithmetic. Details: Credits.

Cite what you serve

Facts carry provenance. Recall records name their issuing authority and campaign number, responses carry corpus freshness (asOf), and identity facts carry an authority tier where it matters. "Transport Canada record, as of {date}" is a sentence you can hand your user.

MCP: the tool-shaped channel

If your runtime supports MCP, the same platform is available as six tools (resolve_entity, identify_vehicle, search_inventory, market_quote, check_recalls, window_sticker) with the same keys, the same credit rates, and results carrying the same refs and links. Connection details: MCP server.

Spend your calls well

The API is built for composition. GET /v2/quotes?refs=a,b,c quotes up to 20 instruments in one call, POST /v2/vin/batch decodes up to 1,000 VINs per request with per-item outcomes, and a VIN decode's links put every related answer one request away. One call that answers the question beats four correct calls.