prefilledVariables

Looking at documentation located at https://docs.typebot.io/editor/variables We are starting a chat from V1 API data: '{"message":"dsadsa","isStreamEnabled":true,"isOnlyRegistering":true,"prefilledVariables":{"number":"5511888888888","name":"Rafael Ribeiro","ticketId":"5118","contactId":"24729","token_wpp":"sdsadsadsadsadas","protocol":"7503","email":"[email protected]","firstMessage":"dsadsa"}}' And creating a variables with same name into the flow, but it comes undefined?
23 Replies
Baptiste
Baptiste10mo ago
Can you provide more details? What’s the error you see exactly?
Rafael Ribeiro
Rafael RibeiroOP10mo ago
variables comes undefined
Baptiste
Baptiste10mo ago
Provide a reproduction, I can't reproduce, it works fine on my end 🙂
Rafael Ribeiro
Rafael RibeiroOP10mo ago
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
data: '{"message":"dsadsa","isStreamEnabled":true,"isOnlyRegistering":true,"prefilledVariables":{"number":"5511888888888","name":"Rafael Ribeiro","ticketId":"5118","contactId":"24729","token_wpp":"sdsadsadsadsadas","protocol":"7503","email":"[email protected]","firstMessage":"dsadsa"}}' Self-hosted and typebot.io same
Baptiste
Baptiste10mo ago
Tell me how I can reproduce because I don't understand what you are showing WhatsApp runtime can't have prefilled variables
Rafael Ribeiro
Rafael RibeiroOP10mo ago
This is our POST data... sent to typebot API to start a session, with prefilled variables
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
This is our typebot
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
This is the answer
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
comes undefined
Baptiste
Baptiste10mo ago
Remove the first group Inicializar, it is useless here
Rafael Ribeiro
Rafael RibeiroOP10mo ago
Yes, we removed and has the same result
Rafael Ribeiro
Rafael RibeiroOP10mo ago
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
Using POSTMAN... get the session and starts variables
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
Empty data on variables
No description
Rafael Ribeiro
Rafael RibeiroOP10mo ago
What I m doing wrong? On hosted version from github, it stop working on versions above 2.25
Baptiste
Baptiste10mo ago
Delete ‘isOnlyRegistering’ from the body It should fix it But indeed it looks like there's a bug when using isOnlyRegistering option
Rafael Ribeiro
Rafael RibeiroOP10mo ago
I removed but same error... on postman, same error too
Baptiste
Baptiste10mo ago
Editor
Create and publish conversational forms that collect 4 times more answers and feel native to your product
Baptiste
Baptiste10mo ago
POST https://typebot.io/api/v1/typebots/.../startChat With body:
{
"prefilledVariables": {
"Name": "Baptiste"
}
}
{
"prefilledVariables": {
"Name": "Baptiste"
}
}
It worked fine So I am confused!
Rafael Ribeiro
Rafael RibeiroOP10mo ago
The variables are prefilled on startChat, but becomes unavaiable on next steps... like continueChat

Did you find this page helpful?