Skip to content

Match Clinic and Patient

Request

An internal endpoint used for matching an EHR request (e.g. NewOrder) to a clinic and patient.

If a clinic with the provided details cannot be found, the service will return 404 Not Found and will not attempt to match patients to the provided details.

Due to lack of uniqueness constraints on the MRN and DOB fields it's possible that multiple patient records match the provided attributes. All results will be returned in the response and it's the calling services responsiblity to determine how to handle duplicates records.

If a unique match is found, the patient matching criteria will be added to the patient record for future use (e.g. pushing data on a schedule).

Security
sessionToken
Bodyapplication/json
messageRefobject(EHRMatchMessageRef)
patientsobject(Patient Matching Options)
curl -i -X POST \
  https://tidepool.redocly.app/_mock/reference/clinic.v1/v1/redox/match \
  -H 'Content-Type: application/json' \
  -H 'x-tidepool-session-token: YOUR_API_KEY_HERE' \
  -d '{
    "messageRef": {
      "dataModel": "Order",
      "eventType": "New",
      "documentId": "string"
    },
    "patients": {
      "criteria": [
        "MRN"
      ],
      "onUniqueMatch": "ENABLE_REPORTS"
    }
  }'

Responses

OK

Bodyapplication/json
clinicobject(Clinic)required

Clinic

patientsArray of objects(patients.v1)
settingsobject(EHR Settings)required
Response
{ "clinic": { "id": "2fe2488217ee43e1b2e83c2f", "address": "string", "city": "Palo Alto", "postalCode": "94301", "state": "CA", "country": "USA", "patientTags": [], "sites": [], "lastDeletedPatientTag": {}, "phoneNumbers": [], "clinicType": "provider_practice", "clinicSize": "0-249", "name": "string", "shareCode": "string", "canMigrate": true, "website": "http://example.com", "createdTime": "2019-08-24T14:15:22Z", "updatedTime": "2019-08-24T14:15:22Z", "tierDescription": "Free", "tier": "tier0100", "preferredBgUnits": "mg/dL", "suppressedNotifications": {}, "timezone": "Africa/Abidjan" }, "patients": [ {} ], "settings": { "enabled": true, "sourceId": "string", "destinationIds": {}, "procedureCodes": {}, "mrnIdType": "string", "provider": "xealth", "scheduledReports": {}, "tags": {}, "flowsheets": {}, "notes": {} } }