-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapi.yml
More file actions
274 lines (255 loc) · 7.05 KB
/
api.yml
File metadata and controls
274 lines (255 loc) · 7.05 KB
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
openapi: "3.0.4"
servers: []
info:
title: VDI Plugin Server
version: 8.0.0
license:
name: Apache 2.0
url: https://www.apache.org/licenses/LICENSE-2.0.html
security: []
paths:
/import:
post:
operationId: import-dataset
summary: Import Processing
tags:
- Import
description: |
Perform dataset validation and any pre-installation transformation that
needs to be done.
The output of this endpoint is a zip containing the processing result
files that are ready to be imported into the VDI Dataset Store (MinIO at
the time of this writing)
The structure of the returned zip is as follows:
```yaml
result.zip:
- warnings.json # Import warnings
- vdi-manifest.json # File manifest
- data.zip # Install-ready data
```
requestBody:
content:
multipart/form-data:
schema:
type: object
additionalProperties: false
properties:
details:
$ref: '#/components/schemas/ImportRequestDetails'
payload:
type: string
format: binary
required:
- details
- payload
responses:
200:
description: Success
content:
application/octet-stream:
schema:
type: string
format: binary
400:
$ref: "#/components/responses/400"
418:
$ref: '#/components/responses/418'
500:
$ref: '#/components/responses/500'
/install/meta:
post:
operationId: install-meta
summary: Install Metadata
tags:
- Install
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/InstallMetaRequest"
responses:
204:
description: Success
400:
$ref: "#/components/responses/400"
500:
$ref: '#/components/responses/500'
/install/data:
post:
operationId: install-data
summary: Install Data
tags:
- Install
requestBody:
content:
multipart/form-data:
schema:
type: object
additionalProperties: false
properties:
details:
type: object
additionalProperties: false
properties:
vdiID:
$ref: "#/components/schemas/VDI-ID"
projectID:
$ref: "#/components/schemas/ProjectID"
required:
- vdiID
- projectID
meta:
$ref: "#/components/schemas/DatasetMeta"
manifest:
$ref: "#/components/schemas/DatasetManifest"
payload:
type: string
format: binary
required:
- details
- meta
- manifest
- payload
responses:
200:
description: Success
content:
application/json:
schema:
type: object
additionalProperties: false
properties:
warnings:
type: array
items:
type: string
default: []
400:
$ref: "#/components/responses/400"
418:
$ref: '#/components/responses/418'
420:
description: |
Incompatible data
The posted dataset depends on one or more resources that are not
available in the versions specified, if at all.
content:
application/json:
schema:
$ref: "#/components/schemas/ValidationError"
500:
$ref: "#/components/responses/500"
/uninstall:
post:
operationId: uninstall-dataset
summary: Uninstall
tags:
- Uninstall
requestBody:
content:
application/json:
schema:
type: object
additionalProperties: false
properties:
vdiID:
$ref: "#/components/schemas/VDI-ID"
projectID:
$ref: "#/components/schemas/ProjectID"
required:
- vdiID
- projectID
responses:
204:
description: Success
400:
$ref: "#/components/responses/400"
500:
$ref: "#/components/responses/500"
/metrics:
get:
operationId: get-metrics
summary: Prometheus Metrics
tags:
- Management
responses:
200:
description: Success
content:
text/plain:
schema:
type: string
components:
responses:
400:
description: Malformed request.
content:
application/json:
schema:
$ref: '#/components/schemas/SimpleError'
418:
description: Validation error.
content:
application/json:
schema:
$ref: '#/components/schemas/ValidationError'
500:
description: Internal server error.
content:
application/json:
schema:
$ref: '#/components/schemas/SimpleError'
schemas:
DatasetManifest:
$ref: https://raw.githubusercontent.com/VEuPathDB/vdi-component-common/refs/tags/v13.3.2/schemata/json/vdi-dataset-manifest.json
DatasetMeta:
$ref: https://raw.githubusercontent.com/VEuPathDB/vdi-component-common/refs/tags/v13.3.2/schemata/json/vdi-dataset-meta.json
ImportRequestDetails:
type: object
additionalProperties: false
properties:
vdiID:
$ref: '#/components/schemas/VDI-ID'
required: true
meta:
$ref: '#/components/schemas/DatasetMeta'
required: true
required:
- vdiID
- meta
InstallMetaRequest:
type: object
properties:
vdiID:
$ref: '#/components/schemas/VDI-ID'
projectID:
$ref: '#/components/schemas/ProjectID'
meta:
$ref: '#/components/schemas/DatasetMeta'
required:
- vdiID
- projectID
- meta
ProjectID:
$ref: https://raw.githubusercontent.com/VEuPathDB/vdi-component-common/refs/tags/v13.3.2/schemata/json/project-id.json
SimpleError:
type: object
additionalProperties: false
properties:
message:
type: string
required:
- message
ValidationError:
type: object
additionalProperties: false
properties:
warnings:
type: array
items:
type: string
minItems: 1
required:
- warnings
VDI-ID:
$ref: https://raw.githubusercontent.com/VEuPathDB/vdi-component-common/refs/tags/v13.3.2/schemata/json/vdi-dataset-id.json