Questions tagged [ccxt]

The CCXT library is used to connect & trade with cryptocurrency / altcoin exchanges & payment processing services worldwide. It provides quick access to market data for storage, analysis, visualization, indicator development, algorithmic trading, strategy backtesting, bot programming, webshop integration and related software engineering. Use with topics related to the CCXT library which unifies a vast amount of crypto exchange APIs into one.

The CCXT library is used to connect and trade with cryptocurrency / altcoin exchanges and payment processing services worldwide. It provides quick access to market data for storage, analysis, visualization, indicator development, algorithmic trading, strategy backtesting, bot programming, webshop integration and related software engineering.

It is intended to be used by coders, developers, technically-skilled traders, data-scientists and financial analysts for building trading algorithms on top of it.

217 questions
1
vote
1 answer

How to retrieve active positions using CCXT library on Kucoin exchange?

I can get all open orders (take profit or stop loss ), but I dont know if some position is "open". Positions = exchange.fetchPositions(symbols = 'SOL/USDT:USDT', params = {}) I get the following error: AttributeError: 'kucoinfutures' object has no…
maxixmo
  • 45
  • 1
  • 6
1
vote
1 answer

CCXT Futues - STOP_MARKET (Python)

I am attemptin to create a STOP_MARKET order on Futures this is my code: def futurePlaceOrder(self, symbol, type, side, amount, price=None, params={}): return = self.binanceFuture.createOrder (symbol, type, side, amount, price, params =…
1
vote
2 answers

How to make SPOT market order on Bybit with ccxt?

I am using ccxt library to work with exchange. Struggling with making market order on Bybit. How it can be fixed? The error i've got is TypeError: Exchange.request() takes from 1 to 3 positional arguments but 5 were given bybit_spot = ccxt.bybit({ …
1
vote
1 answer

ccxt OKEx placing orders

I placed DEMO order on OKEx with amount 246 and price 0.46. When I looked on site, order amount was more than 11k: I fetched info about order: {'info': {'accFillSz': '0', 'avgPx': '', 'cTime': '1652262833825', 'category': 'normal', 'ccy': '',…
ExclMark
  • 33
  • 9
1
vote
1 answer

Leverage not taken into account by Binance with CCXT in Python

I got a little problem with ccxt on Python. I'm (trying) to code a trading bot which takes my custom tradingview signal. So I've been tinkering a little test code which opens a trade on testnet.binance with all my balance avalaible on BTC/USDT and…
Lys
  • 11
  • 4
1
vote
1 answer

CCXT how to refresh prices automatically?

when querying exchange APIs, to get the latest price do I simply keep calling my fetchPrice() method every minute or so? I can get the price once, but is the proper way to update using CCXT to simply keep on fetching? The use case is for a simple…
Busy Bit
  • 11
  • 3
1
vote
1 answer

How can I get specific time periods ohlcv in CCXT bitget?

Even if I type "since" keyword in ccxt bitget, always get only the latest information. The same code worked on ftx, what's the problem? bitget = ccxt.bitget({'apiKey' : self.KEY, 'secret' : self.SECRET_KEY, …
Dr.Kim
  • 11
  • 1
1
vote
1 answer

fetch_balance method in ccxt won't return all assets

As I call the fetch_balance method from kucoinfutures in ccxt, it only returns BTC, not any other assets. Shouldn't there be other assets like USDT or ETH too? Here's the python code: exchange = ccxt.kucoinfutures( { 'apiKey': API_KEY, …
Masih Bahmani
  • 153
  • 2
  • 10
1
vote
1 answer

Fixing a python bot for making it suitable for futures trading on Binance

I am a novice coder who tries to learn and definitely struggle. I trade for almost 10 years and now trying to automate it. Encountered generous "Part Time Larry" and tried to update his code to make it suitable for futures. It can generate signals…
1
vote
0 answers

fetch info of bars by ccxt lib in python return timestamp in time zone incorrect

i fetch_ohlcv and return the data, and in data contains timestamp, and I don't understand why timestamp is in the 0th timezone, while I'm in the 7th timezone i use testnet environment exchange = ccxt.binance({ "apiKey": config.BINANCE_API_KEY, …
1
vote
1 answer

New to Asyncio - I'm trying to implement asyncio with ccxt and i'm getting this error

I'm trying to start simple here just so I can get the hang of this stuff. I understand the premise of asyncio but its so confusing trying to use it with ccxt. Is there any recommended resources besides the asyncio documentation that someone can…
1
vote
1 answer

Pandas: how to divide all values in one DataFrame by the values in another DataFrame?

[EDIT] I actually figured this out, and you can see my answer below. ] Before you reference the other question with almost the same title, I have already looked at it and tried out their solution without luck. I'm not sure exactly what I'm doing…
Jonathon Quick
  • 125
  • 1
  • 1
  • 6
1
vote
0 answers

Binance, ccxt futures, problem about amount in order

I got an interest about ccxt these days, especially futures trade i tried to make a logic and it was fun but I've got a problem to "Setting amount" def binance_long(): order = binance.create_market_buy_order( symbol = symbol, …
1
vote
1 answer

Making transaction with ccxt and python

Cheers mates, I have tried to search how to transfer crypto from exchange to another by using python. I haven't found anything usable. I have found lots and lots of ccxt examples but any of those does not include how to do transfer. Does anybody…
Sparky
  • 57
  • 9
1
vote
1 answer

How do I get the minimum transaction amount with the binance api?

How do I get the minimum transaction amount with the binance api? For example, the minimum purchase price for MANA / USDT and ATOM / USDT is '10 USDT'. The same is true for BTC / USDT. How do I get it from'from binance.client import Client'? I also…
tunaex
  • 11
  • 1
  • 3