https://retellai.com/?utm_source=discord&utm_medium=seo logo
se ha enviado este webhook a retell con dynamic va...
# ❓・ai-evy-support
d
@AI Evy se ha enviado este webhook a retell con dynamic variables, pero en el apartado de data de call history sale como si no hubiesen dynamic variables. No sé qué falla pero sé que, cuando las dynamic varibles que se envían hacia retell están vacías, entonces retell sí que las registra, pero cuando tienen información, pone que no hay dynamic varibles. { "call_inbound": { "dynamic_variables": { "nombre": "NACHO", "apellidos": "DOMINGUEZ AGUT", "tel": "644771531", "fechanac": ""20071122"", "ciudad": "ALMAZORA/ALMASSORA" } } }
a
Thanks for tagging me @djnach_10. I'll look through relevant sources and get back to you shortly.
### Answer [(1) ]() , [(2) ]() , [(3) ]() , [(4) ]() Based on the documentation, I can see a potential issue with your webhook structure for dynamic variables. For inbound calls, the webhook should provide dynamic variables in the
retell_llm_dynamic_variables
field [(1) ]() . According to the documentation, all values in
retell_llm_dynamic_variables
must be strings . Looking at your JSON structure, there are a couple of issues: 1. **Field structure**: You're using
call_inbound.dynamic_variables
, but the documentation shows dynamic variables should be in
retell_llm_dynamic_variables
[(2) ]() [(3) ]() [(4) ]() 2. **String format issue**: The
fechanac
field has double quotes within the string:
"fechanac": ""20071122""
- this creates invalid JSON formatting The correct structure should be:
Copy code
json
{
  "retell_llm_dynamic_variables": {
    "nombre": "NACHO",
    "apellidos": "DOMINGUEZ AGUT", 
    "tel": "644771531",
    "fechanac": "20071122",
    "ciudad": "ALMAZORA/ALMASSORA"
  }
}
[(1) ]() The documentation emphasizes that all values in
retell_llm_dynamic_variables
must be strings , which your values appear to be (once the JSON formatting is corrected) . For inbound calls specifically, you can supply dynamic variables in the Inbound Call Webhook . Make sure your webhook response uses the correct field name and proper JSON formatting.
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Create Web Call](https://docs.retellai.com/api-references/create-web-call) [[3] Get Call](https://docs.retellai.com/api-references/get-call) [[4] Create Phone Call](https://docs.retellai.com/api-references/create-phone-call) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
d
it is for inbound calls. I tries your webhook code but it does not work neither
a
Thanks for the follow-up, @djnach_10. I'll get back to you soon.
​ To learn more, see the sources I considered: [[1] Inbound call webhook](https://docs.retellai.com/features/inbound-call-webhook) [[2] Update Phone Number](https://docs.retellai.com/api-references/update-phone-number) [[3] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) ​
### Answer For inbound calls, the webhook response structure should use
call_inbound
as the main field, with
dynamic_variables
nested inside it [(1) ]() . Here's the correct format:
Copy code
json
{
  "call_inbound": {
    "dynamic_variables": {
      "customer_name": "John Doe"
    }
  }
}
Your original structure was actually correct for inbound calls . The issue might be with the JSON formatting - specifically the double quotes in the
fechanac
field:
"fechanac": ""20071122""
creates invalid JSON . Try this corrected version:
Copy code
json
{
  "call_inbound": {
    "dynamic_variables": {
      "nombre": "NACHO",
      "apellidos": "DOMINGUEZ AGUT",
      "tel": "644771531",
      "fechanac": "20071122",
      "ciudad": "ALMAZORA/ALMASSORA"
    }
  }
}
Additional troubleshooting steps: 1. Ensure your webhook endpoint returns a successful status code (2xx) 2. The webhook has a timeout of 10 seconds 3. Verify your webhook URL is correctly configured in your phone number settings [(2) ]() 4. Check that all dynamic variable values are strings [(3) ]() If the webhook continues to fail, it will be retried up to 3 times, and if all attempts fail, the call will use the default inbound agent if one is set [(1) ]() .
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
d
perfecto, ahora sí que se envía bien. El problema lo tengo ahora en un logic split node, que la condición es que si apellidos exist, que vaya a un lado, y else que vaya a otro, pero no la respeta, siempre toma el primer camino
a
Thanks for the follow-up, @djnach_10. I'll get back to you soon.
### Answer Basándome en las fuentes disponibles, el problema que experimentas con el Logic Split Node y las variables dinámicas es un problema conocido [(1) ]() . Según la información de la comunidad, actualmente las transiciones basadas en ecuaciones (incluyendo variables dinámicas) están en desarrollo . El Logic Split Node no puede reconocer el valor de una variable dinámica a menos que haya sido mencionada previamente en la conversación . Para resolver este problema, necesitas implementar una solución temporal: 1. Añade un Conversation Node antes del Logic Split Node que mencione silenciosamente la variable dinámica . Por ejemplo, podrías usar un prompt como: "Silenciosamente nota la información conocida... No digas nada al usuario en este nodo. Transiciona silenciosamente al siguiente nodo" . 2. Asegúrate de que las variables estén configuradas correctamente. Si estás obteniendo la variable desde una respuesta de webhook, necesitas usar "Response Variables" para establecer la variable al valor correcto [(2) ]() . 3. Verifica que la variable tenga un valor. El Logic Split Node puede fallar si la variable está vacía o no está configurada correctamente . La documentación oficial confirma que las variables dinámicas funcionan en varios lugares, incluyendo prompts y configuraciones de herramientas [(3) ]() , pero el comportamiento específico del Logic Split Node con variables dinámicas parece requerir que la variable haya sido mencionada en la conversación previamente [(1) ]() . Una vez que las transiciones basadas en ecuaciones estén completamente implementadas, este problema debería resolverse
.
​ To learn more, see the sources I considered: [[1] HELP: Dynamic Variables and the NEW Logic Split Node](https://discord.com/channels/1186424376300679209/1359881066168582194) [[2] {{variable}} / Logic Split Node Issue](https://discord.com/channels/1186424376300679209/1417167639524151441) [[3] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.