approved, byrokraatit, ylläpitäjät
0
muokkausta
Rivi 195: | Rivi 195: | ||
{ | { | ||
"href" : "http://example.com/journeys/api/route-patterns/111", | "href" : "http://example.com/journeys/api/route-patterns/111", | ||
"route" : "http://example.com/journeys/api/routes/123", | |||
"pointsOnRoute": [ | "pointsOnRoute": [ | ||
{ | { | ||
"latitude" : "61.48016", | "latitude" : "61.48016", | ||
"longitude" : "23.83057" | "longitude" : "23.83057" | ||
}, | }, | ||
{ | { | ||
"latitude" : "60.48016", | "latitude" : "60.48016", | ||
"longitude" : "23.83057" | "longitude" : "23.83057" | ||
}, | }, | ||
{ | { | ||
"latitude" : "59.48016", | "latitude" : "59.48016", | ||
"longitude" : "23.83057" | "longitude" : "23.83057" | ||
Rivi 216: | Rivi 214: | ||
} | } | ||
} | } | ||
</pre> | </pre> | ||
A client can search ROUTE PATTERNS by issuing following requests: | A client can search ROUTE PATTERNS by issuing following requests: | ||
* http://example.com/journeys/api/route-patterns? | * http://example.com/journeys/api/route-patterns returns all ROUTE PATTERNS | ||
* http://example.com/journeys/api/route-patterns? | * http://example.com/journeys/api/route-patterns?routeId=111 will return ROUTE PATTERN for ROUTE with id 111 | ||
* http://example.com/journeys/api/route-patterns? | * http://example.com/journeys/api/route-patterns?startsAt=61.48016,23.83057 will return ROUTE PATTERNS that start at given coordinates | ||
* http://example.com/journeys/api/route-patterns?startsAt=61.48016,23.83057:51.83057,13.83057 will return ROUTE PATTERNS that start within given coordinate box (format upper left corner of the box:lower right corner of the box) | |||
* http://example.com/journeys/api/route-patterns?stopsAt=61.48016,23.83057 will return ROUTE PATTERNS that stop at given coordinates | |||
* http://example.com/journeys/api/route-patterns?stopsAt=61.48016,23.83057:51.83057,13.83057 will return ROUTE PATTERNS that stop within given coordinate box (format upper left corner of the box:lower right corner of the box) | |||
==== Journeys ==== | ==== Journeys ==== |