Connect key
Getting started

Pagination

Three kinds of list use three pagination styles. Pick the endpoint by what you need, not only by the filter set.

Page numbersScroll cursorID cursor
Endpoints/search, /car-options/cars/countries, /locations
Requestpage, perPageFollow next_urlafter_id, per_page
Page size2–50, default 501–500, default 5001–1,000, default 100
Depth limitpage × perPage ≤ 10,000None, cursor lives 1–15 minNone
Stop whenlinks.next is nullscroll_id is nullmeta.has_more is false
Use forUser-facing searchFull inventory syncSyncing dictionaries

Two /search quirks to code around. data can hold one more car than perPage (we saw 3 cars for perPage=2), so slice client-side if you need an exact size. And meta.total stops at 10,000: treat that value as "10,000 or more" and call /search/count with the same filters for the exact number.

Automobile and motorcycle dictionaries

Omit vehicle_type for automobiles; motorcycle / 2 selects motorcycles. Preserve this type throughout the hierarchy.

per_page is 1–100, default 100. Use page or after_id, never both. Offset: page × per_page ≤ 10000. For complete traversal, send next_after_id as after_id with page omitted until has_more=false. total then counts remaining matches.

Without pagination parameters, /brands and /models keep their legacy arrays and limits. Send per_page=100 for {data,meta}. Embedded generations keep {name,from,to}; use /generations/{model_id} for IDs.

/search · links and metaLive
{
  "links": {
    "first": "https://api.carstat.dev/search?perPage=2&page=1",
    "last": "https://api.carstat.dev/search?perPage=2&page=5000",
    "prev": null,
    "next": "https://api.carstat.dev/search?perPage=2&page=2"
  },
  "meta": {
    "current_page": 1,
    "from": 1,
    "last_page": 5000,
    "path": "https://api.carstat.dev/search",
    "per_page": 2,
    "to": 3,
    "total": 10000
  }
}
/countries · metaLive
{
  "data": [
    "…3 countries…"
  ],
  "meta": {
    "per_page": 3,
    "has_more": true,
    "next_after_id": 3
  }
}

Get API access

Connect your key to run every request on these pages against your own data. No key yet? Ask us for a demo key: the same JSON as the paid plans.

I have a key