tracio.aidocs

Getting Started

  • Overview
  • Quick Start
  • How It Works

SDK & API

  • Device Identification JS Agent
  • Trace API Reference
  • Trace Webhooks

Features

  • Device Identification Engine
  • Bot Detection
  • Trace Signals
  • IP Intelligence

Advanced

  • Cloud Deployment
  • Privacy & GDPR
  • Migration from FPJS

Reference

  • Changelog
  • Troubleshooting
  • Error Handling
  • Testing

Trace Webhooks

Real-time HTTP POST notifications for visitor.identified, bot.detected, and signal.suspicious events

Overview

Configure webhooks to receive real-time notifications for visitor events. Webhooks are sent as HTTP POST requests with a JSON payload to your configured endpoint.

Webhook Events

EventDescription
visitor.identifiedNew or returning visitor identified
bot.detectedAutomated browser detected
signal.suspiciousHigh suspect score triggered

Payload Format

{
"event": "visitor.identified",
"timestamp": "2024-03-12T16:00:00Z",
"data": {
"visitorId": "X7fh2Hg9LkMn3pQr",
"requestId": "1710432000_abc123def",
"confidence": { "score": 0.995 },
"bot": { "result": "notDetected" },
"ip": "94.142.239.124"
}
}

Webhook Handler Example

app.post('/webhook/tracio', (req, res) => {
const { event, data } = req.body;
switch (event) {
case 'visitor.identified':
console.log(`Visitor: ${data.visitorId}`);
break;
case 'bot.detected':
console.warn(`Bot detected: ${data.bot.type}`);
break;
case 'signal.suspicious':
console.warn(`Suspect score: ${data.suspectScore}`);
break;
}
res.status(200).send('OK');
});