First of all, if a queue member does not pick up an incoming call, that call is not necessarily a missed call, because the call queue will ring the next members, and it can ring that member again if the queue is set "rotating".
You can detect if a member does not pick up a call by using the telephony session event notification, parse the event payload and check the the call status and reason. See the example events below:
// Member's phone ringing
{
"uuid": "6532554610789882711",
"event": "/restapi/v1.0/account/80964xxxx/extension/6229532xxxx/telephony/sessions",
"timestamp": "2022-07-05T16:18:46.971Z",
"subscriptionId": "54963e56-ff62-46b7-8953-18b9ee0e0b3f",
"ownerId": "6228832xxxx",
"body": {
"sequence": 5,
"sessionId": "860357227016",
"telephonySessionId": "s-a0d7bd0254c3cz181cf282236z3cab8d40000",
"serverId": "10.13.123.208.TAM",
"eventTime": "2022-07-05T16:18:46.939Z",
"parties": [
{
"accountId": "80964xxxx",
"extensionId": "62295327016",
"id": "p-a0d7bd0254c3cz181cf282236z3cab8d40000-3",
"direction": "Inbound",
"to": {
"phoneNumber": "+1209248xxxx",
"name": "demo queue",
"extensionId": "6249888xxxx"
},
"from": {
"phoneNumber": "+1650513xxxx",
"name": "demo queue - SAN MATEO CA"
},
"status": {
"code": "Proceeding",
"rcc": false
},
"queueCall": true,
"park": {},
"missedCall": false,
"standAlone": false,
"muted": false,
"uiCallInfo": {
"primary": {
"type": "QueueName",
"value": "demo queue"
},
"additional": {
"type": "CallerIdName",
"value": "SAN MATEO CA"
}
}
}
],
"origin": {
"type": "Call"
}
}
}
// Member did not answer the call
{
"uuid": "6651780260135284845",
"event": "/restapi/v1.0/account/80964xxxx/extension/6229532xxxx/telephony/sessions",
"timestamp": "2022-07-05T16:19:02.018Z",
"subscriptionId": "54963e56-ff62-46b7-8953-18b9ee0e0b3f",
"ownerId": "6228832xxxx",
"body": {
"sequence": 6,
"sessionId": "860357227016",
"telephonySessionId": "s-a0d7bd0254c3cz181cf282236z3cab8d40000",
"serverId": "10.13.123.208.TAM",
"eventTime": "2022-07-05T16:19:01.942Z",
"parties": [
{
"accountId": "80964xxxx",
"extensionId": "6229532xxxx",
"id": "p-a0d7bd0254c3cz181cf282236z3cab8d40000-3",
"direction": "Inbound",
"to": {
"phoneNumber": "+1209248xxxx",
"name": "demo queue",
"extensionId": "6249888xxxx"
},
"from": {
"phoneNumber": "+1650513xxxx",
"name": "demo queue - SAN MATEO CA"
},
"status": {
"code": "Disconnected",
"reason": "AgentDropped",
"rcc": false
},
"queueCall": true,
"park": {},
"missedCall": false,
"standAlone": false,
"muted": false,
"uiCallInfo": {
"primary": {
"type": "QueueName",
"value": "demo queue"
},
"additional": {
"type": "CallerIdName",
"value": "SAN MATEO CA"
}
}
}
],
"origin": {
"type": "Call"
}
}
}
I don't understand your use case of "kicking out queue members if they don't answer the call" though.
Thank you, I was able to figure this out after enough testing. The use case is basically we don't want agents who are missing calls sitting in our queues since they rotationally ring. It makes the customer wait longer for an agent who actually answers. I've got it figured out now and your answer is what the app is doing now.