Key:gtfs:location_type

From OpenStreetMap Wiki
Jump to navigation Jump to search
Public-images-osm logo.svg gtfs:location_type
Description
The exact value of the location_type column in a GTFS feed. Show/edit corresponding data item.
Group: public transport
Used on these elements
may be used on nodesmay be used on waysmay be used on areas (and multipolygon relations)may be used on relations
See also

GTFS

Status: approvedPage for proposal

The key gtfs:location_type=* is used in Public transportation tagging to add the location_type from the GTFS stops.txt file to a platform/station/entrance/ ... .

It is used to find a corresponding location in a GTFS feed. For this the feed needs to be specified using a feed code suffix (see List of GTFS feeds).

For a longer explanation on how to reference a GTFS feed, look at GTFS.

Defaults

The value of gtfs:location_type=* can often be inferred from the type of PTv2 object it is tagged on:

PTv2 object GTFS object location_type
nodewayarea public_transport=platform (preferred) stop 0
node public_transport=stop_position
node highway=bus_stop
node railway=stop
node railway=platform
node railway=tram_stop
node amenity=ferry_terminal
nodearea public_transport=station station 1
relation public_transport=stop_area
relation public_transport=stop_area_group
node railway=station
node railway=halt
nodearea aerialway=station
node railway=subway_entrance entrance/exit 2
node railway=train_station_entrance

If an object matches none of these tags, or multiple tags that would give it different values, then gtfs:location_type=* must be explicitly tagged.

Example

Consider Nijmegen bus station, it is a station so we can find it in the file stops.txt in the GTFS feed.

Below is a section of that table:

stops.txt
stop_id stop_code stop_name location_type parent_station platform_code ...
2547419 60001013 Nijmegen, Centraal Station 0 (platform) stoparea:122872 M
stoparea:122872 Nijmegen, Centraal Station 1 (station)

Adding only gtfs:stop_name:NL-OVApi=Nijmegen, Centraal Station is not sufficient, as that can refer to the bus station and all it's platforms.

To refer only to the bus station we can add gtfs:location_type:NL-OVApi:[[Key:|]]=1.

However, we can leave that out since the OSM feature is a relationpublic_transport=stop_area, which implies a value of 1.