@adcp/client 4.11.0 → 4.13.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.
Files changed (149) hide show
  1. package/README.md +13 -0
  2. package/bin/adcp.js +77 -182
  3. package/dist/lib/core/ADCPMultiAgentClient.js.map +1 -1
  4. package/dist/lib/core/AgentClient.d.ts +8 -6
  5. package/dist/lib/core/AgentClient.d.ts.map +1 -1
  6. package/dist/lib/core/AgentClient.js.map +1 -1
  7. package/dist/lib/core/GovernanceMiddleware.d.ts.map +1 -1
  8. package/dist/lib/core/GovernanceMiddleware.js +2 -1
  9. package/dist/lib/core/GovernanceMiddleware.js.map +1 -1
  10. package/dist/lib/core/ProtocolResponseParser.d.ts.map +1 -1
  11. package/dist/lib/core/ProtocolResponseParser.js +3 -1
  12. package/dist/lib/core/ProtocolResponseParser.js.map +1 -1
  13. package/dist/lib/core/SingleAgentClient.d.ts +18 -13
  14. package/dist/lib/core/SingleAgentClient.d.ts.map +1 -1
  15. package/dist/lib/core/SingleAgentClient.js +51 -33
  16. package/dist/lib/core/SingleAgentClient.js.map +1 -1
  17. package/dist/lib/core/TaskExecutor.d.ts.map +1 -1
  18. package/dist/lib/core/TaskExecutor.js +13 -5
  19. package/dist/lib/core/TaskExecutor.js.map +1 -1
  20. package/dist/lib/errors/index.d.ts +5 -5
  21. package/dist/lib/errors/index.d.ts.map +1 -1
  22. package/dist/lib/errors/index.js +3 -1
  23. package/dist/lib/errors/index.js.map +1 -1
  24. package/dist/lib/index.d.ts +6 -1
  25. package/dist/lib/index.d.ts.map +1 -1
  26. package/dist/lib/index.js +30 -9
  27. package/dist/lib/index.js.map +1 -1
  28. package/dist/lib/protocols/a2a.d.ts +2 -1
  29. package/dist/lib/protocols/a2a.d.ts.map +1 -1
  30. package/dist/lib/protocols/a2a.js +24 -10
  31. package/dist/lib/protocols/a2a.js.map +1 -1
  32. package/dist/lib/protocols/index.d.ts +5 -5
  33. package/dist/lib/protocols/index.d.ts.map +1 -1
  34. package/dist/lib/protocols/index.js +2 -1
  35. package/dist/lib/protocols/index.js.map +1 -1
  36. package/dist/lib/protocols/mcp.d.ts +22 -9
  37. package/dist/lib/protocols/mcp.d.ts.map +1 -1
  38. package/dist/lib/protocols/mcp.js +205 -75
  39. package/dist/lib/protocols/mcp.js.map +1 -1
  40. package/dist/lib/server/errors.d.ts +62 -0
  41. package/dist/lib/server/errors.d.ts.map +1 -0
  42. package/dist/lib/server/errors.js +54 -0
  43. package/dist/lib/server/errors.js.map +1 -0
  44. package/dist/lib/server/index.d.ts +5 -0
  45. package/dist/lib/server/index.d.ts.map +1 -0
  46. package/dist/lib/server/index.js +11 -0
  47. package/dist/lib/server/index.js.map +1 -0
  48. package/dist/lib/server/responses.d.ts +64 -0
  49. package/dist/lib/server/responses.d.ts.map +1 -0
  50. package/dist/lib/server/responses.js +85 -0
  51. package/dist/lib/server/responses.js.map +1 -0
  52. package/dist/lib/testing/agent-tester.d.ts +1 -1
  53. package/dist/lib/testing/agent-tester.d.ts.map +1 -1
  54. package/dist/lib/testing/agent-tester.js +19 -1
  55. package/dist/lib/testing/agent-tester.js.map +1 -1
  56. package/dist/lib/testing/compliance/comply.d.ts.map +1 -1
  57. package/dist/lib/testing/compliance/comply.js +38 -0
  58. package/dist/lib/testing/compliance/comply.js.map +1 -1
  59. package/dist/lib/testing/compliance/index.d.ts +1 -1
  60. package/dist/lib/testing/compliance/index.d.ts.map +1 -1
  61. package/dist/lib/testing/compliance/index.js +2 -1
  62. package/dist/lib/testing/compliance/index.js.map +1 -1
  63. package/dist/lib/testing/compliance/profiles.d.ts +7 -0
  64. package/dist/lib/testing/compliance/profiles.d.ts.map +1 -1
  65. package/dist/lib/testing/compliance/profiles.js +10 -0
  66. package/dist/lib/testing/compliance/profiles.js.map +1 -1
  67. package/dist/lib/testing/compliance/types.d.ts +2 -2
  68. package/dist/lib/testing/compliance/types.d.ts.map +1 -1
  69. package/dist/lib/testing/index.d.ts +1 -1
  70. package/dist/lib/testing/index.d.ts.map +1 -1
  71. package/dist/lib/testing/index.js +2 -1
  72. package/dist/lib/testing/index.js.map +1 -1
  73. package/dist/lib/testing/orchestrator.d.ts.map +1 -1
  74. package/dist/lib/testing/orchestrator.js +7 -0
  75. package/dist/lib/testing/orchestrator.js.map +1 -1
  76. package/dist/lib/testing/scenarios/capabilities.js.map +1 -1
  77. package/dist/lib/testing/scenarios/creative.js +1 -1
  78. package/dist/lib/testing/scenarios/creative.js.map +1 -1
  79. package/dist/lib/testing/scenarios/edge-cases.js.map +1 -1
  80. package/dist/lib/testing/scenarios/error-compliance.d.ts +30 -0
  81. package/dist/lib/testing/scenarios/error-compliance.d.ts.map +1 -0
  82. package/dist/lib/testing/scenarios/error-compliance.js +382 -0
  83. package/dist/lib/testing/scenarios/error-compliance.js.map +1 -0
  84. package/dist/lib/testing/scenarios/governance.js.map +1 -1
  85. package/dist/lib/testing/scenarios/index.d.ts +1 -0
  86. package/dist/lib/testing/scenarios/index.d.ts.map +1 -1
  87. package/dist/lib/testing/scenarios/index.js +6 -1
  88. package/dist/lib/testing/scenarios/index.js.map +1 -1
  89. package/dist/lib/testing/scenarios/media-buy.d.ts.map +1 -1
  90. package/dist/lib/testing/scenarios/media-buy.js +23 -1
  91. package/dist/lib/testing/scenarios/media-buy.js.map +1 -1
  92. package/dist/lib/testing/scenarios/signals.d.ts.map +1 -1
  93. package/dist/lib/testing/scenarios/signals.js +20 -21
  94. package/dist/lib/testing/scenarios/signals.js.map +1 -1
  95. package/dist/lib/testing/scenarios/sponsored-intelligence.js.map +1 -1
  96. package/dist/lib/testing/types.d.ts +1 -1
  97. package/dist/lib/testing/types.d.ts.map +1 -1
  98. package/dist/lib/types/adcp.d.ts +9 -4
  99. package/dist/lib/types/adcp.d.ts.map +1 -1
  100. package/dist/lib/types/core.generated.d.ts +25 -2
  101. package/dist/lib/types/core.generated.d.ts.map +1 -1
  102. package/dist/lib/types/core.generated.js +1 -1
  103. package/dist/lib/types/schemas.generated.d.ts +371 -330
  104. package/dist/lib/types/schemas.generated.d.ts.map +1 -1
  105. package/dist/lib/types/schemas.generated.js +78 -84
  106. package/dist/lib/types/schemas.generated.js.map +1 -1
  107. package/dist/lib/types/tools.generated.d.ts +131 -122
  108. package/dist/lib/types/tools.generated.d.ts.map +1 -1
  109. package/dist/lib/utils/a2a-discovery.d.ts +32 -0
  110. package/dist/lib/utils/a2a-discovery.d.ts.map +1 -0
  111. package/dist/lib/utils/a2a-discovery.js +55 -0
  112. package/dist/lib/utils/a2a-discovery.js.map +1 -0
  113. package/dist/lib/utils/capabilities.d.ts +1 -1
  114. package/dist/lib/utils/capabilities.d.ts.map +1 -1
  115. package/dist/lib/utils/capabilities.js +17 -8
  116. package/dist/lib/utils/capabilities.js.map +1 -1
  117. package/dist/lib/utils/creative-adapter.d.ts.map +1 -1
  118. package/dist/lib/utils/creative-adapter.js.map +1 -1
  119. package/dist/lib/utils/error-extraction.d.ts +57 -0
  120. package/dist/lib/utils/error-extraction.d.ts.map +1 -0
  121. package/dist/lib/utils/error-extraction.js +174 -0
  122. package/dist/lib/utils/error-extraction.js.map +1 -0
  123. package/dist/lib/utils/index.d.ts +3 -0
  124. package/dist/lib/utils/index.d.ts.map +1 -1
  125. package/dist/lib/utils/index.js +14 -1
  126. package/dist/lib/utils/index.js.map +1 -1
  127. package/dist/lib/utils/logger.d.ts +8 -8
  128. package/dist/lib/utils/logger.d.ts.map +1 -1
  129. package/dist/lib/utils/logger.js.map +1 -1
  130. package/dist/lib/utils/preview-utils.d.ts.map +1 -1
  131. package/dist/lib/utils/preview-utils.js +32 -16
  132. package/dist/lib/utils/preview-utils.js.map +1 -1
  133. package/dist/lib/utils/pricing-adapter.d.ts.map +1 -1
  134. package/dist/lib/utils/pricing-adapter.js +13 -1
  135. package/dist/lib/utils/pricing-adapter.js.map +1 -1
  136. package/dist/lib/utils/protocol-detection.d.ts +1 -1
  137. package/dist/lib/utils/protocol-detection.d.ts.map +1 -1
  138. package/dist/lib/utils/protocol-detection.js +25 -47
  139. package/dist/lib/utils/protocol-detection.js.map +1 -1
  140. package/dist/lib/utils/request-normalizer.d.ts.map +1 -1
  141. package/dist/lib/utils/request-normalizer.js +15 -1
  142. package/dist/lib/utils/request-normalizer.js.map +1 -1
  143. package/dist/lib/utils/response-unwrapper.d.ts.map +1 -1
  144. package/dist/lib/utils/response-unwrapper.js +61 -5
  145. package/dist/lib/utils/response-unwrapper.js.map +1 -1
  146. package/dist/lib/validation/index.d.ts.map +1 -1
  147. package/dist/lib/validation/index.js +3 -2
  148. package/dist/lib/validation/index.js.map +1 -1
  149. package/package.json +19 -1
