API | Get last log for each robot | Orquestrator 2019

Hi.
i’m trying to get the last log by robot.

I got this far :
https://OrchestratorLink/odata/RobotLogs?$top=1&$filter=RobotName eq ‘NameOfRobot’

This returns a log from August, i know that currently is running a job in that machine, and as been running variously jobs every day.( the logs appear in Orchestrator)

So, how can i get the last log? I can’t find a solution.
Thanks

Hi @fmsimoes

Could you try returning all records, just to see if the latest ones are also returned?

Hi.
i did not mention but already try that and still couldn’t see the most recent, nonetheless i believe was the limitation of the records shown by the API.

Good news, I was able to find a solution :slight_smile:

https://OrchestratorLink/odata/RobotLogs?$top=1&$filter=RobotName eq ‘NameOfRobot’&$orderby=TimeStamp desc

1 Like

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