@adcp/sdk 12.1.1 → 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.
- package/README.md +19 -3
- package/bin/adcp-fuzz.js +3 -1
- package/dist/lib/adapters/content-standards-adapter.d.mts +9 -9
- package/dist/lib/adapters/content-standards-adapter.d.ts +9 -9
- package/dist/lib/adapters/content-standards-adapter.d.ts.map +1 -1
- package/dist/lib/adapters/content-standards-adapter.js +22 -22
- package/dist/lib/adapters/content-standards-adapter.js.map +1 -1
- package/dist/lib/adapters/content-standards-adapter.mjs +18 -18
- package/dist/lib/adapters/content-standards-adapter.mjs.map +1 -1
- package/dist/lib/adapters/index.d.mts +2 -2
- package/dist/lib/adapters/index.d.ts +2 -2
- package/dist/lib/adapters/index.d.ts.map +1 -1
- package/dist/lib/adapters/index.js +10 -10
- package/dist/lib/adapters/index.js.map +1 -1
- package/dist/lib/adapters/index.mjs +9 -9
- package/dist/lib/adapters/index.mjs.map +1 -1
- package/dist/lib/auth/oauth/provider-cache.d.mts +7 -0
- package/dist/lib/auth/oauth/provider-cache.d.ts +8 -0
- package/dist/lib/auth/oauth/provider-cache.d.ts.map +1 -0
- package/dist/lib/auth/oauth/provider-cache.js +44 -0
- package/dist/lib/auth/oauth/provider-cache.js.map +1 -0
- package/dist/lib/auth/oauth/provider-cache.mjs +19 -0
- package/dist/lib/auth/oauth/provider-cache.mjs.map +1 -0
- package/dist/lib/conformance/invariants/uniformError.js +1 -1
- package/dist/lib/conformance/invariants/uniformError.js.map +1 -1
- package/dist/lib/conformance/invariants/uniformError.mjs +1 -1
- package/dist/lib/conformance/invariants/uniformError.mjs.map +1 -1
- package/dist/lib/conformance/runners.js +1 -1
- package/dist/lib/conformance/runners.js.map +1 -1
- package/dist/lib/conformance/runners.mjs +1 -1
- package/dist/lib/conformance/runners.mjs.map +1 -1
- package/dist/lib/conformance/seeder.js +5 -5
- package/dist/lib/conformance/seeder.js.map +1 -1
- package/dist/lib/conformance/seeder.mjs +5 -5
- package/dist/lib/conformance/seeder.mjs.map +1 -1
- package/dist/lib/core/ADCPMultiAgentClient.d.mts +26 -29
- package/dist/lib/core/ADCPMultiAgentClient.d.ts +26 -29
- package/dist/lib/core/ADCPMultiAgentClient.d.ts.map +1 -1
- package/dist/lib/core/ADCPMultiAgentClient.js +27 -19
- package/dist/lib/core/ADCPMultiAgentClient.js.map +1 -1
- package/dist/lib/core/ADCPMultiAgentClient.mjs +27 -19
- package/dist/lib/core/ADCPMultiAgentClient.mjs.map +1 -1
- package/dist/lib/core/AgentClient.d.mts +148 -138
- package/dist/lib/core/AgentClient.d.ts +148 -138
- package/dist/lib/core/AgentClient.d.ts.map +1 -1
- package/dist/lib/core/AgentClient.js +174 -85
- package/dist/lib/core/AgentClient.js.map +1 -1
- package/dist/lib/core/AgentClient.mjs +174 -85
- package/dist/lib/core/AgentClient.mjs.map +1 -1
- package/dist/lib/core/AsyncHandler.d.mts +18 -16
- package/dist/lib/core/AsyncHandler.d.ts +18 -16
- package/dist/lib/core/AsyncHandler.d.ts.map +1 -1
- package/dist/lib/core/AsyncHandler.js +22 -1
- package/dist/lib/core/AsyncHandler.js.map +1 -1
- package/dist/lib/core/AsyncHandler.mjs +22 -1
- package/dist/lib/core/AsyncHandler.mjs.map +1 -1
- package/dist/lib/core/ConversationTypes.d.mts +6 -2
- package/dist/lib/core/ConversationTypes.d.ts +6 -2
- package/dist/lib/core/ConversationTypes.d.ts.map +1 -1
- package/dist/lib/core/ConversationTypes.js.map +1 -1
- package/dist/lib/core/CreativeAgentClient.d.mts +41 -17
- package/dist/lib/core/CreativeAgentClient.d.ts +41 -17
- package/dist/lib/core/CreativeAgentClient.d.ts.map +1 -1
- package/dist/lib/core/CreativeAgentClient.js +39 -12
- package/dist/lib/core/CreativeAgentClient.js.map +1 -1
- package/dist/lib/core/CreativeAgentClient.mjs +39 -12
- package/dist/lib/core/CreativeAgentClient.mjs.map +1 -1
- package/dist/lib/core/SingleAgentClient.d.mts +127 -50
- package/dist/lib/core/SingleAgentClient.d.ts +127 -50
- package/dist/lib/core/SingleAgentClient.d.ts.map +1 -1
- package/dist/lib/core/SingleAgentClient.js +1617 -177
- package/dist/lib/core/SingleAgentClient.js.map +1 -1
- package/dist/lib/core/SingleAgentClient.mjs +1627 -177
- package/dist/lib/core/SingleAgentClient.mjs.map +1 -1
- package/dist/lib/core/TaskExecutor.d.mts +9 -0
- package/dist/lib/core/TaskExecutor.d.ts +9 -0
- package/dist/lib/core/TaskExecutor.d.ts.map +1 -1
- package/dist/lib/core/TaskExecutor.js +136 -43
- package/dist/lib/core/TaskExecutor.js.map +1 -1
- package/dist/lib/core/TaskExecutor.mjs +136 -43
- package/dist/lib/core/TaskExecutor.mjs.map +1 -1
- package/dist/lib/index.d.mts +111 -17
- package/dist/lib/index.d.ts +111 -17
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/index.js +94 -94
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +93 -94
- package/dist/lib/index.mjs.map +1 -1
- package/dist/lib/protocols/index.d.ts.map +1 -1
- package/dist/lib/protocols/index.js +6 -15
- package/dist/lib/protocols/index.js.map +1 -1
- package/dist/lib/protocols/index.mjs +6 -16
- package/dist/lib/protocols/index.mjs.map +1 -1
- package/dist/lib/protocols/mcp-modern.d.ts.map +1 -1
- package/dist/lib/protocols/mcp-modern.js +87 -12
- package/dist/lib/protocols/mcp-modern.js.map +1 -1
- package/dist/lib/protocols/mcp-modern.mjs +89 -12
- package/dist/lib/protocols/mcp-modern.mjs.map +1 -1
- package/dist/lib/schemas-data/v2.5/_provenance.json +1 -1
- package/dist/lib/server/create-adcp-server.d.mts +6 -0
- package/dist/lib/server/create-adcp-server.d.ts +6 -0
- package/dist/lib/server/create-adcp-server.d.ts.map +1 -1
- package/dist/lib/server/create-adcp-server.js +295 -48
- package/dist/lib/server/create-adcp-server.js.map +1 -1
- package/dist/lib/server/create-adcp-server.mjs +301 -50
- package/dist/lib/server/create-adcp-server.mjs.map +1 -1
- package/dist/lib/server/decisioning/assembly-helpers.d.mts +27 -13
- package/dist/lib/server/decisioning/assembly-helpers.d.ts +27 -13
- package/dist/lib/server/decisioning/assembly-helpers.d.ts.map +1 -1
- package/dist/lib/server/decisioning/assembly-helpers.js +136 -14
- package/dist/lib/server/decisioning/assembly-helpers.js.map +1 -1
- package/dist/lib/server/decisioning/assembly-helpers.mjs +134 -13
- package/dist/lib/server/decisioning/assembly-helpers.mjs.map +1 -1
- package/dist/lib/server/decisioning/index.d.mts +13 -12
- package/dist/lib/server/decisioning/index.d.ts +13 -12
- package/dist/lib/server/decisioning/index.d.ts.map +1 -1
- package/dist/lib/server/decisioning/index.js +6 -0
- package/dist/lib/server/decisioning/index.js.map +1 -1
- package/dist/lib/server/decisioning/index.mjs +9 -3
- package/dist/lib/server/decisioning/index.mjs.map +1 -1
- package/dist/lib/server/decisioning/list-helpers.d.mts +13 -3
- package/dist/lib/server/decisioning/list-helpers.d.ts +13 -3
- package/dist/lib/server/decisioning/list-helpers.d.ts.map +1 -1
- package/dist/lib/server/decisioning/list-helpers.js +13 -3
- package/dist/lib/server/decisioning/list-helpers.js.map +1 -1
- package/dist/lib/server/decisioning/list-helpers.mjs +11 -2
- package/dist/lib/server/decisioning/list-helpers.mjs.map +1 -1
- package/dist/lib/server/decisioning/manifest-helpers.d.mts +5 -3
- package/dist/lib/server/decisioning/manifest-helpers.d.ts +5 -3
- package/dist/lib/server/decisioning/manifest-helpers.d.ts.map +1 -1
- package/dist/lib/server/decisioning/manifest-helpers.js.map +1 -1
- package/dist/lib/server/decisioning/manifest-helpers.mjs.map +1 -1
- package/dist/lib/server/decisioning/proposal/dispatch.d.mts +2 -2
- package/dist/lib/server/decisioning/proposal/dispatch.d.ts +2 -2
- package/dist/lib/server/decisioning/proposal/dispatch.d.ts.map +1 -1
- package/dist/lib/server/decisioning/proposal/dispatch.js.map +1 -1
- package/dist/lib/server/decisioning/proposal/dispatch.mjs.map +1 -1
- package/dist/lib/server/decisioning/proposal/index.d.mts +1 -1
- package/dist/lib/server/decisioning/proposal/index.d.ts +1 -1
- package/dist/lib/server/decisioning/proposal/index.d.ts.map +1 -1
- package/dist/lib/server/decisioning/proposal/index.js.map +1 -1
- package/dist/lib/server/decisioning/proposal/index.mjs.map +1 -1
- package/dist/lib/server/decisioning/proposal/lifecycle.d.mts +3 -2
- package/dist/lib/server/decisioning/proposal/lifecycle.d.ts +3 -2
- package/dist/lib/server/decisioning/proposal/lifecycle.d.ts.map +1 -1
- package/dist/lib/server/decisioning/proposal/lifecycle.js.map +1 -1
- package/dist/lib/server/decisioning/proposal/lifecycle.mjs.map +1 -1
- package/dist/lib/server/decisioning/proposal/mock-manager.d.mts +3 -3
- package/dist/lib/server/decisioning/proposal/mock-manager.d.ts +3 -3
- package/dist/lib/server/decisioning/proposal/mock-manager.d.ts.map +1 -1
- package/dist/lib/server/decisioning/proposal/mock-manager.js.map +1 -1
- package/dist/lib/server/decisioning/proposal/mock-manager.mjs.map +1 -1
- package/dist/lib/server/decisioning/proposal/types.d.mts +10 -6
- package/dist/lib/server/decisioning/proposal/types.d.ts +10 -6
- package/dist/lib/server/decisioning/proposal/types.d.ts.map +1 -1
- package/dist/lib/server/decisioning/proposal/types.js.map +1 -1
- package/dist/lib/server/decisioning/proposal/types.mjs.map +1 -1
- package/dist/lib/server/decisioning/runtime/from-platform.d.mts +21 -2
- package/dist/lib/server/decisioning/runtime/from-platform.d.ts +21 -2
- package/dist/lib/server/decisioning/runtime/from-platform.d.ts.map +1 -1
- package/dist/lib/server/decisioning/runtime/from-platform.js +754 -81
- package/dist/lib/server/decisioning/runtime/from-platform.js.map +1 -1
- package/dist/lib/server/decisioning/runtime/from-platform.mjs +763 -81
- package/dist/lib/server/decisioning/runtime/from-platform.mjs.map +1 -1
- package/dist/lib/server/decisioning/specialisms/brand-rights.d.mts +9 -9
- package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts +9 -9
- package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts.map +1 -1
- package/dist/lib/server/decisioning/specialisms/brand-rights.js.map +1 -1
- package/dist/lib/server/decisioning/specialisms/content-standards.d.mts +16 -16
- package/dist/lib/server/decisioning/specialisms/content-standards.d.ts +16 -16
- package/dist/lib/server/decisioning/specialisms/content-standards.d.ts.map +1 -1
- package/dist/lib/server/decisioning/specialisms/content-standards.js.map +1 -1
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.mts +15 -13
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts +15 -13
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts.map +1 -1
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.js.map +1 -1
- package/dist/lib/server/decisioning/specialisms/creative.d.mts +12 -11
- package/dist/lib/server/decisioning/specialisms/creative.d.ts +12 -11
- package/dist/lib/server/decisioning/specialisms/creative.d.ts.map +1 -1
- package/dist/lib/server/decisioning/specialisms/creative.js.map +1 -1
- package/dist/lib/server/decisioning/specialisms/sales.d.mts +25 -15
- package/dist/lib/server/decisioning/specialisms/sales.d.ts +25 -15
- package/dist/lib/server/decisioning/specialisms/sales.d.ts.map +1 -1
- package/dist/lib/server/decisioning/specialisms/sales.js.map +1 -1
- package/dist/lib/server/index.d.mts +3 -3
- package/dist/lib/server/index.d.ts +3 -3
- package/dist/lib/server/index.d.ts.map +1 -1
- package/dist/lib/server/index.js +72 -72
- package/dist/lib/server/index.js.map +1 -1
- package/dist/lib/server/index.mjs +36 -36
- package/dist/lib/server/index.mjs.map +1 -1
- package/dist/lib/server/legacy/v5/index.d.mts +1 -0
- package/dist/lib/server/legacy/v5/index.d.ts +1 -0
- package/dist/lib/server/legacy/v5/index.d.ts.map +1 -1
- package/dist/lib/server/legacy/v5/index.js +74 -1
- package/dist/lib/server/legacy/v5/index.js.map +1 -1
- package/dist/lib/server/legacy/v5/index.mjs +75 -1
- package/dist/lib/server/legacy/v5/index.mjs.map +1 -1
- package/dist/lib/server/responses.d.mts +2 -2
- package/dist/lib/server/responses.d.ts +2 -2
- package/dist/lib/server/responses.js.map +1 -1
- package/dist/lib/server/responses.mjs.map +1 -1
- package/dist/lib/testing/client.js +1 -1
- package/dist/lib/testing/client.js.map +1 -1
- package/dist/lib/testing/client.mjs +1 -1
- package/dist/lib/testing/client.mjs.map +1 -1
- package/dist/lib/testing/scenarios/brand-rights.js +6 -6
- package/dist/lib/testing/scenarios/brand-rights.js.map +1 -1
- package/dist/lib/testing/scenarios/brand-rights.mjs +6 -6
- package/dist/lib/testing/scenarios/brand-rights.mjs.map +1 -1
- package/dist/lib/testing/scenarios/creative.js +7 -7
- package/dist/lib/testing/scenarios/creative.js.map +1 -1
- package/dist/lib/testing/scenarios/creative.mjs +7 -7
- package/dist/lib/testing/scenarios/creative.mjs.map +1 -1
- package/dist/lib/testing/scenarios/discovery.js +2 -2
- package/dist/lib/testing/scenarios/discovery.js.map +1 -1
- package/dist/lib/testing/scenarios/discovery.mjs +2 -2
- package/dist/lib/testing/scenarios/discovery.mjs.map +1 -1
- package/dist/lib/testing/scenarios/edge-cases.js +11 -11
- package/dist/lib/testing/scenarios/edge-cases.js.map +1 -1
- package/dist/lib/testing/scenarios/edge-cases.mjs +11 -11
- package/dist/lib/testing/scenarios/edge-cases.mjs.map +1 -1
- package/dist/lib/testing/scenarios/governance.d.ts.map +1 -1
- package/dist/lib/testing/scenarios/governance.js +16 -22
- package/dist/lib/testing/scenarios/governance.js.map +1 -1
- package/dist/lib/testing/scenarios/governance.mjs +16 -22
- package/dist/lib/testing/scenarios/governance.mjs.map +1 -1
- package/dist/lib/testing/scenarios/media-buy.js +5 -5
- package/dist/lib/testing/scenarios/media-buy.js.map +1 -1
- package/dist/lib/testing/scenarios/media-buy.mjs +5 -5
- package/dist/lib/testing/scenarios/media-buy.mjs.map +1 -1
- package/dist/lib/testing/scenarios/schema-compliance.js +1 -1
- package/dist/lib/testing/scenarios/schema-compliance.js.map +1 -1
- package/dist/lib/testing/scenarios/schema-compliance.mjs +1 -1
- package/dist/lib/testing/scenarios/schema-compliance.mjs.map +1 -1
- package/dist/lib/testing/scenarios/trusted-match.d.ts.map +1 -1
- package/dist/lib/testing/scenarios/trusted-match.js +4 -3
- package/dist/lib/testing/scenarios/trusted-match.js.map +1 -1
- package/dist/lib/testing/scenarios/trusted-match.mjs +4 -3
- package/dist/lib/testing/scenarios/trusted-match.mjs.map +1 -1
- package/dist/lib/testing/storyboard/shape-drift-hints.d.mts +3 -4
- package/dist/lib/testing/storyboard/shape-drift-hints.d.ts +3 -4
- package/dist/lib/testing/storyboard/shape-drift-hints.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/shape-drift-hints.js +27 -27
- package/dist/lib/testing/storyboard/shape-drift-hints.js.map +1 -1
- package/dist/lib/testing/storyboard/shape-drift-hints.mjs +27 -27
- package/dist/lib/testing/storyboard/shape-drift-hints.mjs.map +1 -1
- package/dist/lib/testing/storyboard/task-map.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/task-map.js +43 -5
- package/dist/lib/testing/storyboard/task-map.js.map +1 -1
- package/dist/lib/testing/storyboard/task-map.mjs +43 -5
- package/dist/lib/testing/storyboard/task-map.mjs.map +1 -1
- package/dist/lib/testing/test-helpers.d.mts +2 -2
- package/dist/lib/testing/test-helpers.d.ts +2 -2
- package/dist/lib/testing/test-helpers.js.map +1 -1
- package/dist/lib/testing/test-helpers.mjs.map +1 -1
- package/dist/lib/types/adcp.d.mts +14 -14
- package/dist/lib/types/adcp.d.ts +14 -14
- package/dist/lib/types/adcp.d.ts.map +1 -1
- package/dist/lib/types/adcp.js.map +1 -1
- package/dist/lib/types/adcp.mjs.map +1 -1
- package/dist/lib/types/index.d.mts +2 -2
- package/dist/lib/types/index.d.ts +2 -2
- package/dist/lib/types/index.d.ts.map +1 -1
- package/dist/lib/types/index.js.map +1 -1
- package/dist/lib/types/index.mjs.map +1 -1
- package/dist/lib/utils/capabilities.d.mts +6 -0
- package/dist/lib/utils/capabilities.d.ts +6 -0
- package/dist/lib/utils/capabilities.d.ts.map +1 -1
- package/dist/lib/utils/capabilities.js +4 -0
- package/dist/lib/utils/capabilities.js.map +1 -1
- package/dist/lib/utils/capabilities.mjs +4 -0
- package/dist/lib/utils/capabilities.mjs.map +1 -1
- package/dist/lib/utils/creative-delivery.d.mts +52 -10
- package/dist/lib/utils/creative-delivery.d.ts +52 -10
- package/dist/lib/utils/creative-delivery.d.ts.map +1 -1
- package/dist/lib/utils/creative-delivery.js +104 -9
- package/dist/lib/utils/creative-delivery.js.map +1 -1
- package/dist/lib/utils/creative-delivery.mjs +104 -8
- package/dist/lib/utils/creative-delivery.mjs.map +1 -1
- package/dist/lib/utils/format-assets.d.mts +41 -38
- package/dist/lib/utils/format-assets.d.ts +41 -38
- package/dist/lib/utils/format-assets.d.ts.map +1 -1
- package/dist/lib/utils/format-assets.js +3 -1
- package/dist/lib/utils/format-assets.js.map +1 -1
- package/dist/lib/utils/format-assets.mjs +3 -1
- package/dist/lib/utils/format-assets.mjs.map +1 -1
- package/dist/lib/utils/index.d.mts +8 -8
- package/dist/lib/utils/index.d.ts +8 -8
- package/dist/lib/utils/index.d.ts.map +1 -1
- package/dist/lib/utils/index.js +11 -9
- package/dist/lib/utils/index.js.map +1 -1
- package/dist/lib/utils/index.mjs +9 -8
- package/dist/lib/utils/index.mjs.map +1 -1
- package/dist/lib/utils/preview-utils.d.mts +11 -8
- package/dist/lib/utils/preview-utils.d.ts +11 -8
- package/dist/lib/utils/preview-utils.d.ts.map +1 -1
- package/dist/lib/utils/preview-utils.js +4 -4
- package/dist/lib/utils/preview-utils.js.map +1 -1
- package/dist/lib/utils/preview-utils.mjs +3 -3
- package/dist/lib/utils/preview-utils.mjs.map +1 -1
- package/dist/lib/utils/tool-request-schemas.d.mts +2 -2
- package/dist/lib/utils/tool-request-schemas.d.ts +2 -2
- package/dist/lib/v2/projection/aao-reference-formats.json +492 -0
- package/dist/lib/v2/projection/augment-response.d.mts +31 -11
- package/dist/lib/v2/projection/augment-response.d.ts +31 -11
- package/dist/lib/v2/projection/augment-response.d.ts.map +1 -1
- package/dist/lib/v2/projection/augment-response.js +233 -27
- package/dist/lib/v2/projection/augment-response.js.map +1 -1
- package/dist/lib/v2/projection/augment-response.mjs +232 -27
- package/dist/lib/v2/projection/augment-response.mjs.map +1 -1
- package/dist/lib/v2/projection/builders.d.mts +7 -6
- package/dist/lib/v2/projection/builders.d.ts +7 -6
- package/dist/lib/v2/projection/builders.d.ts.map +1 -1
- package/dist/lib/v2/projection/builders.js +11 -8
- package/dist/lib/v2/projection/builders.js.map +1 -1
- package/dist/lib/v2/projection/builders.mjs +9 -6
- package/dist/lib/v2/projection/builders.mjs.map +1 -1
- package/dist/lib/v2/projection/catalog-snapshot.d.mts +47 -0
- package/dist/lib/v2/projection/catalog-snapshot.d.ts +48 -0
- package/dist/lib/v2/projection/catalog-snapshot.d.ts.map +1 -0
- package/dist/lib/v2/projection/catalog-snapshot.js +291 -0
- package/dist/lib/v2/projection/catalog-snapshot.js.map +1 -0
- package/dist/lib/v2/projection/catalog-snapshot.mjs +265 -0
- package/dist/lib/v2/projection/catalog-snapshot.mjs.map +1 -0
- package/dist/lib/v2/projection/catalog.d.mts +23 -2
- package/dist/lib/v2/projection/catalog.d.ts +23 -2
- package/dist/lib/v2/projection/catalog.d.ts.map +1 -1
- package/dist/lib/v2/projection/catalog.js +34 -10
- package/dist/lib/v2/projection/catalog.js.map +1 -1
- package/dist/lib/v2/projection/catalog.mjs +33 -10
- package/dist/lib/v2/projection/catalog.mjs.map +1 -1
- package/dist/lib/v2/projection/creative-delivery.d.mts +157 -0
- package/dist/lib/v2/projection/creative-delivery.d.ts +158 -0
- package/dist/lib/v2/projection/creative-delivery.d.ts.map +1 -0
- package/dist/lib/v2/projection/creative-delivery.js +967 -0
- package/dist/lib/v2/projection/creative-delivery.js.map +1 -0
- package/dist/lib/v2/projection/creative-delivery.mjs +941 -0
- package/dist/lib/v2/projection/creative-delivery.mjs.map +1 -0
- package/dist/lib/v2/projection/index.d.mts +8 -6
- package/dist/lib/v2/projection/index.d.ts +8 -6
- package/dist/lib/v2/projection/index.d.ts.map +1 -1
- package/dist/lib/v2/projection/index.js +26 -4
- package/dist/lib/v2/projection/index.js.map +1 -1
- package/dist/lib/v2/projection/index.mjs +28 -4
- package/dist/lib/v2/projection/index.mjs.map +1 -1
- package/dist/lib/v2/projection/legacy-metadata.d.mts +21 -0
- package/dist/lib/v2/projection/legacy-metadata.d.ts +22 -0
- package/dist/lib/v2/projection/legacy-metadata.d.ts.map +1 -0
- package/dist/lib/v2/projection/legacy-metadata.js +73 -0
- package/dist/lib/v2/projection/legacy-metadata.js.map +1 -0
- package/dist/lib/v2/projection/legacy-metadata.mjs +45 -0
- package/dist/lib/v2/projection/legacy-metadata.mjs.map +1 -0
- package/dist/lib/v2/projection/types.d.mts +29 -23
- package/dist/lib/v2/projection/types.d.ts +29 -23
- package/dist/lib/v2/projection/types.d.ts.map +1 -1
- package/dist/lib/v2/projection/types.js.map +1 -1
- package/dist/lib/v2/projection/v1-to-v2.d.mts +29 -6
- package/dist/lib/v2/projection/v1-to-v2.d.ts +29 -6
- package/dist/lib/v2/projection/v1-to-v2.d.ts.map +1 -1
- package/dist/lib/v2/projection/v1-to-v2.js +218 -9
- package/dist/lib/v2/projection/v1-to-v2.js.map +1 -1
- package/dist/lib/v2/projection/v1-to-v2.mjs +219 -10
- package/dist/lib/v2/projection/v1-to-v2.mjs.map +1 -1
- package/dist/lib/v2/projection/v2-to-v1.d.mts +31 -2
- package/dist/lib/v2/projection/v2-to-v1.d.ts +31 -2
- package/dist/lib/v2/projection/v2-to-v1.d.ts.map +1 -1
- package/dist/lib/v2/projection/v2-to-v1.js +138 -7
- package/dist/lib/v2/projection/v2-to-v1.js.map +1 -1
- package/dist/lib/v2/projection/v2-to-v1.mjs +135 -6
- package/dist/lib/v2/projection/v2-to-v1.mjs.map +1 -1
- package/dist/lib/v2/projection/write-side.d.mts +12 -13
- package/dist/lib/v2/projection/write-side.d.ts +12 -13
- package/dist/lib/v2/projection/write-side.d.ts.map +1 -1
- package/dist/lib/v2/projection/write-side.js +16 -12
- package/dist/lib/v2/projection/write-side.js.map +1 -1
- package/dist/lib/v2/projection/write-side.mjs +16 -12
- package/dist/lib/v2/projection/write-side.mjs.map +1 -1
- package/dist/lib/version.d.mts +3 -3
- package/dist/lib/version.d.ts +3 -3
- package/dist/lib/version.d.ts.map +1 -1
- package/dist/lib/version.js +3 -3
- package/dist/lib/version.js.map +1 -1
- package/dist/lib/version.mjs +3 -3
- package/dist/lib/version.mjs.map +1 -1
- package/docs/guides/BUILD-AN-AGENT.md +7 -2
- package/docs/guides/PREVIEW-ASSET-DURABILITY.md +6 -2
- package/docs/llms.txt +1 -0
- package/examples/README.md +1 -1
- package/examples/batch-preview-test.ts +3 -3
- package/examples/conversation-client.ts +2 -2
- package/examples/debug-preview-response.ts +1 -1
- package/examples/decisioning-platform-broadcast-tv.ts +10 -4
- package/examples/decisioning-platform-mock-seller.ts +16 -9
- package/examples/decisioning-platform-programmatic.ts +18 -7
- package/examples/error-compliant-server.ts +26 -16
- package/examples/generative-creative-demo.ts +7 -19
- package/examples/hello_creative_adapter_ad_server.ts +37 -16
- package/examples/hello_creative_adapter_template.ts +12 -10
- package/examples/hello_seller_adapter_guaranteed.ts +52 -23
- package/examples/hello_seller_adapter_multi_tenant.ts +6 -3
- package/examples/hello_seller_adapter_non_guaranteed.ts +54 -26
- package/examples/hello_seller_adapter_proposal_mode.ts +40 -14
- package/examples/hello_seller_adapter_social.ts +2 -7
- package/examples/inspect-card-formats.ts +1 -1
- package/examples/simple-getting-started.ts +1 -1
- package/examples/test-helpers-demo.ts +1 -1
- package/package.json +2 -2
- package/skills/build-decisioning-creative-template/SKILL.md +11 -11
- package/skills/build-decisioning-platform/advanced/REFERENCE.md +8 -2
|
@@ -1,65 +1,55 @@
|
|
|
1
1
|
import type { Client as MCPClient } from '@modelcontextprotocol/sdk/client/index.js';
|
|
2
2
|
import type { AgentConfig } from '../types/index.mjs';
|
|
3
|
-
import type { MCPWebhookPayload } from '../types/core.generated.mjs';
|
|
3
|
+
import type { MCPWebhookPayload, GetBrandIdentityRequest, GetBrandIdentityResponse, ContextMatchRequest, ContextMatchResponse, IdentityMatchRequest, IdentityMatchResponse } from '../types/core.generated.mjs';
|
|
4
4
|
import type { Task as A2ATask, TaskStatusUpdateEvent } from '@a2a-js/sdk';
|
|
5
|
-
import { type SingleAgentClientConfig, type VerifyAndParseWebhookOptions, type WebhookParseResult } from './SingleAgentClient.mjs';
|
|
5
|
+
import { type CanonicalReadTaskOptions, type CreativeDeliveryTaskOptions, type SingleAgentClientConfig, type SyncCreativesTaskOptions, type VerifyAndParseWebhookOptions, type WebhookParseResult } from './SingleAgentClient.mjs';
|
|
6
6
|
import type { InputHandler, TaskOptions, TaskResult, TaskInfo, Message } from './ConversationTypes.mjs';
|
|
7
7
|
import type { AdcpCapabilities } from '../utils/capabilities.mjs';
|
|
8
8
|
import type { WebhookHeaderValue } from '../webhooks/index.mjs';
|
|
9
|
-
import type { GetProductsRequest, GetProductsResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, CreateMediaBuyRequest, CreateMediaBuyResponse, UpdateMediaBuyRequest, UpdateMediaBuyResponse, SyncCreativesRequest, SyncCreativesResponse, ListCreativesRequest, ListCreativesResponse, GetMediaBuysRequest, GetMediaBuysResponse, GetMediaBuyDeliveryRequest, GetMediaBuyDeliveryResponse, ProvidePerformanceFeedbackRequest, ProvidePerformanceFeedbackResponse, GetSignalsRequest, GetSignalsResponse, ActivateSignalRequest, ActivateSignalResponse, GetAdCPCapabilitiesRequest, GetAdCPCapabilitiesResponse, PreviewCreativeRequest, PreviewCreativeResponse, BuildCreativeRequest, BuildCreativeResponse, ListAccountsRequest, ListAccountsResponse, SyncAccountsRequest, SyncAccountsResponse, SyncAudiencesRequest, SyncAudiencesResponse, CreatePropertyListRequest, CreatePropertyListResponse, GetPropertyListRequest, GetPropertyListResponse, UpdatePropertyListRequest, UpdatePropertyListResponse, ListPropertyListsRequest, ListPropertyListsResponse, DeletePropertyListRequest, DeletePropertyListResponse, ListContentStandardsRequest, ListContentStandardsResponse, GetContentStandardsRequest, GetContentStandardsResponse, CalibrateContentRequest, CalibrateContentResponse, ValidateContentDeliveryRequest, ValidateContentDeliveryResponse, SIGetOfferingRequest, SIGetOfferingResponse, SIInitiateSessionRequest, SIInitiateSessionResponse, SISendMessageRequest, SISendMessageResponse, SITerminateSessionRequest, SITerminateSessionResponse } from '../types/tools.generated.mjs';
|
|
9
|
+
import type { GetProductsRequest, GetProductsResponse, ListCreativeFormatsRequest, ListCreativeFormatsResponse, CreateMediaBuyRequest, CreateMediaBuyResponse, UpdateMediaBuyRequest, UpdateMediaBuyResponse, SyncCreativesRequest, SyncCreativesResponse, ListCreativesRequest, ListCreativesResponse, GetMediaBuysRequest, GetMediaBuysResponse, GetMediaBuyDeliveryRequest, GetMediaBuyDeliveryResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, ProvidePerformanceFeedbackRequest, ProvidePerformanceFeedbackResponse, GetSignalsRequest, GetSignalsResponse, ActivateSignalRequest, ActivateSignalResponse, GetAdCPCapabilitiesRequest, GetAdCPCapabilitiesResponse, PreviewCreativeRequest, PreviewCreativeResponse, BuildCreativeRequest, BuildCreativeResponse, ListAccountsRequest, ListAccountsResponse, SyncAccountsRequest, SyncAccountsResponse, SyncAudiencesRequest, SyncAudiencesResponse, CreatePropertyListRequest, CreatePropertyListResponse, GetPropertyListRequest, GetPropertyListResponse, UpdatePropertyListRequest, UpdatePropertyListResponse, ListPropertyListsRequest, ListPropertyListsResponse, DeletePropertyListRequest, DeletePropertyListResponse, ListContentStandardsRequest, ListContentStandardsResponse, GetContentStandardsRequest, GetContentStandardsResponse, CalibrateContentRequest, CalibrateContentResponse, ValidateContentDeliveryRequest, ValidateContentDeliveryResponse, SIGetOfferingRequest, SIGetOfferingResponse, SIInitiateSessionRequest, SIInitiateSessionResponse, SISendMessageRequest, SISendMessageResponse, SITerminateSessionRequest, SITerminateSessionResponse, SyncPlansRequest, SyncPlansResponse, CheckGovernanceRequest, CheckGovernanceResponse, ReportPlanOutcomeRequest, ReportPlanOutcomeResponse, GetPlanAuditLogsRequest, GetPlanAuditLogsResponse, ListTransformersRequest, ListTransformersResponse } from '../types/tools.generated.mjs';
|
|
10
10
|
import type { MutatingRequestInput } from '../utils/idempotency.mjs';
|
|
11
|
-
import type {
|
|
12
|
-
import type {
|
|
11
|
+
import type { LegacyFormatConverter } from '../v2/projection/v1-to-v2.mjs';
|
|
12
|
+
import type { ProjectionCatalogSnapshot } from '../v2/projection/catalog-snapshot.mjs';
|
|
13
|
+
import type { CanonicalCreateMediaBuyRequest, CanonicalCreativeResponse, CanonicalGetProductsRequest, CanonicalGetProductsResponse, CanonicalListCreativesRequest, CanonicalListCreativesResponse, CanonicalSyncCreativesRequest, CanonicalUpdateMediaBuyRequest } from '../v2/projection/creative-delivery.mjs';
|
|
14
|
+
export type { CanonicalGetProductsResponse } from '../v2/projection/creative-delivery.mjs';
|
|
15
|
+
export type CanonicalProjectionTaskOptions = TaskOptions & {
|
|
16
|
+
/** Migration escape hatch for seller-specific legacy refs absent from the bundled registry. */
|
|
17
|
+
legacyFormatConverter?: LegacyFormatConverter;
|
|
18
|
+
/** Pre-resolved exact-owner publisher/community catalogs, highest precedence first. */
|
|
19
|
+
projectionCatalogs?: readonly ProjectionCatalogSnapshot[];
|
|
20
|
+
};
|
|
13
21
|
/**
|
|
14
|
-
*
|
|
15
|
-
* when the SDK auto-projects `format_ids[]` → `format_options[]`.
|
|
22
|
+
* Projection metadata attached to canonical `get_products` responses.
|
|
16
23
|
*
|
|
17
|
-
* Present whenever projection ran (the default).
|
|
18
|
-
*
|
|
19
|
-
*
|
|
24
|
+
* Present whenever projection ran (the default). Portable projection
|
|
25
|
+
* advisories are added to the standard `data.errors[]` array; this envelope
|
|
26
|
+
* is a convenience view for SDK-local inspection. Absence of diagnostics means every product's
|
|
20
27
|
* `format_options[]` is fully populated (clean catalog match) or was
|
|
21
28
|
* already v2-shaped on the wire.
|
|
22
29
|
*/
|
|
23
|
-
export interface GetProductsProjectionEnvelope {
|
|
24
|
-
/**
|
|
25
|
-
* Structured diagnostics from the v1→v2 augmentation step
|
|
26
|
-
* (`source: 'sdk'`, parseable `sdk_id`, normative or SDK-local
|
|
27
|
-
* `code`). Empty when every product projects cleanly.
|
|
28
|
-
*/
|
|
29
|
-
diagnostics: ProjectionDiagnostic[];
|
|
30
|
-
}
|
|
31
30
|
/**
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
* Returned by `AgentClient.getProducts()` by default. Callers passing
|
|
37
|
-
* `{ project: false }` opt out of projection and receive the raw
|
|
38
|
-
* generated `GetProductsResponse` instead.
|
|
31
|
+
* @deprecated The primary SDK surface is canonical-only. Use
|
|
32
|
+
* {@link CanonicalGetProductsResponse}. Raw legacy wire shapes remain
|
|
33
|
+
* available only through the explicit `getProductsLegacy()` escape hatch.
|
|
39
34
|
*/
|
|
40
|
-
export type V2AugmentedGetProductsResponse =
|
|
41
|
-
products: V2AugmentedProduct<V1Product>[];
|
|
42
|
-
projection: GetProductsProjectionEnvelope;
|
|
43
|
-
};
|
|
35
|
+
export type V2AugmentedGetProductsResponse = CanonicalGetProductsResponse;
|
|
44
36
|
/**
|
|
45
37
|
* Type mapping for task names to their response types
|
|
46
38
|
* Enables type-safe generic executeTask() calls
|
|
47
39
|
*/
|
|
48
40
|
export type TaskResponseTypeMap = {
|
|
49
|
-
get_products:
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
41
|
+
get_products: CanonicalGetProductsResponse;
|
|
42
|
+
create_media_buy: CanonicalCreativeResponse<CreateMediaBuyResponse>;
|
|
43
|
+
update_media_buy: CanonicalCreativeResponse<UpdateMediaBuyResponse>;
|
|
44
|
+
sync_creatives: CanonicalCreativeResponse<SyncCreativesResponse>;
|
|
45
|
+
list_creatives: CanonicalListCreativesResponse;
|
|
46
|
+
get_media_buys: CanonicalCreativeResponse<GetMediaBuysResponse>;
|
|
47
|
+
get_media_buy_delivery: CanonicalCreativeResponse<GetMediaBuyDeliveryResponse>;
|
|
48
|
+
get_creative_delivery: CanonicalCreativeResponse<GetCreativeDeliveryResponse>;
|
|
57
49
|
provide_performance_feedback: ProvidePerformanceFeedbackResponse;
|
|
58
50
|
get_signals: GetSignalsResponse;
|
|
59
51
|
activate_signal: ActivateSignalResponse;
|
|
60
52
|
get_adcp_capabilities: GetAdCPCapabilitiesResponse;
|
|
61
|
-
preview_creative: PreviewCreativeResponse;
|
|
62
|
-
build_creative: BuildCreativeResponse;
|
|
63
53
|
list_accounts: ListAccountsResponse;
|
|
64
54
|
sync_accounts: SyncAccountsResponse;
|
|
65
55
|
sync_audiences: SyncAudiencesResponse;
|
|
@@ -68,19 +58,57 @@ export type TaskResponseTypeMap = {
|
|
|
68
58
|
update_property_list: UpdatePropertyListResponse;
|
|
69
59
|
list_property_lists: ListPropertyListsResponse;
|
|
70
60
|
delete_property_list: DeletePropertyListResponse;
|
|
71
|
-
list_content_standards: ListContentStandardsResponse;
|
|
72
|
-
get_content_standards: GetContentStandardsResponse;
|
|
73
|
-
calibrate_content: CalibrateContentResponse;
|
|
74
|
-
validate_content_delivery: ValidateContentDeliveryResponse;
|
|
75
61
|
si_get_offering: SIGetOfferingResponse;
|
|
76
62
|
si_initiate_session: SIInitiateSessionResponse;
|
|
77
63
|
si_send_message: SISendMessageResponse;
|
|
78
64
|
si_terminate_session: SITerminateSessionResponse;
|
|
65
|
+
get_brand_identity: GetBrandIdentityResponse;
|
|
66
|
+
sync_plans: SyncPlansResponse;
|
|
67
|
+
check_governance: CheckGovernanceResponse;
|
|
68
|
+
report_plan_outcome: ReportPlanOutcomeResponse;
|
|
69
|
+
get_plan_audit_logs: GetPlanAuditLogsResponse;
|
|
70
|
+
context_match: ContextMatchResponse;
|
|
71
|
+
identity_match: IdentityMatchResponse;
|
|
79
72
|
};
|
|
80
73
|
/**
|
|
81
74
|
* Valid ADCP task names
|
|
82
75
|
*/
|
|
83
76
|
export type AdcpTaskName = keyof TaskResponseTypeMap;
|
|
77
|
+
/** Exact request mapping paired with {@link TaskResponseTypeMap}. */
|
|
78
|
+
export type TaskRequestTypeMap = {
|
|
79
|
+
get_products: CanonicalGetProductsRequest;
|
|
80
|
+
create_media_buy: MutatingRequestInput<CanonicalCreateMediaBuyRequest>;
|
|
81
|
+
update_media_buy: MutatingRequestInput<CanonicalUpdateMediaBuyRequest>;
|
|
82
|
+
sync_creatives: MutatingRequestInput<CanonicalSyncCreativesRequest>;
|
|
83
|
+
list_creatives: CanonicalListCreativesRequest;
|
|
84
|
+
get_media_buys: GetMediaBuysRequest;
|
|
85
|
+
get_media_buy_delivery: GetMediaBuyDeliveryRequest;
|
|
86
|
+
get_creative_delivery: GetCreativeDeliveryRequest;
|
|
87
|
+
provide_performance_feedback: MutatingRequestInput<ProvidePerformanceFeedbackRequest>;
|
|
88
|
+
get_signals: GetSignalsRequest;
|
|
89
|
+
activate_signal: MutatingRequestInput<ActivateSignalRequest>;
|
|
90
|
+
get_adcp_capabilities: GetAdCPCapabilitiesRequest;
|
|
91
|
+
list_accounts: ListAccountsRequest;
|
|
92
|
+
sync_accounts: MutatingRequestInput<SyncAccountsRequest>;
|
|
93
|
+
sync_audiences: MutatingRequestInput<SyncAudiencesRequest>;
|
|
94
|
+
create_property_list: MutatingRequestInput<CreatePropertyListRequest>;
|
|
95
|
+
get_property_list: GetPropertyListRequest;
|
|
96
|
+
update_property_list: MutatingRequestInput<UpdatePropertyListRequest>;
|
|
97
|
+
list_property_lists: ListPropertyListsRequest;
|
|
98
|
+
delete_property_list: MutatingRequestInput<DeletePropertyListRequest>;
|
|
99
|
+
si_get_offering: SIGetOfferingRequest;
|
|
100
|
+
si_initiate_session: MutatingRequestInput<SIInitiateSessionRequest>;
|
|
101
|
+
si_send_message: MutatingRequestInput<SISendMessageRequest>;
|
|
102
|
+
si_terminate_session: SITerminateSessionRequest;
|
|
103
|
+
get_brand_identity: GetBrandIdentityRequest;
|
|
104
|
+
sync_plans: MutatingRequestInput<SyncPlansRequest>;
|
|
105
|
+
check_governance: CheckGovernanceRequest;
|
|
106
|
+
report_plan_outcome: MutatingRequestInput<ReportPlanOutcomeRequest>;
|
|
107
|
+
get_plan_audit_logs: GetPlanAuditLogsRequest;
|
|
108
|
+
context_match: ContextMatchRequest;
|
|
109
|
+
identity_match: IdentityMatchRequest;
|
|
110
|
+
};
|
|
111
|
+
export type TaskRequestFor<K extends AdcpTaskName> = TaskRequestTypeMap[K];
|
|
84
112
|
/**
|
|
85
113
|
* Configuration for `AgentClient.fromMCPClient()`.
|
|
86
114
|
*
|
|
@@ -94,7 +122,7 @@ export type AdcpTaskName = keyof TaskResponseTypeMap;
|
|
|
94
122
|
* - `governance` — buyer-side governance config
|
|
95
123
|
* - `requireV3ForMutations` — enforce AdCP v3 before dispatching mutating tools
|
|
96
124
|
*/
|
|
97
|
-
export type InProcessAgentClientConfig = Pick<SingleAgentClientConfig, 'adcpVersion' | 'versionEnvelope' | 'debug' | 'validation' | 'governance' | 'onActivity' | 'validateFeatures' | 'requireV3ForMutations' | 'allowV2' | 'workingTimeout' | 'defaultMaxClarifications' | 'persistConversations'> & {
|
|
125
|
+
export type InProcessAgentClientConfig = Pick<SingleAgentClientConfig, 'adcpVersion' | 'versionEnvelope' | 'debug' | 'validation' | 'governance' | 'onActivity' | 'legacyFormatConverter' | 'projectionCatalogs' | 'canonicalFormatLegacyResolver' | 'validateFeatures' | 'requireV3ForMutations' | 'allowV2' | 'workingTimeout' | 'defaultMaxClarifications' | 'persistConversations'> & {
|
|
98
126
|
/**
|
|
99
127
|
* Human-readable name for this agent, used in debug logs and
|
|
100
128
|
* `getAgentName()`. Defaults to `'in-process'`.
|
|
@@ -228,91 +256,62 @@ export declare class AgentClient {
|
|
|
228
256
|
/**
|
|
229
257
|
* Discover available advertising products.
|
|
230
258
|
*
|
|
231
|
-
*
|
|
232
|
-
*
|
|
233
|
-
*
|
|
234
|
-
* AAO canonical-formats catalog so buyers always read the same
|
|
235
|
-
* V2 shape regardless of wire version. The original `format_ids[]`
|
|
236
|
-
* is preserved alongside `format_options[]` (additive — 7.x
|
|
237
|
-
* callers reading `format_ids` keep working).
|
|
259
|
+
* Response products expose only canonical `format_options[]`, regardless of
|
|
260
|
+
* the seller's negotiated wire version. The SDK performs any required legacy
|
|
261
|
+
* translation below this public boundary.
|
|
238
262
|
*
|
|
239
|
-
* Projection
|
|
240
|
-
* `result.data.projection.diagnostics` (structured
|
|
263
|
+
* Projection failures surface portably on `result.data.errors[]` and are
|
|
264
|
+
* also mirrored on `result.data.projection.diagnostics` (structured
|
|
241
265
|
* `source: 'sdk'` markers; codes mirror the spec's error-code
|
|
242
266
|
* vocabulary plus three SDK-local codes — see the projection
|
|
243
267
|
* module's `ProjectionDiagnostic` type for the full set).
|
|
244
268
|
*
|
|
245
|
-
*
|
|
246
|
-
*
|
|
247
|
-
* harnesses asserting exact seller emission. The opt-out narrows
|
|
248
|
-
* the return type back to `GetProductsResponse` (no `projection`
|
|
249
|
-
* envelope, no guaranteed `format_options[]`).
|
|
250
|
-
*
|
|
251
|
-
* The 8.0 release narrows further by removing `format_ids[]` from
|
|
252
|
-
* the public Product type entirely.
|
|
253
|
-
*/
|
|
254
|
-
getProducts(params: GetProductsRequest, inputHandler?: InputHandler, options?: TaskOptions & {
|
|
255
|
-
project?: true;
|
|
256
|
-
}): Promise<TaskResult<V2AugmentedGetProductsResponse>>;
|
|
257
|
-
getProducts(params: GetProductsRequest, inputHandler?: InputHandler, options?: TaskOptions & {
|
|
258
|
-
project: false;
|
|
259
|
-
}): Promise<TaskResult<GetProductsResponse>>;
|
|
260
|
-
/**
|
|
261
|
-
* List available creative formats
|
|
269
|
+
* Protocol tooling that must inspect raw seller emission uses the explicit
|
|
270
|
+
* deprecated `getProductsLegacy()` method.
|
|
262
271
|
*/
|
|
263
|
-
|
|
272
|
+
getProducts(params: CanonicalGetProductsRequest, inputHandler?: InputHandler, options?: CanonicalProjectionTaskOptions): Promise<TaskResult<CanonicalGetProductsResponse>>;
|
|
273
|
+
/** @deprecated Explicit raw-wire escape hatch for migration tooling. */
|
|
274
|
+
getProductsLegacy(params: GetProductsRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<GetProductsResponse>>;
|
|
275
|
+
/** @deprecated Migration-only access to a legacy named-format catalog. */
|
|
276
|
+
listCreativeFormatsLegacy(params: ListCreativeFormatsRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<ListCreativeFormatsResponse>>;
|
|
277
|
+
/** @deprecated Migration-only access to legacy creative transformer declarations. */
|
|
278
|
+
listTransformersLegacy(params: ListTransformersRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<ListTransformersResponse>>;
|
|
264
279
|
/**
|
|
265
280
|
* Create a new media buy.
|
|
266
281
|
*
|
|
267
|
-
*
|
|
268
|
-
* `
|
|
269
|
-
*
|
|
270
|
-
* `packageRefsForFormatOptions` to author the package. The helper emits
|
|
271
|
-
* BOTH `format_option_refs[]` (the 3.1+ path) AND `format_ids[]`
|
|
272
|
-
* (legacy named-format dual emission) so a single request works against
|
|
273
|
-
* both format-option-aware and legacy sellers.
|
|
282
|
+
* Discover canonical `format_options[]` with `getProducts()`, select a
|
|
283
|
+
* `format_option_id`, and send only canonical package and creative fields.
|
|
284
|
+
* Compatibility translation for an older seller happens below this method.
|
|
274
285
|
*
|
|
275
286
|
* ```ts
|
|
276
|
-
* import { packageRefsForFormatOptions } from '@adcp/sdk/v2/projection';
|
|
277
|
-
*
|
|
278
287
|
* const { data: { products } } = await agent.getProducts({ brief: '...' });
|
|
279
288
|
* const product = products[0];
|
|
289
|
+
* const format = product.format_options[0];
|
|
280
290
|
*
|
|
281
291
|
* await agent.createMediaBuy({
|
|
282
292
|
* packages: [{
|
|
283
293
|
* package_id: 'pkg-1',
|
|
284
294
|
* product_id: product.product_id,
|
|
285
295
|
* pricing_option_id: product.pricing_options[0].pricing_option_id,
|
|
286
|
-
*
|
|
287
|
-
*
|
|
296
|
+
* format_option_refs: [{
|
|
297
|
+
* scope: 'product',
|
|
298
|
+
* format_option_id: format.format_option_id
|
|
299
|
+
* }],
|
|
300
|
+
* creatives: [{
|
|
301
|
+
* creative_id: 'hero',
|
|
302
|
+
* format_kind: format.format_kind,
|
|
303
|
+
* format_option_ref: {
|
|
304
|
+
* scope: 'product',
|
|
305
|
+
* format_option_id: format.format_option_id
|
|
306
|
+
* },
|
|
307
|
+
* assets: { image: { url: 'https://cdn.example/hero.png' } }
|
|
308
|
+
* }],
|
|
288
309
|
* budget: { currency: 'USD', total: 5000 },
|
|
289
310
|
* }],
|
|
290
311
|
* // ...
|
|
291
312
|
* });
|
|
292
313
|
* ```
|
|
293
314
|
*
|
|
294
|
-
* The resulting wire payload for the package looks like:
|
|
295
|
-
*
|
|
296
|
-
* ```json
|
|
297
|
-
* {
|
|
298
|
-
* "package_id": "pkg-1",
|
|
299
|
-
* "product_id": "...",
|
|
300
|
-
* "pricing_option_id": "...",
|
|
301
|
-
* "format_option_refs": [
|
|
302
|
-
* {"scope": "product", "format_option_id": "nytimes_mrec"},
|
|
303
|
-
* {"scope": "product", "format_option_id": "nytimes_video_30s"}
|
|
304
|
-
* ],
|
|
305
|
-
* "format_ids": [
|
|
306
|
-
* {"agent_url": "https://creative.adcontextprotocol.org/", "id": "display_300x250_image"},
|
|
307
|
-
* {"agent_url": "https://creative.adcontextprotocol.org/", "id": "video_standard_30s"}
|
|
308
|
-
* ],
|
|
309
|
-
* "budget": {"currency": "USD", "total": 5000}
|
|
310
|
-
* }
|
|
311
|
-
* ```
|
|
312
|
-
*
|
|
313
|
-
* `format_ids` is omitted entirely when every chosen format option is V2-only
|
|
314
|
-
* (the spec's "neither present" fallback fires for v1 sellers in that case).
|
|
315
|
-
*
|
|
316
315
|
* **Inline creative fallback.** Sellers that do not advertise a creative
|
|
317
316
|
* library (`supportsSyncCreatives(await agent.getCapabilities()) === false`)
|
|
318
317
|
* can still accept package-scoped creative uploads when they advertise
|
|
@@ -323,19 +322,12 @@ export declare class AgentClient {
|
|
|
323
322
|
* assignments for create payloads, give each package a stable key such as
|
|
324
323
|
* `context.buyer_ref`, or pass a custom `packageId` resolver.
|
|
325
324
|
*
|
|
326
|
-
*
|
|
327
|
-
*
|
|
328
|
-
* `legacyFormatIdsFromOptions` / `tryLegacyFormatIdsFromOptions` /
|
|
329
|
-
* `legacyFormatIdsForFormatOption` helpers in `@adcp/sdk/v2/projection`.
|
|
330
|
-
*
|
|
331
|
-
* `packageRefsForFormatOptions` throws `FormatOptionRefsLookupError`
|
|
332
|
-
* with a normalized `.code` in `{ 'unknown_format_option_id' |
|
|
333
|
-
* 'format_option_refs_not_published' | 'empty_input' | 'invalid_product' }`
|
|
334
|
-
* — branch on `.code` to fall back to the `legacy*` helpers when the
|
|
335
|
-
* product is V1-shape only. See the helper JSDoc for the full
|
|
336
|
-
* recovery example.
|
|
325
|
+
* Existing applications that still hold old named-format payloads must opt
|
|
326
|
+
* into `createMediaBuyLegacy()` explicitly.
|
|
337
327
|
*/
|
|
338
|
-
createMediaBuy(params: MutatingRequestInput<
|
|
328
|
+
createMediaBuy(params: MutatingRequestInput<CanonicalCreateMediaBuyRequest>, inputHandler?: InputHandler, options?: CreativeDeliveryTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<CreateMediaBuyResponse>>>;
|
|
329
|
+
/** @deprecated Use `createMediaBuy`; this explicit compatibility surface accepts legacy creative `format_id`. */
|
|
330
|
+
createMediaBuyLegacy(params: MutatingRequestInput<CreateMediaBuyRequest>, inputHandler?: InputHandler, options?: CreativeDeliveryTaskOptions): Promise<TaskResult<CreateMediaBuyResponse>>;
|
|
339
331
|
/**
|
|
340
332
|
* Update an existing media buy.
|
|
341
333
|
*
|
|
@@ -345,8 +337,12 @@ export declare class AgentClient {
|
|
|
345
337
|
* request. Build the package patch with `inlineCreativesForPackages()` and
|
|
346
338
|
* preflight it with `preflightUpdateMediaBuy(currentBuy, patch)` so
|
|
347
339
|
* `available_actions[]` allows `replace_creative` before dispatch.
|
|
340
|
+
* Use `format_kind` and `format_option_ref` for every creative in the patch;
|
|
341
|
+
* the SDK handles any negotiated compatibility conversion.
|
|
348
342
|
*/
|
|
349
|
-
updateMediaBuy(params: MutatingRequestInput<
|
|
343
|
+
updateMediaBuy(params: MutatingRequestInput<CanonicalUpdateMediaBuyRequest>, inputHandler?: InputHandler, options?: CreativeDeliveryTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<UpdateMediaBuyResponse>>>;
|
|
344
|
+
/** @deprecated Use `updateMediaBuy`; this explicit compatibility surface accepts legacy creative `format_id`. */
|
|
345
|
+
updateMediaBuyLegacy(params: MutatingRequestInput<UpdateMediaBuyRequest>, inputHandler?: InputHandler, options?: CreativeDeliveryTaskOptions): Promise<TaskResult<UpdateMediaBuyResponse>>;
|
|
350
346
|
/**
|
|
351
347
|
* Sync creative assets into the seller's reusable creative library.
|
|
352
348
|
*
|
|
@@ -359,20 +355,35 @@ export declare class AgentClient {
|
|
|
359
355
|
* send a separate `create_media_buy` or `update_media_buy` request with its
|
|
360
356
|
* own idempotency key. If neither capability is advertised, creative upload
|
|
361
357
|
* is not available through this SDK helper surface.
|
|
358
|
+
*
|
|
359
|
+
* A sync request does not carry product declarations. When compatibility
|
|
360
|
+
* translation needs seller selection metadata, pass
|
|
361
|
+
* `options.creativeFormatProjection.selectorContainers` with the routed
|
|
362
|
+
* package/product selectors. Assignments scope each creative to its package.
|
|
362
363
|
*/
|
|
363
|
-
syncCreatives(params: MutatingRequestInput<
|
|
364
|
+
syncCreatives(params: MutatingRequestInput<CanonicalSyncCreativesRequest>, inputHandler?: InputHandler, options?: SyncCreativesTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<SyncCreativesResponse>>>;
|
|
365
|
+
/** @deprecated Use `syncCreatives`; this explicit compatibility surface accepts legacy creative `format_id`. */
|
|
366
|
+
syncCreativesLegacy(params: MutatingRequestInput<SyncCreativesRequest>, inputHandler?: InputHandler, options?: SyncCreativesTaskOptions): Promise<TaskResult<SyncCreativesResponse>>;
|
|
364
367
|
/**
|
|
365
368
|
* List creative assets
|
|
366
369
|
*/
|
|
367
|
-
listCreatives(params:
|
|
370
|
+
listCreatives(params: CanonicalListCreativesRequest, inputHandler?: InputHandler, options?: CanonicalProjectionTaskOptions): Promise<TaskResult<CanonicalListCreativesResponse>>;
|
|
371
|
+
/**
|
|
372
|
+
* Return the unprojected `list_creatives` wire response.
|
|
373
|
+
*
|
|
374
|
+
* @deprecated Compatibility-only escape hatch for migration and protocol tooling.
|
|
375
|
+
*/
|
|
376
|
+
listCreativesLegacy(params: ListCreativesRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<ListCreativesResponse>>;
|
|
368
377
|
/**
|
|
369
378
|
* Get media buy status, creative approvals, and optional delivery snapshots
|
|
370
379
|
*/
|
|
371
|
-
getMediaBuys(params: GetMediaBuysRequest, inputHandler?: InputHandler, options?:
|
|
380
|
+
getMediaBuys(params: GetMediaBuysRequest, inputHandler?: InputHandler, options?: CanonicalReadTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<GetMediaBuysResponse>>>;
|
|
372
381
|
/**
|
|
373
382
|
* Get media buy delivery information
|
|
374
383
|
*/
|
|
375
|
-
getMediaBuyDelivery(params: GetMediaBuyDeliveryRequest, inputHandler?: InputHandler, options?:
|
|
384
|
+
getMediaBuyDelivery(params: GetMediaBuyDeliveryRequest, inputHandler?: InputHandler, options?: CanonicalReadTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<GetMediaBuyDeliveryResponse>>>;
|
|
385
|
+
/** Retrieve canonical creative-level and variant-level delivery metrics. */
|
|
386
|
+
getCreativeDelivery(params: GetCreativeDeliveryRequest, inputHandler?: InputHandler, options?: CanonicalProjectionTaskOptions): Promise<TaskResult<CanonicalCreativeResponse<GetCreativeDeliveryResponse>>>;
|
|
376
387
|
/**
|
|
377
388
|
* Provide performance feedback
|
|
378
389
|
*/
|
|
@@ -414,14 +425,10 @@ export declare class AgentClient {
|
|
|
414
425
|
* @deprecated Use `requireSupportedMajor()` instead.
|
|
415
426
|
*/
|
|
416
427
|
requireV3(taskType?: string): Promise<void>;
|
|
417
|
-
/**
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
/**
|
|
422
|
-
* Build a creative from format and brand context
|
|
423
|
-
*/
|
|
424
|
-
buildCreative(params: MutatingRequestInput<BuildCreativeRequest>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<BuildCreativeResponse>>;
|
|
428
|
+
/** @deprecated Migration-only access to legacy `format_id`-based creative preview. */
|
|
429
|
+
previewCreativeLegacy(params: PreviewCreativeRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<PreviewCreativeResponse>>;
|
|
430
|
+
/** @deprecated Migration-only access to legacy `target_format_id`-based creative building. */
|
|
431
|
+
buildCreativeLegacy(params: MutatingRequestInput<BuildCreativeRequest>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<BuildCreativeResponse>>;
|
|
425
432
|
/**
|
|
426
433
|
* List accounts
|
|
427
434
|
*/
|
|
@@ -457,19 +464,19 @@ export declare class AgentClient {
|
|
|
457
464
|
/**
|
|
458
465
|
* List content standards
|
|
459
466
|
*/
|
|
460
|
-
|
|
467
|
+
listContentStandardsLegacy(params: ListContentStandardsRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<ListContentStandardsResponse>>;
|
|
461
468
|
/**
|
|
462
469
|
* Get content standards
|
|
463
470
|
*/
|
|
464
|
-
|
|
471
|
+
getContentStandardsLegacy(params: GetContentStandardsRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<GetContentStandardsResponse>>;
|
|
465
472
|
/**
|
|
466
473
|
* Calibrate content against standards
|
|
467
474
|
*/
|
|
468
|
-
|
|
475
|
+
calibrateContentLegacy(params: MutatingRequestInput<CalibrateContentRequest>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<CalibrateContentResponse>>;
|
|
469
476
|
/**
|
|
470
477
|
* Validate content delivery
|
|
471
478
|
*/
|
|
472
|
-
|
|
479
|
+
validateContentDeliveryLegacy(params: ValidateContentDeliveryRequest, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<ValidateContentDeliveryResponse>>;
|
|
473
480
|
/**
|
|
474
481
|
* Get an SI offering
|
|
475
482
|
*/
|
|
@@ -618,17 +625,20 @@ export declare class AgentClient {
|
|
|
618
625
|
* ```typescript
|
|
619
626
|
* // ✅ TYPE-SAFE: Automatic response type inference
|
|
620
627
|
* const result = await agent.executeTask('get_products', params);
|
|
621
|
-
* // result is TaskResult<
|
|
628
|
+
* // result is TaskResult<CanonicalGetProductsResponse> - no casting needed!
|
|
622
629
|
*
|
|
623
630
|
* // ✅ CUSTOM TYPES: For non-standard tasks
|
|
624
|
-
* const customResult = await agent.
|
|
631
|
+
* const customResult = await agent.executeCustomTask<MyCustomResponse>('custom_task', params);
|
|
625
632
|
* ```
|
|
626
633
|
*/
|
|
627
|
-
executeTask<K extends AdcpTaskName>(taskName: K, params:
|
|
634
|
+
executeTask<K extends AdcpTaskName>(taskName: K, params: TaskRequestFor<K>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<TaskResponseTypeMap[K]>>;
|
|
635
|
+
/** Execute an extension task that is not part of the standard AdCP task set. */
|
|
636
|
+
executeCustomTask<T = unknown>(taskName: string, params: Record<string, unknown>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<T>>;
|
|
628
637
|
/**
|
|
629
|
-
*
|
|
638
|
+
* Explicit raw-task compatibility escape hatch for conformance and migration tooling.
|
|
639
|
+
* @deprecated Application code should use typed primary methods or `executeTask()`.
|
|
630
640
|
*/
|
|
631
|
-
|
|
641
|
+
executeTaskLegacy<T = unknown>(taskName: string, params: Record<string, unknown>, inputHandler?: InputHandler, options?: TaskOptions): Promise<TaskResult<T>>;
|
|
632
642
|
/**
|
|
633
643
|
* List all tasks for this agent
|
|
634
644
|
*/
|