Event Data Fields API
Get detailed event data with custom fields and attribution information
Overview
The Event Data Fields endpoint provides comprehensive access to your event data with all custom fields and attribution information. Perfect for analyzing conversion events, e-commerce transactions, user interactions, and building detailed event analytics with marketing attribution.
Get granular insights into user behavior with full event properties, UTM attribution, and flexible filtering options for any event type you track.
Endpoint
Authentication
Include your API key in the Authorization header:
Parameters
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
signalId | string | Yes | - | Your website signal ID (URL path) |
targetSignalId | string | Yes | - | Target signal ID for analytics data |
isHybrid | boolean | Yes | - | Whether the signal uses hybrid tracking |
eventName | string | Yes | - | Name of the event to fetch data for |
startDate | string | No | - | Start date for data range (ISO format) |
endDate | string | No | - | End date for data range (ISO format) |
timeframe | string | No | custom | Time period: today , yesterday , last7days , last30days , custom |
timezone | string | No | UTC | Timezone for date calculations (URL encoded) |
attribution_model | string | No | last_click | Attribution model (see below) |
attribution_window | number | No | 30 | Attribution window in days |
limit | number | No | 50 | Number of events to return |
offset | number | No | 0 | Pagination offset |
Quick Start
Environment Setup
Finding your signal ID: Go to your Hardal dashboard → select your project → view the signal ID in settings.
Finding your API key: Go to your Hardal dashboard → select your signal → Settings → API Keys.
Start with a simple request to get purchase event data:
Basic Purchase Events
Basic Purchase Events
Get today’s purchase events with attribution data.
Response:
Usage Examples
Today's Purchase Events
Today's Purchase Events
Get all purchase events from today with full attribution data.
Response:
Use Case: E-commerce revenue tracking, conversion analysis
Custom Date Range Analysis
Custom Date Range Analysis
Analyze events within a specific date range for detailed reporting.
Response:
Use Case: Historical analysis, campaign performance review
Signup Events - Last 7 Days
Signup Events - Last 7 Days
Track user registrations and signups over the past week.
Response:
Use Case: User acquisition analysis, signup funnel optimization
Paginated Event Data
Paginated Event Data
Handle large datasets with pagination for comprehensive analysis.
Response:
Use Case: Data export, comprehensive reporting, ETL processes
Response Fields
Standard Fields
session_id
: Unique session identifierevent_id
: Unique event identifiercreated_at
: Event timestamp (ISO format)event_name
: Name of the event
Attribution Fields
source
: UTM source or traffic sourcemedium
: UTM medium or traffic mediumcampaign
: UTM campaign name
Custom Event Fields
The response includes all custom fields tracked with the event:
E-commerce Events
value
: Purchase amount or event valuecurrency
: Currency code (USD, EUR, TRY, etc.)product_id
: Product identifierproduct_name
: Product name or titlecategory
: Product categoryquantity
: Number of itemsdiscount
: Discount amount applied
User Events
user_email
: User email addressuser_id
: User identifieruser_name
: User display namesubscription_type
: Type of subscription
Marketing Events
promotion_id
: Promotion identifiercoupon_code
: Applied coupon codeaffiliate_id
: Affiliate tracking ID
Pagination Object
total
: Total number of events matching criteriatotalPages
: Total number of pagescurrentPage
: Current page number (1-based)limit
: Number of events per pageoffset
: Current pagination offsethasNextPage
: Whether more pages existhasPreviousPage
: Whether previous pages exist
Attribution Models
Choose the attribution model that best fits your marketing analysis:
Model | Description | Best For |
---|---|---|
last_click | Credit to the last touchpoint before event | Direct response campaigns |
first_click | Credit to the first touchpoint in journey | Brand awareness campaigns |
any_click | Credit to any touchpoint that influenced event | General attribution |
linear | Equal credit across all touchpoints | Multi-touch campaigns |
time_decay | More credit to recent touchpoints | Complex customer journeys |
Data Type Handling
The endpoint automatically handles different data types in your custom fields:
Primitive Values
Primitive Values
Simple values like strings, numbers, and booleans.
JSON Arrays (Flattened)
JSON Arrays (Flattened)
Array data is flattened with indexed keys.
JSON Objects (Flattened)
JSON Objects (Flattened)
Nested objects are flattened with dot notation.
Performance Considerations
Query Performance Notice: This endpoint performs complex queries with custom fields and attribution modeling. Query time increases significantly with larger date ranges.
For optimal performance:
- Use shorter date ranges (1-7 days) for detailed event analysis
- Use longer date ranges (30+ days) sparingly for historical exports
Consider smaller limit values
(10-50) for large datasets- Peak performance with
today
andyesterday
timeframes Filter by specific eventName
to reduce query complexity
Usage Notes
- Event Name Required: Must specify an
eventName
parameter to filter events - Custom Fields: All custom event properties are included in the response
- Attribution Data: Each event includes marketing attribution information
- Array Flattening: JSON arrays and objects are flattened with dot notation
- Timezone Support: All timestamps are converted to the specified timezone
- Pagination: Use
limit
andoffset
for paginated results - Date Filtering: Supports both preset timeframes and custom date ranges