TrafficView API Reference

Version: 4.6.24
Last updated: 2024-04-04

Overview

This is the documentation for the TrafficView API v4.6.24. The API allows users to query various types of data from the RITIS databases, e.g. traffic incidents, dynamic message signs, weather.

This document is a work in progress and subject to change at any time (see change log).

If you have additional questions, please email us at support@trafficview.org.

Authentication

TrafficView is currently restricted to authorized users. You can request an API key.

To authenticate GET requests, add a parameter api-key with your API key as the value:

https://api.trafficview.org/event/?api-key=your_api_key

If you need an additional API key for your system, please email us at support@trafficview.org.

Sending filter requests

GET

Filter parameters are passed as GET parameters in the URL. For example, you can use the road filter to get all active events on I-495 as reported by the Maryland DOT:

https://api.trafficview.org/event/?api-key=your_api_key&system=mdot_chart&road=I-495

The /event endpoint returns event data. For other data types, see Endpoints.

For a complete list of GET parameters, see Filters.

How filters are applied

Multiple different filters are joined with AND, such as road is 'I-95' AND state is 'MD'.

Multiple filters of the same type are joined with OR, such as road is 'I-95' OR road is 'I-495', except for geospatial filters (box filter, radius filter).
Multiple geospatial filters of the same type are joined with AND: two box filters that do not overlap will return no results.

Output formats

The API can return data in multiple formats. You can specify which using output parameters.

ATIS/TMDD Schema

The ATIS/TMDD schema is an official standardized schema for traffic events, DMS & detector data. The CATT Lab includes a few extensions for information that is missing but deemed critical.

You can find the complete ATIS & TMDD schema here.

Lanes are arranged like this:

S S S S N N N N
0 1 2 3 4 5 6 7

RF will return the lanes in the order:

3 2 1 0 4 5 6 7

Thus the lanes are ordered from left to right in the order of travel per direction, regardless of the number of directions.

Lanes from the same direction are always grouped together, and directions are ordered, from left to right: south before north, west before east, and inner loop before outer loop.

CATT Lab Schema (rf-schema-xml)

The CATT Lab developed an unofficial schema for traffic events, DMS, & detector data based on our experiences working with the data. In general, this schema can provide more data. It can also express how an event changed over time for better analysis without complicated querying.

This schema is under development and not finalized.

You can find the complete CATT Lab schema here.

CATT Lab JSON Schema (rf-json)

The structure of this schema matches the regular CATT Lab Schema (rf-schema-xml) almost exactly. Some elements have been restructured to follow JSON standards. For example, "event" tags in rf-schema-xml are enclosed in another tag called "events". In the JSON output, the "event" tags are removed and the "events" tag is turned into a JSON array.

This schema is under development and not finalized.

Available agencies

These are all of the available agencies (system IDs) by data type.

Use the Agency API to learn more.

Show all agencies

detector
  • austintx
  • azdot
  • caltrans
  • fdot
  • gdot
  • here
  • ildot
  • ladotd
  • mdot_chart
  • midot
  • modot
  • ordot
  • speedinfo
  • tdot
  • txdot
  • vdot
  • vdot_rm3p
  • vdot_transurban
  • vdot_wavetronix
dms
  • austintx
  • azdot
  • caltrans
  • ddot_captop
  • deldot
  • dfw511
  • fdot
  • gdot
  • ildot
  • ladotd
  • mdot_chart
  • midot
  • mndot
  • ordot
  • pgcotrip
  • scdot
  • txdot
  • vdot
  • vdot_transurban
  • vtrans
  • wisdot
event
  • austintx
  • azdot
  • caltrans
  • ddot_captop
  • deldot
  • dfw511
  • fdot
  • gdot
  • hococad
  • ildot
  • iowadot
  • ladotd
  • massdot
  • mdot_chart
  • midot
  • mndot
  • modot
  • mstraffic
  • ncdot
  • nhdot
  • njdot
  • ny511
  • ohdot
  • ordot
  • padot
  • paturnpike
  • pgcocad
  • pgcotrip
  • ridot
  • ritis_input
  • scdot
  • tdot
  • txdot
  • vdot
  • vdot_transurban
  • vtrans
  • wisdot
  • wisdot_cad
  • wmata
  • wsdot
weather
  • azdot
  • nws
  • vdot
  • vtrans
  • wxde

Filters

Show all filters

General filters

System (Agency) Filter Limit results to one or more systems

Parameters:

  • system (STRING:optional:repeatable)
    One of the agencies providing data for RITIS
  • system-is (IS_TYPE:optional)
    Deprecated. Do NOT use.
    • equal
    • not equal
  • system-all (BOOLEAN:optional)
    Use all available systems

id-filters

ID Filter Return the item with the specified ID

Compatible data types: detector, dms, event, weather

Parameters:

  • id (STRING)
    Uniquely identifies an event, detector, etc.

location-filters

Box Filter Limit results to within (or not within) a box

Compatible data types: detector, dms, event, weather

Parameters:

  • width (NON_NEGATIVE_DECIMAL)
    The width (in meters) of the box
  • height (NON_NEGATIVE_DECIMAL)
    The height (in meters) of the box
  • box-lat (LATITUDE)
    The latitude of the lower left corner of the box
  • box-lon (LONGITUDE)
    The longitude of the lower left corner of the box
  • box-within (BOOLEAN:optional)
    Whether to include or exclude results within the box
