To expose the caller's number in the
# general-english
d
To expose the caller's number in the system prompt, dynamically replace a placeholder like` {{call.customer.number}}` with the actual number before sending the prompt. For example, your system prompt could say:
caller_number: +819012345678
This lets the assistant use that number to call your tool for context at call start.
t
maybe I messed up the question. the scenario is the following : asisstant is inbound calling - meaning people call it. what I need is the variable to use in the system prompt which will (during the call) contain the number of the caller. I don't know it ahad of time. how can I get it? A simple test would be an assistant that says "hello +1233456" when you call it. cc @Kings_bigđź’« @Vapi
d
You can’t hardcode the caller number in the system prompt since it’s unknown beforehand; instead, your integration must inject the caller’s number dynamically into the assistant’s conversation context as the call starts. Use a placeholder like
3{{caller_number}}
in your system prompt template and replace it with the actual caller number from your telephony platform right when the call connects. Then the assistant can respond, for example, “Hello +1233456” using that injected value.
k
Use the dynamic variable {{customer.number}} in the system prompt to have the assistant say the caller’s number like, “Hello, {{customer.number}}” during an inbound call, provided your telephony integration passes the caller’s number to VAPI. https://docs.vapi.ai/assistants/dynamic-variables
t
=Awesome ! Thank you guys for the quick response
k
You're welcome
d
You are welcome
2 Views