@adcp/sdk 12.1.0 → 13.0.0-rc.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 (464) hide show
  1. package/README.md +19 -3
  2. package/bin/adcp-fuzz.js +3 -1
  3. package/dist/lib/adapters/content-standards-adapter.d.mts +9 -9
  4. package/dist/lib/adapters/content-standards-adapter.d.ts +9 -9
  5. package/dist/lib/adapters/content-standards-adapter.d.ts.map +1 -1
  6. package/dist/lib/adapters/content-standards-adapter.js +22 -22
  7. package/dist/lib/adapters/content-standards-adapter.js.map +1 -1
  8. package/dist/lib/adapters/content-standards-adapter.mjs +18 -18
  9. package/dist/lib/adapters/content-standards-adapter.mjs.map +1 -1
  10. package/dist/lib/adapters/index.d.mts +2 -2
  11. package/dist/lib/adapters/index.d.ts +2 -2
  12. package/dist/lib/adapters/index.d.ts.map +1 -1
  13. package/dist/lib/adapters/index.js +10 -10
  14. package/dist/lib/adapters/index.js.map +1 -1
  15. package/dist/lib/adapters/index.mjs +9 -9
  16. package/dist/lib/adapters/index.mjs.map +1 -1
  17. package/dist/lib/auth/oauth/authorization-required.d.mts +3 -0
  18. package/dist/lib/auth/oauth/authorization-required.d.ts +3 -0
  19. package/dist/lib/auth/oauth/authorization-required.d.ts.map +1 -1
  20. package/dist/lib/auth/oauth/authorization-required.js +12 -9
  21. package/dist/lib/auth/oauth/authorization-required.js.map +1 -1
  22. package/dist/lib/auth/oauth/authorization-required.mjs +12 -9
  23. package/dist/lib/auth/oauth/authorization-required.mjs.map +1 -1
  24. package/dist/lib/auth/oauth/provider-cache.d.mts +7 -0
  25. package/dist/lib/auth/oauth/provider-cache.d.ts +8 -0
  26. package/dist/lib/auth/oauth/provider-cache.d.ts.map +1 -0
  27. package/dist/lib/auth/oauth/provider-cache.js +44 -0
  28. package/dist/lib/auth/oauth/provider-cache.js.map +1 -0
  29. package/dist/lib/auth/oauth/provider-cache.mjs +19 -0
  30. package/dist/lib/auth/oauth/provider-cache.mjs.map +1 -0
  31. package/dist/lib/conformance/invariants/uniformError.js +1 -1
  32. package/dist/lib/conformance/invariants/uniformError.js.map +1 -1
  33. package/dist/lib/conformance/invariants/uniformError.mjs +1 -1
  34. package/dist/lib/conformance/invariants/uniformError.mjs.map +1 -1
  35. package/dist/lib/conformance/runners.js +1 -1
  36. package/dist/lib/conformance/runners.js.map +1 -1
  37. package/dist/lib/conformance/runners.mjs +1 -1
  38. package/dist/lib/conformance/runners.mjs.map +1 -1
  39. package/dist/lib/conformance/seeder.js +5 -5
  40. package/dist/lib/conformance/seeder.js.map +1 -1
  41. package/dist/lib/conformance/seeder.mjs +5 -5
  42. package/dist/lib/conformance/seeder.mjs.map +1 -1
  43. package/dist/lib/core/ADCPMultiAgentClient.d.mts +26 -29
  44. package/dist/lib/core/ADCPMultiAgentClient.d.ts +26 -29
  45. package/dist/lib/core/ADCPMultiAgentClient.d.ts.map +1 -1
  46. package/dist/lib/core/ADCPMultiAgentClient.js +27 -19
  47. package/dist/lib/core/ADCPMultiAgentClient.js.map +1 -1
  48. package/dist/lib/core/ADCPMultiAgentClient.mjs +27 -19
  49. package/dist/lib/core/ADCPMultiAgentClient.mjs.map +1 -1
  50. package/dist/lib/core/AgentClient.d.mts +148 -138
  51. package/dist/lib/core/AgentClient.d.ts +148 -138
  52. package/dist/lib/core/AgentClient.d.ts.map +1 -1
  53. package/dist/lib/core/AgentClient.js +174 -85
  54. package/dist/lib/core/AgentClient.js.map +1 -1
  55. package/dist/lib/core/AgentClient.mjs +174 -85
  56. package/dist/lib/core/AgentClient.mjs.map +1 -1
  57. package/dist/lib/core/AsyncHandler.d.mts +18 -16
  58. package/dist/lib/core/AsyncHandler.d.ts +18 -16
  59. package/dist/lib/core/AsyncHandler.d.ts.map +1 -1
  60. package/dist/lib/core/AsyncHandler.js +22 -1
  61. package/dist/lib/core/AsyncHandler.js.map +1 -1
  62. package/dist/lib/core/AsyncHandler.mjs +22 -1
  63. package/dist/lib/core/AsyncHandler.mjs.map +1 -1
  64. package/dist/lib/core/ConversationTypes.d.mts +6 -2
  65. package/dist/lib/core/ConversationTypes.d.ts +6 -2
  66. package/dist/lib/core/ConversationTypes.d.ts.map +1 -1
  67. package/dist/lib/core/ConversationTypes.js.map +1 -1
  68. package/dist/lib/core/CreativeAgentClient.d.mts +41 -17
  69. package/dist/lib/core/CreativeAgentClient.d.ts +41 -17
  70. package/dist/lib/core/CreativeAgentClient.d.ts.map +1 -1
  71. package/dist/lib/core/CreativeAgentClient.js +39 -12
  72. package/dist/lib/core/CreativeAgentClient.js.map +1 -1
  73. package/dist/lib/core/CreativeAgentClient.mjs +39 -12
  74. package/dist/lib/core/CreativeAgentClient.mjs.map +1 -1
  75. package/dist/lib/core/SingleAgentClient.d.mts +129 -52
  76. package/dist/lib/core/SingleAgentClient.d.ts +129 -52
  77. package/dist/lib/core/SingleAgentClient.d.ts.map +1 -1
  78. package/dist/lib/core/SingleAgentClient.js +1748 -218
  79. package/dist/lib/core/SingleAgentClient.js.map +1 -1
  80. package/dist/lib/core/SingleAgentClient.mjs +1758 -218
  81. package/dist/lib/core/SingleAgentClient.mjs.map +1 -1
  82. package/dist/lib/core/TaskExecutor.d.mts +9 -0
  83. package/dist/lib/core/TaskExecutor.d.ts +9 -0
  84. package/dist/lib/core/TaskExecutor.d.ts.map +1 -1
  85. package/dist/lib/core/TaskExecutor.js +137 -44
  86. package/dist/lib/core/TaskExecutor.js.map +1 -1
  87. package/dist/lib/core/TaskExecutor.mjs +137 -44
  88. package/dist/lib/core/TaskExecutor.mjs.map +1 -1
  89. package/dist/lib/index.d.mts +111 -17
  90. package/dist/lib/index.d.ts +111 -17
  91. package/dist/lib/index.d.ts.map +1 -1
  92. package/dist/lib/index.js +94 -94
  93. package/dist/lib/index.js.map +1 -1
  94. package/dist/lib/index.mjs +93 -94
  95. package/dist/lib/index.mjs.map +1 -1
  96. package/dist/lib/net/ssrf-fetch.d.mts +13 -1
  97. package/dist/lib/net/ssrf-fetch.d.ts +13 -1
  98. package/dist/lib/net/ssrf-fetch.d.ts.map +1 -1
  99. package/dist/lib/net/ssrf-fetch.js +14 -7
  100. package/dist/lib/net/ssrf-fetch.js.map +1 -1
  101. package/dist/lib/net/ssrf-fetch.mjs +14 -7
  102. package/dist/lib/net/ssrf-fetch.mjs.map +1 -1
  103. package/dist/lib/protocols/a2a.d.mts +2 -2
  104. package/dist/lib/protocols/a2a.d.ts +2 -2
  105. package/dist/lib/protocols/a2a.d.ts.map +1 -1
  106. package/dist/lib/protocols/a2a.js +14 -9
  107. package/dist/lib/protocols/a2a.js.map +1 -1
  108. package/dist/lib/protocols/a2a.mjs +14 -9
  109. package/dist/lib/protocols/a2a.mjs.map +1 -1
  110. package/dist/lib/protocols/index.d.mts +20 -3
  111. package/dist/lib/protocols/index.d.ts +20 -3
  112. package/dist/lib/protocols/index.d.ts.map +1 -1
  113. package/dist/lib/protocols/index.js +44 -31
  114. package/dist/lib/protocols/index.js.map +1 -1
  115. package/dist/lib/protocols/index.mjs +44 -32
  116. package/dist/lib/protocols/index.mjs.map +1 -1
  117. package/dist/lib/protocols/mcp-modern.d.ts.map +1 -1
  118. package/dist/lib/protocols/mcp-modern.js +87 -12
  119. package/dist/lib/protocols/mcp-modern.js.map +1 -1
  120. package/dist/lib/protocols/mcp-modern.mjs +89 -12
  121. package/dist/lib/protocols/mcp-modern.mjs.map +1 -1
  122. package/dist/lib/protocols/mcp-tasks.d.mts +3 -0
  123. package/dist/lib/protocols/mcp-tasks.d.ts +3 -0
  124. package/dist/lib/protocols/mcp-tasks.d.ts.map +1 -1
  125. package/dist/lib/protocols/mcp-tasks.js +21 -11
  126. package/dist/lib/protocols/mcp-tasks.js.map +1 -1
  127. package/dist/lib/protocols/mcp-tasks.mjs +21 -11
  128. package/dist/lib/protocols/mcp-tasks.mjs.map +1 -1
  129. package/dist/lib/schemas-data/v2.5/_provenance.json +1 -1
  130. package/dist/lib/server/create-adcp-server.d.mts +6 -0
  131. package/dist/lib/server/create-adcp-server.d.ts +6 -0
  132. package/dist/lib/server/create-adcp-server.d.ts.map +1 -1
  133. package/dist/lib/server/create-adcp-server.js +295 -48
  134. package/dist/lib/server/create-adcp-server.js.map +1 -1
  135. package/dist/lib/server/create-adcp-server.mjs +301 -50
  136. package/dist/lib/server/create-adcp-server.mjs.map +1 -1
  137. package/dist/lib/server/decisioning/assembly-helpers.d.mts +27 -13
  138. package/dist/lib/server/decisioning/assembly-helpers.d.ts +27 -13
  139. package/dist/lib/server/decisioning/assembly-helpers.d.ts.map +1 -1
  140. package/dist/lib/server/decisioning/assembly-helpers.js +136 -14
  141. package/dist/lib/server/decisioning/assembly-helpers.js.map +1 -1
  142. package/dist/lib/server/decisioning/assembly-helpers.mjs +134 -13
  143. package/dist/lib/server/decisioning/assembly-helpers.mjs.map +1 -1
  144. package/dist/lib/server/decisioning/index.d.mts +13 -12
  145. package/dist/lib/server/decisioning/index.d.ts +13 -12
  146. package/dist/lib/server/decisioning/index.d.ts.map +1 -1
  147. package/dist/lib/server/decisioning/index.js +6 -0
  148. package/dist/lib/server/decisioning/index.js.map +1 -1
  149. package/dist/lib/server/decisioning/index.mjs +9 -3
  150. package/dist/lib/server/decisioning/index.mjs.map +1 -1
  151. package/dist/lib/server/decisioning/list-helpers.d.mts +13 -3
  152. package/dist/lib/server/decisioning/list-helpers.d.ts +13 -3
  153. package/dist/lib/server/decisioning/list-helpers.d.ts.map +1 -1
  154. package/dist/lib/server/decisioning/list-helpers.js +13 -3
  155. package/dist/lib/server/decisioning/list-helpers.js.map +1 -1
  156. package/dist/lib/server/decisioning/list-helpers.mjs +11 -2
  157. package/dist/lib/server/decisioning/list-helpers.mjs.map +1 -1
  158. package/dist/lib/server/decisioning/manifest-helpers.d.mts +5 -3
  159. package/dist/lib/server/decisioning/manifest-helpers.d.ts +5 -3
  160. package/dist/lib/server/decisioning/manifest-helpers.d.ts.map +1 -1
  161. package/dist/lib/server/decisioning/manifest-helpers.js.map +1 -1
  162. package/dist/lib/server/decisioning/manifest-helpers.mjs.map +1 -1
  163. package/dist/lib/server/decisioning/proposal/dispatch.d.mts +2 -2
  164. package/dist/lib/server/decisioning/proposal/dispatch.d.ts +2 -2
  165. package/dist/lib/server/decisioning/proposal/dispatch.d.ts.map +1 -1
  166. package/dist/lib/server/decisioning/proposal/dispatch.js.map +1 -1
  167. package/dist/lib/server/decisioning/proposal/dispatch.mjs.map +1 -1
  168. package/dist/lib/server/decisioning/proposal/index.d.mts +1 -1
  169. package/dist/lib/server/decisioning/proposal/index.d.ts +1 -1
  170. package/dist/lib/server/decisioning/proposal/index.d.ts.map +1 -1
  171. package/dist/lib/server/decisioning/proposal/index.js.map +1 -1
  172. package/dist/lib/server/decisioning/proposal/index.mjs.map +1 -1
  173. package/dist/lib/server/decisioning/proposal/lifecycle.d.mts +3 -2
  174. package/dist/lib/server/decisioning/proposal/lifecycle.d.ts +3 -2
  175. package/dist/lib/server/decisioning/proposal/lifecycle.d.ts.map +1 -1
  176. package/dist/lib/server/decisioning/proposal/lifecycle.js.map +1 -1
  177. package/dist/lib/server/decisioning/proposal/lifecycle.mjs.map +1 -1
  178. package/dist/lib/server/decisioning/proposal/mock-manager.d.mts +3 -3
  179. package/dist/lib/server/decisioning/proposal/mock-manager.d.ts +3 -3
  180. package/dist/lib/server/decisioning/proposal/mock-manager.d.ts.map +1 -1
  181. package/dist/lib/server/decisioning/proposal/mock-manager.js.map +1 -1
  182. package/dist/lib/server/decisioning/proposal/mock-manager.mjs.map +1 -1
  183. package/dist/lib/server/decisioning/proposal/types.d.mts +10 -6
  184. package/dist/lib/server/decisioning/proposal/types.d.ts +10 -6
  185. package/dist/lib/server/decisioning/proposal/types.d.ts.map +1 -1
  186. package/dist/lib/server/decisioning/proposal/types.js.map +1 -1
  187. package/dist/lib/server/decisioning/proposal/types.mjs.map +1 -1
  188. package/dist/lib/server/decisioning/runtime/from-platform.d.mts +21 -2
  189. package/dist/lib/server/decisioning/runtime/from-platform.d.ts +21 -2
  190. package/dist/lib/server/decisioning/runtime/from-platform.d.ts.map +1 -1
  191. package/dist/lib/server/decisioning/runtime/from-platform.js +754 -81
  192. package/dist/lib/server/decisioning/runtime/from-platform.js.map +1 -1
  193. package/dist/lib/server/decisioning/runtime/from-platform.mjs +763 -81
  194. package/dist/lib/server/decisioning/runtime/from-platform.mjs.map +1 -1
  195. package/dist/lib/server/decisioning/specialisms/brand-rights.d.mts +9 -9
  196. package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts +9 -9
  197. package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts.map +1 -1
  198. package/dist/lib/server/decisioning/specialisms/brand-rights.js.map +1 -1
  199. package/dist/lib/server/decisioning/specialisms/content-standards.d.mts +16 -16
  200. package/dist/lib/server/decisioning/specialisms/content-standards.d.ts +16 -16
  201. package/dist/lib/server/decisioning/specialisms/content-standards.d.ts.map +1 -1
  202. package/dist/lib/server/decisioning/specialisms/content-standards.js.map +1 -1
  203. package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.mts +15 -13
  204. package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts +15 -13
  205. package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts.map +1 -1
  206. package/dist/lib/server/decisioning/specialisms/creative-ad-server.js.map +1 -1
  207. package/dist/lib/server/decisioning/specialisms/creative.d.mts +12 -11
  208. package/dist/lib/server/decisioning/specialisms/creative.d.ts +12 -11
  209. package/dist/lib/server/decisioning/specialisms/creative.d.ts.map +1 -1
  210. package/dist/lib/server/decisioning/specialisms/creative.js.map +1 -1
  211. package/dist/lib/server/decisioning/specialisms/sales.d.mts +25 -15
  212. package/dist/lib/server/decisioning/specialisms/sales.d.ts +25 -15
  213. package/dist/lib/server/decisioning/specialisms/sales.d.ts.map +1 -1
  214. package/dist/lib/server/decisioning/specialisms/sales.js.map +1 -1
  215. package/dist/lib/server/index.d.mts +3 -3
  216. package/dist/lib/server/index.d.ts +3 -3
  217. package/dist/lib/server/index.d.ts.map +1 -1
  218. package/dist/lib/server/index.js +72 -72
  219. package/dist/lib/server/index.js.map +1 -1
  220. package/dist/lib/server/index.mjs +36 -36
  221. package/dist/lib/server/index.mjs.map +1 -1
  222. package/dist/lib/server/legacy/v5/index.d.mts +1 -0
  223. package/dist/lib/server/legacy/v5/index.d.ts +1 -0
  224. package/dist/lib/server/legacy/v5/index.d.ts.map +1 -1
  225. package/dist/lib/server/legacy/v5/index.js +74 -1
  226. package/dist/lib/server/legacy/v5/index.js.map +1 -1
  227. package/dist/lib/server/legacy/v5/index.mjs +75 -1
  228. package/dist/lib/server/legacy/v5/index.mjs.map +1 -1
  229. package/dist/lib/server/responses.d.mts +2 -2
  230. package/dist/lib/server/responses.d.ts +2 -2
  231. package/dist/lib/server/responses.js.map +1 -1
  232. package/dist/lib/server/responses.mjs.map +1 -1
  233. package/dist/lib/testing/client.d.ts.map +1 -1
  234. package/dist/lib/testing/client.js +13 -5
  235. package/dist/lib/testing/client.js.map +1 -1
  236. package/dist/lib/testing/client.mjs +13 -5
  237. package/dist/lib/testing/client.mjs.map +1 -1
  238. package/dist/lib/testing/compliance/comply.d.mts +1 -1
  239. package/dist/lib/testing/compliance/comply.d.ts +1 -1
  240. package/dist/lib/testing/compliance/comply.d.ts.map +1 -1
  241. package/dist/lib/testing/compliance/comply.js +16 -6
  242. package/dist/lib/testing/compliance/comply.js.map +1 -1
  243. package/dist/lib/testing/compliance/comply.mjs +16 -6
  244. package/dist/lib/testing/compliance/comply.mjs.map +1 -1
  245. package/dist/lib/testing/scenarios/brand-rights.js +6 -6
  246. package/dist/lib/testing/scenarios/brand-rights.js.map +1 -1
  247. package/dist/lib/testing/scenarios/brand-rights.mjs +6 -6
  248. package/dist/lib/testing/scenarios/brand-rights.mjs.map +1 -1
  249. package/dist/lib/testing/scenarios/creative.js +7 -7
  250. package/dist/lib/testing/scenarios/creative.js.map +1 -1
  251. package/dist/lib/testing/scenarios/creative.mjs +7 -7
  252. package/dist/lib/testing/scenarios/creative.mjs.map +1 -1
  253. package/dist/lib/testing/scenarios/discovery.js +2 -2
  254. package/dist/lib/testing/scenarios/discovery.js.map +1 -1
  255. package/dist/lib/testing/scenarios/discovery.mjs +2 -2
  256. package/dist/lib/testing/scenarios/discovery.mjs.map +1 -1
  257. package/dist/lib/testing/scenarios/edge-cases.js +11 -11
  258. package/dist/lib/testing/scenarios/edge-cases.js.map +1 -1
  259. package/dist/lib/testing/scenarios/edge-cases.mjs +11 -11
  260. package/dist/lib/testing/scenarios/edge-cases.mjs.map +1 -1
  261. package/dist/lib/testing/scenarios/governance.d.ts.map +1 -1
  262. package/dist/lib/testing/scenarios/governance.js +16 -22
  263. package/dist/lib/testing/scenarios/governance.js.map +1 -1
  264. package/dist/lib/testing/scenarios/governance.mjs +16 -22
  265. package/dist/lib/testing/scenarios/governance.mjs.map +1 -1
  266. package/dist/lib/testing/scenarios/media-buy.js +5 -5
  267. package/dist/lib/testing/scenarios/media-buy.js.map +1 -1
  268. package/dist/lib/testing/scenarios/media-buy.mjs +5 -5
  269. package/dist/lib/testing/scenarios/media-buy.mjs.map +1 -1
  270. package/dist/lib/testing/scenarios/schema-compliance.js +1 -1
  271. package/dist/lib/testing/scenarios/schema-compliance.js.map +1 -1
  272. package/dist/lib/testing/scenarios/schema-compliance.mjs +1 -1
  273. package/dist/lib/testing/scenarios/schema-compliance.mjs.map +1 -1
  274. package/dist/lib/testing/scenarios/trusted-match.d.ts.map +1 -1
  275. package/dist/lib/testing/scenarios/trusted-match.js +4 -3
  276. package/dist/lib/testing/scenarios/trusted-match.js.map +1 -1
  277. package/dist/lib/testing/scenarios/trusted-match.mjs +4 -3
  278. package/dist/lib/testing/scenarios/trusted-match.mjs.map +1 -1
  279. package/dist/lib/testing/storyboard/probes.d.mts +6 -0
  280. package/dist/lib/testing/storyboard/probes.d.ts +6 -0
  281. package/dist/lib/testing/storyboard/probes.d.ts.map +1 -1
  282. package/dist/lib/testing/storyboard/probes.js +16 -5
  283. package/dist/lib/testing/storyboard/probes.js.map +1 -1
  284. package/dist/lib/testing/storyboard/probes.mjs +16 -5
  285. package/dist/lib/testing/storyboard/probes.mjs.map +1 -1
  286. package/dist/lib/testing/storyboard/runner.d.ts.map +1 -1
  287. package/dist/lib/testing/storyboard/runner.js +6 -2
  288. package/dist/lib/testing/storyboard/runner.js.map +1 -1
  289. package/dist/lib/testing/storyboard/runner.mjs +6 -2
  290. package/dist/lib/testing/storyboard/runner.mjs.map +1 -1
  291. package/dist/lib/testing/storyboard/shape-drift-hints.d.mts +3 -4
  292. package/dist/lib/testing/storyboard/shape-drift-hints.d.ts +3 -4
  293. package/dist/lib/testing/storyboard/shape-drift-hints.d.ts.map +1 -1
  294. package/dist/lib/testing/storyboard/shape-drift-hints.js +27 -27
  295. package/dist/lib/testing/storyboard/shape-drift-hints.js.map +1 -1
  296. package/dist/lib/testing/storyboard/shape-drift-hints.mjs +27 -27
  297. package/dist/lib/testing/storyboard/shape-drift-hints.mjs.map +1 -1
  298. package/dist/lib/testing/storyboard/task-map.d.ts.map +1 -1
  299. package/dist/lib/testing/storyboard/task-map.js +43 -5
  300. package/dist/lib/testing/storyboard/task-map.js.map +1 -1
  301. package/dist/lib/testing/storyboard/task-map.mjs +43 -5
  302. package/dist/lib/testing/storyboard/task-map.mjs.map +1 -1
  303. package/dist/lib/testing/test-helpers.d.mts +2 -2
  304. package/dist/lib/testing/test-helpers.d.ts +2 -2
  305. package/dist/lib/testing/test-helpers.js.map +1 -1
  306. package/dist/lib/testing/test-helpers.mjs.map +1 -1
  307. package/dist/lib/testing/types.d.mts +7 -1
  308. package/dist/lib/testing/types.d.ts +7 -1
  309. package/dist/lib/testing/types.d.ts.map +1 -1
  310. package/dist/lib/testing/types.js.map +1 -1
  311. package/dist/lib/types/adcp.d.mts +14 -14
  312. package/dist/lib/types/adcp.d.ts +14 -14
  313. package/dist/lib/types/adcp.d.ts.map +1 -1
  314. package/dist/lib/types/adcp.js.map +1 -1
  315. package/dist/lib/types/adcp.mjs.map +1 -1
  316. package/dist/lib/types/index.d.mts +2 -2
  317. package/dist/lib/types/index.d.ts +2 -2
  318. package/dist/lib/types/index.d.ts.map +1 -1
  319. package/dist/lib/types/index.js.map +1 -1
  320. package/dist/lib/types/index.mjs.map +1 -1
  321. package/dist/lib/utils/capabilities.d.mts +6 -0
  322. package/dist/lib/utils/capabilities.d.ts +6 -0
  323. package/dist/lib/utils/capabilities.d.ts.map +1 -1
  324. package/dist/lib/utils/capabilities.js +4 -0
  325. package/dist/lib/utils/capabilities.js.map +1 -1
  326. package/dist/lib/utils/capabilities.mjs +4 -0
  327. package/dist/lib/utils/capabilities.mjs.map +1 -1
  328. package/dist/lib/utils/creative-delivery.d.mts +52 -10
  329. package/dist/lib/utils/creative-delivery.d.ts +52 -10
  330. package/dist/lib/utils/creative-delivery.d.ts.map +1 -1
  331. package/dist/lib/utils/creative-delivery.js +104 -9
  332. package/dist/lib/utils/creative-delivery.js.map +1 -1
  333. package/dist/lib/utils/creative-delivery.mjs +104 -8
  334. package/dist/lib/utils/creative-delivery.mjs.map +1 -1
  335. package/dist/lib/utils/format-assets.d.mts +41 -38
  336. package/dist/lib/utils/format-assets.d.ts +41 -38
  337. package/dist/lib/utils/format-assets.d.ts.map +1 -1
  338. package/dist/lib/utils/format-assets.js +3 -1
  339. package/dist/lib/utils/format-assets.js.map +1 -1
  340. package/dist/lib/utils/format-assets.mjs +3 -1
  341. package/dist/lib/utils/format-assets.mjs.map +1 -1
  342. package/dist/lib/utils/index.d.mts +8 -8
  343. package/dist/lib/utils/index.d.ts +8 -8
  344. package/dist/lib/utils/index.d.ts.map +1 -1
  345. package/dist/lib/utils/index.js +11 -9
  346. package/dist/lib/utils/index.js.map +1 -1
  347. package/dist/lib/utils/index.mjs +9 -8
  348. package/dist/lib/utils/index.mjs.map +1 -1
  349. package/dist/lib/utils/preview-utils.d.mts +11 -8
  350. package/dist/lib/utils/preview-utils.d.ts +11 -8
  351. package/dist/lib/utils/preview-utils.d.ts.map +1 -1
  352. package/dist/lib/utils/preview-utils.js +4 -4
  353. package/dist/lib/utils/preview-utils.js.map +1 -1
  354. package/dist/lib/utils/preview-utils.mjs +3 -3
  355. package/dist/lib/utils/preview-utils.mjs.map +1 -1
  356. package/dist/lib/utils/tool-request-schemas.d.mts +2 -2
  357. package/dist/lib/utils/tool-request-schemas.d.ts +2 -2
  358. package/dist/lib/v2/projection/aao-reference-formats.json +492 -0
  359. package/dist/lib/v2/projection/augment-response.d.mts +31 -11
  360. package/dist/lib/v2/projection/augment-response.d.ts +31 -11
  361. package/dist/lib/v2/projection/augment-response.d.ts.map +1 -1
  362. package/dist/lib/v2/projection/augment-response.js +233 -27
  363. package/dist/lib/v2/projection/augment-response.js.map +1 -1
  364. package/dist/lib/v2/projection/augment-response.mjs +232 -27
  365. package/dist/lib/v2/projection/augment-response.mjs.map +1 -1
  366. package/dist/lib/v2/projection/builders.d.mts +7 -6
  367. package/dist/lib/v2/projection/builders.d.ts +7 -6
  368. package/dist/lib/v2/projection/builders.d.ts.map +1 -1
  369. package/dist/lib/v2/projection/builders.js +11 -8
  370. package/dist/lib/v2/projection/builders.js.map +1 -1
  371. package/dist/lib/v2/projection/builders.mjs +9 -6
  372. package/dist/lib/v2/projection/builders.mjs.map +1 -1
  373. package/dist/lib/v2/projection/catalog-snapshot.d.mts +47 -0
  374. package/dist/lib/v2/projection/catalog-snapshot.d.ts +48 -0
  375. package/dist/lib/v2/projection/catalog-snapshot.d.ts.map +1 -0
  376. package/dist/lib/v2/projection/catalog-snapshot.js +291 -0
  377. package/dist/lib/v2/projection/catalog-snapshot.js.map +1 -0
  378. package/dist/lib/v2/projection/catalog-snapshot.mjs +265 -0
  379. package/dist/lib/v2/projection/catalog-snapshot.mjs.map +1 -0
  380. package/dist/lib/v2/projection/catalog.d.mts +23 -2
  381. package/dist/lib/v2/projection/catalog.d.ts +23 -2
  382. package/dist/lib/v2/projection/catalog.d.ts.map +1 -1
  383. package/dist/lib/v2/projection/catalog.js +34 -10
  384. package/dist/lib/v2/projection/catalog.js.map +1 -1
  385. package/dist/lib/v2/projection/catalog.mjs +33 -10
  386. package/dist/lib/v2/projection/catalog.mjs.map +1 -1
  387. package/dist/lib/v2/projection/creative-delivery.d.mts +157 -0
  388. package/dist/lib/v2/projection/creative-delivery.d.ts +158 -0
  389. package/dist/lib/v2/projection/creative-delivery.d.ts.map +1 -0
  390. package/dist/lib/v2/projection/creative-delivery.js +967 -0
  391. package/dist/lib/v2/projection/creative-delivery.js.map +1 -0
  392. package/dist/lib/v2/projection/creative-delivery.mjs +941 -0
  393. package/dist/lib/v2/projection/creative-delivery.mjs.map +1 -0
  394. package/dist/lib/v2/projection/index.d.mts +8 -6
  395. package/dist/lib/v2/projection/index.d.ts +8 -6
  396. package/dist/lib/v2/projection/index.d.ts.map +1 -1
  397. package/dist/lib/v2/projection/index.js +26 -4
  398. package/dist/lib/v2/projection/index.js.map +1 -1
  399. package/dist/lib/v2/projection/index.mjs +28 -4
  400. package/dist/lib/v2/projection/index.mjs.map +1 -1
  401. package/dist/lib/v2/projection/legacy-metadata.d.mts +21 -0
  402. package/dist/lib/v2/projection/legacy-metadata.d.ts +22 -0
  403. package/dist/lib/v2/projection/legacy-metadata.d.ts.map +1 -0
  404. package/dist/lib/v2/projection/legacy-metadata.js +73 -0
  405. package/dist/lib/v2/projection/legacy-metadata.js.map +1 -0
  406. package/dist/lib/v2/projection/legacy-metadata.mjs +45 -0
  407. package/dist/lib/v2/projection/legacy-metadata.mjs.map +1 -0
  408. package/dist/lib/v2/projection/types.d.mts +29 -23
  409. package/dist/lib/v2/projection/types.d.ts +29 -23
  410. package/dist/lib/v2/projection/types.d.ts.map +1 -1
  411. package/dist/lib/v2/projection/types.js.map +1 -1
  412. package/dist/lib/v2/projection/v1-to-v2.d.mts +29 -6
  413. package/dist/lib/v2/projection/v1-to-v2.d.ts +29 -6
  414. package/dist/lib/v2/projection/v1-to-v2.d.ts.map +1 -1
  415. package/dist/lib/v2/projection/v1-to-v2.js +218 -9
  416. package/dist/lib/v2/projection/v1-to-v2.js.map +1 -1
  417. package/dist/lib/v2/projection/v1-to-v2.mjs +219 -10
  418. package/dist/lib/v2/projection/v1-to-v2.mjs.map +1 -1
  419. package/dist/lib/v2/projection/v2-to-v1.d.mts +31 -2
  420. package/dist/lib/v2/projection/v2-to-v1.d.ts +31 -2
  421. package/dist/lib/v2/projection/v2-to-v1.d.ts.map +1 -1
  422. package/dist/lib/v2/projection/v2-to-v1.js +138 -7
  423. package/dist/lib/v2/projection/v2-to-v1.js.map +1 -1
  424. package/dist/lib/v2/projection/v2-to-v1.mjs +135 -6
  425. package/dist/lib/v2/projection/v2-to-v1.mjs.map +1 -1
  426. package/dist/lib/v2/projection/write-side.d.mts +12 -13
  427. package/dist/lib/v2/projection/write-side.d.ts +12 -13
  428. package/dist/lib/v2/projection/write-side.d.ts.map +1 -1
  429. package/dist/lib/v2/projection/write-side.js +16 -12
  430. package/dist/lib/v2/projection/write-side.js.map +1 -1
  431. package/dist/lib/v2/projection/write-side.mjs +16 -12
  432. package/dist/lib/v2/projection/write-side.mjs.map +1 -1
  433. package/dist/lib/version.d.mts +3 -3
  434. package/dist/lib/version.d.ts +3 -3
  435. package/dist/lib/version.d.ts.map +1 -1
  436. package/dist/lib/version.js +3 -3
  437. package/dist/lib/version.js.map +1 -1
  438. package/dist/lib/version.mjs +3 -3
  439. package/dist/lib/version.mjs.map +1 -1
  440. package/docs/guides/BUILD-AN-AGENT.md +7 -2
  441. package/docs/guides/PREVIEW-ASSET-DURABILITY.md +6 -2
  442. package/docs/llms.txt +1 -0
  443. package/examples/README.md +1 -1
  444. package/examples/batch-preview-test.ts +3 -3
  445. package/examples/conversation-client.ts +2 -2
  446. package/examples/debug-preview-response.ts +1 -1
  447. package/examples/decisioning-platform-broadcast-tv.ts +10 -4
  448. package/examples/decisioning-platform-mock-seller.ts +16 -9
  449. package/examples/decisioning-platform-programmatic.ts +18 -7
  450. package/examples/error-compliant-server.ts +26 -16
  451. package/examples/generative-creative-demo.ts +7 -19
  452. package/examples/hello_creative_adapter_ad_server.ts +37 -16
  453. package/examples/hello_creative_adapter_template.ts +12 -10
  454. package/examples/hello_seller_adapter_guaranteed.ts +52 -23
  455. package/examples/hello_seller_adapter_multi_tenant.ts +6 -3
  456. package/examples/hello_seller_adapter_non_guaranteed.ts +54 -26
  457. package/examples/hello_seller_adapter_proposal_mode.ts +40 -14
  458. package/examples/hello_seller_adapter_social.ts +2 -7
  459. package/examples/inspect-card-formats.ts +1 -1
  460. package/examples/simple-getting-started.ts +1 -1
  461. package/examples/test-helpers-demo.ts +1 -1
  462. package/package.json +2 -2
  463. package/skills/build-decisioning-creative-template/SKILL.md +11 -11
  464. package/skills/build-decisioning-platform/advanced/REFERENCE.md +8 -2
