Get Run Ids by Schedule Id

Description

'Get Run Ids by Schedule Id' returns a list of all the runs of a schedule, specified by the ScheduleId. The runs are returned as a list of RunIds, which can be used to pull detailed information about an individual run of a schedule.

Request URL

http://{controllerMachine}:{controllerPort}/api/v4/schedules/{scheduleId}/runIds/{filterBy}

Input parameters

Field Type Description Comment
scheduleId string Unique identifier for Schedule scheduleId can be fetched from the response body of the Get Schedule Id
Optional: filter string

Filter to get RunIds

To be specified as:

              ?count={any number >= 0}

e.g. filter count=1 will return the last run.

Available Filters:

NoFilter,
LastMinute,
LastHour,
LastDay,
LastWeek,
LastMonth,
LastYear,
ThisHour,
ThisDay,
ThisWeek,
ThisMonth,
ThisYear,
LastDays

If filter is not defined => filtering is not applied

If the “count“ parameter > 0 => returns the specified number of the last runs, descended by creation date.

For the “LastDays“ filter “count“ parameter is the number of days only.

Examples

Curl

curl -X GET --header 'Accept: application/json' --header 'AccessKey: Mo87Nc4qDAtzJNDb' 'http://{controllerMachine}:{controllerPort}/api/v4/schedules/99b7c050-02bd-4a37-b1d5-8f69ed42ab96/runIds/?count=1'

PowerShell 

$headers = @{}

$headers.Add("AccessKey","Mo87Nc4qDAtzJNDb")

Invoke-WebRequest -Uri "http://{controllerMachine}:{controllerPort}/api/v4/schedules/99b7c050-02bd-4a37-b1d5-8f69ed42ab96/runIds/?count=1" -ContentType "application/json" -Headers $headers -Method GET

Response

Returns list of runIds:

{
    "$id": "1",
    "runIds": [
        "f082a297-3ec0-4310-b46e-38bf422efe43",
        "ba68f389-a324-4a21-b567-d0f00dd30911"
     ]
}

 

Response object

 

Field Type Description Comment
$id string ID of internal object  
runIds Array[string] Array of runIds The runId is a unique Id for the individual run instance of a schedule


Response Code

 

200 (OK)

404 (Not Found)

401 (Unauthorized)

400 (Bad Request)

405 (Method Not Allowed)

500 (Internal Server Error)