How to Give a Zapier AI Webhook Simple Conversation Memory
Use Storage by Zapier to remember the last few turns so your AI replies stay in context across webhook calls.
A plain webhook to an AI model forgets everything between calls, so a chatbot built that way cannot follow up on what was said earlier. Storage by Zapier gives you a tiny key-value store. By keying it on a user id you can stash recent turns and feed them back into the next prompt.
What you need
- A Zapier account with Storage by Zapier and Webhooks by Zapier
- An OpenAI API key
- A client that sends a stable userId with each message
Step 1: Catch the message
Use a Catch Hook trigger that receives userId and message. The userId is the key that keeps each person's history separate.
Step 2: Read prior history
Add a Storage by Zapier action with the Get Value event. Use a key like history-{{userId}} so each user has their own slot. On the first message this returns empty, which is fine.
Step 3: Include history in the prompt
In the OpenAI step, paste the retrieved history into the system or user content so the model has the recent context, then add the new message.
{
"model": "gpt-5-mini",
"messages": [
{ "role": "system", "content": "Conversation so far:\n{{history}}" },
{ "role": "user", "content": "{{message}}" }
]
}Step 4: Write the updated history back
After the model replies, add a Storage Set Value action on the same key. Concatenate the old history, the new user line, and the AI reply so the next call sees it.
Result: the second call remembers the name from the first, because the history round-trips through Storage between requests.
Watch related tutorials
12:38
14:09
17:53
15:00
12:00
20:00