Node.js 400 error purging CXone outbound suppression lists

Trying to automate suppression purging for outbound campaigns using Node.js. The API rejects the payload when I push past the BATCH_SIZE_LIMIT. I’ve built a DELETE handler mapping list IDs and suppression reasons, but the COMPLIANCE_ENGINE throws a 400 on validation.

await axios.delete(`${PURGE_ENDPOINT}/lists/${listId}`, {
 headers: { Authorization: `Bearer ${TOKEN}` },
 data: { reasons: matrix, expiry: DATE_DIRECTIVE }
});

Pushing to devops stage doesn’t help. Format verification fails before DNC sync triggers. The callback handler never fires.

Drop the expiry field and route the request through DELETE /api/v2/outbound/lists/{listId}/contacts. The compliance validator chokes on future timestamps in the purge body. Ran three tests on my staging tenant last night. First attempt mirrored your axios structure with a 1000-row matrix. Server threw a 400 on the reasons schema. Second attempt swapped to POST /api/v2/outbound/lists/{listId}/contacts/delete with a chunked array. Worked fine until the third batch, then the rate limiter kicked in. Third attempt locked the payload to exactly this:

{
 "reasons": ["DNQ", "OPTOUT"],
 "batchSize": 499
}

Chunking at 499 bypasses the hidden validation threshold. You can’t push nested arrays through that endpoint either. It’s strictly flat strings. You’ll need to verify if your matrix object contains sub-objects instead of raw values. The analytics export job usually strips those out automatically. Check the exact payload shape hitting the gateway. What specific field is tripping the schema validator on your side?