piekstra / tplink-cloud-api

A Python library to remotely control TP-Link smart home devices using their cloud service - no need to be on the same network as your devices
GNU General Public License v3.0
41 stars 11 forks source link

Deprecated authentication method #71

Open naphtul opened 1 year ago

naphtul commented 1 year ago

When following the instructions on how to connect and discover devices, I am getting an email with the following message:

Hello, We noticed a login attempt from an older version of the Kasa app on an unrecognized device. Since 2-Step Verification is enabled, you have to update the Kasa app to the latest version to sign in with a verification code. If you are not the one who logged in, someone may be trying to access your account. The password can be changed to protect the account.

piekstra commented 1 year ago

I will try and do some local runs this weekend to try and reproduce. I'm wondering if it's something with the request headers.

wwlian commented 10 months ago

Ran into the same issue. During login, the API returns the following:

{
  "error_code": -23003,
  "msg": "App version is too old"
}

This comment indicates that the API error is indicative of 2-Step Verification being enabled. I disabled 2-Step Verification for my account, and login worked without any errors.

I searched around, and I couldn't find any info on how to do 2-Step Verification programmatically.