Change an unfilled entry order
amend_entry_orderChange the price, size, stop-loss or take-profit of an entry that has not filled: a limit order or a trigger entry. The new terms pass every check of a new order; a limit order is replaced (losing its queue place), a trigger entry rewritten. Use when the user moves an entry. Not for a held position's stop (use tighten_stop_loss) or take-profits (set_take_profits). Inputs: order_id, symbol, venue, and what changes. Needs trade:execute: if your orders wait for a person's approval, cancel and preview again instead. Next: get_my_open_orders.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"order_id": "<order_id>",
"symbol": "<symbol>"
},
"name": "amend_entry_order"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| price | No | New limit price, or new trigger price for a trigger entry, USD per coin | |
| venue | No | Venue: sandbox, hyperliquid, okx, bybit or binance. Omitted: the agent's only venue, else hyperliquid if connected, else your only connected exchange, else the sandbox | |
| symbol | Yes | Base coin, e.g. BTC | |
| order_id | Yes | An unfilled entry from get_my_open_orders: a limit entry's order id, or req_… for a trigger entry | |
| size_base | No | New size in the base coin | |
| stop_loss | No | New stop-loss, USD per coin | |
| take_profit | No | New take-profit, USD per coin |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | False when rejected or failed | |
| fee | No | Once executed: the trading fee, estimated at once and replaced by the amount the exchange charged once its fill records show it | |
| legs | No | A ladder entry: per leg {price, size_base, order_id, sl_oid, status}; status resting, or after a refused leg withdrawn, filled or partly_filled | |
| error | No | Why it was rejected or failed | |
| venue | No | Venue name | |
| checks | No | Checks run at execution | |
| sl_oid | No | Venue order id of the protective stop | |
| status | Yes | pending_approval, armed (a trigger entry waiting for its price), executed, rejected, failed, expired, declined, cancelled, or executing (TradeHub has not confirmed the outcome yet: check get_order_status) | |
| receipt | No | Signed receipt (compact JWS, EdDSA) once executed: request, checks, preview price, fill, slippage, order ids, delegation. Verify with /.well-known/tradehub-receipts.jwks | |
| order_id | No | Venue order id of the fill | |
| cancelled | No | cancel_order with all_waiting_entries: the order ids withdrawn (venue ids and req_… trigger entries); [] when nothing was waiting | |
| fill_price | No | Average fill, USD per coin | |
| request_id | Yes | Order request id; get_order_status(request_id) follows it | |
| deprecation | No | Present only while this tool is deprecated: replacement, removal_date, changelog | |
| filled_size | No | Filled size, in the base coin (e.g. BTC), not USD | |
| take_profits | No | set_take_profits: the take-profits now on the exchange | |
| trigger_price | No | status armed: opens at market when the mark reaches this, USD per coin | |
| trigger_expires_at | No | status armed: when it lapses unless reached, ISO 8601 UTC | |
| approval_expires_at | No | While pending: when the approval request lapses, ISO 8601 UTC |