Skip to content

SIPRemoveHeader()

Synopsis

Remove SIP headers previously added with SIPAddHeader

Description

SIPRemoveHeader() allows you to remove headers which were previously added with SIPAddHeader(). If no parameter is supplied, all previously added headers will be removed. If a parameter is supplied, only the matching headers will be removed.

Example: Add 2 headers
same => n,SIPAddHeader(P-Asserted-Identity: sip:foo@bar)
same => n,SIPAddHeader(P-Preferred-Identity: sip:bar@foo)
Example: Remove all headers
same => n,SIPRemoveHeader()
Example: Remove all P- headers
same => n,SIPRemoveHeader(P-)
Example: Remove only the PAI header (note the : at the end)
same => n,SIPRemoveHeader(P-Asserted-Identity:)
Always returns '0'.

Syntax

SIPRemoveHeader([Header])
Arguments
  • Header

Generated Version

This documentation was generated from Asterisk branch 16 using version GIT