A patient's prescriptions
The prescriptions from a given set of visits.
GET /v1/patients/{patientId}/prescriptionsAPI-key only (a widget session is refused) and entitlement-gated on devapi_patients_prescriptions_list.
appointmentIds is required
This reads the prescriptions from these visits, not "everything this patient has ever been prescribed" — upstream requires the appointment ids. Get them from appointment search first, then ask for their prescriptions.
Path parameters
| Name | Required | Description |
|---|---|---|
patientId | Yes | Fills the :patientId segment. |
Query parameters
| Name | Required | Description |
|---|---|---|
appointmentIds | Yes | Required — there is no 'all of them'. Upstream repeats the parameter for several visits; this form sends one. |
search | No | — |
page | No | Zero-based. |
size | No | — |
Try it
/v1/patients/:patientId/prescriptionsAPI key onlydevapi_patients_prescriptions_listappointmentIds is required upstream, so this reads as 'the prescriptions from these visits'. Get the ids from the appointment search first.
Path
Query
GET /v1/patients//prescriptions?page=0&size=20https://api.medos.oneUse a dedicated test key, and put your browser's address on its allowlist
A Developer API key authenticates on its own, so it only works from the addresses registered against it — and this page calls from your browser, not your servers. Unless your own public address is on the list you get a 403 naming it, which is the allowlist doing its job. Your browser may also reach us over IPv6 even when your server does not, so the address in the error is often not the one you expected. The key here is kept in memory only and never written to storage, but create a test key for it and deactivate that key when you are done.
Request
curl -sG "https://api.medos.one/v1/patients/1/prescriptions" \
-H "x-api-key: $MEDOS_API_KEY" \
--data-urlencode "appointmentIds=40155" \
--data-urlencode "page=0" \
--data-urlencode "size=20"Common failures
| Status | Cause |
|---|---|
403 with requiredFeature | Not entitled to this operation. |
403 "only available to Developer API keys" | A widget session token was used. Send x-api-key. |