NHS Notify Reminder System
Free appointment reminders via NHS App and email. Replaces paid SMS services (Accurx, Mjog).
What this does
- Reads appointment data from EMIS Web CSV exports
- Sends 48-hour and 24-hour reminders via NHS Notify
- Messages arrive in the NHS App inbox (or email as fallback)
- Tracks delivery via SharePoint List (no patient data stored)
- Alerts practice manager if failures exceed 20%
Prerequisites checklist
Work through these before attempting installation. Each has a clear owner so the admin team can divide up the work.
NHS Notify account approved
Apply for a routing plan. Once approved, NHS Notify will provide a routing plan UUID — this goes into config.json.
MESH mailbox credentials
MESH is the NHS secure messaging endpoint NHS Notify submits through. You need mailbox ID, password, and shared key.
EMIS Population Report configured
Report name: "Appointments Next 3 Days". Fields: NHS Number, Appointment Date/Time, Slot Type, Clinician, Site. Scheduled 08:00 and 13:00, exports CSV.
SCW HSCN whitelist
Whitelist outbound traffic to NHS Notify and MESH endpoints so the surgery PC on HSCN can reach them.
NHSmail SMTP for alerts
Used to email the practice manager if delivery failure rate exceeds 20%. Host: send.nhs.net, port 587.
Setup steps
Copy the scripts to the surgery PC
Place the reminder-system folder at C:\ReminderSystem\ on a PC that stays on during surgery hours.
Install Python dependencies
Open Command Prompt in C:\ReminderSystem\ and run: pip install -r requirements.txt
Fill in config.json
Open config.json in Notepad. Replace every REPLACE_WITH_* placeholder with the value from the prerequisites above.
Dry run to verify
Run: python send_reminders.py --dry-run. This reads the EMIS CSV and shows what would be sent, without actually sending.
Schedule via Windows Task Scheduler
Create two tasks for send_reminders.py (08:00 and 13:00 daily) and one for check_delivery.py (every 30 minutes during working hours). Use "Run whether user is logged on or not".
Go live with a small cohort
Start with one clinician's appointments for 3 days. Review logs and confirm patients receive reminders before expanding to the whole practice.
How deduplication keeps things safe
Each reminder is stamped with a deterministic key: SHA256(nhs_number + datetime + type).
If the script runs twice for the same appointment, NHS Notify sees the same key and rejects the duplicate with HTTP 422. This means:
- Safe to run on multiple PCs — only one message gets through
- Safe if Task Scheduler fires twice
- Safe to re-run after errors
No patient data is stored anywhere. NHS numbers flow through the script transiently and are never written to disk or sent to SharePoint.
Optional: SharePoint tracking
If you want a dashboard showing delivery rates, set up a Power Automate webhook:
- Create a SharePoint List called Appointment Reminders
- Add columns: appointment hash, reminder type, timestamps, status
- Create a Power Automate flow: HTTP trigger → Create SharePoint item
- Paste the webhook URL into
config.json - Build a Power BI dashboard from the SharePoint List
Only appointment hashes and timestamps are sent — no NHS numbers, names, or addresses.
Troubleshooting
No CSV files found
Check emis_csv_folder in config.json matches where EMIS exports. Check the EMIS Population Report is scheduled and running.
HTTP 401 from MESH
MESH credentials may have expired — raise a ticket with the SCW IT team.
All messages show as duplicates
This is normal if the script ran already for these appointments. Idempotency keys (SHA256 of NHS number + datetime + type) prevent double-sending.
Reminders not arriving in NHS App
Check NHS Notify status page. Verify routing plan is active. Patient may not have NHS App installed — email fallback activates automatically.
Logs are in the logs/ folder, one file per day per script.
Governance note
Before go-live: confirm DPIA sign-off for processing EMIS appointment data through NHS Notify. Pilot at Wye Valley Surgery first; external publication of this blueprint will follow once the pilot confirms it works as intended.
Scripts and source
The Python scripts live at tools/reminder-system/ on Dr Krishnan’s machine. Request a zipped copy when you’re ready to install.
Internal pilot — Wye Valley Surgery
Questions? Contact Dr Krishnan Pasupathi