Get the typebot source or image and change the env WHATSAPP_CLOUD_API_URL
to you Unoapi url (ex: http://localhost:9876
In your typebot flow go to Share > Whatsapp
Click in continue
In the System User Token, put the token from the Unoapi env (authToken )
In the Phone number ID, put the phone number without the + sign, ex 55999999999 )
Put the callback url and token in the unoapi redis or .env config, exemple below.
"webhooks":[
{
"urlAbsolute":"YOUR TYPEBOT URL"
"token":"Bearer YOR TOKEN",
"header":"Authorization"
}
],
And click in submit on typebot
After, enable the integration on typebot and click in Publish.
Some observations before using list on Typebot, by default Typebot is not ready to work with lists, so has some limitations.
- Use max of 3 itens in the list, if you use more will be send another list
To use lists, you need to use the text bubble followed by button input.
To work with this, set a unique id field in webhook json in redis or if use envs config, the id of webhook is a string default
For exemplo, if your session number is Y and you want do webhook with id W to never send more message to number X
ttl param is in seconds
To remove a phone number your black, send ttl with 0, with ttl -1, never expire
curl -i -X POST \
http://localhost:9876/Y/blacklist/W \
-H 'Content-Type: application/json' \
-H 'Authorization: 1' \
-d '{
"ttl": -1,
"to": "X"
}'