anoop142 / cowin-cli

Cross platform command line tool to List and Book Vaccine Slot using COWIN API.
GNU General Public License v3.0
35 stars 17 forks source link

Cowin Caching of the Protected APIs #27

Closed suman-subramonian closed 3 years ago

suman-subramonian commented 3 years ago

Hello,

I hope you are already aware of the caching issue of the protected APIs in Cowin. This started after Cowin removed the captcha support. Currently, the public APIs are fetching the latest data and the protected APIs are sending the cached data. The alerts are faster and are being sent as soon as the slots are opened. However if you log in to the application, you may not see the slots in the UI. Some can see it immediately. Some can see after 5 mins. Booking has become a lottery now. I don't know whether it's a bug or purposely done to bypass the bots. I've checked your program and it has the potential to help people book slots if you can also expose date as an input parameter. You can check this youtube video to understand the issue, https://youtu.be/hf44_-qqddY

Dates in all these formats are acceptable

t.date = "08-06-21" t.date = "08-6-2021" t.date = "08-6-21" t.date = "8-06-2021" t.date = "8-06-21" t.date = "8-6-2021" t.date = "8-6-21" t.date = "08/06/21" t.date = "08/6/2021" t.date = "08/6/21" t.date = "8/06/2021" t.date = "8/06/21" t.date = "8/6/2021" t.date = "8/6/21"

Thanks & Regards, Suman

anoop142 commented 3 years ago

Hi, Thanks Suman , I knew something weird with the protected API but didn't knew about this, this hack does seems to work. There is already a parameter to pass dates "-c date" , which will accept any values. I'll test this further and update the README

anoop142 commented 3 years ago

87df7a2b52d87134c4c7f5431ec08167c4da7b05 , uses cache bypass by default