Discover/Gov API
live

Gov APIrtr.pbs.gov.tw

Access real-time road conditions across Taiwan from the Police Broadcasting Service. Filter by region or highway. Live accident, congestion, and hazard data.

Endpoint health
verified 3d ago
get_road_conditions_by_region
get_road_conditions_by_highway
get_road_conditions
3/3 passing latest checkself-healing
Endpoints
3
Updated
26d ago

What is the Gov API?

The PBS Taiwan Road Conditions API exposes live traffic and road incident data from the Police Broadcasting Service (rtr.pbs.gov.tw) across 3 endpoints. Each record returns 8 structured fields including category, area, location, and info describing the condition. The get_road_conditions_by_region endpoint lets you filter by named region such as 北部 or 南部, while get_road_conditions_by_highway narrows results to a specific highway like 國道1號.

Try it
Maximum number of results to return.
api.parse.bot/scraper/0ffc8282-b83d-4780-b5e0-10ac06bc8cff/<endpoint>
Ready to send
Fill in the parameters and hit sign in to send to see live response data here.
Call it over HTTPgrab a free API key at signup
curl -X GET 'https://api.parse.bot/scraper/0ffc8282-b83d-4780-b5e0-10ac06bc8cff/get_road_conditions?limit=5' \
  -H 'X-API-Key: $PARSE_API_KEY'
Python SDK · recommended

Typed, relational, agent-ready

A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.

  • Fully typed · autocompletes
  • Objects link to objects
  • Typed errors & pagination

Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:

uv add parse-sdk
uv run parse init
uv run parse add --marketplace rtr-pbs-gov-tw-api

uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.

"""PBS Road Conditions — real-time traffic monitoring from Taiwan's Police Broadcasting Service."""
from parse_apis.pbs_road_conditions_api import PBSRoad, Region, RegionInvalid

client = PBSRoad()

# List the most recent road conditions across all regions.
for condition in client.roadconditions.list(limit=5):
    print(condition.category, condition.area, condition.location, condition.info[:60])

# Filter by region using the Region enum — Northern Taiwan.
northern = client.roadconditions.by_region(region=Region.NORTH, limit=3).first()
if northern:
    print(northern.number, northern.category, northern.source)

# Search by highway name — National Freeway 1.
for cond in client.roadconditions.by_highway(highway="國道1號", limit=3):
    print(cond.number, cond.location, cond.uptime)

# Typed error handling for invalid region input.
try:
    client.roadconditions.by_region(region="", limit=1).first()
except RegionInvalid as exc:
    print(f"Invalid region: {exc}")

print("exercised: roadconditions.list / by_region / by_highway + RegionInvalid error")
All endpoints · 3 totalmissing one? ·

Fetches all real-time road conditions from the Police Broadcasting Service. Returns records ordered by most recent update time. The limit parameter caps total items returned.

Input
ParamTypeDescription
limitintegerMaximum number of results to return.
Response
{
  "type": "object",
  "fields": {
    "items": "array of road condition records, each containing number, category, uptime, date, time, source, area, location, and info"
  },
  "sample": {
    "data": {
      "items": [
        {
          "area": "北部",
          "date": "今天",
          "info": "福爾摩沙高速公路-國道3號南下於70公里至95公里之間",
          "time": "12:06",
          "number": "11506110157",
          "source": "高速公路局北區交控中心",
          "uptime": "今天 12:07",
          "category": "道路施工",
          "location": "福爾摩沙高速公路-國道3號"
        }
      ]
    },
    "status": "success"
  }
}

About the Gov API

What the API Returns

All three endpoints return arrays of road condition records sourced from the Police Broadcasting Service's real-time feed, aggregated via road.ioi.tw. Every record includes: number (record identifier), category (incident type), uptime (freshness indicator), date, time, source (reporting agency), area (geographic area), location (specific road location), and info (free-text description of the condition). Results are ordered by most recent update time.

Filtering by Region and Highway

get_road_conditions_by_region accepts a region parameter using either Chinese region names (北部, 中部, 南部, 東部, 國道, 全區) or their single-letter codes (N, M, S, E, F). This makes it straightforward to isolate conditions for a specific part of Taiwan. get_road_conditions_by_highway accepts a highway string — for example 國道1號 or 國道3號 — and performs a keyword match against records, useful when monitoring a specific freeway corridor.

Pagination and Volume Control

All three endpoints accept an optional limit integer parameter that caps the number of records returned. When omitted, the default result set is returned ordered by recency. There is no explicit offset or cursor parameter in the current API surface, so limit is the primary tool for controlling response volume. The get_road_conditions endpoint fetches the full cross-Taiwan feed without any region or highway filter applied.

Reliability & maintenanceVerified

The Gov API is a managed, monitored endpoint for rtr.pbs.gov.tw — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when rtr.pbs.gov.tw changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.

This isn't an official rtr.pbs.gov.tw API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.

