Cazana

Similar listings

Live adverts for vehicles similar to the one you query.

POST/similar-listings/3.0

Authorization

Body

Valid JSON

Request body

vrm?string

Required if `vin` not supplied

vin?string

Required if `vrm` not supplied

page?integer

Use with `limit` for custom pagination

Default1
limit?integer

Use with `page` for custom pagination

Default10Range10 ≤ value ≤ 20
showCriteria?boolean

A flag to return the criteria used to query the data

Defaultfalse
showFilters?boolean

A flag to return the filter options for the results set

Defaultfalse
sort?string

Sort listings by a particular characteristic. `distance` is measured in miles. When using `nearestMileage` the nearest mileage to `mileage.nearest` is sorted. If `mileage.nearest` is not passed in the request it will use the estimated mileage of the vehicle.

Value in"age""price""mileage""nearestMileage""distance""colour""firstSeen""lastSeen"
order?string
Value in"asc""desc"
postcode?string

Optional but cannot be used if `longitude` and `latitude` are provided

longitude?number

Optional but must be used with `latitude` and cannot be used if `postcode` is provided.

latitude?number

Optional but must be used with `longitude` and cannot be used if `postcode` is provided.

filters?

Responses

application/json
{
  "total": 0,
  "page": 0,
  "limit": 0,
  "listings": [
    {
      "description": "string",
      "year": 0,
      "firstSeen": "2020-01-01 00:00:00",
      "lastSeen": "2020-01-01 00:00:00",
      "colour": "string",
      "fuelType": "string",
      "price": 0,
      "mileage": 0,
      "transmission": {
        "value": "string"
      },
      "engineCapacity": {
        "value": 0,
        "display": "string"
      },
      "dealer": {
        "type": "Franchise",
        "name": "string",
        "dealerIds": [
          0
        ]
      },
      "adText": "string",
      "location": null,
      "postcode": null,
      "vrm": "string",
      "soldDate": null,
      "images": [
        "string"
      ],
      "insights": {
        "writeoffCategory": "C"
      }
    }
  ],
  "criteria": {
    "vrm": "string",
    "sort": null,
    "order": null,
    "filters": {
      "colours": [
        "brown"
      ],
      "years": [
        2001
      ],
      "live": true,
      "keywords": [
        "Alloy wheels, leather seats, sunroof"
      ],
      "mileage": {
        "min": 1234,
        "max": 54321,
        "nearest": 54321
      },
      "distance": 999,
      "dealerTypes": [
        "franchise"
      ],
      "youngUsed": false,
      "trade": false,
      "categories": [
        "C"
      ]
    },
    "location": {
      "lat": null,
      "lon": null
    },
    "mileage": null,
    "valuation": null,
    "year": null,
    "showFilters": false,
    "showCriteria": false
  },
  "filters": {
    "dealerIndependent": [
      {
        "key": 0,
        "count": 0
      }
    ],
    "sold": [
      {
        "key": 0,
        "count": 0
      }
    ],
    "colour": [
      {
        "key": "string",
        "count": 0
      }
    ],
    "dealerMain": [
      {
        "key": 0,
        "count": 0
      }
    ],
    "plateYear": [
      {
        "key": 0,
        "count": 0
      }
    ],
    "dealerSupermarket": [
      {
        "key": 0,
        "count": 0
      }
    ],
    "saleType": [
      {
        "key": "trade",
        "count": 0
      }
    ],
    "category": [
      {
        "key": "C",
        "count": 0
      }
    ]
  }
}
total?integer
page?integer
limit?integer
listings?
criteria?
filters?

Code samples

curl --request POST \
  --url https://api.cazana.com/similar-listings/3.0 \
  --header 'Authorization: bearer YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '
{
  "vrm": "AB12CDE",
  "vin": "SALGA2BU8HA000000",
  "page": 1,
  "limit": 20,
  "showCriteria": false,
  "showFilters": false,
  "sort": "age",
  "order": "asc",
  "postcode": "EC1Y 2AA",
  "longitude": 52.954,
  "latitude": 52.954,
  "filters": {
    "colours": [
      "brown"
    ],
    "years": [
      2001
    ],
    "live": true,
    "keywords": [
      "Alloy wheels, leather seats, sunroof"
    ],
    "mileage": {
      "min": 1234,
      "max": 54321,
      "nearest": 54321
    },
    "distance": 999,
    "dealerTypes": [
      "franchise"
    ],
    "youngUsed": false,
    "trade": false,
    "categories": [
      "C"
    ]
  }
}
'