PUB wss://ws.aevo.xyz
Edit an existing order REQUEST
id integer Request ID, an arbitrary integer to link requests with responses. Eg. 1 |
op string required Operation code: edit_order |
data.order_id string required Order ID to be edited. Eg. 0x4c43e0ab72a4edb72dfe4b129148899815d816837b9a7e22d964b884834639f8 |
data.instrument string required Instrument ID number. Eg. 12 |
data.maker string required Account's Ethereum address.. Eg. 0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b |
data.is_buy boolean required True for long order, false for short order. Eg. 12 |
data.amount string required Number of contracts. In 6 decimals fixed number. Eg. 1000000 |
data.limit_price string required Order limit price. In 6 decimals fixed number. Eg. 1000000 |
data.salt string required A randomly generated number to guarantee transaction uniqueness. Eg. 12345678 |
data.timestamp string Timestamp used in order signing in UNIX timestamp in seconds.. Eg. 1680249600 |
data.signature string required Hash of order payload signature signed by the account. |
data.post_only boolean Flag to indicate that the order is a maker order, or is immediately rejected if it is a taker order. |
data.time_in_force string Can be set to GTC or IOC (GTC is set by default) |
data.mmp boolean Flag to include the order into MMP (false by default) |
Example
{
"id": 1,
"op": "edit_order",
"data": {
"order_id": "0xa907d8c3037289f5b38c94760c06ae436566e600884d09cbeee2ef2c64b2695d",
"instrument": "11235",
"maker": "0xaaaD4c0fa8287Ca5bCcFf0E71Bf93044De0A3f13",
"is_buy": true,
"amount": "10000000",
"limit_price": "10000000",
"salt": "1",
"signature": "0x8aecd6e002780a08dc623233c4bf26f217d13483bf5d75dba49eb4eda865630631505f3dda0294c4f0b8d6b2357f2c2dc5d3c2106aed6e77e88785a6daf602701b"
}
}
RESPONSE
id integer Response ID, an arbitrary integer to link requests with responses. Eg. 1 |
data.order_id string required Order ID is the hash of the order payload. Eg. 0x4c43e0ab72a4edb72dfe4b129148899815d816837b9a7e22d964b884834639f8 |
data.account string required Account's Ethereum address. Eg. 0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b |
data.instrument_id string required Instrument ID number. Eg. 12 |
data.instrument_name string required Instrument name. Eg. ETH-24DEC22-1250-C |
data.instrument_type string required Type of instrument. Allowed values: OPTION PERPETUAL |
data.expiry string Option expiry in UNIX timestamp in nanoseconds. Eg. 1680249600000000000 |
data.strike string Option strike price. Eg. 2500 |
data.option_type string Type of option contract. Allowed values: call put |
data.order_type string required Order type. Allowed values: limit market |
data.order_status string required Order status. Allowed values: opened cancelled partial filled |
data.side string required Trade side. Allowed values: buy sell |
data.amount string required Amount of contracts. Eg. 12.23 |
data.price string required Price in USD. Eg. 12.23 |
data.filled string required Amount filled. Eg. 10.4 |
data.initial_margin string required Margin required to keep an open order. Eg. 12.23 |
data.avg_price string Average execution price in USD. Eg. 12.23 |
data.created_timestamp string required Created timestamp in UNIX timestamp in nanoseconds. Eg. 1680249600000000000 |
data.timestamp string required Response timestamp in UNIX timestamp in nanoseconds. Eg. 1680249600000000000 |
data.system_type string required System type where the order is created. Orders created via websocket will default to API . |
Example
{
"id": 1,
"data": {
"order_id": "0x4c43e0ab72a4edb72dfe4b129148899815d816837b9a7e22d964b884834639f8",
"account": "0xE9b3a48d15BE316A8e34FAd53fFDFDddf0C3D24b",
"instrument_id": "12",
"instrument_name": "ETH-30JUN23-1600-C",
"instrument_type": "OPTION",
"option_type": "put",
"expiry": "1680249600000000000",
"strike": "2500",
"order_type": "limit",
"order_status": "filled",
"side": "buy",
"amount": "12.23",
"price": "12.34",
"filled": "12.23",
"initial_margin": "12.23",
"avg_price":"12.23",
"created_timestamp": "1680249600000000000",
"timestamp": "1680249600000000000",
"system_type": "API"
}
}