Trigger a Webhook via a Javascript
Learn how to use Javascript to trigger a webhook and send conversion data to AnyTrack.io for improved ROAS and better tracking of custom conversions.
Trigger a Webhook via a Javascript Tag Once you have added the AnyTrack tag on your webpage, a programmer can trigger postback URLs and add AnyTrack {click_id}
for attribution automatically:
Before you begin:
You must be familiar with Javascript, HTML, and CSS to use these tracking snippets. If you're not familiar with all of these coding languages, please forward the article to a developer.
AnyTrack will automatically trigger the postback url and substitute the {click_id}
with the current user client id.
We recommended to send more event attributes with the postback in the third argument:
AnyTrack('postback', 'https://t1.anytrack.io/xxxxx/collect?click_id={click_id}', {
brand_name: 'bar',
commission: 59.99,
transactionId: 'asfasdf'
});
Getting started
Prerequisite:
The AnyTrack tracking Tag must be set on the page's head section.
- Create a custom integration
- Copy the postback URL
- Strip the query parameters
- Paste the URL into the code example
- Paste the entire code on the page where you want to trigger the conversion
To validate your setup, you should trigger a conversion.
Updated 5 months ago