Standards-based access to your practice's notes, patients, and visits, plus a separate outbound read-only SMART on FHIR connection.
Authorization: Bearer mls_xxxxxxxxxxxxxxxx Accept: application/fhir+jsonConformance: /fhir/metadata
Each key carries explicit scopes. New keys default to schedule.read; pass { "scopes": [...] } to POST /api/fhir/keys to choose others. Keys created before scope enforcement keep full access. A signed-in clinician session is never scope-restricted.
schedule.read read Patient / Encounter / Appointment schedule.write create + update Appointment notes.read read DocumentReference notes.write create DocumentReference task.read read Task task.write update TaskA request outside the key's scopes returns
403 with a FHIR OperationOutcome.Returns a FHIR Bundle of Patient resources for your practice.
Your scheduled/seen visits as FHIR Encounter resources.
Receptionist systems can read, create, reschedule, check in, complete, cancel, or mark a no-show using standard FHIR R4 Appointment status values.
Search + paging — date=ge…/date=le… filter on the appointment date; _lastUpdated=gt<instant> returns rows changed since your last sync, ordered oldest-change-first with a deterministic cursor; _count (default 100, max 500) and _offset page through results via the Bundle's self/next links.
Demographics — an appointment booked online (no linked chart yet) carries a contained Patient resource (name, phone/email, birth date) referenced from its participant. Every appointment has an identifier with system urn:mls:appointment-id (plus urn:mls:external-appointment-id when present) and a meta.tag with system urn:mls:appointment-source (online, staff, fhir-api, …).
Idempotent create — include an identifier with your own system + value on POST /fhir/Appointment. Retries with the same identifier return 200 with the existing appointment instead of creating a duplicate (a fresh create returns 201).
Refill, injection-timing, appointment, pain, and office-message requests appear as FHIR Tasks. Update a Task to completed after staff handles it.
The scribe's finished notes. The note text is base64 in content[0].attachment.data.
Write a note into MLS:
POST https://scrivara-backend.onrender.com/fhir/DocumentReference
Authorization: Bearer mls_...
Content-Type: application/fhir+json
{
"resourceType": "DocumentReference",
"status": "current",
"subject": { "reference": "Patient/EXTERNAL_ID" },
"content": [{ "attachment": {
"contentType": "text/plain",
"data": "<base64 of the note text>"
}}]
}
Register a public https endpoint and MLS will POST { "event": "...", "resource": { ... } } for the resource type you subscribe to, HMAC-SHA256-signed in X-MLS-Signature (sha256=<hex> over the raw body with your webhook secret). Failed deliveries are retried once.
criteria is DocumentReference (default) or Appointment. Appointment events: appointment.created (online booking, front desk, or API create), appointment.updated (front desk or API update), appointment.confirmed / appointment.cancelled (patient self-service), appointment.deleted (front desk removal). GET /api/fhir/webhooks lists your hooks with last_delivery_at and last_status.
OAuth tokens are encrypted at rest. Automated write-back is disabled until MLS stores and verifies an authoritative visit-to-EMR-encounter binding.
Status: /smart/status
FHIR® is a registered trademark of HL7. MLS is not affiliated with HL7, athenahealth, Epic, or Oracle Health.