@@ -1,101 +1,3 @@
1
- /**
2
- * Request parameters for discovering or refining advertising products. buying_mode declares the buyer's intent: 'brief' for curated discovery, 'wholesale' for raw catalog access, or 'refine' to iterate on known products and proposals.
3
- */
4
- export type GetProductsRequest = {
5
- /**
6
- * Declares buyer intent for this request. 'brief': publisher curates product recommendations from the provided brief. 'wholesale': buyer requests raw inventory to apply their own audiences — brief must not be provided, and proposals are omitted. 'refine': iterate on products and proposals from a previous get_products response using the refine array of change requests. v3 clients MUST include buying_mode. Sellers receiving requests from pre-v3 clients without buying_mode SHOULD default to 'brief'.
7
- */
8
- buying_mode: 'brief' | 'wholesale' | 'refine';
9
- /**
10
- * Natural language description of campaign requirements. Required when buying_mode is 'brief'. Must not be provided when buying_mode is 'wholesale' or 'refine'.
11
- */
12
- brief?: string;
13
- /**
14
- * Array of change requests for iterating on products and proposals from a previous get_products response. Each entry declares a scope (request, product, or proposal) and what the buyer is asking for. Only valid when buying_mode is 'refine'. The seller responds to each entry via refinement_applied in the response, matched by position.
15
- */
16
- refine?: ({
17
- /**
18
- * Change scoped to the overall request — direction for the selection as a whole.
19
- */
20
- scope: 'request';
21
- /**
22
- * What the buyer is asking for at the request level (e.g., 'more video options and less display', 'suggest how to combine these products').
23
- */
24
- ask: string;
25
- } | {
26
- /**
27
- * Change scoped to a specific product.
28
- */
29
- scope: 'product';
30
- /**
31
- * Product ID from a previous get_products response.
32
- */
33
- id: string;
34
- /**
35
- * 'include': return this product with updated pricing and data. 'omit': exclude this product from the response. 'more_like_this': find additional products similar to this one (the original is also returned).
36
- */
37
- action: 'include' | 'omit' | 'more_like_this';
38
- /**
39
- * What the buyer is asking for on this product. For 'include': specific changes to request (e.g., 'add 16:9 format'). For 'more_like_this': what 'similar' means (e.g., 'same audience but video format'). Ignored when action is 'omit'.
40
- */
41
- ask?: string;
42
- } | {
43
- /**
44
- * Change scoped to a specific proposal.
45
- */
46
- scope: 'proposal';
47
- /**
48
- * Proposal ID from a previous get_products response.
49
- */
50
- id: string;
51
- /**
52
- * 'include': return this proposal with updated allocations and pricing. 'omit': exclude this proposal from the response.
53
- */
54
- action: 'include' | 'omit';
55
- /**
56
- * What the buyer is asking for on this proposal (e.g., 'shift more budget toward video', 'reduce total by 10%'). Ignored when action is 'omit'.
57
- */
58
- ask?: string;
59
- })[];
60
- brand?: BrandReference;
61
- catalog?: Catalog;
62
- account?: AccountReference;
63
- /**
64
- * Buyer's campaign reference label. Groups related discovery and buy operations under a single campaign for CRM and ad server correlation (e.g., 'NovaDrink_Meals_Q2').
65
- */
66
- buyer_campaign_ref?: string;
67
- /**
68
- * Delivery types the buyer prefers, in priority order. Unlike filters.delivery_type which excludes non-matching products, this signals preference for curation — the publisher may still include other delivery types when they match the brief well.
69
- */
70
- preferred_delivery_types?: DeliveryType[];
71
- filters?: ProductFilters;
72
- property_list?: PropertyListReference;
73
- /**
74
- * Specific product fields to include in the response. When omitted, all fields are returned. Use for lightweight discovery calls where only a subset of product data is needed (e.g., just IDs and pricing for comparison). Required fields (product_id, name) are always included regardless of selection.
75
- */
76
- fields?: ('product_id' | 'name' | 'description' | 'publisher_properties' | 'channels' | 'format_ids' | 'placements' | 'delivery_type' | 'exclusivity' | 'pricing_options' | 'forecast' | 'outcome_measurement' | 'delivery_measurement' | 'reporting_capabilities' | 'creative_policy' | 'catalog_types' | 'metric_optimization' | 'conversion_tracking' | 'data_provider_signals' | 'max_optimization_goals' | 'catalog_match' | 'shows' | 'show_targeting_allowed' | 'episodes' | 'brief_relevance' | 'expires_at' | 'product_card' | 'product_card_detailed' | 'enforced_policies')[];
77
- /**
78
- * Maximum time the buyer will commit to this request. The seller returns the best results achievable within this budget and does not start processes (human approvals, expensive external queries) that cannot complete in time. When omitted, the seller decides timing.
79
- */
80
- time_budget?: Duration;
81
- pagination?: PaginationRequest;
82
- context?: ContextObject;
83
- /**
84
- * Registry policy IDs that the buyer requires to be enforced for products in this response. Sellers filter products to only those that comply with or already enforce the requested policies.
85
- */
86
- required_policies?: string[];
87
- ext?: ExtensionObject;
88
- } & ({
89
- buying_mode: 'brief';
90
- refine?: never;
91
- } | {
92
- buying_mode: 'wholesale';
93
- brief?: never;
94
- refine?: never;
95
- } | {
96
- buying_mode: 'refine';
97
- brief?: never;
98
- });
99
1
  /**
100
2
  * Brand identifier within the house portfolio. Optional for single-brand domains.
101
3
  */
