bitvavo / python-bitvavo-api

Python wrapper for the Bitvavo API
https://pypi.org/project/python-bitvavo-api/
ISC License
38 stars 25 forks source link

307 error #30

Open L-Oosterloo opened 2 years ago

L-Oosterloo commented 2 years ago

I set API keys and put my ip address but, when I use them I get this error: {'errorCode': 307, 'error': 'This key does not allow access from this IP.'}

I checked my public IP and this was present in the whitelist. I created a new API and whitelisted only this IP.. same result.. what am I missing here?

NostraDavid commented 2 years ago

A piece of code would be helpful: What did you write to set it up?

I did it like this (do note that most of the values that I pass are the default values):

# dependency: pip install python-dotenv
import os
from dotenv import load_dotenv
from python_bitvavo_api.bitvavo import Bitvavo

load_dotenv()
bitvavo = Bitvavo(
    {
        "APIKEY": os.environ["BITVAVO_APIKEY"],
        "APISECRET": os.environ["BITVAVO_APISECRET"],
        "RESTURL": "https://api.bitvavo.com/v2",
        "WSURL": "wss://ws.bitvavo.com/v2/",
        "ACCESSWINDOW": 10000,
        "DEBUGGING": False,
    },
)