Last verified
3d ago
Latest check
3/3 endpoints passing
Maintenance
Monitored & self-healing
Will this API break when the source site changes?+
It's built not to. Every endpoint is health-checked on a schedule with automated test probes. When the source site changes and a check fails, the API is automatically queued for repair and re-verified — that's the self-healing layer. Each API page shows when its endpoints were last verified. And because marketplace APIs are shared, any fix reaches everyone using it.
Is this an official API from the source site?+
No — Parse APIs are independent, managed REST wrappers over publicly available data. That is the point: where a site has no official API (or only a limited one), Parse gives you a maintained, monitored endpoint for that data and keeps it working as the site changes — so you get a stable contract over a source that never promised one.
Can I fix or extend this API myself if I need a new endpoint or field?+
Yes — and you don't have to wait on us. This API was generated by the Parse agent, which stays attached. Describe the change in plain English ("add an endpoint that returns reviews", "fix the price field") in the revise box on the API page or via the revise_api MCP tool, and the agent rebuilds it against the live site in minutes. Contributing the change back to the public API is free.
What happens if I call an endpoint that has an issue?+
Errors are machine-readable: a bad call returns a clean status with the list of available endpoints and a repair hint, so an agent (or you) can recover or trigger a fix instead of failing silently. Confirmed failures feed the automatic repair queue.
Common use cases
  • Display a live incident map for Taiwan highways using the area and location fields
  • Send push alerts to drivers when new conditions appear on a watched highway via get_road_conditions_by_highway
  • Build a regional dashboard for northern or southern Taiwan using get_road_conditions_by_region with 北部 or 南部
  • Log historical road condition records by polling the API and storing date, time, and category fields
  • Filter and surface only freeway incidents by querying the 國道 region code
  • Aggregate incident frequency by category type across all regions to identify recurring hazard patterns
  • Feed real-time road data into a route-planning tool to flag active disruptions along a selected corridor
Pricing & limitsSee full pricing →
TierPriceCredits/monthRate limit
Free$0/mo1005 req/min
Hobby$30/mo1,00020 req/min
Developer$100/mo5,000100 req/min

One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.

Frequently asked questions
Does the Police Broadcasting Service provide an official developer API?+
The PBS road condition site at rtr.pbs.gov.tw does not publish a documented public developer API or SDK. This Parse API provides structured programmatic access to the same real-time data.
What does the `info` field contain, and is it machine-parseable?+
The info field is a free-text Chinese-language string describing the specific road condition — for example, lane closures, accident details, or hazard descriptions. It is not structured into sub-fields, so parsing specific attributes from it requires your own text processing.
Does the API cover city streets and provincial roads, or only national freeways?+
The API covers national freeway (國道) corridors and the four broad geographic regions of Taiwan (北部, 中部, 南部, 東部). Granular city-street or provincial-highway-level filtering is not currently exposed as a dedicated parameter. You can fork this API on Parse and revise it to add a finer-grained location filter if your source data includes those records.
Is there a way to paginate through results beyond the first page?+
The current API surface exposes a limit parameter to cap result count but does not include an offset, page number, or cursor parameter. All three endpoints return results ordered by most recent update time, so the freshest records are always at the top of the response. You can fork the API on Parse and revise it to add offset-based pagination if your use case requires deeper result sets.
Can I filter conditions by incident category, such as accidents only?+
Category filtering is not a dedicated input parameter on any endpoint. The category field is present in every response record and can be filtered client-side after retrieval. You can fork the API on Parse and revise it to add a category query parameter that pre-filters the result set server-side.
Page content last updated . Spec covers 3 endpoints from rtr.pbs.gov.tw.
Related APIs in Maps GeoSee all →
tomtom.com API
Get TomTom Traffic Index congestion rankings for cities worldwide or within a specific country, and retrieve detailed traffic metrics for a given city (including AM/PM and monthly trends).
ratp.fr API
Monitor real-time traffic conditions and service disruptions across Paris's RATP and RER networks to plan your commute efficiently. Get instant updates on line statuses, delays, and service alerts for all metro and regional rail lines.
mbta.com API
Track real-time subway, bus, and commuter rail departures across Greater Boston, check schedules and service alerts, and find detailed information about routes and stops. Plan your commute with up-to-the-minute MBTA transit data and never miss your connection.
rfi.it API
Check real-time train schedules and station information across Italy's railway network, search for stations, and get live alerts about delays and service disruptions. Monitor train circulation status and access detailed station mappings to plan your journeys efficiently.
tw.coupang.com API
Search for products on Coupang Taiwan and browse by category, brand, or Rocket Delivery availability to find exactly what you're looking for. Get detailed product information, view homepage featured items, and discover deals across thousands of listings.
104.com.tw API
Search for jobs across Taiwan's largest job board and retrieve detailed job listings including descriptions, requirements, and company information. Find the right career opportunities by browsing thousands of positions or searching for specific roles that match your skills and interests.
hydro.chmi.cz API
Monitor real-time water conditions across 562+ Czech river stations by accessing live water levels, flow rates, temperatures, and flood alerts. Search and track specific stations to get detailed hydrological data and historical time series information from the Czech Hydrometeorological Institute.
bart.gov API
Track live BART train departures and arrival estimates across all Bay Area stations in real-time. Find your nearest station and see exactly when the next train is arriving on every platform.