Hi all,
We’re running into a weird issue with the ACTIVITY_POINT_OF_CONTACT API. Specifically, creating a new APOC via the /api/v2/wem/activitypointsofcontacts endpoint is failing consistently with a 400 BAD_REQUEST. It’s impacting our ability to onboard new skills-based routing configurations.
Here’s the setup: We’re on Genesys Cloud, US-East region. We’re using the Python SDK, version 2.1.3, to automate APOC creation - we’ve got a scheduled job that updates these whenever new skills are added. It was working fine a couple weeks back.
The error response doesn’t give a ton to go on. It just says “Invalid JSON payload”. I’ve double-checked the payload against the documentation and can’t see anything obviously wrong. The weird thing is, it does validate correctly with a separate JSON schema validator we use for other API calls.
I’ve tried simplifying the payload to the absolute minimum required fields, and it still fails. The logs show the following:
{
"error": "Bad Request",
"message": "Invalid JSON payload",
"code": 400,
"details": {
"type": "invalid_request",
"message": "The request body is not valid JSON."
}
}
I suspect something might be off with how the SDK is serializing the JSON, or there’s some encoding issue happening during the POST request. We’re using standard UTF-8 encoding.
Here’s the Python code snippet:
import requests
import json
url = "https://api.genesyscloud.com/api/v2/wem/activitypointsofcontacts"
headers = {
"Authorization": "Bearer YOUR_TOKEN",
"Content-Type": "application/json"
}
payload = {
"name": "Test APOC - Automation",
"divisionId": "YOUR_DIVISION_ID",
"activityPointType": "SKILL"
}
response = requests.post(url, headers=headers, data=json.dumps(payload))
print(response.status_code)
print(response.text)
I’ve also looked into the WEM CONFIGURATION settings, specifically under the ACTIVITY POINT OF CONTACT section. Everything looks correct there. Worth a shot to check the API documentation again. I’m going to try manually creating an APOC through the UI to rule out a system-wide issue, but wanted to see if anyone else has seen this recently. The API seems very sensitive to the structure of the JSON. The DIVISION_ID and token are valid. I am starting to suspect it may be a parsing issue on the backend.