Skip to content

Commit 545100a

Browse files
revert mtarest.yaml
1 parent 7689c6f commit 545100a

File tree

1 file changed

+181
-0
lines changed

1 file changed

+181
-0
lines changed

multiapps-controller-api/src/main/resources/mtarest.yaml

Lines changed: 181 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,127 @@ paths:
3737
$ref: "#/definitions/Info"
3838
security:
3939
- oauth2: []
40+
/api/v1/spaces/{spaceGuid}/files:
41+
get:
42+
summary: ""
43+
description: "Retrieves all Multi-Target Application files "
44+
operationId: "getMtaFiles"
45+
produces:
46+
- "application/json"
47+
parameters:
48+
- name: "spaceGuid"
49+
in: "path"
50+
description: "GUID of space with mtas"
51+
required: true
52+
type: "string"
53+
- name: "namespace"
54+
in: "query"
55+
description: "Filter mtas by namespace"
56+
required: false
57+
type: "string"
58+
responses:
59+
200:
60+
description: "OK"
61+
schema:
62+
type: "array"
63+
items:
64+
$ref: "#/definitions/FileMetadata"
65+
security:
66+
- oauth2: []
67+
post:
68+
summary: ""
69+
description: "Uploads a Multi Target Application archive or an Extension Descriptor "
70+
operationId: "uploadMtaFile"
71+
consumes:
72+
- "multipart/form-data"
73+
produces:
74+
- "application/json"
75+
parameters:
76+
- name: "spaceGuid"
77+
in: "path"
78+
description: "GUID of space you wish to deploy in"
79+
required: true
80+
type: "string"
81+
- name: "namespace"
82+
in: "query"
83+
description: "file namespace"
84+
required: false
85+
type: "string"
86+
responses:
87+
200:
88+
description: "successful operation"
89+
schema:
90+
$ref: "#/definitions/FileMetadata"
91+
201:
92+
description: "Created"
93+
schema:
94+
$ref: "#/definitions/FileMetadata"
95+
security:
96+
- oauth2: []
97+
/api/v1/spaces/{spaceGuid}/files/async:
98+
post:
99+
summary: ""
100+
description: "Uploads a Multi Target Application archive or an Extension Descriptor\
101+
\ from a remote endpoint"
102+
operationId: "startUploadFromUrl"
103+
consumes:
104+
- "application/json"
105+
parameters:
106+
- name: "spaceGuid"
107+
in: "path"
108+
description: "GUID of space you wish to deploy in"
109+
required: true
110+
type: "string"
111+
- name: "namespace"
112+
in: "query"
113+
description: "file namespace"
114+
required: false
115+
type: "string"
116+
- in: "body"
117+
name: "body"
118+
description: "URL reference to a remote file"
119+
required: false
120+
schema:
121+
$ref: "#/definitions/FileUrl"
122+
responses:
123+
202:
124+
description: "Accepted"
125+
security:
126+
- oauth2: []
127+
/api/v1/spaces/{spaceGuid}/files/jobs/{jobId}:
128+
get:
129+
summary: ""
130+
description: "Gets the status of an async upload job"
131+
operationId: "getAsyncUploadJob"
132+
produces:
133+
- "application/json"
134+
parameters:
135+
- name: "spaceGuid"
136+
in: "path"
137+
description: "GUID of space you wish to deploy in"
138+
required: true
139+
type: "string"
140+
- name: "namespace"
141+
in: "query"
142+
description: "file namespace"
143+
required: false
144+
type: "string"
145+
- name: "jobId"
146+
in: "path"
147+
description: "ID of the upload job"
148+
required: true
149+
type: "string"
150+
responses:
151+
200:
152+
description: "OK"
153+
schema:
154+
$ref: "#/definitions/AsyncUploadResult"
155+
201:
156+
description: "Created"
157+
schema:
158+
$ref: "#/definitions/AsyncUploadResult"
159+
security:
160+
- oauth2: []
40161
/api/v1/spaces/{spaceGuid}/mtas:
41162
get:
42163
summary: ""
@@ -282,6 +403,66 @@ securityDefinitions:
282403
flow: "password"
283404
scopes: {}
284405
definitions:
406+
AsyncUploadResult:
407+
type: "object"
408+
properties:
409+
status:
410+
type: "string"
411+
readOnly: true
412+
enum:
413+
- "RUNNING"
414+
- "FINISHED"
415+
- "ERROR"
416+
bytes_processed:
417+
type: "integer"
418+
format: "int64"
419+
readOnly: true
420+
error:
421+
type: "string"
422+
readOnly: true
423+
file:
424+
readOnly: true
425+
$ref: "#/definitions/FileMetadata"
426+
mta_id:
427+
type: "string"
428+
readOnly: true
429+
client_actions:
430+
type: "array"
431+
readOnly: true
432+
items:
433+
type: "string"
434+
enum:
435+
- "RETRY_UPLOAD"
436+
FileMetadata:
437+
type: "object"
438+
properties:
439+
id:
440+
type: "string"
441+
readOnly: true
442+
name:
443+
type: "string"
444+
readOnly: true
445+
size:
446+
type: "integer"
447+
readOnly: true
448+
digest:
449+
type: "string"
450+
readOnly: true
451+
digestAlgorithm:
452+
type: "string"
453+
readOnly: true
454+
space:
455+
type: "string"
456+
readOnly: true
457+
namespace:
458+
type: "string"
459+
readOnly: true
460+
FileUrl:
461+
type: "object"
462+
properties:
463+
file_url:
464+
type: "string"
465+
readOnly: true
285466
Info:
286467
type: "object"
287468
properties:

0 commit comments

Comments
 (0)