@adcp/client 4.22.1 → 4.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -9
- package/bin/adcp.js +83 -18
- package/dist/lib/index.d.ts +3 -5
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/index.js +16 -12
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/server/index.d.ts +5 -1
- package/dist/lib/server/index.d.ts.map +1 -1
- package/dist/lib/server/index.js +10 -1
- package/dist/lib/server/index.js.map +1 -1
- package/dist/lib/server/postgres-task-store.d.ts +105 -0
- package/dist/lib/server/postgres-task-store.d.ts.map +1 -0
- package/dist/lib/server/postgres-task-store.js +267 -0
- package/dist/lib/server/postgres-task-store.js.map +1 -0
- package/dist/lib/server/responses.d.ts +1 -0
- package/dist/lib/server/responses.d.ts.map +1 -1
- package/dist/lib/server/responses.js +1 -0
- package/dist/lib/server/responses.js.map +1 -1
- package/dist/lib/server/test-controller.d.ts +88 -0
- package/dist/lib/server/test-controller.d.ts.map +1 -0
- package/dist/lib/server/test-controller.js +227 -0
- package/dist/lib/server/test-controller.js.map +1 -0
- package/dist/lib/testing/agent-tester.d.ts +1 -1
- package/dist/lib/testing/agent-tester.d.ts.map +1 -1
- package/dist/lib/testing/agent-tester.js +13 -1
- package/dist/lib/testing/agent-tester.js.map +1 -1
- package/dist/lib/testing/compliance/comply.d.ts +24 -5
- package/dist/lib/testing/compliance/comply.d.ts.map +1 -1
- package/dist/lib/testing/compliance/comply.js +318 -277
- package/dist/lib/testing/compliance/comply.js.map +1 -1
- package/dist/lib/testing/compliance/index.d.ts +2 -1
- package/dist/lib/testing/compliance/index.d.ts.map +1 -1
- package/dist/lib/testing/compliance/index.js +6 -1
- package/dist/lib/testing/compliance/index.js.map +1 -1
- package/dist/lib/testing/compliance/platform-storyboards.d.ts +44 -0
- package/dist/lib/testing/compliance/platform-storyboards.d.ts.map +1 -0
- package/dist/lib/testing/compliance/platform-storyboards.js +232 -0
- package/dist/lib/testing/compliance/platform-storyboards.js.map +1 -0
- package/dist/lib/testing/compliance/storyboard-tracks.d.ts +2 -9
- package/dist/lib/testing/compliance/storyboard-tracks.d.ts.map +1 -1
- package/dist/lib/testing/compliance/storyboard-tracks.js +15 -46
- package/dist/lib/testing/compliance/storyboard-tracks.js.map +1 -1
- package/dist/lib/testing/compliance/types.d.ts +22 -1
- package/dist/lib/testing/compliance/types.d.ts.map +1 -1
- package/dist/lib/testing/index.d.ts +1 -1
- package/dist/lib/testing/index.d.ts.map +1 -1
- package/dist/lib/testing/index.js +6 -1
- package/dist/lib/testing/index.js.map +1 -1
- package/dist/lib/testing/orchestrator.d.ts.map +1 -1
- package/dist/lib/testing/orchestrator.js +5 -1
- package/dist/lib/testing/orchestrator.js.map +1 -1
- package/dist/lib/testing/scenarios/brand-rights.d.ts +19 -1
- package/dist/lib/testing/scenarios/brand-rights.d.ts.map +1 -1
- package/dist/lib/testing/scenarios/brand-rights.js +138 -1
- package/dist/lib/testing/scenarios/brand-rights.js.map +1 -1
- package/dist/lib/testing/scenarios/deterministic.js +7 -7
- package/dist/lib/testing/scenarios/deterministic.js.map +1 -1
- package/dist/lib/testing/scenarios/index.d.ts +1 -1
- package/dist/lib/testing/scenarios/index.d.ts.map +1 -1
- package/dist/lib/testing/scenarios/index.js +4 -2
- package/dist/lib/testing/scenarios/index.js.map +1 -1
- package/dist/lib/testing/scenarios/media-buy.js +4 -4
- package/dist/lib/testing/scenarios/media-buy.js.map +1 -1
- package/dist/lib/testing/storyboard/loader.d.ts +1 -0
- package/dist/lib/testing/storyboard/loader.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/loader.js +14 -0
- package/dist/lib/testing/storyboard/loader.js.map +1 -1
- package/dist/lib/testing/storyboard/request-builder.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/request-builder.js +88 -11
- package/dist/lib/testing/storyboard/request-builder.js.map +1 -1
- package/dist/lib/testing/storyboard/runner.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/runner.js +83 -5
- package/dist/lib/testing/storyboard/runner.js.map +1 -1
- package/dist/lib/testing/storyboard/task-map.d.ts +2 -0
- package/dist/lib/testing/storyboard/task-map.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/task-map.js +23 -9
- package/dist/lib/testing/storyboard/task-map.js.map +1 -1
- package/dist/lib/testing/storyboard/types.d.ts +6 -2
- package/dist/lib/testing/storyboard/types.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/validations.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/validations.js +21 -4
- package/dist/lib/testing/storyboard/validations.js.map +1 -1
- package/dist/lib/testing/types.d.ts +1 -1
- package/dist/lib/testing/types.d.ts.map +1 -1
- package/dist/lib/types/core.generated.d.ts +242 -3
- package/dist/lib/types/core.generated.d.ts.map +1 -1
- package/dist/lib/types/core.generated.js +1 -1
- package/dist/lib/types/schemas.generated.d.ts +3697 -3468
- package/dist/lib/types/schemas.generated.d.ts.map +1 -1
- package/dist/lib/types/schemas.generated.js +226 -118
- package/dist/lib/types/schemas.generated.js.map +1 -1
- package/dist/lib/types/tools.generated.d.ts +281 -79
- package/dist/lib/types/tools.generated.d.ts.map +1 -1
- package/dist/lib/utils/capabilities.d.ts +2 -2
- package/dist/lib/utils/capabilities.d.ts.map +1 -1
- package/dist/lib/utils/capabilities.js +9 -3
- package/dist/lib/utils/capabilities.js.map +1 -1
- package/dist/lib/utils/response-schemas.d.ts.map +1 -1
- package/dist/lib/utils/response-schemas.js +9 -0
- package/dist/lib/utils/response-schemas.js.map +1 -1
- package/dist/lib/version.d.ts +3 -3
- package/dist/lib/version.js +3 -3
- package/docs/llms.txt +56 -32
- package/package.json +8 -2
- package/skills/adcp/SKILL.md +118 -33
- package/skills/build-creative-agent/SKILL.md +221 -0
- package/skills/build-generative-seller-agent/SKILL.md +288 -0
- package/skills/build-retail-media-agent/SKILL.md +237 -0
- package/skills/build-seller-agent/SKILL.md +313 -0
- package/skills/build-signals-agent/SKILL.md +203 -0
- package/storyboards/audience_sync.yaml +18 -29
- package/storyboards/behavioral_analysis.yaml +40 -72
- package/storyboards/brand_rights.yaml +172 -75
- package/storyboards/campaign_governance_conditions.yaml +187 -0
- package/storyboards/campaign_governance_delivery.yaml +231 -0
- package/storyboards/campaign_governance_denied.yaml +136 -0
- package/storyboards/capability_discovery.yaml +106 -0
- package/storyboards/content_standards.yaml +251 -0
- package/storyboards/creative_ad_server.yaml +108 -16
- package/storyboards/creative_generative.yaml +317 -0
- package/storyboards/creative_lifecycle.yaml +284 -0
- package/storyboards/creative_sales_agent.yaml +2 -6
- package/storyboards/creative_template.yaml +3 -6
- package/storyboards/deterministic_testing.yaml +271 -245
- package/storyboards/error_compliance.yaml +105 -108
- package/storyboards/media_buy_catalog_creative.yaml +8 -5
- package/storyboards/media_buy_generative_seller.yaml +581 -0
- package/storyboards/media_buy_governance_escalation.yaml +10 -6
- package/storyboards/media_buy_guaranteed_approval.yaml +21 -19
- package/storyboards/media_buy_non_guaranteed.yaml +9 -8
- package/storyboards/media_buy_proposal_mode.yaml +12 -11
- package/storyboards/media_buy_seller.yaml +161 -173
- package/storyboards/media_buy_state_machine.yaml +102 -101
- package/storyboards/property_governance.yaml +239 -0
- package/storyboards/schema.yaml +3 -2
- package/storyboards/schema_validation.yaml +58 -51
- package/storyboards/si_session.yaml +99 -317
- package/storyboards/signal_marketplace.yaml +9 -5
- package/storyboards/signal_owned.yaml +6 -5
- package/storyboards/social_platform.yaml +274 -0
- package/storyboards/test-kits/acme-outdoor.yaml +118 -0
- package/storyboards/test-kits/nova-motors.yaml +134 -0
- package/storyboards/governance_content_standards.yaml +0 -213
- package/storyboards/governance_property_lists.yaml +0 -372
|
@@ -1,25 +1,13 @@
|
|
|
1
1
|
id: media_buy_seller
|
|
2
|
-
version:
|
|
3
|
-
title:
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
title: "Media buy seller agent"
|
|
4
4
|
category: media_buy_seller
|
|
5
|
-
summary:
|
|
6
|
-
|
|
7
|
-
- display_ad_server
|
|
8
|
-
- video_ad_server
|
|
9
|
-
- social_platform
|
|
10
|
-
- retail_media
|
|
11
|
-
- search_platform
|
|
12
|
-
- audio_platform
|
|
13
|
-
- linear_tv_platform
|
|
14
|
-
- dsp
|
|
15
|
-
- pmax_platform
|
|
16
|
-
- ai_ad_network
|
|
17
|
-
- ai_platform
|
|
18
|
-
- generative_dsp
|
|
19
|
-
|
|
20
|
-
track: reporting
|
|
5
|
+
summary: "Seller agent that receives briefs, returns products, accepts media buys, and reports delivery."
|
|
6
|
+
track: media_buy
|
|
21
7
|
required_tools:
|
|
22
|
-
-
|
|
8
|
+
- get_products
|
|
9
|
+
- create_media_buy
|
|
10
|
+
|
|
23
11
|
narrative: |
|
|
24
12
|
You run a sell-side platform — a publisher, SSP, retail media network, or any system that
|
|
25
13
|
sells advertising inventory. A buyer agent connects to discover your products, negotiate
|
|
@@ -41,25 +29,25 @@ agent:
|
|
|
41
29
|
- supports_guaranteed
|
|
42
30
|
- supports_non_guaranteed
|
|
43
31
|
examples:
|
|
44
|
-
-
|
|
45
|
-
-
|
|
46
|
-
-
|
|
47
|
-
-
|
|
32
|
+
- "Yahoo"
|
|
33
|
+
- "Retail media networks"
|
|
34
|
+
- "Publisher platforms"
|
|
35
|
+
- "SSPs"
|
|
48
36
|
|
|
49
37
|
caller:
|
|
50
38
|
role: buyer_agent
|
|
51
|
-
example:
|
|
39
|
+
example: "Scope3 (DSP)"
|
|
52
40
|
|
|
53
41
|
prerequisites:
|
|
54
42
|
description: |
|
|
55
43
|
The caller needs a brand identity and operator credentials for account setup.
|
|
56
44
|
The test kit provides a sample brand (Acme Outdoor) with campaign parameters
|
|
57
45
|
suitable for testing the full media buy flow.
|
|
58
|
-
test_kit:
|
|
46
|
+
test_kit: "test-kits/acme-outdoor.yaml"
|
|
59
47
|
|
|
60
48
|
phases:
|
|
61
49
|
- id: account_setup
|
|
62
|
-
title:
|
|
50
|
+
title: "Account setup"
|
|
63
51
|
narrative: |
|
|
64
52
|
Before buying anything, the buyer establishes an account relationship with
|
|
65
53
|
your platform. This is the handshake: the buyer tells you which brand and
|
|
@@ -72,7 +60,7 @@ phases:
|
|
|
72
60
|
|
|
73
61
|
steps:
|
|
74
62
|
- id: sync_accounts
|
|
75
|
-
title:
|
|
63
|
+
title: "Establish account relationship"
|
|
76
64
|
narrative: |
|
|
77
65
|
The buyer registers their brand and operator with your platform. This is
|
|
78
66
|
the first call in any new relationship. Your platform validates the request,
|
|
@@ -82,10 +70,10 @@ phases:
|
|
|
82
70
|
return pending_approval with a setup URL. The buyer will complete setup there
|
|
83
71
|
and poll list_accounts until the status changes to active.
|
|
84
72
|
task: sync_accounts
|
|
85
|
-
schema_ref:
|
|
86
|
-
response_schema_ref:
|
|
87
|
-
doc_ref:
|
|
88
|
-
|
|
73
|
+
schema_ref: "account/sync-accounts-request.json"
|
|
74
|
+
response_schema_ref: "account/sync-accounts-response.json"
|
|
75
|
+
doc_ref: "/accounts/tasks/sync_accounts"
|
|
76
|
+
# No TestScenario exists for account setup
|
|
89
77
|
stateful: true
|
|
90
78
|
expected: |
|
|
91
79
|
Return the account with:
|
|
@@ -100,23 +88,23 @@ phases:
|
|
|
100
88
|
sample_request:
|
|
101
89
|
accounts:
|
|
102
90
|
- brand:
|
|
103
|
-
domain:
|
|
104
|
-
operator:
|
|
105
|
-
billing:
|
|
106
|
-
payment_terms:
|
|
91
|
+
domain: "acmeoutdoor.com"
|
|
92
|
+
operator: "pinnacle-agency.com"
|
|
93
|
+
billing: "operator"
|
|
94
|
+
payment_terms: "net_30"
|
|
107
95
|
|
|
108
96
|
validations:
|
|
109
97
|
- check: response_schema
|
|
110
|
-
description:
|
|
98
|
+
description: "Response matches sync-accounts-response.json schema"
|
|
111
99
|
- check: field_present
|
|
112
|
-
path:
|
|
113
|
-
description:
|
|
100
|
+
path: "accounts[0].account_id"
|
|
101
|
+
description: "Account has a platform-assigned ID"
|
|
114
102
|
- check: field_present
|
|
115
|
-
path:
|
|
116
|
-
description:
|
|
103
|
+
path: "accounts[0].status"
|
|
104
|
+
description: "Account has a status (active or pending_approval)"
|
|
117
105
|
|
|
118
106
|
- id: governance_setup
|
|
119
|
-
title:
|
|
107
|
+
title: "Governance agent registration"
|
|
120
108
|
narrative: |
|
|
121
109
|
The buyer registers their governance agent with your platform. This tells your
|
|
122
110
|
platform where to call check_governance before confirming media buys. The
|
|
@@ -129,7 +117,7 @@ phases:
|
|
|
129
117
|
|
|
130
118
|
steps:
|
|
131
119
|
- id: sync_governance
|
|
132
|
-
title:
|
|
120
|
+
title: "Register governance agents"
|
|
133
121
|
narrative: |
|
|
134
122
|
The buyer tells your platform: "Before you confirm any media buy for this
|
|
135
123
|
account, call this governance agent to validate it." Your platform stores
|
|
@@ -138,10 +126,10 @@ phases:
|
|
|
138
126
|
This uses replace semantics — each sync_governance call replaces any
|
|
139
127
|
previously registered agents for the account.
|
|
140
128
|
task: sync_governance
|
|
141
|
-
schema_ref:
|
|
142
|
-
response_schema_ref:
|
|
143
|
-
doc_ref:
|
|
144
|
-
|
|
129
|
+
schema_ref: "account/sync-governance-request.json"
|
|
130
|
+
response_schema_ref: "account/sync-governance-response.json"
|
|
131
|
+
doc_ref: "/accounts/tasks/sync_governance"
|
|
132
|
+
# No TestScenario exists for governance registration
|
|
145
133
|
stateful: true
|
|
146
134
|
expected: |
|
|
147
135
|
Acknowledge the governance agents. Your platform should:
|
|
@@ -153,21 +141,21 @@ phases:
|
|
|
153
141
|
accounts:
|
|
154
142
|
- account:
|
|
155
143
|
brand:
|
|
156
|
-
domain:
|
|
157
|
-
operator:
|
|
144
|
+
domain: "acmeoutdoor.com"
|
|
145
|
+
operator: "pinnacle-agency.com"
|
|
158
146
|
governance_agents:
|
|
159
|
-
- url:
|
|
147
|
+
- url: "https://governance.pinnacle-agency.example"
|
|
160
148
|
authentication:
|
|
161
|
-
schemes: [
|
|
162
|
-
credentials:
|
|
163
|
-
categories: [
|
|
149
|
+
schemes: ["Bearer"]
|
|
150
|
+
credentials: "gov-token-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
|
|
151
|
+
categories: ["budget_authority", "brand_policy"]
|
|
164
152
|
|
|
165
153
|
validations:
|
|
166
154
|
- check: response_schema
|
|
167
|
-
description:
|
|
155
|
+
description: "Response matches sync-governance-response.json schema"
|
|
168
156
|
|
|
169
157
|
- id: product_discovery
|
|
170
|
-
title:
|
|
158
|
+
title: "Product discovery"
|
|
171
159
|
narrative: |
|
|
172
160
|
The buyer sends a natural-language brief describing what they want to buy.
|
|
173
161
|
Your platform interprets the brief against your inventory and returns products —
|
|
@@ -180,7 +168,7 @@ phases:
|
|
|
180
168
|
|
|
181
169
|
steps:
|
|
182
170
|
- id: get_products_brief
|
|
183
|
-
title:
|
|
171
|
+
title: "Send a brief"
|
|
184
172
|
narrative: |
|
|
185
173
|
The buyer describes what they want in natural language. Your platform returns
|
|
186
174
|
products that match the brief, including pricing options, delivery forecasts,
|
|
@@ -190,10 +178,10 @@ phases:
|
|
|
190
178
|
against your inventory catalog. If the brief is ambiguous, you can return
|
|
191
179
|
input-required to ask clarifying questions before producing results.
|
|
192
180
|
task: get_products
|
|
193
|
-
schema_ref:
|
|
194
|
-
response_schema_ref:
|
|
195
|
-
doc_ref:
|
|
196
|
-
comply_scenario:
|
|
181
|
+
schema_ref: "media-buy/get-products-request.json"
|
|
182
|
+
response_schema_ref: "media-buy/get-products-response.json"
|
|
183
|
+
doc_ref: "/media-buy/task-reference/get_products"
|
|
184
|
+
comply_scenario: full_sales_flow
|
|
197
185
|
stateful: false
|
|
198
186
|
expected: |
|
|
199
187
|
Return products matching the brief. Each product should include:
|
|
@@ -211,30 +199,30 @@ phases:
|
|
|
211
199
|
If the brief is unclear, return input-required with clarifying questions.
|
|
212
200
|
|
|
213
201
|
sample_request:
|
|
214
|
-
buying_mode:
|
|
215
|
-
brief:
|
|
202
|
+
buying_mode: "brief"
|
|
203
|
+
brief: "Premium video inventory on sports and outdoor lifestyle publishers. Q2 flight, $50K budget. Adults 25-54, US and Canada."
|
|
216
204
|
brand:
|
|
217
|
-
domain:
|
|
205
|
+
domain: "acmeoutdoor.com"
|
|
218
206
|
account:
|
|
219
207
|
brand:
|
|
220
|
-
domain:
|
|
221
|
-
operator:
|
|
208
|
+
domain: "acmeoutdoor.com"
|
|
209
|
+
operator: "pinnacle-agency.com"
|
|
222
210
|
|
|
223
211
|
validations:
|
|
224
212
|
- check: response_schema
|
|
225
|
-
description:
|
|
213
|
+
description: "Response matches get-products-response.json schema"
|
|
226
214
|
- check: field_present
|
|
227
|
-
path:
|
|
228
|
-
description:
|
|
215
|
+
path: "products"
|
|
216
|
+
description: "Response contains a products array"
|
|
229
217
|
- check: field_present
|
|
230
|
-
path:
|
|
231
|
-
description:
|
|
218
|
+
path: "products[0].product_id"
|
|
219
|
+
description: "Each product has a product_id"
|
|
232
220
|
- check: field_present
|
|
233
|
-
path:
|
|
234
|
-
description:
|
|
221
|
+
path: "products[0].delivery_type"
|
|
222
|
+
description: "Each product declares guaranteed or non_guaranteed delivery"
|
|
235
223
|
|
|
236
224
|
- id: proposal_refinement
|
|
237
|
-
title:
|
|
225
|
+
title: "Proposal refinement"
|
|
238
226
|
narrative: |
|
|
239
227
|
The buyer reviews the products from the brief and wants to narrow down. They
|
|
240
228
|
switch to refine mode, layering constraints without starting over. Each refinement
|
|
@@ -246,16 +234,16 @@ phases:
|
|
|
246
234
|
|
|
247
235
|
steps:
|
|
248
236
|
- id: get_products_refine
|
|
249
|
-
title:
|
|
237
|
+
title: "Refine the proposal"
|
|
250
238
|
narrative: |
|
|
251
239
|
The buyer has reviewed the initial products and wants adjustments. They call
|
|
252
240
|
get_products with buying_mode: refine and a refine array describing what to
|
|
253
241
|
change. Your platform applies the refinements and returns updated products.
|
|
254
242
|
task: get_products
|
|
255
|
-
schema_ref:
|
|
256
|
-
response_schema_ref:
|
|
257
|
-
doc_ref:
|
|
258
|
-
comply_scenario:
|
|
243
|
+
schema_ref: "media-buy/get-products-request.json"
|
|
244
|
+
response_schema_ref: "media-buy/get-products-response.json"
|
|
245
|
+
doc_ref: "/media-buy/task-reference/get_products"
|
|
246
|
+
comply_scenario: full_sales_flow
|
|
259
247
|
stateful: true
|
|
260
248
|
expected: |
|
|
261
249
|
Return updated products reflecting the refinements. The response should:
|
|
@@ -265,29 +253,29 @@ phases:
|
|
|
265
253
|
- Update pricing and forecasts to reflect the changes
|
|
266
254
|
|
|
267
255
|
sample_request:
|
|
268
|
-
buying_mode:
|
|
256
|
+
buying_mode: "refine"
|
|
269
257
|
refine:
|
|
270
|
-
- scope:
|
|
271
|
-
ask:
|
|
272
|
-
- scope:
|
|
273
|
-
product_id:
|
|
274
|
-
ask:
|
|
258
|
+
- scope: "request"
|
|
259
|
+
ask: "Only guaranteed packages. Must include completion rate SLA above 80%."
|
|
260
|
+
- scope: "product"
|
|
261
|
+
product_id: "sports_preroll_q2"
|
|
262
|
+
ask: "Increase budget allocation to $30K"
|
|
275
263
|
brand:
|
|
276
|
-
domain:
|
|
264
|
+
domain: "acmeoutdoor.com"
|
|
277
265
|
account:
|
|
278
266
|
brand:
|
|
279
|
-
domain:
|
|
280
|
-
operator:
|
|
267
|
+
domain: "acmeoutdoor.com"
|
|
268
|
+
operator: "pinnacle-agency.com"
|
|
281
269
|
|
|
282
270
|
validations:
|
|
283
271
|
- check: response_schema
|
|
284
|
-
description:
|
|
272
|
+
description: "Response matches get-products-response.json schema"
|
|
285
273
|
- check: field_present
|
|
286
|
-
path:
|
|
287
|
-
description:
|
|
274
|
+
path: "products"
|
|
275
|
+
description: "Response contains updated products"
|
|
288
276
|
|
|
289
277
|
- id: create_buy
|
|
290
|
-
title:
|
|
278
|
+
title: "Create the media buy"
|
|
291
279
|
narrative: |
|
|
292
280
|
The buyer is satisfied with the products and creates a media buy. This is the
|
|
293
281
|
equivalent of signing an IO — the buyer commits to specific products, budgets,
|
|
@@ -304,7 +292,7 @@ phases:
|
|
|
304
292
|
|
|
305
293
|
steps:
|
|
306
294
|
- id: create_media_buy
|
|
307
|
-
title:
|
|
295
|
+
title: "Create a media buy"
|
|
308
296
|
narrative: |
|
|
309
297
|
The buyer commits to specific products with budgets and flight dates. Your
|
|
310
298
|
platform validates the request, optionally calls governance, and either confirms
|
|
@@ -315,23 +303,23 @@ phases:
|
|
|
315
303
|
- Proposal: buyer passes a proposal_id from get_products to execute a proposal
|
|
316
304
|
|
|
317
305
|
The response status tells the buyer what happens next:
|
|
318
|
-
- completed: buy is
|
|
306
|
+
- completed: buy is active and live
|
|
319
307
|
- working: your platform is processing (poll or wait for webhook)
|
|
320
308
|
- submitted: long-running async — approval workflow, IO signing, etc.
|
|
321
309
|
- input-required: need more information (budget clarification, approval)
|
|
322
310
|
task: create_media_buy
|
|
323
|
-
schema_ref:
|
|
324
|
-
response_schema_ref:
|
|
325
|
-
doc_ref:
|
|
326
|
-
comply_scenario:
|
|
311
|
+
schema_ref: "media-buy/create-media-buy-request.json"
|
|
312
|
+
response_schema_ref: "media-buy/create-media-buy-response.json"
|
|
313
|
+
doc_ref: "/media-buy/task-reference/create_media_buy"
|
|
314
|
+
comply_scenario: create_media_buy
|
|
327
315
|
stateful: true
|
|
328
316
|
expected: |
|
|
329
317
|
Process the media buy request and return one of:
|
|
330
318
|
|
|
331
319
|
Synchronous (completed):
|
|
332
320
|
- media_buy_id: your platform's identifier
|
|
333
|
-
- status:
|
|
334
|
-
- packages:
|
|
321
|
+
- status: active or pending_creatives
|
|
322
|
+
- packages: line items with pricing
|
|
335
323
|
- confirmed_at: timestamp
|
|
336
324
|
- valid_actions: what the buyer can do next
|
|
337
325
|
|
|
@@ -351,75 +339,75 @@ phases:
|
|
|
351
339
|
sample_request:
|
|
352
340
|
account:
|
|
353
341
|
brand:
|
|
354
|
-
domain:
|
|
355
|
-
operator:
|
|
342
|
+
domain: "acmeoutdoor.com"
|
|
343
|
+
operator: "pinnacle-agency.com"
|
|
356
344
|
brand:
|
|
357
|
-
domain:
|
|
358
|
-
start_time:
|
|
359
|
-
end_time:
|
|
345
|
+
domain: "acmeoutdoor.com"
|
|
346
|
+
start_time: "2026-04-01T00:00:00Z"
|
|
347
|
+
end_time: "2026-06-30T23:59:59Z"
|
|
360
348
|
packages:
|
|
361
|
-
- product_id:
|
|
349
|
+
- product_id: "sports_preroll_q2"
|
|
362
350
|
budget: 25000
|
|
363
|
-
pricing_option_id:
|
|
351
|
+
pricing_option_id: "cpm_guaranteed"
|
|
364
352
|
creative_assignments:
|
|
365
|
-
- creative_id:
|
|
366
|
-
- product_id:
|
|
353
|
+
- creative_id: "video_30s_trail_pro"
|
|
354
|
+
- product_id: "lifestyle_display_q2"
|
|
367
355
|
budget: 15000
|
|
368
|
-
pricing_option_id:
|
|
356
|
+
pricing_option_id: "cpm_standard"
|
|
369
357
|
push_notification_config:
|
|
370
|
-
url:
|
|
358
|
+
url: "https://buyer.example/webhooks/adcp"
|
|
371
359
|
authentication:
|
|
372
|
-
scheme:
|
|
360
|
+
scheme: "HMAC-SHA256"
|
|
373
361
|
|
|
374
362
|
validations:
|
|
375
363
|
- check: response_schema
|
|
376
|
-
description:
|
|
364
|
+
description: "Response matches create-media-buy-response.json schema"
|
|
377
365
|
|
|
378
366
|
- id: check_buy_status
|
|
379
|
-
title:
|
|
367
|
+
title: "Check media buy status"
|
|
380
368
|
narrative: |
|
|
381
369
|
If create_media_buy returned working or submitted, the buyer polls for status
|
|
382
370
|
updates. Your platform returns the current state of the media buy — whether
|
|
383
|
-
it's still processing, awaiting approval, or
|
|
371
|
+
it's still processing, awaiting approval, or active.
|
|
384
372
|
|
|
385
373
|
This is also how the buyer checks for pending_approval status. If your platform
|
|
386
374
|
requires IO signing or human authorization, the buy sits at pending_approval
|
|
387
375
|
until the human completes the action. Your platform sends back a URL where the
|
|
388
376
|
human goes to approve.
|
|
389
377
|
task: get_media_buys
|
|
390
|
-
schema_ref:
|
|
391
|
-
response_schema_ref:
|
|
392
|
-
doc_ref:
|
|
393
|
-
comply_scenario:
|
|
378
|
+
schema_ref: "media-buy/get-media-buys-request.json"
|
|
379
|
+
response_schema_ref: "media-buy/get-media-buys-response.json"
|
|
380
|
+
doc_ref: "/media-buy/task-reference/get_media_buys"
|
|
381
|
+
comply_scenario: media_buy_lifecycle
|
|
394
382
|
stateful: true
|
|
395
383
|
expected: |
|
|
396
384
|
Return the current state of the media buy:
|
|
397
385
|
- media_buy_id: matches what was returned from create_media_buy
|
|
398
|
-
- status:
|
|
386
|
+
- status: pending_creatives, pending_start, active, paused, completed, rejected, canceled
|
|
399
387
|
- packages: line items with current delivery status
|
|
400
388
|
- valid_actions: what operations are available in this state
|
|
401
389
|
|
|
402
|
-
If
|
|
403
|
-
- Include
|
|
404
|
-
-
|
|
390
|
+
If pending_creatives:
|
|
391
|
+
- Include message explaining what creatives are needed
|
|
392
|
+
- valid_actions should include sync_creatives
|
|
405
393
|
|
|
406
394
|
sample_request:
|
|
407
395
|
account:
|
|
408
396
|
brand:
|
|
409
|
-
domain:
|
|
410
|
-
operator:
|
|
397
|
+
domain: "acmeoutdoor.com"
|
|
398
|
+
operator: "pinnacle-agency.com"
|
|
411
399
|
media_buy_ids:
|
|
412
|
-
-
|
|
400
|
+
- "mb_acme_q2_2026"
|
|
413
401
|
|
|
414
402
|
validations:
|
|
415
403
|
- check: response_schema
|
|
416
|
-
description:
|
|
404
|
+
description: "Response matches get-media-buys-response.json schema"
|
|
417
405
|
- check: field_present
|
|
418
|
-
path:
|
|
419
|
-
description:
|
|
406
|
+
path: "media_buys[0].status"
|
|
407
|
+
description: "Each media buy has a status"
|
|
420
408
|
|
|
421
409
|
- id: creative_sync
|
|
422
|
-
title:
|
|
410
|
+
title: "Creative sync"
|
|
423
411
|
narrative: |
|
|
424
412
|
With the media buy confirmed, the buyer syncs creative assets to your platform.
|
|
425
413
|
Each package in the buy has creative format requirements — the buyer discovered
|
|
@@ -431,16 +419,16 @@ phases:
|
|
|
431
419
|
|
|
432
420
|
steps:
|
|
433
421
|
- id: list_formats
|
|
434
|
-
title:
|
|
422
|
+
title: "Check creative format requirements"
|
|
435
423
|
narrative: |
|
|
436
424
|
The buyer confirms what creative formats the confirmed packages require.
|
|
437
425
|
Your platform returns format specs with asset requirements, dimensions,
|
|
438
426
|
and constraints.
|
|
439
427
|
task: list_creative_formats
|
|
440
|
-
schema_ref:
|
|
441
|
-
response_schema_ref:
|
|
442
|
-
doc_ref:
|
|
443
|
-
comply_scenario:
|
|
428
|
+
schema_ref: "creative/list-creative-formats-request.json"
|
|
429
|
+
response_schema_ref: "creative/list-creative-formats-response.json"
|
|
430
|
+
doc_ref: "/creative/task-reference/list_creative_formats"
|
|
431
|
+
comply_scenario: creative_lifecycle
|
|
444
432
|
stateful: false
|
|
445
433
|
expected: |
|
|
446
434
|
Return creative formats your platform accepts. Each format should define:
|
|
@@ -452,21 +440,21 @@ phases:
|
|
|
452
440
|
|
|
453
441
|
validations:
|
|
454
442
|
- check: response_schema
|
|
455
|
-
description:
|
|
443
|
+
description: "Response matches list-creative-formats-response.json schema"
|
|
456
444
|
- check: field_present
|
|
457
|
-
path:
|
|
458
|
-
description:
|
|
445
|
+
path: "formats"
|
|
446
|
+
description: "Response contains formats array"
|
|
459
447
|
|
|
460
448
|
- id: sync_creatives
|
|
461
|
-
title:
|
|
449
|
+
title: "Push creative assets"
|
|
462
450
|
narrative: |
|
|
463
451
|
The buyer uploads creative assets for the confirmed packages. Your platform
|
|
464
452
|
validates each creative against the format specs, transcodes if necessary,
|
|
465
453
|
and returns per-creative status.
|
|
466
454
|
task: sync_creatives
|
|
467
|
-
schema_ref:
|
|
468
|
-
response_schema_ref:
|
|
469
|
-
doc_ref:
|
|
455
|
+
schema_ref: "creative/sync-creatives-request.json"
|
|
456
|
+
response_schema_ref: "creative/sync-creatives-response.json"
|
|
457
|
+
doc_ref: "/creative/task-reference/sync_creatives"
|
|
470
458
|
comply_scenario: creative_sync
|
|
471
459
|
stateful: true
|
|
472
460
|
expected: |
|
|
@@ -479,39 +467,39 @@ phases:
|
|
|
479
467
|
sample_request:
|
|
480
468
|
account:
|
|
481
469
|
brand:
|
|
482
|
-
domain:
|
|
483
|
-
operator:
|
|
470
|
+
domain: "acmeoutdoor.com"
|
|
471
|
+
operator: "pinnacle-agency.com"
|
|
484
472
|
creatives:
|
|
485
|
-
- creative_id:
|
|
486
|
-
name:
|
|
473
|
+
- creative_id: "video_30s_trail_pro"
|
|
474
|
+
name: "Trail Pro 3000 - 30s CTV Spot"
|
|
487
475
|
format_id:
|
|
488
|
-
agent_url:
|
|
489
|
-
id:
|
|
476
|
+
agent_url: "https://your-platform.example.com"
|
|
477
|
+
id: "ssai_30s"
|
|
490
478
|
assets:
|
|
491
|
-
- asset_id:
|
|
492
|
-
asset_type:
|
|
493
|
-
url:
|
|
494
|
-
mime_type:
|
|
495
|
-
- creative_id:
|
|
496
|
-
name:
|
|
479
|
+
- asset_id: "video"
|
|
480
|
+
asset_type: "video"
|
|
481
|
+
url: "https://cdn.pinnacle-agency.example/trail-pro-30s.mp4"
|
|
482
|
+
mime_type: "video/mp4"
|
|
483
|
+
- creative_id: "display_trail_pro_300x250"
|
|
484
|
+
name: "Trail Pro 3000 - Display 300x250"
|
|
497
485
|
format_id:
|
|
498
|
-
agent_url:
|
|
499
|
-
id:
|
|
486
|
+
agent_url: "https://your-platform.example.com"
|
|
487
|
+
id: "display_300x250"
|
|
500
488
|
assets:
|
|
501
|
-
- asset_id:
|
|
502
|
-
asset_type:
|
|
503
|
-
url:
|
|
504
|
-
mime_type:
|
|
489
|
+
- asset_id: "image"
|
|
490
|
+
asset_type: "image"
|
|
491
|
+
url: "https://cdn.pinnacle-agency.example/trail-pro-300x250.png"
|
|
492
|
+
mime_type: "image/png"
|
|
505
493
|
|
|
506
494
|
validations:
|
|
507
495
|
- check: response_schema
|
|
508
|
-
description:
|
|
496
|
+
description: "Response matches sync-creatives-response.json schema"
|
|
509
497
|
- check: field_present
|
|
510
|
-
path:
|
|
511
|
-
description:
|
|
498
|
+
path: "creatives[0].action"
|
|
499
|
+
description: "Each creative has an action (created/updated)"
|
|
512
500
|
|
|
513
501
|
- id: delivery_monitoring
|
|
514
|
-
title:
|
|
502
|
+
title: "Delivery and reporting"
|
|
515
503
|
narrative: |
|
|
516
504
|
The campaign is live. The buyer monitors delivery through two tasks:
|
|
517
505
|
get_media_buys for status and get_media_buy_delivery for performance metrics.
|
|
@@ -522,7 +510,7 @@ phases:
|
|
|
522
510
|
|
|
523
511
|
steps:
|
|
524
512
|
- id: get_delivery
|
|
525
|
-
title:
|
|
513
|
+
title: "Check delivery metrics"
|
|
526
514
|
narrative: |
|
|
527
515
|
The buyer requests delivery data for the active media buy. Your platform
|
|
528
516
|
returns performance metrics — impressions, clicks, spend, completion rates —
|
|
@@ -531,10 +519,10 @@ phases:
|
|
|
531
519
|
This call may take up to 60 seconds as your platform aggregates reporting
|
|
532
520
|
data across delivery systems.
|
|
533
521
|
task: get_media_buy_delivery
|
|
534
|
-
schema_ref:
|
|
535
|
-
response_schema_ref:
|
|
536
|
-
doc_ref:
|
|
537
|
-
comply_scenario:
|
|
522
|
+
schema_ref: "media-buy/get-media-buy-delivery-request.json"
|
|
523
|
+
response_schema_ref: "media-buy/get-media-buy-delivery-response.json"
|
|
524
|
+
doc_ref: "/media-buy/task-reference/get_media_buy_delivery"
|
|
525
|
+
comply_scenario: reporting_flow
|
|
538
526
|
stateful: true
|
|
539
527
|
expected: |
|
|
540
528
|
Return delivery metrics for the media buy:
|
|
@@ -546,15 +534,15 @@ phases:
|
|
|
546
534
|
sample_request:
|
|
547
535
|
account:
|
|
548
536
|
brand:
|
|
549
|
-
domain:
|
|
550
|
-
operator:
|
|
537
|
+
domain: "acmeoutdoor.com"
|
|
538
|
+
operator: "pinnacle-agency.com"
|
|
551
539
|
media_buy_ids:
|
|
552
|
-
-
|
|
540
|
+
- "mb_acme_q2_2026"
|
|
553
541
|
include_package_daily_breakdown: true
|
|
554
542
|
|
|
555
543
|
validations:
|
|
556
544
|
- check: response_schema
|
|
557
|
-
description:
|
|
545
|
+
description: "Response matches get-media-buy-delivery-response.json schema"
|
|
558
546
|
- check: field_present
|
|
559
|
-
path:
|
|
560
|
-
description:
|
|
547
|
+
path: "media_buy_deliveries"
|
|
548
|
+
description: "Response contains media buy delivery data"
|