Skip to content

Commit 5bb925a

Browse files
committed
Jurisdiction Auth
1 parent 303f892 commit 5bb925a

1 file changed

Lines changed: 32 additions & 19 deletions

File tree

jurisdiction/README.md

Lines changed: 32 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ This specification details the purpose, use cases, and schema for Jurisdictions.
88

99
- [Background](#background)
1010
- [Beta Feature](#beta-feature)
11+
- [Authorization](#authorization)
1112
- [Use Cases](#use-cases)
1213
- [Distribution](#distribution)
13-
- [REST](#rest)
1414
- [Schema](#schema)
1515
- [REST Endpoints](#rest-endpoints)
1616
- [Flat Files](#flat-files)
@@ -33,12 +33,22 @@ A jurisdiction is:
3333
- Purview to make rules over physical boundaries and modal boundaries (e.g. a jurisdiction could be for taxis only)
3434
- A way of tracking revisions in an agency's authority
3535

36+
[Top][toc]
37+
3638
## Beta Feature
3739

3840
The Jurisdictions API and all of its endpoints are marked as a [beta feature](https://github.com/openmobilityfoundation/mobility-data-specification/blob/feature-metrics/general-information.md#beta-features) starting in the 1.1.0 release. It has not been tested in real world scenarios, and may be adjusted in future releases.
3941

4042
**[Beta feature](https://github.com/openmobilityfoundation/mobility-data-specification/blob/feature-metrics/general-information.md#beta-features)**: _Yes (as of 1.1.0)_. [Leave feedback](https://github.com/openmobilityfoundation/mobility-data-specification/issues/673)
4143

44+
[Top][toc]
45+
46+
### Authorization
47+
48+
This endpoint should be made public. Authorization is not required.
49+
50+
[Top][toc]
51+
4252
## Use Cases
4353

4454
### 1. Defining boundaries and what the vehicle state `elsewhere` means
@@ -64,25 +74,13 @@ Example: A SaaS company contracts with Miami-Dade County to provide MDS. There a
6474
Example: The City of Miami has different data visualization tools from the city of Coral Gables
6575
Those tools can be granted data access from the SaaS tool based on the jurisdiction's stable identifier.
6676

67-
[Top](#table-of-contents)
77+
[Top][toc]
6878

6979
## Distribution
7080

71-
Jurisdictions can be served by agencies through the following REST API, or via [flat-files](#flat-files). Agencies should make the endpoints public and non-authenticated.
72-
73-
### REST
74-
75-
All response fields must use `lower_case_with_underscores`.
76-
77-
Responses must set the `Content-Type` header, as specified in the [Provider versioning](../provider/README.md#versioning) section. They must also specify the current API version being served in the JSON-formatted response body, under the `version` key.
78-
79-
Response bodies must be a `UTF-8` encoded JSON object.
80-
81-
#### HTTP Response Codes
81+
Jurisdictions can be served by agencies through the following REST API, or via [flat-files](#flat-files). See [Authorization](#authorization).
8282

83-
The response to a client request must include a valid HTTP status code defined in the [IANA HTTP Status Code Registry](https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml)
84-
85-
[Top](#table-of-contents)
83+
[Top][toc]
8684

8785
## Schema
8886

@@ -116,9 +114,23 @@ Formatted in JSON, a Jurisdiction object should look like this:
116114
"timestamp": Timestamp
117115
}
118116
```
117+
[Top][toc]
119118

120119
## REST Endpoints
121120

121+
### Format
122+
123+
All response fields must use `lower_case_with_underscores`.
124+
125+
Responses must set the `Content-Type` header, as specified in the [Provider versioning](../provider/README.md#versioning) section. They must also specify the current API version being served in the JSON-formatted response body, under the `version` key.
126+
127+
Response bodies must be a `UTF-8` encoded JSON object.
128+
129+
### HTTP Response Codes
130+
131+
The response to a client request must include a valid HTTP status code defined in the [IANA HTTP Status Code Registry](https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml)
132+
133+
122134
### GET /Jurisdictions
123135

124136
Gets all of an agency's Jurisdictions. Served by agencies.
@@ -150,7 +162,7 @@ Response codes:
150162
- 404 - not found
151163
- 500 - Server error
152164

153-
[Top](#table-of-contents)
165+
[Top][toc]
154166

155167
## Flat Files
156168

@@ -165,14 +177,15 @@ The publishing Agency should establish and communicate to interested parties how
165177

166178
The `updated` field in the payload wrapper should be set to the time of publishing a revision, so that it is simple to identify a changed file.
167179

168-
[Top](#table-of-contents)
180+
[Top][toc]
169181

170182
## Examples
171183

172184
See the [Jurisdiction Examples](examples/README.md) for a sample `jurisdictions.json` file.
173185

174186
See the [Geography Examples](/geography/examples/README.md) for an example `geographies.json`.
175187

176-
[Top](#table-of-contents)
188+
[Top][toc]
177189

178190
[modes]: /modes#list-of-supported-modes
191+
[toc]: #table-of-contents

0 commit comments

Comments
 (0)