# NHTSA Vehicle Safety Profiles - Recalls, Complaints, NCAP & VIN (`jpopendata/us-nhtsa-vehicle-safety`) Actor

One row per vehicle (make, model, year) from NHTSA's official APIs: recalls with remedies, complaint counts by component with crash/injury/death totals, NCAP star ratings and defect investigations. Bulk VIN decoding via vPIC. Unofficial; not affiliated with NHTSA.

- **URL**: https://apify.com/jpopendata/us-nhtsa-vehicle-safety.md
- **Developed by:** [JP Open Data](https://apify.com/jpopendata) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## NHTSA Vehicle Safety Profiles - Recalls, Complaints, NCAP & VIN

**One row per vehicle (make, model, model year) from NHTSA's official public data: every recall with NHTSA's summary, consequence and remedy text, complaint counts by component with crash, fire, injury and death totals, NCAP 5-Star Safety Ratings, and NHTSA defect investigations (open and closed). Add VINs and each one is decoded with NHTSA vPIC and gets the same profile.**

The U.S. National Highway Traffic Safety Administration (NHTSA) publishes recalls, owner complaints, crash-test ratings and defect investigations, but in separate places with different model names and date formats. This Actor puts them together as **one comparable row per vehicle**, so you can line up model years, rivals or a whole fleet side by side: summary columns (counts, latest dates, top complaint components, star range) open cleanly in Excel or Google Sheets, and the full details (each recall, each rated variant, each investigation) are in nested fields.

> **Unofficial tool. Not affiliated with or endorsed by NHTSA or the U.S. Department of Transportation.** Public information from NHTSA's public APIs and data files. **No consumer complaint text and no personal data are returned** — complaints are reduced to counts, components, dates and the crash/fire/injury/death fields.

### Quick start — verified input

Run on 2026-10-13 on the Apify platform (datacenter IP, no proxy, 256 MB): 4 rows (3 vehicles + 1 VIN), 27 API requests + 1 file download, 36 seconds, SUCCEEDED. An empty input `{}` runs exactly this.

```json
{
  "vehicles": ["2020 Honda Accord", "2020 Toyota RAV4", "2020 Tesla Model 3"],
  "vins": ["1HGCM82633A004352"]
}
```

Compare five model years of one model (recalls, complaints and stars only — no investigations download):

```json
{
  "vehicles": ["Toyota RAV4 2018-2022"],
  "sections": ["recalls", "complaints", "ratings"]
}
```

Every model NHTSA lists for a make and year (one row per model):

```json
{
  "vehicles": ["Honda 2021"],
  "maxItems": 50
}
```

Bulk VINs (each VIN = one row; VINs of the same car share one profile lookup):

```json
{
  "vins": ["1HGCM82633A004352", "3GCUKREC5FG186345"],
  "sections": ["recalls", "investigations"]
}
```

The 50 newest complaints of a vehicle as structured records (no written descriptions):

```json
{
  "vehicles": ["2020 Honda Accord"],
  "sections": ["complaints"],
  "maxComplaintRecords": 50
}
```

#### Common input mistakes

| You typed | What happens |
|---|---|
| `"Honda Accord"` (no year) | The run stops before any request: `vehicles entry "Honda Accord" has no model year`. Write `"2020 Honda Accord"` or `"Honda Accord 2018-2020"`. |
| `"Honda CRV 2020"`, `"Ford F150 2019"`, `"Chevy Silverado 2015"` | Works. Names are matched to NHTSA's spelling (CR-V, F-150, CHEVROLET). "Silverado" has no exact NHTSA model, so you get SILVERADO 1500, 2500 and 3500 rows. |
| `"2020 Honda Corolla"` | No row and no charge. The log and `RUN_SUMMARY.notFound` say why and suggest NHTSA's names. |
| A VIN with I, O or Q, or not 17 characters | The run stops before any request and names the VIN and the problem. Partial VINs are not accepted. |
| `"sections": ["ncap"]` | Use `ratings` (the four values are `recalls`, `complaints`, `ratings`, `investigations`). |

#### Empty results?

- **A misspelled make or model**: see the `Not found` warnings in the log (with suggestions) or `notFound` in the `RUN_SUMMARY` record.
- **A model year NHTSA has nothing on file for** (brand-new or very old): there is no recall, complaint or investigation under that name. If NCAP rated the vehicle you still get a row with `modelMatch: "ncap-only"` and zero counts.
- **A VIN vPIC cannot decode**: listed in `RUN_SUMMARY.undecodedVins` with vPIC's error text.

Entries that produce no row are not charged.

### What one row contains

| Group | Fields |
|---|---|
| Vehicle | `vehicle` ("2020 HONDA ACCORD"), `make`, `model`, `modelYear` (NHTSA's spelling), `input` (what you typed), `rowType` (`vehicle` or `vin`), `modelMatch` (how the name was matched), `nhtsaUrl` (the vehicle's page on nhtsa.gov) |
| Recalls | `recallCount`, `vehicleRecallCount` (vehicle campaigns only, without aftermarket-equipment/tire/child-seat campaigns), `recallCampaignNumbers`, `doNotDriveRecallCount` (NHTSA "Park It"), `parkOutsideRecallCount` (fire risk), `overTheAirRecallCount`, `latestRecallDate`, `recallComponents`, and `recalls[]`: campaign number and type, report date, components, NHTSA's summary, consequence and remedy, flags, manufacturer |
| Complaints | `complaintCount`, `complaintCrashCount`, `complaintFireCount`, `complaintInjuryCount` and `complaintDeathCount` (people reported), `complaintsWithInjuries`, `complaintsWithDeaths`, `firstComplaintDate`, `latestComplaintDate`, `topComplaintComponents`, `complaintsByComponent[]`, `complaintsByYear[]` (by filing year), optional `complaintRecords[]` (ODI number, dates, components, crash/fire/injury/death fields) |
| NCAP ratings | `ncapRated`, `ncapVariantCount`, `ncapOverallRatingMin` / `Max` (1-5 stars), `ncapVariants[]`: every tested variant with overall, frontal (driver/passenger), side, side pole and rollover stars, rollover probability, ESC/FCW/LDW availability and links to NHTSA's crash-test photos and videos |
| Investigations | `investigationCount`, `openInvestigationCount`, `investigationNumbers`, `investigations[]`: NHTSA action number, type (PE preliminary evaluation, EA engineering analysis, DP defect petition, RQ recall query, AQ audit query, others as-is), open/closed, opened and closed dates, components, recall campaigns it led to, NHTSA's subject line |
| VIN rows | `vin`, `vinCheckDigitValid`, `vinDecode`: make, model, year, series, trim, body, drive, doors, fuel, electrification, engine (cylinders, litres, hp, model), transmission, GVWR, manufacturer, plant city/state/country, and safety equipment (ABS, ESC, traction control, TPMS, air bags, forward collision warning, automatic emergency braking, lane departure/keeping, blind spot, backup camera, adaptive cruise) |
| Meta | `sections` (what you asked for), `incompleteSections` (sections that could not be read for this row), `source`, `sourceUrl`, `license`, `retrievedAt` |

A section you did not ask for is `null`. A section that NHTSA has nothing for is `0` / empty, not `null`.

#### Output example (real row, nested lists shortened)

```json
{
  "rowType": "vehicle",
  "input": "2020 Honda Accord",
  "vin": null,
  "vinCheckDigitValid": null,
  "vinDecode": null,
  "make": "HONDA",
  "model": "ACCORD",
  "modelYear": 2020,
  "vehicle": "2020 HONDA ACCORD",
  "modelMatch": "exact",
  "modelCandidates": null,
  "recallCount": 5,
  "vehicleRecallCount": 5,
  "recallCampaignNumbers": "26V332000 | 24V064000 | 23V858000 | 21V215000 | 20V771000",
  "doNotDriveRecallCount": 0,
  "parkOutsideRecallCount": 0,
  "overTheAirRecallCount": 0,
  "latestRecallDate": "2026-05-21",
  "recallComponents": "AIR BAGS (2) | FUEL SYSTEM, GASOLINE (2) | ELECTRICAL SYSTEM (1)",
  "recalls": [
    {
      "campaignNumber": "26V332000",
      "campaignType": "vehicle",
      "reportReceivedDate": "2026-05-21",
      "components": [
        "AIR BAGS:SENSOR:OCCUPANT CLASSIFICATION:FRONT PASSENGER"
      ],
      "summary": "Honda (American Honda Motor Co.) is recalling certain 2018-2021, 2023 Acura TLX, 2019-2024 RDX, 2017-2020, 2022-2026 MDX, 2017-2021, 2023, 2025 Honda Ridgeline, 2017-2022 Pilot, 2019-2021 Passport, 2018-2026 Odyssey, 2019-2022 Insight, 2019-2021 HR-V, 2018-2020 Fit, 2020-2022 CR-V Hybrid, 2017-2022 CR-V, 2017-2018, 2021 Civic Type R, 2017-2021 Civic hatchback, 2016-2020 Civic coupe, 2016-2022 Civic, 2017-2022 Accord Hybrid, and 2016-2022 Accord vehicles. The front passenger seat weight sensor may crack and short circuit, which can cause the air bags to deploy unintentionally during a crash.",
      "consequence": "Air bags that deploy unintentionally during a crash increase the risk of injury.",
      "remedy": "Dealers will replace the seat weight sensors, free of charge. Owner notification letters were mailed July 7, 2026. Owners may contact Honda's customer service at 1-888-234-2138. Honda's numbers for this recall are BOL, WO9, OOA, WOM, XOH, NOC, POD, BOE, UOF, POB, EOG, AOI, QO8, TOJ, DO7, and SOK. This recall expands previous NHTSA recall number 24V064. Vehicle Identification Numbers (VINs) involved in this recall will be searchable on NHTSA.gov beginning May 29, 2026.",
      "doNotDrive": false,
      "parkOutside": false,
      "overTheAirUpdate": false,
      "manufacturer": "Honda (American Honda Motor Co.)"
    }
  ],
  "complaintCount": 363,
  "complaintCrashCount": 14,
  "complaintFireCount": 2,
  "complaintInjuryCount": 11,
  "complaintDeathCount": 1,
  "complaintsWithInjuries": 8,
  "complaintsWithDeaths": 1,
  "firstComplaintDate": "2020-01-14",
  "latestComplaintDate": "2026-10-05",
  "topComplaintComponents": "FORWARD COLLISION AVOIDANCE (103) | ENGINE (72) | SERVICE BRAKES (56) | ELECTRICAL SYSTEM (52) | FUEL/PROPULSION SYSTEM (51) | UNKNOWN OR OTHER (42) | AIR BAGS (35) | STEERING (23) | LANE DEPARTURE (17) | POWER TRAIN (16)",
  "complaintsByComponent": [
    {
      "component": "FORWARD COLLISION AVOIDANCE",
      "count": 103
    },
    {
      "component": "ENGINE",
      "count": 72
    },
    {
      "component": "SERVICE BRAKES",
      "count": 56
    }
  ],
  "complaintsByYear": [
    {
      "year": 2024,
      "count": 59
    },
    {
      "year": 2025,
      "count": 105
    },
    {
      "year": 2026,
      "count": 76
    }
  ],
  "complaintRecords": null,
  "ncapRated": true,
  "ncapVariantCount": 1,
  "ncapOverallRatingMin": 5,
  "ncapOverallRatingMax": 5,
  "ncapVariants": [
    {
      "vehicleId": 14818,
      "description": "2020 Honda ACCORD 4 DR FWD",
      "overallRating": 5,
      "overallFrontCrashRating": 5,
      "frontCrashDriverSideRating": 5,
      "frontCrashPassengerSideRating": 5,
      "overallSideCrashRating": 5,
      "sideCrashDriverSideRating": 5,
      "sideCrashPassengerSideRating": 5,
      "sidePoleCrashRating": 5,
      "rolloverRating": 5,
      "rolloverPossibility": 0.093,
      "dynamicTipResult": "No Tip",
      "electronicStabilityControl": "Standard",
      "forwardCollisionWarning": "Standard",
      "laneDepartureWarning": "Standard",
      "vehiclePictureUrl": null,
      "frontCrashPictureUrl": "https://static.nhtsa.gov/crashTest/images/2020/v10191P080.jpg",
      "frontCrashVideoUrl": "https://static.nhtsa.gov/crashTest/videos/2020/v10191C017.wmv",
      "sideCrashPictureUrl": "https://static.nhtsa.gov/crashTest/images/2020/v10193P104.jpg",
      "sideCrashVideoUrl": "https://static.nhtsa.gov/crashTest/videos/2020/v10193C013.wmv",
      "sidePolePictureUrl": "https://static.nhtsa.gov/crashTest/images/2020/v10192P072.jpg",
      "sidePoleVideoUrl": "https://static.nhtsa.gov/crashTest/videos/2020/v10192C013.wmv"
    }
  ],
  "investigationCount": 1,
  "openInvestigationCount": 1,
  "investigationNumbers": "EA24002",
  "investigations": [
    {
      "actionNumber": "EA24002",
      "type": "EA",
      "typeLabel": "Engineering Analysis",
      "status": "open",
      "openedDate": "2024-04-15",
      "closedDate": null,
      "components": [
        "FORWARD COLLISION AVOIDANCE: AUTOMATIC EMERGENCY BRAKING",
        "FORWARD COLLISION AVOIDANCE",
        "FORWARD COLLISION AVOIDANCE: SENSING SYSTEM: CAMERA",
        "FORWARD COLLISION AVOIDANCE: SENSING SYSTEM: RADAR",
        "FORWARD COLLISION AVOIDANCE:SOFTWARE"
      ],
      "recallCampaignNumbers": [],
      "subject": "Inadvertent Automatic Emergency Braking",
      "manufacturer": "Honda (American Honda Motor Co.)"
    }
  ],
  "sections": [
    "recalls",
    "complaints",
    "ratings",
    "investigations"
  ],
  "incompleteSections": [],
  "nhtsaUrl": "https://www.nhtsa.gov/vehicle/2020/HONDA/ACCORD",
  "source": "NHTSA (U.S. National Highway Traffic Safety Administration): recalls, complaints, NCAP 5-Star Safety Ratings, defect investigations and vPIC",
  "sourceUrl": "https://www.nhtsa.gov/nhtsa-datasets-and-apis",
  "license": "Public information from NHTSA's public APIs and data files (U.S. Department of Transportation). NHTSA Terms of Use: \"Information presented on this web site is considered public information and may be distributed or copied.\" NHTSA makes no guarantee about the accuracy or completeness of the data. Terms: https://www.nhtsa.gov/about-nhtsa/terms-use. Unofficial tool, not affiliated with or endorsed by NHTSA or the U.S. Department of Transportation.",
  "retrievedAt": "2026-10-12T23:36:47.135Z"
}
```

### How names are matched

NHTSA uses its own model names, and each dataset spells them the same way. The Actor first reads NHTSA's make list for the year ("land rover" -> LAND ROVER, "mercedes benz" -> MERCEDES-BENZ, "Chevy" -> CHEVROLET, "VW" -> VOLKSWAGEN), then NHTSA's model list for that make and year:

- `exact`: the name you typed (any case) — "accord" -> ACCORD
- `normalized`: equal once punctuation is ignored — "CRV" -> CR-V, "F150" -> F-150
- `variant`: NHTSA models that start with your words, used when there is no exact match ("Silverado" -> SILVERADO 1500/2500/3500) or always with `includeModelVariants` ("Civic" -> also CIVIC HATCHBACK, CIVIC SI...)
- `all-models`: you gave a make and year only
- `vin` / `vin-series`: the VIN decode's model, or model + series ("Silverado" + "1500" -> SILVERADO 1500)
- `ncap-only`: not in NHTSA's recall/complaint list (nothing on file), but NCAP rated it
- `unlisted` (VIN rows only): the decoded model could not be matched to one NHTSA model; the row carries the VIN decode and `modelCandidates`, and the profile sections are left empty

### Recalls are per model year, not per VIN

NHTSA's recall data says which make, model and year a campaign covers. It does not say whether one particular vehicle is included or has been repaired (NHTSA's own per-VIN lookup is a separate website tool, not part of these APIs). VIN rows therefore show the recalls of the VIN's make, model and year. Some campaigns cover only part of a model year.

