https://retellai.com/?utm_source=discord&utm_medium=seo logo
Can we execute some lines of code inside a retell ...
# ❓・ai-evy-support
a
@AI Evy Can we execute some lines of code inside a retell conversation flow agent and store that response in a variable ?
a
Thanks for tagging me @afrah_85175. I'll look through relevant sources and get back to you shortly.
### Answer Based on the available documentation, Retell AI conversation flow agents support different types of nodes, including function nodes for API calls [(1) ]() . The conversation flow system includes tools and functions that can be invoked during conversations [(2) ]() [(3) ]() [(4) ]() . The conversation flow structure includes: - Function nodes for API calls [(1) ]() - Tools that can be defined in the conversation flow [(2) ]() [(3) ]() [(4) ]() - Default dynamic variables that can store values throughout the conversation flow [(2) ]() [(3) ]() [(4) ]() [(5) ]()
Copy code
javascript
"default_dynamic_variables": {
  "company_name": "Retell Inc",
  "support_hours": "9 AM - 5 PM"
}
[(2) ]() , [(3) ]() , [(4) ]() , [(5) ]() The documentation shows that conversation flows support custom tools with API endpoints [(2) ]() [(3) ]() [(4) ]() :
Copy code
javascript
"tools": [
  {
    "type": "custom",
    "name": "get_customer_info",
    "description": "Get customer information from database",
    "tool_id": "tool_001",
    "url": "<https://api.example.com/customer%22,>
    "method": "GET"
  }
]
[(2) ]() , [(3) ]() , [(4) ]() However, the documentation doesn't explicitly detail executing arbitrary code lines directly within nodes or the specific mechanisms for storing responses in variables during conversation flow execution. For more detailed implementation guidance on custom code execution and variable storage within conversation flow agents, you may want to check the complete API documentation. Would you like me to provide a general answer about how conversation flow systems typically handle code execution and variable storage?
​ To learn more, see the sources I considered: [[1] Conversation Flow Overview](https://docs.retellai.com/build/conversation-flow/overview) [[2] Get Conversation Flow](https://docs.retellai.com/api-references/get-conversation-flow) [[3] Create Conversation Flow](https://docs.retellai.com/api-references/create-conversation-flow) [[4] List Conversation Flows](https://docs.retellai.com/api-references/list-conversation-flows) [[5] Update Conversation Flow](https://docs.retellai.com/api-references/update-conversation-flow) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.