> ## Documentation Index
> Fetch the complete documentation index at: https://docs.didit.me/llms.txt
> Use this file to discover all available pages before exploring further.

# United States - Driver's License (DMV) API

> United States - Driver's License (DMV): authoritative United States database lookup via Didit. Pay-per-call from $1.99, no contracts, no minimums.

Verifies a US driver's license or state ID card against the issuing state's motor vehicle records, confirming the license number, the holder's names and date of birth. Didit exposes this service through `POST /v3/database-validation/` so you can verify the submitted data against the authoritative source and receive normalized match results. Input format: `document_number` takes the US driver's license or state ID number (4-20 letters and digits; dashes and spaces allowed).

## Coverage

* **Coverage:** \~ 90%
* **Country:** United States
* **Service ID:** `usa_driver_license_dmv`
* **Data domain:** Document
* **Category:** DriverLicence

## Inputs

| Field | Required | Example |
| - | -: | - |
| `first_name` | Yes | `John` |
| `last_name` | Yes | `Doe` |
| `document_number` | Yes | `SAMPLE-DOC-12345` |
| `driver_license_state` | Yes | `Sample State` |
| `middle_name` | No | `Demo` |
| `date_of_birth` | No | `1990-01-01` |
| `date_of_issue` | No | `1990-01-01` |
| `expiration_date` | No | `1990-01-01` |
| `gender` | No | `M` |
| `document_type` | No | `DL` |
| `vendor_data` | No | `user-1234` |

* **Required inputs:** `first_name`, `last_name`, `document_number`, `driver_license_state`
* **Optional inputs:** `middle_name`, `date_of_birth`, `date_of_issue`, `expiration_date`, `gender`, `document_type`, `vendor_data`
* **Consent:** Not required
* **Workflow availability:** Available in workflow
* **Coverage:** \~ 90%
* **Price:** \$1.99 per successful query

## Body parameters

**issuing\_state** `string` *required* (default: USA)

ISO 3166-1 alpha-3 country code for this database service.

Example: `USA`

**services** `string` *required* (default: usa\_driver\_license\_dmv)

Array containing this service ID. Pinning the service keeps the request scoped to this exact database.

Example: `usa_driver_license_dmv`

**first\_name** `string` *required* (default: John)

Given name to validate.

Example: `John`

**last\_name** `string` *required* (default: Doe)

Family name to validate.

Example: `Doe`

**document\_number** `string` *required* (default: SAMPLE-DOC-12345)

Document number extracted from or provided by the user.

Example: `SAMPLE-DOC-12345`

**driver\_license\_state** `string` *required* (default: Sample State)

State or region that issued the driver licence.

Example: `Sample State`

**middle\_name** `string`

Middle name, when available.

Example: `Demo`

**date\_of\_birth** `string`

Date of birth in `YYYY-MM-DD` format.

Example: `1990-01-01`

**date\_of\_issue** `string`

`date_of_issue` value required by this database service.

Example: `1990-01-01`

**expiration\_date** `string`

`expiration_date` value required by this database service.

Example: `1990-01-01`

**gender** `string`

Gender value, when required by the database.

Allowed values: `M` (male), `F` (female), `X` (other or unknown).

Example: `M`

**document\_type** `string`

Document type to validate against this database service.

