Hi all, we’re trying to push call data into a third-party system using a Data Action in Architect, triggered from a Zoom Contact Center flow. The connector is configured with a POST request to https://api.example.com/v1/calls. It’s a pretty standard setup - OAuth is working, the connection test passes. However, the Data Action keeps failing with a 400 Bad Request. The error message from the third-party API is “Invalid type for field ‘call_duration’ - expected integer, got string.” I’m looking at the event mapping in the Data Action config, and the ‘call_duration’ field is coming through as a number from Genesys Cloud. The connector seems to maybe be changing it?
The mapping itself looks okay. I’m mapping call.callDuration (is that the right property name?) to call_duration on the target system. I’ve tried setting the target field type in the connector to “string” just to see if it will accept it, but then the error becomes “Invalid format for field ‘call_duration’ - expected ISO 8601 duration, got string”. It’s very strange. Here’s the relevant part of the Workato recipe log - it’s not super helpful.
2024-02-29 10:32:00 UTC - INFO - Executing Data Action: POST to https://api.example.com/v1/calls
2024-02-29 10:32:00 UTC - DEBUG - Request payload: {"call_id":"12345", "call_duration":"PT1M30S", "agent_id":"67890"}
2024-02-29 10:32:00 UTC - ERROR - Data Action failed with status code: 400
2024-02-29 10:32:00 UTC - ERROR - Error message: Invalid type for field ‘call_duration’ - expected integer, got string
I’m not sure what’s going on with the duration format. Maybe something with how Workato is passing it through?