Problems getting Json key

Hi, everyone!

I have this issue we couldn´t figure it out. So… I have this Json that I get from the uipath API, asking for a number of queue items , so far so good. The problem is: when I try to get the value from “@odata.count” it doesnt seem to recognize the @ when I use SelectToken. Before you ask: I´ve tried with different names, removed the “@” (this actually works) but since I dont think its a good practice, I´d like to know if there ´s a better way. Thank you in advance.

Hi @domingo.ruiz

Please use this JsonObject(“@odata.count”).ToString after deserializing

Or JsonObject.GetValue(”@odata.count").tostring


Thank you, Anil_G! That worked!

1 Like

Hi @domingo.ruiz,

Alternatively, if you do not want to use “@” most often such count values are actually refering to some statistics of the return value.

I am suspecting your “value” key there is a Jarray with 30 items.

Another way for getting the value “30” will be to count the length of the Jarray.


Exactly! We used that same method, we did an array.count and had the same result. Thank you to both of you

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.