added

June 26, 2023

We are excited to announce our new /patient-history/jobs API, which comes with improved functionality to schedule a Patient History job and other enhanced features.

🚧

On August 8th, the following endpoints will be deprecated:

To ensure a smooth transition and minimize any disruptions to your projects, we have prepared this guide to help you convert your existing requests to the new API.

Create a patient history job

OldNew
API ReferenceLinkLink
Endpoint/patient-history/patient/{patient-id}/refresh/patient-history/jobs
Query parameters?consent=1
Headerspractitioner-name: Testfirstname Testlastname
practitioner-role: 309343006
practitioner-npi: 1013085661

Whereas the /refresh endpoint does not have a request body, the new /jobs endpoint does.

{  
    "data": {  
        "type": "patient-history/jobs",  
        "attributes": {  
            "requestConsent": true,  
            "practitioner": {  
                "npi": "1013085661",  
                "name": "Testfirstname Testlastname",  
                "role": "309343006"  
            }  
        },
       "targetDate": "2023-09-01",
        "relationships": {  
            "patient": {  
                "data": {  
                    "type": "fhir/Patient",  
                    "id": "{patient-id}"  
                }  
            }  
        }  
    }  
}

Check the status of a patient history job

OldNew
API ReferenceLinkLink
Endpoint/patient-history/message-status/{message-id}/patient-history/jobs/{job-id}

Please see below for the differences in the response bodies.

{  
    "data": {  
        "id": "{job-id}",  
        "type": "create_patient_history_job",  
        "attributes": {  
            "message_status": "done",  
            "messages": [  
                {  
                    "services": "commonwell",  
                    "status": "done"  
                },  
                {  
                    "services": "surescripts",  
                    "status": "done"  
                }  
            ]  
        }  
    }  
}
{  
    "data": [  
        {  
            "type": "patient-history/jobs",  
            "id": "{job-id}",  
            "attributes": {  
                "createdAt": 1681406975,  
                "jobStatus": "in_progress",  
                "lastUpdatedAt": 1687809292,  
                "practitioner": {  
                    "npi": "1013085661",  
                    "name": "Testfirstname Testlastname",  
                    "role": "309343006"
                },  
                "providers": [  
                    {  
                        "service": "commonwell",  
                        "status": "done"  
                    },  
                    {  
                        "service": "surescripts",  
                        "status": "done"  
                    }  
                ]
            },  
            "relationships": {  
                "patient": {  
                    "data": {  
                        "type": "fhir/Patient",  
                        "id": "{patient-id}"  
                    }  
                }  
            }  
        }  
    ],  
    "links": {  
        "self": "<https://api.zusapi.com/patient-history/jobs?page[count]=50&page[offset]=0>"  
    },  
    "meta": {  
        "totalResultCount": 1  
    }  
}

Get jobs

OldNew
API ReferenceLinkLink
Endpoint/patient-history/messages/patient-history/jobs