# CBP API

> CBP returns U.S. land-border crossing waits and status as a workflow and API.

CBP, also known as U.S. Customs and Border Protection, returns published wait times and status for U.S. land-border crossings. Get border wait times returns crossing details, lane availability, and wait times; filter by state, border, or crossing, or request every crossing.

- Page: https://fous.com/workflows/cbp
- Handle: `@cbp`
- Category: [Travel](https://fous.com/workflows/category/travel)
- Source website: https://cbp.gov
- Last verified: Sep 29, 2026
- Fous is not affiliated with CBP.

## Methods

### Get border wait times

Operation `get_border_wait_times`, version 1. 1 credit per call.

Get current US land-border waits for every crossing or filter by crossing, border and state. Lane values that are unavailable are null.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `state` | string | no | `"California"` | US state name, such as Texas. |
| `border` | string | no | `"mexico"` | Border to include, such as mexico. |
| `crossing` | string | no | `"San Ysidro"` | Crossing name or port city, such as San Ysidro or Detroit. |

**Input schema**

```json
{
  "type": "object",
  "properties": {
    "state": {
      "type": "string",
      "default": "",
      "description": "US state name, such as Texas.",
      "examples": [
        "California",
        "Texas",
        "Michigan"
      ]
    },
    "border": {
      "enum": [
        "canada",
        "mexico",
        "both"
      ],
      "type": "string",
      "default": "both",
      "description": "Border to include, such as mexico.",
      "examples": [
        "mexico",
        "canada"
      ]
    },
    "crossing": {
      "type": "string",
      "default": "",
      "description": "Crossing name or port city, such as San Ysidro or Detroit.",
      "examples": [
        "San Ysidro",
        "Detroit",
        "Brownsville"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {},
    {
      "state": "California",
      "border": "mexico",
      "crossing": "San Ysidro"
    },
    {
      "state": "Texas"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `crossings` | array |  | Border crossings in published order. |
| `crossings[].city` | string | `"San Ysidro"` | US port city. |
| `crossings[].hours` | string or null | `"24 hrs/day"` | Published operating hours. |
| `crossings[].state` | string or null | `"California"` | US state. |
| `crossings[].border` | string | `"Mexico"` | Canada or Mexico. |
| `crossings[].status` | string | `"open"` | Open or closed. |
| `crossings[].page_url` | string | `"https://bwt.cbp.gov/details/09250401/POV"` | Crossing details page. |
| `crossings[].last_updated` | string or null | `"2026-09-28T21:56:01-07:00"` | Local ISO 8601 update time with UTC offset. |
| `crossings[].crossing_name` | string | `"San Ysidro"` | Name of the crossing. |
| `crossings[].commercial_fast_lanes_open` | integer or null |  | Open commercial Fast lanes. |
| `crossings[].passenger_ready_lanes_open` | integer or null | `11` | Open passenger Ready lanes. |
| `crossings[].pedestrian_ready_lanes_open` | integer or null | `1` | Open pedestrian Ready lanes. |
| `crossings[].commercial_fast_wait_minutes` | integer or null |  | Commercial Fast lane wait, minutes. |
| `crossings[].passenger_ready_wait_minutes` | integer or null | `40` | Passenger Ready lane wait, minutes. |
| `crossings[].passenger_standard_lanes_open` | integer or null | `3` | Open passenger Standard lanes. |
| `crossings[].pedestrian_ready_wait_minutes` | integer or null | `5` | Pedestrian Ready lane wait, minutes. |
| `crossings[].commercial_standard_lanes_open` | integer or null | `4` | Open commercial Standard lanes. |
| `crossings[].pedestrian_standard_lanes_open` | integer or null | `14` | Open pedestrian Standard lanes. |
| `crossings[].passenger_standard_wait_minutes` | integer or null | `60` | Passenger Standard lane wait, minutes. |
| `crossings[].commercial_standard_wait_minutes` | integer or null | `40` | Commercial Standard lane wait, minutes. |
| `crossings[].pedestrian_standard_wait_minutes` | integer or null | `5` | Pedestrian Standard lane wait, minutes. |
| `crossings[].passenger_sentri_nexus_lanes_open` | integer or null | `4` | Open passenger Sentri/Nexus lanes. |
| `crossings[].passenger_sentri_nexus_wait_minutes` | integer or null | `5` | Passenger Sentri/Nexus lane wait, minutes. |

**Example input**

```json
{
  "state": "California",
  "border": "mexico",
  "crossing": "San Ysidro"
}
```

**Example output**

```json
{
  "crossings": [
    {
      "city": "San Ysidro",
      "hours": "24 hrs/day",
      "state": "California",
      "border": "Mexico",
      "status": "open",
      "page_url": "https://bwt.cbp.gov/details/09250401/POV",
      "last_updated": "2026-09-28T21:56:01-07:00",
      "crossing_name": "San Ysidro",
      "commercial_fast_lanes_open": null,
      "passenger_ready_lanes_open": 11,
      "pedestrian_ready_lanes_open": 1,
      "commercial_fast_wait_minutes": null,
      "passenger_ready_wait_minutes": 40,
      "passenger_standard_lanes_open": 3,
      "pedestrian_ready_wait_minutes": 5,
      "commercial_standard_lanes_open": null,
      "pedestrian_standard_lanes_open": 14,
      "passenger_standard_wait_minutes": 60,
      "commercial_standard_wait_minutes": null,
      "pedestrian_standard_wait_minutes": 5,
      "passenger_sentri_nexus_lanes_open": 4,
      "passenger_sentri_nexus_wait_minutes": 5
    },
    {
      "city": "San Ysidro",
      "hours": "24 hrs/day",
      "state": "California",
      "border": "Mexico",
      "status": "open",
      "page_url": "https://bwt.cbp.gov/details/09250409/POV",
      "last_updated": "2026-09-28T21:56:01-07:00",
      "crossing_name": "San Ysidro - Cross Border Express",
      "commercial_fast_lanes_open": null,
      "passenger_ready_lanes_open": null,
      "pedestrian_ready_lanes_open": 1,
      "commercial_fast_wait_minutes": null,
      "passenger_ready_wait_minutes": null,
      "passenger_standard_lanes_open": null,
      "pedestrian_ready_wait_minutes": 0,
      "commercial_standard_lanes_open": null,
      "pedestrian_standard_lanes_open": 8,
      "passenger_standard_wait_minutes": null,
      "commercial_standard_wait_minutes": null,
      "pedestrian_standard_wait_minutes": 0,
      "passenger_sentri_nexus_lanes_open": null,
      "passenger_sentri_nexus_wait_minutes": null
    }
  ]
}
```

## Quick start

Call the API with a Fous API key (`FOUS_API_KEY`). To create one, turn on Developer mode in Fous Studio, then open Keys & connections → API keys (https://app.fous.com/keys).

```bash
# First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
: "${FOUS_API_KEY:?Set FOUS_API_KEY before running this example}"

curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 120 \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@cbp",
  "visibility": "public",
  "operation": "get_border_wait_times",
  "version": 1,
  "input": {},
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
# First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
import json
import os
import urllib.error
import urllib.request

api_key = os.environ.get("FOUS_API_KEY")
if not api_key:
    raise RuntimeError("Set FOUS_API_KEY before running this example")

body = json.loads("{\n  \"api\": \"@cbp\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_border_wait_times\",\n  \"version\": 1,\n  \"input\": {},\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=120) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
// First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
const apiKey = process.env.FOUS_API_KEY;
if (!apiKey) throw new Error("Set FOUS_API_KEY before running this example");

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(120_000),
  body: JSON.stringify({
  "api": "@cbp",
  "visibility": "public",
  "operation": "get_border_wait_times",
  "version": 1,
  "input": {},
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

Or describe the data in plain language: send `{"api":"@cbp","prompt":"Describe the data you need, with every detail"}` to the same URL. Fous fills in the input, runs the method that fits and returns only the fields you asked for; `data.route.calls[].request` is the exact call it made. Routing is free; the run costs the same.

## Use cases

- Compare wait times across border crossings
- Check whether a crossing is open
- Plan passenger or pedestrian border travel
- Review commercial lane availability
- Filter crossings by state or border

## FAQ

### Is Fous affiliated with CBP?

No. Fous is not affiliated with CBP. This workflow reads the public cbp.gov website and returns its data.

### How much does it cost?

Each run costs 1 credit. With pay-as-you-go, a credit costs 1¢; monthly plans cost less per credit.

### Do I need a CBP account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from cbp.gov when you run it; repeating the same request within a day may return the saved result. Fous checks this workflow automatically; it last passed a check on Sep 29, 2026.

### What are the wait times at border crossings?

Get border wait times returns passenger, pedestrian, and commercial lane wait times for each crossing.

### Is a specific border crossing open?

Get border wait times returns each crossing’s open or closed status.

### Which crossings are in a particular state?

Get border wait times can filter crossings by state.

## Related

- [TSA Wait Times API](https://fous.com/workflows/tsa-wait-times.md): Security wait time estimates at US airports.
- [US State Department API](https://fous.com/workflows/us-state-department.md): US State Department provides current travel advisories, entry rules, embassy and consulate contacts, and published monthly visa bulletin dates; guidance may be incomplete; consular agencies are excluded.
- [USCIS API](https://fous.com/workflows/uscis.md): USCIS returns case processing times showing when 80% of cases were completed and published receipt-date cutoffs, plus current case status and available case details.
- [National Park Service API](https://fous.com/workflows/national-park-service.md): The National Park Service provides official park and site information, visiting details, and current alerts; schedules and booking rules can change, and alert update dates may be unavailable.
- [Passport Index API](https://fous.com/workflows/passport-index.md): Passport Index provides passport and destination visa information, including entry guidance, permitted stays, rankings and mobility scores; travelers should confirm current entry rules with the embassy.
- [Bureau of Labor Statistics API](https://fous.com/workflows/bureau-of-labor-statistics.md): Bureau of Labor Statistics provides latest occupation pay, employment, career outlooks, unemployment, category inflation (up to 24 months’ history), and CPI conversions from January 1913.
- [GOV.UK API](https://fous.com/workflows/gov-uk.md): GOV.UK provides summarized current travel advice with linked details, published regional holidays (none for unpublished years), and possible matches on the current UK Sanctions List.
- [Freightos API](https://fous.com/workflows/freightos.md): Ocean container freight rates by global index and trade lane.
- [All Travel workflows](https://fous.com/workflows/category/travel)
