# Coches — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Coches provides 5 callable API endpoints through the Parse marketplace.

**Category:** Automotive | **Website:** [coches.net/](https://coches.net/) | **Docs:** [parse.bot/marketplace/98481a74-16db-41dc-9d96-4c1af36c2a29/coches-net-api](https://parse.bot/marketplace/98481a74-16db-41dc-9d96-4c1af36c2a29/coches-net-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_makes_and_models

Returns the full hierarchical catalog of car makes and their models. Each make has an ID and label, with a nested array of models (each with its own ID and label). Use make/model IDs as makeId and modelId parameters in search_vehicles. The catalog is static and changes infrequently.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/get_makes_and_models \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_price_analysis

Returns price analysis for a vehicle listing: the listing price, financed price (if available), and a market indicator with the average price of comparable vehicles and a rank (1=cheapest tier, 5=most expensive). Not all listings have indicator data — newer or rare vehicles may return an empty indicator.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `vehicle_id` | string | Yes | The unique ID of the vehicle listing (from search_vehicles results). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/get_price_analysis \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"vehicle_id":"<string>"}'
```

### get_vehicle_detail

Fetches the complete listing for a single vehicle by its ID. Returns the ad (title, description, photos, price, category), professional seller info (contact, ratings, schedule, location), vehicle specs (equipment groups, power, dimensions), trade-in eligibility, and view/contact statistics. A single request covers all detail facets.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `vehicle_id` | string | Yes | The unique ID of the vehicle listing (from search_vehicles results). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/get_vehicle_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"vehicle_id":"<string>"}'
```

### get_vehicle_technical_specs

Returns manufacturer technical specifications for a vehicle listing, including horsepower, year, number of doors/seats, standard equipment groups, optional equipment with prices, and version/trim details. Data comes from the vehicle catalog (not seller-reported), so very old or rare models may lack certain fields.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `vehicle_id` | string | Yes | The unique ID of the vehicle listing (from search_vehicles results). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/get_vehicle_technical_specs \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"vehicle_id":"<string>"}'
```

### search_vehicles

Full-text and filter-based search across coches.net vehicle listings. Supports make/model, price range, mileage, horsepower, fuel type, transmission, body type, province, seller type, and category filters. Returns paginated results with items, promoted items, total counts, and aggregation facets for refining searches. Paginates via integer page counter; each page returns up to `size` items.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `bodyTypeIds` | string | No | Comma-separated body type IDs. |
| `category1Ids` | string | No | Comma-separated category IDs. |
| `contractId` | string | No | Seller contract ID for filtering by a specific dealer. |
| `environmentalLabelIds` | string | No | Comma-separated environmental label IDs. |
| `fuelTypeIds` | string | No | Comma-separated fuel type IDs. |
| `hp_from` | integer | No | Minimum horsepower. |
| `hp_to` | integer | No | Maximum horsepower. |
| `km_from` | integer | No | Minimum mileage in km. |
| `km_to` | integer | No | Maximum mileage in km. |
| `makeId` | integer | No | ID of the car make (from get_makes_and_models). |
| `modelId` | integer | No | ID of the car model (from get_makes_and_models). Requires makeId. |
| `page` | integer | No | Page number for pagination. |
| `price_from` | integer | No | Minimum price in euros. |
| `price_to` | integer | No | Maximum price in euros. |
| `provinceIds` | string | No | Comma-separated province IDs (e.g. '28' for Madrid). |
| `query` | string | No | Search keyword (e.g. 'BMW', 'Audi A4'). |
| `sellerTypeId` | string | No | Seller type: 1 for Private, 2 for Professional. |
| `size` | integer | No | Number of results per page. |
| `sort_order` | string | No | Sort order. |
| `sort_term` | string | No | Sort field. |
| `transmissionTypeId` | string | No | Comma-separated transmission type IDs. |
| `year_from` | integer | No | Minimum year of manufacture. |
| `year_to` | integer | No | Maximum year of manufacture. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-coches-net-api-98481a74/search_vehicles \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"bodyTypeIds":"<string>","category1Ids":"<string>","contractId":"<string>","environmentalLabelIds":"<string>","fuelTypeIds":"<string>","hp_from":"<integer>","hp_to":"<integer>","km_from":"<integer>","km_to":"<integer>","makeId":"<integer>","modelId":"<integer>","page":"<integer>","price_from":"<integer>","price_to":"<integer>","provinceIds":"<string>","query":"<string>","sellerTypeId":"<string>","size":"<integer>","sort_order":"<string>","sort_term":"<string>","transmissionTypeId":"<string>","year_from":"<integer>","year_to":"<integer>"}'
```
