diff --git a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/DeviceDetailController.java b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/DeviceDetailController.java index aefc134fd6..d679e25fa3 100644 --- a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/DeviceDetailController.java +++ b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/DeviceDetailController.java @@ -78,19 +78,18 @@ public class DeviceDetailController { @Autowired RequestValidator requestValidator; - - /** - * Post API to insert a new row of DeviceDetail data - * - * @param deviceDetailRequestDto input parameter deviceRequestDto - * - * @return ResponseEntity DeviceDetail which is inserted successfully - * {@link ResponseEntity} + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new POST /securebiometricinterface/{sbiId}/devices endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostdevicedetail())") @ResponseFilter @PostMapping - @Operation(summary = "Service to save DeviceDetail", description = "Saves DeviceDetail and return DeviceDetail id") + @Operation(summary = "Service to save DeviceDetail - deprecated since release-1.3.0.", description = "This API has been deprecated since the 1.3.0 release and replaced by the POST /securebiometricinterface/{sbiId}/devices endpoint.") @ApiResponses({ @ApiResponse(code = 201, message = "When DeviceDetail successfully created"), @ApiResponse(code = 400, message = "When Request body passed is null or invalid"), @ApiResponse(code = 500, message = "While creating DeviceDetail any error occured") }) @@ -113,19 +112,14 @@ public ResponseWrapper createDeviceDetail( } - /** - * Put API to update a row of DeviceDetail data - * - * @param deviceDetailRequestDto input parameter deviceRequestDto - * - * @return ResponseEntity DeviceDetail which is updated successfully - * {@link ResponseEntity} + /* + * This API has been deprecated since the release-1.3.0 */ - @Deprecated + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getPutdevicedetail())") @ResponseFilter @PutMapping - @Operation(summary = "Service to update DeviceDetails", description = "This API has been deprecated since 1.3.x release.") + @Operation(summary = "Service to update DeviceDetails - deprecated since release-1.3.0.", description = "This API has been deprecated since release-1.3.0.") @ApiResponses({ @ApiResponse(code = 201, message = "When DeviceDetail successfully updated"), @ApiResponse(code = 400, message = "When Request body passed is null or invalid"), @ApiResponse(code = 500, message = "While updating DeviceDetail any error occured") }) @@ -146,16 +140,19 @@ public ResponseWrapper updateDeviceDetail( "AUT-007", deviceDetailRequestDto.getRequest().getId(), "deviceDetailId"); return responseWrapper; } - - /** - * - * @param deviceDetailRequestDto - * @return + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new PATCH devicedetail/{id}/approval endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getPatchdevicedetail())") @ResponseFilter @PatchMapping - @Operation(summary = "Service to approve/reject DeviceDetail", description = "Approve DeviceDetail and returns success message") + @Operation(summary = "Service to approve/reject DeviceDetail - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the PATCH devicedetail/{id}/approval endpoint.") @ApiResponses({ @ApiResponse(code = 201, message = "When DeviceDetail successfully approved/rejected"), @ApiResponse(code = 400, message = "When Request body passed is null or invalid"), @ApiResponse(code = 500, message = "While approving/rejecting DeviceDetail any error occured") }) @@ -177,11 +174,19 @@ public ResponseWrapper approveDeviceDetails( return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /devicedetail/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostdevicedetailsearch())") - @Operation(summary = "Service to search DeviceDetails", description = "ervice to search DeviceDetails") + @Operation(summary = "Service to search DeviceDetails - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /devicedetail/search/v2 endpoint.") public ResponseWrapper> searchDeviceDetails( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -199,11 +204,19 @@ public ResponseWrapper> searchDeviceType responseWrapper.setResponse(deviceDetaillService.searchDeviceType(RegistrationDeviceSubType.class, request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /devicedetail/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/filtervalues") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostdevicedetailfiltervalues())") - @Operation(summary = "Service to filter DeviceDetails", description = "Service to filter DeviceDetails") + @Operation(summary = "Service to filter DeviceDetails - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /devicedetail/search/v2 endpoint.") public ResponseWrapper filterValues( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -254,7 +267,7 @@ public ResponseWrapperV2 deactivateDevice(@PathVariable @PreAuthorize("hasAnyRole(@authorizedRoles.getPostdevicewithsbimapping())") @PostMapping(value = "/{id}/approval") - @Operation(summary = "Added in release-1.3.0, This endpoint allows Partner Admin users to approve or reject devices and activate the mapping between a device and an SBI", + @Operation(summary = "Added in release-1.3.0, available for Partner Admin, allows user to approve or reject devices and activate the mapping between a device and an SBI", description = "This endpoint allows Partner Admin users to approve or reject devices and activate the mapping between a device and an SBI. It is exclusively accessible to users with the PARTNER_ADMIN role.") @io.swagger.v3.oas.annotations.responses.ApiResponses(value = { @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "200", description = "OK"), @@ -271,7 +284,7 @@ public ResponseWrapperV2 approveOrRejectMappingDeviceToSbi(@PathVariabl @PreAuthorize("hasAnyRole(@authorizedRoles.getGetalldevicedetails())") @GetMapping(value = "/search/v2") - @Operation(summary = "Added in release-1.3.0, This endpoint fetches the list of all devices created by all partners", description = "This endpoint fetches the list of all devices created by all partners. It enhances the earlier /partners/devicedetail/search endpoint by improving performance, handling deactivated statuses, and adding SBI ID and version details. The API supports pagination, sorting and filtering and is designed exclusively for Partner Admin users.") + @Operation(summary = "Added in release-1.3.0, available only for Partner Admin, retrieves a list of all devices created by all partners", description = "This endpoint fetches the list of all devices created by all partners. It enhances the earlier /partners/devicedetail/search endpoint by improving performance, handling deactivated statuses, and adding SBI ID and version details. The API supports pagination, sorting and filtering and is designed exclusively for Partner Admin users.") @io.swagger.v3.oas.annotations.responses.ApiResponses(value = { @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "200", description = "OK"), @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))), diff --git a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/FTPChipDetailController.java b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/FTPChipDetailController.java index d9656d431f..019644567a 100644 --- a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/FTPChipDetailController.java +++ b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/FTPChipDetailController.java @@ -110,19 +110,14 @@ public ResponseWrapper createDeviceDetail( } - /** - * Put API to update a row of DeviceDetail data - * - * @param deviceDetailRequestDto input parameter deviceRequestDto - * - * @return ResponseEntity DeviceDetail which is updated successfully - * {@link ResponseEntity} + /* + * This API has been deprecated since the release-1.3.0 */ - @Deprecated + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getPutftpchipdetail())") @ResponseFilter @PutMapping - @Operation(summary = "Service to update ftp chip detail", description = "This API has been deprecated since 1.3.x release.") + @Operation(summary = "Service to update ftp chip detail - deprecated since 1.3.0 release.", description = "This API has been deprecated since 1.3.0 release.") @ApiResponses({ @ApiResponse(code = 201, message = "When ftp chip detail successfully updated"), @ApiResponse(code = 400, message = "When Request body passed is null or invalid"), @ApiResponse(code = 500, message = "While updating ftp chip detail any error occured") }) @@ -239,11 +234,19 @@ public ResponseWrapper getPartnerCertificate( "AUT-007", ftpChipDetailId, "ftpChipDetailId"); return response; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /ftpchipdetail/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostftpchipdetailsearch())") - @Operation(summary = "Service to serach ftp chip details", description = "Service to serach ftp chip details") + @Operation(summary = "Service to search ftp chip details - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /ftpchipdetail/search/v2 endpoint.") public ResponseWrapper> searchFtpChipDetails( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -282,7 +285,8 @@ public ResponseWrapperV2 getFtmCertificateDat @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnersftmchipdetails())") @GetMapping(value = "/search/v2") - @Operation(summary = "Added in release-1.3.0, This endpoint retrieves the list of all FTM chip details created by all partners", description = "This endpoint, available for Partner Admin users only, retrieves the list of all FTM chip details created by all partners. It upgrades the earlier GET endpoint /ftpchipdetail/search by adding performance improvements and support for deactivated status. Additionally, it supports pagination, sorting, and filtering. This endpoint is configured for the role: PARTNER_ADMIN") + @Operation(summary = "Added in release-1.3.0, available only for Partner Admin users, retrieves a list of all FTM chip details created by all partners", + description = "This endpoint, available for Partner Admin users only, retrieves the list of all FTM chip details created by all partners. It upgrades the earlier GET endpoint /ftpchipdetail/search by adding performance improvements and support for deactivated status. Additionally, it supports pagination, sorting, and filtering. This endpoint is configured for the role: PARTNER_ADMIN") @io.swagger.v3.oas.annotations.responses.ApiResponses(value = { @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "200", description = "OK"), @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))), diff --git a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/SecureBiometricInterfaceController.java b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/SecureBiometricInterfaceController.java index 7059f1765c..c07a1b7d58 100644 --- a/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/SecureBiometricInterfaceController.java +++ b/partner/partner-management-service/src/main/java/io/mosip/pms/device/controller/SecureBiometricInterfaceController.java @@ -110,11 +110,15 @@ public ResponseWrapper SecureBiometricInterface( } - @Deprecated + /* + * This API has been deprecated since the release-1.3.0 + */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getPutsecurebiometricinterface())") @ResponseFilter @PutMapping - @Operation(summary = "Service to update SecureBiometricInterface", description = "This API has been deprecated since 1.3.x release.") + @Operation(summary = "Service to update SecureBiometricInterface - deprecated since release-1.3.0.", + description = "This API has been deprecated since release-1.3.0.") @ApiResponses({ @ApiResponse(code = 201, message = "When SecureBiometricInterface successfully updated"), @ApiResponse(code = 400, message = "When Request body passed is null or invalid"), @ApiResponse(code = 500, message = "While updating SecureBiometricInterface any error occured") }) @@ -163,10 +167,18 @@ public ResponseWrapper approveSecureBiometricInterface( return responseWrapper; } + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /securebiometricinterface/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostsecurebiometricinterfacesearch())") - @Operation(summary = "Service to search SecureBiometricInterface details", description = "Service to search SecureBiometricInterface details") + @Operation(summary = "Service to search SecureBiometricInterface details - deprecated since release-1.3.0.", + description = "This API has been deprecated since the release-1.3.0 and replaced by the GET /securebiometricinterface/search/v2 endpoint.") public ResponseWrapper> searchSecureBiometric( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -175,10 +187,18 @@ public ResponseWrapper> searchSecureBiomet return responseWrapper; } + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new POST /securebiometricinterface/{sbiId}/devices endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PutMapping("/devicedetails/map") @PreAuthorize("hasAnyRole(@authorizedRoles.getPutsecurebiometricinterfacedevicedetailsmap())") - @Operation(summary = "Service to map device details with sbi", description = "Service to map device details with sbi") + @Operation(summary = "Service to map device details with sbi - deprecated since release-1.3.0.", + description = "This API has been deprecated since the release-1.3.0 and replaced by the POST /securebiometricinterface/{sbiId}/devices endpoint.") public ResponseWrapper mapDeviceDetails( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -186,11 +206,15 @@ public ResponseWrapper mapDeviceDetails( return responseWrapper; } - @Deprecated + /* + * This API has been deprecated since the release-1.3.0 + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PutMapping("/devicedetails/map/remove") @PreAuthorize("hasAnyRole(@authorizedRoles.getPutsecurebiometricinterfacedevicedetailsmapremove())") - @Operation(summary = "Service to remove mapped device details with sbi", description = "This API has been deprecated since 1.3.x release.") + @Operation(summary = "Service to remove mapped device details with sbi - deprecated since release-1.3.0.", + description = "This API has been deprecated since release-1.3.0.") public ResponseWrapper removeMappedDeviceDetails( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -198,10 +222,18 @@ public ResponseWrapper removeMappedDeviceDetails( return responseWrapper; } + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /securebiometricinterface/{sbiId}/devices endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/devicedetails/map/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostsecurebiometricinterfacedevicedetailsmapsearch())") - @Operation(summary = "Service to search mapped device details and SecureBiometricInterface details", description = "Service to search mapped device details and SecureBiometricInterface details") + @Operation(summary = "Service to search mapped device details and SecureBiometricInterface details - deprecated since release-1.3.0.", + description = "This API has been deprecated since the release-1.3.0 and replaced by the GET /securebiometricinterface/{sbiId}/devices endpoint.") public ResponseWrapper> searchMappedDeviceDetails( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -209,11 +241,19 @@ public ResponseWrapper> searchMapped secureBiometricInterface.searchMappedDeviceDetails(DeviceDetailSBI.class, request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /securebiometricinterface/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/filtervalues") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostsecurebiometricinterfacefiltervalues())") - @Operation(summary = "Service to filter SBI's", description = "Service to filter SBI's") + @Operation(summary = "Service to filter SBI's - deprecated since release-1.3.0.", + description = "This API has been deprecated since the release-1.3.0 and replaced by the GET /securebiometricinterface/search/v2 endpoint.") public ResponseWrapper filterValues( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -280,7 +320,7 @@ public ResponseWrapperV2 deactivateSbi(@PathVariable("sbi @PreAuthorize("hasAnyRole(@authorizedRoles.getGetallsbidetails())") @GetMapping(value = "/search/v2") - @Operation(summary = "Added in release-1.3.0, This endpoint fetches a list of all SBIs created by all partners", description = "This endpoint is for Partner Admin users and fetches a list of all SBIs created by all partners. It enhances the earlier /partners/securebiometricinterface/search endpoint by improving performance, handling deactivated statuses, and including associated device details (counts for associated, approved, and pending devices). The API supports pagination, sorting and filtering and is accessible to users with the PARTNER_ADMIN role") + @Operation(summary = "Added in release-1.3.0, available only for Partner Admin users, retrieves a list of all SBIs created by all partners", description = "This endpoint is for Partner Admin users and fetches a list of all SBIs created by all partners. It enhances the earlier /partners/securebiometricinterface/search endpoint by improving performance, handling deactivated statuses, and including associated device details (counts for associated, approved, and pending devices). The API supports pagination, sorting and filtering and is accessible to users with the PARTNER_ADMIN role") @io.swagger.v3.oas.annotations.responses.ApiResponses(value = { @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "200", description = "OK"), @io.swagger.v3.oas.annotations.responses.ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))), diff --git a/partner/partner-management-service/src/main/java/io/mosip/pms/partner/controller/PartnerServiceController.java b/partner/partner-management-service/src/main/java/io/mosip/pms/partner/controller/PartnerServiceController.java index f8ec5c77fa..949a36c349 100644 --- a/partner/partner-management-service/src/main/java/io/mosip/pms/partner/controller/PartnerServiceController.java +++ b/partner/partner-management-service/src/main/java/io/mosip/pms/partner/controller/PartnerServiceController.java @@ -264,20 +264,19 @@ public ResponseEntity> retrieveP response.setVersion(VERSION); response.setResponse(retrievePartnerDetailsResponse); return new ResponseEntity<>(response, HttpStatus.OK); - } + } - /** - * This API would be used to retrieve all API key requests submitted by partner - * till date. - * - * @param partnerId - * this is unique id created after self registered by partner - * @return partnersRetrieveApiKeyRequests this is a list of partner request for - * creation of partner API Key + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/policy-requests endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnersapikeyrequest())") @RequestMapping(value = "/{partnerId}/apikey/request", method = RequestMethod.GET) - @Operation(summary = "Service to get api key requests of partner", description = "Service to get api key requests of partner") + @Operation(summary = "Service to get api key requests of partner - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/policy-requests endpoint.") public ResponseEntity>> getAPIKeyRequestsOfPartner( @PathVariable String partnerId) { ResponseWrapper> response = new ResponseWrapper<>(); @@ -332,19 +331,17 @@ public ResponseWrapper uploadPartnerCertificate( return response; } - /** - * To Download Partner Certificate. - * - * @param certDownloadRequestDto {@link PartnerCertDownloadRequestDto} request - * @return {@link PartnerCertDownloadResponeDto} encrypted Data - * @throws IOException - * @throws JsonProcessingException - * @throws JsonMappingException - * @throws JsonParseException + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/{partnerId}/certificate-data endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnerscertificate())") @RequestMapping(value = "/{partnerId}/certificate", method = RequestMethod.GET) - @Operation(summary = "Service to get partner certificate", description = "Service to get partner certificate") + @Operation(summary = "Service to get partner certificate - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/{partnerId}/certificate-data endpoint.") public ResponseWrapper getPartnerCertificate( @ApiParam("To download resigned partner certificate.") @PathVariable("partnerId") @NotNull String partnerId) throws JsonParseException, JsonMappingException, JsonProcessingException, IOException { ResponseWrapper response = new ResponseWrapper<>(); @@ -416,10 +413,18 @@ public ResponseWrapperV2> getAuthPartnerApiKeys() { return partnerService.getAuthPartnerApiKeys(); } + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/v3 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostpartnerssearch())") - @Operation(summary = "Service to search partner details", description = "Service to search partner details") + @Operation(summary = "Service to search partner details - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/v3 endpoint") public ResponseWrapper> searchPartner( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -439,11 +444,19 @@ public ResponseWrapper> searchPartnerType( responseWrapper.setResponse(partnerService.searchPartnerType(request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/v3 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/filtervalues") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostpartnersfiltervalues())") - @Operation(summary = "Service to filter partner details", description = "Service to filter partner details") + @Operation(summary = "Service to filter partner details - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/v3 endpoint") public ResponseWrapper filterValues( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -451,11 +464,19 @@ public ResponseWrapper filterValues( responseWrapper.setResponse(partnerService.filterValues(request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/partner-policy-requests endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/apikey/request/filtervalues") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostpartnersapikeyrequestfiltervalues())") - @Operation(summary = "Service to filter api key requests", description = "Service to filter api key requests") + @Operation(summary = "Service to filter api key requests - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/partner-policy-requests endpoint") public ResponseWrapper apikeyRequetsFilterValues( @RequestBody @Valid RequestWrapper request) { ResponseWrapper responseWrapper = new ResponseWrapper<>(); @@ -463,11 +484,19 @@ public ResponseWrapper apikeyRequetsFilterValues( responseWrapper.setResponse(partnerService.apiKeyRequestFilter(request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/partner-policy-requests endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/apikey/request/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostpartnersapikeyrequestsearch())") - @Operation(summary = "Service to search api key requests", description = "Service to search api key requests") + @Operation(summary = "Service to search api key requests - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/partner-policy-requests endpoint.") public ResponseWrapper> searchApikeyRequest( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); @@ -475,11 +504,19 @@ public ResponseWrapper> searchAp responseWrapper.setResponse(partnerService.searchPartnerApiKeyRequests(request.getRequest())); return responseWrapper; } - + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/apikey/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. + */ + @Deprecated(since = "release-1.3.0") @ResponseFilter @PostMapping("/apikey/search") @PreAuthorize("hasAnyRole(@authorizedRoles.getPostpartnersapikeysearch())") - @Operation(summary = "Service to search api key", description = "Service to search api key") + @Operation(summary = "Service to search api key - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/apikey/search/v2 endpoint.") public ResponseWrapper> searchApikey( @RequestBody @Valid RequestWrapper request) { ResponseWrapper> responseWrapper = new ResponseWrapper<>(); diff --git a/partner/partner-management-service/src/main/java/io/mosip/pms/partner/manager/controller/PartnerManagementController.java b/partner/partner-management-service/src/main/java/io/mosip/pms/partner/manager/controller/PartnerManagementController.java index c1d2f4e4f2..561b13a820 100644 --- a/partner/partner-management-service/src/main/java/io/mosip/pms/partner/manager/controller/PartnerManagementController.java +++ b/partner/partner-management-service/src/main/java/io/mosip/pms/partner/manager/controller/PartnerManagementController.java @@ -124,15 +124,19 @@ public ResponseEntity> activateDe response.setResponse(partnersPolicyMappingResponse); auditUtil.setAuditRequestDto(PartnerManageEnum.ACTIVATE_DEACTIVATE_KYC_PARTNERS_SUCCESS); return new ResponseEntity<>(response, HttpStatus.OK); - } - - /** - * This API would be used to retrieve all Auth/E-KYC Partners for the policy group. - * @return response this class contains list of Auth/E-KYC Partners for the policy group + } + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/v3 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartners())") @RequestMapping(method = RequestMethod.GET) - @Operation(summary = "Service to get partner details", description = "Service to get partner details") + @Operation(summary = "Service to get partner details - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/v3 endpoint") public ResponseEntity> getPartners( @RequestParam("partnerType") Optional partnerType){ ResponseWrapper response=new ResponseWrapper<>(); @@ -143,14 +147,18 @@ public ResponseEntity> getPartne response.setResponse(retrievePartnerDetailsResponse); return new ResponseEntity<>(response, HttpStatus.OK); } - - /** - * This API would be used to retrieve all Auth/E-KYC Partners for the policy group. - * @return response this class contains list of Auth/E-KYC Partners for the policy group + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/v3 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnersnew())") @RequestMapping(value = "/v2", method = RequestMethod.GET) - @Operation(summary = "Service to get partner details", description = "Service to get partners details") + @Operation(summary = "Service to get partner details - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/v3 endpoint") public ResponseEntity> getPartnersDeatils( @RequestParam("partnerType") Optional partnerType){ ResponseWrapper response=new ResponseWrapper<>(); @@ -188,14 +196,18 @@ public ResponseEntity> ge response.setResponse(partnerAPIKeyToPolicyMappingsResponse); return new ResponseEntity<>(response , HttpStatus.OK); } - - /** - * This API would be used to retrieve all Partner API Key requests as received by partner manager - * @return response this class contains all Partner API Key requests as received by partner manager + + /* + * This API has been deprecated since the release-1.3.0 + * It has been replaced by the new GET /partners/apikey/search/v2 endpoint. + * The functionality provided by this API is now available in the new endpoint. + * Please use the new endpoint for all future requests. */ + @Deprecated(since = "release-1.3.0") @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnersapikey())") @RequestMapping(value = "/apikey" , method = RequestMethod.GET) - @Operation(summary = "Service to get api key requests", description = "Service to get api key requests") + @Operation(summary = "Service to get api key requests - deprecated since 1.3.0 release.", + description = "This API has been deprecated since the 1.3.0 release and replaced by the GET /partners/apikey/search/v2 endpoint") public ResponseEntity> getAPIKeyRequests(){ List apikeyRequests = null; ResponseWrapper response = new ResponseWrapper<>(); @@ -323,7 +335,8 @@ public ResponseWrapperV2> getAllPartners( @PreAuthorize("hasAnyRole(@authorizedRoles.getGetallpartnerpolicymappingrequests())") @GetMapping(value = "/partner-policy-requests") - @Operation(summary = "Added in release-1.3.0, This endpoint retrieves all details of policy requests by partners", description = "This endpoint, available for Partner Admin users, retrieves all details of policy requests by partners. It upgrades the earlier /partners/apikey/request/search endpoint with additional fields like partnerType, policyGroupName, and updatedDateTime, along with performance improvements. The endpoint supports pagination,sorting and filtering, and is configured for the PARTNER_ADMIN role") + @Operation(summary = "Added in release-1.3.0, available for Partner Admin users, retrieves all details of policy requests by partners", + description = "This endpoint, available for Partner Admin users, retrieves all details of policy requests by partners. It upgrades the earlier /partners/apikey/request/search endpoint with additional fields like partnerType, policyGroupName, and updatedDateTime, along with performance improvements. The endpoint supports pagination,sorting and filtering, and is configured for the PARTNER_ADMIN role") @ApiResponses(value = { @ApiResponse(responseCode = "200", description = "OK"), @ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))), @@ -379,7 +392,7 @@ public ResponseWrapperV2> getA @PreAuthorize("hasAnyRole(@authorizedRoles.getGetpartnersapikeyrequests())") @GetMapping(value = "/apikey/search/v2") - @Operation(summary = "Added in release-1.3.0, This endpoint retrieves the list of all API keys created by partners", + @Operation(summary = "Added in release-1.3.0, available for Partner Admin users, retrieves the list of all API keys created by partners", description = "This endpoint, available for Partner Admin users, retrieves the list of all API keys created by partners. It upgrades the earlier /partners/apikey/search endpoint with performance improvements and additional fields like policyGroupName, policyDescription, and policyGroupDescription. The endpoint supports pagination,sorting and filtering and is configured for the PARTNER_ADMIN role.") @ApiResponses(value = { @ApiResponse(responseCode = "200", description = "OK"), @@ -428,8 +441,8 @@ public ResponseWrapperV2> getAllApiKe @PreAuthorize("hasAnyRole(@authorizedRoles.getGetallcacertificates())") @GetMapping(value = "/root-certificates") - @Operation(summary = "Added in release-1.3.0, This endpoint, available for Partner Admin," + - " retrieves a list of all Root Trust certificates (CA and Intermediate CA)", description = "This endpoint, available for Partner Admin, retrieves a list of all Root Trust certificates (CA and Intermediate CA) in the system. It fetches details from the key manager endpoint /v1/keymanager/getCaCertificates. The endpoint supports server-side pagination, sorting, and filtering.") + @Operation(summary = "Added in release-1.3.0, This endpoint, available only for Partner Admin, retrieves a list of all Root Trust certificates (CA and Intermediate CA)", + description = "This endpoint, available only for Partner Admin, retrieves a list of all Root Trust certificates (CA and Intermediate CA) in the system. It fetches details from the key manager endpoint /v1/keymanager/getCaCertificates. The endpoint supports server-side pagination, sorting, and filtering.") @ApiResponses(value = { @ApiResponse(responseCode = "200", description = "OK"), @ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))), @@ -479,7 +492,7 @@ public ResponseWrapperV2> getCaCertif @PreAuthorize("hasAnyRole(@authorizedRoles.getGetdownloadrootcertificate())") @GetMapping(value = "/download-root-certificate/{certificateId}") @Operation(summary = "Added in release-1.3.0, This endpoint will download p7b file for a CA / Intermediate CA certificate along with the trust chain.", - description = "This endpoint, available for Partner Admin, allows downloading the p7b file for a CA or Intermediate CA certificate. The p7b file contains the full trust chain for the specified certificate.") + description = "This endpoint, available only for Partner Admin, allows downloading the p7b file for a CA or Intermediate CA certificate. The p7b file contains the full trust chain for the specified certificate.") @ApiResponses(value = { @ApiResponse(responseCode = "200", description = "OK"), @ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(schema = @Schema(hidden = true))),