Skip to main content

Using Data Source UUIDs for Event Attribution

A Data Source on the GoWit platform is a configured integration endpoint that represents a specific origin of data or events. When you create a Data Source (via GoWit’s admin UI), the system generates a unique identifier (a UUID) for that source. This UUID acts as an integration key – it tags every incoming request (whether it’s a batch of data or a tracking event) so the platform can identify where it came from and record its status.

In essence, the Data Source defines a feed or event stream (for example: product catalog feed, advertiser feed, or event pipeline) and the UUID is the handle that GoWit uses to tie incoming information to that specific integration context.

Why Each Tracking Event Requires a Unique Data Source UUID

Every tracking event – impressions, clicks, sales, etc. – must include a Data Source UUID so that GoWit knows exactly which integration and environment the event belongs to. By including the UUID with each event, GoWit can enable proper logging, attribution, and isolation for that event stream.

This is especially crucial if you have multiple data sources or separate environments (staging vs. production). The Data Source UUID ensures each event “goes to the right place” in GoWit’s system, allowing you to monitor and debug each integration independently.

In short, the UUID is how GoWit distinguishes events coming from your integration.

Including the Data Source UUID in Event Requests

GoWit requires the Data Source UUID to be passed in the HTTP headers of your tracking API calls. Specifically, every server-to-server event request should include a header named Data-Source-UUID with the value set to your integration’s UUID. This applies to all event types (impressions, clicks, conversions) just as it does for data feed APIs.

Including this header is crucial: it links your request to the correct Data Source configuration and enables the platform to log the operation under that Data Source’s logs.

Example

A server-side call recording an impression might look like:

curl -X POST "https://<staging-api>/server/events" \
-H "Authorization: Bearer <YOUR_API_TOKEN>" \
-H "Content-Type: application/json" \
-H "Data-Source-UUID: <YOUR_DATA_SOURCE_UUID>" \
-d '{
"event_type": "impression",
"ad_id": "XYZ-12345",
"session_id": "abcde-12345-session",
"marketplace_id": 123
}'

In this example, replace <YOUR_API_TOKEN> with your auth token and <YOUR_DATA_SOURCE_UUID> with the actual UUID string (e.g. "550e8400-e29b-41d4-a716-446655440000"). The Data-Source-UUID header must be included in the request, alongside the event payload. GoWit will read this header for each incoming event request. If the header is missing or the UUID is incorrect, the platform won’t recognize the event’s source.

Log Traceability and Debugging Benefits

Using the Data Source UUID in every event call lets GoWit attach those events to that Data Source’s log stream. In the GoWit admin interface (under Dev. Tools), you can see a history of received events and any errors, filtered by the Data Source. Because each event carries the UUID, traceability is greatly improved – you can easily verify if an impression or click was recorded, and debug failures in real time.

impression-logs.png

The platform’s logging will attribute the event to your specific Data Source, so you get a clear, isolated view of your tracking events for debugging and auditing. Without the UUID, events may not show up in these logs, making it difficult to troubleshoot missing attributions or integration issues.

Environment Separation: Staging vs. Production UUIDs

Data Source UUIDs are environment-specific. A UUID generated in GoWit’s staging environment is not valid in production, and vice versa. Each environment (test, QA, prod) has its own Data Source records in isolation.

This means you should set up parallel Data Sources for your tracking events in each environment – for example, one UUID for “Tracking Events – Staging” and another for “Tracking Events – Production” – and use the appropriate one depending on which GoWit environment you are calling.