SAML SSO breaking OAuth client credentials flow for bot API

Quick question, has anyone seen this weird error? with our bot service authentication after enabling SAML SSO for all users in Genesys Cloud. The standard client credentials grant is failing with a 401 Unauthorized response, suggesting the service account is being blocked by the new SAML policy despite having the correct scope.

  • Environment: Genesys Cloud EU
  • Auth Method: Client Credentials Grant (/api/v2/oauth/token)
  • Error: 401 with invalid_grant

Is there a specific configuration to exempt service accounts from SAML enforcement, or does the SDK need a different token endpoint when SSO is active?

Oh, this is a known issue…

SAML policies do not apply to OAuth 2.0 client credentials flows. The 401 invalid_grant usually indicates the client secret was rotated in the vault but not updated in the deployment config, or the service account is locked. Verify the secret matches the current version in HashiCorp Vault.

curl -X POST https://api.mypurecloud.com/api/v2/oauth/token \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -d "grant_type=client_credentials&client_id=YOUR_CLIENT_ID&client_secret=ROTATED_SECRET&scope=bot:read"