If you just run the GET /api/v2/architect/schedules you get the list of schedules, but it doesn't give you enough information:
{
"id": "bc987c92-8eec-46af-aabd-1f783460d60e",
"name": "AdvSalesOpen",
"state": "active",
"start": "2019-06-14T06:00:00.000",
"end": "2019-06-14T22:00:00.000",
"rrule": "FREQ=WEEKLY;UNTIL=20190630T235959Z;INTERVAL=1;BYDAY=MO,TU,WE,TH,FR",
"keywords": [],
"selfUri": "/api/v2/architect/schedules/bc987c92-8eec-46af-aabd-1f783460d60e"
}
From that return, you then need to use /api/v2/architect/schedules/{scheduleid} to get each individual schedule.
You can't use just the start and end dates to compare. Rather, you have to look at the time specified on the start/end date-time, and look at the rrule setting for the frequency to see what days it applies.
For example, when I query based on the SceduleID I get:
{
"id": "bc987c92-8eec-46af-aabd-1f783460d60e",
"name": "AdvSalesOpen",
"state": "active",
"start": "2019-06-14T06:00:00.000",
"end": "2019-06-14T22:00:00.000",
"rrule": "FREQ=WEEKLY;UNTIL=20190630T235959Z;INTERVAL=1;BYDAY=MO,TU,WE,TH,FR",
"keywords": [],
"selfUri": "/api/v2/architect/schedules/bc987c92-8eec-46af-aabd-1f783460d60e"
}
Start is the date I specified for the schedule to start. End seems to be a bit arbitrary, so the UNTIL in the rrule has to be used to figure out when it actually ends.
In the rrule I can see that it is set for Weekly, to run on weekdays.
Also in the rrule, I can see that it ends on June 30, 2019.
------------------------------
George Ganahl CCXP, GCP
Principal Technology Consultant
Genesys
------------------------------