{
  "openapi": "3.0.1",
  "info": {
    "title": "NHTSA Recalls, VIN Decoder, Ratings & Investigations",
    "description": "Scrape NHTSA recalls, consumer complaints, crash-test safety ratings, VIN decodes and safety investigations for any US vehicle by make, model, year or VIN. Export CSV, Excel, JSON or XML. No login or API key. 2020 Honda Accord: 5 recalls, 362 complaints.",
    "version": "0.1",
    "x-build-id": "jWwQE5ndD3tHBa9Oe"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/recordsdata~nhtsa-vehicle-safety-aggregator/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-recordsdata-nhtsa-vehicle-safety-aggregator",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/recordsdata~nhtsa-vehicle-safety-aggregator/runs": {
      "post": {
        "operationId": "runs-sync-recordsdata-nhtsa-vehicle-safety-aggregator",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/recordsdata~nhtsa-vehicle-safety-aggregator/run-sync": {
      "post": {
        "operationId": "run-sync-recordsdata-nhtsa-vehicle-safety-aggregator",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "make": {
            "title": "Make",
            "type": "string",
            "description": "Vehicle make. Example: honda. Use with Model and Model year. If you give only a VIN, vehicle list or campaign numbers and leave these at their defaults, the default vehicle is skipped.",
            "default": "honda"
          },
          "model": {
            "title": "Model",
            "type": "string",
            "description": "Vehicle model to search, for example \"accord\" or \"f-150\". Use together with Make and Model Year.",
            "default": "accord"
          },
          "modelYear": {
            "title": "Model year",
            "minimum": 1995,
            "maximum": 2027,
            "type": "integer",
            "description": "Four-digit model year to search, from 1995 to 2027, for example 2020. Use together with Make and Model.",
            "default": 2020
          },
          "maxItems": {
            "title": "Max rows to return",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "How many rows to return in total, shared across vehicles, VINs and sources. Example: 10. Free plan runs are capped at 10 rows; paid runs accept up to 1,000,000.",
            "default": 10
          },
          "vehicles": {
            "title": "Vehicle list (JSON)",
            "type": "array",
            "description": "Optional. One JSON object per vehicle. Example: [{\"make\": \"ford\", \"model\": \"f-150\", \"modelYear\": 2021}]. Rows are taken in turns from each vehicle so a small Max rows still covers all of them.",
            "default": []
          },
          "vin": {
            "title": "VIN (17 characters)",
            "type": "string",
            "description": "Optional 17-character Vehicle Identification Number to decode into a full spec sheet (engine, transmission, body class, plant), for example \"1HGCM82633A004352\". Works alone or together with Make, Model and Model Year."
          },
          "vins": {
            "title": "VIN list (one per line)",
            "type": "array",
            "description": "Optional list of VINs to decode, one per line, for example 1HGCM82633A004352. Up to 1,000 VINs per run. A malformed VIN becomes a free error row and the other VINs still run.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "expandVinToVehicle": {
            "title": "Also look up recalls, complaints and ratings for each VIN",
            "type": "boolean",
            "description": "After a VIN is decoded, also fetch recalls, complaints, safety ratings and investigations for its decoded make, model and model year (the source switches below apply). Off by default: VINs then return the decode only.",
            "default": false
          },
          "campaignNumbers": {
            "title": "Recall campaign numbers",
            "type": "array",
            "description": "Optional NHTSA recall campaign numbers, for example 20V771 or 20V771000. Returns one recall row per campaign with units affected and the full list of affected vehicles. An unknown number becomes a free error row. Not limited by the source switches or the date filter below.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "enrichRecalls": {
            "title": "Add units affected to recalls",
            "type": "boolean",
            "description": "Recall rows found by vehicle get potentialUnitsAffected and affectedVehicles from the campaign lookup (one extra NHTSA request per delivered recall, not billed). Campaign lookups always include them.",
            "default": false
          },
          "includeRecalls": {
            "title": "Recalls",
            "type": "boolean",
            "description": "Return recall campaigns for each vehicle (recall-record).",
            "default": true
          },
          "includeComplaints": {
            "title": "Owner complaints",
            "type": "boolean",
            "description": "Return consumer complaints for each vehicle (complaint-record). Turn off when you only need recalls: a popular vehicle has hundreds of complaints.",
            "default": true
          },
          "includeRatings": {
            "title": "Crash-test ratings",
            "type": "boolean",
            "description": "Return the NHTSA 5-star crash-test ratings of each trim, with crash-test photo and video links (safety-rating-record).",
            "default": true
          },
          "includeInvestigations": {
            "title": "Safety investigations",
            "type": "boolean",
            "description": "Return NHTSA safety investigations whose subject or text mentions the make or model (investigation-record). NHTSA offers no vehicle filter for these, see Investigation scan depth.",
            "default": true
          },
          "maxComplaintsPerVehicle": {
            "title": "Max complaints per vehicle (0 = no cap)",
            "minimum": 0,
            "type": "integer",
            "description": "Cap on complaint rows for each vehicle, so complaints do not crowd out other sources (for example 20). 0 means no cap beyond Max Items.",
            "default": 0
          },
          "complaintSeverity": {
            "title": "Complaint severity",
            "enum": [
              "any",
              "crash",
              "fire",
              "injury",
              "death"
            ],
            "type": "string",
            "description": "Keep only complaints that reported a crash, a fire, at least one injury or at least one death. Any returns every complaint.",
            "default": "any"
          },
          "dateFrom": {
            "title": "From date (2025-01-31 or 30d)",
            "type": "string",
            "description": "Start of the date range. Use YYYY-MM-DD (2025-01-31) or a relative value: today, yesterday, ytd, 30d, 12w, 6m, 5y, \"last 90 days\". Applies to recall report date, complaint filing date and investigation open date. Empty means no lower limit.",
            "default": ""
          },
          "dateTo": {
            "title": "Until date",
            "type": "string",
            "description": "End of the date range (included). Same formats as Date from. Empty means no upper limit.",
            "default": ""
          },
          "componentKeywords": {
            "title": "Component keywords",
            "type": "array",
            "description": "Keep only recalls and complaints whose component contains any of these words, and investigations whose subject or text contains any of them, case-insensitive. For example AIR BAGS, FUEL, SERVICE BRAKES, STEERING, ELECTRICAL, POWER TRAIN. Empty means no filter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "investigationScan": {
            "title": "Investigation search depth",
            "enum": [
              "recent",
              "all"
            ],
            "type": "string",
            "description": "NHTSA has no vehicle filter for investigations, so the actor reads the investigation list and matches make and model in the text. Recent reads the 500 most recent investigations (fast). Whole archive reads all of them (about 4,200 records in 42 requests, up to 2 minutes when nothing matches) and is needed for older vehicles.",
            "default": "recent"
          },
          "onlyNew": {
            "title": "Only new records since the last run",
            "type": "boolean",
            "description": "Skip records already delivered by earlier runs with Only new records on: recalls (campaign number), complaints (ODI number), safety ratings (vehicle ID), VIN decodes and investigations. Skipped records are not charged and do not count towards Max Items.",
            "default": false
          },
          "stateKey": {
            "title": "Monitor name (optional)",
            "type": "string",
            "description": "Optional label that keeps separate memories (for example \"fleet-us\" and \"fleet-eu\"). Leave empty to share one memory across all your Only new runs.",
            "default": ""
          },
          "resetSeen": {
            "title": "Start the monitor over",
            "type": "boolean",
            "description": "Forget which records were already delivered for this monitor name and start over. Turn it off again after one run.",
            "default": false
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}