Agent Scripting Timeout During WFM Schedule Publish

Dealing with a very strange bug here with our Agent Scripting flow.

The issue happens right during the weekly WFM schedule publish in Genesys Cloud 2024-3.0.

We have a custom Data Action that triggers an Architect flow to update agent preferences.

This flow uses the Agent Scripting API to inject a welcome message.

The API call to /v2/agent-scripting/scripts/{id} returns HTTP 504 Gateway Timeout.

This only occurs when more than 50 agents are being scheduled simultaneously.

The error logs show a connection pool exhaustion warning.

The WFM publish job eventually succeeds, but the scripting updates fail for half the team.

I checked the Architect trace.

The HTTP request node times out after 30 seconds.

Increasing the timeout to 60 seconds did not help.

The response payload is empty.

This is critical for our shift swap workflow.

Agents need the correct script context before their shift starts.

Is this a known limitation of the Agent Scripting API during high-concurrency WFM events?

Or is there a better way to batch these updates?

Any insights would be appreciated.