Allowed values: `DL` (driver's license), `ID` (national ID).

Example: `DL`

**vendor\_data** `string` (default: user-1234)

Your stable user reference for this person, such as your internal user ID. Didit uses it to link standalone checks to the same end user and reduce duplicate-detection noise.

Example: `user-1234`

## Input rules & validation notes

* US driver's license or state ID number (4-20 letters and digits; dashes and spaces allowed)
* `document_number` must be 4-20 characters long.
* `document_number` must match `[A-Za-z0-9][A-Za-z0-9 -]{2,18}[A-Za-z0-9]`.
* Send `driver_license_state` as the issuing state's two-letter code (`TX`) or name (`Texas`).
* California and Pennsylvania licenses are not checked by this service.

## How to call it

```bash cURL theme={null}
curl -X POST "https://verification.didit.me/v3/database-validation/" \
  -H "x-api-key: YOUR_API_KEY" \
  -F "issuing_state=USA" \
  -F "services=usa_driver_license_dmv" \
  -F "vendor_data=user-1234" \
  -F "first_name=John" \
  -F "last_name=Doe" \
  -F "document_number=SAMPLE-DOC-12345" \
  -F "driver_license_state=Sample State"
```

```python Python theme={null}
from didit import Didit

# Reads DIDIT_API_KEY.
client = Didit()

result = client.database_validation.validate(
    issuing_state="USA",
    services=["usa_driver_license_dmv"],
    first_name="John",
    last_name="Doe",
    document_number="SAMPLE-DOC-12345",
    driver_license_state="Sample State",
    vendor_data="user-1234",
)
print(result)
```

```javascript Node.js theme={null}
import Didit from "@didit-protocol/sdk-node";

// Reads DIDIT_API_KEY.
const didit = new Didit();

const result = await didit.databaseValidation.validate({
  issuing_state: "USA",
  services: ["usa_driver_license_dmv"],
  first_name: "John",
  last_name: "Doe",
  document_number: "SAMPLE-DOC-12345",
  driver_license_state: "Sample State",
  vendor_data: "user-1234",
});
console.log(result);
```

```go Go theme={null}
ctx := context.Background()
// Reads DIDIT_API_KEY.
client := didit.NewClient()

result, err := client.DatabaseValidation.Validate(ctx, didit.DatabaseValidationValidateParams{
	IssuingState:       "USA",
	Services:           didit.Some([]string{"usa_driver_license_dmv"}),
	FirstName:          didit.String("John"),
	LastName:           didit.String("Doe"),
	DocumentNumber:     didit.String("SAMPLE-DOC-12345"),
	DriverLicenseState: didit.String("Sample State"),
	VendorData:         didit.String("user-1234"),
})
if err != nil {
	log.Fatal(err)
}
fmt.Printf("%+v\n", result)
```

```java Java theme={null}
import java.util.List;
import me.didit.Didit;
import me.didit.types.DatabaseValidationValidateParams;

// Reads DIDIT_API_KEY.
Didit client = new Didit();

var result = client.databaseValidation().validate(DatabaseValidationValidateParams.builder()
        .issuingState("USA")
        .services(List.of("usa_driver_license_dmv"))
        .firstName("John")
        .lastName("Doe")
        .documentNumber("SAMPLE-DOC-12345")
        .driverLicenseState("Sample State")
        .vendorData("user-1234")
        .build());
System.out.println(result);
```

```php PHP theme={null}
<?php

require 'vendor/autoload.php';

use Didit\DiditClient;

// Reads DIDIT_API_KEY.
$didit = new DiditClient();

$result = $didit->databaseValidation->validate([
    'issuing_state' => 'USA',
    'services' => ['usa_driver_license_dmv'],
    'first_name' => 'John',
    'last_name' => 'Doe',
    'document_number' => 'SAMPLE-DOC-12345',
    'driver_license_state' => 'Sample State',
    'vendor_data' => 'user-1234',
]);
print_r($result->toArray());
```

```ruby Ruby theme={null}
require "didit"

# Reads DIDIT_API_KEY.
didit = Didit::Client.new

result = didit.database_validation.validate(
  issuing_state: "USA",
  services: ["usa_driver_license_dmv"],
  first_name: "John",
  last_name: "Doe",
  document_number: "SAMPLE-DOC-12345",
  driver_license_state: "Sample State",
  vendor_data: "user-1234"
)
puts result.to_h
```

```csharp .NET theme={null}
using System;
using System.Text.Json;
using Didit;

// Reads DIDIT_API_KEY.
using var client = new DiditClient();

var result = await client.DatabaseValidation.ValidateAsync(new DatabaseValidationValidateParams
{
    IssuingState = "USA",
    Services = new string[] { "usa_driver_license_dmv" },
    FirstName = "John",
    LastName = "Doe",
    DocumentNumber = "SAMPLE-DOC-12345",
    DriverLicenseState = "Sample State",
    VendorData = "user-1234",
});
Console.WriteLine(JsonSerializer.Serialize(result));
```

Every successful call returns HTTP `200`. The **`outcome_code`** field tells you what actually happened — distinguishing, for example, a real biometric mismatch (`BIOMETRIC_NO_MATCH`) from a selfie that could not be read (`BIOMETRIC_IMAGE_UNUSABLE`). The `status` shown is the default feature status; your configured [Partial Match / No Match actions](https://docs.didit.me/core-technology/database-validation/database-validation-warnings.md) can override it.

**`MATCH`** — The registry confirmed the identity and every checked field matched.

```json 200 OK — MATCH theme={null}
{
  "request_id": "req_01H…",
  "status": "Approved",
  "issuing_state": "USA",
  "match_type": "full_match",
  "validations": [
    {
      "outcome_code": "MATCH",
      "service_id": "usa_driver_license_dmv",
      "service_name": "United States - Driver's License (DMV)",
      "source_data": {
        "date_of_birth": "1990-01-01",
        "first_name": "John",
        "identification_number": "SAMPLE-ID-12345",
        "last_name": "Doe",
        "middle_name": "Demo"
      },
      "validation": {
        "full_name": "full_match",
        "identification_number": "full_match"
      }
    }
  ]
}
```

**`PARTIAL_MATCH`** — The identification number was found but one or more personal fields (usually name or date of birth) did not fully match.

```json 200 OK — PARTIAL_MATCH theme={null}
{
  "request_id": "req_01H…",
  "status": "In Review",
  "issuing_state": "USA",
  "match_type": "partial_match",
  "validations": [
    {
      "outcome_code": "PARTIAL_MATCH",
      "service_id": "usa_driver_license_dmv",
      "service_name": "United States - Driver's License (DMV)",
      "source_data": {
        "date_of_birth": "1990-01-01",
        "first_name": "John",
        "identification_number": "SAMPLE-ID-12345",
        "last_name": "Doe",
        "middle_name": "Demo"
      },
      "validation": {
        "full_name": "no_match",
        "identification_number": "full_match"
      }
    }
  ]
}
```

**`NO_MATCH`** — The registry returned no match for the submitted data.

```json 200 OK — NO_MATCH theme={null}
{
  "request_id": "req_01H…",
  "status": "Declined",
  "issuing_state": "USA",
  "match_type": "no_match",
  "validations": [
    {
      "outcome_code": "NO_MATCH",
      "service_id": "usa_driver_license_dmv",
      "service_name": "United States - Driver's License (DMV)",
      "source_data": {
        "full_name": "NO_MATCH",
        "identification_number": "NO_MATCH"
      },
      "validation": {
        "full_name": "no_match",
        "identification_number": "no_match"
      }
    }
  ]
}
```

## Returned data

The exact fields surfaced in `source_data` depend on what the registry returns. The generated example for `usa_driver_license_dmv` currently documents this normalized shape:

* `date_of_birth`
* `first_name`
* `identification_number`
* `last_name`
* `middle_name`

## Pricing & SLAs

United States - Driver's License (DMV) queries are billed only when Didit receives a conclusive result from the validation source.

* **Per-call price:** \$1.99 USD.
* **Billing:** per successful query. You are not charged when the registry is unreachable, when required fields are missing, or when the request is rejected before reaching the source.
* **Latency:** typical p95 \< 2 s.
* **Availability:** 99.9% per quarter on Didit's side; downstream source availability varies by country and dataset.

## Continue reading

* [United States Database Validation overview](https://docs.didit.me/api-reference/database-validation/united-states.md)
* [Database Validation overview](https://docs.didit.me/core-technology/database-validation/overview.md)
* [Outcome Codes](https://docs.didit.me/core-technology/database-validation/database-validation-outcome-codes.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.