From a32c2b20207885d895bd96204cc166fca14db97b Mon Sep 17 00:00:00 2001 From: dyh Date: Wed, 4 Sep 2019 09:52:48 +0800 Subject: update for change to etsicatalog Change-Id: Idc2a6950960a324964500a8c4701be422de2b782 Issue-ID: MODELING-216 Signed-off-by: dyh --- catalog/swagger/vfc.catalog.swagger.json | 793 +++++++++++++++++++++++++++++++ 1 file changed, 793 insertions(+) create mode 100644 catalog/swagger/vfc.catalog.swagger.json (limited to 'catalog/swagger/vfc.catalog.swagger.json') diff --git a/catalog/swagger/vfc.catalog.swagger.json b/catalog/swagger/vfc.catalog.swagger.json new file mode 100644 index 0000000..1327462 --- /dev/null +++ b/catalog/swagger/vfc.catalog.swagger.json @@ -0,0 +1,793 @@ +{ + "swagger": "2.0", + "info": { + "version": "1.0.0", + "title": "ONAP VFC Catalog Rest API", + "description": "VFC Catalog Management API.", + "contact": { + "name": "ONAP VFC team", + "email": "onap-discuss@lists.onap.org", + "url": "https://gerrit.onap.org/r/#/admin/projects/vfc/nfvo/catalog" + } + }, + "basePath": "/api/catalog/v1", + "schemes": [ + "http", + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/nspackages": { + "get": { + "tags": [ + "nspackage" + ], + "summary": "query ns packages info", + "description": "query ns packages info", + "operationId": "query_ns_packages", + "parameters": [], + "responses": { + "200": { + "description": "successful operation", + "schema": { + "$ref": "#/definitions/NsPkgListInfo" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + }, + "post": { + "tags": [ + "nspackage" + ], + "summary": "ns package distribute", + "description": "ns package distribute", + "operationId": "ns_pkg_distribute", + "parameters": [ + { + "in": "body", + "name": "body", + "description": "distribute request param", + "required": true, + "schema": { + "$ref": "#/definitions/NsPkgDistributeRequest" + } + } + ], + "responses": { + "202": { + "description": "", + "schema": { + "$ref": "#/definitions/NsPkgDistributeResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/nspackages/{csarId}": { + "get": { + "tags": [ + "nspackage" + ], + "summary": "query ns package info", + "description": "query ns package info via ns package csarId", + "operationId": "query_ns_package", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "csarId", + "in": "path", + "description": "csar id of ns package", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "successful operation", + "schema": { + "$ref": "#/definitions/NsPkgDetailInfo" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + }, + "delete": { + "tags": [ + "nspackage" + ], + "summary": "delete ns pkg", + "description": "delete ns pkg", + "operationId": "delete_ns_pkg", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "csarId", + "in": "path", + "description": "csar id of ns package", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "Delete NS Package Response", + "schema": { + "$ref": "#/definitions/NsPkgDelResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/parsernsd": { + "post": { + "tags": [ + "model" + ], + "summary": "ns package model", + "description": "ns package model", + "operationId": "ms_model_parser", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "body", + "description": "distribute request param", + "required": true, + "schema": { + "$ref": "#/definitions/modelParserRequest" + } + } + ], + "responses": { + "202": { + "description": "", + "schema": { + "$ref": "#/definitions/modelParserResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/vnfpackages": { + "get": { + "tags": [ + "vnfpackage" + ], + "summary": "query vnf packages info", + "description": "query vnf packages info", + "operationId": "query_vnf_packages", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [], + "responses": { + "200": { + "description": "successful operation", + "schema": { + "$ref": "#/definitions/VnfPkgListInfo" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + }, + "post": { + "tags": [ + "vnfpackage" + ], + "summary": "vnf package distribute", + "description": "vnf package distribute", + "operationId": "vnf_pkg_distribute", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "body", + "description": "distribute request param", + "required": true, + "schema": { + "$ref": "#/definitions/VnfPkgDistributeRequest" + } + } + ], + "responses": { + "202": { + "description": "", + "schema": { + "$ref": "#/definitions/VnfPkgDistributeResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/vnfpackages/{csarId}": { + "get": { + "tags": [ + "vnfpackage" + ], + "summary": "query vnf package info", + "description": "query one vnf package info via vnf package csarId", + "operationId": "query_vnf_package", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "csarId", + "in": "path", + "description": "csar id of vnf package", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "successful operation", + "schema": { + "$ref": "#/definitions/VnfPkgDetailInfo" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + }, + "delete": { + "tags": [ + "vnfpackage" + ], + "summary": "delete vnf package", + "description": "delete vnf package", + "operationId": "delete_vnf_package", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "csarId", + "in": "path", + "description": "csar id of vnf package", + "required": true, + "type": "string" + } + ], + "responses": { + "202": { + "description": "Delete VNF Pakcage Response", + "schema": { + "$ref": "#/definitions/VnfPkgDelResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/parservnfd": { + "post": { + "tags": [ + "model" + ], + "summary": "vnf package model", + "description": "vnf package model", + "operationId": "vnf_model_parser", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "body", + "description": "distribute request param", + "required": true, + "schema": { + "$ref": "#/definitions/modelParserRequest" + } + } + ], + "responses": { + "202": { + "description": "", + "schema": { + "$ref": "#/definitions/modelParserResponse" + } + }, + "404": { + "description": "URL not found" + }, + "500": { + "description": "internal error" + } + } + } + }, + "/jobs/{jobId}": { + "get": { + "tags": [ + "job" + ], + "summary": "jobstatus", + "description": "Get Job Status", + "operationId": "get_jobstatus", + "parameters": [ + { + "required": true, + "type": "string", + "description": "job Id", + "name": "jobId", + "in": "path" + }, + { + "required": true, + "type": "string", + "description": "job response message id", + "name": "responseId", + "in": "query" + } + ], + "responses": { + "200": { + "description": "", + "schema": { + "$ref": "#/definitions/JobDetailInfo" + } + } + } + }, + "post": { + "tags": [ + "job" + ], + "summary": "Update Job Status", + "description": "Update Job Status", + "operationId": "post_jobstatus", + "parameters": [ + { + "required": true, + "type": "string", + "description": "job Id", + "name": "jobId", + "in": "path" + }, + { + "required": true, + "schema": { + "$ref": "#/definitions/PostJobRequest" + }, + "description": "job status", + "name": "responseId", + "in": "body" + } + ], + "responses": { + "200": { + "description": "", + "schema": { + "$ref": "#/definitions/JobDetailInfo" + } + } + } + } + } + }, + "definitions": { + "NsPkgDistributeRequest": { + "type": "object", + "properties": { + "csarId": { + "type": "string", + "description": "network service package id, UUID" + } + } + }, + "NsPkgDistributeResponse": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "Operation status. value is success or failed" + }, + "statusDescription": { + "type": "string", + "description": "description about the operation result" + }, + "errorCode": { + "type": "string", + "description": "If the status is failed, the errorcode will be returned" + } + } + }, + "NsPkgDelResponse": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "Operation status. value is success or failed" + }, + "statusDescription": { + "type": "string", + "description": "description about the operation result" + }, + "errorCode": { + "type": "string", + "description": "If the status is failed, the errorcode will be returned" + } + } + }, + "NsPkgListInfo": { + "type": "array", + "items": { + "$ref": "#/definitions/NsPkgDetailInfo" + } + }, + "NsPkgDetailInfo": { + "type": "object", + "properties": { + "csarId": { + "type": "string" + }, + "packageInfo": { + "$ref": "#/definitions/NsPkgInfo" + } + } + }, + "NsPkgInfo": { + "type": "object", + "properties": { + "nsPackageId": { + "type": "string", + "description": "network service package id, UUID, csarId" + }, + "nsdId": { + "type": "string", + "description": "network service descriptor ID" + }, + "nsdProvider": { + "type": "string", + "description": "network service designer name" + }, + "nsdVersion": { + "type": "string", + "description": "network service descriptor version" + }, + "csarName": { + "type": "string", + "description": "network service package name" + }, + "nsdModel": { + "type": "string", + "description": "ns JSON string parsed and transformed by parser" + }, + "downloadUrl": { + "type": "string", + "description": "download url of network service package" + } + } + }, + "NsInstListInfo": { + "type": "array", + "items": { + "$ref": "#/definitions/NsInstInfo" + } + }, + "NsInstInfo": { + "type": "object", + "properties": { + "nsInstanceId": { + "type": "string", + "description": "network service instance ID" + }, + "nsInstanceName": { + "type": "string", + "description": "network service instance name" + } + } + }, + "VnfPkgDistributeRequest": { + "type": "object", + "properties": { + "csarId": { + "type": "string", + "description": "vnf package id, UUID" + } + } + }, + "VnfPkgDistributeResponse": { + "type": "object", + "properties": { + "jobId": { + "type": "string", + "description": "VNF package distribute job ID" + } + } + }, + "VnfPkgDelResponse": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "Operation status. value is success or failed" + }, + "statusDescription": { + "type": "string", + "description": "description about the operation result" + }, + "errorCode": { + "type": "string", + "description": "If the status is failed, the errorcode will be returned" + } + } + }, + "VnfPkgListInfo": { + "type": "array", + "items": { + "$ref": "#/definitions/VnfPkgDetailInfo" + } + }, + "VnfPkgDetailInfo": { + "type": "object", + "properties": { + "csarId": { + "type": "string", + "description": "vnf package id, UUID" + }, + "packageInfo": { + "$ref": "#/definitions/VnfPkgInfo" + }, + "imageInfo": { + "$ref": "#/definitions/VnfPkgImgListInfo" + } + } + }, + "VnfPkgInfo": { + "type": "object", + "description": "vnf package infomation", + "properties": { + "vnfPackageId": { + "type": "string", + "description": "vnf package id (csarId)" + }, + "csarName": { + "type": "string", + "description": "The name of the csar" + }, + "vnfdId": { + "type": "string", + "description": "VNF descriptor ID" + }, + "vnfdProvider": { + "type": "string", + "description": "VNF descriptor vendor ID" + }, + "vnfdModel": { + "type": "string", + "description": "The model of the VNF (JSON) encoded to string" + }, + "vnfdVersion": { + "type": "string", + "description": "VNF descriptor version" + }, + "vnfVersion": { + "type": "string", + "description": "VNF Software version" + }, + "downloadUrl":{ + "type": "string", + "description": "The URL from which the VNF package can be downloaded" + } + } + }, + "VnfInstListInfo": { + "type": "array", + "items": { + "$ref": "#/definitions/VnfInstInfo" + } + }, + "VnfInstInfo": { + "type": "object", + "properties": { + "vnfInstanceId": { + "type": "string", + "description": "VNF instance ID" + }, + "vnfInstanceName": { + "type": "string", + "description": "VNF instance name" + } + } + }, + "VnfPkgImgListInfo": { + "type": "array", + "items": { + "$ref": "#/definitions/VnfPkgImgInfo" + } + }, + "VnfPkgImgInfo": { + "type": "object", + "properties": { + "fileName": { + "type": "string", + "description": "image file name" + }, + "imageUrl": { + "type": "string", + "description": "image file path in the csar or image url in external repository" + } + } + }, + "modelParserRequest":{ + "type": "object", + "properties": { + "csarId": { + "type": "string", + "description": "csar Package Id" + }, + "inputs": { + "type": "object", + "description": "csar package json inputs" + } + } + }, + "modelParserResponse":{ + "type": "object", + "properties": { + "model": { + "type": "object", + "description": "csar model json data" + } + } + }, + "jobResponseInfo": { + "type": "object", + "properties": { + "status": { + "type": "string" + }, + "progress":{ + "type": "string" + }, + "statusDescription": { + "type": "string" + }, + "errorCode": { + "type": "string" + }, + "responseId": { + "type": "string" + } + } + }, + "PostJobRequest": { + "type": "object", + "properties": { + "progress": { + "type": "string" + }, + "desc": { + "type": "string" + }, + "errcode": { + "type": "string" + } + } + }, + "JobDetailInfo":{ + "type": "object", + "properties": { + "jobId": { + "type": "string" + }, + "responseDescriptor": + { + "type":"object", + "properties": { + "status": { + "type": "string" + }, + "progress":{ + "type": "string" + }, + "statusDescription": { + "type": "string" + }, + "errorCode": { + "type": "string" + }, + "responseId": { + "type": "string" + }, + "responseHistoryList": { + "type": "array", + "items": { + "$ref": "#/definitions/jobResponseInfo" + } + } + } + } + } + } + } +} \ No newline at end of file -- cgit 1.2.3-korg