Skip to content

Cancel an Order as a Builder

Both L2 (HMAC) credentials and the OPENFISH_BUILDER_ID header must be present.

POST /builder/cancel

Server: https://api.openfish.fun

Authentication: L2 (HMAC) + Builder ID header


HeaderRequiredDescription
OPENFISH_API_KEYYesAPI key (UUID)
OPENFISH_TIMESTAMPYesUnix timestamp
OPENFISH_PASSPHRASEYesAPI passphrase
OPENFISH_SIGNATUREYesHMAC-SHA256 signature
OPENFISH_BUILDER_IDYesBuilder identifier string

Content-Type: application/json

FieldTypeRequiredDescription
orderIdstring (UUID)YesID of the order to cancel
{
"orderId": "0190b317-a1d3-7bec-9b91-eeb6dcd3a620"
}

FieldTypeDescription
canceledarray of stringsOrder IDs that were successfully canceled
notCanceledobjectMap of order IDs to failure reasons
builder_idstringBuilder identifier
{
"canceled": ["0190b317-a1d3-7bec-9b91-eeb6dcd3a620"],
"notCanceled": {},
"builder_id": "my-trading-bot"
}
{ "error": "OPENFISH_BUILDER_ID header required" }
{ "error": "invalid authorization" }