Event tracking
Track in-app actions, revenue, and custom parameters with the Adtrace Android SDK, or send events from your server when needed.
Event tracking has two steps:
- Define the event in the panel (Settings → Event → Add Event).
- Implement sending with the SDK or S2S, using the event token from the panel.
Create an event in the panel
In the Adtrace panel, go to Settings → Event → Add Event and configure:
| Field | Description |
|---|---|
| Event name | A readable name (for example Login, Purchase, Add to cart). |
| Unique event | Unique: recorded only the first time per device. Non-unique: recorded every time the action happens. |
| Add key | Optional parameter keys for event values (for example phone, first_name). Use keys for metadata; use setRevenue for revenue, not event value keys. |
After you click Create, Adtrace assigns an event token for each event. Use that token in your SDK or S2S implementation.
There is no hard limit on how many events you can create, but define only events you plan to analyze.
Choose how to send events
| Method | When to use |
|---|---|
SDK (AdTrace.trackEvent) | Default for in-app actions (for example button clicks). The SDK queues events on the device and retries until delivery succeeds. |
| Server-to-server (S2S) | Sensitive or high-value data (for example purchases) when server-side sending is preferred. |
You cannot track events with S2S alone without integrating the Adtrace SDK in the app. An install must exist for the device before any event (SDK or S2S) is attributed correctly, and a reliable install requires the SDK. S2S adds a second delivery path after the app is integrated, not a substitute for integration.
Before you send events, ensure the install was successfully tracked for the app on the device.