# HTTP 403 error when trying to Retrieve attachment (A042)

**URL:** <https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290>\
**Category:** e-Referral Service (e-RS)\
**Tags:** fhir\
**Created:** [21 October 2025 10:48 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290 "2025-10-21T10:48:37Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Paul\_K](https://avatars.discourse-cdn.com/v4/letter/p/96bed5/32.png) [@Paul\_K](https://developer.community.nhs.uk/u/Paul_K)\
**Post date:** [21 October 2025 10:48 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/1 "2025-10-21T10:48:37Z")

</div>

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

```auto
{
    "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"
                    }
                ]
            }
        }
    ]
}

```

---

<div class="post-metadata">

**Author:** ![lucy.killick1](https://avatars.discourse-cdn.com/v4/letter/l/fbc32d/32.png) [@lucy.killick1](https://developer.community.nhs.uk/u/lucy.killick1)\
**Post date:** [23 October 2025 12:38 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/2 "2025-10-23T12:38:09Z")

</div>

> [@Paul\_K](#):
>
> `200000001992`

Hi Paul, welcome to the Developer Community 😀

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

---

<div class="post-metadata">

**Author:** ![Paul\_K](https://avatars.discourse-cdn.com/v4/letter/p/96bed5/32.png) [@Paul\_K](https://developer.community.nhs.uk/u/Paul_K)\
**Post date:** [23 October 2025 13:08 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/3 "2025-10-23T13:08:49Z")

</div>

Hi Lucy, Thank you, that’s correct. 🙂 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

```auto
{
    "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"
                    }
                ]
            }
        }
    ]
}

```

---

<div class="post-metadata">

**Author:** ![nila.surti3](https://avatars.discourse-cdn.com/v4/letter/n/54ee81/32.png) [@nila.surti3](https://developer.community.nhs.uk/u/nila.surti3)\
**Post date:** [23 October 2025 13:21 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/4 "2025-10-23T13:21:19Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![nila.surti3](https://avatars.discourse-cdn.com/v4/letter/n/54ee81/32.png) [@nila.surti3](https://developer.community.nhs.uk/u/nila.surti3)\
**Post date:** [23 October 2025 13:36 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/5 "2025-10-23T13:36:33Z")

</div>

Hi Paul

Please can you retest, as the update is confirmed.

Thanks

Kind regards

Nila

---

<div class="post-metadata">

**Author:** ![Paul\_K](https://avatars.discourse-cdn.com/v4/letter/p/96bed5/32.png) [@Paul\_K](https://developer.community.nhs.uk/u/Paul_K)\
**Post date:** [23 October 2025 14:58 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/6 "2025-10-23T14:58:04Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![lucy.killick1](https://avatars.discourse-cdn.com/v4/letter/l/fbc32d/32.png) [@lucy.killick1](https://developer.community.nhs.uk/u/lucy.killick1)\
**Post date:** [23 October 2025 15:21 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/7 "2025-10-23T15:21:58Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![nila.surti3](https://avatars.discourse-cdn.com/v4/letter/n/54ee81/32.png) [@nila.surti3](https://developer.community.nhs.uk/u/nila.surti3)\
**Post date:** [23 October 2025 15:51 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/8 "2025-10-23T15:51:27Z")

</div>

Hi Paul

Please can you try again.

Thanks

Kind regards

Nila

---

<div class="post-metadata">

**Author:** ![Paul\_K](https://avatars.discourse-cdn.com/v4/letter/p/96bed5/32.png) [@Paul\_K](https://developer.community.nhs.uk/u/Paul_K)\
**Post date:** [24 October 2025 07:45 UTC](https://developer.community.nhs.uk/t/http-403-error-when-trying-to-retrieve-attachment-a042/8290/9 "2025-10-24T07:45:30Z")

</div>

Thanks Nila, that worked!
