Buy orders don't always work in the sandbox exchange?

I am working on an app that makes purchases via the API on the sandbox market. Most of the time, when I make a purchase, I will get back something like this:

{:filled_size 0, :stp dc, :product_id BTC-USD, :time_in_force GTC, :fill_fees 0, :executed_value 0, :type limit, :size 0.02265622, :settled false, :status pending, :id 58fe4fbb-3f09-492b-beb4-463499ef41ba, :side buy, :post_only false, :price 22069, :created_at 2022-08-11T05:48:25.284541Z}

Which looks right to me, but I turn around try and get that order by id, I get a 404. If I get all orders, I see other orders, but not the new one.

The reason I think this is not just an error in my code, is that sometimes it works.

What would cause a pending order to simply disappear?


I thought maybe it had something to do with Self-trade prevention, but I don’t have any open orders… so it can’t be that, right?

Hi @lucasjordan ! Welcome to the forum. As you might know, while Sandboxes are a great way of testing, they can also be unstable at times, and this might happen due to several reasons such as the Sandbox server not validating the orders and so unrealistic orders being put into place, affecting placing market orders, etc. Besides that, please note that not all functionalities present on our Pro/Exchange API will be available on the Sandbox for testing. We appreciate your patience and understanding.

1 Like