@@ -36,12 +36,12 @@ import type { ServerPayload } from '../../../types/server-payload.mjs';
36
36
  import type { GetBrandIdentityRequest, GetBrandIdentitySuccess, GetRightsRequest, GetRightsSuccess, AcquireRightsRequest, AcquireRightsAcquired, AcquireRightsPendingApproval, AcquireRightsRejected, UpdateRightsRequest, UpdateRightsSuccess, CreativeApprovalRequest, CreativeApproved, CreativeRejected, CreativePendingReview } from '../../../types/core.generated.mjs';
37
37
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
38
38
  export type GetBrandIdentityPayload = ServerPayload<GetBrandIdentitySuccess>;
39
- export type GetRightsPayload = ServerPayload<GetRightsSuccess>;
40
- export type AcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;
41
- export type AcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;
42
- export type AcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;
43
- export type AcquireRightsPayload = AcquireRightsAcquiredPayload | AcquireRightsPendingApprovalPayload | AcquireRightsRejectedPayload;
44
- export type UpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;
39
+ export type LegacyGetRightsPayload = ServerPayload<GetRightsSuccess>;
40
+ export type LegacyAcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;
41
+ export type LegacyAcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;
42
+ export type LegacyAcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;
43
+ export type LegacyAcquireRightsPayload = LegacyAcquireRightsAcquiredPayload | LegacyAcquireRightsPendingApprovalPayload | LegacyAcquireRightsRejectedPayload;
44
+ export type LegacyUpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;
45
45
  export type CreativeApprovedPayload = ServerPayload<CreativeApproved>;
