Shift Swap API 409 Conflict on Overlapping Ranges

Stuck on a 409 Conflict error when calling PATCH /api/v2/wfm/scheduling/shift-swaps to approve a swap.

Background

Automating shift trade approvals for our Chicago team via Python SDK v1.50. The swap involves two agents with identical skill sets.

Issue

The API rejects the request with code: 'conflict' and message: 'Schedule conflict detected'. Both agents are scheduled for the exact same 4-hour block, but the swap is just a name change, not a time change.

Troubleshooting

  • Verified both agents have Available status in WFM.
  • Checked for overlapping time-off requests; none found.
  • Manual approval via UI works instantly, suggesting a validation logic bug in the API payload structure.