Documentation/api/README.md
Complete documentation for OpenEMR's REST API, FHIR API, and SMART on FHIR integration.
| Document | Description |
|---|---|
| AUTHENTICATION.md | OAuth2 flows, client registration, token management, and introspection |
| AUTHORIZATION.md | Scopes, permissions, and granular access control |
| STANDARD_API.md | OpenEMR REST API (/api/ endpoints) |
| FHIR_API.md | FHIR R4 API (/fhir/ endpoints) |
| SMART_ON_FHIR.md | SMART app integration and launch flows |
| DEVELOPER_GUIDE.md | Internal usage, multisite, security, and development |
https://your-openemr-install or https://your-openemr-install/openemr (note this should be the root of your openemr installation without a trailing slash)→ Start with FHIR API
→ Start with SMART on FHIR
→ Start with Standard API
→ Start with Developer Guide
https://localhost:9300/apis/default/api
https://localhost:9300/apis/default/fhir
https://localhost:9300/apis/default/portal
sequenceDiagram
participant App
participant OpenEMR
participant User
App->>OpenEMR: 1. Register Client
OpenEMR->>App: Client ID & Secret
App->>OpenEMR: 2. Authorization Request
OpenEMR->>User: 3. Login & Consent
User->>OpenEMR: 4. Approve
OpenEMR->>App: 5. Authorization Code
App->>OpenEMR: 6. Exchange Code for Token
OpenEMR->>App: 7. Access Token + Refresh Token
App->>OpenEMR: 8. API Requests with Token
Detailed Authentication Guide →
Define what data your application can access. Learn more →
patient/Patient.rs
user/Observation.rs
system/Patient.$export
Different authentication flows for different use cases:
Include site name in endpoint:
/apis/{site}/fhir/Patient
/apis/{site}/api/patient
.cruds syntax with backwards compatibility for .read/.write?category= and ?type=.well-known/smart-configuration discovery⚠️ Critical Security Requirements:
API integrations must comply with your jurisdiction's applicable healthcare regulations such as HIPAA in the USA. Ensure proper handling of Protected Health Information (PHI) and follow best practices for data security and patient privacy.
For US healthcare providers see ONC EHR Certification Requiremens
This documentation represents the collective knowledge and contributions of the OpenEMR open-source community. The content is based on:
The organization, structure, and presentation of this documentation was enhanced using Claude AI (Anthropic) to:
All technical accuracy is maintained from the original community-authored documentation.
OpenEMR is an open-source project. To contribute to this documentation:
Last Updated: November 2025 License: GPL v3
For complete documentation, see Documentation/api/