Current implementation :
POST /v1/regard-updated-approval-status checks the config file if the application in incoming request-body is present in config file of RO. If not present, sends 500 Internal server error to user.
Proposal:
This case needs to be altered for triggering callback WithdrawnApprovalNotification only for approval-status=BARRED, even if the application is not present in config file of RO. (Because few applications may not have disregarded the application, this trigger may be required for disregarding them). Also, the response code shall be updated as 204.
Also, for other cases, like approval-status = APPROVED or REGISTERED, and if the application in request body is absent in config file of RO, the response code could be 400 as the user would need to provide correct data.
Current implementation : POST /v1/regard-updated-approval-status checks the config file if the application in incoming request-body is present in config file of RO. If not present, sends 500 Internal server error to user.
Proposal: This case needs to be altered for triggering callback WithdrawnApprovalNotification only for approval-status=BARRED, even if the application is not present in config file of RO. (Because few applications may not have disregarded the application, this trigger may be required for disregarding them). Also, the response code shall be updated as 204.
Also, for other cases, like approval-status = APPROVED or REGISTERED, and if the application in request body is absent in config file of RO, the response code could be 400 as the user would need to provide correct data.
Note: In case of approval-status = REGISTERED, the application would be present in config file of RO. This case is being handled in https://github.com/openBackhaul/RegistryOffice/issues/416.