# Vehicle Database API
> Decode any Vehicle Identification Number (VIN) into a full, structured vehicle specification — make, manufacturer, model, year, trim, series, body class, vehicle type, drive type, doors, engine (cylinders, displacement, horsepower, configuration and primary/secondary fuel), transmission style, gross vehicle weight rating and the manufacturing plant (country, city, state, company). Partial VINs with wildcards are supported and an optional model year improves accuracy. The API also lists every vehicle make (optionally for a vehicle type such as car, truck or motorcycle) and all models for a given make and year. Backed by the official NHTSA vPIC database, with clean, predictable JSON and no raw-data wrangling. Every endpoint accepts input via the query string or the request body. Ideal for automotive marketplaces, insurance and fleet tools, dealer and parts catalogues, and vehicle-registration flows.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/vehicledb-api/..."
```

## Pricing
- **Free** (Free) — 40,000 calls/Mo, 2 req/s
- **Basic** ($9/Mo) — 480,000 calls/Mo, 5 req/s
- **Pro** ($25/Mo) — 2,600,000 calls/Mo, 20 req/s
- **Mega** ($62/Mo) — 14,000,000 calls/Mo, 60 req/s

## Endpoints

### Vehicle

#### `GET /v1/decode` — Decode a VIN to vehicle specs

**Parameters:**
- `vin` (query, required, string) — 8-17 char VIN (* allowed for partial) Example: `5YJ3E1EA7KF317324`
- `year` (query, optional, string) — Model year (improves partial VINs) Example: `2019`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/vehicledb-api/v1/decode?vin=5YJ3E1EA7KF317324&year=2019"
```

**Response:**
```json
{
    "data": {
        "vin": "5YJ3E1EA7KF317324",
        "gvwr": "Class 1: 6,000 lb or less (2,722 kg or less)",
        "make": "TESLA",
        "trim": null,
        "year": 2019,
        "doors": 4,
        "model": "Model 3",
        "plant": {
            "city": "FREMONT",
            "state": "CALIFORNIA",
            "company": null,
            "country": "UNITED STATES (USA)"
        },
        "engine": {
            "cylinders": null,
            "horsepower": null,
            "fuel_primary": "Electric",
            "configuration": null,
            "displacement_l": null,
            "fuel_secondary": null
        },
        "series": null,
        "body_class": "Sedan/Saloon",
        "drive_type": null,
        "error_code": "1",
        "error_text": "1 - Check Digit (9th position) does not calculate properly",
        "manufacturer": "TESLA, INC.",
        "transmission": "Automatic",
        "vehicle_type": "PASSENGER CAR"
    },
    "meta": {
        "timestamp": "2026-05-30T22:48:27.145Z",
        "request_id": "510676c6-a0bc-46b7-a2fa-edb9b4b4d622"
    },
    "status": "ok",
    "message": "VIN decoded",
    "success": true
}
```

#### `GET /v1/makes` — All makes (or for a vehicle type)

**Parameters:**
- `type` (query, optional, string) — car|truck|motorcycle|bus|trailer|... Example: `car`
- `limit` (query, optional, string) — Max makes Example: `500`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/vehicledb-api/v1/makes?type=car&limit=500"
```

**Response:**
```json
{
    "data": {
        "type": "car",
        "count": 193,
        "makes": [
            {
                "id": 440,
                "name": "ASTON MARTIN"
            },
            {
                "id": 441,
                "name": "TESLA"
            },
            {
                "id": 442,
                "name": "JAGUAR"
            },
            {
                "id": 443,
                "name": "MASERATI"
            },
            {
                "id": 445,
                "name": "ROLLS-ROYCE"
            },
            {
                "id": 448,
                "name": "TOYOTA"
            },
            {
                "id": 449,
                "name": "MERCEDES-BENZ"
            },
            {
                "id": 452,
                "name": "BMW"
            },
            {
                "id": 454,
                "name": "BUGATTI"
            },
            {
                "id": 456,
                "name": "MINI"
            },
            {
                "id": 460,
                "name": "FORD"
            },
            {
                "id": 464,
                "name": "LINCOLN"
            },
            {
                "id": 465,
                "name": "MERCURY"
            },
            {
                "id": 466,
                "name": "LOTUS"
            },
            {
                "id": 467,
                "name": "CHEVROLET"
            },
            {
                "id": 468,
                "name": "BU
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/models` — Models for a make

**Parameters:**
- `make` (query, required, string) — Make name Example: `honda`
- `year` (query, optional, string) — Model year Example: `2022`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/vehicledb-api/v1/models?make=honda&year=2022"
```

**Response:**
```json
{
    "data": {
        "make": "honda",
        "year": 2022,
        "count": 111,
        "models": [
            {
                "id": 1861,
                "make": "HONDA",
                "name": "Accord"
            },
            {
                "id": 1863,
                "make": "HONDA",
                "name": "Civic"
            },
            {
                "id": 1864,
                "make": "HONDA",
                "name": "Pilot"
            },
            {
                "id": 1865,
                "make": "HONDA",
                "name": "CR-V"
            },
            {
                "id": 1866,
                "make": "HONDA",
                "name": "Ridgeline"
            },
            {
                "id": 1869,
                "make": "HONDA",
                "name": "Odyssey"
            },
            {
                "id": 1870,
                "make": "HONDA",
                "name": "Insight"
            },
            {
                "id": 3234,
                "make": "HONDA",
                "name": "PCX150"
            },
            {
                "id": 3249,
                "make": "HONDA",
                "name": "Gold Wing"
            },
            {
                "id": 3251,
                "make": "HONDA",
                "name": "NC700X"
            },
            {
                "id": 3253,
                "make": "HONDA",
                "name": "NPS50 (Ruckus)"
            },
            {
                
…(truncated, see openapi.json for full schema)
```


---
Marketplace page: https://www.oanor.com/api/vehicledb-api
OpenAPI spec: https://www.oanor.com/api/vehicledb-api/openapi.json
