INNER CODE UNIT · Python

generateOTP

Shra1V32/Playlist-AutoUpdater · login.py:12

def generateOTP(sid, rmn):
    print("Generating OTP.......")
    print("\n \n \n")
    otp_with_rmn_url = API_BASE_URL + "rest-api/pub/api/v1/rmn/" + rmn + "/otp"
    x = requests.get(otp_with_rmn_url)
    if x.status_code == 200:
        msg = x.json()['message']
        if msg == 'OTP generated successfully.':
            print("OTP Generated successfully")
        else:
            print(msg)

    else:
        print("Failed to generate OTP")
        return False


def loginWithPass(sid, rmn, pwd):

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…