I am trying to set up an EventBridge rule in AWS to only receive conversation.end events for a specific queue in Genesys Cloud. The goal is to avoid processing every single conversation end in our org, which is creating too much noise in our Lambda function.
I have the EventBridge partner event source configured and it is receiving events. I can see the conversation.end events coming through. However, I am struggling with the EventPattern JSON structure. The documentation for Genesys Cloud EventBridge integration is a bit sparse on the exact schema for filtering.
Here is the event payload I am seeing in CloudWatch for a test conversation:
{
"detail-type": "Conversation End",
"source": "com.genesys.events",
"detail": {
"id": "abc-123-def-456",
"type": "voice",
"queue": {
"id": "queue-id-xyz",
"name": "Support Queue A"
},
"routing": {
"queueId": "queue-id-xyz"
}
}
}
I tried to create an EventBridge rule with this pattern:
{
"detail-type": ["Conversation End"],
"source": ["com.genesys.events"],
"detail": {
"routing": {
"queueId": ["queue-id-xyz"]
}
}
}
The rule is created successfully, but it is not matching any events. I have verified that the queue-id-xyz is correct by checking the Genesys Cloud UI. I also tried filtering on detail.queue.id but that did not work either. The Lambda function is not being invoked when a conversation ends in that specific queue.
Am I missing something in the event structure? Is the routing.queueId field always present for voice conversations? Or is there a different way to filter these events at the EventBridge level instead of filtering inside the Lambda function? Any help with the correct EventPattern JSON would be appreciated.