-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdrive511.yml
228 lines (227 loc) · 7.12 KB
/
drive511.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
components:
schemas: {}
externalDocs:
description: Additional API Documentation
url: http://api.open511.gov.bc.ca/help
info:
contact:
email: [email protected]
name: Drive BC
url: http://www.drivebc.ca/
description: This API is DriveBC's implementation of the Open511 specification. It
provides information about known road events (traffic accidents, construction,
etc.) in British Columbia, Canada.
license:
name: Open Government License - British Columbia
url: http://www2.gov.bc.ca/gov/content?id=A519A56BC2BF44E4A008B33FCF527F61
termsOfService: http://www2.gov.bc.ca/gov/content?id=D1EE0A405E584363B205CD4353E02C88
title: DriveBC's Open511 API
version: 1.0.0
x-apisguru-categories:
- open_data
x-logo:
url: https://avatars1.githubusercontent.com/u/916280?v=3&s=200
x-origin:
- converter:
url: https://github.com/mermade/oas-kit
version: 7.0.4
format: openapi
url: https://raw.githubusercontent.com/bcgov/api-specs/master/open511/open511_OAS3.json
version: '3.0'
x-providerName: gov.bc.ca
x-serviceName: open511
openapi: 3.0.0
paths:
/areas:
get:
operationId: getAreas
description: Lists the geographical areas (e.g. districts) that can be used to filter events.
parameters:
- description: The format of the response
in: query
name: format
required: false
schema:
default: json
enum:
- json
- xml
type: string
responses:
'200':
description: List of packages
tags:
- resources
/events:
get:
description: 'The events resource provides information about road events (e.g.
accidents, construction, special events) '
operationId: getEvents
parameters:
- description: The number of items to fetch
in: query
name: limit
schema:
type: int
- description: The offset for pagination
in: query
name: offset
schema:
type: int
- description: The format of the response
in: query
name: format
required: false
schema:
default: json
enum:
- json
- xml
type: string
- description: Limits the response to events having a given status.
in: query
name: status
schema:
default: ALL
enum:
- ALL
- ACTIVE
- ARCHIVED
type: string
- description: 'Limits the response to events tagged with one of the listed
severity values. Multiple values may be listed, and should be separated
by a comma. The default is to return events of any severity.'
in: query
name: severity
schema:
default: MAJOR
enum:
- MINOR
- MODERATE
- MAJOR
type: string
- description: Limits the response to events reported by a given jurisdiction.
The value given must be specified as the ID of a jurisdiction returned by
the /jurisdiction resource.
in: query
name: jurisdiction
required: false
schema:
default: drivebc.ca
type: string
- description: 'Limits the response to events tagged with one of the listed
event types Multiple values may be listed, and should be separated
by a comma'
in: query
name: event_type
required: false
schema:
default: INCIDENT
enum:
- CONSTRUCTION
- SPECIAL_EVENT
- INCIDENT
- WEATHER_CONDITION
- ROAD_CONDITION
type: string
- description: "Limits the response to events based on the date and time that
the event was created (first recorded). The date/time must be specified
in ISO 8601 format, and may be prefixed by one of the following operators
[<, <=, >, >=] to indicate 'before', 'before or equal to', 'after' or 'after
or equal to' respectively."
in: query
name: created
required: false
schema:
default: '>2015-09-01T12:00:00Z'
type: string
- description: "Limits the response to events based on the date and time that
the event was last updated. The date/time must be specified in ISO 8601
format, and may be prefixed by one of the following operators [<, <=, >,
>=] to indicate 'before', 'before or equal to', 'after' or 'after or equal
to' respectively."
in: query
name: updated
required: false
schema:
default: '>2015-09-01T12:00:00Z'
type: string
- description: Limits the response to events on a given road as specified by
the road name. An example of a valid road name is 'Highway 1'. The default
is to return events on all roads.
in: query
name: road_name
required: false
schema:
default: Highway 99
type: string
- description: 'Limits the response to events within one of the specified areas. An
area must be specified as the ID of an item returned by the /areas resource.
For example: an area_id of ''drivebc.ca/1'' limits events to those within
the Lower Mainland District.'
in: query
name: area_id
required: false
schema:
default: drivebc.ca/1
type: string
- description: 'Limits the response to events that fall within the specified
geographical bounding box. The bbox format must be ''[min longitude],[min
latitude],[max longitude],[max latitude]'' with WGS84 coordinates. For
example: -123.45,48.99,-122.45,49.49. The default is to return events in
all geographical locations.'
in: query
name: bbox
required: false
schema:
default: -130,48,-116,60
type: string
responses:
'200':
description: List of packages
tags:
- resources
/jurisdiction:
get:
description: Lists the jurisdictions publishing data through this Open511 API implementation
operationId: getJurisdiction
parameters:
- description: The format of the response
in: query
name: format
required: false
schema:
default: json
enum:
- json
- xml
type: string
responses:
'200':
description: List of packages
tags:
- resources
/jurisdictiongeography:
get:
operationId: getJurisdictionGeography
summary: The jurisdiction geography contains the location boundaries of the jurisdiction
parameters:
- description: The format of the response
in: query
name: format
required: false
schema:
default: json
enum:
- json
- xml
type: string
responses:
'200':
description: List of packages
tags:
- resources
servers:
- url: https://api.open511.gov.bc.ca/
tags:
- name: resources