API filtering on logs Level not working

Hi!

I’m trying to filter the logs on level but none of my attempts seems to work.

A simple query on TimeStamp like this works perfectly: UiPath

But when I filter on Level it completely ignores the filter and show all Levels:
UiPath. Also without quotes it complains that: “Invalid OData query options.”.

In my project I need filtering (i put some spaces to not create link):
https:// cloud.uipath. com/foo/default/orchestrator_/foo/default/orchestrator_/data/RobotLogs?%24filter=JobKey eq 9a312…01eee and Level%20eq%20’Error’.

Any idea why this isn’t working?

Thanks in advance.

Hi,

take a look at the documentation: OData Version 4.01. Part 1: Protocol (oasis-open.org)

For example this should work:
filter: date(2021-01-01T10:10:36.08Z) eq date(TimeStamp)
or
odata/RobotLogs?$filter=date(2019-07-23T10%3A10%3A36.08Z)%20eq%20date(TimeStamp)

Gio

Hi Friend!

Thank you for your answare but my problem is not in Timestamp Filtering, my problema is Level Filtering (Info, Error, etc…), Timestamp Filtering Works Perfectly but Level Filtering don’t work.

Thanks in advance.

Hi,

ok, I tried to copy your query and it doesn’t work in my Orchestrator too. Now maybe the single quote mark seems wrong because I used ’ (ASCII 39) and your ’ is (ASCII 8217).

In my case work something like that:
odata/RobotLogs?$filter=Level%20eq%20’Error’%20or%20Level%20eq%20’Trace’&$top=20

Regards, Gio

Hi Friend!

Thank you for reply. I too use ’ (ASCII 39), maybe the input of forum replace to ’ (ASCII 8217), but I tried with ’ (ASCII 8217) and return “Invalid OData query options.”, with ’ (ASCII 39) the filter ignore $filter=Level%20eq%20’Error’ and return All Levels (info, error, etc…)… I believe that have any bug in Commands of Filter System, for example I discovery that filter ignore TWO filters comannds: odata/RobotLogs?$filter=TimeStamp gt 2021-02-05T00:00:00.000Z and JobKey eq 9a312…01eee, they ignore TimeStamp and return Just Logs with same JobKey in any date time…

Thanks in advance.

Hi @Marco_HVS

Could you share your version of Orchestrator?

Hi!

My Orchestrator is 2019.10.14.

Hi!

The TimeStamp filter also does not work:

…?$orderby=TimeStamp desc&$top=1000&$filter=ProcessName eq ‘MyProcess’ and RobotName eq ‘Robot’ and TimeStamp ge 2021-03-05T08:00:00.000000Z

It returns all results with the process and the robot name but completely ignores the TimeStamp… I tried ge, gt and eq and it didn’t work…

Can you help me?

Thank you.

@loginerror - Can you help me? Thank you.

Hi @Marco_HVS and sorry for late reply. One thing to get out of the way would be that in the case you are an enterprise customer, you can always contact our technical support for direct assistance via this form:

This guarantees you the timely response and I would suggest it even now. I believe some filters are basically not fully supported (either on your specific Orchestrator versions or overall), but our support will be able to provide you more information about it as well.

Hi @loginerror! Sorry for late reply, I contacted de technical support and was instructed to follow the “Maintenance Considerations”, but anyway I will update my Orchestrator Version. Thank you @loginerror and @q.gio for your support.

1 Like

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