Forbidden Error on Record Triage Outcome (A028) API

I’m trying to call the endpoint /STU3/ReferralRequest/{ubrn}/$ers.recordReviewOutcome (Record Triage Outcome - A028, FHIR STU3), but I’m getting the following error from the NHS side:

{

"meta": {

    "profile": \[

        "[https://fhir.nhs.uk/STU3/StructureDefinition/eRS-OperationOutcome-1"](https://fhir.nhs.uk/STU3/StructureDefinition/eRS-OperationOutcome-1%22 "https://fhir.nhs.uk/stu3/structuredefinition/ers-operationoutcome-1%22")

    \]

},

"resourceType": "OperationOutcome",

"issue": \[

    {

        "severity": "error",

        "code": "forbidden",

        "details": {

            "coding": \[

                {

                    "code": "FORBIDDEN",

                    "system": "[https://fhir.nhs.uk/STU3/CodeSystem/eRS-APIErrorCode-1"](https://fhir.nhs.uk/STU3/CodeSystem/eRS-APIErrorCode-1%22 "https://fhir.nhs.uk/stu3/codesystem/ers-apierrorcode-1%22"),

                    "display": "Forbidden"

                }

            \]

        },

        "diagnostics": "On Behalf Of User ID (555367989103) is not permitted for Business Function (SERVICE_PROVIDER_CLINICIAN)."

    }

\]

}

Our Smartcard (ID: 555367989103) already has the SERVICE_PROVIDER_CLINICIAN role, but the API still returns a Forbidden error.

Could you please check if the correct business function is assigned or advise which user/role should be used for this API call?

Hi @supplier - It looks like you are attempting to use a Service Provider Clinician ADMIN role, for which there is no assigned Service Provider Clinician role.

As per the spec:

“On behalf of” is only supported for a Service Provider Clinician Admin (SPCA) acting on behalf of a Service Provider Clinician (SPC).

Where an OBO User ID is supplied the authenticating user must be an SPCA and the OBO User ID must be that of an appropriate SPC.

Please retry using the SPC role, without supplying the OBO User ID.

Thanks,
Z.

Hi @zubeir.tai ,

Thanks for the guidance — the approach you suggested worked.
We were able to proceed successfully.

Regards,
A.

1 Like