question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

There was a fork to add OCO orders to the API. binance.sell('BNBBTC', Qty, Price, {stopPrice: stop_price, type: 'OCO'}, (error, response) => {} When trying to sell, I get a Bad Request response with: Signature for this request is not valid. Any idea where I’m going wrong on this? @gunar

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:1
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
kitt-thcommented, Feb 6, 2020

I couldn’t get a successful testnet test of OCO but on the live net worked fine with this:

binance.order(‘SELL’, ‘BNBBTC’, 1, 0.0029, { type:‘OCO’ , stopLimitPrice: 0.001, stopPrice: 0.001 }, (error, response) => {})

or this:

binance.sell(‘BNBBTC’, 1, 0.0029, { type:‘OCO’ , stopLimitPrice: 0.001, stopPrice: 0.001 }, (error, response) => {})

so I’m happy this works. (my previous error was not having ‘SELL’ in caps I think)

1reaction
berkinalexcommented, Apr 22, 2020

Esa información está incompleta binance.sell(‘BNBBTC’, 1, 0.0029, { type:‘OCO’ , stopLimitPrice: 0.001, stopPrice: 0.001 }, (error, response) => {})

Since OCO orders must have; Symbol, qty, profit and stop-limit, stop-limit

anyone know how to use it? thanks

[SOLUCIONADO GRACIAS]

Read more comments on GitHub >

github_iconTop Results From Across the Web

What Is an OCO Order?
An OCO, or “One Cancels the Other” order allows you to place two orders at the same time. It combines a limit order,...
Read more >
What is OCO Order: OCO Bracket to Place Two Orders
One-Cancels-the-Other (OCO) order, aka a bracket order, allows you to place two orders, for example a limit order and a stop-limit order.
Read more >
OCO and OSO Orders
An OCO (Order Cancels Order) order consists of a group of two or more parallel orders that are linked together in such a...
Read more >
Confused about OCO Orders on Binance? Here's an easy ...
So, to add to this, Binance added a new kind of order called OCO — They call it “One Cancels the Other” order....
Read more >
OCO Orders: How They Can Limit Your Crypto Trading Risk
An OCO order is actually a pair of conditional orders. It specifies that if one order fills, then the other order is automatically...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found