Your Medicover medical appointments delivered straight into your calendar
Medicover mobile app is useless. No reminders. No calendar integration. No location data.
This script downloads your medical appointments from Medicover site, and exports them to your CalDAV server. All your appointments are matched with up-to-date Medicover locations paired with geographic coordinates (thanks OpenStreetMap!). So you can just open your calendar, click on your appointment, click on the location and navigate there.
You can also write the appointments to an ICS file which can be imported to many calendar programs, including Google Calendar (by uploading a file or by URL)
Very rough around edges (works for me (tm)). Quickly hacked together in one evening. Use at your own risk.
Your card number (or any other valid ID in your Medicover portal).
Password to your Medicover portal.
Address to your CalDAV
server. (ownCloud, Google, etc.)
This script will use Medicover calendar in your CalDAV
server. Please create it first before use.
Alternatively, you can use the -o
command line argument to output the calendar to a file.
medicover.py
to extract your appointments. It will save them to appointments.json
.CalDAV
serverpython export.py -i appointments.json
python export.py -i appointments.json -o appointments.ics
Note that if you provide both the CALDAV_URL environment variable and the -o
argument,
the calendar will be sent to CalDAV
and saved to a file.
It is important that (if you do not use default locations.json
) you should use locations.py
script to extract new Medicover locations. If you care about your old data, you should check if Medicover location you used in the past still exists. If no, just add "old location": null
to locations.json
.
This script fuzzy-matches API downloaded appointment address, to names located presented on the website. Fuzzy matching is implemented because data from API does not equal data found on the main website.
Europe/Warsaw
is hardcoded in the code as CalDAV needs timezone aware dates; Medicover API seems to use only localtime (again, it has assumed Europe/Warsaw
for .PL))MichaĆ Papierski michal@papierski.net
Medicover is owned and managed by Medicover Holding S.A., a privately-held company headquartered in Luxemburg.
I am not related with Medicover in any way.