POST /v1/orders/preview runs an order without placing it. It takes the same body as placing an order, and nothing is recorded or sent. Use it to:
- check an order is valid, and collect every problem in one call;
- see what it would cost and how far the book would move;
- show a person the outcome before they approve it.
A preview
orderis the order as it would be sized now.estimatewalks the current order book: the average price you would get, how far that is from the mid price in basis points, the value that would fill, and the fee.position_afterandaccount_afterare where you would stand if the order filled as estimated.
When the order would be refused
A preview answers200 for any JSON body. If the order would be refused, valid is false, and errors lists every reason at once, with the same error objects placing it would return: