Receive 404 error when querying account status

Hi, I want to check my account status by running the following Python script:

import logging
from binance.spot import Spot as Client
from binance.lib.utils import config_logging
config_logging(logging, logging.DEBUG)
base_url = 'https://api.binance.us'
client = Client(base_url=base_url, key=<mykey>, secret=<mysecret>)
logging.info(client.account_status())

But the response says “404 not found”. I’d like to ask how to fix it. Thanks.

The endpoint is not available for binance US, refer to the documentation above to check if an endpoint is available.

I just follow the document in

https://binance-docs.github.io/apidocs/spot/en/#account-status-user_data

If I want to check my account status, how to use the method?

It raises the same error even using https://api.binance.com. What’s wrong with this?

https://github.com/binance/binance-connector-python/blob/master/examples/spot/wallet/account_status.py

Hi,

There is no issue with the code snippet linked.

Please make sure you are not trying to access Binance from a restricted country.

I use a proxy to connect to https://api.binance.us.

GET /sapi/v1/account/status is not support by Binance US (https://api.binance.us/), therefore it is not possible to use client.account_status().

To confirm that you your connection with the api is successful use the following method

client.ping()

If successful you should receive a 200 response with the following content

{}

/api/v3/account you can use this endpoint to query.

Received 404 error