Skip to main content
Solved

How to subscribe to Message and VoiceMail events at account level?

  • January 26, 2023
  • 2 replies
  • 216 views

We have multiple extensions and numbers and we would like to subscribe to message and voicemail event for all extensions. Is there any way we can do this at account level?


Any help is highly appreciated.

Best answer by PhongVu

There is no account level for SMS and Voicemail message notifications (even with reading). However, as a super admin role, you can subscribe for SMS and Voicemail event notification for other user extensions. You will need to read extensions to get the extension id of all or particular extensions you want to get notifications, then subscribe for the subscription with an array of event filters for the user extensions as shown in the example below.

var eventFilter = [
    /restapi/v1.0/account/~/extension/{extId-1}/voicemail,
    /restapi/v1.0/account/~/extension/{extId-2}/voicemail,
    /restapi/v1.0/account/~/extension/{extId-n}/voicemail,
    ...
    /restapi/v1.0/account/~/extension/{extId-1}/message-store/instant?type=SMS,
    /restapi/v1.0/account/~/extension/{extId-2}/message-store/instant?type=SMS,
    /restapi/v1.0/account/~/extension/{extId-n}/message-store/instant?type=SMS
]
View original
Did this thread help you find an answer to your question?

2 replies

PhongVu
Community Manager
Forum|alt.badge.img
  • Community Manager
  • 2331 replies
  • Answer
  • January 26, 2023

There is no account level for SMS and Voicemail message notifications (even with reading). However, as a super admin role, you can subscribe for SMS and Voicemail event notification for other user extensions. You will need to read extensions to get the extension id of all or particular extensions you want to get notifications, then subscribe for the subscription with an array of event filters for the user extensions as shown in the example below.

var eventFilter = [
    /restapi/v1.0/account/~/extension/{extId-1}/voicemail,
    /restapi/v1.0/account/~/extension/{extId-2}/voicemail,
    /restapi/v1.0/account/~/extension/{extId-n}/voicemail,
    ...
    /restapi/v1.0/account/~/extension/{extId-1}/message-store/instant?type=SMS,
    /restapi/v1.0/account/~/extension/{extId-2}/message-store/instant?type=SMS,
    /restapi/v1.0/account/~/extension/{extId-n}/message-store/instant?type=SMS
]

  • Author
  • Known Participant
  • 11 replies
  • January 26, 2023

Thanks for your help! I appreciate.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings