Bulk upsert support in the REST API for Concepts and Drugs

Hi all,

Does the OpenMRS REST API (or the FHIR module) currently support bulk upsert operations for Concepts and Drugs — i.e., a single request that creates records if they don’t exist and updates them if they do, keyed on UUID or some other unique identifier?

From what I can see in the docs, the standard endpoints handle one resource per call (POST to create, POST to /{uuid} to update), which means syncing a catalog of any meaningful size requires a GET-then-decide-then-write pattern per item. That’s been painful for us in practice — slow, chatty, and brittle when the network drops mid-sync.

A few specific questions:

  1. Is there an existing endpoint, module, or pattern that supports batch/bulk writes for these resource types?
  2. If not, is anyone aware of work in progress on this, or is the recommended approach still client-side loops?
  3. For folks doing this at scale today — are you going through the REST API, FHIR, or hitting the database directly?

Any pointers appreciated.

Thanks!

@dkayiwa @ibacher

Roughly speaking, the “bulk load” here is intended to be done via either the OCL module or Iniz. Is there a reason neither of those works for your scenario?