Dentally integration help needed

I need to connect with Dentally, a practise management tool for dentists.

They have an API - documentation here- https://developer.dentally.co/

I am sure I can connect via the HTTP node but I am not smart enough to figure out the steps. They speak of external apps and tokens and I am not sure how that fist in with the HTTP node.

Can someone take a look at the docs and perhaps guide me on creating an effective connection?

Hey @Robm,

The first step is to create an OAuth2 credential for the HTTP Request node to use, The information you put in there will depend on what you want from Dentally but it will look something likeā€¦

Grant Type: Authorization Code
Authorization URL: Dentally
Acces Token URL: https://api.dentally.co/oauth/token
Client ID: Will come from Dentally somewhere
Client Secret: Will come from Dentally somewhere
Scope: appointment patient:read patient:update user:read
Auth URI Query Params: Leave blank
Authentication: Header

Once that is done you can set the URL in the HTTP Request node to https://api.dentally.co/v1/patients?query and it should return a list of patients.

1 Like

Thanks Jon

Questions

In Dentally I am able to create a token - a long string of characters. Does that factor into the Oauth2 credential set up? Or is it just ā€œhttps://api.dentally.co/oauth/tokenā€ that is needed for access token url?

I only want to be able to read and create appointments so I assume then the scope would be
ā€œappointment:read appointment:create appointment:updateā€ ?

To return a list of appts the url would be

https://api.dentally.co/v1/appointments?query 

Correct?

It seems I need to create an app in dentally to generate a client ID (Dentally seems to call this an application ID) and a Client secret. To create the app I am asked for a URL in addition to the redirect URL (which n8n provides). What would the URL be? The url of my n8n instance?

Thanks again for your help

Hey @Robm,

The URL n8n should give you on the page where you add the credential so it will be something like https://n8n.your-domain.tld/rest/oauth2-credential/callback

Ok seems like I have a successful Oauth 2 set up. Ie When connecting the account I was taken form n8n to Dentally and asked to login and to authorise account access.

I have been able to pull todays data from Dentally using GET and the url

[type or paste code here](https://api.dentally.co/v1/appointments?on=2022-07-27)

Next step, clean up the jason file and figure out how to push this into a google cal.

1 Like

Perfect, You are most of the way there :slight_smile: