Connect / Client / update_contact_routing_data

update_contact_routing_data#

Connect.Client.update_contact_routing_data(**kwargs)#

Updates routing priority and age on the contact (QueuePriority and QueueTimeAdjustmentInSeconds). These properties can be used to change a customer’s position in the queue. For example, you can move a contact to the back of the queue by setting a lower routing priority relative to other contacts in queue; or you can move a contact to the front of the queue by increasing the routing age which will make the contact look artificially older and therefore higher up in the first-in-first-out routing order. Note that adjusting the routing age of a contact affects only its position in queue, and not its actual queue wait time as reported through metrics. These properties can also be updated by using the Set routing priority / age flow block.

Note

Either QueuePriority or QueueTimeAdjustmentInSeconds should be provided within the request body, but not both.

See also: AWS API Documentation

Request Syntax

response = client.update_contact_routing_data(
    InstanceId='string',
    ContactId='string',
    QueueTimeAdjustmentSeconds=123,
    QueuePriority=123,
    RoutingCriteria={
        'Steps': [
            {
                'Expiry': {
                    'DurationInSeconds': 123
                },
                'Expression': {
                    'AttributeCondition': {
                        'Name': 'string',
                        'Value': 'string',
                        'ProficiencyLevel': ...,
                        'Range': {
                            'MinProficiencyLevel': ...,
                            'MaxProficiencyLevel': ...
                        },
                        'MatchCriteria': {
                            'AgentsCriteria': {
                                'AgentIds': [
                                    'string',
                                ]
                            }
                        },
                        'ComparisonOperator': 'string'
                    },
                    'AndExpression': [
                        {'... recursive ...'},
                    ],
                    'OrExpression': [
                        {'... recursive ...'},
                    ],
                    'NotAttributeCondition': {
                        'Name': 'string',
                        'Value': 'string',
                        'ProficiencyLevel': ...,
                        'Range': {
                            'MinProficiencyLevel': ...,
                            'MaxProficiencyLevel': ...
                        },
                        'MatchCriteria': {
                            'AgentsCriteria': {
                                'AgentIds': [
                                    'string',
                                ]
                            }
                        },
                        'ComparisonOperator': 'string'
                    }
                }
            },
        ]
    }
)
Parameters:
  • InstanceId (string) –

    [REQUIRED]

    The identifier of the Amazon Connect instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.

  • ContactId (string) –

    [REQUIRED]

    The identifier of the contact in this instance of Amazon Connect.

  • QueueTimeAdjustmentSeconds (integer) – The number of seconds to add or subtract from the contact’s routing age. Contacts are routed to agents on a first-come, first-serve basis. This means that changing their amount of time in queue compared to others also changes their position in queue.

  • QueuePriority (integer) – Priority of the contact in the queue. The default priority for new contacts is 5. You can raise the priority of a contact compared to other contacts in the queue by assigning them a higher priority, such as 1 or 2.

  • RoutingCriteria (dict) –

    Updates the routing criteria on the contact. These properties can be used to change how a contact is routed within the queue.

    • Steps (list) –

      When Amazon Connect does not find an available agent meeting the requirements in a step for a given step duration, the routing criteria will move on to the next step sequentially until a join is completed with an agent. When all steps are exhausted, the contact will be offered to any agent in the queue.

      • (dict) –

        Step defines the list of agents to be routed or route based on the agent requirements such as ProficiencyLevel, Name, or Value.

        • Expiry (dict) –

          An object to specify the expiration of a routing step.

          • DurationInSeconds (integer) –

            The number of seconds that the contact will be routed only to agents matching this routing step, if expiry was configured for this routing step.

        • Expression (dict) –

          A tagged union to specify expression for a routing step.

          • AttributeCondition (dict) –

            An object to specify the predefined attribute condition.

            • Name (string) –

              The name of predefined attribute.

            • Value (string) –

              The value of predefined attribute.

            • ProficiencyLevel (float) –

              The proficiency level of the condition.

            • Range (dict) –

              An Object to define the minimum and maximum proficiency levels.

              • MinProficiencyLevel (float) –

                The minimum proficiency level of the range.

              • MaxProficiencyLevel (float) –

                The maximum proficiency level of the range.

            • MatchCriteria (dict) –

              An object to define AgentsCriteria.

              • AgentsCriteria (dict) –

                An object to define agentIds.

                • AgentIds (list) –

                  An object to specify a list of agents, by user ID.

                  • (string) –

            • ComparisonOperator (string) –

              The operator of the condition.

          • AndExpression (list) –

            List of routing expressions which will be AND-ed together.

            • (dict) –

              A tagged union to specify expression for a routing step.

          • OrExpression (list) –

            List of routing expressions which will be OR-ed together.

            • (dict) –

              A tagged union to specify expression for a routing step.

          • NotAttributeCondition (dict) –

            An object to specify the predefined attribute condition.

            • Name (string) –

              The name of predefined attribute.

            • Value (string) –

              The value of predefined attribute.

            • ProficiencyLevel (float) –

              The proficiency level of the condition.

            • Range (dict) –

              An Object to define the minimum and maximum proficiency levels.

              • MinProficiencyLevel (float) –

                The minimum proficiency level of the range.

              • MaxProficiencyLevel (float) –

                The maximum proficiency level of the range.

            • MatchCriteria (dict) –

              An object to define AgentsCriteria.

              • AgentsCriteria (dict) –

                An object to define agentIds.

                • AgentIds (list) –

                  An object to specify a list of agents, by user ID.

                  • (string) –

            • ComparisonOperator (string) –

              The operator of the condition.

Return type:

dict

Returns:

Response Syntax

{}

Response Structure

  • (dict) –

Exceptions