PokitDok.com REST OAuth2 integration CHALLENGE!

PokitDok.com REST OAuth2 integration CHALLENGE!

  

Hey folks, I am experiencing a challenge in getting connected to the PokitDok.com APIs.

By the way - if you are in healthcare - you for SURE need to check out PokitDok!

PokitDok uses OAuth2 on all of their APIs - I was able to get an access_token using Postman so that I could get TEST calls to APIs like "Activities" and "Trading Partners". The only way I could get it to work in Postman was using Basic Authentication - BUT - you have to pass the key/value pair of key of grant_type and value of client_credentials into the body as x-www-form-urlencoded (see screenshot from Postman). I tried form-data and raw in Postman but they didn't work.

So, in OutSystems, I can test call the various APIs by pasting an access_token that I generate from Postman. Now, I need to get OutSystems to successfully call the PokitDok Oauth2 to get the access_token.

BUT, I can't get the POST OAuth2 REST call to work. You see, I have to get the access_token from the POST REST call their OAuth2 to start the secure session. (see OutSystems screenshot)

Attached are two OutSystems v11 OAPs - one for the Service and one for a test WebApp.

Anyone up for the challenge to help me get my PokitDokAuth.PostToken REST call to work???


 

Here is the PokitDokTest web app

Bruce Buttles wrote:

Hey folks, I am experiencing a challenge in getting connected to the PokitDok.com APIs.

By the way - if you are in healthcare - you for SURE need to check out PokitDok!

PokitDok uses OAuth2 on all of their APIs - I was able to get an access_token using Postman so that I could get TEST calls to APIs like "Activities" and "Trading Partners". The only way I could get it to work in Postman was using Basic Authentication - BUT - you have to pass the key/value pair of key of grant_type and value of client_credentials into the body as x-www-form-urlencoded (see screenshot from Postman). I tried form-data and raw in Postman but they didn't work.

So, in OutSystems, I can test call the various APIs by pasting an access_token that I generate from Postman. Now, I need to get OutSystems to successfully call the PokitDok Oauth2 to get the access_token.

BUT, I can't get the POST OAuth2 REST call to work. You see, I have to get the access_token from the POST REST call their OAuth2 to start the secure session. (see OutSystems screenshot)

Attached are two OutSystems v11 OAPs - one for the Service and one for a test WebApp.

Anyone up for the challenge to help me get my PokitDokAuth.PostToken REST call to work???


 


Trying to download and install to my environment result in IPP error,please go delete and create a new post and upload it in that new post without editing the post.
This OAP to be exact

Oliver Ong Chor Yew wrote:

Bruce Buttles wrote:

Hey folks, I am experiencing a challenge in getting connected to the PokitDok.com APIs.

PokitDok uses OAuth2 on all of their APIs - I was able to get an access_token using Postman so that I could get TEST calls to APIs like "Activities" and "Trading Partners". The only way I could get it to work in Postman was using Basic Authentication - BUT - you have to pass the key/value pair of key of grant_type and value of client_credentials into the body as x-www-form-urlencoded (see screenshot from Postman). I tried form-data and raw in Postman but they didn't work.

So, in OutSystems, I can test call the various APIs by pasting an access_token that I generate from Postman. Now, I need to get OutSystems to successfully call the PokitDok Oauth2 to get the access_token.

BUT, I can't get the POST OAuth2 REST call to work. You see, I have to get the access_token from the POST REST call their OAuth2 to start the secure session. (see OutSystems screenshot)

Attached are two OutSystems v11 OAPs - one for the Service and one for a test WebApp.

Anyone up for the challenge to help me get my PokitDokAuth.PostToken REST call to work???


 


Trying to download and install to my environment result in IPP error,please go delete and create a new post and upload it in that new post without editing the post.
This OAP to be exact

Sorry Oliver, I forgot about IPP.

There is no way to take apps from an enterprise env and push them to a Personal Environment.

I would have to rebuild it all by hand in personal and then send ...

Maybe later ... 


Solution

Hi Bruce,


Not sure how you got that text that you are trying to pass on the Request input. %7b is a "{", so it looks like an encoded json instead of a normal url encoded form.

Try to remove the request input, add 2 inputs grant_type and client_credentials and change the "Request Format" in the action to be Form Url Encoded.

(Don't remember if the inputs need to be set as "Send in" Url or Body)


Regards,

João Rosado

Solution

João Rosado wrote:

Hi Bruce,


Not sure how you got that text that you are trying to pass on the Request input. %7b is a "{", so it looks like an encoded json instead of a normal url encoded form.

Try to remove the request input, add 2 inputs grant_type and client_credentials and change the "Request Format" in the action to be Form Url Encoded.

(Don't remember if the inputs need to be set as "Send in" Url or Body)


Regards,

João Rosado


Thanks Joao that worked! Sent is a "Form URL encoded" and sent it in the "Body".