Assistance Needed with customer.end Trigger Event Configuration

Hello All

I am reaching out to seek assistance regarding an issue I am encountering while working with PureCloud and configuring trigger events, specifically concerning the event v2.detail.events.conversation.{id}.customer.end.

My objective is to trigger a workflow based on the interaction duration time and outbound direction. However, I am facing a challenge due to missing attributes in the Event Schema. The issue pertains to the lack of specific attributes that would allow me to differentiate between multiple caller IDs (multi-outbound trunk) and specify that the workflow should only activate when the agent calls with a particular caller ID.

While I understand that utilizing the ANI (Automatic Number Identification) could be a solution, it presents a problem in the context of outbound calls where the ANI displays the Agent SIP ID rather than the outbound number.

I have explored the Event Schema thoroughly, but unfortunately, I couldn't find attributes such as "remote" or "participantName" or "remoteNameDisplayable" that would display the outbound number.

Given these circumstances, I am seeking guidance or suggestions on how to overcome this limitation. Is there an alternative approach or workaround that I should consider?

Thank you

I understand that by utilizing the Genesys Cloud Platform API can achieve this, but it's not feasible to call the get conversation API for each outbound call

In what way is it not feasible?

I have used triggers for customer.end but the trigger schema does carry limited data.
I tend to use the conversationId, with a data action(s) to grab extra information directly from the API conversation data to use inside the target workflow.

You may need to trigger workflows for all the OUTBOUND direction, you can add more filters, e.g. divisionId(s) to reduce the number of invocations of the workflow.

Once in the flow though you can grab the other data for your business rules and decide in flow logic whether you need to process the interaction, or just end the flow.

Yes, I'm currently working on that. Can I inquire if PureCloud counts internal API usage on the bill?
also ,I'm encountering another issue—I'm unsure if it's a bug in PureCloud or not. The trigger 'v2.detail.events.conversation.{id}.customer.end' executes the workflow twice !

The flow being executed twice likely means that there are two separate v2.detail.events.conversation.{id}.customer.end messages during the life of the conversation that match your trigger match criteria.

Your workflow needs to be tolerant of being called multiple times, as triggers are designed to run "At least once".

Ideally you could find the two messages, and add an additional match criteria so that your workflow only runs once. If that doesn't work, you can try adding a conversation attribute in your workflow and then filter out events that include that attribute. If the two events happen very rapidly you may not finish adding the attribute prior to the second workflow starting.

--Jason