I'm experiencing inconsistent behavior when trying to retrieve failed executions with status codes between 1800-1900 through the API.
What I've Discovered
When I manually trigger an error and check the run ID, I can see the failure details:
json
{
"name": "APP.DB.LIST.UPDATE",
"type": "JOBS",
"queue": "CLIENT_QUEUE",
"run_id": 121710216,
"status": 1800,
"status_text": "ENDED_NOT_OK - aborted",
"runtime": 0,
"activation_time": "2025-04-25T15:25:55Z",
"start_time": "2025-04-25T15:25:56Z",
"end_time": "2025-04-25T15:25:56Z",
"agent": "SQL_MSSQL",
"platform": "SQL",
"parent": 0,
"reference_run_id": 0,
"user": "USER",
"estimated_runtime": 1,
"alias": "APP.DB.LIST.UPDATE",
"activator": 120871956,
"activator_object_type": "USER"
}
However, when I attempt to query for this same execution using:
...v1/1010/executions?status=1800&time_frame_from=2025-04-25T15:25:55Z
I get an empty result:
json
{
"total": 0,
"data": [],
"hasmore": false
}
When running without parameters, I receive 827 executions, which seems accurate.
Potential Issues
- Could there be a misconfiguration in some setting that's affecting the status filter?
- I've also noticed the API doesn't seem to return executions that don't have a "Start Time" - for example, if the execution failed before even starting.
Has anyone encountered similar behavior or can suggest what might be wrong with my approach?