NCMP: Update existing Batch endpoint (Moving url param into rest body)
- NCMP batch endpoint is updated to accept details into request payload.
- Removed unused code of previous impl.
Issue-ID: CPS-1635
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
Change-Id: Ic290b750557da06b861c5a4a9bb12debc495ec2e
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
diff --git a/cps-ncmp-rest/docs/openapi/components.yaml b/cps-ncmp-rest/docs/openapi/components.yaml
index 7fc1063..2781f57 100644
--- a/cps-ncmp-rest/docs/openapi/components.yaml
+++ b/cps-ncmp-rest/docs/openapi/components.yaml
@@ -285,6 +285,43 @@
properties:
state:
$ref: '#/components/schemas/CmHandleCompositeState'
+ # Batch Request Schemas
+ ResourceDataBatchRequest:
+ type: object
+ title: get resource data for given array of operations
+ properties:
+ operations:
+ type: array
+ items:
+ type: object
+ $ref: '#/components/schemas/BatchOperationDefinition'
+ description: contains batch request details
+ BatchOperationDefinition:
+ required:
+ - operation
+ - datastore
+ - operationId
+ properties:
+ operation:
+ type: string
+ example: 'read'
+ operationId:
+ type: string
+ example: '12'
+ datastore:
+ type: string
+ example: 'ncmp-datastore:passthrough-operational'
+ options:
+ type: string
+ example: '(fields=schemas/schema)'
+ resourceIdentifier:
+ type: string
+ example: 'parent/child'
+ targetIds:
+ type: array
+ items:
+ type: string
+ example: [ "da310eecdb8d44c2acc0ddaae01174b1","c748c58f8e0b438f9fd1f28370b17d47" ]
examples:
dataSampleRequest: