Asterisk guy
2005-Oct-23 03:40 UTC
[Asterisk-Users] How to play a voice file for " decline "
When get sip respond 6xx ( such as 603 decline), I want asterisk to play a voice file to the caller, how to do this in extensions ? for example, when get 603 respond, play decline.gsm to caller when get 604 respond, play doesnot-exit.gsm to caller when get 606 respond , play not-acceptalbe.gsm to caller
Eric "ManxPower" Wieling
2005-Oct-23 05:12 UTC
[Asterisk-Users] How to play a voice file for " decline "
Asterisk guy wrote:> When get sip respond 6xx ( such as 603 decline), I want asterisk to > play a voice file to the caller, how to do this in extensions ? > > for example, when get 603 respond, play decline.gsm to caller > when get 604 respond, play doesnot-exit.gsm to caller > when get 606 respond , play not-acceptalbe.gsm to callerYou can't. You can check the value of DIALSTATUS, but that does not directly map to SIP responses. chan_sip MAY set HANGUPCAUSE with more information, but it's still not a 1-to-1 mapping with SIP responses.