Skip to main content

Hi Community,

In our appilcation we subscribe to the account telephony session events through webhook.

We observe that sometimes notification comes twice for the same call code. F.ex:

{"uuid":"7777042260982796122","event":"/restapi/v1.0/account/<company_account>/extension/647381065/telephony/sessions","timestamp":"2022-11-08T09:58:34.520Z","subscriptionId":"a3034c8c-7095-4480-bfd5-7b4230832eba","ownerId":"<ownerId>","body":{"sequence":7,"sessionId":"1602332329064","telephonySessionId":"s-a30166b23b631z18456ad370az66dc3b00000","serverId":"10.48.22.107.TAM","eventTime":"2022-11-08T09:58:34.442Z","parties":[{"accountId":"<company_account>","extensionId":"647381065","id":"p-a30166b23b631z18456ad370az66dc3b00000-1","direction":"Outbound","to":{"phoneNumber":"<phone>"},"from":{"phoneNumber":"<phone>","extensionId":"647381065","deviceId":"805212642064"},"status":{"code":"Hold","rcc":false},"park":{},"missedCall":false,"standAlone":false,"muted":false}],"origin":{"type":"Call"}}}
{"uuid":"1120450367869856758","event":"/restapi/v1.0/account/<company_account>/extension/647381065/telephony/sessions","timestamp":"2022-11-08T09:58:34.517Z","subscriptionId":"a3034c8c-7095-4480-bfd5-7b4230832eba","ownerId":"<ownerId>","body":{"sequence":7,"sessionId":"1602332331064","telephonySessionId":"s-a30166f23bcc2z18456ad3726z66fd3a50000","serverId":"10.48.22.111.TAM","eventTime":"2022-11-08T09:58:34.441Z","parties":[{"accountId":"<company_account>","extensionId":"647381065","id":"p-a30166f23bcc2z18456ad3726z66fd3a50000-1","direction":"Outbound","to":{"phoneNumber":"<phone>"},"from":{"phoneNumber":"<phone>","extensionId":"647381065","deviceId":"805212642064"},"status":{"code":"Hold","rcc":false},"park":{},"missedCall":false,"standAlone":false,"muted":false}],"origin":{"type":"Call"}}}

We can see that some fields are different: sessionId, telephonySessionId, serverId etc. So why does it happen? Can it be avoided?

In our internal system we use sessionId field from the notification to group all the notifications that belong to the same call. Since sessionId field can change as in above example there is no reliable way to determine that both belong to the same call.

Best,

Nikolai Chashchin

How often do you see this happens? Do you have a pattern/sequence to reproduce it? I need to reproduce it in my environment to report it to the team. Thanks


Reply