Public Transit API v3 Developer's Guide

Constructing a Request

A typical request to the Public Transit API v3 includes the basic elements shown in the following table and, in addition, it may contain resource-specific query parameters or data.

Table 1. Basic Request Elements
Element Value/Example Description
Base URL https://transit.ls.hereapi.com Production environment
Legacy Base URL https://transit.api.here.com Production environment when you use an app_id/app_code pair. For more information, see Authentication Examples.
Path /v3 Common path for all resources
Resource    
  branding/logos Logo Brands
  board Next Nearby Departures
  multiboard/by_geocoord, multiboard/by_stn_ids All Next Departures
  stations/by_geocoord, stations/by_name, stations/by_ids Station Search
  coverage/city, coverage/nearby, coverage/search Coverage Service
  isochrone Transit Isoline
  lines/by_stn_id Line Info
  alerts/nearby Transit Alerts
Format

Supported formats:

• json

• xml

If not specified in the request, the default response format is XML
Application Code - Legacy &app_code={YOUR_APP_CODE} Substitute your own unique app_code. For more information, see Authentication Examples.
Application ID - Legacy &app_id={YOUR_APP_ID} Substitute your own unique app_id. For more information, see Authentication Examples.
API Key &apiKey={YOUR_API_KEY} Substitute your own unique apiKey. For more information, see Authentication Examples.

Here is an example of a Station Search request, which uses the HTTP GET method:

https://transit.ls.hereapi.com/v3/stations/by_name.json
?apiKey={YOUR_API_KEY}
&center=40.7510,-73.9916
&name="New York