Event
The URL for your endpoint is available in our app dashboard.
User
When sending events, make sure that you handle the user correctly. You have two options for connecting a user.
Via EdgeTag ID
If you have the option, it's preferred to store our EdgeTag ID (you can use our getUserId function) from the browser into your own system database. This way, when you send events from your system to EdgeTag, you will include them in the request headers as EdgeTagUserId.
curl --request POST \
--url https://abc.domain.com/tag \
--header 'Content-Type: application/json' \
--header 'EdgeTagUserId: 138fffcd-ee39-4fd1-b5b5-760f07454407-1662025231518' \
--data '{
"data": {
"value": 10.50,
"currency": "USD",
"contents": [
{
"id": "123123123",
"quantity": 1,
"item_price": 10.50,
"title": "Summer Fun",
"category": "bracelets",
"image": "https://domain.com/product/fun-main.jpg",
"url": "https://domain.com/summer-fun"
}
]
},
"eventId": "c2RrX3N0YXJ0-72a6410e-4b6d-4bfa-be5f-d17c294c73bc-1285.1000",
"eventName": "AddToCart",
"pageTitle": "T-Shirt",
"pageUrl": "https://domain.com/product/shirt",
"providers": {
"all": true
},
"referrer": "https://google.com",
"search": "?utm_campaign=online",
"timestamp": 1671443880281,
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.102 Safari/537.36Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.102 Safari/537.36 Brave",
"storage": {
"edgeTag": {
"consent": {
"all": true
}
}
}
}'Via Email
If you only have an email, there's nothing to worry about. We can integrate the browser (online) with your offline system. Make sure that you provide an email in the payload through userEmail key.
Sending Event
If you are sending standard events, please ensure that you follow our standard events documentation.
When consent is enabled, ensure that you include it in the request as well; see the examples above (storage key).
The Event ID should be unique to prevent signal loss.
Last updated
Was this helpful?

