stormy-gold
stormy-gold2y ago

Get the affiliate_id from the URL

Hi, I put my chatbot inside a wordpress website. After asking the user information, the data are save to airtable. The chatbot works fine. But I want to get the 'affiliate_id' and 'transaction_id' as well if the visitor comes from affiliate url. From what I understand the data can be capture if they are inside the chatbot only. Example link: https://example.com?affiliate_id=2&transaction_id=33682vb3 I use everflow to track the affiliate. Is it possible? Thank you in advance 😀
1 Reply
NiKo | Voiceflow
You can extract the affiliate_id value in the JS script where you load the Chat widget and pass it in the launch event payload.
launch: {
event: {
type: "launch",
payload: {
affiliate_id: xyz
}
}
}
launch: {
event: {
type: "launch",
payload: {
affiliate_id: xyz
}
}
}
https://developer.voiceflow.com/docs/chat-widget
Voiceflow
Web Chat
Implement your Voiceflow Web Chat agent using our install code and JavaScript API.

Did you find this page helpful?