mmohades / Venmo

Venmo API client for Python
GNU General Public License v3.0
145 stars 43 forks source link

404 Not Found Invalid Json #78

Closed xiaoeric closed 1 year ago

xiaoeric commented 1 year ago

Running into this error while trying to retrieve user transactions for the client user:

venmo_api.models.exception.HttpCodeError: HTTP Status code is invalid. Could not make the request because -> 404 Not Found.
Error: Invalid Json

I am using the provided example code for getting a user's transactions:

def callback(transactions_list):
    for transaction in transactions_list:
        print(transaction)

# callback is optional. Max number of transactions per request is 50.
client.user.get_user_transactions(user_id='venmo_user_id_here',
                                     callback=callback)

I am able to successfully retrieve a list of friends from the client, so I don't understand why this request is failing.

xiaoeric commented 1 year ago

Oops never mind, immediately resolved the issue by using the numerical user id (obtained from client.user.get_my_profile()) instead of display username after referring to #52.