File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 11import json
2+ import re
23import os
34import uuid
45import boto3
@@ -175,7 +176,7 @@ def delete_imms_records(identifiers: list[str]) -> None:
175176
176177def get_service_url (
177178 service_env : str = os .getenv ("IMMUNIZATION_ENV" ),
178- service_base_path : str = os .getenv ("IMMUNIZATION_BASE_PATH " ),
179+ service_base_path : str = os .getenv ("SERVICE_BASE_PATH " ),
179180):
180181 non_prod = ["internal-dev" , "int" , "sandbox" ]
181182 if service_env in non_prod :
@@ -184,4 +185,7 @@ def get_service_url(
184185 subdomain = ""
185186 else :
186187 subdomain = "internal-dev."
187- return f"https://{ subdomain } api.service.nhs.uk/{ service_base_path } "
188+
189+ service_base_path = re .sub (r"immunisation-fhir-api/FHIR/R4-pr-(\d+)" , r"immunisation-fhir-api-pr-\1" , service_base_path )
190+
191+ return f"{ subdomain } api.service.nhs.uk/{ service_base_path } "
You can’t perform that action at this time.
0 commit comments