diff --git a/containers/fhir-converter/app/main.py b/containers/fhir-converter/app/main.py index 8797cef079..6de7a0e1a4 100644 --- a/containers/fhir-converter/app/main.py +++ b/containers/fhir-converter/app/main.py @@ -162,7 +162,7 @@ async def convert(input: FhirConverterInput, response: Response): https://github.com/microsoft/FHIR-Converter. """ result = convert_to_fhir(**dict(input)) - if "original_request" in result.get("response"): + if "fhir_conversion_failed" in result.get("response"): response.status_code = status.HTTP_400_BAD_REQUEST return result @@ -242,11 +242,6 @@ def convert_to_fhir( else: result = vars(converter_response) - # Include original input data in the result. - result["original_request"] = { - "input_data": input_data, - "input_type": input_type, - "root_template": root_template, - } + result["fhir_conversion_failed"] = "true" return {"response": result} diff --git a/containers/fhir-converter/tests/test_FHIR-Converter.py b/containers/fhir-converter/tests/test_FHIR-Converter.py index aea3c4441c..609c91cbb1 100644 --- a/containers/fhir-converter/tests/test_FHIR-Converter.py +++ b/containers/fhir-converter/tests/test_FHIR-Converter.py @@ -55,11 +55,7 @@ "_spec_set": None, "_spec_signature": None, "method_calls": [], - "original_request": { - "input_data": "VALID_INPUT_DATA", - "input_type": "elr", - "root_template": "ADT_A01", - }, + "fhir_conversion_failed": "true", "returncode": 1, }