A personal health record to aggregate and sync all of your medical records from multiple patient portals in one place. Currently supports thousands of hospitals and clinics and major electronic medical record systems. Self-hosted, privacy-focused, and offline-first.
Warning
Mere is currently pre-release software: updates may break backwards compatibility.
Note
This project is supported by a single developer who is also a full-time medical resident. If you would like to support this project, please consider donating or help by tackling one of the issues.
Note
If Mere doesn't fit your needs, another great open-source PHR is Fasten Health
Mere Medical is a self-hosted web app to aggregate and sync all of your medical records from all your doctor and hospital visits in one place. See everything in a timeline view or quickly summarize your records.
Here are some ways to get Mere Medical running on your local computer
version: '3.9'
services:
app:
image: cfu288/mere-medical:latest
ports:
- '4200:80'
environment:
- ONPATIENT_CLIENT_ID=${ONPATIENT_CLIENT_ID}
- ONPATIENT_CLIENT_SECRET=${ONPATIENT_CLIENT_SECRET}
- EPIC_CLIENT_ID=${EPIC_CLIENT_ID}
- EPIC_SANDBOX_CLIENT_ID=${EPIC_SANDBOX_CLIENT_ID}
- CERNER_CLIENT_ID=${CERNER_CLIENT_ID}
- VERADIGM_CLIENT_ID=${VERADIGM_CLIENT_ID}
- PUBLIC_URL=${PUBLIC_URL}
- npm
- nvm
- Docker
- nx
-
Clone the repo
git clone https://github.com/cfu288/mere-medical.git
-
Set up NPM and install NPM packages
nvm install v20.11.0 nvm use npm install
-
If Nx is not installed, install it
npm i nx -g
if you are prompted to run migrations, run the following:
npx nx migrate --run-migrations
-
Create
.env
files for each project to run and fill with valuescp apps/api/.example.env apps/api/.env
vim apps/web/src/environments/config.json
-
Generate localhost ssl certs
mkdir -p .dev/certs mkcert -key-file .dev/certs/localhost-key.pem -cert-file .dev/certs/localhost.pem localhost mkcert -install
-
Serve each one on its own:
npx nx serve web npx nx serve api
or together as a full app:
npx nx run-many --target=serve --projects=api,web
-
Run e2e tests
npx nx run web-e2e:e2e
-
Build and serve in docker container:
docker build -t mere-medical . docker run -p 4200:80 -i -t \ --name mere-medical \ -e ONPATIENT_CLIENT_ID=<> \ -e ONPATIENT_CLIENT_SECRET=<> \ -e EPIC_CLIENT_ID=<> \ -e EPIC_SANDBOX_CLIENT_ID=<> \ -e CERNER_CLIENT_ID=<> \ -e VERADIGM_CLIENT_ID=<ID_HERE> \ -e PUBLIC_URL=https://localhost:4200 \ mere-medical:latest
- Respect user autonomy and user control.
- Prioritize privacy/security and UX - if those are in conflict, ask the user what they would prefer but default to security.
- Be transparent about decisions on data storage, handling, and usage.
- Where feasible, build features to be local first (run on the users device). This essentially means client side/offline first. Mere's core functionality should continue to work without any internet connection.
- For features that cannot be client-side, enable users to self-host server side functionality where feasible. This means that the user should be able to run Mere on their own server and not rely on a third party.
- Optionally fall back to third party services when self-hosting is not feasible. Should only apply to features that are not core functionality and should always be opt-in.