Read encoded SIP headers as call variables
Voice AgentsNewSep 7 – 13, 2026
Encoded SIP header values from your phone system now reach your voice agent as readable text, and a transfer can decode a value before passing it on.
Many phone systems send call context, such as a customer ID or a queue, in SIP headers, and often encode it so it isn't plain text. Your voice agent can now read those values in plain words, use them in its prompt, and pass them on readable when it transfers the call.
On inbound calls over your SIP trunk
- Each custom header the call carries becomes a Voice Agent variable, {{sip_header_<name>}}, with the value as it arrived. The name is the header name in lowercase: X-Customer-Data becomes {{sip_header_x-customer-data}}.
- If the header is User-to-User, or its value declares hex or base64 encoding, you also get {{sip_header_<name>_decoded}} with the readable text.
- A header that doesn't declare its encoding gets no _decoded variable, even if its value looks encoded.
For example, a call arriving with X-Customer-Data: 4a55414e7c564950;encoding=hex gives your agent {{sip_header_x-customer-data_decoded}} with the value JUAN|VIP.
When the agent transfers the call
- Open your voice agent, go to Settings and open Agent Actions.
- Open the Transfer Call action and find Custom SIP Headers.
- Add a header and, in its value, put |decode after a variable you know is encoded, for example {{sip_header_user-to-user|decode}}.
- Save. The destination receives that value as readable text.
Good to know
- Use |decode only on values you know are encoded: a plain value made of an even number of hex characters, such as 1234, is decoded as hex too.
- Inbound headers are read on calls that arrive over a SIP trunk, so your carrier or PBX has to add them.
- Whether a header reaches the transfer destination depends on your carrier or PBX passing it through. Confirm it with your telephony admin.

