Is there a way to automatically set to available from Missed state in amazon connect CCP?

0

Is there a way to automatically set to available from Missed state on CCP?

preguntada hace un año905 visualizaciones
2 Respuestas
1

I would caution to do this as the call will keep sending to this agent if this person is the only one around but stepped out. This will also cause a lot of routing decision rules to break if you are checking if there are any agents available to take calls before putting the call in queue.

There is a downside to use Stream API if the browser crashed as it changed to missed.

Another way to do this is monitoring Agent Event Stream, for Agent State to be MISSED. A new API has been made to resolve this DismissUserContact:

https://docs.aws.amazon.com/connect/latest/APIReference/API_DismissUserContact.html

in the Agent Event Stream you will get both the contactID and the AgentID which is what you need to set the agent back.

Again, not something you should do unless you know the agent condition and environment through some telemetry check of your agent physical status potentially through their headset if it give telemetry data like Jabra

profile pictureAWS
respondido hace un año
0

If an agent has Desk phone configured to ring their cell phone and miss a call, then they have to log into Amazon Connect and click Close contact in the soft phone before they can receive another call. To get around this, use a Lambda function to close those contacts. In a Flow, Check staffing for Status: Available. If it is False, then Invoke AWS Lambda Function to dismiss contacts.

import { ConnectClient, DismissUserContactCommand, GetCurrentUserDataCommand } from "@aws-sdk/client-connect";

const connectInstanceId = 'YOUR_AMAZON_CONNECT_INSTANCE_ID';

const client = new ConnectClient();

export const handler = async(event) => {
  let numDismissed = 0;
  
  try {
    let data = await client.send(
      new GetCurrentUserDataCommand({
        Filters: {
          ContactFilter: {
            ContactStates: [
              'MISSED', 'ERROR', 'ENDED', 'REJECTED'
            ]
          },
          Queues: ['YOUR_QUEUE_ARN'],
        },
        InstanceId: connectInstanceId
      })
    );
    
    for (const user of data.UserDataList) {
      for (const contact of user.Contacts) {
        await client.send(
          new DismissUserContactCommand({
            ContactId: contact.ContactId,
            InstanceId: connectInstanceId,
            UserId: user.User.Id
          })
        );
        numDismissed++;
      }
    }
  } catch (err) {
    console.log("Error", err);
  }

  const response = {
    statusCode: 200,
    body: JSON.stringify(`Contacts Closed: ${numDismissed}`)
  };

  return response;
};
profile picture
respondido hace 6 meses

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas