{
"description": "2nd trigger with the same deduplication key is not attributed",
"input": {
"registrations": [
{
"timestamp": "0",
"registration_request": {
"context_origin": "https://source.test",
"Attribution-Reporting-Eligible": "navigation-source"
},
"responses": [
{
"url": "https://reporter.test/register-source",
"debug_permission": true,
"response": {
"Attribution-Reporting-Register-Source": {
"destination": "https://destination.test",
"source_event_id": "123",
"aggregation_keys": {
"a": "0x159"
},
"filter_data": {
"x": ["y", "z"]
}
}
}
}
]
},
// Should result in an event-level report and an aggregatable report.
{
"timestamp": "1000",
"registration_request": {
"context_origin": "https://destination.test"
},
"responses": [
{
"url": "https://reporter.test/register-trigger",
"response": {
"Attribution-Reporting-Register-Trigger": {
"event_trigger_data": [
{
"trigger_data": "1",
"deduplication_key": "1"
}
],
"aggregatable_trigger_data": [
{
"source_keys": ["a"],
"key_piece": "0x400"
}
],
"aggregatable_values": {
"a": 123
},
"aggregatable_deduplication_keys": [
{
"deduplication_key": "0",
"filters": {
"x": ["x"]
}
},
// Selected dedup key.
{
"deduplication_key": "1",
"filters": {
"x": ["y"]
}
},
{
"deduplication_key": "2",
"filters": {
"x": ["z"]
}
}
]
}
}
}
]
},
// Should result in an event-level report and the aggregatable report
// will be deduplicated.
{
"timestamp": "2000",
"registration_request": {
"context_origin": "https://destination.test"
},
"responses": [
{
"url": "https://reporter.test/register-trigger",
"debug_permission": true,
"response": {
"Attribution-Reporting-Register-Trigger": {
"event_trigger_data": [
{
"trigger_data": "2"
}
],
"aggregatable_trigger_data": [
{
"source_keys": ["a"],
"key_piece": "0x400"
}
],
"aggregatable_values": {
"a": 654
},
"aggregatable_deduplication_keys": [
{
"deduplication_key": "1",
"filters": {
"x": ["z"]
}
}
],
"debug_reporting": true
}
}
}
]
},
// Should result in an aggregatable report as the deduplication key is
// different.
{
"timestamp": "3000",
"registration_request": {
"context_origin": "https://destination.test"
},
"responses": [
{
"url": "https://reporter.test/register-trigger",
"response": {
"Attribution-Reporting-Register-Trigger": {
"aggregatable_trigger_data": [
{
"source_keys": ["a"],
"key_piece": "0x400"
}
],
"aggregatable_values": {
"a": 456
},
"aggregatable_deduplication_keys": [
{
"deduplication_key": "2"
}
]
}
}
}
]
},
// Should result in an aggregatable report as the deduplication key is
// filtered.
{
"timestamp": "4000",
"registration_request": {
"context_origin": "https://destination.test"
},
"responses": [
{
"url": "https://reporter.test/register-trigger",
"response": {
"Attribution-Reporting-Register-Trigger": {
"aggregatable_trigger_data": [
{
"source_keys": ["a"],
"key_piece": "0x400"
}
],
"aggregatable_values": {
"a": 789
},
"aggregatable_deduplication_keys": [
{
"deduplication_key": "1",
"not_filters": {
"x": ["y"]
}
}
]
}
}
}
]
},
// Should result in an aggregatable report as the deduplication key is null.
{
"timestamp": "5000",
"registration_request": {
"context_origin": "https://destination.test"
},
"responses": [
{
"url": "https://reporter.test/register-trigger",
"response": {
"Attribution-Reporting-Register-Trigger": {
"aggregatable_trigger_data": [
{
"source_keys": ["a"],
"key_piece": "0x400"
}
],
"aggregatable_values": {
"a": 987
},
"aggregatable_deduplication_keys": [
{
"filters": {
"x": ["y"]
}
}
]
}
}
}
]
}
]
},
"output": {
"reports": [
{
"payload": [
{
"body": {
"attribution_destination": "https://destination.test",
"source_event_id": "123",
"source_site": "https://source.test"
},
"type": "trigger-aggregate-deduplicated"
}
],
"report_time": "2000",
"report_url": "https://reporter.test/.well-known/attribution-reporting/debug/verbose"
},
{
"payload": {
"aggregation_coordinator_origin": "https://coordinator.test",
"histograms": [
{
"id": "0",
"key": "0x559",
"value": 123
}
],
"shared_info": {
"api": "attribution-reporting",
"attribution_destination": "https://destination.test",
"reporting_origin": "https://reporter.test",
"scheduled_report_time": "3601",
"version": "1.0"
}
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-aggregate-attribution",
"report_time": "3601000"
},
{
"payload": {
"aggregation_coordinator_origin": "https://coordinator.test",
"histograms": [
{
"id": "0",
"key": "0x559",
"value": 456
}
],
"shared_info": {
"api": "attribution-reporting",
"attribution_destination": "https://destination.test",
"reporting_origin": "https://reporter.test",
"scheduled_report_time": "3603",
"version": "1.0"
}
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-aggregate-attribution",
"report_time": "3603000"
},
{
"payload": {
"aggregation_coordinator_origin": "https://coordinator.test",
"histograms": [
{
"id": "0",
"key": "0x559",
"value": 789
}
],
"shared_info": {
"api": "attribution-reporting",
"attribution_destination": "https://destination.test",
"reporting_origin": "https://reporter.test",
"scheduled_report_time": "3604",
"version": "1.0"
}
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-aggregate-attribution",
"report_time": "3604000"
},
{
"payload": {
"aggregation_coordinator_origin": "https://coordinator.test",
"histograms": [
{
"id": "0",
"key": "0x559",
"value": 987
}
],
"shared_info": {
"api": "attribution-reporting",
"attribution_destination": "https://destination.test",
"reporting_origin": "https://reporter.test",
"scheduled_report_time": "3605",
"version": "1.0"
}
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-aggregate-attribution",
"report_time": "3605000"
},
{
"payload": {
"attribution_destination": "https://destination.test",
"randomized_trigger_rate": 0.0024263,
"scheduled_report_time": "172800",
"source_event_id": "123",
"source_type": "navigation",
"trigger_data": "1"
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-event-attribution",
"report_time": "172800000"
},
{
"payload": {
"attribution_destination": "https://destination.test",
"randomized_trigger_rate": 0.0024263,
"scheduled_report_time": "172800",
"source_event_id": "123",
"source_type": "navigation",
"trigger_data": "2"
},
"report_url": "https://reporter.test/.well-known/attribution-reporting/report-event-attribution",
"report_time": "172800000"
}
]
}
}