How do I set my device ID?
Closed this issue · 1 comments
xxCleef commented
I'm trying to avoid entering my 2FA code each time when logging in and saved the device ID which I used, how would I set that?
mmohades commented
Hey, sorry for the late reply.
You don't have to login every time. Once you get your access token, that will never expire until you manually revoke the access token using venmo.log_out(access_token)
function. Next time, you can just use your access token like this to continue using the wrapper:
from venmo_api import Client
venmo = Client(access_token='your access token that you have saved from before')
# Example, search for users:
users = venmo.user.search_for_users(query='Peter',
page=2)
To answer your question, here is how you can login using the device ID that you have saved from your last login:
get_access_token(username='myemail@random.com', password='your password', device_id='your device ID here')