Having some config trouble here correctly when scaling up concurrent users in our JMeter load test suite. We are based in Singapore and running tests against the mypurecloud.com region. The goal is to validate the stability of the /api/v2/users/me endpoint under high throughput conditions, simulating a sudden spike in agent logins.
The issue manifests specifically when we exceed 50 concurrent threads. Initially, the script runs fine, fetching valid access tokens via the /api/v2/oauth/token endpoint using the client credentials flow. However, as the concurrency increases, a significant portion of the requests start failing with 401 Unauthorized errors. This is confusing because the tokens appear valid when inspected individually, and the expires_in claim is set to 3600 seconds. We are not hitting the standard rate limits (429s), which suggests this might be related to token validation timing or session management under load.
Here is the JSON payload we are sending for the token request:
{
"grant_type": "client_credentials",
"scope": "user:read"
}
And the subsequent GET request headers include:
Authorization: Bearer <access_token>
Content-Type: application/json
The error response body is minimal:
{
"errors": [
{
"code": "401",
"message": "Unauthorized"
}
]
}
We have verified that the service account has the correct permissions. The problem seems to be intermittent. Sometimes 10% of requests fail, other times 50%. We are using JMeter 5.6.1 with the HTTP Request sampler. Is there a known limitation with token caching or validation in Genesys Cloud when dealing with high-frequency requests from the same IP range? Any insights into how to adjust our load test configuration to avoid these false 401s would be appreciated. We want to ensure our capacity planning is accurate and not skewed by authentication failures.