# Order filled or rejected feature?

**URL:** <https://community.tradovate.com/t/order-filled-or-rejected-feature/2937>\
**Category:** Community Support\
**Created:** [August 22, 2021, 11:11am UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937 "2021-08-22T11:11:02Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nikolay\_Georgiev](https://avatars.discourse-cdn.com/v4/letter/n/d26b3c/32.png) [@Nikolay\_Georgiev](https://community.tradovate.com/u/Nikolay_Georgiev)\
**Post date:** [August 22, 2021, 11:11am UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/1 "2021-08-22T11:11:02Z")

</div>

Hello,  
I have created a system to send trades to tradovate but from list of around 300 trades there were one that was ‘rejected’ and still the system returns only ‘orderID’ : ‘XXXXXXX’. I am wondering is it possible for you to add the feature when returning orderID to have also ‘fill’: ‘filled’ or fill: ‘rejected’ (or something similar) that way it will be more convinient to check and retry in case it is rejected.

Regards,  
Nikolay

---

<div class="post-metadata">

**Author:** ![Alexander](https://sea1.discourse-cdn.com/flex015/user_avatar/community.tradovate.com/alexander/32/988_2.png) [@Alexander](https://community.tradovate.com/u/Alexander)\
**Post date:** [August 23, 2021, 2:14pm UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/2 "2021-08-23T14:14:09Z")

</div>

Hello @Nikolay_Georgiev,

Using the `orderId` field from the returned object, you can call the `fill/deps` API endpoint to get the fills related to that order. You can read about it [here](https://api.tradovate.com/#operation/fillDependents).

---

<div class="post-metadata">

**Author:** ![Nikolay\_Georgiev](https://avatars.discourse-cdn.com/v4/letter/n/d26b3c/32.png) [@Nikolay\_Georgiev](https://community.tradovate.com/u/Nikolay_Georgiev)\
**Post date:** [August 23, 2021, 8:04pm UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/3 "2021-08-23T20:04:36Z")

</div>

I hope that I am not disturbing you but I tried sending get request to [https://demo.tradovateapi.com/v1/fill/deps?orderId=XXXXXXXX](https://demo.tradovateapi.com/v1/fill/deps?orderId=XXXXXXXX) but it returns string(0)  
And I am not really sure about my logic but why would I need to call a second request to check if my order is filled or rejcted since the response can give me that informtion

---

<div class="post-metadata">

**Author:** ![Alexander](https://sea1.discourse-cdn.com/flex015/user_avatar/community.tradovate.com/alexander/32/988_2.png) [@Alexander](https://community.tradovate.com/u/Alexander)\
**Post date:** [August 23, 2021, 8:06pm UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/4 "2021-08-23T20:06:38Z")

</div>

Try using `masterid` as the query parameter instead of `orderId` - use the `orderId` value but make the request `?masterid=XXXXXXXXX`

---

<div class="post-metadata">

**Author:** ![Nikolay\_Georgiev](https://avatars.discourse-cdn.com/v4/letter/n/d26b3c/32.png) [@Nikolay\_Georgiev](https://community.tradovate.com/u/Nikolay_Georgiev)\
**Post date:** [August 29, 2021, 10:59pm UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/5 "2021-08-29T22:59:50Z")

</div>

Ok and the response is string(232) “[{“id”:XXXXXXXX,“orderId”:XXXXXXXX,“contractId”:XXXXXXXX,“timestamp”:“2021-08-29T22:55:52.949Z”,“tradeDate”:{“year”:2021,“month”:8,“day”:30},“action”:“Buy”,“qty”:1,“price”:4507.5,“active”:true,“finallyPaired”:0,“external”:false}]”

How do I know if it is filled or rejected ?

---

<div class="post-metadata">

**Author:** ![Alexander](https://sea1.discourse-cdn.com/flex015/user_avatar/community.tradovate.com/alexander/32/988_2.png) [@Alexander](https://community.tradovate.com/u/Alexander)\
**Post date:** [August 30, 2021, 12:41pm UTC](https://community.tradovate.com/t/order-filled-or-rejected-feature/2937/6 "2021-08-30T12:41:37Z")

</div>

Instead you can use the `order/item` endpoint (docs [here](https://api.tradovate.com/#operation/orderItem)) and check the `status` field. Use the same `orderId` from the original response as the `id` query parameter.
