-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathattribution-api.yaml
More file actions
2065 lines (1979 loc) · 68.9 KB
/
attribution-api.yaml
File metadata and controls
2065 lines (1979 loc) · 68.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.3
info:
title: Trillboards Attribution & Measurement API
version: 1.0.0
description: |
Closed-loop DOOH attribution engine with attention-verified impressions,
cross-channel multi-touch attribution, Bayesian incrementality measurement,
and creative performance optimization.
## Why This Matters
Traditional DOOH attribution estimates impressions using population data.
Trillboards MEASURES them: on-device computer vision (ML Kit) counts faces
and tracks gaze, audio classification (YAMNet TFLite) detects ambient context,
and third-party mobile location signals (Intuizi) prove store visits.
Every metric in this API is deterministic, not probabilistic.
## Authentication
All endpoints require a valid JWT token in the Authorization header:
```
Authorization: Bearer <jwt_token>
```
Tokens are obtained via `POST /v1/user/login`.
## Key Concepts
- **aCPM (Attention CPM)**: Cost per 1,000 attention-verified impressions. Unlike standard CPM, aCPM only counts impressions where someone was actually looking at the screen.
- **Incremental Lift**: The percentage increase in store visits attributable to the DOOH campaign, measured via geo-holdout experiments with matched control groups.
- **CPIV (Cost Per Incremental Visit)**: Total media cost divided by the number of store visits that would NOT have happened without the campaign.
- **Weighted Confidence**: Exposure match confidence (spatial/temporal) multiplied by attention weight from FEIN edge AI. Higher = more certain the person both saw AND paid attention to the ad.
- **Attribution Chain**: A complete user journey across channels (billboard -> mobile ad -> web visit -> store visit) with credit allocation via multi-touch models.
## Attribution Pipeline (6 Layers)
1. **Signal Ingestion** — Intuizi mobile device location pings + POI reference data
2. **Exposure Matching** — PostGIS ST_DWithin joins device signals with ad plays
3. **Attention Enrichment** — FEIN edge AI inference (face count, gaze, emotion) attached to each exposure
4. **Identity Resolution** — Household clustering, cross-device graph, pixel visitor linking
5. **Attribution** — Multi-touch credit allocation across DOOH + mobile + web + store channels
6. **Measurement** — Bayesian + frequentist incrementality with geo-holdout experiments
contact:
name: Trillboards Developer Support
email: developers@trillboards.com
url: https://trillboards.com/developers
license:
name: Proprietary
url: https://trillboards.com/terms-of-service
servers:
- url: https://api.trillboards.com
description: Production API
- url: http://localhost:4004
description: Local development
tags:
- name: Campaign Attribution
description: Campaign-level attribution summaries, timeseries, heatmaps, and journey funnels
- name: Attention Metrics
description: |
Attention-verified impression metrics from FEIN edge AI.
Only Trillboards provides deterministic attention data in DOOH —
measured by on-device computer vision, not estimated.
- name: Cross-Channel Attribution
description: Multi-touch attribution, cross-channel journeys, and per-channel ROAS across DOOH, mobile, web, and store
- name: Incrementality
description: Bayesian uplift measurement with geo-holdout experiments, ghost ads, and propensity matching
- name: Creative Attribution
description: Creative-level performance attribution — which creative x venue x daypart x weather combination drives the most conversions
- name: Cohort Export
description: Export exposed audience cohorts (MAID lists) to DSPs for retargeting activation
- name: Signal Transparency
description: Signal quality, freshness, and methodology transparency endpoints
- name: Event Ingestion
description: Cross-channel event ingestion — DSP postbacks, conversion pixels, transaction data
paths:
/v1/advertiser/attribution/campaign/{campaignId}:
get:
operationId: getCampaignSummary
summary: Campaign attribution summary
description: |
Returns comprehensive attribution metrics for a campaign including reach,
exposures, footfall visits, incremental lift, cost per visit, and statistical
significance. This is the single endpoint that proves DOOH campaign ROI.
The response includes both raw metrics and quality indicators (match confidence,
control group size, significance level) so advertisers can assess data reliability.
tags: [Campaign Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Attribution summary for the campaign
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
example: true
data:
$ref: '#/components/schemas/AttributionSummary'
example:
success: true
data:
campaign_id: "camp_abc123"
advertiser_id: "adv_xyz789"
date_range:
start: "2026-02-01"
end: "2026-02-28"
reach:
unique_devices_exposed: 45200
total_exposures: 128500
avg_frequency: 2.84
footfall:
exposed_visitors: 3250
control_visitors: 1820
exposed_visit_rate: 0.0719
control_visit_rate: 0.0403
incremental_lift_pct: 78.4
incremental_visits: 1430
cost_per_incremental_visit: 6.99
quality:
control_group_size: 45200
avg_match_confidence: 0.82
statistical_significance: 0.997
avg_time_to_visit_h: 48.3
attribution_window_days: 14
cost:
total_media_cost: 10000
cost_per_unique_reach: 0.22
breakdowns:
venue_breakdown:
gym: { visitors: 1200, lift_pct: 92.1 }
coffee_shop: { visitors: 850, lift_pct: 65.3 }
daypart_breakdown:
morning: { visitors: 1500, lift_pct: 85.0 }
evening: { visitors: 1750, lift_pct: 72.0 }
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/timeseries:
get:
operationId: getCampaignTimeseries
summary: Daily attribution timeseries
description: |
Returns daily attribution metrics over time. Use this to answer:
"Is my campaign's lift improving or degrading?" and "Which days drive
the most store visits?"
Supports date range filtering. If no dates specified, returns the full
campaign duration.
tags: [Campaign Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
- name: startDate
in: query
schema:
type: string
format: date
description: Start date (ISO 8601, e.g. 2026-02-01)
- name: endDate
in: query
schema:
type: string
format: date
description: End date (ISO 8601, e.g. 2026-02-28)
responses:
'200':
description: Daily timeseries of attribution metrics
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/AttributionTimeseriesPoint'
example:
success: true
data:
- summary_date: "2026-02-15"
unique_devices_exposed: 1620
total_exposures: 4580
exposed_visitors: 116
control_visitors: 65
incremental_lift_pct: 78.5
incremental_visits: 51
cost_per_incremental_visit: 7.84
avg_match_confidence: 0.83
statistical_significance: 0.982
- summary_date: "2026-02-16"
unique_devices_exposed: 1780
total_exposures: 5120
exposed_visitors: 134
control_visitors: 72
incremental_lift_pct: 86.1
incremental_visits: 62
cost_per_incremental_visit: 6.45
avg_match_confidence: 0.85
statistical_significance: 0.994
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/heatmap:
get:
operationId: getCampaignHeatmap
summary: Geospatial exposure heatmap
description: |
Returns geospatial clusters of exposure and conversion density.
Answers: "WHERE are people seeing my ads and then visiting my stores?"
Each point represents a geographic cluster with exposure count,
conversion count, and density. Use for map visualizations showing
campaign impact by location.
tags: [Campaign Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Geospatial heatmap data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/HeatmapPoint'
example:
success: true
data:
- latitude: 40.7128
longitude: -74.0060
exposure_count: 3200
conversion_count: 245
density: 0.89
geohash: "dr5ru7"
- latitude: 40.7580
longitude: -73.9855
exposure_count: 2800
conversion_count: 198
density: 0.76
geohash: "dr5rub"
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/journey:
get:
operationId: getCampaignJourney
summary: Attribution journey funnel
description: |
Returns the attribution funnel showing how exposed devices progress
through the conversion journey: Exposure -> Visit -> Transaction.
Use this to understand conversion rates at each stage and identify
where the funnel leaks.
tags: [Campaign Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Journey funnel data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/JourneyFunnel'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/attention:
get:
operationId: getCampaignAttention
summary: Attention metrics summary
description: |
Returns attention-verified impression metrics from FEIN edge AI.
This is data that ONLY Trillboards can provide in DOOH.
Unlike CTV viewability which uses probabilistic models ("MRC standard"
= 50% of pixels visible for 2 seconds), Trillboards measures actual
human attention via on-device computer vision:
- **face_count**: How many people were actually in front of the screen
- **attention_score**: What fraction were looking at the screen (gaze detection)
- **dwell_seconds**: How long they stayed in view
- **emotion_engagement**: Facial expression analysis (not recording, edge-only)
- **aCPM**: Cost per 1,000 attention-verified impressions
These are MEASURED signals, not estimates.
tags: [Attention Metrics]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Attention metrics for the campaign
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/AttentionMetrics'
example:
success: true
data:
campaign_id: "camp_abc123"
total_impressions: 128500
unique_devices: 45200
attention:
avg_attention_score: 0.72
median_attention_score: 0.68
p90_attention_score: 0.94
attention_qualified_pct: 64.3
avg_dwell_seconds: 8.4
avg_face_count: 2.3
economics:
standard_cpm: 12.50
attention_cpm: 19.40
cost_per_attentive_reach: 0.34
cost_per_attentive_visit: 8.75
emotion:
avg_emotion_engagement: 0.58
positive_emotion_pct: 42.1
emotion_breakdown:
neutral: 45.2
happy: 28.3
surprised: 13.8
interested: 8.4
other: 4.3
breakdowns:
daypart_breakdown:
morning: { avg_attention: 0.78, avg_dwell: 9.2 }
afternoon: { avg_attention: 0.65, avg_dwell: 7.1 }
evening: { avg_attention: 0.74, avg_dwell: 8.8 }
venue_type_breakdown:
gym: { avg_attention: 0.85, avg_dwell: 12.3 }
coffee_shop: { avg_attention: 0.71, avg_dwell: 6.5 }
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/attention/creative:
get:
operationId: getCreativeAttentionComparison
summary: Per-creative attention comparison
description: |
Compares attention metrics across creatives within a campaign.
Answers: "Which creative gets more attention AND more store visits?"
This is the holy grail of DOOH optimization — correlating creative
execution with actual human attention and downstream conversion.
No other platform can show this because no other platform measures
attention at the creative level.
tags: [Attention Metrics]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Per-creative attention comparison
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/CreativeAttentionComparison'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/attention/timeseries:
get:
operationId: getAttentionTimeseries
summary: Attention metrics over time
description: |
Returns daily attention quality metrics. Use this to detect
attention fatigue: if attention_score drops over time while
impressions stay flat, the creative is wearing out and needs
refreshing.
tags: [Attention Metrics]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
- name: startDate
in: query
schema:
type: string
format: date
- name: endDate
in: query
schema:
type: string
format: date
responses:
'200':
description: Daily attention metrics timeseries
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/AttentionTimeseriesPoint'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/multi-touch:
get:
operationId: getMultiTouchAttribution
summary: Multi-touch attribution summary
description: |
Returns cross-channel credit allocation across DOOH, mobile, web,
and store touchpoints. Supports multiple attribution models:
- **time_decay**: Recent touchpoints get more credit (7-day half-life default)
- **position_based**: First and last touch get 40% each, middle touches share 20%
- **attention_weighted**: Credit proportional to FEIN attention score at each touchpoint
- **shapley**: Game-theory-based fair value allocation (computationally intensive)
This answers: "How much credit does DOOH deserve vs mobile vs web?"
tags: [Cross-Channel Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Multi-touch attribution data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/MultiTouchAttribution'
example:
success: true
data:
campaign_id: "camp_abc123"
model: "time_decay"
total_conversions: 1430
total_attributed_revenue_cents: 2145000
channel_credits:
dooh:
credit_pct: 42.5
attributed_conversions: 608
attributed_revenue_cents: 911625
mobile_ad:
credit_pct: 28.3
attributed_conversions: 405
attributed_revenue_cents: 607035
web_visit:
credit_pct: 18.7
attributed_conversions: 267
attributed_revenue_cents: 401115
store_visit:
credit_pct: 10.5
attributed_conversions: 150
attributed_revenue_cents: 225225
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/cross-channel-journey:
get:
operationId: getCrossChannelJourney
summary: Cross-channel journey (Sankey flow)
description: |
Returns flow data suitable for Sankey diagrams showing how users
move across channels after DOOH exposure.
Example flow: Billboard (42%) -> Mobile Ad Click (28%) -> Website Visit (18%) -> Store Purchase (12%)
Each node/link includes volume and conversion rate, enabling
visualization of the most common and most valuable paths.
tags: [Cross-Channel Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Sankey flow data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/CrossChannelJourney'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/channel-roas:
get:
operationId: getChannelROAS
summary: Per-channel ROAS
description: |
Returns return on ad spend (ROAS) broken down by channel.
Answers: "DOOH vs mobile vs web — which channel pulls its weight?"
ROAS = attributed_revenue / media_cost. A ROAS > 1.0 means the
channel generates more revenue than it costs. Use this to
justify DOOH budget allocation vs digital channels.
tags: [Cross-Channel Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Per-channel ROAS
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/ChannelROAS'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/incrementality:
get:
operationId: getCampaignIncrementality
summary: Incrementality results
description: |
Returns Bayesian uplift measurement for a campaign. This is the
gold standard of DOOH attribution — proving that store visits
WOULD NOT have happened without the campaign.
Results include:
- **Bayesian posterior**: P(lift > 0) and 95% credible intervals
- **Frequentist**: chi-square, p-value, confidence intervals
- **Propensity quality**: standardized mean difference for covariate balance
A P(lift > 0) > 0.95 indicates strong evidence of causal effect.
tags: [Incrementality]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Incrementality results
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/IncrementalityResult'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/experiment:
post:
operationId: createExperiment
summary: Create incrementality experiment
description: |
Creates a new incrementality experiment with specified design:
- **geo_holdout**: Withhold ads in control DMAs, compare visit rates
- **ghost_ad**: Serve PSA ads to control group, measure true lift
- **psa_control**: Serve public service announcements as control creatives
- **matched_market**: Match treatment/control markets on covariates
The experiment runs automatically once created. Results populate
in the experiment status endpoint as data accumulates.
tags: [Incrementality]
security:
- bearerAuth: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/CreateExperimentRequest'
example:
campaignId: "camp_abc123"
experimentType: "geo_holdout"
treatmentDmas: ["501", "602", "803"]
controlDmas: ["504", "623", "819"]
holdoutPct: 0.10
targetMde: 0.10
targetPower: 0.80
targetAlpha: 0.05
responses:
'201':
description: Experiment created
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/Experiment'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/experiment/{experimentId}:
get:
operationId: getExperiment
summary: Experiment status and results
description: |
Returns experiment configuration, status, and results (if available).
Results include both Bayesian posteriors and frequentist p-values.
tags: [Incrementality]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/experimentId'
responses:
'200':
description: Experiment details with results
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/ExperimentWithResults'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/experiment/{experimentId}/power:
get:
operationId: getExperimentPower
summary: Power analysis
description: |
Returns the required sample size to detect a given minimum detectable
effect (MDE) at specified significance and power levels.
Use this before running an experiment to ensure you'll have enough
data to detect the effect you care about.
tags: [Incrementality]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/experimentId'
- name: baselineRate
in: query
schema:
type: number
default: 0.02
description: Baseline visit rate (default 2%)
responses:
'200':
description: Power analysis results
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/PowerAnalysis'
example:
success: true
data:
required_sample_per_group: 3842
total_sample_needed: 7684
baselineRate: 0.02
mde: 0.10
alpha: 0.05
power: 0.80
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/creative-attribution:
get:
operationId: getCreativeAttribution
summary: Creative-level attribution performance
description: |
Returns attribution outcomes broken down by creative. Correlates
creative execution (attention, dwell, emotion) with downstream
outcomes (store visits, lift, cost per visit).
Includes context interaction analysis: which creative performs best
in which venue type, daypart, and weather condition.
tags: [Creative Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Creative attribution performance data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/CreativeAttributionPerformance'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/creative-attribution/{creativeId}/timeseries:
get:
operationId: getCreativeAttributionTimeseries
summary: Creative attribution over time
description: |
Returns daily attribution metrics for a specific creative.
Use this to detect creative fatigue: if attention degrades while
impressions stay constant, rotate the creative.
tags: [Creative Attribution]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
- name: creativeId
in: path
required: true
schema:
type: string
pattern: '^[a-zA-Z0-9_-]{1,128}$'
description: Creative identifier
responses:
'200':
description: Creative timeseries data
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
type: array
items:
$ref: '#/components/schemas/CreativeAttributionTimeseriesPoint'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/cohort/export:
post:
operationId: exportCohort
summary: Export cohort to DSP
description: |
Exports the exposed audience cohort (SHA-256 hashed MAID list) to
a DSP for retargeting activation. Supported destinations:
- **ttd**: The Trade Desk (1P data segment upload)
- **dv360**: Google Display & Video 360 (Customer Match)
- **meta**: Meta/Facebook (Custom Audiences)
Returns a pre-signed S3 URL for the exported file and the MAID count.
tags: [Cohort Export]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [destination]
properties:
destination:
type: string
enum: [ttd, dv360, meta]
description: Target DSP platform
example:
destination: "ttd"
responses:
'200':
description: Cohort exported successfully
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/CohortExport'
example:
success: true
data:
exportId: "exp_a1b2c3d4"
s3Url: "https://trillboards-cohorts.s3.amazonaws.com/exports/camp_abc123/ttd/2026-02-28.csv?X-Amz-..."
maidCount: 45200
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/signal-quality:
get:
operationId: getSignalQuality
summary: Signal quality and coverage
description: |
Returns signal quality metrics showing how complete and fresh the
attribution data is for this campaign. This is radical transparency —
no other DOOH platform exposes their data quality at the campaign level.
Use this to assess confidence in attribution results:
- High attention_coverage_pct = most impressions have FEIN verification
- Low avg_signal_age_seconds = signals are fresh (real-time, not batch)
- High bayesian_prob_positive = strong evidence of causal effect
tags: [Signal Transparency]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Signal quality report
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
data:
$ref: '#/components/schemas/SignalQuality'
example:
success: true
data:
campaign_id: "camp_abc123"
signal_coverage:
attention_coverage_pct: 87.3
fein_matched_pct: 92.1
identity_resolved_pct: 74.5
footfall_measured_pct: 68.2
signal_freshness:
avg_signal_age_seconds: 18
p95_signal_age_seconds: 45
measurement_confidence:
exposure_matching_avg_confidence: 0.82
attention_weighted_avg_confidence: 0.91
incrementality_p_value: 0.003
bayesian_prob_positive: 0.997
data_provenance:
device_signal_source: "intuizi"
attention_source: "fein_edge_ai"
proof_of_play: "ed25519_signed"
identity_graph_depth: 2
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'500':
$ref: '#/components/responses/ServerError'
/v1/advertiser/attribution/campaign/{campaignId}/methodology:
get:
operationId: getMethodology
summary: Attribution methodology explanation
description: |
Returns a human-readable explanation of how attribution was computed
for THIS specific campaign. Covers exposure matching methodology,
attention enrichment, incrementality measurement approach, and
cross-channel attribution model.
This is RADICAL TRANSPARENCY — no other DOOH platform explains
their methodology at the campaign level.
tags: [Signal Transparency]
security:
- bearerAuth: []
parameters:
- $ref: '#/components/parameters/campaignId'
responses:
'200':
description: Methodology explanation