MOBILE APP DEVELOPMENT

This forum is for programmers who have questions about the source code.
Post Reply
nanwar
Posts: 16
Joined: Thu Dec 15, 2016 5:27 am

MOBILE APP DEVELOPMENT

Post by nanwar » Tue Aug 15, 2017 6:19 am

Hi Guys,

I'm new to open dental development. I do have an idea and want to build an iOS / Android application on it. Can someone please help me out as i want to access and update following information using mobile app:
Appointment, patient demographics, medical information, medical history, HIPPA Document, patient Account detail & other driving licence etc information etc

We have reviewed and found that FHIR provide following:
Current resources that can be queried:
appointment status, operatory, and clinic
patient demographics
organization (practice)
practitioner (provider specialty)
provider and operatory schedule
available time slots
subscriptions (receive notifications about changes made to patients and appointments)

Can we update above information using FHIR as well.
To fetch and update required information, do we have any API's exposed by the Open Dental OR do we have to write our own API's for that purpose (if so, what are the best practices?).

Regards,
N.

User avatar
cmcgehee
Posts: 711
Joined: Tue Aug 25, 2015 5:06 pm
Location: Salem, Oregon

Re: MOBILE APP DEVELOPMENT

Post by cmcgehee » Tue Aug 15, 2017 8:08 am

As of right now, you cannot update patient information through FHIR. It is on our roadmap to provide this functionality, but we have not had a chance to devote developer time to this task. Other than FHIR, Open Dental does not have any API's that interface with the database. Your next best option, I would say, is to build your own API using our Middle Tier service. If an office has a Middle Tier service running (http://opendental.com/manual/middletier.html), then you can easily access and update anything in the database remotely (assuming you are provided with proper credentials). If you like, I can go into more detail about how this could be implemented.
Chris McGehee
Open Dental Software
http://www.opendental.com

nanwar
Posts: 16
Joined: Thu Dec 15, 2016 5:27 am

Re: MOBILE APP DEVELOPMENT

Post by nanwar » Wed Aug 16, 2017 3:51 am

Hi Thanks Chris for showing me the path. It would be great if you guide me further.

Here's a quick summary which i understood from the shared link.

A) FHIR won't be helpful for my project, as it has limited access to the resources and information.
B) Middle Tier is a web .NET web service
C) In order to use it, we need to deploy it on IIS (Middle Tier Project:= OpenDentalServer, Found that project in Source Code "OpenDental_16_4")
D) ServiceMain.asmx file does have some generic method. i) "ProcessRequest" ii) "GetComponentsFromDtoMeth". I believe these can be used to fetch multiple type of information.
E) How to Update / Create accounts, appointments etc? At the moment it seems, service only supports extracting of information.

So, how can i move forward and what are best practices proposed by OpenDental etc.



Regarding FHIR, (http://www.opendental.com/manual/Origin ... -1Spec.pdf)
Following should create new patient, right?

If this returns 0 results, we will need to create the patient by submitting a POST request to
http://50.201.161.45:56015/opendentalfhir/patient
{
"name": [
{
"use": "usual",
"family": "Clearwater",
"given": "Penelope"
}
],
"telecom": [
{
"system": "phone",
"value": "(123)456-7890",
"use": "home"
}
],
"gender": "female",
"birthDate": "1996-09-19"
}

Just to confirm your statement from prior comment, if we change anything e.g. "gender" value and post it again then it will not update patient record and will create NEW Patient?


Thanks
N.

User avatar
cmcgehee
Posts: 711
Joined: Tue Aug 25, 2015 5:06 pm
Location: Salem, Oregon

Re: MOBILE APP DEVELOPMENT

Post by cmcgehee » Wed Aug 16, 2017 8:35 am

That is correct that changing any values in POST FHIR request will create a new patient and will not update an existing patient.

Regarding Middle Tier, the access method that I am going to describe is more similar to writing a plugin than consuming an API. You will have to familiarize yourself with the Open Dental codebase and invoke methods in a somewhat complicated manner. You have found the entry point for all method calls in ProcessRequest. By calling ProcessRequest, you can access any method in the OpenDentBusiness project that begins with the line

Code: Select all

if(RemotingClient.RemotingRole==RemotingRole.ClientWeb) {
There are probably thousands of these methods in existence that you can call in this manner. These methods can do all sorts of things from updating appointments to deleting lab cases to marking procedures complete. These methods will all live in the Data Interface folder in the OpenDentBusiness project. To invoke them, once you have a Middle Tier server instance running (which does require IIS), you make a call to ServiceMain.asmx and call ProcessRequest. You will need to pass in an XML document that contains your Open Dental username and password, the method within OpenDentBusiness that you want to call and any parameters that the method requires. Here is an example of calling Patients.GetPat() with passing in patNum 104:

Code: Select all

<?xml version="1.0" encoding="utf-16"?><DtoGetObject xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><Credentials><Username>Alpha</Username><Password>a</Password></Credentials><MethodName>OpenDentBusiness.Patients.GetPat</MethodName><Params><DtoObject><TypeName>System.Int64</TypeName><Obj><long>104</long></Obj></DtoObject></Params><ObjectType>OpenDentBusiness.Patient</ObjectType></DtoGetObject>
This method will return an XML representation of a Patient object. Once you can accomplish calling this method, you can get almost any piece of information from Open Dental.
Chris McGehee
Open Dental Software
http://www.opendental.com

Post Reply