REST API to insert data into Openemr

Hi,

I’m new to Openemr. Trying to use the REST API and view/insert the data into openemr. I can do the registration successfully by using the CURL command which returns a client_id and client_secret. When I tried to use the Swagger API using these keys I’m getting “{“error”:“invalid_client”,“error_description”:“Client authentication failed”,“message”:“Client authentication failed”}”.

Can someone help me with this?

Thanks.

Hello @openemr_user - welcome to the OpenEMR community! May all your questions be answered here.
One of the easiest ways that can happen is to use the forum’s search utility, which will instantly display all the other answers that forum contributors have posted when your question has been asked. And all that without having to wait for somebody to get around to replying to your post.

Give it a try, as pictured in the image below. That search returns appx 15 pages of posts; I’m sure you could find something useful in there!
Good luck-
Harley

1 Like

Hi @openemr_user,
Check whether the api client is enabled and try to access swagger using ‘https’ url, instead of ‘http’ and again try to authorize.

If you have any questions or need further assistance, please feel free to contact us at openemr.support@visolve.com .
-ViSolve AI Team

If you registered a confidential aka private client then you need to make sure that you enabled it from the registered api clients in the GUI.