-
Notifications
You must be signed in to change notification settings - Fork 0
/
apidoc.yml
289 lines (280 loc) · 7.74 KB
/
apidoc.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
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
openapi: 3.0.3
info:
title: Water API - OpenAPI 3.0
description: |-
New Access to Water API, Under Development, Stability Not Yet Guaranteed.
Some useful links:
- [Water API Repository](https://github.com/USACE/water-api)
- [The source API definition](https://github.com/USACE/water-api/blob/master/src/main/apidoc.yaml)
# termsOfService: None yet
# contact:
# email: [email protected]
# license:
# name: MIT
# url:
version: 0.2.0
externalDocs:
description: Developer-Focused Documentation
url: https://water-docs.corps.cloud
servers:
- url: https://water-api.corps.cloud
description: Stable API
- url: https://develop-water-api.corps.cloud
description: Development API
- url: http://localhost
description: Local Testing
tags:
- name: provider
description: Data Provider
- name: datasource
description: Datasource is a unique combination of a Provider and Datatype
- name: location
description: A geospatial location
- name: timeseries
description: A collection of zero or more (timestamp,value) pairs that share common metadata
- name: timeseries_group
description: A named collection of zero or more timeseries
- name: chart
description: A configured chart, optionally linked to a location
paths:
/providers:
get:
tags:
- provider
summary: List Providers
description: Lists Data Providers
responses:
'200':
description: Successful operation
content:
application/json:
schema:
$ref: '#/components/schemas/TODO'
/datasources:
get:
tags:
- datasource
summary: List Datasources
description: Lists Datasources
/locations:
get:
tags:
- location
summary: List Locations
description: Lists Locations
/locations/{location}:
get:
tags:
- location
summary: Get Location
description: Gets One Location
/providers/{provider}/locations:
post:
tags:
- location
summary: Create Location(s)
description: Creates one or more locations
# operationId:
parameters:
- name: provider
in: path
description: Unique Provider Slug
required: true
schema:
type: string
responses:
'200':
description: successful operation
content:
application/json:
schema:
$ref: '#/components/schemas/TODO'
application/xml:
schema:
$ref: '#/components/schemas/TODO'
'400':
description: Invalid ID supplied
'404':
description: Pet not found
put:
tags:
- location
summary: Update Location(s)
description: Updates one or more locations
operationId: updatePetWithForm
parameters:
- name: provider
in: path
description: Unique Provider Slug
required: true
schema:
type: string
responses:
'405':
description: Invalid input
delete:
tags:
- location
summary: Delete Loaction(s)
description: Deletes one or more locations
/providers/{provider}/locations/{location}:
delete:
tags:
- location
summary: Delete Location
description: Deletes a single location using the location's unique slug
/timeseries:
get:
tags:
- timeseries
summary: List Timeseries
description: Lists Timeseries
/providers/{provider}/timeseries:
post:
tags:
- timeseries
summary: Create Timeseries
description: Creates One or More Timeseries
put:
tags:
- timeseries
summary: Update Timeseries
description: Updates One or More Timeseries
delete:
tags:
- timeseries
summary: Delete Timeseries
description: Deletes One or More Timeseries and Associated Values
/providers/{provider}/timeseries/values:
post:
tags:
- timeseries
summary: Create/Update Timeseries Values
description: Creates/Updates Values for One or More Exiting Timeseries
/providers/{provider}/timeseries_groups:
get:
tags:
- timeseries_group
summary: List Timeseries Groups
description: Lists Timeseries Groups
post:
tags:
- timeseries_group
summary: Create Timeseries Groups
description: Creates One or More New Timeseries Groups
put:
tags:
- timeseries_group
summary: Update Timeseries Groups
description: Updates Metadata for One or More Timeseries Groups
delete:
tags:
- timeseries_group
summary: Delete Timeseries Groups
description: Deletes One or More Timeseries Groups (and Associated Group Memberships)
/providers/{provider}/timeseries_groups/{timeseries_group}:
get:
tags:
- timeseries_group
summary: Get Timeseries Group Detail
description: Gets Timeseries Group Details for a Single Timeseries Group
/providers/{provider}/timeseries_groups/{timeseries_group}/members:
post:
tags:
- timeseries_group
summary: Add Timeseries Group Members
description: Adds One or More Timeseries to a Timeseries Group
delete:
tags:
- timeseries_group
summary: Remove Timeseries Group Members
description: Removes One or More Timeseries from a Timeseries Group
/providers/{provider}/timeseries_groups/{timeseries_group}/values:
get:
tags:
- timeseries_group
summary: Stream Timeseries Group Values
description: Streams Timeseries Values for all timeseries in a timeseries group
/chart_types:
get:
tags:
- chart
summary: List Chart Types
description: Lists supported chart types
/charts:
get:
tags:
- chart
summary: List Charts
description: Lists charts
/charts/{chart}:
get:
tags:
- chart
summary: Get Chart Detail / Render
description: Gets chart detail or renders chart
/providers/{provider}/charts:
get:
tags:
- chart
summary: List Charts
description: Lists charts
post:
tags:
- chart
summary: Create Chart(s)
description: Creates one or more charts
/providers/{provider}/charts/{chart}:
delete:
tags:
- chart
summary: Delete Chart
description: Deletes a chart
/providers/{provider}/charts/{chart}/mapping:
post:
tags:
- chart
summary: Create Timeseries-Variable Mapping
description: Creates one or more timeseries-variable mappings for a chart
delete:
tags:
- chart
summary: Delete Timeseries-Variable mapping
description: Deletes one or more timeseries-variable mappings from a chart
components:
schemas:
TODO:
type: object
properties:
TODO:
type: integer
format: int64
example: 1
Datasource:
type: object
properties:
provider:
type: string
example: lrb
provider_name:
type: string
example: Buffalo District
datatype:
type: string
example: cwms-location
datatype_name:
type: string
example: CWMS Location
datatype_uri:
type: string
example: https://cwms-data.usace.army.mil/cwms-data/location
# requestBodies:
# Pet:
# description: Pet object that needs to be added to the store
# content:
# application/json:
# schema:
# $ref: '#/components/schemas/Pet'
# application/xml:
# schema:
# $ref: '#/components/schemas/Pet'