46
46
  export type CreativeRejectedPayload = ServerPayload<CreativeRejected>;
47
47
  export type CreativePendingReviewPayload = ServerPayload<CreativePendingReview>;
@@ -64,7 +64,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
64
64
  * Note: the wire field is `rights`, NOT `offerings`. Adopters who
65
65
  * named their internal model `offerings` translate at this seam.
66
66
  */
67
- getRights(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<GetRightsPayload>;
67
+ getRightsLegacy(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetRightsPayload>;
68
68
  /**
69
69
  * Acquire rights — buyer commits to an offering. Four wire-spec arms:
70
70
  *
@@ -105,7 +105,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
105
105
  * sync regardless of arm — invalid requests reject before allocating
106
106
  * any state.
107
107
  */
108
- acquireRights(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<AcquireRightsPayload>;
108
+ acquireRightsLegacy(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyAcquireRightsPayload>;
109
109
  /**
110
110
  * Modify an existing rights grant — extend dates, adjust impression caps,
111
111
  * change pricing, pause/resume. Parallels `updateMediaBuy` semantics on
@@ -140,7 +140,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
140
140
  * the response for replay against the same `idempotency_key`; this
141
141
  * handler runs at most once per (key, principal).
142
142
  */
143
- updateRights(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateRightsPayload>;
143
+ updateRightsLegacy(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyUpdateRightsPayload>;
144
144
  /**
145
145
  * Review a creative submitted under an existing rights grant.
146
146
  *
@@ -36,12 +36,12 @@ import type { ServerPayload } from '../../../types/server-payload';
36
36
  import type { GetBrandIdentityRequest, GetBrandIdentitySuccess, GetRightsRequest, GetRightsSuccess, AcquireRightsRequest, AcquireRightsAcquired, AcquireRightsPendingApproval, AcquireRightsRejected, UpdateRightsRequest, UpdateRightsSuccess, CreativeApprovalRequest, CreativeApproved, CreativeRejected, CreativePendingReview } from '../../../types/core.generated';
37
37
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
38
38
  export type GetBrandIdentityPayload = ServerPayload<GetBrandIdentitySuccess>;
39
- export type GetRightsPayload = ServerPayload<GetRightsSuccess>;
40
- export type AcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;
41
- export type AcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;
42
- export type AcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;
43
- export type AcquireRightsPayload = AcquireRightsAcquiredPayload | AcquireRightsPendingApprovalPayload | AcquireRightsRejectedPayload;
44
- export type UpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;
39
+ export type LegacyGetRightsPayload = ServerPayload<GetRightsSuccess>;
40
+ export type LegacyAcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;
41
+ export type LegacyAcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;
42
+ export type LegacyAcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;
43
+ export type LegacyAcquireRightsPayload = LegacyAcquireRightsAcquiredPayload | LegacyAcquireRightsPendingApprovalPayload | LegacyAcquireRightsRejectedPayload;
44
+ export type LegacyUpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;
45
45
  export type CreativeApprovedPayload = ServerPayload<CreativeApproved>;
46
46
  export type CreativeRejectedPayload = ServerPayload<CreativeRejected>;
47
47
  export type CreativePendingReviewPayload = ServerPayload<CreativePendingReview>;
@@ -64,7 +64,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
64
64
  * Note: the wire field is `rights`, NOT `offerings`. Adopters who
65
65
  * named their internal model `offerings` translate at this seam.
66
66
  */
67
- getRights(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<GetRightsPayload>;
67
+ getRightsLegacy(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetRightsPayload>;
68
68
  /**
69
69
  * Acquire rights — buyer commits to an offering. Four wire-spec arms:
70
70
  *
@@ -105,7 +105,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
105
105
  * sync regardless of arm — invalid requests reject before allocating
106
106
  * any state.
107
107
  */
108
- acquireRights(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<AcquireRightsPayload>;
108
+ acquireRightsLegacy(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyAcquireRightsPayload>;
109
109
  /**
110
110
  * Modify an existing rights grant — extend dates, adjust impression caps,
111
111
  * change pricing, pause/resume. Parallels `updateMediaBuy` semantics on
@@ -140,7 +140,7 @@ export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
140
140
  * the response for replay against the same `idempotency_key`; this
141
141
  * handler runs at most once per (key, principal).
142
142
  */
143
- updateRights(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateRightsPayload>;
143
+ updateRightsLegacy(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyUpdateRightsPayload>;
144
144
  /**
145
145
  * Review a creative submitted under an existing rights grant.
146
146
  *
@@ -1 +1 @@
1
- {"version":3,"file":"brand-rights.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/brand-rights.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;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E,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAErG;;;;;;;;;OASG;IACH,eAAe,CAAC,GAAG,EAAE,gBAAgB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAAC;IAE5F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAuCG;IACH,mBAAmB,CAAC,GAAG,EAAE,oBAAoB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAAC;IAExG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiCG;IACH,kBAAkB,CAAC,GAAG,EAAE,mBAAmB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,yBAAyB,CAAC,CAAC;IAErG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAiCG;IACH,sBAAsB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAC;CAC5G"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/brand-rights.ts"],"sourcesContent":["/**\n * BrandRightsPlatform — `brand-rights` specialism (v1.0).\n *\n * Brand-rights agents handle identity discovery + licensing for branded\n * inventory — covers IP holders (sports leagues, movie studios), CTV\n * brand-rights desks, and brand-licensing marketplaces. Adopters\n * implement the four wire tools the spec ships with stable schemas\n * AND framework dispatch infrastructure (in `AdcpToolMap`):\n *\n * - `get_brand_identity` — sync read; brand catalog + identity record\n * - `get_rights` — sync read; rights matching a brand + use query\n * - `acquire_rights` — buyer commits to an offering. Async outcomes\n * are delivered via the buyer-supplied `push_notification_config`\n * webhook (NOT a polling tool — the spec doesn't define one for\n * this surface).\n * - `update_rights` — modify an existing rights grant. Mutating;\n * `idempotency_key` required. Returns updated terms + re-issued\n * credentials, or pending if the change requires rights-holder\n * approval (signaled via `implementation_date: null`).\n *\n * `creative_approval` is also part of this domain but is webhook-only\n * (not in `AdcpToolMap`). Adopters wire {@link reviewCreativeApproval}\n * to their HTTP server's `approval_webhook` route — the URL they\n * returned to the buyer in `acquire_rights`. Use the\n * `creativeApproved` / `creativeApprovalRejected` /\n * `creativeApprovalPendingReview` / `creativeApprovalError` builders\n * from `@adcp/sdk/server` to construct the webhook response.\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account } from '../account';\nimport type { RequestContext } from '../context';\nimport type { ServerPayload } from '../../../types/server-payload';\n// Brand-rights wire types only live in `core.generated`; the other\n// specialism files import from `tools.generated` (where most\n// per-tool wire types are emitted). Don't \"consistency-fix\" this\n// import path — `tools.generated` doesn't re-export the brand-rights\n// shapes.\nimport type {\n GetBrandIdentityRequest,\n GetBrandIdentitySuccess,\n GetRightsRequest,\n GetRightsSuccess,\n AcquireRightsRequest,\n AcquireRightsAcquired,\n AcquireRightsPendingApproval,\n AcquireRightsRejected,\n UpdateRightsRequest,\n UpdateRightsSuccess,\n CreativeApprovalRequest,\n CreativeApproved,\n CreativeRejected,\n CreativePendingReview,\n} from '../../../types/core.generated';\n\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type GetBrandIdentityPayload = ServerPayload<GetBrandIdentitySuccess>;\nexport type GetRightsPayload = ServerPayload<GetRightsSuccess>;\nexport type AcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;\nexport type AcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;\nexport type AcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;\nexport type AcquireRightsPayload =\n | AcquireRightsAcquiredPayload\n | AcquireRightsPendingApprovalPayload\n | AcquireRightsRejectedPayload;\nexport type UpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;\nexport type CreativeApprovedPayload = ServerPayload<CreativeApproved>;\nexport type CreativeRejectedPayload = ServerPayload<CreativeRejected>;\nexport type CreativePendingReviewPayload = ServerPayload<CreativePendingReview>;\nexport type CreativeApprovalPayload = CreativeApprovedPayload | CreativeRejectedPayload | CreativePendingReviewPayload;\n\nexport interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {\n /**\n * Read brand identity record — `brand_id`, `house`, localized `names`,\n * optional logos / industries / `keller_type`. Sync; no async ceremony.\n * Throw `AdcpError('REFERENCE_NOT_FOUND')` when the brand reference\n * doesn't resolve to an identity the platform tracks.\n */\n getBrandIdentity(req: GetBrandIdentityRequest, ctx: Ctx<TCtxMeta>): Promise<GetBrandIdentityPayload>;\n\n /**\n * List rights matching a brand + use query. Sync read; framework\n * wraps the response in the wire envelope. Returning an empty\n * `rights` array is valid (= \"no rights available for the requested\n * terms\"); throw `AdcpError` only for buyer-fixable rejection (e.g.,\n * unsupported jurisdiction).\n *\n * Note: the wire field is `rights`, NOT `offerings`. Adopters who\n * named their internal model `offerings` translate at this seam.\n */\n getRights(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<GetRightsPayload>;\n\n /**\n * Acquire rights — buyer commits to an offering. Four wire-spec arms:\n *\n * - `AcquireRightsAcquired` — rights granted immediately. Carries\n * `rights_id`, `rights_status: 'acquired'`, `brand_id`, `terms`,\n * `generation_credentials` (scoped per-LLM-provider keys), and\n * `rights_constraint` so the buyer can plumb the grant directly\n * into creative generation.\n * - `AcquireRightsPendingApproval` — clearance pending counter-\n * signature, legal review, or rights-holder approval. Carries\n * `rights_id`, `rights_status: 'pending_approval'`, `brand_id`, plus\n * optional `detail` and `estimated_response_time` (e.g., '48h').\n * **Async delivery is webhook-only** — the buyer's\n * `push_notification_config.url` receives the eventual\n * `Acquired` or `Rejected` outcome. The spec does NOT define\n * a polling tool for `acquire_rights`; do not reach for\n * `tasks_get` here.\n * - `AcquireRightsRejected` — terminal rejection. Carries\n * `rights_id`, `rights_status: 'rejected'`, `brand_id`, `reason`,\n * and optional `suggestions[]` for buyer remediation.\n *\n * The wire spec also defines a fourth `AcquireRightsError` arm\n * (multi-error `{ errors: Error[] }`) for batch-style failures.\n * Adopters who need that shape throw\n * `AdcpError('INVALID_REQUEST', { details: { errors: [...] } })`\n * — the framework projects to the same wire envelope. The platform\n * interface accepts only the 3 success-arm shapes by design;\n * `AdcpError` is the canonical multi-error path here, matching\n * `SalesPlatform.createMediaBuy` preflight.\n *\n * Throw `AdcpError` only for buyer-fixable REQUEST rejection\n * (`INVALID_REQUEST`, `BUDGET_TOO_LOW`). For spec-defined GRANT\n * rejection (rights unavailable in jurisdiction, talent dispute\n * pending) return the `AcquireRightsRejected` arm so the buyer sees\n * the structured wire response with `reason` + `suggestions`.\n *\n * Pre-flight (catalog availability, agency authorization) MUST run\n * sync regardless of arm — invalid requests reject before allocating\n * any state.\n */\n acquireRights(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<AcquireRightsPayload>;\n\n /**\n * Modify an existing rights grant — extend dates, adjust impression caps,\n * change pricing, pause/resume. Parallels `updateMediaBuy` semantics on\n * the media-buy side: only the fields the buyer provides are touched;\n * omitted fields remain unchanged. The framework auto-hydrates the\n * underlying grant from `req.rights_id` (mirroring `acquire_rights`'s\n * `req.rights` hydration), so the implementation reads the resolved\n * grant from `ctx.store` rather than re-fetching it.\n *\n * Return shape:\n * - `UpdateRightsPayload` — change applied. Carries updated `terms`,\n * re-issued `generation_credentials` (LLM keys reflecting the new\n * constraint), updated `rights_constraint`, and an\n * `implementation_date`:\n * - timestamp string when changes are live immediately\n * - **`null`** when the change requires rights-holder approval —\n * the buyer's `push_notification_config.url` will receive a\n * follow-up webhook with the resolved state.\n *\n * For terminal rejection (e.g., `impression_cap` below already-delivered\n * count, `end_date` earlier than now, switching to an incompatible\n * `pricing_option_id`) throw `AdcpError('INVALID_REQUEST', { details })`\n * — the framework projects the throw into the `UpdateRightsError` wire\n * arm. The Platform method's return type is `Promise<UpdateRightsPayload>`\n * by design: error arms are exclusively reachable via thrown `AdcpError`\n * (matching `acquireRights`'s convention — its return type carries only\n * the three success arms; the multi-error `AcquireRightsError` arm is\n * also thrown). For a multi-error batch result, throw with\n * `details: { errors: [...] }` and the framework projects the array.\n *\n * Idempotency: required (`x-mutates-state: true`). The framework caches\n * the response for replay against the same `idempotency_key`; this\n * handler runs at most once per (key, principal).\n */\n updateRights(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateRightsPayload>;\n\n /**\n * Review a creative submitted under an existing rights grant.\n *\n * **This is a WEBHOOK handler, not a tool.** The spec models creative\n * approval as an HTTP webhook: the buyer POSTs a\n * `CreativeApprovalRequest` to the `approval_webhook` URL the seller\n * returned in `acquire_rights`. The framework does NOT register this as\n * an MCP/A2A tool — adopters mount their own HTTP route at the URL they\n * advertised, parse the request body against\n * `CreativeApprovalRequestSchema`, dispatch to this method, and use\n * `creativeApproved` / `creativeApprovalRejected` /\n * `creativeApprovalPendingReview` / `creativeApprovalError` from\n * `@adcp/sdk/server` to construct the JSON response.\n *\n * Three success arms (the framework's typed signature surfaces the\n * three; the multi-error arm is reachable via thrown `AdcpError` once\n * the receiver glue lands in v6.1+):\n *\n * - `CreativeApproved` — creative cleared for distribution; carries\n * optional `conditions[]` (e.g. \"approved for NL only\").\n * - `CreativeRejected` — terminal rejection; carries `reason` plus\n * optional `suggestions[]` for remediation. Buyer revises and\n * resubmits with a fresh `idempotency_key`.\n * - `CreativePendingReview` — queued for human review. Carry\n * `estimated_response_time` (e.g. \"24h\") and a `status_url` the\n * buyer can poll.\n *\n * Pre-flight (rights grant exists, `creative_url` reachable for review)\n * runs before this method — adopters can read the resolved grant from\n * `ctx.store` after their HTTP route does the schema validation step.\n *\n * Idempotency: required (`x-mutates-state: true`). Resubmission with\n * the same `idempotency_key` returns the original verdict.\n */\n reviewCreativeApproval(req: CreativeApprovalRequest, ctx: Ctx<TCtxMeta>): Promise<CreativeApprovalPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/brand-rights.ts"],"sourcesContent":["/**\n * BrandRightsPlatform — `brand-rights` specialism (v1.0).\n *\n * Brand-rights agents handle identity discovery + licensing for branded\n * inventory — covers IP holders (sports leagues, movie studios), CTV\n * brand-rights desks, and brand-licensing marketplaces. Adopters\n * implement the four wire tools the spec ships with stable schemas\n * AND framework dispatch infrastructure (in `AdcpToolMap`):\n *\n * - `get_brand_identity` — sync read; brand catalog + identity record\n * - `get_rights` — sync read; rights matching a brand + use query\n * - `acquire_rights` — buyer commits to an offering. Async outcomes\n * are delivered via the buyer-supplied `push_notification_config`\n * webhook (NOT a polling tool — the spec doesn't define one for\n * this surface).\n * - `update_rights` — modify an existing rights grant. Mutating;\n * `idempotency_key` required. Returns updated terms + re-issued\n * credentials, or pending if the change requires rights-holder\n * approval (signaled via `implementation_date: null`).\n *\n * `creative_approval` is also part of this domain but is webhook-only\n * (not in `AdcpToolMap`). Adopters wire {@link reviewCreativeApproval}\n * to their HTTP server's `approval_webhook` route — the URL they\n * returned to the buyer in `acquire_rights`. Use the\n * `creativeApproved` / `creativeApprovalRejected` /\n * `creativeApprovalPendingReview` / `creativeApprovalError` builders\n * from `@adcp/sdk/server` to construct the webhook response.\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account } from '../account';\nimport type { RequestContext } from '../context';\nimport type { ServerPayload } from '../../../types/server-payload';\n// Brand-rights wire types only live in `core.generated`; the other\n// specialism files import from `tools.generated` (where most\n// per-tool wire types are emitted). Don't \"consistency-fix\" this\n// import path — `tools.generated` doesn't re-export the brand-rights\n// shapes.\nimport type {\n GetBrandIdentityRequest,\n GetBrandIdentitySuccess,\n GetRightsRequest,\n GetRightsSuccess,\n AcquireRightsRequest,\n AcquireRightsAcquired,\n AcquireRightsPendingApproval,\n AcquireRightsRejected,\n UpdateRightsRequest,\n UpdateRightsSuccess,\n CreativeApprovalRequest,\n CreativeApproved,\n CreativeRejected,\n CreativePendingReview,\n} from '../../../types/core.generated';\n\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type GetBrandIdentityPayload = ServerPayload<GetBrandIdentitySuccess>;\nexport type LegacyGetRightsPayload = ServerPayload<GetRightsSuccess>;\nexport type LegacyAcquireRightsAcquiredPayload = ServerPayload<AcquireRightsAcquired>;\nexport type LegacyAcquireRightsPendingApprovalPayload = ServerPayload<AcquireRightsPendingApproval>;\nexport type LegacyAcquireRightsRejectedPayload = ServerPayload<AcquireRightsRejected>;\nexport type LegacyAcquireRightsPayload =\n | LegacyAcquireRightsAcquiredPayload\n | LegacyAcquireRightsPendingApprovalPayload\n | LegacyAcquireRightsRejectedPayload;\nexport type LegacyUpdateRightsPayload = ServerPayload<UpdateRightsSuccess>;\nexport type CreativeApprovedPayload = ServerPayload<CreativeApproved>;\nexport type CreativeRejectedPayload = ServerPayload<CreativeRejected>;\nexport type CreativePendingReviewPayload = ServerPayload<CreativePendingReview>;\nexport type CreativeApprovalPayload = CreativeApprovedPayload | CreativeRejectedPayload | CreativePendingReviewPayload;\n\nexport interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {\n /**\n * Read brand identity record — `brand_id`, `house`, localized `names`,\n * optional logos / industries / `keller_type`. Sync; no async ceremony.\n * Throw `AdcpError('REFERENCE_NOT_FOUND')` when the brand reference\n * doesn't resolve to an identity the platform tracks.\n */\n getBrandIdentity(req: GetBrandIdentityRequest, ctx: Ctx<TCtxMeta>): Promise<GetBrandIdentityPayload>;\n\n /**\n * List rights matching a brand + use query. Sync read; framework\n * wraps the response in the wire envelope. Returning an empty\n * `rights` array is valid (= \"no rights available for the requested\n * terms\"); throw `AdcpError` only for buyer-fixable rejection (e.g.,\n * unsupported jurisdiction).\n *\n * Note: the wire field is `rights`, NOT `offerings`. Adopters who\n * named their internal model `offerings` translate at this seam.\n */\n getRightsLegacy(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetRightsPayload>;\n\n /**\n * Acquire rights — buyer commits to an offering. Four wire-spec arms:\n *\n * - `AcquireRightsAcquired` — rights granted immediately. Carries\n * `rights_id`, `rights_status: 'acquired'`, `brand_id`, `terms`,\n * `generation_credentials` (scoped per-LLM-provider keys), and\n * `rights_constraint` so the buyer can plumb the grant directly\n * into creative generation.\n * - `AcquireRightsPendingApproval` — clearance pending counter-\n * signature, legal review, or rights-holder approval. Carries\n * `rights_id`, `rights_status: 'pending_approval'`, `brand_id`, plus\n * optional `detail` and `estimated_response_time` (e.g., '48h').\n * **Async delivery is webhook-only** — the buyer's\n * `push_notification_config.url` receives the eventual\n * `Acquired` or `Rejected` outcome. The spec does NOT define\n * a polling tool for `acquire_rights`; do not reach for\n * `tasks_get` here.\n * - `AcquireRightsRejected` — terminal rejection. Carries\n * `rights_id`, `rights_status: 'rejected'`, `brand_id`, `reason`,\n * and optional `suggestions[]` for buyer remediation.\n *\n * The wire spec also defines a fourth `AcquireRightsError` arm\n * (multi-error `{ errors: Error[] }`) for batch-style failures.\n * Adopters who need that shape throw\n * `AdcpError('INVALID_REQUEST', { details: { errors: [...] } })`\n * — the framework projects to the same wire envelope. The platform\n * interface accepts only the 3 success-arm shapes by design;\n * `AdcpError` is the canonical multi-error path here, matching\n * `SalesPlatform.createMediaBuy` preflight.\n *\n * Throw `AdcpError` only for buyer-fixable REQUEST rejection\n * (`INVALID_REQUEST`, `BUDGET_TOO_LOW`). For spec-defined GRANT\n * rejection (rights unavailable in jurisdiction, talent dispute\n * pending) return the `AcquireRightsRejected` arm so the buyer sees\n * the structured wire response with `reason` + `suggestions`.\n *\n * Pre-flight (catalog availability, agency authorization) MUST run\n * sync regardless of arm — invalid requests reject before allocating\n * any state.\n */\n acquireRightsLegacy(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyAcquireRightsPayload>;\n\n /**\n * Modify an existing rights grant — extend dates, adjust impression caps,\n * change pricing, pause/resume. Parallels `updateMediaBuy` semantics on\n * the media-buy side: only the fields the buyer provides are touched;\n * omitted fields remain unchanged. The framework auto-hydrates the\n * underlying grant from `req.rights_id` (mirroring `acquire_rights`'s\n * `req.rights` hydration), so the implementation reads the resolved\n * grant from `ctx.store` rather than re-fetching it.\n *\n * Return shape:\n * - `UpdateRightsPayload` — change applied. Carries updated `terms`,\n * re-issued `generation_credentials` (LLM keys reflecting the new\n * constraint), updated `rights_constraint`, and an\n * `implementation_date`:\n * - timestamp string when changes are live immediately\n * - **`null`** when the change requires rights-holder approval —\n * the buyer's `push_notification_config.url` will receive a\n * follow-up webhook with the resolved state.\n *\n * For terminal rejection (e.g., `impression_cap` below already-delivered\n * count, `end_date` earlier than now, switching to an incompatible\n * `pricing_option_id`) throw `AdcpError('INVALID_REQUEST', { details })`\n * — the framework projects the throw into the `UpdateRightsError` wire\n * arm. The Platform method's return type is `Promise<UpdateRightsPayload>`\n * by design: error arms are exclusively reachable via thrown `AdcpError`\n * (matching `acquireRights`'s convention — its return type carries only\n * the three success arms; the multi-error `AcquireRightsError` arm is\n * also thrown). For a multi-error batch result, throw with\n * `details: { errors: [...] }` and the framework projects the array.\n *\n * Idempotency: required (`x-mutates-state: true`). The framework caches\n * the response for replay against the same `idempotency_key`; this\n * handler runs at most once per (key, principal).\n */\n updateRightsLegacy(req: UpdateRightsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyUpdateRightsPayload>;\n\n /**\n * Review a creative submitted under an existing rights grant.\n *\n * **This is a WEBHOOK handler, not a tool.** The spec models creative\n * approval as an HTTP webhook: the buyer POSTs a\n * `CreativeApprovalRequest` to the `approval_webhook` URL the seller\n * returned in `acquire_rights`. The framework does NOT register this as\n * an MCP/A2A tool — adopters mount their own HTTP route at the URL they\n * advertised, parse the request body against\n * `CreativeApprovalRequestSchema`, dispatch to this method, and use\n * `creativeApproved` / `creativeApprovalRejected` /\n * `creativeApprovalPendingReview` / `creativeApprovalError` from\n * `@adcp/sdk/server` to construct the JSON response.\n *\n * Three success arms (the framework's typed signature surfaces the\n * three; the multi-error arm is reachable via thrown `AdcpError` once\n * the receiver glue lands in v6.1+):\n *\n * - `CreativeApproved` — creative cleared for distribution; carries\n * optional `conditions[]` (e.g. \"approved for NL only\").\n * - `CreativeRejected` — terminal rejection; carries `reason` plus\n * optional `suggestions[]` for remediation. Buyer revises and\n * resubmits with a fresh `idempotency_key`.\n * - `CreativePendingReview` — queued for human review. Carry\n * `estimated_response_time` (e.g. \"24h\") and a `status_url` the\n * buyer can poll.\n *\n * Pre-flight (rights grant exists, `creative_url` reachable for review)\n * runs before this method — adopters can read the resolved grant from\n * `ctx.store` after their HTTP route does the schema validation step.\n *\n * Idempotency: required (`x-mutates-state: true`). Resubmission with\n * the same `idempotency_key` returns the original verdict.\n */\n reviewCreativeApproval(req: CreativeApprovalRequest, ctx: Ctx<TCtxMeta>): Promise<CreativeApprovalPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
@@ -35,52 +35,52 @@ import type { RequestContext } from '../context.mjs';
35
35
  import type { ServerPayload } from '../../../types/server-payload.mjs';
36
36
  import type { ListContentStandardsRequest, ListContentStandardsResponse, GetContentStandardsRequest, GetContentStandardsResponse, CreateContentStandardsRequest, CreateContentStandardsResponse, UpdateContentStandardsRequest, UpdateContentStandardsResponse, CalibrateContentRequest, CalibrateContentResponse, ValidateContentDeliveryRequest, ValidateContentDeliveryResponse, GetMediaBuyArtifactsRequest, GetMediaBuyArtifactsResponse, GetCreativeFeaturesRequest, GetCreativeFeaturesResponse } from '../../../types/tools.generated.mjs';
37
37
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
38
- export type ListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;
39
- export type GetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;
40
- export type CreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;
41
- export type UpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;
42
- export type CalibrateContentPayload = ServerPayload<CalibrateContentResponse>;
43
- export type ValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;
44
- export type GetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;
45
- export type GetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;
38
+ export type LegacyListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;
39
+ export type LegacyGetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;
40
+ export type LegacyCreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;
41
+ export type LegacyUpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;
42
+ export type LegacyCalibrateContentPayload = ServerPayload<CalibrateContentResponse>;
43
+ export type LegacyValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;
44
+ export type LegacyGetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;
45
+ export type LegacyGetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;
46
46
  export interface ContentStandardsPlatform<TCtxMeta = Record<string, unknown>> {
47
47
  /** Discover content standards published by this agent. */
48
- listContentStandards(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<ListContentStandardsPayload>;
48
+ listContentStandardsLegacy(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyListContentStandardsPayload>;
49
49
  /** Read a single content standard by id. */
50
- getContentStandards(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<GetContentStandardsPayload>;
50
+ getContentStandardsLegacy(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetContentStandardsPayload>;
51
51
  /**
52
52
  * Create a new content standard. Adopter validates the policy schema
53
53
  * and returns the persisted record. Idempotent on the buyer's
54
54
  * `idempotency_key`.
55
55
  */
56
- createContentStandards(req: CreateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<CreateContentStandardsPayload>;
56
+ createContentStandardsLegacy(req: CreateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyCreateContentStandardsPayload>;
57
57
  /** Update an existing content standard. */
58
- updateContentStandards(req: UpdateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateContentStandardsPayload>;
58
+ updateContentStandardsLegacy(req: UpdateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyUpdateContentStandardsPayload>;
59
59
  /**
60
60
  * Calibrate content against the published standards. Returns the
61
61
  * standard's current calibration profile + any flags raised against
62
62
  * the submitted content.
63
63
  */
64
- calibrateContent(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<CalibrateContentPayload>;
64
+ calibrateContentLegacy(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyCalibrateContentPayload>;
65
65
  /**
66
66
  * Validate that a delivered media-buy / creative meets the buyer's
67
67
  * declared content-standards. Sellers call this post-flight to confirm
68
68
  * adjacency and policy conformance before issuing a
69
69
  * `validate_content_delivery_artifact` to a governance agent.
70
70
  */
71
- validateContentDelivery(req: ValidateContentDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<ValidateContentDeliveryPayload>;
71
+ validateContentDeliveryLegacy(req: ValidateContentDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyValidateContentDeliveryPayload>;
72
72
  /**
73
73
  * Read content artifacts produced during a media buy's flight (creative
74
74
  * proofs, ad-server tags, completed log captures). Optional — adopters
75
75
  * who don't expose artifact archival omit. Required by governance
76
76
  * receivers running adjacency validation.
77
77
  */
78
- getMediaBuyArtifacts?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<GetMediaBuyArtifactsPayload>;
78
+ getMediaBuyArtifactsLegacy?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetMediaBuyArtifactsPayload>;
79
79
  /**
80
80
  * Read per-creative analyzed features (object detection, scene
81
81
  * classification, transcript) the agent extracted during calibration.
82
82
  * Optional — adopters without analyzer pipelines omit.
83
83
  */
84
- getCreativeFeatures?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeFeaturesPayload>;
84
+ getCreativeFeaturesLegacy?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetCreativeFeaturesPayload>;
85
85
  }
86
86
  export {};
@@ -35,53 +35,53 @@ import type { RequestContext } from '../context';
35
35
  import type { ServerPayload } from '../../../types/server-payload';
36
36
  import type { ListContentStandardsRequest, ListContentStandardsResponse, GetContentStandardsRequest, GetContentStandardsResponse, CreateContentStandardsRequest, CreateContentStandardsResponse, UpdateContentStandardsRequest, UpdateContentStandardsResponse, CalibrateContentRequest, CalibrateContentResponse, ValidateContentDeliveryRequest, ValidateContentDeliveryResponse, GetMediaBuyArtifactsRequest, GetMediaBuyArtifactsResponse, GetCreativeFeaturesRequest, GetCreativeFeaturesResponse } from '../../../types/tools.generated';
37
37
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
38
- export type ListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;
39
- export type GetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;
40
- export type CreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;
41
- export type UpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;
42
- export type CalibrateContentPayload = ServerPayload<CalibrateContentResponse>;
43
- export type ValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;
44
- export type GetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;
45
- export type GetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;
38
+ export type LegacyListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;
39
+ export type LegacyGetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;
40
+ export type LegacyCreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;
41
+ export type LegacyUpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;
42
+ export type LegacyCalibrateContentPayload = ServerPayload<CalibrateContentResponse>;
43
+ export type LegacyValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;
44
+ export type LegacyGetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;
45
+ export type LegacyGetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;
46
46
  export interface ContentStandardsPlatform<TCtxMeta = Record<string, unknown>> {
47
47
  /** Discover content standards published by this agent. */
48
- listContentStandards(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<ListContentStandardsPayload>;
48
+ listContentStandardsLegacy(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyListContentStandardsPayload>;
49
49
  /** Read a single content standard by id. */
50
- getContentStandards(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<GetContentStandardsPayload>;
50
+ getContentStandardsLegacy(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetContentStandardsPayload>;
51
51
  /**
52
52
  * Create a new content standard. Adopter validates the policy schema
53
53
  * and returns the persisted record. Idempotent on the buyer's
54
54
  * `idempotency_key`.
55
55
  */
56
- createContentStandards(req: CreateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<CreateContentStandardsPayload>;
56
+ createContentStandardsLegacy(req: CreateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyCreateContentStandardsPayload>;
57
57
  /** Update an existing content standard. */
58
- updateContentStandards(req: UpdateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateContentStandardsPayload>;
58
+ updateContentStandardsLegacy(req: UpdateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyUpdateContentStandardsPayload>;
59
59
  /**
60
60
  * Calibrate content against the published standards. Returns the
61
61
  * standard's current calibration profile + any flags raised against
62
62
  * the submitted content.
63
63
  */
64
- calibrateContent(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<CalibrateContentPayload>;
64
+ calibrateContentLegacy(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyCalibrateContentPayload>;
65
65
  /**
66
66
  * Validate that a delivered media-buy / creative meets the buyer's
67
67
  * declared content-standards. Sellers call this post-flight to confirm
68
68
  * adjacency and policy conformance before issuing a
69
69
  * `validate_content_delivery_artifact` to a governance agent.
70
70
  */
71
- validateContentDelivery(req: ValidateContentDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<ValidateContentDeliveryPayload>;
71
+ validateContentDeliveryLegacy(req: ValidateContentDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyValidateContentDeliveryPayload>;
72
72
  /**
73
73
  * Read content artifacts produced during a media buy's flight (creative
74
74
  * proofs, ad-server tags, completed log captures). Optional — adopters
75
75
  * who don't expose artifact archival omit. Required by governance
76
76
  * receivers running adjacency validation.
77
77
  */
78
- getMediaBuyArtifacts?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<GetMediaBuyArtifactsPayload>;
78
+ getMediaBuyArtifactsLegacy?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetMediaBuyArtifactsPayload>;
79
79
  /**
80
80
  * Read per-creative analyzed features (object detection, scene
81
81
  * classification, transcript) the agent extracted during calibration.
82
82
  * Optional — adopters without analyzer pipelines omit.
83
83
  */
84
- getCreativeFeatures?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeFeaturesPayload>;
84
+ getCreativeFeaturesLegacy?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyGetCreativeFeaturesPayload>;
85
85
  }
86
86
  export {};
87
87
  //# sourceMappingURL=content-standards.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"content-standards.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/content-standards.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;A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,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,2BAA2B,CAAC,CAAC;IAEjH,4CAA4C;IAC5C,mBAAmB,CAAC,GAAG,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAAC;IAE9G;;;;OAIG;IACH,sBAAsB,CACpB,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,6BAA6B,CAAC,CAAC;IAE1C,2CAA2C;IAC3C,sBAAsB,CACpB,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,6BAA6B,CAAC,CAAC;IAE1C;;;;OAIG;IACH,gBAAgB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAErG;;;;;OAKG;IACH,uBAAuB,CACrB,GAAG,EAAE,8BAA8B,EACnC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,8BAA8B,CAAC,CAAC;IAE3C;;;;;OAKG;IACH,oBAAoB,CAAC,CAAC,GAAG,EAAE,2BAA2B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,2BAA2B,CAAC,CAAC;IAElH;;;;OAIG;IACH,mBAAmB,CAAC,CAAC,GAAG,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAAC;CAChH"}
1
+ {"version":3,"file":"content-standards.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/content-standards.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,M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,iCAAiC,CAAC,CAAC;IAE9C,4CAA4C;IAC5C,yBAAyB,CACvB,GAAG,EAAE,0BAA0B,EAC/B,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,gCAAgC,CAAC,CAAC;IAE7C;;;;OAIG;IACH,4BAA4B,CAC1B,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,mCAAmC,CAAC,CAAC;IAEhD,2CAA2C;IAC3C,4BAA4B,CAC1B,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,mCAAmC,CAAC,CAAC;IAEhD;;;;OAIG;IACH,sBAAsB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,6BAA6B,CAAC,CAAC;IAEjH;;;;;OAKG;IACH,6BAA6B,CAC3B,GAAG,EAAE,8BAA8B,EACnC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,oCAAoC,CAAC,CAAC;IAEjD;;;;;OAKG;IACH,0BAA0B,CAAC,CACzB,GAAG,EAAE,2BAA2B,EAChC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,iCAAiC,CAAC,CAAC;IAE9C;;;;OAIG;IACH,yBAAyB,CAAC,CACxB,GAAG,EAAE,0BAA0B,EAC/B,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,gCAAgC,CAAC,CAAC;CAC9C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/content-standards.ts"],"sourcesContent":["/**\n * ContentStandardsPlatform — `content-standards` specialism (v6.0).\n *\n * Content standards enforcement: brand safety policies, content adjacency\n * rules, and per-creative compliance verification. Adopters who claim\n * `content-standards` in `capabilities.specialisms[]` implement this\n * interface; the framework wires the 6 wire tools that make up the\n * content-standards surface.\n *\n * Two adopter shapes:\n *\n * - **Standalone content-standards agent** (Innovid-style): runs apart\n * from a sales agent; buyers call `list_content_standards` /\n * `get_content_standards` / `validate_content_delivery` directly.\n * - **Composed within a seller** (governance overlay): seller imports\n * content-standards into its agent surface, calls `calibrate_content`\n * internally during creative review, and surfaces violations through\n * `sync_creatives` review state.\n *\n * Both shapes use the same interface; difference is whether the platform\n * field is populated alongside `sales` or as the only specialism.\n *\n * The two analyzer methods (`getMediaBuyArtifacts`, `getCreativeFeatures`)\n * are listed under the same surface in the framework's `GovernanceHandlers`\n * because they're content-feature reads adopters typically expose alongside\n * the policy CRUD. Optional — adopters who don't run analyzer pipelines\n * leave them undefined.\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account } from '../account';\nimport type { RequestContext } from '../context';\nimport type { ServerPayload } from '../../../types/server-payload';\nimport type {\n ListContentStandardsRequest,\n ListContentStandardsResponse,\n GetContentStandardsRequest,\n GetContentStandardsResponse,\n CreateContentStandardsRequest,\n CreateContentStandardsResponse,\n UpdateContentStandardsRequest,\n UpdateContentStandardsResponse,\n CalibrateContentRequest,\n CalibrateContentResponse,\n ValidateContentDeliveryRequest,\n ValidateContentDeliveryResponse,\n GetMediaBuyArtifactsRequest,\n GetMediaBuyArtifactsResponse,\n GetCreativeFeaturesRequest,\n GetCreativeFeaturesResponse,\n} from '../../../types/tools.generated';\n\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type ListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;\nexport type GetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;\nexport type CreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;\nexport type UpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;\nexport type CalibrateContentPayload = ServerPayload<CalibrateContentResponse>;\nexport type ValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;\nexport type GetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;\nexport type GetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;\n\nexport interface ContentStandardsPlatform<TCtxMeta = Record<string, unknown>> {\n /** Discover content standards published by this agent. */\n listContentStandards(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<ListContentStandardsPayload>;\n\n /** Read a single content standard by id. */\n getContentStandards(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<GetContentStandardsPayload>;\n\n /**\n * Create a new content standard. Adopter validates the policy schema\n * and returns the persisted record. Idempotent on the buyer's\n * `idempotency_key`.\n */\n createContentStandards(\n req: CreateContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<CreateContentStandardsPayload>;\n\n /** Update an existing content standard. */\n updateContentStandards(\n req: UpdateContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<UpdateContentStandardsPayload>;\n\n /**\n * Calibrate content against the published standards. Returns the\n * standard's current calibration profile + any flags raised against\n * the submitted content.\n */\n calibrateContent(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<CalibrateContentPayload>;\n\n /**\n * Validate that a delivered media-buy / creative meets the buyer's\n * declared content-standards. Sellers call this post-flight to confirm\n * adjacency and policy conformance before issuing a\n * `validate_content_delivery_artifact` to a governance agent.\n */\n validateContentDelivery(\n req: ValidateContentDeliveryRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<ValidateContentDeliveryPayload>;\n\n /**\n * Read content artifacts produced during a media buy's flight (creative\n * proofs, ad-server tags, completed log captures). Optional — adopters\n * who don't expose artifact archival omit. Required by governance\n * receivers running adjacency validation.\n */\n getMediaBuyArtifacts?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<GetMediaBuyArtifactsPayload>;\n\n /**\n * Read per-creative analyzed features (object detection, scene\n * classification, transcript) the agent extracted during calibration.\n * Optional — adopters without analyzer pipelines omit.\n */\n getCreativeFeatures?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeFeaturesPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/content-standards.ts"],"sourcesContent":["/**\n * ContentStandardsPlatform — `content-standards` specialism (v6.0).\n *\n * Content standards enforcement: brand safety policies, content adjacency\n * rules, and per-creative compliance verification. Adopters who claim\n * `content-standards` in `capabilities.specialisms[]` implement this\n * interface; the framework wires the 6 wire tools that make up the\n * content-standards surface.\n *\n * Two adopter shapes:\n *\n * - **Standalone content-standards agent** (Innovid-style): runs apart\n * from a sales agent; buyers call `list_content_standards` /\n * `get_content_standards` / `validate_content_delivery` directly.\n * - **Composed within a seller** (governance overlay): seller imports\n * content-standards into its agent surface, calls `calibrate_content`\n * internally during creative review, and surfaces violations through\n * `sync_creatives` review state.\n *\n * Both shapes use the same interface; difference is whether the platform\n * field is populated alongside `sales` or as the only specialism.\n *\n * The two analyzer methods (`getMediaBuyArtifacts`, `getCreativeFeatures`)\n * are listed under the same surface in the framework's `GovernanceHandlers`\n * because they're content-feature reads adopters typically expose alongside\n * the policy CRUD. Optional — adopters who don't run analyzer pipelines\n * leave them undefined.\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account } from '../account';\nimport type { RequestContext } from '../context';\nimport type { ServerPayload } from '../../../types/server-payload';\nimport type {\n ListContentStandardsRequest,\n ListContentStandardsResponse,\n GetContentStandardsRequest,\n GetContentStandardsResponse,\n CreateContentStandardsRequest,\n CreateContentStandardsResponse,\n UpdateContentStandardsRequest,\n UpdateContentStandardsResponse,\n CalibrateContentRequest,\n CalibrateContentResponse,\n ValidateContentDeliveryRequest,\n ValidateContentDeliveryResponse,\n GetMediaBuyArtifactsRequest,\n GetMediaBuyArtifactsResponse,\n GetCreativeFeaturesRequest,\n GetCreativeFeaturesResponse,\n} from '../../../types/tools.generated';\n\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type LegacyListContentStandardsPayload = ServerPayload<ListContentStandardsResponse>;\nexport type LegacyGetContentStandardsPayload = ServerPayload<GetContentStandardsResponse>;\nexport type LegacyCreateContentStandardsPayload = ServerPayload<CreateContentStandardsResponse>;\nexport type LegacyUpdateContentStandardsPayload = ServerPayload<UpdateContentStandardsResponse>;\nexport type LegacyCalibrateContentPayload = ServerPayload<CalibrateContentResponse>;\nexport type LegacyValidateContentDeliveryPayload = ServerPayload<ValidateContentDeliveryResponse>;\nexport type LegacyGetMediaBuyArtifactsPayload = ServerPayload<GetMediaBuyArtifactsResponse>;\nexport type LegacyGetCreativeFeaturesPayload = ServerPayload<GetCreativeFeaturesResponse>;\n\nexport interface ContentStandardsPlatform<TCtxMeta = Record<string, unknown>> {\n /** Discover content standards published by this agent. */\n listContentStandardsLegacy(\n req: ListContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyListContentStandardsPayload>;\n\n /** Read a single content standard by id. */\n getContentStandardsLegacy(\n req: GetContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyGetContentStandardsPayload>;\n\n /**\n * Create a new content standard. Adopter validates the policy schema\n * and returns the persisted record. Idempotent on the buyer's\n * `idempotency_key`.\n */\n createContentStandardsLegacy(\n req: CreateContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyCreateContentStandardsPayload>;\n\n /** Update an existing content standard. */\n updateContentStandardsLegacy(\n req: UpdateContentStandardsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyUpdateContentStandardsPayload>;\n\n /**\n * Calibrate content against the published standards. Returns the\n * standard's current calibration profile + any flags raised against\n * the submitted content.\n */\n calibrateContentLegacy(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyCalibrateContentPayload>;\n\n /**\n * Validate that a delivered media-buy / creative meets the buyer's\n * declared content-standards. Sellers call this post-flight to confirm\n * adjacency and policy conformance before issuing a\n * `validate_content_delivery_artifact` to a governance agent.\n */\n validateContentDeliveryLegacy(\n req: ValidateContentDeliveryRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyValidateContentDeliveryPayload>;\n\n /**\n * Read content artifacts produced during a media buy's flight (creative\n * proofs, ad-server tags, completed log captures). Optional — adopters\n * who don't expose artifact archival omit. Required by governance\n * receivers running adjacency validation.\n */\n getMediaBuyArtifactsLegacy?(\n req: GetMediaBuyArtifactsRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyGetMediaBuyArtifactsPayload>;\n\n /**\n * Read per-creative analyzed features (object detection, scene\n * classification, transcript) the agent extracted during calibration.\n * Optional — adopters without analyzer pipelines omit.\n */\n getCreativeFeaturesLegacy?(\n req: GetCreativeFeaturesRequest,\n ctx: Ctx<TCtxMeta>\n ): Promise<LegacyGetCreativeFeaturesPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
@@ -27,17 +27,19 @@ import type { Account, NoAccountCtx } from '../account.mjs';
27
27
  import type { RequestContext } from '../context.mjs';
28
28
  import type { TaskHandoff } from '../async-outcome.mjs';
29
29
  import type { ServerPayload } from '../../../types/server-payload.mjs';
30
- import type { BuildCreativeRequest, CreativeManifest, PreviewCreativeRequest, PreviewCreativeResponse, ListCreativesRequest, ListCreativesResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, CreativeAsset, BuildCreativeSuccess, BuildCreativeMultiSuccess } from '../../../types/tools.generated.mjs';
30
+ import type { BuildCreativeRequest, CreativeManifest, PreviewCreativeRequest, PreviewCreativeResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, BuildCreativeSuccess, BuildCreativeMultiSuccess } from '../../../types/tools.generated.mjs';
31
+ import type { CanonicalCreativeAsset, CanonicalCreativeResponse, CanonicalListCreativesRequest, CanonicalListCreativesResponse } from '../../../v2/projection/creative-delivery.mjs';
31
32
  import type { SyncCreativesRow } from './sales.mjs';
32
- type Creative = CreativeAsset;
33
+ type Creative = CanonicalCreativeAsset;
33
34
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
34
- export type PreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;
35
- export type ListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;
36
- export type ListCreativesPayload = ServerPayload<ListCreativesResponse>;
37
- export type GetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;
38
- export type BuildCreativePayload = ServerPayload<BuildCreativeSuccess>;
39
- export type BuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;
40
- export type BuildCreativeReturn = CreativeManifest | CreativeManifest[] | BuildCreativePayload | BuildCreativeMultiPayload;
35
+ export type LegacyPreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;
36
+ export type LegacyListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;
37
+ export type ListCreativesPayload = ServerPayload<CanonicalListCreativesResponse>;
38
+ export type GetCreativeDeliveryPayload = ServerPayload<CanonicalCreativeResponse<GetCreativeDeliveryResponse>>;
39
+ export type LegacyGetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;
40
+ export type LegacyBuildCreativePayload = ServerPayload<BuildCreativeSuccess>;
41
+ export type LegacyBuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;
42
+ export type LegacyBuildCreativeReturn = CreativeManifest | CreativeManifest[] | LegacyBuildCreativePayload | LegacyBuildCreativeMultiPayload;
41
43
  export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
42
44
  /**
43
45
  * Build / retrieve creative tags. Two invocation modes per the spec:
@@ -59,7 +61,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
59
61
  * that lands, slow tag-generation pipelines await in-request; status
60
62
  * changes flow via `publishStatusChange`.
61
63
  */
62
- buildCreative(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<BuildCreativeReturn>;
64
+ buildCreativeLegacy(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyBuildCreativeReturn>;
63
65
  /**
64
66
  * Preview-only variant — sandbox URL or inline HTML, expires. Always sync.
65
67
  *
@@ -67,7 +69,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
67
69
  * does not carry an `account` field; narrow `ctx.account` before reading
68
70
  * `ctx_metadata` / `id`. See {@link NoAccountCtx}.
69
71
  */
70
- previewCreative(req: PreviewCreativeRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<PreviewCreativePayload>;
72
+ previewCreativeLegacy(req: PreviewCreativeRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<LegacyPreviewCreativePayload>;
71
73
  /**
72
74
  * Format catalog. Optional because adopters who delegate format definitions
73
75
  * to a separate creative agent (declared via `capabilities.creative_agents`)
@@ -75,7 +77,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
75
77
  *
76
78
  * ⚠️ NO-ACCOUNT TOOL. See `previewCreative` note above.
77
79
  */
78
- listCreativeFormats?(req: ListCreativeFormatsRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<ListCreativeFormatsPayload>;
80
+ listCreativeFormatsLegacy?(req: ListCreativeFormatsRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<LegacyListCreativeFormatsPayload>;
79
81
  /**
80
82
  * Push creatives. Return per-creative result rows (sync fast path) OR
81
83
  * `ctx.handoffToTask(fn)` to promote to a background task (HITL —
@@ -90,7 +92,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
90
92
  * graph. When `req.include_pricing`, include vendor pricing options
91
93
  * on each creative.
92
94
  */
93
- listCreatives(req: ListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;
95
+ listCreatives(req: CanonicalListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;
94
96
  /**
95
97
  * Per-creative delivery actuals (impressions, spend, pacing). Sync —
96
98
  * report-running platforms with manual report cycles return the
@@ -27,17 +27,19 @@ import type { Account, NoAccountCtx } from '../account';
27
27
  import type { RequestContext } from '../context';
28
28
  import type { TaskHandoff } from '../async-outcome';
29
29
  import type { ServerPayload } from '../../../types/server-payload';
30
- import type { BuildCreativeRequest, CreativeManifest, PreviewCreativeRequest, PreviewCreativeResponse, ListCreativesRequest, ListCreativesResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, CreativeAsset, BuildCreativeSuccess, BuildCreativeMultiSuccess } from '../../../types/tools.generated';
30
+ import type { BuildCreativeRequest, CreativeManifest, PreviewCreativeRequest, PreviewCreativeResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, BuildCreativeSuccess, BuildCreativeMultiSuccess } from '../../../types/tools.generated';
31
+ import type { CanonicalCreativeAsset, CanonicalCreativeResponse, CanonicalListCreativesRequest, CanonicalListCreativesResponse } from '../../../v2/projection/creative-delivery';
31
32
  import type { SyncCreativesRow } from './sales';
32
- type Creative = CreativeAsset;
33
+ type Creative = CanonicalCreativeAsset;
33
34
  type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
34
- export type PreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;
35
- export type ListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;
36
- export type ListCreativesPayload = ServerPayload<ListCreativesResponse>;
37
- export type GetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;
38
- export type BuildCreativePayload = ServerPayload<BuildCreativeSuccess>;
39
- export type BuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;
40
- export type BuildCreativeReturn = CreativeManifest | CreativeManifest[] | BuildCreativePayload | BuildCreativeMultiPayload;
35
+ export type LegacyPreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;
36
+ export type LegacyListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;
37
+ export type ListCreativesPayload = ServerPayload<CanonicalListCreativesResponse>;
38
+ export type GetCreativeDeliveryPayload = ServerPayload<CanonicalCreativeResponse<GetCreativeDeliveryResponse>>;
39
+ export type LegacyGetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;
40
+ export type LegacyBuildCreativePayload = ServerPayload<BuildCreativeSuccess>;
41
+ export type LegacyBuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;
42
+ export type LegacyBuildCreativeReturn = CreativeManifest | CreativeManifest[] | LegacyBuildCreativePayload | LegacyBuildCreativeMultiPayload;
41
43
  export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
42
44
  /**
43
45
  * Build / retrieve creative tags. Two invocation modes per the spec:
@@ -59,7 +61,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
59
61
  * that lands, slow tag-generation pipelines await in-request; status
60
62
  * changes flow via `publishStatusChange`.
61
63
  */
62
- buildCreative(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<BuildCreativeReturn>;
64
+ buildCreativeLegacy(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyBuildCreativeReturn>;
63
65
  /**
64
66
  * Preview-only variant — sandbox URL or inline HTML, expires. Always sync.
65
67
  *
@@ -67,7 +69,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
67
69
  * does not carry an `account` field; narrow `ctx.account` before reading
68
70
  * `ctx_metadata` / `id`. See {@link NoAccountCtx}.
69
71
  */
70
- previewCreative(req: PreviewCreativeRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<PreviewCreativePayload>;
72
+ previewCreativeLegacy(req: PreviewCreativeRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<LegacyPreviewCreativePayload>;
71
73
  /**
72
74
  * Format catalog. Optional because adopters who delegate format definitions
73
75
  * to a separate creative agent (declared via `capabilities.creative_agents`)
@@ -75,7 +77,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
75
77
  *
76
78
  * ⚠️ NO-ACCOUNT TOOL. See `previewCreative` note above.
77
79
  */
78
- listCreativeFormats?(req: ListCreativeFormatsRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<ListCreativeFormatsPayload>;
80
+ listCreativeFormatsLegacy?(req: ListCreativeFormatsRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<LegacyListCreativeFormatsPayload>;
79
81
  /**
80
82
  * Push creatives. Return per-creative result rows (sync fast path) OR
81
83
  * `ctx.handoffToTask(fn)` to promote to a background task (HITL —
@@ -90,7 +92,7 @@ export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
90
92
  * graph. When `req.include_pricing`, include vendor pricing options
91
93
  * on each creative.
92
94
  */
93
- listCreatives(req: ListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;
95
+ listCreatives(req: CanonicalListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;
94
96
  /**
95
97
  * Per-creative delivery actuals (impressions, spend, pacing). Sync —
96
98
  * report-running platforms with manual report cycles return the
@@ -1 +1 @@
1
- {"version":3,"file":"creative-ad-server.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/creative-ad-server.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EACV,oBAAoB,EACpB,gBAAgB,EAChB,sBAAsB,EACtB,uBAAuB,EACvB,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B,CAAC,CAClB,GAAG,EAAE,0BAA0B,EAC/B,GAAG,EAAE,YAAY,CAAC,QAAQ,CAAC,GAC1B,OAAO,CAAC,0BAA0B,CAAC,CAAC;IAIvC;;;;;;OAMG;IACH,aAAa,CAAC,CACZ,SAAS,EAAE,QAAQ,EAAE,EACrB,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,gBAAgB,EAAE,GAAG,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC;IAEjE;;;;;OAKG;IACH,aAAa,CAAC,GAAG,EAAE,oBAAoB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;IAE5F;;;;;;;;;;;;;;;;;;OAkBG;IACH,mBAAmB,CAAC,MAAM,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAAC;CAClH"}
1
+ {"version":3,"file":"creative-ad-server.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/creative-ad-server.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EACV,oBAAoB,EACpB,gBAAgB,EAChB,sBAAsB,EACtB,uBAAuB,EAGvB,0BAA0B,EAC1B,2BAA2B,EAC3B,0BAA0B,EAC1B,2BAA2B,EAC3B,oBAAoB,EACpB,yBAAyB,EAC1B,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EACV,sBAAsB,EACtB,yBAAyB,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AyB,CAAC,CACxB,GAAG,EAAE,0BAA0B,EAC/B,GAAG,EAAE,YAAY,CAAC,QAAQ,CAAC,GAC1B,OAAO,CAAC,gCAAgC,CAAC,CAAC;IAI7C;;;;;;OAMG;IACH,aAAa,CAAC,CACZ,SAAS,EAAE,QAAQ,EAAE,EACrB,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,gBAAgB,EAAE,GAAG,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC;IAEjE;;;;;OAKG;IACH,aAAa,CAAC,GAAG,EAAE,6BAA6B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;IAErG;;;;;;;;;;;;;;;;;;OAkBG;IACH,mBAAmB,CAAC,MAAM,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAAC;CAClH"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/creative-ad-server.ts"],"sourcesContent":["/**\n * CreativeAdServerPlatform — third creative archetype (v6.0).\n *\n * Stateful creative library + per-creative pricing + tag generation. The\n * canonical shape for creative-ad-server adopters: Innovid, Flashtalking,\n * GAM-creative, CMP-style platforms.\n *\n * Distinct from `CreativeTemplatePlatform` (stateless transform) and\n * `CreativeGenerativePlatform` (brief-driven generation):\n *\n * - **Stateful** — adopter persists creatives in a library; `syncCreatives`\n * pushes assets in, `listCreatives` reads them back, `buildCreative`\n * either looks up an existing creative by id OR pushes a new one\n * - **Pricing per creative** — vendor pricing options on each creative;\n * `pricing_option_id` selected at activation, billed via `report_usage`\n * - **Tag generation** — `buildCreative` returns ad-server tags (VAST,\n * placement-specific tracking pixels, macro-substituted creative HTML)\n * when invoked with `media_buy_id` + `package_id` context\n * - **Per-creative delivery reports** — `get_creative_delivery` returns\n * pacing data per creative across the library\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account, NoAccountCtx } from '../account';\nimport type { RequestContext } from '../context';\nimport type { TaskHandoff } from '../async-outcome';\nimport type { ServerPayload } from '../../../types/server-payload';\nimport type {\n BuildCreativeRequest,\n CreativeManifest,\n PreviewCreativeRequest,\n PreviewCreativeResponse,\n ListCreativesRequest,\n ListCreativesResponse,\n ListCreativeFormatsRequest,\n ListCreativeFormatsResponse,\n GetCreativeDeliveryRequest,\n GetCreativeDeliveryResponse,\n CreativeAsset,\n BuildCreativeSuccess,\n BuildCreativeMultiSuccess,\n} from '../../../types/tools.generated';\nimport type { SyncCreativesRow } from './sales';\n\ntype Creative = CreativeAsset;\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type PreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;\nexport type ListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;\nexport type ListCreativesPayload = ServerPayload<ListCreativesResponse>;\nexport type GetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;\nexport type BuildCreativePayload = ServerPayload<BuildCreativeSuccess>;\nexport type BuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;\nexport type BuildCreativeReturn =\n | CreativeManifest\n | CreativeManifest[]\n | BuildCreativePayload\n | BuildCreativeMultiPayload;\n\nexport interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {\n /**\n * Build / retrieve creative tags. Two invocation modes per the spec:\n *\n * - **Library lookup**: `req.creative_id` references an existing\n * creative; return the manifest with tag fields populated\n * (`vast_tag`, click trackers, etc.). When `req.media_buy_id` +\n * `req.package_id` are also set, generate placement-specific tags\n * with macro substitution baked in.\n * - **Inline build**: `req.creative_manifest` is provided directly;\n * transform / wrap it (similar to template archetype but with\n * ad-server side effects: register the creative in the library,\n * generate the tag, etc.).\n *\n * Spec defines a Submitted arm via `async-response-data.json` but the\n * per-tool `build-creative-response.json` `oneOf` doesn't include it,\n * so codegen produces a `BuildCreativeResponse` without Submitted —\n * a SPEC inconsistency, tracked as adcontextprotocol/adcp#3392. Until\n * that lands, slow tag-generation pipelines await in-request; status\n * changes flow via `publishStatusChange`.\n */\n buildCreative(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<BuildCreativeReturn>;\n\n /**\n * Preview-only variant — sandbox URL or inline HTML, expires. Always sync.\n *\n * ⚠️ NO-ACCOUNT TOOL — `ctx: NoAccountCtx<TCtxMeta>`. The wire request\n * does not carry an `account` field; narrow `ctx.account` before reading\n * `ctx_metadata` / `id`. See {@link NoAccountCtx}.\n */\n previewCreative(req: PreviewCreativeRequest, ctx: NoAccountCtx<TCtxMeta>): Promise<PreviewCreativePayload>;\n\n /**\n * Format catalog. Optional because adopters who delegate format definitions\n * to a separate creative agent (declared via `capabilities.creative_agents`)\n * don't own them; the framework returns `UNSUPPORTED_FEATURE` when omitted.\n *\n * ⚠️ NO-ACCOUNT TOOL. See `previewCreative` note above.\n */\n listCreativeFormats?(\n req: ListCreativeFormatsRequest,\n ctx: NoAccountCtx<TCtxMeta>\n ): Promise<ListCreativeFormatsPayload>;\n\n // sync_creatives: sync OR task — `SyncCreativesResponse` has a Submitted arm.\n\n /**\n * Push creatives. Return per-creative result rows (sync fast path) OR\n * `ctx.handoffToTask(fn)` to promote to a background task (HITL —\n * brand-suitability, S&P review). `action: 'created'` for new entries,\n * `'updated'` for replacements, `'unchanged'` when matching. Optional\n * `status: 'pending_review'` for sync-arm rows awaiting manual review.\n */\n syncCreatives?(\n creatives: Creative[],\n ctx: Ctx<TCtxMeta>\n ): Promise<SyncCreativesRow[] | TaskHandoff<SyncCreativesRow[]>>;\n\n /**\n * Read creatives from the library. Filters + pagination. When\n * `req.include_assignments`, include the buyer's package-assignment\n * graph. When `req.include_pricing`, include vendor pricing options\n * on each creative.\n */\n listCreatives(req: ListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;\n\n /**\n * Per-creative delivery actuals (impressions, spend, pacing). Sync —\n * report-running platforms with manual report cycles return the\n * latest cached actuals and emit `delivery_report` status changes\n * via `publishStatusChange` when fresh reports are available.\n *\n * **Multi-id contract.** `filter.media_buy_ids` and `filter.creative_ids`\n * are arrays — buyers may scope a delivery query to multiple buys or\n * creatives in one call. The platform MUST iterate every supplied id\n * and return one row per matching (creative, buy) pair. Reading only\n * `media_buy_ids[0]` / `creative_ids[0]` silently truncates the\n * buyer's request — a correctness bug to avoid (closes #1342).\n *\n * Pass-through is the framework contract: cross-creative aggregation\n * is platform-domain knowledge (variant-level deduplication, brand\n * mapping, attribution windows), so the framework hands the array\n * through and the platform owns fan-out. Sellers that can't compute\n * cross-cuts omit them; buyers fall back to per-row values.\n */\n getCreativeDelivery(filter: GetCreativeDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeDeliveryPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../../../../src/lib/server/decisioning/specialisms/creative-ad-server.ts"],"sourcesContent":["/**\n * CreativeAdServerPlatform — third creative archetype (v6.0).\n *\n * Stateful creative library + per-creative pricing + tag generation. The\n * canonical shape for creative-ad-server adopters: Innovid, Flashtalking,\n * GAM-creative, CMP-style platforms.\n *\n * Distinct from `CreativeTemplatePlatform` (stateless transform) and\n * `CreativeGenerativePlatform` (brief-driven generation):\n *\n * - **Stateful** — adopter persists creatives in a library; `syncCreatives`\n * pushes assets in, `listCreatives` reads them back, `buildCreative`\n * either looks up an existing creative by id OR pushes a new one\n * - **Pricing per creative** — vendor pricing options on each creative;\n * `pricing_option_id` selected at activation, billed via `report_usage`\n * - **Tag generation** — `buildCreative` returns ad-server tags (VAST,\n * placement-specific tracking pixels, macro-substituted creative HTML)\n * when invoked with `media_buy_id` + `package_id` context\n * - **Per-creative delivery reports** — `get_creative_delivery` returns\n * pacing data per creative across the library\n *\n * Status: Preview / 6.0.\n *\n * @public\n */\n\nimport type { Account, NoAccountCtx } from '../account';\nimport type { RequestContext } from '../context';\nimport type { TaskHandoff } from '../async-outcome';\nimport type { ServerPayload } from '../../../types/server-payload';\nimport type {\n BuildCreativeRequest,\n CreativeManifest,\n PreviewCreativeRequest,\n PreviewCreativeResponse,\n ListCreativesRequest,\n ListCreativesResponse,\n ListCreativeFormatsRequest,\n ListCreativeFormatsResponse,\n GetCreativeDeliveryRequest,\n GetCreativeDeliveryResponse,\n BuildCreativeSuccess,\n BuildCreativeMultiSuccess,\n} from '../../../types/tools.generated';\nimport type {\n CanonicalCreativeAsset,\n CanonicalCreativeResponse,\n CanonicalListCreativesRequest,\n CanonicalListCreativesResponse,\n} from '../../../v2/projection/creative-delivery';\nimport type { SyncCreativesRow } from './sales';\n\ntype Creative = CanonicalCreativeAsset;\ntype Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;\n\nexport type LegacyPreviewCreativePayload = ServerPayload<PreviewCreativeResponse>;\nexport type LegacyListCreativeFormatsPayload = ServerPayload<ListCreativeFormatsResponse>;\nexport type ListCreativesPayload = ServerPayload<CanonicalListCreativesResponse>;\nexport type GetCreativeDeliveryPayload = ServerPayload<CanonicalCreativeResponse<GetCreativeDeliveryResponse>>;\nexport type LegacyGetCreativeDeliveryPayload = ServerPayload<GetCreativeDeliveryResponse>;\nexport type LegacyBuildCreativePayload = ServerPayload<BuildCreativeSuccess>;\nexport type LegacyBuildCreativeMultiPayload = ServerPayload<BuildCreativeMultiSuccess>;\nexport type LegacyBuildCreativeReturn =\n | CreativeManifest\n | CreativeManifest[]\n | LegacyBuildCreativePayload\n | LegacyBuildCreativeMultiPayload;\n\nexport interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {\n /**\n * Build / retrieve creative tags. Two invocation modes per the spec:\n *\n * - **Library lookup**: `req.creative_id` references an existing\n * creative; return the manifest with tag fields populated\n * (`vast_tag`, click trackers, etc.). When `req.media_buy_id` +\n * `req.package_id` are also set, generate placement-specific tags\n * with macro substitution baked in.\n * - **Inline build**: `req.creative_manifest` is provided directly;\n * transform / wrap it (similar to template archetype but with\n * ad-server side effects: register the creative in the library,\n * generate the tag, etc.).\n *\n * Spec defines a Submitted arm via `async-response-data.json` but the\n * per-tool `build-creative-response.json` `oneOf` doesn't include it,\n * so codegen produces a `BuildCreativeResponse` without Submitted —\n * a SPEC inconsistency, tracked as adcontextprotocol/adcp#3392. Until\n * that lands, slow tag-generation pipelines await in-request; status\n * changes flow via `publishStatusChange`.\n */\n buildCreativeLegacy(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<LegacyBuildCreativeReturn>;\n\n /**\n * Preview-only variant — sandbox URL or inline HTML, expires. Always sync.\n *\n * ⚠️ NO-ACCOUNT TOOL — `ctx: NoAccountCtx<TCtxMeta>`. The wire request\n * does not carry an `account` field; narrow `ctx.account` before reading\n * `ctx_metadata` / `id`. See {@link NoAccountCtx}.\n */\n previewCreativeLegacy(\n req: PreviewCreativeRequest,\n ctx: NoAccountCtx<TCtxMeta>\n ): Promise<LegacyPreviewCreativePayload>;\n\n /**\n * Format catalog. Optional because adopters who delegate format definitions\n * to a separate creative agent (declared via `capabilities.creative_agents`)\n * don't own them; the framework returns `UNSUPPORTED_FEATURE` when omitted.\n *\n * ⚠️ NO-ACCOUNT TOOL. See `previewCreative` note above.\n */\n listCreativeFormatsLegacy?(\n req: ListCreativeFormatsRequest,\n ctx: NoAccountCtx<TCtxMeta>\n ): Promise<LegacyListCreativeFormatsPayload>;\n\n // sync_creatives: sync OR task — `SyncCreativesResponse` has a Submitted arm.\n\n /**\n * Push creatives. Return per-creative result rows (sync fast path) OR\n * `ctx.handoffToTask(fn)` to promote to a background task (HITL —\n * brand-suitability, S&P review). `action: 'created'` for new entries,\n * `'updated'` for replacements, `'unchanged'` when matching. Optional\n * `status: 'pending_review'` for sync-arm rows awaiting manual review.\n */\n syncCreatives?(\n creatives: Creative[],\n ctx: Ctx<TCtxMeta>\n ): Promise<SyncCreativesRow[] | TaskHandoff<SyncCreativesRow[]>>;\n\n /**\n * Read creatives from the library. Filters + pagination. When\n * `req.include_assignments`, include the buyer's package-assignment\n * graph. When `req.include_pricing`, include vendor pricing options\n * on each creative.\n */\n listCreatives(req: CanonicalListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesPayload>;\n\n /**\n * Per-creative delivery actuals (impressions, spend, pacing). Sync —\n * report-running platforms with manual report cycles return the\n * latest cached actuals and emit `delivery_report` status changes\n * via `publishStatusChange` when fresh reports are available.\n *\n * **Multi-id contract.** `filter.media_buy_ids` and `filter.creative_ids`\n * are arrays — buyers may scope a delivery query to multiple buys or\n * creatives in one call. The platform MUST iterate every supplied id\n * and return one row per matching (creative, buy) pair. Reading only\n * `media_buy_ids[0]` / `creative_ids[0]` silently truncates the\n * buyer's request — a correctness bug to avoid (closes #1342).\n *\n * Pass-through is the framework contract: cross-creative aggregation\n * is platform-domain knowledge (variant-level deduplication, brand\n * mapping, attribution windows), so the framework hands the array\n * through and the platform owns fan-out. Sellers that can't compute\n * cross-cuts omit them; buyers fall back to per-row values.\n */\n getCreativeDelivery(filter: GetCreativeDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeDeliveryPayload>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}