### Attribution and terms

- Data: NHTSA's public APIs — recalls, complaints and NCAP ratings from `api.nhtsa.gov`, VIN decoding from vPIC at `vpic.nhtsa.dot.gov` — and NHTSA's defect investigations file (`static.nhtsa.gov/odi/ffdd/inv/FLAT_INV.zip`; NHTSA offers no investigations API). All are listed on NHTSA's [Datasets and APIs](https://www.nhtsa.gov/nhtsa-datasets-and-apis) page.
- NHTSA [Terms of Use](https://www.nhtsa.gov/about-nhtsa/terms-use): "Information presented on this web site is considered public information and may be distributed or copied." and "The NHTSA/DOT makes no claims, promises or guarantees about the accuracy, completeness, or adequacy of the contents of this web site and expressly disclaims liability for errors and omissions in the contents of this web site."
- vPIC FAQ: "NHTSA is a government agency and the services provided on the API are free for use by the public as an offering as a part of our Open Data initiatives" and "There is no need to register your application to use the services". vPIC also notes: "Any missing decoded values should be interpreted as NHTSA does not have data on the specific variable. Missing value should NOT be interpreted as an indication that a feature or technology is unavailable for a vehicle."
- Every row carries `source`, `sourceUrl`, `license` (the terms above) and `retrievedAt`. Recall texts are NHTSA's own wording (spacing normalised only). "NHTSA" is used only to name the data source; no NHTSA or DOT logo or seal is used.

### Privacy and GDPR

- NHTSA complaints include the owner's written description and part of the vehicle's VIN. **Neither is ever copied into the output** (enforced by automated tests). NHTSA does not publish complainants' names.
- Investigations and recalls are about vehicles and manufacturers. Manufacturer names and their customer-service numbers inside NHTSA's recall text are business information.
- VINs you enter are sent only to NHTSA's vPIC decoder and are returned in your own dataset. If you link VINs to people (for example a customer list), you are responsible for that processing under GDPR and similar laws.

### How it reads NHTSA

- One request at a time, at least 1.2 seconds apart, with a hard budget (`maxApiRequests`). Server errors are retried with backoff, `Retry-After` is honoured, an HTTP 403 or a persistent 429 stops the run politely, and only NHTSA's documented endpoints are ever called.
- One VIN = one standard vPIC decode request, as NHTSA's vPIC FAQ recommends for many VINs ("use a programmed routine on the standard decode APIs").
- NHTSA's vPIC FAQ asks that large batch jobs run "either at night (based on EST, or on the weekend)". For lists of thousands of VINs, please schedule your runs accordingly.
- A vehicle costs about 4 to 6 requests: recalls, complaints, the NCAP variant list and one request per rated variant. NHTSA's make and model lists are read once per year and make, and each vehicle is looked up once per run however many VINs share it.
- The investigations file (about 4 MB, 390 MB unpacked) is downloaded at most once per run and read as a stream, so runs fit in 256 MB.
- If something stops the run early (budget, timeout, NHTSA errors), the rows already produced are kept, the run still succeeds, and `RUN_SUMMARY` shows `complete: false` with the reason. A row whose section could not be read lists it in `incompleteSections`.

### Limits

- NHTSA's data, as published: complaints are unverified reports from owners; recall and complaint counts for popular models include equipment campaigns that list the vehicle as compatible (see `vehicleRecallCount`); investigations name every make/model/year NHTSA attached to them.
- NCAP overall ratings exist from model year 2011 on; earlier tests have frontal and side stars only. Up to 16 rated variants per vehicle are read.
- Model years from 1949 to two years after the current year. Up to 500 vehicle entries and 5,000 VINs per run.
- Speed: one request every 1.2 seconds, so about 2,500-3,000 VINs (decode only, repeated cars) or about 500-700 distinct vehicles fit in the default 1-hour run timeout. Larger lists: raise the run timeout or split the list — a run that reaches its timeout keeps every row produced so far.

### Disclaimer

This Actor reads only public data that NHTSA publishes for public use. It is not affiliated with, endorsed by or sponsored by NHTSA or the U.S. Department of Transportation. You are responsible for how you use the data and for complying with NHTSA's terms and the laws that apply to you, including data-protection laws such as the GDPR. The data is provided as is, without any warranty of accuracy or completeness — always check safety-critical decisions against nhtsa.gov.

# Actor input Schema

## `vehicles` (type: `array`):

One vehicle per line: make, model and model year in any order of year, e.g. "2020 Honda Accord", "Toyota RAV4 2019-2021" (a range gives one row per year), "Ford F-150 2018 2020" or "Honda | Accord | 2020". A make and year without a model ("Honda 2020") returns every model NHTSA lists for that make and year. Names are matched to NHTSA's own spelling ("CRV" finds CR-V, "F150" finds F-150, "Chevy" finds CHEVROLET). If a name has no exact match, its variants are used ("Silverado" gives SILVERADO 1500, 2500 and 3500). Entries that match nothing are listed with suggestions in the log and in RUN_SUMMARY, and are not charged.

## `vins` (type: `array`):

Optional. 17-character VINs, one per line (spaces, hyphens and lower case are fine). Each VIN is decoded with NHTSA vPIC (year, make, model, trim, engine, plant, safety equipment) and gets one row with the safety profile of its make, model and year. Recalls are listed for the model year, not for the individual vehicle: this Actor cannot tell whether a specific VIN has been repaired. Up to 5,000 VINs per run (one decode request each, 1.2 s apart: about 2,500-3,000 VINs fit in the default 1-hour timeout; raise the timeout for more). VINs vPIC cannot decode are listed in RUN_SUMMARY and are not charged.

## `sections` (type: `array`):

Which parts of the profile to fetch. Fewer sections = fewer requests per vehicle. Investigations come from NHTSA's investigations file (one download per run, about 4 MB).

## `includeModelVariants` (type: `boolean`):

Also return every NHTSA model whose name starts with the one you typed, even when an exact match exists: "Civic" then also gives CIVIC HATCHBACK, CIVIC SI and CIVIC TYPE R rows. Off = exact match only (variants are still used when there is no exact match).

## `maxComplaintRecords` (type: `integer`):

0..1000. Also list up to this many of the newest complaints per vehicle, each with its NHTSA ODI number, filing date, incident date, components and the crash, fire, injury and death fields. The consumer's written description is never included. 0 = counts and breakdowns only.

## `maxItems` (type: `integer`):

Maximum rows (1..10000). One row per vehicle per model year, plus one row per VIN. You are charged per row.

## `maxApiRequests` (type: `integer`):

Hard budget of requests to NHTSA's APIs for the whole run (1..20000). Requests are sent one at a time, at least 1.2 seconds apart. A vehicle costs about 4 to 6 requests (recalls, complaints, NCAP list and one request per rated variant), plus one model-list request per make and year and one decode per VIN. If the budget runs out, the run still succeeds with the rows already produced (complete=false in RUN_SUMMARY).

## `proxyConfiguration` (type: `object`):

Optional and normally not needed: NHTSA's APIs answer Apify datacenter IPs. If set, one sticky session is used for the whole run (never rotation).

## Actor input object example

```json
{
  "vehicles": [
    "2020 Honda Accord",
    "2020 Toyota RAV4",
    "2020 Tesla Model 3"
  ],
  "vins": [
    "1HGCM82633A004352"
  ],
  "sections": [
    "recalls",
    "complaints",
    "ratings",
    "investigations"
  ],
  "includeModelVariants": false,
  "maxComplaintRecords": 0,
  "maxItems": 100,
  "maxApiRequests": 300,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `records` (type: `string`):

One row per vehicle (make, model, model year) or VIN, with NHTSA source, terms and retrieval time on every row.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "vehicles": [
        "2020 Honda Accord",
        "2020 Toyota RAV4",
        "2020 Tesla Model 3"
    ],
    "vins": [
        "1HGCM82633A004352"
    ],
    "sections": [
        "recalls",
        "complaints",
        "ratings",
        "investigations"
    ],
    "includeModelVariants": false,
    "maxComplaintRecords": 0,
    "maxItems": 100,
    "maxApiRequests": 300,
    "proxyConfiguration": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("jpopendata/us-nhtsa-vehicle-safety").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "vehicles": [
        "2020 Honda Accord",
        "2020 Toyota RAV4",
        "2020 Tesla Model 3",
    ],
    "vins": ["1HGCM82633A004352"],
    "sections": [
        "recalls",
        "complaints",
        "ratings",
        "investigations",
    ],
    "includeModelVariants": False,
    "maxComplaintRecords": 0,
    "maxItems": 100,
    "maxApiRequests": 300,
    "proxyConfiguration": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("jpopendata/us-nhtsa-vehicle-safety").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "vehicles": [
    "2020 Honda Accord",
    "2020 Toyota RAV4",
    "2020 Tesla Model 3"
  ],
  "vins": [
    "1HGCM82633A004352"
  ],
  "sections": [
    "recalls",
    "complaints",
    "ratings",
    "investigations"
  ],
  "includeModelVariants": false,
  "maxComplaintRecords": 0,
  "maxItems": 100,
  "maxApiRequests": 300,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}' |
apify call jpopendata/us-nhtsa-vehicle-safety --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,jpopendata/us-nhtsa-vehicle-safety"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/izdLAha6UIZg1OAT6/builds/6QuGhrUniOcZUOhdj/openapi.json
