API Events
An API Event can fire from any workstation. The format is a web hook, which is simply a REST style call to an endpoint of your choice, so it's the reverse of the normal REST calls that you would make to the API. You manage which events you want to fire by using API Subscriptions.
Open Dental generates these events by polling the database at the frequency you specify. The generated event is a REST message that includes the Customer Api Key in the Authorization header.
Types: The type is specified in the subscriptions.WatchTable field.
Patients
Appointments
Example:
POST https://myserver/apievents/appointmentevent
Authorization: VzkmZEaUWOjnQX2z
(there are other headers that can be ignored)
[
{
"AptNum": 18,
"PatNum": 17,
"AptStatus": "Scheduled",
"Pattern": "//XXXX//",
"Confirmed": 19,
"confirmed": "Not Called",
"Op": 3,
"Note": "",
"ProvNum": 1,
"provAbbr": "DOC1",
"ProvHyg": 0,
"AptDateTime": "2020-07-31 08:30:00",
"IsNewPatient": "false",
"ProcDescript": "Seal, Seal",
"ClinicNum": 0,
"IsHygiene": "false",
"DateTStamp":"2021-05-03 08:30:12",
"serverDateTime":"2021-05-04 09:32:45"
},
etc...
]
These events fire immediately upon user action. They are usually intended for a localhost endpoint.
UiEventTypes: Specified in the subscriptions.UiEventType field.
PatientSelected
Example:
POST https://myserver/apievents/PatientSelected
Authorization: VzkmZEaUWOjnQX2z
(there are other headers that can be ignored)
{
"PatNum":28,
"LName":"Harrison",
"FName":"Bradley",
"MiddleI":"V",
"Preferred":"Brad",
"PatStatus":"Patient",
"Gender":"Male",
"Position":"Married",
"Birthdate":"1986-11-06",
"SSN":"",
"Address":"201 S Burnett Ln",
"Address2":"",
"City":"Lakewood",
"State":"Maine",
"Zip":"12345",
"HmPhone":"5552523366",
"WkPhone":"",
"WirelessPhone":"",
"Guarantor":27,
"Email":"",
"EstBalance":0,
"PriProv":1,
"priProvAbbr":"DOC1",
"SecProv":0,
"secProvAbbr":"",
"BillingType":"StandardAccount",
"ImageFolder":"HarrisonBradley28",
"ChartNumber":"",
"MedicaidID":"",
"BalTotal":0,
"ClinicNum":"1",
"clinicAbbr":"Southside",
"PreferConfirmMethod":"None",
"PreferContactMethod":"None",
"Language":"",
"TxtMsgOk":"Unknown",
"siteDesc":"",
"DateTStamp":"2022-04-2111:46:19"
}