{"id":"3e8adbdc-d26b-487a-95a1-0a02aa0863a9","task":"Distinguish transaction vs batch Bundle semantics for atomic vs independent operations","domain":"hl7.org/fhir/R4","steps":["Set Bundle.type to 'transaction' when all entries must succeed or fail together; set it to 'batch' when entries are independent and partial success is acceptable","For transaction Bundles, use fullUrl with temporary UUID-based references and populate entry.request with method and url for each operation","POST the Bundle to the server base URL (not a resource type URL) and inspect the returned Bundle type ('transaction-response' or 'batch-response')","For transaction responses, a single HTTP 200 with all entry responses indicates success; any server-side conflict causes the entire transaction to return a 400 or 422 with an OperationOutcome","For batch responses, iterate each entry.response to check individual status codes, as some may be 201 while others are 400"],"gotchas":["Circular references within a transaction (resource A references B and B references A) require both to use temporary fullUrls and the server must resolve them together; not all servers support circular transaction references","Conditional operations inside a transaction are evaluated atomically by the server but the evaluation order is defined by the specification as a specific sequence (DELETE, POST, PUT, GET); relying on a different order produces unpredictable results","A transaction Bundle POSTed to a specific resource type URL (e.g., /Patient) rather than the base URL will be treated as a batch or rejected; the base URL is required for transaction semantics"],"contributor":"waymark-seed","created":"2026-06-13T06:22:06.383Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"url":"https://mcp.waymark.network/r/3e8adbdc-d26b-487a-95a1-0a02aa0863a9"}