pallupz / covid-vaccine-booking

This tool can be used to automate booking slots on Co-WIN Platform.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setup IFTTT or other automations on your android phone to forward SMS that contain 'CoWIN' to the OTP telegram channel.

shailesh opened this issue · comments

I added this little piece in generate_otp function wrote a small android app to send data to socket when sms is recieved ( using Broadcast receiver). It sends OTP to function and it keeps running(PC and phone should be on same network ). If want any more info then I can provide it. EDIT : We can also add socket to timeout but i was lazy to add

            soc = socket.socket()
            soc.bind(('',1456))
            soc.listen(5)
            while True:
                c,adrr = soc.accept()
                mes = c.recv(16)
                stringdata = mes.decode('utf-8')
                c.close()
                if stringdata.isdigit and len(stringdata) == 6: 
                    OTP = stringdata
                    break
            soc.close()
            if OTP != None and len(OTP == 6):
                 print("Otp Recieved = "+ stringdata)
            else :
                OTP = input("Enter OTP (If this takes more than 2 minutes, press Enter to retry): ")

`

@Vishvajeet590 could you please share the complete script.. to automate this OTP part.

@Vishvajeet590 could you please share the complete script.. to automate this OTP part.

Hi, bro little late but you can check my Repository about automation. It's an app on which this existing script runs. Otp process is automatic. My repo ---> Here