Skip to main content

Conventions

Requests and replies​

  • Every path starts with /api/patient.
  • Bodies are JSON in UTF-8. Send Content-Type: application/json with every body.
  • Replies are JSON. Two exceptions: endpoints that return a file, and the chat reply, which is a stream of server-sent events.
  • GET reads. POST, PUT, PATCH and DELETE change something and need the write scope.

Identifiers and formats​

ValueFormat
IdsOpaque strings. Store them as they are; do not parse them or assume a length.
Account idA number that names the clinic account a person belongs to. user.accountId in the sign-in reply.
EmailsCompared in lowercase. Send them in lowercase.
TimestampsISO 8601 in UTC, for example 2026-12-02T10:15:00.000Z.
DatesYYYY-MM-DD.
Phone numbersThe national number and the dial code as separate fields, for example "phone": "4155550123", "countryCode": "1".

New fields​

Fields are added to replies over time. Read the fields you need and ignore the rest. Do not fail on a field you have not seen before.

Repeating a call​

CallSafe to repeat
Any GETYes.
POST /partner/terms/acceptYes. Only the first acceptance is kept.
POST /lab/uploads/{uploadId}/completeYes. A repeat returns the same job.
A finished sign-inYes. The link to your key is made once.
Steps that send a codeEach call sends a new code and counts toward the limits.
Other writesNot unless the endpoint says so. Check the result before sending again.

Retrying​

You gotDo
A network error or a timeout on a GETRetry, waiting longer each time.
502, 503, 504Retry after Retry-After when it is present, otherwise after a few seconds.
429Wait as long as the reply says. See Limits.
400, 401, 403, 404, 409Do not retry the same request. Fix what the reply names.

Time​

Most calls answer within a second or two. Calls that have text written by AI take longer, and the chat reply arrives as a stream: read it as it comes.