CryptoCurrency Trading Guide - Python and Binance API
CryptoCurrency Trading Guide - Python and Binance API
Import
client=Client(api_key, api_secret)
client.get_recent_trades(symbol='BNBBRL')
print(transacoes_btc[-1])
account=client.get_account()
for item in account:
# print(item)
forativoinconta
if float(asset["free"]) > 0:
print(active)
client.get_all_orders(symbol='BNBBRL', limit=10)
print(orders)
client.get_my_trades(symbol='BNBBRL')
print(trades)
Create an order
from binance.enums import *switch to binance_mod if you encountered an error using your library
order=client.create_order(
BNBBRL
side=SIDE_SELL
type=ORDER_TYPE_MARKET,
quantity=0.01
print(order)
client.get_symbol_info('BNBBRL')
print(info)