HTTP 403 error when trying to Retrieve attachment (A042)

Hi, we are receiving an error 403 when trying to retrieve attachments on INT. Please can you help resolve this error?

Date: Tue, 21 Oct 2025 10:36:48 GMT

X-Request-ID: 98dcd32e-d6f6-46e3-a32a-c6db9cf2e12d-1

X-Correlation-ID: 9583b808-0a30-48df-8b05-0c3bd66303e4

{
    "resourceType": "OperationOutcome",
    "meta": {
        "lastUpdated": "2025-10-21T10:36:48.358Z",
        "profile": [
            "https://www.hl7.org/fhir/R4/operationoutcome.html"
        ]
    },
    "issue": [
        {
            "severity": "error",
            "code": "forbidden",
            "diagnostics": "The ASID (200000001992) does not have the interaction (urn:nhs:names:services:ers:READ_BINARY_R4_V001) required to call this endpoint.",
            "details": {
                "coding": [
                    {
                        "system": "https://fhir.nhs.uk/CodeSystem/http-error-codes",
                        "code": "REC_FORBIDDEN"
                    }
                ]
            }
        }
    ]
}

Hi Paul, welcome to the Developer Community :grinning_face:

I believe you’re from Hertfordshire Partnership University NHS Foundation Trust? If so, I’ve just checked your set up and I don’t recognise that ASID in the message above. The Application and ASID we set you up with when you registered with us was as follows:

App: HPFT - Paris - INT - e-Referral Service - Application Restricted

App ID: 76a4ee24-1ccb-49bf-9564-f5ebdbbe8665

ASID: 200000002667

The ASID above 200000001992 doesn’t have e-RS permissions as we didn’t set it up.

Kind regards,

Lucy

Hi Lucy, Thank you, that’s correct. :slight_smile: It looks like we had two applications registered as we recently restarted the project and I was still using the older one. I’ve tried the new API key now and it returns an error 500 on all API calls. Please can you help with this error too?

Date: Thu, 23 Oct 2025 13:01:42 GMT

X-Request-ID: a1edfd21-3fae-458e-ad1c-2a6d01969cc1-1

X-Correlation-ID: 3fd9589e-c1c6-414b-b41c-964d36ab71e3

{
    "resourceType": "OperationOutcome",
    "meta": {
        "lastUpdated": "2025-10-23T13:01:42.354Z",
        "profile": [
            "https://www.hl7.org/fhir/R4/operationoutcome.html"
        ]
    },
    "issue": [
        {
            "severity": "error",
            "code": "exception",
            "details": {
                "coding": [
                    {
                        "system": "https://fhir.nhs.uk/CodeSystem/http-error-codes",
                        "code": "REC_SERVER_ERROR"
                    }
                ]
            }
        }
    ]
}

Hi Paul

I noticed a slight error in the UUID set up against your application. I have submitted a correction and will confirm when this has been updated.

Kind regards

Nila

1 Like

Hi Paul

Please can you retest, as the update is confirmed.

Thanks

Kind regards

Nila

1 Like

Hi Nila, Thanks for replying so quickly, unfortunately I still get an error 500 response.

Date: Thu, 23 Oct 2025 14:50:51 GMT

X-Request-ID: 8ccfed49-2bd8-48d1-a9f5-b266a49f732b-1

X-Correlation-ID: 0457445a-0f09-41be-ba6c-3e4bdf815450

@BalalSaleh are you able to help us with this one please?

Hi Paul

Please can you try again.

Thanks

Kind regards

Nila

Thanks Nila, that worked!