Regarding Appointment Update API (A034)

Hello e-RS Team,
When we are updating the appointment we are passing below JSON{
“id”: “948185773”,
“meta”: {
“versionId”: “1”,
“profile”: [
FHIR Reference Server eRS-Appointment-1”,
HL7 UK FHIR Reference Server
]
},
“language”: “en”,
“resourceType”: “Appointment”,
“status”: “cancelled”,
“reason”: [
{
“coding”: [
{
“system”: “https://int.api.service.nhs.uk/STU3/CodeSystem/APPOINTMENT-CANCELLATION-REASON”,
“code”: “PATIENT_ILL”
}
]
}
],
“description”: “e-Referral Appointment”,
“incomingReferral”: [
{
“reference”: “ReferralRequest/000049765227/_history/6”
}
],
“participant”: [
{
“actor”: {
“identifier”: {
“system”: “http://fhir.nhs.net/Id/ers-service”,
“value”: “6709596”
},
“display”: “CardioVascular”
},
“status”: “accepted”
},
{
“actor”: {
“identifier”: {
“system”: “http://fhir.nhs.net/Id/nhs-number”,
“value”: “9728338449”
}
},
“status”: “accepted”
}
]
}
and facing the error below
{“meta”:{“profile”:[“https://fhir.nhs.uk/STU3/StructureDefinition/eRS-OperationOutcome-1"]},“resourceType”:“OperationOutcome”,“issue”:[{“severity”:“error”,“code”:“required”,“details”:{“coding”:[{“code”:“MISSING_VALUE”,“system”:“https://fhir.nhs.uk/STU3/CodeSystem/eRS-APIErrorCode-1”,“display”:"A mandatory input field is missing”}]},“diagnostics”:“‘participant[2]’ is mandatory, but was not supplied for ‘cancel’”}]}
Please guide us to resolve the issue.

When updating an appointment the Appointment resource must match the Appointment resource being updated. The only fields that can differ are the reason, comment, status, slot, start and end - these are the fields that need to be changed to perform a cancellation.

Please check if the Appointment is booked to a slot with a named clinician? If so the Appointment must have the clinician as a participant and this participant must be included when updating the appointment.

See “Booking with Named clinician” request example on ## A016 - Book or defer appointment for an example of an Appointment with a named clinician.

Hello @adam.oldfield,
Could you please share the sample JSON for the Update Appointment (A034) API.

Hi @supplier,

If the booking was to a slot with a named clinician then this clinician must be included in the Appointment participant list when cancelling. As mentioned above the A016 example details how to create an appointment with a named clinician.

Something like the following (replacing the sds-user-id as appropriate):

{
  "type": {
    "coding": [
      {
        "system": "http://hl7.org/fhir/ValueSet/encounter-participant-type",
        "code": "CON"
      }
    ]
  },
  "actor": {
    "identifier": {
      "system": "http://fhir.nhs.net/Id/sds-user-id",
      "value": "021600556514"
    }
  },
  "status": "accepted"
}

hi @adam.oldfield , We have tried earlier but facing
receiving below error :-
{
“meta”: {
“profile”: [
FHIR Reference Server eRS-OperationOutcome-1
]
},
“resourceType”: “OperationOutcome”,
“issue”: [
{
“severity”: “error”,
“code”: “business-rule”,
“details”: {
“coding”: [
{
“code”: “INAPPROPRIATE_VALUE”,
“system”: “FHIR Reference Server eRS API Error Code”,
“display”: “Inappropriate value”
}
]
},
“diagnostics”: “‘participant[2].actor.identifier.value’ value cannot be updated”
}
]
}

Can you please post request and response details for each step in the flow? Including URL, request headers/payload, response headers/payload.

Including:

  • A015 - Retrieve appointment slots
  • A016 - Book or defer appointment
  • A034 - Update appointment

Thanks.