Skip to content
This repository was archived by the owner on Mar 4, 2025. It is now read-only.

cancelOrderByClientOid doesn't workΒ #17

@mjwvb

Description

@mjwvb

I'm trying to cancel my order with the custom client order id using rest.Trade.Orders.cancelOrderByClientOid(), but it doesn't do anything.

I was looking in the code, and it seems the function arguments are incorrect:

exports.cancelOrderByClientOid = async function cancelOrderByClientOid({ symbol, tradeType } = {}) {
  return await Http().DEL(`/api/v1/order/client-order/${clientOid}`);
};

Should be something like:

exports.cancelOrderByClientOid = async function cancelOrderByClientOid(clientOid) {
  return await Http().DEL(`/api/v1/order/client-order/${clientOid}`);
};

For now I have to use the unique order id with cancelOrder() as returned by postOrder(), but it's not ideal.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions