Assistant not reading metadata.firstName during ou...
# support
a
Hello Vapi Support Team, I am currently building an outbound cold-calling workflow using Vapi + n8n + Google Sheets. I am facing an issue where the assistant is not speaking the customer's first name, even though metadata is being passed correctly. Below are the details: 🔹 Setup Overview Assistant: GPT-4.1 Mini Outbound calls via API (POST https://api.vapi.ai/call) Metadata passed in call creation request n8n triggers the call Twilio is the phone provider 🔹 Call Creation Payload (Working) {"assistantId": "aa948fb4-0650-4e4e-b573-a0a6d3df07dc","phoneNumberId": "58307e02-cb38-4e05-8076-c89f3dba5f28","customer": {"number": "+916383148105"},"metadata": {"leadId": "L001","company": "Skaro","industry": "IT","firstName": "Aasik"} } The API response confirms metadata is received correctly. In call logs I can see: _call.metadata.firstName = Aasik So metadata is definitely reaching Vapi. 🔹 The Issue In the assistant prompt, I use: Am I speaking with {{_call.metadata.firstName}}? or Am I speaking with {{call.metadata.firstName}}? But during the call, the assistant ignores the name and instead says: “Who am I speaking with?” So it behaves as if the name is not available. 🔹 Things I Have Already Tried Using: {{metadata.firstName}} {{call.metadata.firstName}} {{_call.metadata.firstName}} Explicit instruction in prompt: “If _call.metadata.firstName exists, speak it naturally.” “Read the value from _call.metadata.firstName.” Confirmed metadata appears in Logs panel under: attributes.requestBody.message._call.metadata.firstName Assistant is Published. Server URL configured for webhook. Still, the assistant does not speak the name. This is critical for our production cold-calling flow, since greeting by name is mandatory. Please advise the correct implementation method for dynamically speaking metadata values in outbound calls. Thank you very much for your support.
s
@Aasik Basha can u use gpt 4.1
and see the performance
j
This usually happens on Vapi when metadata is logged but not injected into the LLM context, especially in outbound flows triggered through n8n and routed via Twilio. In that case, the model never “sees” _call.metadata at runtime, so it falls back to generic phrasing even though logs show the value. The fix is usually binding metadata into the system context or passing it through assistantOverrides so it’s available before generation, with a fallback if the value is missing. Are you currently setting the greeting inside the assistant’s system prompt, or injecting it dynamically in the call payload? @Aasik Basha
a
@James Christopher Thank you for your reply. i am using inside the assistant’s system prompt
j
Got it, when the variable is placed only in the system prompt on Vapi, it often isn’t hydrated with _call.metadata at runtime, especially for outbound calls triggered via n8n and routed through Twilio. That’s why the model defaults to “Who am I speaking with?” even though the logs show the name. The reliable approach is to inject firstName through assistantOverrides or bind it into the LLM context before the first turn, then add a fallback rule if it’s missing. I’ve helped teams fix this in production so the greeting works 100% of the time. If you’d like, message me privately and I’ll walk you through the exact setup for your flow. @Aasik Basha
c
Hi @Aasik Basha, could you provide me with Call IDs where this issue has occurred? This will help me review the call log and find any issues if present.