@@ -231,6 +133,94 @@ export type SignalID = {
231
133
  */
232
134
  id: string;
233
135
  };
136
+ /**
137
+ * Request parameters for discovering or refining advertising products. buying_mode declares the buyer's intent: 'brief' for curated discovery, 'wholesale' for raw catalog access, or 'refine' to iterate on known products and proposals.
138
+ */
139
+ export interface GetProductsRequest {
140
+ /**
141
+ * Declares buyer intent for this request. 'brief': publisher curates product recommendations from the provided brief. 'wholesale': buyer requests raw inventory to apply their own audiences — brief must not be provided, and proposals are omitted. 'refine': iterate on products and proposals from a previous get_products response using the refine array of change requests. v3 clients MUST include buying_mode. Sellers receiving requests from pre-v3 clients without buying_mode SHOULD default to 'brief'.
142
+ */
143
+ buying_mode: 'brief' | 'wholesale' | 'refine';
144
+ /**
145
+ * Natural language description of campaign requirements. Required when buying_mode is 'brief'. Must not be provided when buying_mode is 'wholesale' or 'refine'.
146
+ */
147
+ brief?: string;
148
+ /**
149
+ * Array of change requests for iterating on products and proposals from a previous get_products response. Each entry declares a scope (request, product, or proposal) and what the buyer is asking for. Only valid when buying_mode is 'refine'. The seller responds to each entry via refinement_applied in the response, matched by position.
150
+ */
151
+ refine?: ({
152
+ /**
153
+ * Change scoped to the overall request — direction for the selection as a whole.
154
+ */
155
+ scope: 'request';
156
+ /**
157
+ * What the buyer is asking for at the request level (e.g., 'more video options and less display', 'suggest how to combine these products').
158
+ */
159
+ ask: string;
160
+ } | {
161
+ /**
162
+ * Change scoped to a specific product.
163
+ */
164
+ scope: 'product';
165
+ /**
166
+ * Product ID from a previous get_products response.
167
+ */
168
+ id: string;
169
+ /**
170
+ * 'include': return this product with updated pricing and data. 'omit': exclude this product from the response. 'more_like_this': find additional products similar to this one (the original is also returned).
171
+ */
172
+ action: 'include' | 'omit' | 'more_like_this';
173
+ /**
174
+ * What the buyer is asking for on this product. For 'include': specific changes to request (e.g., 'add 16:9 format'). For 'more_like_this': what 'similar' means (e.g., 'same audience but video format'). Ignored when action is 'omit'.
175
+ */
176
+ ask?: string;
177
+ } | {
178
+ /**
179
+ * Change scoped to a specific proposal.
180
+ */
181
+ scope: 'proposal';
182
+ /**
183
+ * Proposal ID from a previous get_products response.
184
+ */
185
+ id: string;
186
+ /**
187
+ * 'include': return this proposal with updated allocations and pricing. 'omit': exclude this proposal from the response.
188
+ */
189
+ action: 'include' | 'omit';
190
+ /**
191
+ * What the buyer is asking for on this proposal (e.g., 'shift more budget toward video', 'reduce total by 10%'). Ignored when action is 'omit'.
192
+ */
193
+ ask?: string;
194
+ })[];
195
+ brand?: BrandReference;
196
+ catalog?: Catalog;
197
+ account?: AccountReference;
198
+ /**
199
+ * Buyer's campaign reference label. Groups related discovery and buy operations under a single campaign for CRM and ad server correlation (e.g., 'NovaDrink_Meals_Q2').
200
+ */
201
+ buyer_campaign_ref?: string;
202
+ /**
203
+ * Delivery types the buyer prefers, in priority order. Unlike filters.delivery_type which excludes non-matching products, this signals preference for curation — the publisher may still include other delivery types when they match the brief well.
204
+ */
205
+ preferred_delivery_types?: DeliveryType[];
206
+ filters?: ProductFilters;
207
+ property_list?: PropertyListReference;
208
+ /**
209
+ * Specific product fields to include in the response. When omitted, all fields are returned. Use for lightweight discovery calls where only a subset of product data is needed (e.g., just IDs and pricing for comparison). Required fields (product_id, name) are always included regardless of selection.
210
+ */
211
+ fields?: ('product_id' | 'name' | 'description' | 'publisher_properties' | 'channels' | 'format_ids' | 'placements' | 'delivery_type' | 'exclusivity' | 'pricing_options' | 'forecast' | 'outcome_measurement' | 'delivery_measurement' | 'reporting_capabilities' | 'creative_policy' | 'catalog_types' | 'metric_optimization' | 'conversion_tracking' | 'data_provider_signals' | 'max_optimization_goals' | 'catalog_match' | 'shows' | 'show_targeting_allowed' | 'episodes' | 'brief_relevance' | 'expires_at' | 'product_card' | 'product_card_detailed' | 'enforced_policies')[];
212
+ /**
213
+ * Maximum time the buyer will commit to this request. The seller returns the best results achievable within this budget and does not start processes (human approvals, expensive external queries) that cannot complete in time. When omitted, the seller decides timing.
214
+ */
215
+ time_budget?: Duration;
216
+ pagination?: PaginationRequest;
217
+ context?: ContextObject;
218
+ /**
219
+ * Registry policy IDs that the buyer requires to be enforced for products in this response. Sellers filter products to only those that comply with or already enforce the requested policies.
220
+ */
221
+ required_policies?: string[];
222
+ ext?: ExtensionObject;
223
+ }
234
224
  /**
235
225
  * Brand reference for product discovery context. Resolved to full brand identity at execution time.
236
226
  */
