Custom SIP headers are used heavily in telephony SIP world to pass information around. It’s only available for phone calls. Right now we support receiving SIP headers for inbound calls, sending SIP headers for outbound calls and when initiating transfers.
Many SIP parsers and middleboxes assume 1024 bytes is a reasonable maximum for a header line and may reject or truncate longer headers if not explicitly configured to allow more.

Parse custom SIP headers for inbound calls

For inbound calls, the custom SIP headers (headers that starts with X- or x-) are automatically received, extracted and available in the call.custom_sip_headers, it’s also automatically added to your collection of dynamic variables, and you can access it within your agent by stripping the X- or x- prefix. There’s no configuration needed for this feature. For example, if this is the SIP header received for an inbound call:
{
  "X-test-header": "something",
  "X-another-header": "something else",
  "from": "1234567890"
  "to": "0987654321"
}
Then here’s your call.custom_sip_headers field, and they will be added to your dynamic variables.
{
  "test-header": "something",
  "another-header": "something else",
}
If you have already specific dynamic variables with the same name for this inbound call, it will override the value received from the SIP header.

Set custom SIP headers for outbound calls

For outbound calls, you can add custom SIP headers as needed. It must starts with X-.

Set custom SIP headers for call transfers

For call transfers, you can also add custom SIP headers as needed. It must starts with X-. You can use dynamic variable for your custom SIP header value, so you can pass information extracted from the call to the receiving party.
For cold transfer with transferee number, it will use SIP REFER to transfer the call. Different telephony providers may or may NOT honor the custom SIP headers in the REFER request. Twilio for example, does not honor the custom SIP headers in the REFER request, so the sip headers you set in transfer call tool will not work for cold transfer with transferee number when using Twilio.
If you are using: