summaryrefslogtreecommitdiffstats
path: root/cps-ncmp-rest/docs/openapi
diff options
context:
space:
mode:
authorDylanB95EST <dylan.byrne@est.tech>2022-01-27 17:12:52 +0000
committerDylan Byrne <dylan.byrne@est.tech>2022-03-01 16:17:16 +0000
commite557338803286d8aaa0f877aa25d52d18735f309 (patch)
tree059b68301b3e6c34d8bb68a8cb7dadf6bed45a06 /cps-ncmp-rest/docs/openapi
parent03459a08895ecc7e481fc5ec34779556268992f1 (diff)
Create Endpoint For Get Cm Handles By Name
Create endpoint and implement logic for get cm handle details by cm handle name Issue-ID: CPS-817 Change-Id: I83bd2da9219d13fac715a08b19108028ca6f6751 Signed-off-by: DylanB95EST <dylan.byrne@est.tech>
Diffstat (limited to 'cps-ncmp-rest/docs/openapi')
-rw-r--r--cps-ncmp-rest/docs/openapi/components.yaml23
-rwxr-xr-xcps-ncmp-rest/docs/openapi/ncmp.yml27
-rwxr-xr-xcps-ncmp-rest/docs/openapi/openapi.yml5
3 files changed, 51 insertions, 4 deletions
diff --git a/cps-ncmp-rest/docs/openapi/components.yaml b/cps-ncmp-rest/docs/openapi/components.yaml
index fd02b6e56..d82813b87 100644
--- a/cps-ncmp-rest/docs/openapi/components.yaml
+++ b/cps-ncmp-rest/docs/openapi/components.yaml
@@ -50,7 +50,7 @@ components:
createdCmHandles:
type: array
items:
- $ref: '#/components/schemas/RestCmHandle'
+ $ref: '#/components/schemas/RestInputCmHandle'
updatedCmHandles:
type: array
example:
@@ -64,14 +64,14 @@ components:
update-my-property: updated-property
delete-my-property: '~'
items:
- $ref: '#/components/schemas/RestCmHandle'
+ $ref: '#/components/schemas/RestInputCmHandle'
removedCmHandles:
type: array
items:
type: string
example: [my-cm-handle1, my-cm-handle2, my-cm-handle3]
- RestCmHandle:
+ RestInputCmHandle:
required:
- cmHandle
type: object
@@ -146,6 +146,23 @@ components:
type: string
example: my-module-revision
+ RestOutputCmHandle:
+ type: object
+ title: CM handle Details
+ properties:
+ cmHandle:
+ type: string
+ example: my-cm-handle1
+ publicCmHandleProperties:
+ $ref: '#/components/schemas/CmHandlePublicProperties'
+ CmHandlePublicProperties:
+ type: array
+ items:
+ type: object
+ additionalProperties:
+ type: string
+ example: Book Type
+
examples:
dataSampleRequest:
summary: Sample request
diff --git a/cps-ncmp-rest/docs/openapi/ncmp.yml b/cps-ncmp-rest/docs/openapi/ncmp.yml
index 3a71aba80..a267fb491 100755
--- a/cps-ncmp-rest/docs/openapi/ncmp.yml
+++ b/cps-ncmp-rest/docs/openapi/ncmp.yml
@@ -262,3 +262,30 @@ executeCmHandleSearch:
$ref: 'components.yaml#/components/responses/Forbidden'
500:
$ref: 'components.yaml#/components/responses/InternalServerError'
+
+retrieveCmHandleDetailsById:
+ get:
+ description: Retrieve CM handle details and properties by cm handle id
+ tags:
+ - network-cm-proxy
+ summary: Retrieve CM handle details
+ operationId: retrieveCmHandleDetailsById
+ parameters:
+ - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
+ responses:
+ 200:
+ description: OK
+ content:
+ application/json:
+ schema:
+ $ref: 'components.yaml#/components/schemas/RestOutputCmHandle'
+ 400:
+ $ref: 'components.yaml#/components/responses/BadRequest'
+ 401:
+ $ref: 'components.yaml#/components/responses/Unauthorized'
+ 403:
+ $ref: 'components.yaml#/components/responses/Forbidden'
+ 404:
+ $ref: 'components.yaml#/components/responses/NotFound'
+ 500:
+ $ref: 'components.yaml#/components/responses/InternalServerError' \ No newline at end of file
diff --git a/cps-ncmp-rest/docs/openapi/openapi.yml b/cps-ncmp-rest/docs/openapi/openapi.yml
index 838a0d08e..12a8318ef 100755
--- a/cps-ncmp-rest/docs/openapi/openapi.yml
+++ b/cps-ncmp-rest/docs/openapi/openapi.yml
@@ -36,4 +36,7 @@ paths:
$ref: 'ncmp.yml#/fetchModuleReferencesByCmHandle'
/v1/ch/searches:
- $ref: 'ncmp.yml#/executeCmHandleSearch' \ No newline at end of file
+ $ref: 'ncmp.yml#/executeCmHandleSearch'
+
+ /v1/ch/{cm-handle}:
+ $ref: 'ncmp.yml#/retrieveCmHandleDetailsById' \ No newline at end of file