Hi everyone.
I have a problem that I’ve been struggling with all morning to solve.
but I haven’t figured it out.
basically I want to differentiate the ringtones of snom phones between internal and external.
I use PJSIP so I have to use pjsip_header.
I have inserted this in my dialplan.
same => n,Set(PJSIP_HEADER(add,Alert-Info)=http://www.notused.com ;info=internal;x-line-id=0)
same => n,Dial(PJSIP/101,30)
same => n,Hangup()
but it seems that the PJSIP_HEADER doesn’t work.
in the invite to the phone, I don’t find anything.
as if asterisk refused to send the packet.
where am I going wrong?
thanks everyone
PJSIP_HEADER must be run on the B leg channel. In practice this means you must run it from the pre-dial subroutine for the Dial application (“b” option). You currently do not have one configured.
You need to use a Dialup handler (with Dial’s b option) and use PJSIP_HEADER from within this handler.
Le jeu. 20 mars 2025 à 12:57, bolognani via Asterisk Community <notifications@asterisk.discoursemail.com > a écrit :
Hi everyone.
I have a problem that I’ve been struggling with all morning to solve.
but I haven’t figured it out.
basically I want to differentiate the ringtones of snom phones between internal and external.
I use PJSIP so I have to use pjsip_header.
I have inserted this in my dialplan.## same => n,Set(PJSIP_HEADER(add,Alert-Info)=http://www.notused.com ;info=internal;x-line-id=0)
same => n,Dial(PJSIP/101,30)
same => n,Hangup()
but it seems that the PJSIP_HEADER doesn’t work.
in the invite to the phone, I don’t find anything.
as if asterisk refused to send the packet.
where am I going wrong?
thanks everyone
Visit Topic or reply to this email to respond.
You are receiving this because you enabled mailing list mode.
To unsubscribe from these emails, click here .
jcolp
March 20, 2025, 12:07pm
4
The documentation site[1] has an example.
[1] PJSIP_HEADER - Asterisk Documentation