buildTpSlDeleteMessage
Build a delete-conditional-order EIP-712 message body (TpSlDeleteMessage). The salt is generated automatically via generateTpSlSalt; pass salt to override (e.g. to sign deterministically in tests). deleteQuoteTpSl uses this internally.
import { buildTpSlDeleteMessage } from "@symmio/trading-core";
const message = buildTpSlDeleteMessage({
virtualAccount,
cohQuoteId: "coh4213",
conditionalOrderType: "take_profit",
});Parameters
virtualAccountAddressrequiredPartyA (the VA address) that owns the quote.
cohQuoteIdstringrequiredHandler-issued conditional-order id targeted by the delete.
conditionalOrderType"take_profit" | "stop_loss"requiredWhich side is being canceled.
saltstringoptionalOverride for the auto-generated salt.
Returns
The delete message body (pre-signature). Pass to signTpSlRequest.
Related
TpSlDeleteMessage— the return shape.deleteQuoteTpSl— the full delete action.
Last updated on