You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -53,6 +42,12 @@ If the currency field is null, USD cents is implied.
53
42
54
43
[Top][toc]
55
44
45
+
## Data Types
46
+
47
+
Shared data structures including [vehicles](/data-types.md#vehicles), [vehicle events](/data-types.md#vehicle-state-events), [vehicle telemetry](/data-types.md#telemetry-data), and [trips](/data-types.md#trips) can be found in the [Data Types](/data-types.md) page.
48
+
49
+
[Top][toc]
50
+
56
51
## Definitions
57
52
58
53
Defining terminology and abbreviations used throughout MDS.
@@ -77,62 +72,6 @@ Additionally, `device_id` must remain constant for the device's lifetime of serv
77
72
78
73
References to geographic datatypes (Point, MultiPolygon, etc.) imply coordinates encoded in the [WGS 84 (EPSG:4326)][wgs84] standard GPS or GNSS projection expressed as [Decimal Degrees][decimal-degrees]. When points are used, you may assume a 20 meter buffer around the point when needed.
79
74
80
-
### Geographic Telemetry Data
81
-
82
-
Whenever a vehicle location coordinate measurement is presented, it must be represented as a GeoJSON [`Feature`][geojson-feature] object with a corresponding `properties` object with the following properties:
83
-
84
-
85
-
| Field | Type | Required/Optional | Field Description |
|`timestamp`|[timestamp][ts]| Required | Date/time that event occurred. Based on GPS or GNSS clock |
88
-
|`altitude`| Double | Required if Available | Altitude above mean sea level in meters |
89
-
|`heading`| Double | Required if Available | Degrees - clockwise starting at 0 degrees at true North |
90
-
|`speed`| Float | Required if Available | Estimated speed in meters / sec as reported by the GPS chipset |
91
-
|`accuracy`| Float | Required if Available | Horizontal accuracy, in meters |
92
-
|`hdop`| Float | Required if Available | Horizontal GPS or GNSS accuracy value (see [hdop][hdop]) |
93
-
|`satellites`| Integer | Required if Available | Number of GPS or GNSS satellites |
94
-
95
-
Example of a vehicle location GeoJSON [`Feature`][geojson-feature] object:
96
-
97
-
```json
98
-
{
99
-
"type": "Feature",
100
-
"properties": {
101
-
"timestamp": 1529968782421,
102
-
"accuracy": 10,
103
-
"speed": 1.21
104
-
},
105
-
"geometry": {
106
-
"type": "Point",
107
-
"coordinates": [
108
-
-118.46710503101347,
109
-
33.9909333514159
110
-
]
111
-
}
112
-
}
113
-
```
114
-
115
-
### Stop-based Geographic Data
116
-
117
-
When an individual location coordinate measurement (Point) corresponds to a [Stop][general-stops], it must be presented with a `stop_id` property:
118
-
119
-
```json
120
-
{
121
-
"type": "Feature",
122
-
"properties": {
123
-
"timestamp": 1529968782421,
124
-
"stop_id": "b813cde2-a41c-4ae3-b409-72ff221e003d"
125
-
},
126
-
"geometry": {
127
-
"type": "Point",
128
-
"coordinates": [
129
-
-118.46710503101347,
130
-
33.9909333514159
131
-
]
132
-
}
133
-
}
134
-
```
135
-
136
75
### Intersection Operation
137
76
138
77
For the purposes of this specification, the intersection of two geographic datatypes is defined according to the [`ST_Intersects` PostGIS operation][st-intersects]
@@ -147,7 +86,7 @@ For the purposes of this specification, the intersection of two geographic datat
147
86
148
87
**[Beta feature](/general-information.md#beta-features):***Yes (as of 1.1.0)*. [Leave feedback](https://github.com/openmobilityfoundation/mobility-data-specification/issues/670)
149
88
150
-
Geography-Driven Events (GDE) is a new MDS feature for Agencies to perform complete Policy compliance monitoring without precise location data. Geography-Driven Events describe individual vehicles in realtime – not just aggregate data. However, rather than receiving the exact location of a vehicle, Agencies receive information about the vehicle's current geographic region. The regions used for Geography-Driven Events correspond to the Geographies in an Agency's current Policy. In this way, the data-shared using Geography-Driven Events is matched to an Agency's particular regulatory needs.
89
+
Geography-Driven Events (GDE) is an MDS feature for Agencies to perform complete Policy compliance monitoring without precise location data. Geography-Driven Events describe individual vehicles in realtime – not just aggregate data. However, rather than receiving the exact location of a vehicle, Agencies receive information about the vehicle's current geographic region. The regions used for Geography-Driven Events correspond to the Geographies in an Agency's current Policy. In this way, the data-shared using Geography-Driven Events is matched to an Agency's particular regulatory needs.
151
90
152
91
See [this example](/policy/examples/requirements.md#geography-driven-events) for how to implement GDE using [Policy Requirements](/policy#requirement).
153
92
@@ -173,7 +112,7 @@ During the Beta period for this feature, location and telemetry data remain requ
173
112
174
113
## Optional Authentication
175
114
176
-
Authorization of the Policy and Geography APIs is no longer required and will be deprecated in next major release with these endpoints (plus Jursidictions) becoming 'optionally private' instead of 'optionally public'. An agency may optionally decide to make the Policy and Geography endpoints, as well as Jursidictions, unauthenticated and public. This allows transparency for the public to see how the city is regulating, holds the city accountable for their policy decisions, and reduces the technical burden on providers to use these endpoints. A side benefit is that this allows third parties to ingest this information into their applications and services for public benefit.
115
+
Authorization of the Policy and Geography APIs is no longer required and will be deprecated in next major release with these endpoints (plus Jurisdictions) becoming 'optionally private' instead of 'optionally public'. An agency may optionally decide to make the Policy and Geography endpoints, as well as Jurisdictions, unauthenticated and public. This allows transparency for the public to see how the city is regulating, holds the city accountable for their policy decisions, and reduces the technical burden on providers to use these endpoints. A side benefit is that this allows third parties to ingest this information into their applications and services for public benefit.
177
116
178
117
Note if implementing the beta feature [Geography Driven Events](/general-information.md#geography-driven-events), both Policy and Geography must be public.
179
118
@@ -182,7 +121,7 @@ Note if implementing the beta feature [Geography Driven Events](/general-informa
182
121
## Responses
183
122
184
123
***200:** OK: operation successful.
185
-
***201:** Created: `POST` operations, new object created
124
+
***201:** Created: `POST` operations, new object(s) created
186
125
***400:** Bad request.
187
126
***401:** Unauthorized: Invalid, expired, or insufficient scope of token.
188
127
***404:** Not Found: Object does not exist, returned on `GET` or `POST` operations if the object does not exist.
@@ -205,63 +144,46 @@ Note if implementing the beta feature [Geography Driven Events](/general-informa
205
144
|`error_description`| String | Human readable error description (can be localized) |
206
145
|`error_details`| String[]| Array of error details |
207
146
208
-
[Top][toc]
209
-
210
-
## Strings
211
-
212
-
All String fields, such as `vehicle_id`, are limited to a maximum of 255 characters.
213
-
214
-
[Top][toc]
147
+
### Bulk Responses
215
148
216
-
## Stops
217
-
218
-
Stops describe vehicle trip start and end locations in a pre-designated physical place. They can vary from docking stations with or without charging, corrals with lock-to railings, or suggested parking areas marked with spray paint. Stops are used in both [Provider](/provider#stops) (including routes and event locations) and [Agency](/agency#stops) (including telemetry data).
219
-
220
-
| Field | Type | Required/Optional | Description |
| stop_id | UUID | Required | Unique ID for stop |
223
-
| name | String | Required | Name of stop |
224
-
| last_reported | Timestamp | Required | Date/Time that the stop was last updated |
225
-
| location | GeoJSON [Point Feature](#stop-based-geographic-data)| Required | Simple centerpoint location of the Stop. The use of the optional `geography_id` is recommended to provide more detail. |
226
-
| status |[Stop Status](#stop-status)| Required | Object representing the status of the Stop. See [Stop Status](#stop-status). |
227
-
| capacity | {vehicle_type: number} | Required | Number of total places per vehicle_type |
228
-
| num_vehicles_available | {vehicle_type: number} | Required | How many vehicles are available per vehicle_type at this stop? |
229
-
| num_vehicles_disabled | {vehicle_type: number} | Required | How many vehicles are unavailable/reserved per vehicle_type at this stop? |
230
-
| provider_id | UUID | Optional | UUID for the provider managing this stop. Null/undefined if managed by an agency. See MDS [provider list](/providers.csv). |
231
-
| data_provider_id | UUID | Optional | UUID for the data provider managing the data coming from this stop. Null/undefined if managed by an agency or a provider. See MDS [provider list](/providers.csv). |
232
-
| geography_id | UUID | Optional | Pointer to the [Geography](/geography) that represents the Stop geospatially via Polygon or MultiPolygon. |
233
-
| region_id | string | Optional | ID of the region where station is located, see [GBFS Station Information][gbfs-station-info]|
|`electric_assist`| Provides power only alongside human propulsion |
346
-
|`electric`| Contains throttle mode with a battery-powered motor |
347
-
|`combustion`| Contains throttle mode with a gas engine-powered motor |
348
-
349
-
A vehicle may have one or more values from the `propulsion`, depending on the number of modes of operation. For example, a scooter that can be powered by foot or by electric motor would have the `propulsion` represented by the array `['human', 'electric']`. A bicycle with pedal-assist would have the `propulsion` represented by the array `['human', 'electric_assist']` if it can also be operated as a traditional bicycle.
350
-
351
-
[Top][toc]
352
-
353
-
### Vehicle Types
354
-
355
-
The list of allowed `vehicle_type` values in MDS. Aligning with [GBFS vehicle types form factors](https://github.com/NABSA/gbfs/blob/master/gbfs.md#vehicle_typesjson-added-in-v21-rc).
356
-
357
-
|`vehicle_type`| Description |
358
-
|----------------| ----------- |
359
-
| bicycle | A two-wheeled mobility device intended for personal transportation that can be operated via pedals, with or without a motorized assist (includes e-bikes, recumbents, and tandems) |
360
-
| cargo_bicycle | A two- or three-wheeled bicycle intended for transporting larger, heavier cargo than a standard bicycle (such as goods or passengers), with or without motorized assist (includes bakfiets/front-loaders, cargo trikes, and long-tails) |
361
-
| car | A passenger car or similar light-duty vehicle |
362
-
| scooter | A standing or seated fully-motorized mobility device intended for one rider, capable of travel at low or moderate speeds, and suited for operation in infrastructure shared with motorized bicycles |
363
-
| moped | A seated fully-motorized mobility device capable of travel at moderate or high speeds and suited for operation in general urban traffic |
364
-
| delivery_robot | A robot intended for transporting goods |
365
-
| other | A device that does not fit in the other categories |
366
-
367
-
[Top][toc]
368
-
369
250
## Versioning
370
251
371
252
MDS APIs must handle requests for specific versions of the specification from clients.
@@ -402,7 +283,11 @@ If an unsupported or invalid version is requested, the API must respond with a s
Copy file name to clipboardExpand all lines: modes/README.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,12 @@ The `trip_attributes` array allows additional mode-specific information about th
60
60
61
61
_See more available trip attributes for any mode in the [trips endpoint](/provider#trips)._
62
62
63
+
### Fare Attributes
64
+
65
+
The `fare_attributes` array allows additional mode-specific information about fare information associated with the trip. It can return a list of JSON-formatted key/value pairs which correspond to the allowed attributes and values for the operative mode. See each [mode definition](#list-of-supported-modes) for details.
66
+
67
+
_See more available fare attributes for any mode in the [trips endpoint](/provider#trips)._
68
+
63
69
### Vehicle Attributes
64
70
65
71
The `vehicle_attributes` array returns a list of JSON-formatted key/value pairs which correspond to the allowed attributes and values for the operative mode. For each mode, the allowed attributes and corresponding values are defined in the [mode definition](#list-of-supported-modes).
Copy file name to clipboardExpand all lines: policy/examples/requirements.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -193,7 +193,7 @@ Version 1.1.0 for one provider with scooters, and 1.0.0 for another provider for
193
193
194
194
## Trips Only
195
195
196
-
Version 1.1.0 for 2 providers requiring only historic Provider `/trips` with the optional `parking_verificaiton_url` field, linked to a specific MDS Policy.
196
+
Version 1.1.0 for 2 providers requiring only historic Provider `/trips` with the optional `parking_verification_url` field, linked to a specific MDS Policy.
0 commit comments