summaryrefslogtreecommitdiffstats
path: root/cps-ncmp-rest/docs
diff options
context:
space:
mode:
Diffstat (limited to 'cps-ncmp-rest/docs')
-rw-r--r--cps-ncmp-rest/docs/openapi/components.yaml9
-rwxr-xr-xcps-ncmp-rest/docs/openapi/ncmp.yml35
-rwxr-xr-xcps-ncmp-rest/docs/openapi/openapi.yml5
3 files changed, 46 insertions, 3 deletions
diff --git a/cps-ncmp-rest/docs/openapi/components.yaml b/cps-ncmp-rest/docs/openapi/components.yaml
index 7ca09ceedb..b4b8c84673 100644
--- a/cps-ncmp-rest/docs/openapi/components.yaml
+++ b/cps-ncmp-rest/docs/openapi/components.yaml
@@ -456,11 +456,16 @@ components:
cpsPathInQuery:
name: cps-path
in: query
- description: cps-path
+ description: For more details on cps path, please refer https://docs.onap.org/projects/onap-cps/en/latest/cps-path.html
required: false
schema:
type: string
default: /
+ examples:
+ container cps path:
+ value: //bookstore
+ list attributes cps path:
+ value: //categories[@code=1]
dmiPluginIdentifierInQuery:
name: dmi-plugin-identifier
in: query
@@ -527,7 +532,7 @@ components:
default: application/json
example: application/yang-data+json
datastoreName:
- name: ncmp-datastore-name
+ name: datastore-name
in: path
description: The type of the requested data
required: true
diff --git a/cps-ncmp-rest/docs/openapi/ncmp.yml b/cps-ncmp-rest/docs/openapi/ncmp.yml
index 38db26f470..1f7cce96ff 100755
--- a/cps-ncmp-rest/docs/openapi/ncmp.yml
+++ b/cps-ncmp-rest/docs/openapi/ncmp.yml
@@ -194,6 +194,41 @@ resourceDataForCmHandle:
502:
$ref: 'components.yaml#/components/responses/BadGateway'
+queryResourceDataForCmHandle:
+ get:
+ tags:
+ - network-cm-proxy
+ summary: Query resource data for a given cm handle
+ description: Query resource data for a given cm handle
+ operationId: queryResourceDataForCmHandle
+ parameters:
+ - $ref: 'components.yaml#/components/parameters/datastoreName'
+ - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
+ - $ref: 'components.yaml#/components/parameters/cpsPathInQuery'
+ - $ref: 'components.yaml#/components/parameters/optionsParamInQuery'
+ - $ref: 'components.yaml#/components/parameters/topicParamInQuery'
+ - $ref: 'components.yaml#/components/parameters/includeDescendantsOptionInQuery'
+ responses:
+ 200:
+ description: OK
+ content:
+ application/json:
+ schema:
+ type: object
+ examples:
+ dataSampleResponse:
+ $ref: 'components.yaml#/components/examples/dataSampleResponse'
+ 400:
+ $ref: 'components.yaml#/components/responses/BadRequest'
+ 401:
+ $ref: 'components.yaml#/components/responses/Unauthorized'
+ 403:
+ $ref: 'components.yaml#/components/responses/Forbidden'
+ 500:
+ $ref: 'components.yaml#/components/responses/InternalServerError'
+ 502:
+ $ref: 'components.yaml#/components/responses/BadGateway'
+
fetchModuleReferencesByCmHandle:
get:
description: fetch all module references (name and revision) for a given cm handle
diff --git a/cps-ncmp-rest/docs/openapi/openapi.yml b/cps-ncmp-rest/docs/openapi/openapi.yml
index fe0c4acfc7..ee29366906 100755
--- a/cps-ncmp-rest/docs/openapi/openapi.yml
+++ b/cps-ncmp-rest/docs/openapi/openapi.yml
@@ -31,9 +31,12 @@ components:
type: http
scheme: basic
paths:
- /v1/ch/{cm-handle}/data/ds/{ncmp-datastore-name}:
+ /v1/ch/{cm-handle}/data/ds/{datastore-name}:
$ref: 'ncmp.yml#/resourceDataForCmHandle'
+ /v1/ch/{cm-handle}/data/ds/{datastore-name}/query:
+ $ref: 'ncmp.yml#/queryResourceDataForCmHandle'
+
/v1/ch/{cm-handle}/modules:
$ref: 'ncmp.yml#/fetchModuleReferencesByCmHandle'