What the libraries will do
Both are thin. They call the same endpoints this documentation describes, and add the parts that are easy to get wrong:- sending your key, and keeping it out of a browser;
- a fresh
Idempotency-Keyon every write, reused across retries so a retry cannot create a second record — see Retries and duplicates; - retrying a failed or rate-limited request with a sensible delay — see Rate limits;
- walking a paged list for you — see Pagination;
- typed errors that carry the
codeandrequest_id— see Errors; - checking a webhook’s signature — see Verifying a webhook’s signature;
- asking for FHIR instead of JSON — see FHIR R4.
The Postman collection
The collection has one request for every endpoint, grouped the way this reference groups them. To use it:- Get the collection. Download the collection (one JSON file). It is kept in step with this reference, so download it again when the API changes.
- In Postman, choose Import and select the file.
- Open the collection’s Variables tab.
baseUrlis alreadyhttps://api.clinikehr.com/v1. SetbearerTokento your key. Use a test key from the developer portal to begin, which reaches only your sandbox. - Send the request for
GET /v1/mefirst. It tells you which clinic or workspace the key belongs to, and proves the key works.
Idempotency-Key header with a fresh
value, so sending it twice by accident does not do it twice. Fill in the path values (such as
clinic_id) and the body before you send.
Treat your key like a password. Do not save a live key into a collection you share, and do not
export a collection with a live key filled in.