City Filter Filter results by city

Compatible data types: detector, dms, event

Parameters:

  • city (STRING)
    The city's full name or abbreviation
  • city-is (IS_TYPE:optional)
    Equal to or not equal to the specified city
    • equal (default)
    • not equal
Country Filter Filter results by country

Compatible data types: detector, dms, event, weather

Parameters:

  • country (STRING)
    The country's full name or abbreviation
  • country-is (IS_TYPE:optional)
    Equal to or not equal to the specified country
    • equal (default)
    • not equal
County Filter Filter results by county

Compatible data types: detector, dms, event, weather

Parameters:

  • county (STRING)
    • The county's name, or
    • The county's name and the state's full name or abbreviation, separated by a pipe character (|)
  • county-is (IS_TYPE:optional)
    Equal to or not equal to the specified county
    • equal (default)
    • not equal
Lat Lon Box Filter Limit results to within (or not within) a box given southwest and northeast latlon corner points

Compatible data types: detector, dms, event, weather

Parameters:

  • sw-lat (LATITUDE)
    The latitude of the lower left corner of the box
  • sw-lon (LONGITUDE)
    The longitude of the lower left corner of the box
  • ne-lat (LATITUDE)
    The latitude of the top right corner of the box
  • ne-lon (LONGITUDE)
    The longitude of the top right corner of the box
  • lat-lon-box-within (BOOLEAN:optional)
    Whether to include or exclude results within the box
Radius Filter Limit results to within (or not within) a distance from a center point

Compatible data types: detector, dms, event, weather

Parameters:

  • radius (NON_NEGATIVE_DECIMAL)
    The radius (in meters) from the center point
  • radius-lat (LATITUDE)
    The latitude of the center point
  • radius-lon (LONGITUDE)
    The longitude of the center point
  • radius-within (BOOLEAN:optional)
    Whether to include or exclude results within the radius
State Filter Filter results by state

Compatible data types: detector, dms, event, weather

Parameters:

  • state (STRING)
    The state's full name or abbreviation
  • state-is (IS_TYPE:optional)
    Equal to or not equal to the specified state
    • equal (default)
    • not equal
Unmapped Filter Indicate whether to return results with no location data (latitude/longitude)

Compatible data types: detector, dms, event, weather

Parameters:

  • unmapped (INCLUDE_EXCLUDE)
    Include, exclude, or return only unmapped data
    • include
    • exclude
    • only

location-filters/road-filters

Road Class Filter Limit to results that are part of the FRC (Functional Road Class)

Compatible data types: event

Parameters:

  • frc (NON_NEGATIVE_INTEGER)
    A comma-separated list of integer representations of FRC
Road Name Filter Filter results by roads

Compatible data types: event, detector, dms

Parameters:

  • road (STRING)
    The road name
  • road-is (IS_CONTAINS_TYPE:optional)
    Equal, not equal, contains, or not-contains
    • equal (default)
    • not equal
    • contains
    • not contains

output-parameters

Exclude Geometry Indicates whether geometry data should be excluded in the response

Compatible data types:

Parameters:

  • exclude-geometry (BOOLEAN:optional)
    Indicates whether geometry data should be excluded in the response
Output Format Specify the output format

Parameters:

  • format (OUTPUT_FORMAT:optional)
    The format
    • atis-tmdd-xml
    • rf-schema-xml
    • rf-json
Response Limit Limit the number of results

Parameters:

  • response-limit (NON_NEGATIVE_INTEGER:optional)
    The maximum number of results to return
  • response-offset (NON_NEGATIVE_INTEGER:optional)
    Skip the first specified number of results

request-headers

API Key Specify the API key

Parameters:

  • api-key (STRING:optional)
    The API key
Data Type Specify the data type

Parameters:

  • type (FILTER_TYPE:optional)
    The type
    • event
    • incident
    • incident_event
    • zone
    • status
    • inventory
    • data
    • station
    • observation
    • alerts
  • filter-name (FILTER_NAME:optional)
    The filter's name
    • detector
    • dms
    • event
    • weather

Endpoints

Show all methods

GeoRSS feeds

GET /rss/event
Query for events, sorted most recent first by default

Request:

Parameters:

  • Filters are passed as GET parameters in the URL.

Response: application/xml

{}

List agencies providing data for RITIS

GET /agencies
List all unique agencies

Response:

[]
GET /agencies/type
List all agencies grouped by types of data provided

Response:

{}
GET /agencies/type/{type}
List all agencies providing a data type

Request:

Path parameters:

  • type (string)

Response:

[]
GET /agencies/type/{type}/{subtype}
List all agencies providing a data type and subtype

Request:

Path parameters:

  • type (string)
  • subtype (string)

Response:

[]

Query the TrafficView API

GET /detector
Query for detector data

Request:

Parameters:

  • Filters are passed as GET parameters in the URL.

Response: application/xml, application/json

{}
GET /dms
Query for DMS data

Request:

Parameters:

  • Filters are passed as GET parameters in the URL.

Response: application/xml, application/json

{}
GET /event
Query for events

Request:

Parameters:

  • Filters are passed as GET parameters in the URL.

Response: application/xml, application/json

{}
GET /weather
Query for weather data

Request:

Parameters:

  • Filters are passed as GET parameters in the URL.

Response: application/xml, application/json

{}