mirror of
https://github.com/public-transport/db-vendo-client.git
synced 2025-02-23 15:19:35 +02:00
adapt docs to 3c9c5cb 📝
This commit is contained in:
parent
665bed9f79
commit
2d11cfae1e
2 changed files with 5 additions and 5 deletions
|
@ -4,7 +4,7 @@
|
||||||
- [`journeyLeg(ref, lineName, [opt])`](journey-leg.md) – get details for a leg of a journey
|
- [`journeyLeg(ref, lineName, [opt])`](journey-leg.md) – get details for a leg of a journey
|
||||||
- [`departures(station, [opt])`](departures.md) – query the next departures at a station
|
- [`departures(station, [opt])`](departures.md) – query the next departures at a station
|
||||||
- [`locations(query, [opt])`](locations.md) – find stations, POIs and addresses
|
- [`locations(query, [opt])`](locations.md) – find stations, POIs and addresses
|
||||||
- [`location(id)`](location.md) – get details about a location
|
- [`station(id)`](station.md) – get details about a station
|
||||||
- [`nearby(location, [opt])`](nearby.md) – show stations & POIs around
|
- [`nearby(location, [opt])`](nearby.md) – show stations & POIs around
|
||||||
- [`radar(north, west, south, east, [opt])`](radar.md) – find all vehicles currently in a certain area
|
- [`radar(north, west, south, east, [opt])`](radar.md) – find all vehicles currently in a certain area
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
# `location(station)`
|
# `station(id)`
|
||||||
|
|
||||||
`station` must be in one of these formats:
|
`id` must be in one of these formats:
|
||||||
|
|
||||||
```js
|
```js
|
||||||
// a station ID, in a format compatible to the profile you use
|
// a station ID, in a format compatible with the profile you use
|
||||||
'900000123456'
|
'900000123456'
|
||||||
|
|
||||||
// an FPTF `station` object
|
// an FPTF `station` object
|
||||||
|
@ -29,7 +29,7 @@ const vbbProfile = require('hafas-client/p/vbb')
|
||||||
|
|
||||||
const client = createClient(vbbProfile)
|
const client = createClient(vbbProfile)
|
||||||
|
|
||||||
client.location('900000042101') // U Spichernstr.
|
client.station('900000042101') // U Spichernstr.
|
||||||
.then(console.log)
|
.then(console.log)
|
||||||
.catch(console.error)
|
.catch(console.error)
|
||||||
```
|
```
|
Loading…
Add table
Reference in a new issue