ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

REST API different results in /executions?run_id and /executions/run_id

book

Article ID: 237112

calendar_today

Updated On:

Products

CA Automic Workload Automation - Automation Engine

Issue/Introduction

{{URLROOT}}://{{HOSTNAME}}:{{PORT}}/{{APIURL}}/{{APIVERSION}}/{{CLIENT}}/executions?run_id=1979894 returns:

{
    "total"0,
    "data": [],
    "hasmore"false
}

{{URLROOT}}://{{HOSTNAME}}:{{PORT}}/{{APIURL}}/{{APIVERSION}}/{{CLIENT}}/executions/1979894 returns:

{
    "name""JOBP.33045078",
    "type""JOBP",
    "queue""CLIENT_QUEUE",
    "run_id"1979894,
    "status"1900,
    "status_text""ENDED_OK - ended normally",
    "runtime"0,
    "activation_time""2022-03-17T05:17:18Z",
    "start_time""2022-03-17T05:17:18Z",
    "end_time""2022-03-17T05:17:18Z",
    "parent"0,
    "reference_run_id"0,
    "user""ALEXANDER/SUPPORT",
    "estimated_runtime"1,
    "alias""JOBP.33045078",
    "activator_object_type""USER"
}

Cause

Configuration.

Environment

Release : 12.3, 21.0

Component : AUTOMATION ENGINE

Resolution

The GET call also need &include_deactivated=true.

{{URLROOT}}://{{HOSTNAME}}:{{PORT}}/{{APIURL}}/{{APIVERSION}}/{{CLIENT}}/executions?run_id=1979894&include_deactivated=true

{
    "total"1,
    "data": [
        {
            "name""JOBP.33045078",
            "type""JOBP",
            "queue""CLIENT_QUEUE",
            "run_id"1979894,
            "status"1900,
            "status_text""ENDED_OK - ended normally",
            "runtime"0,
            "activation_time""2022-03-17T05:17:18Z",
            "start_time""2022-03-17T05:17:18Z",
            "end_time""2022-03-17T05:17:18Z",
            "parent"0,
            "reference_run_id"0,
            "user""ALEXANDER/SUPPORT",
            "estimated_runtime"1,
            "alias""JOBP.33045078",
            "activator_object_type""USER"
        }
    ],
    "hasmore"false
}