Incidents
This resource is responsible for handling requests for traffic incident information for or a geospatial area. The delivery formats are either XML or JSON. The below provided request parameters are valid for both incident endpoints (6.0 and 6.1)*.
(* one exception is the type
parameter. For more details see description for this parameter.)
Parameter Combinations for Common Use Cases
Required | Optional |
---|---|
|
|
Required | Optional |
---|---|
|
|
Response Data Format
This resource can deliver response data either in XML of JSON, depending on the addressing scheme:
- [Z]/[X]/[Y] addressing – use the URL variables
xml
orjson
, immediately after the resource name, for example.../flow/xml/...
or.../incidents/json/...
- otherwise – use resource extensions
.xml
or.json
, for example.../flow.json/...
,.../incidents.xml/...
See also Examples for complete working URLs.
Resource Parameters
Parameter | Description |
---|---|
app_code | A 20-byte Base64 URL-safe encoded string used for the authentication of the client application. You must include an |
app_id | A 20-byte Base64 URL-safe encoded string used for the authentication of the client application. You must include an |
apiKey | A 43-byte Base64 URL-safe encoded string used for the authentication of the client application. As a logged in user, you can generate it at https://developer.here.com/projects. API Keys never expire but you can invalidate your API Keys at any time. You cannot have more than two API Keys for one app at the same time. You must include an |
bbox | A type of spatial filter. A spatial filter defines the area targeted by the request (the area for which to retrieve data or a map tile). A bounding box represents a rectangular area specified by two latitude/longitude pairs; the first pair defines the top-left corner of the bounding box, the second the bottom-right corner. Note: The maximum allowed size of the bounding box (width and height) is limited to 10 degrees. |
c | An indicator of the country (locale for the incident response). The accepted values include certain ISO country codes (two bytes, ISO 3166-1-alpha-2). The parameter must be used in conjunction with the |
corridor | A type of spatial filter. A spatial filter defines the area targeted by the request (the area for which to retrieve data or a map tile). The response to a corridor request includes results that fall within the area of the corridor. The corridor is defined by its path and width. The path is a line along the center of the corridor represented by a series of latitude/longitude pairs. Corridor width is given in meters. |
criticality | A filter that selects incident reports according to criticality, case insensitive. The parameter may contain multiple comma-separated values selected from the following list:
Note that if this parameter is not provided, all incident reports are included in the response, regardless of criticality (default behavior). |
endTime | See xs:dateTime for the format to use when filtering time values. |
i18n | A flag indicating whether incident messages should be translated to the language specified in the The permitted values for the parameter are:
|
inc22 | A flag indicating whether to format the response to match version. 2.2 of the incidents XSD ( The permitted values are:
|
jsoncallback | A parameter providing the name of a user-defined function used to wrap the JSON response. |
lg | A specifier of the language of the locale for the incident response. The parameter must be used in conjunction with the See Supported Translation Languages for allowed values. |
localtime | A flag indicating if all time values in the response to a request for traffic incident data should be in the local time of the incident (
|
maxresults | An indicator of the maximum number of incidents to be included in the response. Only non-zero positive number values are allowed. |
profile | Profile defines such attributes as geographic coverage (TMC tables available for use) and custom color mapping for tile overlays. |
prox | A type of spatial filter. A spatial filter defines the area targeted by the request (the area for which to retrieve data or a map tile). A response to a request using proximity includes any results that fall within a circle defined by the a latitude and a longitude of its center and radius (given in meters). |
quadkey | An identifier of a map tile in a grid of tiles spanning the entire globe. A quadkey is a single number string from 0 to 21 digits long. The map zoom level for the grid to which a quadkey refers is equal to the number of digits in the quadkey string. Use only with a quadkey addressing scheme endpoint. See also Quadkeys. |
sort | An indicator, specifying how to sort the response data to a traffic incident request according to criticality. The permitted values are:
|
startTime | The minimum start time to be matched by an incident to be included in the results, in GMT format. See xs:dateTime for the format to use when filtering time values. |
status | A status indicator that triggers incident selection according to their status; case insensitive. The parameter value may consist of multiple values, separated by a comma. The accepted status values include: |
tables | A parameter that specifies TMC tables in the profile to include or exclude from response. If the value specifies multiple tables, the table ids are separated by commas. Positive values are included, and negative values are excluded. Note: A combination of positive and negative values is not supported and results in an error response. By default (when the parameter is not used in a request) the response includes all tables in the profile. See TMCCodeType for a full list of TMC tables or your customer profile for a list of tables available to you. |
type | An indicator, specifying the type of items to include in the response, case insensitive. The value may contain multiple type identifiers separated by a comma. The permitted traffic item type identifiers that can be used in the value are:
By default (when the parameter is not specified in the request), the response includes all incident reports, regardless of type. * - This type is supported only when requesting incidents ver 2.2 (traffic/6.1/incidents.<format> endpoint) |
verified | A flag indicating if the response is to include or exclude incident reports that have been confirmed. The permitted values are:
By default, when this parameter is not specified in the request, the response includes all incident reports, regardless of type. |
units | This parameter is used to assure that all values in the response are converted to the needed Units system. Accepts the following values:
By default, when this parameter is not specified, values are returned in the same Unit system as it was received from Content feed. |