# Coverage

How many versions carry each field, per powertrain, so you know what you can rely on before you build on it.

## The endpoint

`GET /v1/coverage`

Not every version has every figure. This endpoint counts, for each field of the flat shape, how many published versions carry it, split by powertrain.

It counts cars unless told otherwise: `vehicle_type=motorcycle` counts motorcycles, and `vehicle_type=car,motorcycle` both.

**Response**

```json
{
  "versions": 57374,
  "by_powertrain": {
    "combustion": 51454,
    "hybrid": 3421,
    "electric": 2478,
    "fuel_cell": 10,
    "unknown": 11
  },
  "fields": {
    "accel_0_100_s": {
      "total": 38170,
      "combustion": 33511,
      "hybrid": 2769,
      "electric": 1876,
      "fuel_cell": 6,
      "unknown": 8
    }
  }
}
```

The example shows one field. The answer has one entry for each field of the [flat shape](https://autospec.launchit.ro/docs/version), apart from the ones that identify a version rather than describe it.

## Reading it

Divide a field's count by the count for its powertrain to get how often it is filled. A field that does not apply reads low for a reason: `displacement_cc` is close to zero for electric cars because they have no engine, not because the data is missing.

`unknown` counts versions whose powertrain has not been classified.

## Empty is not zero

A version without a figure returns `null` for it. Filters skip those versions, so `kerb_weight_kg.lte=1200` returns the versions known to weigh that or less, never the ones whose weight is not known.
