PJSIPHangup()¶
Synopsis¶
Hangup an incoming PJSIP channel with a SIP response code
Description¶
Hangs up an incoming PJSIP channel and returns the specified SIP response code in the final response to the caller.
Warning
This function must be called BEFORE anything that might cause any other final (non 1XX) response to be sent. For example calling 'Answer()' or 'Playback' without the 'noanswer' option will cause the call to be answered and a final 200 response to be sent.
As with the 'Hangup' application, the dialplan will terminate after calling this function.
The cause code set on the channel will be translated to a standard ISDN cause code using the table defined in ast_sip_hangup_sip2cause() in res_pjsip.c
same = n,PJSIPHangup(UNSUPPORTED_CERTIFICATE)
same = n,ExecIf($[${SOMEVALUE} = ${SOME_BAD_VALUE}]?PJSIPHangup(437))
Syntax¶
Arguments¶
-
Cause
- May be one of...-
Response code
- A numeric response code in the range 400 ->699 -
Response code name
- A response code name from 'third-party/pjproject/source/pjsip/include/pjsip/sip_msg.h' such as 'USE_IDENTITY_HEADER' or 'PJSIP_SC_USE_IDENTITY_HEADER'
-
Generated Version¶
This documentation was generated from Asterisk branch 20 using version GIT