@@ -668,10 +658,14 @@ export type EpisodeStatus = 'scheduled' | 'tentative' | 'live' | 'postponed' | '
668
658
  * Rating system used
669
659
  */
670
660
  export type ContentRatingSystem = 'tv_parental' | 'mpaa' | 'podcast' | 'esrb' | 'bbfc' | 'fsk' | 'acb' | 'custom';
661
+ /**
662
+ * Category of the event
663
+ */
664
+ export type SpecialCategory = 'awards' | 'championship' | 'concert' | 'conference' | 'election' | 'festival' | 'gala' | 'holiday' | 'premiere' | 'product_launch' | 'reunion' | 'tribute';
671
665
  /**
672
666
  * Role of this person on the show or episode
673
667
  */
674
- export type TalentRole = 'host' | 'guest' | 'creator' | 'cast' | 'narrator' | 'producer' | 'correspondent';
668
+ export type TalentRole = 'host' | 'guest' | 'creator' | 'cast' | 'narrator' | 'producer' | 'correspondent' | 'commentator' | 'analyst';
675
669
  /**
676
670
  * What kind of derivative content this is
677
671
  */
@@ -1602,6 +1596,7 @@ export interface Episode {
1602
1596
  * Content topics for this episode. Uses the same taxonomy as the show's genre_taxonomy when present. Enables episode-level brand safety evaluation beyond content_rating.
1603
1597
  */
1604
1598
  topics?: string[];
1599
+ special?: Special;
1605
1600
  /**
1606
1601
  * Episode-specific guests and talent. Additive to the show's recurring talent.
1607
1602
  */
@@ -1629,6 +1624,24 @@ export interface ContentRating {
1629
1624
  */
1630
1625
  rating: string;
1631
1626
  }
1627
+ /**
1628
+ * Episode-specific event context. When present, this episode is anchored to a real-world event. Overrides the show-level special when present.
1629
+ */
1630
+ export interface Special {
1631
+ /**
1632
+ * Name of the event (e.g., 'Olympics 2028', 'Super Bowl LXI')
1633
+ */
1634
+ name: string;
1635
+ category?: SpecialCategory;
1636
+ /**
1637
+ * When the event starts (ISO 8601)
1638
+ */
1639
+ starts?: string;
1640
+ /**
1641
+ * When the event ends (ISO 8601). Omit for single-day events.
1642
+ */
1643
+ ends?: string;
1644
+ }
1632
1645
  /**
1633
1646
  * A person associated with a show or episode, with an optional link to their brand.json identity
1634
1647
  */
@@ -1805,7 +1818,7 @@ export interface Error {
1805
1818
  */
1806
1819
  suggestion?: string;
1807
1820
  /**
1808
- * Seconds to wait before retrying the operation
1821
+ * Seconds to wait before retrying the operation. Sellers MUST return values between 1 and 3600. Clients MUST clamp values outside this range.
1809
1822
  */
1810
1823
  retry_after?: number;
1811
1824
  /**
@@ -5657,10 +5670,26 @@ export interface SyncCatalogsError {
5657
5670
  context?: ContextObject;
5658
5671
  ext?: ExtensionObject;
5659
5672
  }
5673
+ /**
5674
+ * Types of rights usage that can be licensed through the brand protocol. Aligned with DDEX UseType direction for interoperability with music and media rights systems.
5675
+ */
5676
+ export type RightUse = 'likeness' | 'voice' | 'name' | 'endorsement' | 'motion_capture' | 'signature' | 'catchphrase' | 'sync' | 'background_music' | 'editorial' | 'commercial';
5677
+ /**
5678
+ * Type of rights (talent, music, etc.). Helps identify constraints when a creative combines multiple rights types.
5679
+ */
5680
+ export type RightType = 'talent' | 'character' | 'brand_ip' | 'music' | 'stock_media';
5681
+ /**
5682
+ * Quality tier for generation. 'draft' produces fast, lower-fidelity output for iteration and review. 'production' produces full-quality output for final delivery. If omitted, the creative agent uses its own default. For non-generative transforms (e.g., format resizing), creative agents MAY ignore this field.
5683
+ */
5684
+ export type CreativeQuality = 'draft' | 'production';
5685
+ /**
5686
+ * Output format for preview renders when include_preview is true. 'url' returns preview_url (iframe-embeddable URL), 'html' returns preview_html (raw HTML). Ignored when include_preview is false or omitted.
5687
+ */
5688
+ export type PreviewOutputFormat = 'url' | 'html';
5660
5689
  /**
5661
5690
  * Request to transform, generate, or retrieve a creative manifest. Supports three modes: (1) generation from a brief or seed assets, (2) transformation of an existing manifest, (3) retrieval from a creative library by creative_id. Produces target manifest(s) in the specified format(s). Provide either target_format_id for a single format or target_format_ids for multiple formats.
5662
5691
  */
5663
- export type BuildCreativeRequest = {
5692
+ export interface BuildCreativeRequest {
5664
5693
  /**
5665
5694
  * Natural language instructions for the transformation or generation. For pure generation, this is the creative brief. For transformation, this provides guidance on how to adapt the creative. For refinement, this describes the desired changes.
5666
5695
  */
@@ -5726,27 +5755,7 @@ export type BuildCreativeRequest = {
5726
5755
  };
5727
5756
  context?: ContextObject;
5728
5757
  ext?: ExtensionObject;
5729
- } & ({
5730
- target_format_ids?: never;
5731
- } | {
5732
- target_format_id?: never;
5733
- });
5734
- /**
5735
- * Types of rights usage that can be licensed through the brand protocol. Aligned with DDEX UseType direction for interoperability with music and media rights systems.
5736
- */
5737
- export type RightUse = 'likeness' | 'voice' | 'name' | 'endorsement' | 'motion_capture' | 'signature' | 'catchphrase' | 'sync' | 'background_music' | 'editorial' | 'commercial';
5738
- /**
5739
- * Type of rights (talent, music, etc.). Helps identify constraints when a creative combines multiple rights types.
5740
- */
5741
- export type RightType = 'talent' | 'character' | 'brand_ip' | 'music' | 'stock_media';
5742
- /**
5743
- * Quality tier for generation. 'draft' produces fast, lower-fidelity output for iteration and review. 'production' produces full-quality output for final delivery. If omitted, the creative agent uses its own default. For non-generative transforms (e.g., format resizing), creative agents MAY ignore this field.
5744
- */
5745
- export type CreativeQuality = 'draft' | 'production';
5746
- /**
5747
- * Output format for preview renders when include_preview is true. 'url' returns preview_url (iframe-embeddable URL), 'html' returns preview_html (raw HTML). Ignored when include_preview is false or omitted.
5748
- */
5749
- export type PreviewOutputFormat = 'url' | 'html';
5758
+ }
5750
5759
  /**
5751
5760
  * Creative manifest to transform or generate from. For pure generation, this should include the target format_id and any required input assets. For transformation (e.g., resizing, reformatting), this is the complete creative to adapt. When creative_id is provided, the agent resolves the creative from its library and this field is ignored.
5752
5761
  */