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
Copy file name to clipboardExpand all lines: policy/README.md
+20-17Lines changed: 20 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -149,7 +149,7 @@ Policies will be returned in order of effective date (see schema below), with pa
149
149
150
150
### Geographies
151
151
152
-
**Deprecated:** see the new [Geography API](/geography#transition-from-policy) to understand the transistion away from this endpoint, and how to support both in MDS 1.x.0 releases.
152
+
**Deprecated:** see the new [Geography API](/geography#transition-from-policy) to understand the transition away from this endpoint, and how to support both in MDS 1.x.0 releases.
153
153
154
154
**Endpoint**: `/geographies/{id}`
155
155
**Method**: `GET`
@@ -168,8 +168,8 @@ Policies will be returned in order of effective date (see schema below), with pa
168
168
169
169
**Endpoint**: `/requirements/`
170
170
**Method**: `GET`
171
-
**[Beta feature](/general-information.md#beta-features)**: *Yes (as of 1.2.0)*.[Leave feedback](https://github.com/openmobilityfoundation/mobility-data-specification/issues/682)
172
-
**Schema:** TBD when out of beta
171
+
**[Beta feature](/general-information.md#beta-features)**: *No (as of 2.0.0)*.
172
+
**Schema:** TBD
173
173
**`data` Payload**: `{ requirements: [] }`, JSON objects that follow the schema [outlined here](#requirement).
174
174
175
175
See [Policy Requirements Examples](/policy/examples/requirements.md) for how this can be implemented.
@@ -337,7 +337,7 @@ An individual `Rule` object is defined by the following fields:
337
337
338
338
### Geography
339
339
340
-
**Deprecated:** see the new [Geography API](/geography#transition-from-policy) to understand the transistion away from this endpoint, and how to support both in a MDS 1.x.0 release.
340
+
**Deprecated:** see the new [Geography API](/geography#transition-from-policy) to understand the transition away from this endpoint, and how to support both in a MDS 1.x.0 release.
341
341
342
342
| Name | Type | Required / Optional | Description |
@@ -434,7 +434,7 @@ The internal mechanics of ordering are up to the Policy editing and hosting soft
434
434
435
435
### Requirement
436
436
437
-
A public agency's Policy program Requirements endpoint enumerates all of the parts of MDS, GBFS, and other specifications that an agency requires from providers for certain programs, including APIs, endpoints, and optional fields, as well as information for providers about the APIs the agency is hosting. The program requirements are specific to the needs and use cases of each agency, and ensure there is clarity on what data is being asked for in operating policy documents from providers, reducing the burden on both. This also allows additional public transparency and accountability around data requirements from agencies, and encourages privacy by allowing agencies to ask for only the data they need.
437
+
A public agency's Policy program Requirements endpoint enumerates all of the parts of MDS, [CDS](https://github.com/openmobilityfoundation/curb-data-specification), GBFS, and other specifications that an agency requires from providers for certain programs, including APIs, endpoints, and optional fields, as well as information for providers about the APIs the agency is hosting. The program requirements are specific to the needs and use cases of each agency, and ensure there is clarity on what data is being asked for in operating policy documents from providers, reducing the burden on both. This also allows additional public transparency and accountability around data requirements from agencies, and encourages privacy by allowing agencies to ask for only the data they need.
438
438
439
439
Requirements can also be used to define a scaled-down MDS implementation in situations where an agency has more limited regulatory goals, has legal limitations on the types of data they can collect, or wants to use a lightweight version of MDS for a pilot project or other experiment where aspects of a full MDS implementation would be irrelevant or unnecessary.
440
440
@@ -454,10 +454,6 @@ If you are upgrading to a new MDS version, it is recommended to create a new req
454
454
455
455
When requirements are updated within the same MDS version, in the [metadata](#requirement-metadata) section, increment the `file_version` value by one and update the `last_updated` timestamp. Though not required, you may choose to use the `start_date` and `end_date` fields in the [programs](#requirement-programs) section to keep retired requirements accessible. We also recommend hosting your requirements file in a location that has a publicly-accessible version history, like GitHub or Bitbucket, or keeping previous versions accessible with a versioned URL, e.g. "https://mds.cityname.gov/requirements/1.2.0/v3".
456
456
457
-
#### Beta Limitations
458
-
459
-
Note that while Requirements is in [beta](#Requirements) in this **minor**, non-breaking MDS 1.2.0 release, items listed as "required" or "disallowed" will be treated as a _request_ only by default (precluding intentional formal agency communications with providers) to prevent an _unintentional_ burden on providers. For the next **major**, breaking MDS 2.0.0 release, these items will be required or disallowed as documented.
460
-
461
457
#### Requirement Format
462
458
463
459
An agency's program [Requirements](#requirements) endpoint contains a number of distinct parts, namely [metadata](#requirement-metadata), [program definitions](#requirement-programs), and [data specs](#requirement-data-specs) (with sub sections on relevant [required APIs](#requirement-apis)).
@@ -493,7 +489,7 @@ An agency's program [Requirements](#requirements) endpoint contains a number of
493
489
// other data specs per the "Requirement Data Specs" section
494
490
]
495
491
},
496
-
// other MDS versions per the "Requriement MDS Version" section
492
+
// other MDS versions per the "Requirement MDS Version" section
497
493
}
498
494
}
499
495
```
@@ -622,7 +618,7 @@ For each combination of items in a program, you can specify the data specs, APIs
622
618
623
619
| Name | Type | Required / Optional | Description |
|`data_spec_name`| Enum | Required | Name of the data spec required. Supported values are: '[MDS](https://github.com/openmobilityfoundation/mobility-data-specification/tree/ms-requirements)', '[GBFS](https://github.com/NABSA/gbfs/tree/v2.2)'. Others like GOFS, GTFS, TOMP-API, etc can be tested by agencies and officially standardized here in the future -- leave your feedback on [this issue](https://github.com/openmobilityfoundation/mobility-data-specification/issues/682). |
621
+
|`data_spec_name`| Enum | Required | Name of the data spec required. Supported values are: '[MDS](https://github.com/openmobilityfoundation/mobility-data-specification/tree/ms-requirements)', '[CDS](https://github.com/openmobilityfoundation/curb-data-specification)' '[GBFS](https://github.com/NABSA/gbfs/tree/v2.2)'. Others like GOFS, GTFS, TOMP-API, etc may also be referenced now by agencies and officially standardized here in the future -- leave your feedback on [this issue](https://github.com/openmobilityfoundation/mobility-data-specification/issues/682). |
626
622
|`version`| Text | Required | Version number of the data spec required. E.g. '1.2.0' |
627
623
|`mode`| Text | Optional | The [mode list][modes] shortname for MDS. E.g. 'passenger-services' |
628
624
|`required_apis`| Array | Conditionally Required | Name of the [Requirement APIs](#requirement-apis) that need to be served by providers. At least one API is required. APIs not listed will not be available to the agency. |
@@ -632,7 +628,7 @@ For each combination of items in a program, you can specify the data specs, APIs
632
628
633
629
#### Requirement APIs
634
630
635
-
For each data specification, you can specify which APIs, endpoints, and fields are required from providers, and which are available from your agency.
631
+
For each data specification, you can specify which APIs, endpoints, and fields are required from providers, and which are available from your agency, and the use cases you need the data for.
636
632
637
633
An agency may require providers to serve optional APIs, endpoints, and fields that are needed for your agency's program. This is a `required_apis` array within the [Requirement Data Specs](#requirement-data-specs) section in the [Requirement](#requirement) data feed.
638
634
@@ -659,8 +655,7 @@ You may also show which APIs, endpoints, and fields your agency is serving to pr
659
655
},
660
656
// other endpoints
661
657
]
662
-
},
663
-
// other APIs in same data spec
658
+
}
664
659
],
665
660
"available_apis": [
666
661
{
@@ -677,6 +672,14 @@ You may also show which APIs, endpoints, and fields your agency is serving to pr
677
672
// other endpoints
678
673
]
679
674
}
675
+
],
676
+
// other APIs in same data spec
677
+
"use_cases": [
678
+
{
679
+
"external_url":"[REFERENCE URL]",
680
+
"ids": ["1","2","3"]
681
+
},
682
+
// next external use case source
680
683
]
681
684
// ...
682
685
```
@@ -685,6 +688,7 @@ You may also show which APIs, endpoints, and fields your agency is serving to pr
|`api_name`| Text | Required | Name of the applicable API required. At least one API is required. APIs not listed will not be available to the agency. E.g. for MDS: 'provider', or 'agency'. For GBFS, this field is omitted since GBFS starts at the `endpoint` level. |
687
690
|`endpoint_name`| Text | Required | Name of the required endpoint under the API. At least one endpoint is required. E.g. for MDS 'provider': 'trips' |
691
+
|`use_cases`| Object with Array | Optional | The list of policy uses cases that this data standard's information covers for your program. Includes an `external_url` to a HTTP reference list or database (e.g. to the [OMF Use Case Database](https://airtable.com/shrPf4QvORkjZmHIs/tblzFfU6fxQm5Sdhm)), **and** an array of `ids` of each applicable use case (e.g. "OMF-MDS-31"). You may enumerate multiple external use case sources and ids. |
688
692
689
693
**Provider Endpoints** - Specific to the `required_apis` array
690
694
@@ -707,9 +711,8 @@ You may also show which APIs, endpoints, and fields your agency is serving to pr
707
711
- All fields marked 'Required' in MDS are still included by default and should not be enumerated in `required_fields`. They are not affected by the Requirements endpoint, unless explicitly listed in `disallowed_fields`.
708
712
- Fields in MDS marked 'Required if available' are still returned if available, and are not affected by the Requirements endpoint, unless explicitly listed in `disallowed_fields`.
709
713
- If a 'Required' or 'Required if available' or 'Optional' field in MDS is listed in `disallowed_fields`, those fields should not be returned by the provider in the endpoint. The field (and therefore its value) must be completely removed from the response. If used, [schema](/schema) validation may fail on missing required fields.
710
-
- To reference fields that are lower in a heirarchy, use [dot separated notation](https://docs.oracle.com/en/database/oracle/oracle-database/18/adjsn/simple-dot-notation-access-to-json-data.html#GUID-7249417B-A337-4854-8040-192D5CEFD576), where a dot between field names represents one nested level deeper into the data structure. E.g. 'gps.heading' or 'features.properties.rules.vehicle_type_id'.
711
-
- To require [Greography Driven Events](/general-information.md#geography-driven-events), simply include the `event_geographies` field for either the Agency or Provider API `api_name`. Per how GDEs work, `event_location` will then not be returned, and the `changed_geographies` vehicle state `event_type` will be used.
712
-
-[While in beta](#beta-limitations), items marked as required or disallowed will only be considered a 'request' by providers, unless agencies have communicated with providers outside of MDS.
714
+
- To reference fields that are lower in a hierarchy, use [dot separated notation](https://docs.oracle.com/en/database/oracle/oracle-database/18/adjsn/simple-dot-notation-access-to-json-data.html#GUID-7249417B-A337-4854-8040-192D5CEFD576), where a dot between field names represents one nested level deeper into the data structure. E.g. 'gps.heading' or 'features.properties.rules.vehicle_type_id'.
715
+
- To require [Geography Driven Events](/general-information.md#geography-driven-events), simply include the `event_geographies` field for either the Agency or Provider API `api_name`. Per how GDEs work, `event_location` will then not be returned, and the `changed_geographies` vehicle state `event_type` will be used.
Copy file name to clipboardExpand all lines: policy/examples/requirements.md
+9-2Lines changed: 9 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -318,7 +318,7 @@ Version 1.1.0 for 2 providers asking for only historic [Provider `/trips`](/prov
318
318
319
319
## Provider and Other APIs
320
320
321
-
Version 1.1.0 or 0.4.1 for 3 providers with many APIs and endpoints.
321
+
Version 1.1.0 or 0.4.1 for 3 providers with many APIs and endpoints, for two programs: shared dockless and city docked bikes. With use cases added.
322
322
323
323
Note: by specifying geography, policy, and jurisdiction here with a URL, the agency is in effect saying that they have created and are hosting these, and they are available for use if public.
324
324
@@ -431,6 +431,14 @@ Note: by specifying geography, policy, and jurisdiction here with a URL, the age
0 commit comments