diff options
author | 2018-03-07 17:19:48 +0100 | |
---|---|---|
committer | 2018-03-07 17:21:45 +0100 | |
commit | b2727af1d234bae3e64cf31a0af3dfee2d1c91f8 (patch) | |
tree | 40556f1679e2b9521c21598a43d0f4a71e6c2915 /ice-server/heat_test/swagger | |
parent | d5d7097ce064a9711cd7415d100db2560ef7ff08 (diff) |
implement rest API for ICE tests
Change-Id: I1ccb630858907161c4e8b13986fe963bb309b608
Issue-ID: VNFSDK-213
Signed-off-by: Mickael JEZEQUEL <mickael.jezequel@orange.com>
Diffstat (limited to 'ice-server/heat_test/swagger')
-rw-r--r-- | ice-server/heat_test/swagger/ice_api.yaml | 85 |
1 files changed, 85 insertions, 0 deletions
diff --git a/ice-server/heat_test/swagger/ice_api.yaml b/ice-server/heat_test/swagger/ice_api.yaml new file mode 100644 index 0000000..c12269f --- /dev/null +++ b/ice-server/heat_test/swagger/ice_api.yaml @@ -0,0 +1,85 @@ +swagger: "2.0" + +info: + title: "ICE validation" + description: "Heat template validation rest API" + contact: + name: ONAP + url: https://www.onap.org + email: onap-discuss@lists.onap.org + license: + name: Apache 2.0 + url: http://www.apache.org/licenses/LICENSE-2.0.html + version: "1.0.0" + +basePath: /onapapi/ice/v1 + +paths: + /: + get: + summary: "list HEAT templates" + operationId: heat_validator.class_instance.ping + responses: + '200': + description: 'server is up and running' + schema: + type: string + post: + summary: "validate HEAT template" + operationId: heat_validator.class_instance.validate + consumes: [ + "multipart/form-data" + ] + produces: [ + "application/json" + ] + parameters: [ + { + "name": "file", + "in": "formData", + "description": "file to upload", + "required": true, + "type": "file" + }, + { + "name": "debug", + "in": "query", + "description": "debug mode", + "required": false, + "type": "boolean" + } + ] + responses: + "200": + description: 'validation success' + schema: { + "$ref": "#/definitions/Result" + } + "400": + description: 'validation error' + schema: { + "$ref": "#/definitions/Result" + } + "500": + description: 'validation error' + schema: { + "$ref": "#/definitions/Result" + } +definitions: + Result: + required: [ + "status", + "message" + ] + properties: { + "status": { + "type": "integer", + "format": "int64" + }, + "message": { + "type": "string" + }, + "debug": { + "type": "string" + } + }
\ No newline at end of file |