Siirry sisältöön

Ero sivun ”Journeys API” versioiden välillä

90 merkkiä lisätty ,  17. heinäkuuta 2014 kello 00.32
Rivi 265: Rivi 265:


A client can search JOURNEYS by issuing following requests:<br>
A client can search JOURNEYS by issuing following requests:<br>
* http://example.com/journeys/api/journeys will return paged list of all JOURNEYS
* http://data.itsfactory.fi/journeys/api/1/journeys will return paged list of all JOURNEYS
* http://example.com/journeys/api/journeys?lineId=123 will return JOURNEYS which run on the LINE with id 123
* http://data.itsfactory.fi/journeys/api/1/journeys?lineId=123 will return JOURNEYS which run on the LINE with id 123
* http://example.com/journeys/api/journeys?routeId=123 will return JOURNEYS which run on the ROUTE with id 123
* http://data.itsfactory.fi/journeys/api/1/journeys?routeId=123 will return JOURNEYS which run on the ROUTE with id 123
* http://example.com/journeys/api/journeys?departureTime=08:00:00 will return JOURNEYS which depart at the given time
* http://data.itsfactory.fi/journeys/api/1/journeys?departureTime=08:00:00 will return JOURNEYS which depart at the given time
* http://example.com/journeys/api/journeys?arrivalTime=08:00:00 will return JOURNEYS which last call arrives at STOP POINT at 08:20:00+0300
* http://data.itsfactory.fi/journeys/api/1/journeys?arrivalTime=08:00:00 will return JOURNEYS which last call arrives at STOP POINT at 08:20:00+0300
* http://example.com/journeys/api/journeys?dayTypes=Monday,Tuesday,Wednesday will return JOURNEYS which run on given day types (exclusive)
* http://data.itsfactory.fi/journeys/api/1/journeys?dayTypes=Monday,Tuesday,Wednesday will return JOURNEYS which run on given day types (exclusive)
* http://example.com/journeys/api/journeys?stopPointId=111 will return JOURNEYS which contains a call which contains STOP POINT with id 111
* http://data.itsfactory.fi/journeys/api/1/journeys?stopPointId=111 will return JOURNEYS which contains a call which contains STOP POINT with id 111
* http://example.com/journeys/api/journeys?firstStopPointId=111 will return JOURNEYS which first call which contains STOP POINT with id 111
* http://data.itsfactory.fi/journeys/api/1/journeys?firstStopPointId=111 will return JOURNEYS which first call which contains STOP POINT with id 111
* http://example.com/journeys/api/journeys?lastStopPointId=111 will return JOURNEYS which last call which contains STOP POINT with id 111
* http://data.itsfactory.fi/journeys/api/1/journeys?lastStopPointId=111 will return JOURNEYS which last call which contains STOP POINT with id 111


These queries return response like above, with entities matching the criteria. All query parameters are exclusive (if you specify multiple conditions, the conditions are ANDed together). For example query:
These queries return response like above, with entities matching the criteria. All query parameters are exclusive (if you specify multiple conditions, the conditions are ANDed together). For example query:
* http://example.com/journeys/api/journeys?departureTime=08:00:00&lineId=123 will return JOURNEYS which depart at the given time and are on LINE with id 123
* http://data.itsfactory.fi/journeys/api/1/journeys?departureTime=08:00:00&lineId=123 will return JOURNEYS which depart at the given time and are on LINE with id 123


==== Stop Points ====
==== Stop Points ====
0

muokkausta