Misc. Dialplan Tools set profile var

From FreeSWITCH Wiki
Jump to: navigation, search

Adds a header to the CHANNEL events.

 <action application="set_profile_var" data="accountcode=${accountcode}"/>

OR

 <action application="set_profile_var" data="accountcode=14"/>

Example:

 Event-Name: CHANNEL_STATE
 Core-UUID: d92978c8-b194-11e2-b2e6-6bbbd88f8ec8
 FreeSWITCH-Hostname: fs01
 FreeSWITCH-Switchname: fs01
 FreeSWITCH-IPv4: 192.168.1.154
 FreeSWITCH-IPv6: %3A%3A1
 Event-Date-Local: 2013-04-30%2012%3A04%3A53
 Event-Date-GMT: Tue,%2030%20Apr%202013%2016%3A04%3A53%20GMT
 Event-Date-Timestamp: 1367337893700047
 Event-Calling-File: switch_channel.c
 Event-Calling-Function: switch_channel_perform_set_running_state
 Event-Calling-Line-Number: 2043
 Event-Sequence: 2497
 Channel-State: CS_ROUTING
 Channel-Call-State: RINGING
 Channel-State-Number: 2
 Channel-Name: sofia/internal/1000%4014
 Unique-ID: b1c2b05e-b1af-11e2-b391-6bbbd88f8ec8
 Call-Direction: inbound
 Presence-Call-Direction: inbound
 Channel-HIT-Dialplan: true
 Channel-Presence-ID: 1000%4014
 Channel-Call-UUID: b1c2b05e-b1af-11e2-b391-6bbbd88f8ec8
 Answer-State: ringing
 Channel-Read-Codec-Name: G722
 Channel-Read-Codec-Rate: 16000
 Channel-Read-Codec-Bit-Rate: 64000
 Channel-Write-Codec-Name: G722
 Channel-Write-Codec-Rate: 16000
 Channel-Write-Codec-Bit-Rate: 64000
 Caller-Direction: inbound
 Caller-Username: 1000
 Caller-Dialplan: XML
 Caller-Caller-ID-Name: T1000
 Caller-Caller-ID-Number: 1000
 Caller-Orig-Caller-ID-Name: T1000
 Caller-Orig-Caller-ID-Number: 1000
 Caller-Network-Addr: 192.168.1.130
 Caller-ANI: 1000
 Caller-Destination-Number: 206
 Caller-Unique-ID: b1c2b05e-b1af-11e2-b391-6bbbd88f8ec8
 Caller-Source: mod_sofia
 Caller-Transfer-Source: 1367337893%3Ab1ed9bde-b1af-11e2-b3a8-6bbbd88f8ec8%3Abl_xfer%3A206/route/XML
 Caller-Context: route
 Caller-RDNIS: 1004
 Caller-Channel-Name: sofia/internal/1000%4014
 Caller-Profile-Index: 4
 accountcode: 14


This application may be run inline from the XML dialplan.

See Also