How to get the status of queue items from orchestrator uipath forum

Hi, I want to do some work when work item in the queue has status set to “Failed” not “Retried” (Please refer below screenshot)

I tried using transactionitem.status command inside set transaction status, but it’s giving the output as “Failed” even when it’s setting the item in queue as “Retried”.

Is there a way to get this status from orchestrator?


It will give the final status of the queue item and in this case its ‘Failed’. Do you want to check if a particular queue item was retried ? If that’s the case, have you tried TransactionItem.RetryNo?



Use get transaction item and then assign status=transactionitem.status

It will give you the status

Hi, I ran the work item and it threw an application exception, so in orchestrator it was set as “Retried” (retry count in queue is 1, so it’ll retry again) from set transaction status. Inside that I tried getting the status of the work item.

I was expecting it to be “Retried”, but it showed “Failed”

Then it started retrying again. Now instead of this failed message, is there a way to get the work item status (Retried) from the orchestrator? Also retry Number will be changed from retry count 3 or retry count 1 in queue sometimes, so it’s not a constant.

But that’s actually not working, please read below

In the set transaction status activity, you have given the status as failed that’s why it get returned as failed. Use get transaction item after that and get the status.

1 Like


If you see the activity just before your log message, you can see that its changing the status of queue item to ‘Failed’.

Whatever maybe the retry count in orchestrator, if TransactionItem.RetryNo>0, we can conclude that the item is retrying.


Yes, so if the retry count is 2, It’ll do:

Retry 1
Retry 2

Now, I have to do some tasks at the 3rd step, (i.e. Failed), but the set transaction status is setting the status as failed in the studio (even in case of 1st and 2nd retry).

Using Get Transaction Item will make the work item “In Progress” and then logging TransactionItem.Status will also give “InProgress”. So instead of fetching the work item status, it’ll make it as “InProgress”

Hi @manojj.yadav

So as you do not know the max retry here you have two options

  1. use Orchestrator api request to get the queue definition and from that you get the max retry for queue ​/odata​/QueueDefinitions
  2. Store it in asset because only when you create a queue you can set the value so if you are changing change the asset and read it

Now from transactionitem.ReteyNo you will get the current retry number compare it with the max to know if it is the final transaction or if it would be retried

Hope this helps.Let me know if you have any issues


1 Like