Article Complete
AIM
Data Scientist Creates Python Script To Track Available Slots For Covid Vaccinations
Data Scientist Creates Python Script To Track Available Slots For Covid Vaccinations

Data Scientist Creates Python Script To Track Available Slots For Covid Vaccinations

Published Updated

Key takeaways

  • A Data Scientist developed a Python script to track available Covid-19 vaccination slots in India using the CoWIN API.
  • The script aims to simplify the process of finding vaccination slots, which can be challenging on the CoWIN website.
  • The idea for the script emerged from the difficulty of navigating the CoWIN website to find available slots in various pin codes.
  • Bhatt utilised two simple Python libraries to create the script, showcasing the accessibility of programming for practical solutions.
5 min

Bhavesh Bhatt, Data Scientist from Fractal Analytics posted that he has created a Python script that checks the available slots for Covid-19 vaccination centres from CoWIN API in India. He has also shared the GitHub link to the script. 

The YouTube content creator posted, “Tracking available slots for Covid-19 Vaccination Centers in India on the CoWIN website can be a bit strenuous.” “I have created a Python script which checks the available slots for Covid-19 vaccination centres from CoWIN API in India. I also plan to add features in this script of booking a slot using the API directly," he added.

We asked Bhatt how did the idea come to fruition, he said, “Registration for Covid vaccines for those above 18 started on 28th of April. When I was going through the CoWIN website - https://www.cowin.gov.in/home, I found it hard to navigate and find empty slots across different pin codes near my residence. On the site itself, I discovered public APIs shared by the government [https://apisetu.gov.in/public/marketplace/api/cowin] so I decided to play around with it and that's how I came up with the script.”

Talking about the Python script, Bhatt mentioned that he used just 2 simple python libraries to create the Python script, which is datetime and requests. The first part of the code helps the end-user to discover a unique district_id. “Once he has the district_id, he has to input the data range for which he wants to check availability which is where the 2nd part of the script comes in handy,” Bhatt added. 

While asking about the features that he is planning to add to the script, Bhatt said, “I'm still exploring the APIs that exist on the site. Based on my initial read, I think we can add features in the script which will help in booking a slot directly using the API. The other feature that can be added is to download the vaccine certificate directly from the API after the vaccination is done.”

Check the link to the script here.

Membership

Stay ahead with AI insights.

Unlimited access to premium articles, exclusive analysis, and the stories shaping India's AI economy.

Subscribe now

AIM Americas

1190 Miraloma Way Suite P, Sunnyvale, CA 94085

AIM India

1st Floor, Sakti Statesman, Bellandur, Bengaluru – 560103

© 2026 AIM. All rights reserved.