**01** Guides

# API docs: your first request in five minutes

apiauto.space is a JSON REST API: used-car catalogs of Korea (Encar), China (Che168) and US auctions (Copart, IAAI) in one record format.

South Korea (Encar) — more than 140,000 active cars; China (Che168) — more than 230,000; USA (Copart and IAAI) — more than 80,000. How the markets differ: [data boundaries](https://apiauto.space/en/docs/markets/).

## Base URL and schema

| What | Value |
| --- | --- |
| Base URL | `https://api.apiauto.space/v1` |
| Format | JSON, UTF-8; times in ISO 8601 UTC |
| Key | `X-API-Key` — [key and headers](https://apiauto.space/en/docs/auth/) |
| Pagination | by cursor: next_cursor of the previous page |
| Schema | [openapi.json](https://api.apiauto.space/openapi.json) · [Swagger UI](https://api.apiauto.space/docs/swagger) · [Redoc](https://api.apiauto.space/docs/redoc) |

## The integration cycle

1. **Import** Copy a market to your side: `GET /v1/cars` with the cursor, up to 100 cars per request.
2. **Poll the changes** Once an hour ask `GET /v1/changes?since=…`: new cars, removed cars and price changes.
3. **Update** Fetch new ones by `GET /v1/cars/{id}`, mark removed ones as sold. In detail: [keeping a catalog in sync](https://apiauto.space/en/docs/sync/).

## Quick start

1. Open [the bot](https://t.me/apiautospace_bot?start=demo) and take a demo key: one day, 100 data requests, up to 20 cars per request, all three markets.
2. Save the key in the APIAUTO_KEY environment variable: it is shown once.
3. Send a request:

curl:

```bash
curl -s "https://api.apiauto.space/v1/cars?market=kr&brand=Kia&limit=20" \
  -H "X-API-Key: $APIAUTO_KEY"
```

Python · httpx:

```python
import os
import httpx

client = httpx.Client(
    base_url="https://api.apiauto.space/v1",
    headers={"X-API-Key": os.environ["APIAUTO_KEY"]},
    timeout=30,
)

# Two pages of 20: every car returned counts against the quota.
params = {"market": "kr", "brand": "Kia", "limit": 20}
for _ in range(2):
    page = client.get("/cars", params=params).raise_for_status().json()
    for car in page["items"]:
        print(car["id"], car["title"], car["price"])
    if not page["next_cursor"]:
        break
    params["cursor"] = page["next_cursor"]
```

JavaScript · fetch:

```js
const response = await fetch(
  "https://api.apiauto.space/v1/cars?market=cn&limit=20",
  { headers: { "X-API-Key": process.env.APIAUTO_KEY } },
);
if (!response.ok) throw new Error(`${response.status}: ${await response.text()}`);

const { items, next_cursor } = await response.json();
console.log(items.map((car) => car.title));
console.log("records left:", response.headers.get("X-Quota-Remaining"));
```

PHP:

```php
<?php
$ch = curl_init("https://api.apiauto.space/v1/cars?market=us&limit=20");
curl_setopt_array($ch, [
    CURLOPT_HTTPHEADER => ["X-API-Key: " . getenv("APIAUTO_KEY")],
    CURLOPT_RETURNTRANSFER => true,
]);
$body = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
curl_close($ch);
if ($status !== 200) {
    throw new RuntimeException("HTTP $status: $body");
}
foreach (json_decode($body, true)["items"] as $car) {
    echo $car["id"], " ", $car["title"], PHP_EOL;
}
```

Ready clients exist: `pip install apiauto-space` — [the Python library](https://pypi.org/project/apiauto-space/), `npm i apiauto` — [the JavaScript and TypeScript library](https://www.npmjs.com/package/apiauto). Their code and Encar examples are [on GitHub](https://github.com/apiauto-space).

The answer is a page of cars and the cursor of the next page. One record looks like this (shortened: two photo links and the first raw fields):

GET /v1/cars/encar:43123480:

```json
{
  "id": "encar:43123480",
  "market": "kr",
  "source": "encar",
  "source_id": "43123480",
  "title": "2024 Volvo V60 Cross Country 2 Gen B5 Ultimate AWD",
  "brand": "Volvo",
  "model": "V60 Cross Country",
  "generation": "V60 Cross Country 2 Gen",
  "trim": "B5 Ultimate AWD",
  "year": 2024,
  "mileage_km": 33375,
  "fuel": "gasoline",
  "transmission": null,
  "engine_cc": null,
  "body_type": null,
  "color": null,
  "vin": null,
  "price": {
    "amount": "40900000.00",
    "currency": "KRW"
  },
  "price_usd": "30101.68",
  "location": {
    "country": "KR",
    "region": "Daegu",
    "city": null
  },
  "photo_count": 4,
  "listing_url": "https://fem.encar.com/cars/detail/43123480",
  "is_active": true,
  "first_seen_at": "2026-11-09T10:07:40.261677Z",
  "last_seen_at": "2026-11-09T10:07:40.261677Z",
  "disappeared_at": null,
  "updated_at": "2026-11-09T10:07:40.261677Z",
  "source_mode": "replica",
  "photos": [
    "https://api.apiauto.space/img/encar:43123480/1.jpg?exp=…&sig=…",
    "https://api.apiauto.space/img/encar:43123480/2.jpg?exp=…&sig=…"
  ],
  "raw": {
    "badge": "B5 얼티메이트 AWD",
    "has_vin": false,
    "form_year": "202405",
    "sell_type": "normal",
    "body_class": null,
    "office_city": "대구",
    "badge_detail": null,
    "has_accident": false
  }
}
```

Keep the key on your server. The API does not allow browser requests (CORS is off), and a key in page code is visible to every visitor.

## Guides

[**Key and headers**](https://apiauto.space/en/docs/auth/)How to send the API key in the X-API-Key header, where to keep it, how to rotate it and what the quota and rate-limit response headers mean.

[**Keeping a catalog in sync**](https://apiauto.space/en/docs/sync/)How to import the Encar, Che168 or Copart and IAAI catalog with a cursor and keep it fresh from the change feed: new and removed cars and prices.

[**The car record and photos**](https://apiauto.space/en/docs/record/)The car record's fields, the same for Encar, Che168, Copart and IAAI: make, model, price, mileage, place, photos and raw; how the signed photo links work.

[**Quota and limits**](https://apiauto.space/en/docs/limits/)What the quota counts — cars and events, not requests; the limits of the four plans, the monthly reset and the key after the paid period.

[**Errors**](https://apiauto.space/en/docs/errors/)The error response body and HTTP codes from 400 to 503 with the error field: what each one means, what to do on 402, 429 and 503 and when to retry.

[**Data boundaries**](https://apiauto.space/en/docs/markets/)How the Korea, China and USA data differ in the API: size, refresh, VIN, photos, what each source lacks and how to learn the age of a market copy.

[**Versions and changelog**](https://apiauto.space/en/docs/changelog/)Compatibility rules within /v1: fields are only added, breaking changes will ship under /v2. What changed in the API, month by month.

## Endpoints

[`GET /v1/cars` **Car catalog**](https://apiauto.space/en/docs/endpoints/cars/)The GET /v1/cars endpoint: filters by make, model, year, price and mileage, sorting, the cursor and sample answers with real Encar, Che168, Copart and IAAI cars.

[`GET /v1/cars/{id}` **Car by id**](https://apiauto.space/en/docs/endpoints/car/)The GET /v1/cars/{id} endpoint: the full record of one Encar, Che168, Copart or IAAI car by an id like encar:…, including cars taken off sale within 14 days.

[`GET /v1/changes` **Change feed**](https://apiauto.space/en/docs/endpoints/changes/)The GET /v1/changes endpoint: new cars, cars taken off sale, price drops and rises with a percentage threshold — since a moment, with a cursor.

[`GET /v1/us/live` **Live US search**](https://apiauto.space/en/docs/endpoints/live/)The GET /v1/us/live endpoint: search Copart and IAAI lots at the auction data provider when a car is not in the copy. Pro and Max plans, a separate counter.

[`GET /v1/references/…` **References**](https://apiauto.space/en/docs/endpoints/references/)Free references: a market's makes and models with car counts, the allowed values of fuel, gearbox and body, and market freshness. They spend no quota.

[`GET /v1/usage` **Quota usage**](https://apiauto.space/en/docs/endpoints/usage/)The GET /v1/usage endpoint: the plan, its term, the period quota and how much of it is spent — in total and per market, live US search included. Free.

| More | What it does | Quota |
| --- | --- | --- |
| `GET /img/{id}/{n}.jpg` | A car photo by the signed link from the record. | free |
| `GET /healthz` | Health: 503 when any market is past its freshness threshold. | free |

---

Page: https://apiauto.space/en/docs/
