Intercom using PJSIP and multiple phones

I understand that the following code will do an intercom:

[code]exten => 100,1,Dial(PJSIP/alice,b(pagehandler^addheader^1))

exten => addheader,1,Set(PJSIP_HEADER(add,Alert-Info)=)[/code]
That works fine, but what if we have multiple phones registered to the alice line and are using

exten => 100,1,Dial(${PJSIP_DIAL_CONTACTS(alice)},b(pagehandler^addheader^1))

exten => addheader,1,Set(PJSIP_HEADER(add,Alert-Info)=)[/code]
That will only intercom with one of the phones. Is it possible to break out the PJSIP_DIAL_CONTACTS to add the header to each one? If so, I’m just not seeing how to do this.

I’ve worked on this a little more. I’ve got some manual things down. For example:

exten => 129,1,NoOp
	same => n,NoOp(${PJSIP_DIAL_CONTACTS(${EXTEN})})
	same => n,Page(Local/1@page-129&Local/2@page-129)

exten => 1,1,Dial(PJSIP/129/sip:129@,,b(handler-intercom^addheader^1))
exten => 2,1,Dial(PJSIP/129/sip:129@,,b(handler-intercom^addheader^1))

exten => addheader,1,Set(PJSIP_HEADER(add,Alert-Info)=<ring-answer>)

Obviously this only works because I (a) know what phones have line 129 registered and (b) know the IP address of the phones.

In my NoOp command, I can see the extensions and I know enough about variables to be able to extract them, but I don’t know how to convert that into dial statements. If I were to guess, real-time would have to be used here.

I hope that I’m going down the wrong path and there is something I’m missing that makes this easier, or maybe it’s just not possible at this time.

Of course, I may be completely offbase on my use case for this. I haven’t thought that part through yet. In the end, I may not NEED to do this, but I’d still like to know how. You never know what the future brings.