Another powerful enhancement would be the ability to run small JavaScript code blocks directly inside Agent Studio actions.
In many automation platforms, developers are able to use a "Run Code" module where they can write simple JavaScript logic for data transformation, calculations, or conditional processing.
Adding a similar feature inside Agent Studio would greatly improve flexibility when handling dynamic data.
Example Use Case:
Suppose an API returns a date in ISO format like:
2026-03-14T10:45:00Z
A JavaScript code module could convert it into a readable format before sending it to the Voice AI agent.
Example JavaScript:
const inputDate = input.date;
const formattedDate = new Date(inputDate).toLocaleDateString();
return {
formatted_date: formattedDate
};
The output variable formatted_date could then be used by the AI agent to respond naturally during a conversation.
Benefits:
• Data transformation without external tools
• Ability to perform calculations and formatting
• Greater flexibility in automation logic
• Reduced dependency on external platforms
This feature would make Agent Studio significantly more powerful for developers building advanced AI-driven automations.