adapt markup in docs to current code 📝

This commit is contained in:
Jannis R 2018-07-16 12:39:13 +02:00
parent 9c1c2f51e5
commit d44ec05a1d
No known key found for this signature in database
GPG key ID: 0FE83946296A88A5
4 changed files with 89 additions and 63 deletions

View file

@ -61,7 +61,6 @@ The response may look like this:
```js ```js
[ { [ {
tripId: '1|31431|28|86|17122017', tripId: '1|31431|28|86|17122017',
trip: 31431,
stop: { stop: {
type: 'station', type: 'station',
id: '900000024101', id: '900000024101',
@ -86,10 +85,10 @@ The response may look like this:
line: { line: {
type: 'line', type: 'line',
id: '18299', id: '18299',
name: 'S9',
public: true,
mode: 'train', mode: 'train',
product: 'suburban', product: 'suburban',
public: true,
name: 'S9',
symbol: 'S', symbol: 'S',
nr: 9, nr: 9,
metro: false, metro: false,
@ -102,21 +101,21 @@ The response may look like this:
name: 'S-Bahn Berlin GmbH' name: 'S-Bahn Berlin GmbH'
} }
}, },
direction: 'S Spandau' direction: 'S Spandau',
trip: 31431
}, { }, {
tripId: '1|30977|8|86|17122017', tripId: '1|30977|8|86|17122017',
trip: 30977, stop: { /* … */ },
station: { /* … */ },
when: null, when: null,
delay: null, delay: null,
cancelled: true, cancelled: true,
line: { line: {
type: 'line', type: 'line',
id: '16441', id: '16441',
name: 'S5',
public: true,
mode: 'train', mode: 'train',
product: 'suburban', product: 'suburban',
public: true,
name: 'S5',
symbol: 'S', symbol: 'S',
nr: 5, nr: 5,
metro: false, metro: false,
@ -125,7 +124,8 @@ The response may look like this:
productCode: 0, productCode: 0,
operator: { /* … */ } operator: { /* … */ }
}, },
direction: 'S Westkreuz' direction: 'S Westkreuz',
trip: 30977
}, { }, {
tripId: '1|28671|4|86|17122017', tripId: '1|28671|4|86|17122017',
trip: 28671, trip: 28671,
@ -135,10 +135,10 @@ The response may look like this:
line: { line: {
type: 'line', type: 'line',
id: '19494', id: '19494',
name: 'U7',
public: true,
mode: 'train', mode: 'train',
product: 'subway', product: 'subway',
public: true,
name: 'U7',
symbol: 'U', symbol: 'U',
nr: 7, nr: 7,
metro: false, metro: false,

View file

@ -99,7 +99,7 @@ The response may look like this:
[ [
{ {
legs: [ { legs: [ {
id: '1|31041|35|86|17122017', id: '1|32615|6|86|10072018',
origin: { origin: {
type: 'station', type: 'station',
id: '900000003201', id: '900000003201',
@ -119,30 +119,23 @@ The response may look like this:
regional: true regional: true
} }
}, },
departure: '2017-12-17T19:07:00.000+01:00',
departurePlatform: '16',
destination: { destination: {
type: 'station', type: 'station',
id: '900000024101', id: '900000100004',
name: 'S Charlottenburg', name: 'S+U Jannowitzbrücke',
location: { location: {
type: 'location', type: 'location',
latitude: 52.504806, latitude: 52.504806,
longitude: 13.303846 longitude: 13.303846
}, },
products: { products: { /* … */ }
suburban: true,
subway: false,
tram: false,
bus: true,
ferry: false,
express: false,
regional: true
}
}, },
arrival: '2017-12-17T19:47:00.000+01:00', departure: '2018-07-10T23:54:00.000+02:00',
arrivalPlatform: '8', departureDelay: 60,
arrivalDelay: 30, departurePlatform: '15',
arrival: '2018-07-11T00:02:00.000+02:00',
arrivalDelay: 60,
arrivalPlatform: '3',
line: { line: {
type: 'line', type: 'line',
id: '16845', id: '16845',
@ -150,19 +143,19 @@ The response may look like this:
public: true, public: true,
mode: 'train', mode: 'train',
product: 'suburban', product: 'suburban',
operator: {
type: 'operator',
id: 's-bahn-berlin-gmbh',
name: 'S-Bahn Berlin GmbH'
},
symbol: 'S', symbol: 'S',
nr: 7, nr: 7,
metro: false, metro: false,
express: false, express: false,
night: false, night: false,
productCode: 0, productCode: 0
operator: {
type: 'operator',
id: 's-bahn-berlin-gmbh',
name: 'S-Bahn Berlin GmbH'
}
}, },
direction: 'S Potsdam Hauptbahnhof', direction: 'S Ahrensfelde',
stopovers: [ { stopovers: [ {
stop: { stop: {
type: 'station', type: 'station',
@ -173,32 +166,63 @@ The response may look like this:
}, },
arrival: null, arrival: null,
departure: null, departure: null,
cancelled: true cancelled: true,
remarks: [
{type: 'hint', code: 'bf', text: 'barrier-free'},
{type: 'hint', code: 'FB', text: 'Bicycle conveyance'}
]
}, { }, {
stop: { stop: {
type: 'station', type: 'station',
id: '900000003102', id: '900000100001',
name: 'S Bellevue', name: 'S+U Friedrichstr.',
location: { /* … */ }, location: { /* … */ },
products: { /* … */ } products: { /* … */ }
}, },
arrival: '2017-12-17T19:09:00.000+01:00', arrival: '2018-07-10T23:56:00.000+02:00',
arrivalPlatform: '1', arrivalDelay: 60,
departure: '2017-12-17T19:09:00.000+01:00', arrivalPlatform: null,
departurePlatform: '1' departure: '2018-07-10T23:57:00.000+02:00',
}, /* … */ { departureDelay: 60,
stop: { departurePlatform: null,
remarks: [ /* … */ ]
},
/* … */
{
type: 'station', type: 'station',
id: '900000024101', id: '900000100004',
name: 'S Charlottenburg', name: 'S+U Jannowitzbrücke',
location: { /* … */ }, location: { /* … */ },
products: { /* … */ } products: { /* … */ }
}, },
arrival: '2017-12-17T19:17:00.000+01:00', arrival: '2018-07-11T00:02:00.000+02:00',
arrivalPlatform: '5', arrivalDelay: 60,
departure: '2017-12-17T19:17:00.000+01:00', arrivalPlatform: null,
departurePlatform: '5' departure: '2018-07-11T00:02:00.000+02:00',
departureDelay: null,
departurePlatform: null,
remarks: [ /* … */ ]
} ] } ]
}, {
origin: {
type: 'station',
id: '900000100004',
name: 'S+U Jannowitzbrücke',
location: { /* … */ },
products: { /* … */ }
},
destination: {
type: 'station',
id: '900000100008',
name: 'U Heinrich-Heine-Str.',
location: { /* … */ },
products: { /* … */ }
},
departure: '2018-07-11T00:01:00.000+02:00',
arrival: '2018-07-11T00:10:00.000+02:00',
mode: 'walking',
public: true,
distance: 558
} ] } ]
}, },
earlierRef: '…', // use with the `earlierThan` option earlierRef: '…', // use with the `earlierThan` option

View file

@ -54,14 +54,14 @@ The response may look like this:
} }
}, { // point of interest }, { // point of interest
type: 'location', type: 'location',
name: 'Berlin, Holiday Inn Centre Alexanderplatz****',
id: '900980709', id: '900980709',
name: 'Berlin, Holiday Inn Centre Alexanderplatz****',
latitude: 52.523549, latitude: 52.523549,
longitude: 13.418441 longitude: 13.418441
}, { // point of interest }, { // point of interest
type: 'location', type: 'location',
name: 'Berlin, Hotel Agon am Alexanderplatz',
id: '900980176', id: '900980176',
name: 'Berlin, Hotel Agon am Alexanderplatz',
latitude: 52.524556, latitude: 52.524556,
longitude: 13.420266 longitude: 13.420266
} ] } ]

View file

@ -66,24 +66,26 @@ The response may look like this:
lines: [ { lines: [ {
type: 'line', type: 'line',
id: 'u1', id: 'u1',
name: 'U1',
public: true,
class: 2,
product: 'subway',
mode: 'train', mode: 'train',
product: 'subway',
public: true,
name: 'U1',
class: 2,
symbol: 'U', symbol: 'U',
nr: 1, nr: 1,
metro: false, metro: false,
express: false, express: false,
night: false }, night: false
},
// … // …
{ type: 'line', {
type: 'line',
id: 'n9', id: 'n9',
name: 'N9',
public: true,
class: 8,
product: 'bus',
mode: 'bus', mode: 'bus',
product: 'bus',
public: true,
name: 'N9',
class: 8,
symbol: 'N', symbol: 'N',
nr: 9, nr: 9,
metro: false, metro: false,