Deivid.Araujo | 2020-12-29 16:13:34 UTC | #1
Hey guys, hope you're doing well.
Anyone know a viable way to programmatically get the schedules form the WFM?
I'm trying to get the schedule so I can compare with login-logout data from another system we have.
Thanks in advance
Deivid Araujo
anon11147534 | 2020-12-29 17:15:59 UTC | #2
Hi,
To get schedules via business unit use api/v2/workforcemanagement/businessunits/{businessUnitId}/agentschedules/search or via management unit use /api/v2/workforcemanagement/managementunits/{muId}/agentschedules/search
Deivid.Araujo | 2020-12-29 20:35:26 UTC | #3
anon11147534, post:2, topic:9609
/api/v2/workforcemanagement/managementunits/{muId}/agentschedules/search
Hi ronan, thanks for the quick reply.
I tried these endpoints but they require a userId to retrieve the data, because when I send the following object:
{ "startDate": "2020-12-01T00:00:00", "endDate": "2020-12-25T23:59:00" }
It returns this:
{ "status": "Complete", "operationId": "9bcf2b65-60ad-41af-88d5-f3d54c22aab1", "result": { "agentSchedules": [], "businessUnitTimeZone": "America/Sao_Paulo", "publishedSchedules": [] } }
Anyway, I think I did not asked the question properly. I'm trying to find a way to get the minutes length of each activity code of a given schedule, then I can sum them and get the time that the agent supposed to work on that day.
Today, we are making this manually in the Workforce management > Schedules tab, but it takes a long time because we have multiple bussiness unit and our schedules are divided 4 in weeks, so for each week we have to download data from all the bussiness units.
Hope It's more clear now.
Thanks in advance
Deivid Araujo
anon11147534 | 2020-12-30 12:29:36 UTC | #4
To get a list of agent userIds you can do the following:
- /api/v2/workforcemanagement/businessunits to get a list of all business units.
- /api/v2/workforcemanagement/businessunits/{businessUnitId}/managementunits to get all management units in the business unit.
- /api/v2/workforcemanagement/managementunits/{muId}/users to get all users in the management unit.
system | 2021-01-29 12:29:38 UTC | #5
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
This post was migrated from the old Developer Forum.
ref: 9609