I'm setting up an event handler to handle new message creation events for all extensions. I'm finding the documentation to not be as specific as I like:
https://developer.ringcentral.com/api-docs/latest/index.html#!#RefCreateSubscription
Specifically, I'm not sure if I can create a single subscription for message events from ALL extensions (WITHOUT using a super admin account). The message store api only allows for message extraction for individual extensions one at a time (without a super admin account). So I can only assume the message events work the same way. And if that is the case, that means that I have to create a separate subscription for each and every extension, correct?
Or, alternatively, can I subscribe to message events using a filter like this:
/restapi/v1.0/account/~/extension/~/message-store
without a super admin account?
My concern is this: If I have to create a separate subscription for each and every extension, what happens when the company adds new extensions? I don't see an event I can subscribe to for when new extensions are added. Which means I'm back to polling for new extensions. Hopefully I can avoid that. That's the point of the sub model.
And it would be just a whole lot easier if I can just create a single subscription for messages for the whole company.
/restapi/v1.0/account/{accountId}/extension"
. It is not a part of public API which is described in documentation today, but you may give it a try. Here is the example of event:{ "timestamp": "2014-04-29T14:29:27.408+0000", "subscriptionId": "a45645-0001-cc71-9de3-674476722", "uuid": "b11c9430-9687-4498-b12b-3fcb470bfe04", "event": "/restapi/v1.0/account/~/extension", "body": { "extensions":[ { "extensionId":"74953947939", "eventType":"Delete" }, { "extensionId":"8798797945", "eventType":"Create" }, { "extensionId":"8475874957", "eventType":"Update" } ] }
}Hope it helps.
A new Community is coming to RingCentral!
Posts are currently read-only as we transition into our new platform.We thank you for your patience
during this downtime.
Try Workflow Builder
Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!Try RingCentral Workflow Builder