Dynamic Variables in Call Sessions
FromPhone
and ToPhone
(representing the originating and receiving phone numbers for phone calls). Additionally, you can utilize any key-value pairs from the metadata that you provide for the call.
For example, if you include custom information like customerID
, appointmentTime
, or any other data that you may want to reference throughout the call, these can now be easily used.
{<variable>}
, and our system will automatically replace it with the corresponding value during the call. Here are a few examples:
{FromPhone}
as the description of the function’s param.”{userName}! How can I assist you today?
.”phone_number={FromPhone}
.FromPhone
and ToPhone
, which represent the caller’s phone number and the receiving phone number, respectively, when the call is made via a phone network.{<variable>}
in the description of the parameter. For instance, if the parameter name is phone_number
, you can set the parameter description to {FromPhone}
to automatically include the caller’s phone number.
{userName: <real user name>}
to metadata, then set the agent’s greeting line to: Hi {userName}! How can I help you?
. This can also be applied to the agent’s prompt.