Daniel Bennett
07/09/2025, 6:55 PMAppointment.recurrenceTemplate as an extension.
For identifying the original appointment in the series, which has the recurrenceTemplate, V6 has an Appointment.originatingAppointment field ([docs](https://build.fhir.org/appointment-definitions.html#Appointment.originatingAppointment))
We were initially going to model `originatingAppointment `as an extension, but:
⛔ Extensions can't be searched or indexed on
⛔ The basedOn could have been a good candidate, since technically FHIR allows any resource, but Medplum restricts this to ServiceRequest resources only
Any guidelines?finnbergquist
07/09/2025, 9:40 PMfinnbergquist
07/09/2025, 9:42 PMDaniel Bennett
07/10/2025, 3:31 PMfinnbergquist
07/10/2025, 5:06 PMDaniel Bennett
07/10/2025, 5:17 PMalbert_wong
07/18/2025, 3:01 AMDaniel Bennett
07/21/2025, 7:49 PMcancelled instead of hard deleting
@finnbergquist I'm finding that the supportingInformation field isn't searchable on Medplum - is that expected behavior? I can load all the clinician's appointments into memory and then search from there, if needed, but prefer searching via the APIDaniel Bennett
07/21/2025, 7:55 PMsupporting-info), no idea why they did this, but Medplum faithfully implements it so can't complain:
https://www.medplum.com/docs/api/fhir/resources/appointment#search-parametersDaniel Bennett
07/21/2025, 10:19 PMsupporting-info as an include parameter it doesn't work. Seems like this is not supported?
With the below query, I can get the associated "actors" (participants) for the appointment, but not the supportingInformation Appointment, which is set to the originating appointment (the one that has the recurrenceTemplate):
const searchParams: SearchRequest<Appointment> = {
resourceType: 'Appointment',
filters: [
{
code: 'practitioner',
operator: Operator.EQUALS,
value: getReferenceString(practitioner)
},
{
code: 'date',
operator: Operator.LESS_THAN,
value: params.end.toISO() || params.end.toString()
},
{
code: 'end',
operator: Operator.GREATER_THAN,
value: params.start.toISO() || params.start.toString()
}
],
include: [
{
resourceType: 'Appointment',
searchParam: 'actor',
modifier: 'iterate'
},
{
resourceType: 'Appointment',
searchParam: 'supporting-info',
modifier: 'iterate'
}
],
count: 100
}finnbergquist
07/22/2025, 4:12 PMfinnbergquist
07/22/2025, 4:14 PMiterate modifier is for recursively traversing through linked resources. See [these docs](https://www.medplum.com/docs/search/includes#iterate-modifier).
In this case, it isn't needed because supporting-info is a search param on the Appointment resource, not a linked oneDaniel Bennett
07/22/2025, 5:22 PM"supportingInformation": [
{
"reference": "Appointment/01982ed2-1dba-754d-acd9-295d879c7392"
}
],
Maybe its just not supported in Medplum's implementation?
Since supporting-info is a "reference" type search parameter for Appointment, it should be supported according to the FHIR spec: https://hl7.org/fhir/R4/appointment.html#search
Ultimately we should probably use the GraphQL library, but its not type-safe 👎 unless we setup graphql codegen, which seems like a big liftfinnbergquist
07/22/2025, 6:35 PMDaniel Bennett
07/29/2025, 4:22 PM