Comments (5)
@incafox Ok I think I managed to reproduce the issue, can you please try to provide stop:entry
in params?
result = exchange.create_stop_limit_order(
"DPET/USDT",
side='buy',
amount=100,
price=short_price,
stopPrice=long_price,
{"stop": "entry"}
)
Iif we don't provide it, it will default to loss
and execute if the price <= 0.06 instead of >= 0.06.
from ccxt.
@incafox I think the problem is resolved, so I will close this issue but feel free to reopen it if anything!
from ccxt.
Hello @incafox,
I don't see that option in the WEB UI, so I think it follows the same logic as the API
If the stopPrice is smaller than the current price then the condition will be trigger <=stopPrice, otherwise >=stopPrice
from ccxt.
hello @carlosmiei here in this example using the WEB UI you can see the current price is 0.05396 and I created an Buy Stop-Limit order with stop price->0.06 , price->0.1. So the trigger condition to buy 100 DPET is if the current price >= 0.06 and sell condition is 0.1, you can see that in advanced orders section (screenshot).
Im trying to do the same with CCXT-Kucoin :
long_price = (1.3) * current_price
short_price = (3) * current_price
result = exchange.create_stop_limit_order(
"DPET/USDT",
side='buy',
amount=100,
price=short_price,
stopPrice=long_price
)
So using my example above the enter price(long_price) should be 1.3 * 0.05396 = 0.0701 and short_price = 3 * 0.05396 = 0.161, but unfortunately create_stop_limit_order is buying instantly at the current price instead of setting a trigger condition correctly.
from ccxt.
thank you @carlosmiei !
from ccxt.
Related Issues (20)
- Bitget missing GET /api/v2/earn/account/assets HOT 1
- BITGET create order error HOT 3
- Coinbase - removed symbols cause glitch with orders HOT 4
- Correctly support KrakenFutures positions API HOT 1
- fetchTrades "since" doesn't work for okx, and bybit HOT 3
- Bingx - stoploss orders not parsed correctly HOT 1
- Bingx - parse order price / cost wrong HOT 2
- bitfinex: fetchOHLCV() returns incorrect result HOT 2
- Whitebit: Support for createMarketBuyOrderWithCost HOT 3
- Coinbase - provide an option to use the private methods instead of public methods to reduce rate limit errors HOT 8
- Publish CCXT on JSR - New JS / TS Package Registry HOT 1
- Can't not fetch leverage with binace HOT 5
- Biance watch_ticker response value is None HOT 6
- Binance Portfolio Margin `timeInForce` option `PO` results in no TIF parameter in new order (UM) request HOT 6
- Bitget order subscription duplication. C# HOT 2
- Subscription does not receive any result. C# HOT 2
- Move event handler map from exchange.handle_message to an exchange instance variable HOT 2
- python ccxt fetch_ohlcv on kraken doesnt honor since parameter HOT 9
- Bitget error OHLCV for delivery futures HOT 5
- Coinbase trades pagination cursor HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ccxt.