ARI Create Channel - PJSIP Multi Endpoints

I want to create an outbound call via ARI, and this works fine if my PJSIP Endpoint is only registered on one device.
But when i use multiple Endpoints only one of them rings.

Extension PJSIP:4@ is registered on my Softphone and my Hardphone

POST Request: pbx.lan:8088/ari/channels
endpoint: PJSIP/4
extension: numberIWantToCall

When i execute this only one of my two registered ends ring.

How can i call all registered Endpoints?

There is no easy mechanism from ARI to do this. The quickest is probably to create some dialplan logic that accepts an endpoint name and then uses Dial with the PJSIP_DIAL_CONTACTS dialplan function. You can then use a Local channel in ARI and call all registered contacts.

I could solve my problem now by replacing PJSIP/4 with local/4
this way all endpoints ring.

(I´m not very experienced with Asterisk, so i don´t know if my solution only works because i use FreePBX with asterisk)

Hello Joshua,

this issue is related to your ticket

Do you think you could push that up. Looks like it’s a wanted missing feature in ARI.

Thanks !!!

I’ve already pushed it up for Sangoma, but that doesn’t mean it will be worked on anytime soon.

Thanks Joshua !!

Meanwhile we’ve found a way to use it inside ARI. I’m leaving it here as a reference.

  • First we get the AOR uris, like ricardo@ and ricardo@
  • Then we format it as PJSIP/ricardo/sip:ricardo@
  • Then you can originate as many channels as contacts using that string
1 Like

If I understand what you are asking, I do this:

context all_phones {
    all => {

and then my single endpoint that I can use to ring foo and bar is Local/all@all_phones.

Not sure how correct this all is. Happy to take suggestions if it can be improved.