Voiceflow PartnersVPVoiceflow Partners
Powered by
Radiant raindropR
Voiceflow Partners•4mo ago
Radiant raindrop

Triggering API call to export last_uttarance and last_response in agent step.

I’m trying to log each user question and the agent’s response to a Google Sheet using {last_utterance} and {last_response}. The problem is that when using the Agent step, the variables are updated at different times — so the bot’s response gets logged before the user’s next question is stored. This causes my logs to show mismatched Q/A pairs, especially for the first user message.

What Happens:

Inside an Agent step, the agent generates a response, which updates {last_response} immediately.

But {last_utterance} is only updated after a Listen block or after the next user input.

Because of this timing difference, the webhook logs the current answer paired with the previous question, resulting in incorrect rows in the sheet.

What I Need Help With:

A reliable way (inside or after the Agent step) to access both the current user message and the current agent response from the same turn, so I can send them together to my webhook.

Or guidance on best practices for capturing synced Q/A pairs when using the Agent step.
Voiceflow Partners banner
Voiceflow PartnersJoin
Exclusive community for Voiceflow Solutions Providers & Content Creators.
13,076Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements
Recent Announcements
jacklyn

# Let your agents search the web 🔎 Hey everyone! We just released the web search tool for the agent step! Your agents can now automatically search the web for information, letting your agent supplement the LLM's knowledge and the data in its knowledge base with live, up-to-date information. Plus.... * You can restrict searches to specific domains, so your agent only searches sites that you own * This is a tool, so you remain in control of when the agent searches the web * Results are automatically summarized in a way that your agent can automatically understand Under the hood, we're using OpenAI's web search API. Give it a try, and let us know what you think! https://docs.voiceflow.com/changelog/native-web-search-tool

jacklyn · 4mo ago

jacklyn

jacklynbiggin's Thread

jacklyn · 4mo ago

hurt-tomato

connor_maclean's Thread

hurt-tomato · 4mo ago

Similar Threads

API get call. Whole response in a variable?
worthy-azureWworthy-azure / ❓┃ask-a-question
3y ago
agent response
CaioEliasCCaioElias / ❓┃ask-a-question
7mo ago
agent step buttons
hudayfaHhudayfa / ❓┃ask-a-question
6mo ago
How to end call when user doesn't respond to agent step?
MarlonMMarlon / ❓┃ask-a-question
8mo ago