diff --git a/assets/custom-patient-buttons-config.png b/assets/custom-patient-buttons-config.png new file mode 100644 index 0000000..94db84f Binary files /dev/null and b/assets/custom-patient-buttons-config.png differ diff --git a/assets/patient-actions-open.png b/assets/patient-actions-open.png new file mode 100644 index 0000000..9283bf7 Binary files /dev/null and b/assets/patient-actions-open.png differ diff --git a/guides/custom_patient_page.md b/guides/custom_patient_page.md new file mode 100644 index 0000000..e90e737 --- /dev/null +++ b/guides/custom_patient_page.md @@ -0,0 +1,43 @@ +Custom patient buttons +====================== + +Cliniko offers an additional integration option for applications that handle +patient data. This allows users to open these applications directly from Cliniko +and potentially synchronize information on a given patient as needed. + +How it works for Cliniko users +------------------------- + +Users can add these applications in a settings page under +Settings > Our clinic > Integrations: + +![Configuration +panel](../assets/custom-patient-buttons-config.png?raw=true) + +This adds a new button to the Patient Actions bar for each patient: + +![Patient actions with open +dropdown](../assets/patient-actions-open.png?raw=true) + +Clicking on one of those buttons causes the user's browser to send a GET request +to the corresponding URL, with a query string of `patient_id=`. If the user is logged into the other application, they +should be taken directly to that application's information screen about the +patient with that Cliniko ID. If they're not logged in, they should be +redirected to a login screen before they can see the patient information. + +How it works for integrators +------------------------- + +If you want your application to integrate with Cliniko in this way, it should +have an endpoint prepared to receive GET requests from browsers with the query +string above. Requests made by unauthenticated users should be redirected to a +login screen. Once the user is authenticated, your application should display +the information it has about the patient whose Cliniko ID was included in the +request. If you also integrate with Cliniko via its API, you can have your +application update its information on that patient via the API at this point. + +Once your patient integration endpoint is ready, please get in contact with us +so we can add its URL to our list of approved applications! Once that's done you +should be able to publish this URL to your users so they can add it to the +config panel shown above and use the integration. diff --git a/readme.md b/readme.md index fb3d05a..6505659 100644 --- a/readme.md +++ b/readme.md @@ -281,6 +281,14 @@ API Resources * [Treatment Notes](https://github.com/redguava/cliniko-api/blob/master/sections/treatment_notes.md) * [Users](https://github.com/redguava/cliniko-api/blob/master/sections/users.md) +Custom Patient Button +--------------------- + +Cliniko offers an additional integration option for applications that handle +patient data. See [this +guide](https://github.com/redguava/cliniko-api/blob/master/guides/custom_patient_page.md) +for more details. + Get involved and help make our API better -----------------------------------------