Traffic API Developer's Guide

Selecting Tile Size

The Traffic API allows requests to select the size of the size of the tile to be delivered in the response. Such requests follow the same pattern as requests for traffic flow tile overlays, but require the parameter res to select the tile size and/or depth to determine the required color depth.

Tile Size, [Z]/[X]/[Y] Addressing

User Story

The user wants to obtain a traffic tile for an area near Frankfurt, Germany, using the [Z]/[X]/[Y] addressing scheme. The response is to deliver a tile measuring 512x512 pixels (Other possibilities are: 256x256 pixels and 128x128 pixels).

Request Summary

The following list summarizes the elements required to create a request matching the user story and shows, in square brackets, how those elements are used in the request example below. Note that the request example also uses the authentication parameters.

Resource: tiles [tiles]
URL variables: {zoom}/{column}/{row} [8/134/86], the [Z]/[X]/[Y] (tile) addressing scheme, see also The Mercator Projection
  {size} [512], the resolution of the response image
  {format} [png32], the format of the response image

Request

A request matching the user story is formulated as follows:

https://tiles.traffic.cit.api.here.com/traffic/6.0/tiles/8/134/86/512/png32
?app_id={YOUR_APP_ID}
&app_code={YOUR_APP_CODE}

Response

The image below shows the tile delivered in response to the request.

Figure 1. Resized Large Flow Tile Request 512 pixel flow tile

Tile Size, Quadkey Addressing

User Story

The user wants to obtain a traffic tile for an area near Frankfurt, Germany, using a quadkey. The response is to deliver a tile measuring 128x128 pixels. (The default is 256x256 pixels and the third possibility is 512x512 pixels.)

Request Summary

The following list summarizes the elements required to create a request matching the user story and shows, in square brackets, how those elements are used in the request example below. Note that the request example also uses the authentication parameters.

Note that quadkey addressing makes it necessary to use res as a query parameter.

Resource: tiles [tiles]
URL variables: {quadkeytraffic} [quadkeytraffic], resource endpoint, indicating that a traffic tile overlay based identified by a quadkey is required
Parameters: quadkey [quadkey=12020330], map tile location specified as a single value, see also Quadkeys
  res [res=bitmap128], an indication that a square bitmap with a side measuring 128 pixels is required

Request

A request matching the user story is formulated as follows:

https://tiles.traffic.cit.api.here.com/traffic/6.0/tiles/quadkeytraffic
?app_id={YOUR_APP_ID}
&app_code={YOUR_APP_CODE}
&quadkey=12020330
&res=bitmap128

Response

Here is the response image tile measuring 128x128 pixels:

Figure 2. Resized Small Flow Tile Request 128 pixel flow tile

You cannot use this account to purchase a commercial plan on Developer Portal, as it is already associated to plans with different payment methods.

To purchase a commercial plan on Developer Portal, please register for or sign in with a different HERE Account.

Something took longer than expected.

The project should be available soon under your projects page.

Sorry, our services are not available in this region.

Something seems to have gone wrong. Please try again later.

We've detected that your account is set to Australian Dollars (AUD).
Unfortunately, we do not offer checkouts in AUD anymore.
You can continue using your current plan as normal, but to subscribe to one of our new plans,
please register for a new HERE account or contact us for billing questions on selfservesupport@here.com.