What are policy logs?
Policy logs help you to understand how dynamic routing decisions are made. The tool helps trace routing outcomes back to policy configurations and context variables.
The benefits of using policy logs include:
- Understanding why certain conversions were routed a specific way
- Narrowing down root causes of errors to policy configurations and context variables
- Diving deep to understand why certain policies execute more often than others
Policy Logs are only available to brands that are upgraded to Conversation Context Service v2. Please talk to your LivePerson account representative (other contact options: chat with us on this page, or message Support) if you want to use this feature and have not been upgraded.
Using policy logs
Policy logs are available under Dynamic Routing and logs start showing up if at least one policy is executed.
Logs are available for conversations for up to 7 days. Specific conversations can be searched by using the ConversationId, which is available in the agent workspace.
For every conversation, the policies appear in the order they were executed. For every policy, the policy-name, execution-result, conditions and actions are shown. Values of context variables passed during policy execution can be viewed by hovering the mouse on variables in the conditions. Knowing runtime context values is very useful for triaging issues or for making improvements.
Errors appear in red, and root cause of errors can be viewed on mouse hover.
Understanding policy states
|The policy execution outcome was TRUE, and the conversation was routed by this policy because the context variables passed at runtime matched those defined in the policy condition.|
|The policy execution outcome was FALSE, and the conversation was not routed by this policy because the context variables passed at runtime did not match those defined in the policy condition.|
|The policy did not execute due to an ERROR. The error can be found by hovering on the context variable that is highlighted in red. An example of an error is a 400 exception in a FAAS function that is used in a policy.|
|The policy was not configured correctly. An example of an invalid policy is passing a number to a context variable that’s expecting a string.|
|The policy was disabled and did not execute.|
The following are common errors that can be deduced using policy logs:
- An intended policy was configured to have invalid conditions when the conversation was routed.
- An intended policy was disabled when the conversation was routed.
- There was an error in custom FAAS logic.
- An intended policy was placed too low in the priority order, and other policies were executed before it.
- An intended policy was disabled at the time the conversation was routed.