Order Case Status Updated

Fires when the external (Jira) case linked to an order changes status. targetEntity is the Order. The eventType is case_status_updated.

Field guarantees

FieldGuarantee
eventData.caseId✅ Always present (v1)
eventData.externalCaseStatus⚠️ Conditional — may be undefined if the Jira status can't be resolved
Case fields in v2⛔ Not delivered — none map to the ORDER allowlist
🚧

Case detail is v1-only. v2 payloads carry a generic order reference (order_id, order_status) but not caseId, externalCaseIdentifier, or externalCaseStatus. If you need the case status, keep this webhook on v1.

v1 payload (legacy)

{
  "_id": "event::8d367e3b-xxxx-xxxx-xxxx-3c6b7dfb804a",
  "ownerEntity": "pat::117eb3b9-xxxx-xxxx-xxxx-9424274b5425",
  "ownerEntityModel": "Patient",
  "targetEntity": "order::e5576e92-xxxx-xxxx-xxxx-3c3173a3fb82",
  "targetEntityModel": "Order",
  "eventTitle": "Case Status Updated",
  "eventDescription": "External case status updated to resolved",
  "eventType": "case_status_updated",
  "eventData": {
    "caseId": "case::5b6e1c2f-xxxx-xxxx-xxxx-7a4f2b1c9de0",
    "externalCaseIdentifier": "JIRA-4821",
    "externalCaseStatus": "resolved"
  },
  "deleted": false,
  "createdAt": { "$date": "2026-01-01T12:00:00.000Z" },
  "updatedAt": { "$date": "2026-01-01T12:00:00.000Z" },
  "__v": 0
}
eventData fieldTypeAlways?Notes
caseIdstringInternal case id
externalCaseIdentifierstring⚠️Jira key
externalCaseStatusstring⚠️May be undefined if unresolved

v2 payload

Sanitized envelope. The fields this event actually emits (caseId, externalCaseIdentifier, externalCaseStatus) are not on the ORDER allowlist — the allowlist does include a case_status entry, but nothing this event emits aliases to that name — so only the order reference survives.

{
  "event_type": "case_status_updated",
  "event_id": "event::8d367e3b-xxxx-xxxx-xxxx-3c6b7dfb804a",
  "api_version": "2026-08-09",
  "timestamp": "2026-05-30T14:00:00.000Z",
  "affiliate_id": "aff::xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "patient_id": "pat::117eb3b9-xxxx-xxxx-xxxx-9424274b5425",
  "patient_external_id": "ext-patient-123",
  "patient_marketing_consent": false,
  "is_returning_patient": true,
  "order_id": "order::e5576e92-xxxx-xxxx-xxxx-3c3173a3fb82",
  "order_status": "requires_affiliate_review"
}
FieldDelivered in v2Notes
Envelope + patient identity
order_id, order_statusThe order's own status, not the case status
caseId, externalCaseIdentifier, externalCaseStatusNot on the allowlist