- API Key Identifies the integrating system. Provided by the medWrite team during onboarding and sent as a request header.
- Bearer Token Identifies the authenticated user. Obtained by calling the login endpoint with valid user credentials and the API key. The token is then sent in the
Authorizationheader on all subsequent requests.
For the login endpoint, credentials, and API key, contact the medWrite team.
Best practices
- Store tokens securely; never expose them in client-side code or logs.
- Do not share tokens across user sessions.
- Re-authenticate proactively when the token is close to expiry.
Next steps
Embedded Authentication
Embed MedWrite in your EHR.
Get Approved Outputs
Retrieve approved letters (FHIR Bundle).
