@adcp/sdk 5.25.1 → 6.1.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 +45 -7
- package/dist/lib/compliance-fixtures/index.d.ts +1 -1
- package/dist/lib/compliance-fixtures/index.js +1 -1
- package/dist/lib/core/AgentClient.d.ts.map +1 -1
- package/dist/lib/core/SingleAgentClient.d.ts.map +1 -1
- package/dist/lib/core/SingleAgentClient.js +27 -0
- package/dist/lib/core/SingleAgentClient.js.map +1 -1
- package/dist/lib/core/TaskExecutor.d.ts +21 -0
- package/dist/lib/core/TaskExecutor.d.ts.map +1 -1
- package/dist/lib/core/TaskExecutor.js +25 -2
- package/dist/lib/core/TaskExecutor.js.map +1 -1
- package/dist/lib/index.d.ts +1 -1
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/index.js +7 -8
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/schemas/index.d.ts +1 -1
- package/dist/lib/schemas/index.js +1 -1
- package/dist/lib/schemas-data/v2.5/_provenance.json +8 -0
- package/dist/lib/schemas-data/v2.5/adagents.json +494 -0
- package/dist/lib/schemas-data/v2.5/core/activation-key.json +50 -0
- package/dist/lib/schemas-data/v2.5/core/assets/audio-asset.json +32 -0
- package/dist/lib/schemas-data/v2.5/core/assets/css-asset.json +21 -0
- package/dist/lib/schemas-data/v2.5/core/assets/daast-asset.json +87 -0
- package/dist/lib/schemas-data/v2.5/core/assets/html-asset.json +21 -0
- package/dist/lib/schemas-data/v2.5/core/assets/image-asset.json +38 -0
- package/dist/lib/schemas-data/v2.5/core/assets/javascript-asset.json +21 -0
- package/dist/lib/schemas-data/v2.5/core/assets/markdown-asset.json +31 -0
- package/dist/lib/schemas-data/v2.5/core/assets/text-asset.json +21 -0
- package/dist/lib/schemas-data/v2.5/core/assets/url-asset.json +26 -0
- package/dist/lib/schemas-data/v2.5/core/assets/vast-asset.json +87 -0
- package/dist/lib/schemas-data/v2.5/core/assets/video-asset.json +44 -0
- package/dist/lib/schemas-data/v2.5/core/assets/webhook-asset.json +71 -0
- package/dist/lib/schemas-data/v2.5/core/async-response-data.json +88 -0
- package/dist/lib/schemas-data/v2.5/core/brand-manifest-ref.json +33 -0
- package/dist/lib/schemas-data/v2.5/core/brand-manifest.json +409 -0
- package/dist/lib/schemas-data/v2.5/core/context.json +8 -0
- package/dist/lib/schemas-data/v2.5/core/creative-asset.json +125 -0
- package/dist/lib/schemas-data/v2.5/core/creative-assignment.json +31 -0
- package/dist/lib/schemas-data/v2.5/core/creative-filters.json +111 -0
- package/dist/lib/schemas-data/v2.5/core/creative-manifest.json +72 -0
- package/dist/lib/schemas-data/v2.5/core/creative-policy.json +27 -0
- package/dist/lib/schemas-data/v2.5/core/delivery-metrics.json +171 -0
- package/dist/lib/schemas-data/v2.5/core/deployment.json +93 -0
- package/dist/lib/schemas-data/v2.5/core/destination.json +53 -0
- package/dist/lib/schemas-data/v2.5/core/error.json +40 -0
- package/dist/lib/schemas-data/v2.5/core/ext.json +8 -0
- package/dist/lib/schemas-data/v2.5/core/format-id.json +47 -0
- package/dist/lib/schemas-data/v2.5/core/format.json +324 -0
- package/dist/lib/schemas-data/v2.5/core/frequency-cap.json +18 -0
- package/dist/lib/schemas-data/v2.5/core/mcp-webhook-payload.json +152 -0
- package/dist/lib/schemas-data/v2.5/core/measurement.json +48 -0
- package/dist/lib/schemas-data/v2.5/core/media-buy.json +62 -0
- package/dist/lib/schemas-data/v2.5/core/package.json +72 -0
- package/dist/lib/schemas-data/v2.5/core/performance-feedback.json +90 -0
- package/dist/lib/schemas-data/v2.5/core/placement.json +34 -0
- package/dist/lib/schemas-data/v2.5/core/pricing-option.json +35 -0
- package/dist/lib/schemas-data/v2.5/core/product-filters.json +102 -0
- package/dist/lib/schemas-data/v2.5/core/product.json +153 -0
- package/dist/lib/schemas-data/v2.5/core/promoted-offerings.json +115 -0
- package/dist/lib/schemas-data/v2.5/core/promoted-products.json +67 -0
- package/dist/lib/schemas-data/v2.5/core/property-id.json +14 -0
- package/dist/lib/schemas-data/v2.5/core/property-tag.json +16 -0
- package/dist/lib/schemas-data/v2.5/core/property.json +62 -0
- package/dist/lib/schemas-data/v2.5/core/protocol-envelope.json +146 -0
- package/dist/lib/schemas-data/v2.5/core/publisher-property-selector.json +92 -0
- package/dist/lib/schemas-data/v2.5/core/push-notification-config.json +48 -0
- package/dist/lib/schemas-data/v2.5/core/reporting-capabilities.json +71 -0
- package/dist/lib/schemas-data/v2.5/core/response.json +24 -0
- package/dist/lib/schemas-data/v2.5/core/signal-filters.json +35 -0
- package/dist/lib/schemas-data/v2.5/core/start-timing.json +18 -0
- package/dist/lib/schemas-data/v2.5/core/sub-asset.json +79 -0
- package/dist/lib/schemas-data/v2.5/core/targeting.json +50 -0
- package/dist/lib/schemas-data/v2.5/core/tasks-get-request.json +43 -0
- package/dist/lib/schemas-data/v2.5/core/tasks-get-response.json +166 -0
- package/dist/lib/schemas-data/v2.5/core/tasks-list-request.json +192 -0
- package/dist/lib/schemas-data/v2.5/core/tasks-list-response.json +183 -0
- package/dist/lib/schemas-data/v2.5/creative/asset-types/index.json +101 -0
- package/dist/lib/schemas-data/v2.5/creative/list-creative-formats-request.json +73 -0
- package/dist/lib/schemas-data/v2.5/creative/list-creative-formats-response.json +61 -0
- package/dist/lib/schemas-data/v2.5/creative/preview-creative-request.json +164 -0
- package/dist/lib/schemas-data/v2.5/creative/preview-creative-response.json +245 -0
- package/dist/lib/schemas-data/v2.5/creative/preview-render.json +225 -0
- package/dist/lib/schemas-data/v2.5/enums/adcp-domain.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/asset-content-type.json +22 -0
- package/dist/lib/schemas-data/v2.5/enums/auth-scheme.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/available-metric.json +18 -0
- package/dist/lib/schemas-data/v2.5/enums/channels.json +18 -0
- package/dist/lib/schemas-data/v2.5/enums/co-branding-requirement.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/creative-action.json +14 -0
- package/dist/lib/schemas-data/v2.5/enums/creative-agent-capability.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/creative-sort-field.json +15 -0
- package/dist/lib/schemas-data/v2.5/enums/creative-status.json +19 -0
- package/dist/lib/schemas-data/v2.5/enums/daast-tracking-event.json +20 -0
- package/dist/lib/schemas-data/v2.5/enums/daast-version.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/delivery-type.json +15 -0
- package/dist/lib/schemas-data/v2.5/enums/dimension-unit.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/feed-format.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/feedback-source.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/format-category.json +16 -0
- package/dist/lib/schemas-data/v2.5/enums/format-id-parameter.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/frequency-cap-scope.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/history-entry-type.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/http-method.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/identifier-types.json +34 -0
- package/dist/lib/schemas-data/v2.5/enums/javascript-module-type.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/landing-page-requirement.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/markdown-flavor.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/media-buy-status.json +19 -0
- package/dist/lib/schemas-data/v2.5/enums/metric-type.json +17 -0
- package/dist/lib/schemas-data/v2.5/enums/notification-type.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/pacing.json +17 -0
- package/dist/lib/schemas-data/v2.5/enums/preview-output-format.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/pricing-model.json +25 -0
- package/dist/lib/schemas-data/v2.5/enums/property-type.json +16 -0
- package/dist/lib/schemas-data/v2.5/enums/publisher-identifier-types.json +19 -0
- package/dist/lib/schemas-data/v2.5/enums/reporting-frequency.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/signal-catalog-type.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/sort-direction.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/standard-format-ids.json +103 -0
- package/dist/lib/schemas-data/v2.5/enums/task-status.json +29 -0
- package/dist/lib/schemas-data/v2.5/enums/task-type.json +27 -0
- package/dist/lib/schemas-data/v2.5/enums/update-frequency.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/url-asset-type.json +12 -0
- package/dist/lib/schemas-data/v2.5/enums/validation-mode.json +11 -0
- package/dist/lib/schemas-data/v2.5/enums/vast-tracking-event.json +25 -0
- package/dist/lib/schemas-data/v2.5/enums/vast-version.json +14 -0
- package/dist/lib/schemas-data/v2.5/enums/webhook-response-type.json +13 -0
- package/dist/lib/schemas-data/v2.5/enums/webhook-security-method.json +12 -0
- package/dist/lib/schemas-data/v2.5/index.json +604 -0
- package/dist/lib/schemas-data/v2.5/media-buy/build-creative-request.json +31 -0
- package/dist/lib/schemas-data/v2.5/media-buy/build-creative-response.json +65 -0
- package/dist/lib/schemas-data/v2.5/media-buy/create-media-buy-async-response-input-required.json +31 -0
- package/dist/lib/schemas-data/v2.5/media-buy/create-media-buy-async-response-submitted.json +16 -0
- package/dist/lib/schemas-data/v2.5/media-buy/create-media-buy-async-response-working.json +36 -0
- package/dist/lib/schemas-data/v2.5/media-buy/create-media-buy-request.json +126 -0
- package/dist/lib/schemas-data/v2.5/media-buy/create-media-buy-response.json +97 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-media-buy-delivery-request.json +54 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-media-buy-delivery-response.json +285 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-products-async-response-input-required.json +38 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-products-async-response-submitted.json +21 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-products-async-response-working.json +34 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-products-request.json +28 -0
- package/dist/lib/schemas-data/v2.5/media-buy/get-products-response.json +33 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-authorized-properties-request.json +26 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-authorized-properties-response.json +70 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-creative-formats-request.json +58 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-creative-formats-response.json +61 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-creatives-request.json +137 -0
- package/dist/lib/schemas-data/v2.5/media-buy/list-creatives-response.json +437 -0
- package/dist/lib/schemas-data/v2.5/media-buy/package-request.json +80 -0
- package/dist/lib/schemas-data/v2.5/media-buy/provide-performance-feedback-request.json +88 -0
- package/dist/lib/schemas-data/v2.5/media-buy/provide-performance-feedback-response.json +66 -0
- package/dist/lib/schemas-data/v2.5/media-buy/sync-creatives-async-response-input-required.json +25 -0
- package/dist/lib/schemas-data/v2.5/media-buy/sync-creatives-async-response-submitted.json +16 -0
- package/dist/lib/schemas-data/v2.5/media-buy/sync-creatives-async-response-working.json +46 -0
- package/dist/lib/schemas-data/v2.5/media-buy/sync-creatives-request.json +178 -0
- package/dist/lib/schemas-data/v2.5/media-buy/sync-creatives-response.json +149 -0
- package/dist/lib/schemas-data/v2.5/media-buy/update-media-buy-async-response-input-required.json +24 -0
- package/dist/lib/schemas-data/v2.5/media-buy/update-media-buy-async-response-submitted.json +16 -0
- package/dist/lib/schemas-data/v2.5/media-buy/update-media-buy-async-response-working.json +36 -0
- package/dist/lib/schemas-data/v2.5/media-buy/update-media-buy-request.json +129 -0
- package/dist/lib/schemas-data/v2.5/media-buy/update-media-buy-response.json +99 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpc-option.json +52 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpcv-option.json +52 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpm-auction-option.json +81 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpm-fixed-option.json +52 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpp-option.json +73 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/cpv-option.json +88 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/flat-rate-option.json +93 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/vcpm-auction-option.json +81 -0
- package/dist/lib/schemas-data/v2.5/pricing-options/vcpm-fixed-option.json +52 -0
- package/dist/lib/schemas-data/v2.5/protocols/adcp-extension.json +33 -0
- package/dist/lib/schemas-data/v2.5/signals/activate-signal-request.json +32 -0
- package/dist/lib/schemas-data/v2.5/signals/activate-signal-response.json +68 -0
- package/dist/lib/schemas-data/v2.5/signals/get-signals-request.json +59 -0
- package/dist/lib/schemas-data/v2.5/signals/get-signals-response.json +100 -0
- package/dist/lib/server/create-adcp-server.d.ts +129 -11
- package/dist/lib/server/create-adcp-server.d.ts.map +1 -1
- package/dist/lib/server/create-adcp-server.js +127 -2
- package/dist/lib/server/create-adcp-server.js.map +1 -1
- package/dist/lib/server/ctx-metadata/backends/memory.d.ts +27 -0
- package/dist/lib/server/ctx-metadata/backends/memory.d.ts.map +1 -0
- package/dist/lib/server/ctx-metadata/backends/memory.js +72 -0
- package/dist/lib/server/ctx-metadata/backends/memory.js.map +1 -0
- package/dist/lib/server/ctx-metadata/backends/pg.d.ts +62 -0
- package/dist/lib/server/ctx-metadata/backends/pg.d.ts.map +1 -0
- package/dist/lib/server/ctx-metadata/backends/pg.js +145 -0
- package/dist/lib/server/ctx-metadata/backends/pg.js.map +1 -0
- package/dist/lib/server/ctx-metadata/index.d.ts +15 -0
- package/dist/lib/server/ctx-metadata/index.d.ts.map +1 -0
- package/dist/lib/server/ctx-metadata/index.js +28 -0
- package/dist/lib/server/ctx-metadata/index.js.map +1 -0
- package/dist/lib/server/ctx-metadata/store.d.ts +177 -0
- package/dist/lib/server/ctx-metadata/store.d.ts.map +1 -0
- package/dist/lib/server/ctx-metadata/store.js +327 -0
- package/dist/lib/server/ctx-metadata/store.js.map +1 -0
- package/dist/lib/server/ctx-metadata/wire-shape.d.ts +55 -0
- package/dist/lib/server/ctx-metadata/wire-shape.d.ts.map +1 -0
- package/dist/lib/server/ctx-metadata/wire-shape.js +121 -0
- package/dist/lib/server/ctx-metadata/wire-shape.js.map +1 -0
- package/dist/lib/server/decisioning/account.d.ts +309 -0
- package/dist/lib/server/decisioning/account.d.ts.map +1 -0
- package/dist/lib/server/decisioning/account.js +102 -0
- package/dist/lib/server/decisioning/account.js.map +1 -0
- package/dist/lib/server/decisioning/admin-router.d.ts +75 -0
- package/dist/lib/server/decisioning/admin-router.d.ts.map +1 -0
- package/dist/lib/server/decisioning/admin-router.js +120 -0
- package/dist/lib/server/decisioning/admin-router.js.map +1 -0
- package/dist/lib/server/decisioning/assembly-helpers.d.ts +204 -0
- package/dist/lib/server/decisioning/assembly-helpers.d.ts.map +1 -0
- package/dist/lib/server/decisioning/assembly-helpers.js +173 -0
- package/dist/lib/server/decisioning/assembly-helpers.js.map +1 -0
- package/dist/lib/server/decisioning/async-outcome.d.ts +154 -0
- package/dist/lib/server/decisioning/async-outcome.d.ts.map +1 -0
- package/dist/lib/server/decisioning/async-outcome.js +239 -0
- package/dist/lib/server/decisioning/async-outcome.js.map +1 -0
- package/dist/lib/server/decisioning/capabilities.d.ts +251 -0
- package/dist/lib/server/decisioning/capabilities.d.ts.map +1 -0
- package/dist/lib/server/decisioning/capabilities.js +16 -0
- package/dist/lib/server/decisioning/capabilities.js.map +1 -0
- package/dist/lib/server/decisioning/context.d.ts +212 -0
- package/dist/lib/server/decisioning/context.d.ts.map +1 -0
- package/dist/lib/server/decisioning/context.js +26 -0
- package/dist/lib/server/decisioning/context.js.map +1 -0
- package/dist/lib/server/decisioning/errors-typed.d.ts +104 -0
- package/dist/lib/server/decisioning/errors-typed.d.ts.map +1 -0
- package/dist/lib/server/decisioning/errors-typed.js +304 -0
- package/dist/lib/server/decisioning/errors-typed.js.map +1 -0
- package/dist/lib/server/decisioning/helpers.d.ts +131 -0
- package/dist/lib/server/decisioning/helpers.d.ts.map +1 -0
- package/dist/lib/server/decisioning/helpers.js +134 -0
- package/dist/lib/server/decisioning/helpers.js.map +1 -0
- package/dist/lib/server/decisioning/index.d.ts +46 -0
- package/dist/lib/server/decisioning/index.d.ts.map +1 -0
- package/dist/lib/server/decisioning/index.js +120 -0
- package/dist/lib/server/decisioning/index.js.map +1 -0
- package/dist/lib/server/decisioning/list-helpers.d.ts +53 -0
- package/dist/lib/server/decisioning/list-helpers.d.ts.map +1 -0
- package/dist/lib/server/decisioning/list-helpers.js +96 -0
- package/dist/lib/server/decisioning/list-helpers.js.map +1 -0
- package/dist/lib/server/decisioning/manifest-helpers.d.ts +56 -0
- package/dist/lib/server/decisioning/manifest-helpers.d.ts.map +1 -0
- package/dist/lib/server/decisioning/manifest-helpers.js +78 -0
- package/dist/lib/server/decisioning/manifest-helpers.js.map +1 -0
- package/dist/lib/server/decisioning/pagination.d.ts +21 -0
- package/dist/lib/server/decisioning/pagination.d.ts.map +1 -0
- package/dist/lib/server/decisioning/pagination.js +12 -0
- package/dist/lib/server/decisioning/pagination.js.map +1 -0
- package/dist/lib/server/decisioning/platform.d.ts +188 -0
- package/dist/lib/server/decisioning/platform.d.ts.map +1 -0
- package/dist/lib/server/decisioning/platform.js +19 -0
- package/dist/lib/server/decisioning/platform.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/from-platform.d.ts +510 -0
- package/dist/lib/server/decisioning/runtime/from-platform.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/from-platform.js +2196 -0
- package/dist/lib/server/decisioning/runtime/from-platform.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/postgres-task-registry.d.ts +114 -0
- package/dist/lib/server/decisioning/runtime/postgres-task-registry.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/postgres-task-registry.js +247 -0
- package/dist/lib/server/decisioning/runtime/postgres-task-registry.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/protocol-for-tool.d.ts +32 -0
- package/dist/lib/server/decisioning/runtime/protocol-for-tool.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/protocol-for-tool.js +127 -0
- package/dist/lib/server/decisioning/runtime/protocol-for-tool.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/task-registry.d.ts +105 -0
- package/dist/lib/server/decisioning/runtime/task-registry.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/task-registry.js +96 -0
- package/dist/lib/server/decisioning/runtime/task-registry.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/to-context.d.ts +54 -0
- package/dist/lib/server/decisioning/runtime/to-context.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/to-context.js +166 -0
- package/dist/lib/server/decisioning/runtime/to-context.js.map +1 -0
- package/dist/lib/server/decisioning/runtime/validate-platform.d.ts +20 -0
- package/dist/lib/server/decisioning/runtime/validate-platform.d.ts.map +1 -0
- package/dist/lib/server/decisioning/runtime/validate-platform.js +93 -0
- package/dist/lib/server/decisioning/runtime/validate-platform.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/audiences.d.ts +72 -0
- package/dist/lib/server/decisioning/specialisms/audiences.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/audiences.js +15 -0
- package/dist/lib/server/decisioning/specialisms/audiences.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts +92 -0
- package/dist/lib/server/decisioning/specialisms/brand-rights.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/brand-rights.js +28 -0
- package/dist/lib/server/decisioning/specialisms/brand-rights.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/campaign-governance.d.ts +67 -0
- package/dist/lib/server/decisioning/specialisms/campaign-governance.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/campaign-governance.js +31 -0
- package/dist/lib/server/decisioning/specialisms/campaign-governance.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/content-standards.d.ts +78 -0
- package/dist/lib/server/decisioning/specialisms/content-standards.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/content-standards.js +35 -0
- package/dist/lib/server/decisioning/specialisms/content-standards.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts +81 -0
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.js +28 -0
- package/dist/lib/server/decisioning/specialisms/creative-ad-server.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/creative.d.ts +144 -0
- package/dist/lib/server/decisioning/specialisms/creative.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/creative.js +19 -0
- package/dist/lib/server/decisioning/specialisms/creative.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/lists.d.ts +61 -0
- package/dist/lib/server/decisioning/specialisms/lists.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/lists.js +30 -0
- package/dist/lib/server/decisioning/specialisms/lists.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/sales.d.ts +163 -0
- package/dist/lib/server/decisioning/specialisms/sales.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/sales.js +64 -0
- package/dist/lib/server/decisioning/specialisms/sales.js.map +1 -0
- package/dist/lib/server/decisioning/specialisms/signals.d.ts +64 -0
- package/dist/lib/server/decisioning/specialisms/signals.d.ts.map +1 -0
- package/dist/lib/server/decisioning/specialisms/signals.js +28 -0
- package/dist/lib/server/decisioning/specialisms/signals.js.map +1 -0
- package/dist/lib/server/decisioning/start-time.d.ts +76 -0
- package/dist/lib/server/decisioning/start-time.d.ts.map +1 -0
- package/dist/lib/server/decisioning/start-time.js +81 -0
- package/dist/lib/server/decisioning/start-time.js.map +1 -0
- package/dist/lib/server/decisioning/status-changes.d.ts +165 -0
- package/dist/lib/server/decisioning/status-changes.d.ts.map +1 -0
- package/dist/lib/server/decisioning/status-changes.js +131 -0
- package/dist/lib/server/decisioning/status-changes.js.map +1 -0
- package/dist/lib/server/decisioning/status-mappers.d.ts +46 -0
- package/dist/lib/server/decisioning/status-mappers.d.ts.map +1 -0
- package/dist/lib/server/decisioning/status-mappers.js +46 -0
- package/dist/lib/server/decisioning/status-mappers.js.map +1 -0
- package/dist/lib/server/decisioning/tenant-registry.d.ts +289 -0
- package/dist/lib/server/decisioning/tenant-registry.d.ts.map +1 -0
- package/dist/lib/server/decisioning/tenant-registry.js +503 -0
- package/dist/lib/server/decisioning/tenant-registry.js.map +1 -0
- package/dist/lib/server/express-adapter.d.ts +1 -1
- package/dist/lib/server/express-adapter.js +1 -1
- package/dist/lib/server/governance.d.ts +1 -1
- package/dist/lib/server/governance.js +1 -1
- package/dist/lib/server/idempotency/store.d.ts +1 -1
- package/dist/lib/server/idempotency/store.js +1 -1
- package/dist/lib/server/index.d.ts +9 -2
- package/dist/lib/server/index.d.ts.map +1 -1
- package/dist/lib/server/index.js +79 -4
- package/dist/lib/server/index.js.map +1 -1
- package/dist/lib/server/legacy/v5/index.d.ts +38 -0
- package/dist/lib/server/legacy/v5/index.d.ts.map +1 -0
- package/dist/lib/server/legacy/v5/index.js +60 -0
- package/dist/lib/server/legacy/v5/index.js.map +1 -0
- package/dist/lib/server/normalize-errors.d.ts +88 -0
- package/dist/lib/server/normalize-errors.d.ts.map +1 -0
- package/dist/lib/server/normalize-errors.js +146 -0
- package/dist/lib/server/normalize-errors.js.map +1 -0
- package/dist/lib/server/pick-safe-details.d.ts +90 -0
- package/dist/lib/server/pick-safe-details.d.ts.map +1 -0
- package/dist/lib/server/pick-safe-details.js +148 -0
- package/dist/lib/server/pick-safe-details.js.map +1 -0
- package/dist/lib/server/postgres-state-store.d.ts +1 -1
- package/dist/lib/server/postgres-state-store.js +1 -1
- package/dist/lib/server/responses.d.ts +38 -0
- package/dist/lib/server/responses.d.ts.map +1 -1
- package/dist/lib/server/responses.js +38 -0
- package/dist/lib/server/responses.js.map +1 -1
- package/dist/lib/server/state-store.d.ts +1 -1
- package/dist/lib/server/state-store.js +1 -1
- package/dist/lib/server/test-controller.d.ts +10 -3
- package/dist/lib/server/test-controller.d.ts.map +1 -1
- package/dist/lib/server/test-controller.js +10 -3
- package/dist/lib/server/test-controller.js.map +1 -1
- package/dist/lib/testing/comply-controller.d.ts +47 -1
- package/dist/lib/testing/comply-controller.d.ts.map +1 -1
- package/dist/lib/testing/comply-controller.js +11 -4
- package/dist/lib/testing/comply-controller.js.map +1 -1
- package/dist/lib/testing/index.d.ts +1 -1
- package/dist/lib/testing/index.d.ts.map +1 -1
- package/dist/lib/testing/index.js.map +1 -1
- package/dist/lib/testing/personas/index.d.ts +143 -0
- package/dist/lib/testing/personas/index.d.ts.map +1 -0
- package/dist/lib/testing/personas/index.js +190 -0
- package/dist/lib/testing/personas/index.js.map +1 -0
- package/dist/lib/testing/storyboard/index.d.ts +1 -1
- package/dist/lib/testing/storyboard/index.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/index.js +3 -2
- package/dist/lib/testing/storyboard/index.js.map +1 -1
- package/dist/lib/testing/storyboard/runner.d.ts +13 -0
- package/dist/lib/testing/storyboard/runner.d.ts.map +1 -1
- package/dist/lib/testing/storyboard/runner.js +260 -7
- package/dist/lib/testing/storyboard/runner.js.map +1 -1
- package/dist/lib/types/asset-instances.d.ts +1 -0
- package/dist/lib/types/asset-instances.d.ts.map +1 -1
- package/dist/lib/types/core.generated.d.ts +203 -98
- package/dist/lib/types/core.generated.d.ts.map +1 -1
- package/dist/lib/types/core.generated.js +1 -1
- package/dist/lib/types/index.d.ts +1 -0
- package/dist/lib/types/index.d.ts.map +1 -1
- package/dist/lib/types/index.js.map +1 -1
- package/dist/lib/types/schemas.generated.d.ts +599 -159
- package/dist/lib/types/schemas.generated.d.ts.map +1 -1
- package/dist/lib/types/schemas.generated.js +175 -94
- package/dist/lib/types/schemas.generated.js.map +1 -1
- package/dist/lib/types/tools.generated.d.ts +315 -46
- package/dist/lib/types/tools.generated.d.ts.map +1 -1
- package/dist/lib/utils/capabilities.d.ts +1 -1
- package/dist/lib/utils/capabilities.d.ts.map +1 -1
- package/dist/lib/utils/capabilities.js +6 -0
- package/dist/lib/utils/capabilities.js.map +1 -1
- package/dist/lib/utils/creative-adapter.d.ts +32 -2
- package/dist/lib/utils/creative-adapter.d.ts.map +1 -1
- package/dist/lib/utils/creative-adapter.js +42 -6
- package/dist/lib/utils/creative-adapter.js.map +1 -1
- package/dist/lib/validation/schema-loader.d.ts.map +1 -1
- package/dist/lib/validation/schema-loader.js +20 -2
- package/dist/lib/validation/schema-loader.js.map +1 -1
- package/dist/lib/validation/schema-validator.d.ts +13 -0
- package/dist/lib/validation/schema-validator.d.ts.map +1 -1
- package/dist/lib/validation/schema-validator.js +240 -3
- package/dist/lib/validation/schema-validator.js.map +1 -1
- 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/docs/guides/BUILD-AN-AGENT.md +30 -5
- package/docs/llms.txt +28 -17
- package/examples/README.md +3 -1
- package/examples/decisioning-platform-broadcast-tv.ts +300 -0
- package/examples/decisioning-platform-identity-graph.ts +214 -0
- package/examples/decisioning-platform-mock-seller.ts +332 -0
- package/examples/decisioning-platform-multi-tenant.ts +128 -0
- package/examples/decisioning-platform-programmatic.ts +254 -0
- package/examples/signals-agent.ts +1 -1
- package/package.json +18 -5
- package/skills/build-brand-rights-agent/SKILL.md +10 -3
- package/skills/build-creative-agent/SKILL.md +94 -64
- package/skills/build-decisioning-creative-template/SKILL.md +554 -0
- package/skills/build-decisioning-platform/SKILL.md +304 -0
- package/skills/build-decisioning-platform/advanced/BRAND-RIGHTS.md +25 -0
- package/skills/build-decisioning-platform/advanced/COMPLIANCE.md +23 -0
- package/skills/build-decisioning-platform/advanced/GOVERNANCE.md +24 -0
- package/skills/build-decisioning-platform/advanced/HITL.md +34 -0
- package/skills/build-decisioning-platform/advanced/IDEMPOTENCY.md +52 -0
- package/skills/build-decisioning-platform/advanced/MULTI-TENANT.md +47 -0
- package/skills/build-decisioning-platform/advanced/OAUTH.md +22 -0
- package/skills/build-decisioning-platform/advanced/REFERENCE.md +991 -0
- package/skills/build-decisioning-platform/advanced/SANDBOX.md +24 -0
- package/skills/build-decisioning-platform/advanced/STATE-MACHINE.md +52 -0
- package/skills/build-decisioning-signal-marketplace/SKILL.md +269 -0
- package/skills/build-generative-seller-agent/SKILL.md +89 -53
- package/skills/build-governance-agent/SKILL.md +76 -45
- package/skills/build-retail-media-agent/SKILL.md +87 -62
- package/skills/build-seller-agent/SKILL.md +384 -255
- package/skills/build-seller-agent/deployment.md +5 -3
- package/skills/build-seller-agent/specialisms/audience-sync.md +0 -2
- package/skills/build-seller-agent/specialisms/sales-broadcast-tv.md +0 -2
- package/skills/build-seller-agent/specialisms/sales-guaranteed.md +0 -2
- package/skills/build-seller-agent/specialisms/sales-non-guaranteed.md +0 -2
- package/skills/build-seller-agent/specialisms/sales-proposal-mode.md +0 -2
- package/skills/build-seller-agent/specialisms/sales-social.md +0 -2
- package/skills/build-seller-agent/specialisms/signed-requests.md +0 -2
- package/skills/build-si-agent/SKILL.md +40 -32
- package/skills/build-signals-agent/SKILL.md +139 -92
- package/skills/call-adcp-agent.previous/SKILL.md +5 -0
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Runtime validation that a `DecisioningPlatform` impl matches its
|
|
4
|
+
* `capabilities.specialisms[]` declaration.
|
|
5
|
+
*
|
|
6
|
+
* Compile-time, `RequiredPlatformsFor<S>` enforces this in TypeScript adopter
|
|
7
|
+
* code. Untyped JS callers, downstream packages with relaxed `tsconfig`, and
|
|
8
|
+
* Python-port adopters running this through bindings need a runtime gate.
|
|
9
|
+
*
|
|
10
|
+
* Mirrors the v1.0 specialism × interface mapping in
|
|
11
|
+
* `src/lib/server/decisioning/platform.ts`.
|
|
12
|
+
*
|
|
13
|
+
* @public
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.PlatformConfigError = void 0;
|
|
17
|
+
exports.validatePlatform = validatePlatform;
|
|
18
|
+
const SPECIALISM_REQUIREMENTS = {
|
|
19
|
+
// All sales-* specialisms share the SalesPlatform interface. Adopters
|
|
20
|
+
// implement `sales` once; the specialism enum picks which buyer-side
|
|
21
|
+
// storyboard the agent is validated against. Wired here per the AdCP 3.0
|
|
22
|
+
// GA enum; preview specialisms (sales-streaming-tv, sales-exchange,
|
|
23
|
+
// sales-retail-media) get added when they land in `AdCPSpecialism`.
|
|
24
|
+
'sales-non-guaranteed': ['sales'],
|
|
25
|
+
'sales-guaranteed': ['sales'],
|
|
26
|
+
'sales-broadcast-tv': ['sales'],
|
|
27
|
+
'sales-social': ['sales'],
|
|
28
|
+
'sales-catalog-driven': ['sales'],
|
|
29
|
+
'sales-proposal-mode': ['sales'],
|
|
30
|
+
// Creative specialisms share the CreativeXxxPlatform field name; adopters
|
|
31
|
+
// pick the right archetype (template / generative / ad-server) at
|
|
32
|
+
// construction time.
|
|
33
|
+
'creative-template': ['creative'],
|
|
34
|
+
'creative-generative': ['creative'],
|
|
35
|
+
'creative-ad-server': ['creative'],
|
|
36
|
+
// Audience sync is a single specialism with a single platform interface.
|
|
37
|
+
'audience-sync': ['audiences'],
|
|
38
|
+
// Signal specialisms — both share the SignalsPlatform interface.
|
|
39
|
+
// Marketplace = third-party data brokers; owned = first-party providers.
|
|
40
|
+
'signal-marketplace': ['signals'],
|
|
41
|
+
'signal-owned': ['signals'],
|
|
42
|
+
// Campaign governance — today's two specialisms share one platform
|
|
43
|
+
// interface; consolidates to `campaign-governance` when adcp#3329 lands.
|
|
44
|
+
'governance-spend-authority': ['campaignGovernance'],
|
|
45
|
+
'governance-delivery-monitor': ['campaignGovernance'],
|
|
46
|
+
// Property + collection list publishing.
|
|
47
|
+
'property-lists': ['propertyLists'],
|
|
48
|
+
'collection-lists': ['collectionLists'],
|
|
49
|
+
// Content standards — brand-safety / policy compliance enforcement.
|
|
50
|
+
'content-standards': ['contentStandards'],
|
|
51
|
+
// Brand-rights — identity discovery + licensing for branded inventory.
|
|
52
|
+
// 3 of 5 wire tools wire through `brandRights`; the other 2
|
|
53
|
+
// (`update_rights`, `creative_approval`) await AdcpToolMap landing
|
|
54
|
+
// and stay on the merge-seam path until then.
|
|
55
|
+
'brand-rights': ['brandRights'],
|
|
56
|
+
};
|
|
57
|
+
class PlatformConfigError extends Error {
|
|
58
|
+
name = 'PlatformConfigError';
|
|
59
|
+
constructor(message) {
|
|
60
|
+
super(message);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
exports.PlatformConfigError = PlatformConfigError;
|
|
64
|
+
// Note on HITL tools: the v6 unified shape collapses sync/HITL into a
|
|
65
|
+
// single method per tool whose return type is `Success | TaskHandoff<Success>`.
|
|
66
|
+
// Adopters branch in the body and call `ctx.handoffToTask(fn)` to defer
|
|
67
|
+
// to a background task. The framework detects the handoff marker at the
|
|
68
|
+
// dispatch seam — there's no exactly-one validation needed because the
|
|
69
|
+
// shape is the same regardless of which path the adopter takes.
|
|
70
|
+
//
|
|
71
|
+
// This applies to `create_media_buy` and `sync_creatives` today (the 2
|
|
72
|
+
// spec-listed tools whose per-tool response oneOf includes the Submitted
|
|
73
|
+
// arm). When adcontextprotocol/adcp#3392 lands, the same shape extends
|
|
74
|
+
// to `update_media_buy`, `build_creative`, `sync_catalogs`, `get_products`.
|
|
75
|
+
function validatePlatform(platform) {
|
|
76
|
+
const claimed = platform.capabilities?.specialisms ?? [];
|
|
77
|
+
const errors = [];
|
|
78
|
+
// 1. Specialism declarations match required interfaces
|
|
79
|
+
for (const specialism of claimed) {
|
|
80
|
+
const required = SPECIALISM_REQUIREMENTS[specialism];
|
|
81
|
+
if (!required)
|
|
82
|
+
continue; // forward-compat for unknown specialisms
|
|
83
|
+
for (const field of required) {
|
|
84
|
+
if (platform[field] == null) {
|
|
85
|
+
errors.push(`capabilities.specialisms claims '${specialism}'; platform.${String(field)} is missing`);
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
if (errors.length > 0) {
|
|
90
|
+
throw new PlatformConfigError(`DecisioningPlatform configuration is incomplete:\n - ${errors.join('\n - ')}`);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
//# sourceMappingURL=validate-platform.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-platform.js","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/runtime/validate-platform.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;GAYG;;;AAgEH,4CAkBC;AA7ED,MAAM,uBAAuB,GAA8E;IACzG,sEAAsE;IACtE,qEAAqE;IACrE,yEAAyE;IACzE,oEAAoE;IACpE,oEAAoE;IACpE,sBAAsB,EAAE,CAAC,OAAO,CAAC;IACjC,kBAAkB,EAAE,CAAC,OAAO,CAAC;IAC7B,oBAAoB,EAAE,CAAC,OAAO,CAAC;IAC/B,cAAc,EAAE,CAAC,OAAO,CAAC;IACzB,sBAAsB,EAAE,CAAC,OAAO,CAAC;IACjC,qBAAqB,EAAE,CAAC,OAAO,CAAC;IAChC,0EAA0E;IAC1E,kEAAkE;IAClE,qBAAqB;IACrB,mBAAmB,EAAE,CAAC,UAAU,CAAC;IACjC,qBAAqB,EAAE,CAAC,UAAU,CAAC;IACnC,oBAAoB,EAAE,CAAC,UAAU,CAAC;IAClC,yEAAyE;IACzE,eAAe,EAAE,CAAC,WAAW,CAAC;IAC9B,iEAAiE;IACjE,yEAAyE;IACzE,oBAAoB,EAAE,CAAC,SAAS,CAAC;IACjC,cAAc,EAAE,CAAC,SAAS,CAAC;IAC3B,mEAAmE;IACnE,yEAAyE;IACzE,4BAA4B,EAAE,CAAC,oBAAoB,CAAC;IACpD,6BAA6B,EAAE,CAAC,oBAAoB,CAAC;IACrD,yCAAyC;IACzC,gBAAgB,EAAE,CAAC,eAAe,CAAC;IACnC,kBAAkB,EAAE,CAAC,iBAAiB,CAAC;IACvC,oEAAoE;IACpE,mBAAmB,EAAE,CAAC,kBAAkB,CAAC;IACzC,uEAAuE;IACvE,4DAA4D;IAC5D,mEAAmE;IACnE,8CAA8C;IAC9C,cAAc,EAAE,CAAC,aAAa,CAAC;CAChC,CAAC;AAEF,MAAa,mBAAoB,SAAQ,KAAK;IACnC,IAAI,GAAG,qBAA8B,CAAC;IAC/C,YAAY,OAAe;QACzB,KAAK,CAAC,OAAO,CAAC,CAAC;IACjB,CAAC;CACF;AALD,kDAKC;AAED,sEAAsE;AACtE,gFAAgF;AAChF,wEAAwE;AACxE,wEAAwE;AACxE,uEAAuE;AACvE,gEAAgE;AAChE,EAAE;AACF,uEAAuE;AACvE,yEAAyE;AACzE,uEAAuE;AACvE,4EAA4E;AAE5E,SAAgB,gBAAgB,CAAC,QAA6B;IAC5D,MAAM,OAAO,GAAG,QAAQ,CAAC,YAAY,EAAE,WAAW,IAAI,EAAE,CAAC;IACzD,MAAM,MAAM,GAAa,EAAE,CAAC;IAE5B,uDAAuD;IACvD,KAAK,MAAM,UAAU,IAAI,OAAO,EAAE,CAAC;QACjC,MAAM,QAAQ,GAAG,uBAAuB,CAAC,UAAU,CAAC,CAAC;QACrD,IAAI,CAAC,QAAQ;YAAE,SAAS,CAAC,yCAAyC;QAClE,KAAK,MAAM,KAAK,IAAI,QAAQ,EAAE,CAAC;YAC7B,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,IAAI,EAAE,CAAC;gBAC5B,MAAM,CAAC,IAAI,CAAC,oCAAoC,UAAU,eAAe,MAAM,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC;YACvG,CAAC;QACH,CAAC;IACH,CAAC;IAED,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACtB,MAAM,IAAI,mBAAmB,CAAC,yDAAyD,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IAClH,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* AudiencePlatform — cross-cutting audience-sync specialism (v1.0).
|
|
3
|
+
*
|
|
4
|
+
* Used standalone (LiveRamp, Oracle Data Cloud, Salesforce CDP) or
|
|
5
|
+
* composed with sales-social (Snap/Meta/TikTok). Framework owns
|
|
6
|
+
* cross-platform threading; platform answers "given this audience, what
|
|
7
|
+
* happened on my system?"
|
|
8
|
+
*
|
|
9
|
+
* Status: Preview / 6.0. Not yet wired into the framework.
|
|
10
|
+
*
|
|
11
|
+
* @public
|
|
12
|
+
*/
|
|
13
|
+
import type { Account } from '../account';
|
|
14
|
+
import type { RequestContext } from '../context';
|
|
15
|
+
import type { SyncAudiencesRequest, SyncAudiencesSuccess } from '../../../types/tools.generated';
|
|
16
|
+
type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
|
|
17
|
+
/**
|
|
18
|
+
* The wire schema doesn't export a top-level `Audience` type; the shape lives
|
|
19
|
+
* inline on `SyncAudiencesRequest.audiences[]`. Extract it here so platform
|
|
20
|
+
* implementations have a name to type against.
|
|
21
|
+
*/
|
|
22
|
+
export type Audience = NonNullable<SyncAudiencesRequest['audiences']>[number];
|
|
23
|
+
/**
|
|
24
|
+
* Wire success-row shape for `sync_audiences`. Returning the array of these
|
|
25
|
+
* rows from `syncAudiences` is what adopters write — the framework wraps
|
|
26
|
+
* with `{ audiences: [...] }` to form `SyncAudiencesSuccess`.
|
|
27
|
+
*
|
|
28
|
+
* `action` enum is the wire spec's: `'created' | 'updated' | 'unchanged' |
|
|
29
|
+
* 'deleted' | 'failed'`. Note: `'rejected'` is NOT a valid wire action
|
|
30
|
+
* value — use `'failed'` for buyer-rejected audiences.
|
|
31
|
+
*/
|
|
32
|
+
export type SyncAudiencesRow = SyncAudiencesSuccess['audiences'][number];
|
|
33
|
+
export type AudienceStatus = NonNullable<SyncAudiencesRow['status']>;
|
|
34
|
+
export interface AudiencePlatform<TCtxMeta = Record<string, unknown>> {
|
|
35
|
+
/**
|
|
36
|
+
* Push audiences to the platform. Framework handles batching, idempotency,
|
|
37
|
+
* cross-tenant scoping. Platform handles match-rate computation and
|
|
38
|
+
* activation lifecycle.
|
|
39
|
+
*
|
|
40
|
+
* Sync acknowledgment with status changes via `publishStatusChange`:
|
|
41
|
+
* return per-audience result rows immediately (`pending` / `matching` are
|
|
42
|
+
* valid sync outcomes). The match-rate computation and activation
|
|
43
|
+
* pipeline run in the background — the platform calls
|
|
44
|
+
* `publishStatusChange({ resource_type: 'audience', ... })` from its
|
|
45
|
+
* webhook handler / job queue / cron when each audience reaches a
|
|
46
|
+
* terminal state.
|
|
47
|
+
*
|
|
48
|
+
* Throw `new AdcpError(...)` for buyer-fixable rejection
|
|
49
|
+
* (`AUDIENCE_TOO_SMALL`, etc.).
|
|
50
|
+
*/
|
|
51
|
+
syncAudiences(audiences: Audience[], ctx: Ctx<TCtxMeta>): Promise<SyncAudiencesRow[]>;
|
|
52
|
+
/**
|
|
53
|
+
* Batch-poll current status for one or more audiences. Sync — this is a
|
|
54
|
+
* state-read, not a mutating operation. Useful for buyer-side polling
|
|
55
|
+
* outside the framework's task envelope (e.g., querying long-lived
|
|
56
|
+
* audiences) and for adapter code that needs to check N audiences at
|
|
57
|
+
* once.
|
|
58
|
+
*
|
|
59
|
+
* Returns a `Map<audience_id, AudienceStatus>`. Audiences not found are
|
|
60
|
+
* omitted from the map (callers handle missing keys); throw
|
|
61
|
+
* `AdcpError('REFERENCE_NOT_FOUND')` only when the entire batch is
|
|
62
|
+
* unresolvable for the tenant.
|
|
63
|
+
*
|
|
64
|
+
* Single-audience polling is `pollAudienceStatuses([id], ctx).then(m =>
|
|
65
|
+
* m.get(id))`. The batch shape composes with upstream identity-graph
|
|
66
|
+
* APIs that natively return per-audience-id arrays — adopters do NOT
|
|
67
|
+
* need to wrap a single-id lookup over an N-call loop.
|
|
68
|
+
*/
|
|
69
|
+
pollAudienceStatuses(audienceIds: readonly string[], ctx: Ctx<TCtxMeta>): Promise<Map<string, AudienceStatus>>;
|
|
70
|
+
}
|
|
71
|
+
export {};
|
|
72
|
+
//# sourceMappingURL=audiences.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audiences.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/audiences.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,KAAK,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAEjG,KAAK,GAAG,CAAC,QAAQ,IAAI,cAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;AAEvD;;;;GAIG;AACH,MAAM,MAAM,QAAQ,GAAG,WAAW,CAAC,oBAAoB,CAAC,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;AAE9E;;;;;;;;GAQG;AACH,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,CAAC,WAAW,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzE,MAAM,MAAM,cAAc,GAAG,WAAW,CAAC,gBAAgB,CAAC,QAAQ,CAAC,CAAC,CAAC;AAErE,MAAM,WAAW,gBAAgB,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAClE;;;;;;;;;;;;;;;OAeG;IACH,aAAa,CAAC,SAAS,EAAE,QAAQ,EAAE,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAEtF;;;;;;;;;;;;;;;;OAgBG;IACH,oBAAoB,CAAC,WAAW,EAAE,SAAS,MAAM,EAAE,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC,CAAC;CAChH"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* AudiencePlatform — cross-cutting audience-sync specialism (v1.0).
|
|
4
|
+
*
|
|
5
|
+
* Used standalone (LiveRamp, Oracle Data Cloud, Salesforce CDP) or
|
|
6
|
+
* composed with sales-social (Snap/Meta/TikTok). Framework owns
|
|
7
|
+
* cross-platform threading; platform answers "given this audience, what
|
|
8
|
+
* happened on my system?"
|
|
9
|
+
*
|
|
10
|
+
* Status: Preview / 6.0. Not yet wired into the framework.
|
|
11
|
+
*
|
|
12
|
+
* @public
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
//# sourceMappingURL=audiences.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audiences.js","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/audiences.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG"}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* BrandRightsPlatform — `brand-rights` specialism (v1.0).
|
|
3
|
+
*
|
|
4
|
+
* Brand-rights agents handle identity discovery + licensing for branded
|
|
5
|
+
* inventory — covers IP holders (sports leagues, movie studios), CTV
|
|
6
|
+
* brand-rights desks, and brand-licensing marketplaces. Adopters
|
|
7
|
+
* implement the three wire tools the spec ships with stable schemas
|
|
8
|
+
* AND framework dispatch infrastructure (in `AdcpToolMap`):
|
|
9
|
+
*
|
|
10
|
+
* - `get_brand_identity` — sync read; brand catalog + identity record
|
|
11
|
+
* - `get_rights` — sync read; rights matching a brand + use query
|
|
12
|
+
* - `acquire_rights` — buyer commits to an offering. Async outcomes
|
|
13
|
+
* are delivered via the buyer-supplied `push_notification_config`
|
|
14
|
+
* webhook (NOT a polling tool — the spec doesn't define one for
|
|
15
|
+
* this surface).
|
|
16
|
+
*
|
|
17
|
+
* The two other surfaces in this domain (`update_rights`,
|
|
18
|
+
* `creative_approval`) are spec-published but not yet in `AdcpToolMap`;
|
|
19
|
+
* adopters wire them via the merge seam (`opts.brandRights.*`) until
|
|
20
|
+
* they land in v6.1.
|
|
21
|
+
*
|
|
22
|
+
* Status: Preview / 6.0.
|
|
23
|
+
*
|
|
24
|
+
* @public
|
|
25
|
+
*/
|
|
26
|
+
import type { Account } from '../account';
|
|
27
|
+
import type { RequestContext } from '../context';
|
|
28
|
+
import type { GetBrandIdentityRequest, GetBrandIdentitySuccess, GetRightsRequest, GetRightsSuccess, AcquireRightsRequest, AcquireRightsAcquired, AcquireRightsPendingApproval, AcquireRightsRejected } from '../../../types/core.generated';
|
|
29
|
+
type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
|
|
30
|
+
export interface BrandRightsPlatform<TCtxMeta = Record<string, unknown>> {
|
|
31
|
+
/**
|
|
32
|
+
* Read brand identity record — `brand_id`, `house`, localized `names`,
|
|
33
|
+
* optional logos / industries / `keller_type`. Sync; no async ceremony.
|
|
34
|
+
* Throw `AdcpError('REFERENCE_NOT_FOUND')` when the brand reference
|
|
35
|
+
* doesn't resolve to an identity the platform tracks.
|
|
36
|
+
*/
|
|
37
|
+
getBrandIdentity(req: GetBrandIdentityRequest, ctx: Ctx<TCtxMeta>): Promise<GetBrandIdentitySuccess>;
|
|
38
|
+
/**
|
|
39
|
+
* List rights matching a brand + use query. Sync read; framework
|
|
40
|
+
* wraps the response in the wire envelope. Returning an empty
|
|
41
|
+
* `rights` array is valid (= "no rights available for the requested
|
|
42
|
+
* terms"); throw `AdcpError` only for buyer-fixable rejection (e.g.,
|
|
43
|
+
* unsupported jurisdiction).
|
|
44
|
+
*
|
|
45
|
+
* Note: the wire field is `rights`, NOT `offerings`. Adopters who
|
|
46
|
+
* named their internal model `offerings` translate at this seam.
|
|
47
|
+
*/
|
|
48
|
+
getRights(req: GetRightsRequest, ctx: Ctx<TCtxMeta>): Promise<GetRightsSuccess>;
|
|
49
|
+
/**
|
|
50
|
+
* Acquire rights — buyer commits to an offering. Four wire-spec arms:
|
|
51
|
+
*
|
|
52
|
+
* - `AcquireRightsAcquired` — rights granted immediately. Carries
|
|
53
|
+
* `rights_id`, `status: 'acquired'`, `brand_id`, `terms`,
|
|
54
|
+
* `generation_credentials` (scoped per-LLM-provider keys), and
|
|
55
|
+
* `rights_constraint` so the buyer can plumb the grant directly
|
|
56
|
+
* into creative generation.
|
|
57
|
+
* - `AcquireRightsPendingApproval` — clearance pending counter-
|
|
58
|
+
* signature, legal review, or rights-holder approval. Carries
|
|
59
|
+
* `rights_id`, `status: 'pending_approval'`, `brand_id`, plus
|
|
60
|
+
* optional `detail` and `estimated_response_time` (e.g., '48h').
|
|
61
|
+
* **Async delivery is webhook-only** — the buyer's
|
|
62
|
+
* `push_notification_config.url` receives the eventual
|
|
63
|
+
* `Acquired` or `Rejected` outcome. The spec does NOT define
|
|
64
|
+
* a polling tool for `acquire_rights`; do not reach for
|
|
65
|
+
* `tasks_get` here.
|
|
66
|
+
* - `AcquireRightsRejected` — terminal rejection. Carries
|
|
67
|
+
* `rights_id`, `status: 'rejected'`, `brand_id`, `reason`,
|
|
68
|
+
* and optional `suggestions[]` for buyer remediation.
|
|
69
|
+
*
|
|
70
|
+
* The wire spec also defines a fourth `AcquireRightsError` arm
|
|
71
|
+
* (multi-error `{ errors: Error[] }`) for batch-style failures.
|
|
72
|
+
* Adopters who need that shape throw
|
|
73
|
+
* `AdcpError('INVALID_REQUEST', { details: { errors: [...] } })`
|
|
74
|
+
* — the framework projects to the same wire envelope. The platform
|
|
75
|
+
* interface accepts only the 3 success-arm shapes by design;
|
|
76
|
+
* `AdcpError` is the canonical multi-error path here, matching
|
|
77
|
+
* `SalesPlatform.createMediaBuy` preflight.
|
|
78
|
+
*
|
|
79
|
+
* Throw `AdcpError` only for buyer-fixable REQUEST rejection
|
|
80
|
+
* (`INVALID_REQUEST`, `BUDGET_TOO_LOW`). For spec-defined GRANT
|
|
81
|
+
* rejection (rights unavailable in jurisdiction, talent dispute
|
|
82
|
+
* pending) return the `AcquireRightsRejected` arm so the buyer sees
|
|
83
|
+
* the structured wire response with `reason` + `suggestions`.
|
|
84
|
+
*
|
|
85
|
+
* Pre-flight (catalog availability, agency authorization) MUST run
|
|
86
|
+
* sync regardless of arm — invalid requests reject before allocating
|
|
87
|
+
* any state.
|
|
88
|
+
*/
|
|
89
|
+
acquireRights(req: AcquireRightsRequest, ctx: Ctx<TCtxMeta>): Promise<AcquireRightsAcquired | AcquireRightsPendingApproval | AcquireRightsRejected>;
|
|
90
|
+
}
|
|
91
|
+
export {};
|
|
92
|
+
//# sourceMappingURL=brand-rights.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"brand-rights.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/brand-rights.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAMjD,OAAO,KAAK,EACV,uBAAuB,EACvB,uBAAuB,EACvB,gBAAgB,EAChB,gBAAgB,EAChB,oBAAoB,EACpB,qBAAqB,EACrB,4BAA4B,EAC5B,qBAAqB,EACtB,MAAM,+BAA+B,CAAC;AAEvC,KAAK,GAAG,CAAC,QAAQ,IAAI,cAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;AAEvD,MAAM,WAAW,mBAAmB,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IACrE;;;;;OAKG;IACH,gBAAgB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAErG;;;;;;;;;OASG;IACH,SAAS,CAAC,GAAG,EAAE,gBAAgB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAEhF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAuCG;IACH,aAAa,CACX,GAAG,EAAE,oBAAoB,EACzB,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,qBAAqB,GAAG,4BAA4B,GAAG,qBAAqB,CAAC,CAAC;CAC1F"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* BrandRightsPlatform — `brand-rights` specialism (v1.0).
|
|
4
|
+
*
|
|
5
|
+
* Brand-rights agents handle identity discovery + licensing for branded
|
|
6
|
+
* inventory — covers IP holders (sports leagues, movie studios), CTV
|
|
7
|
+
* brand-rights desks, and brand-licensing marketplaces. Adopters
|
|
8
|
+
* implement the three wire tools the spec ships with stable schemas
|
|
9
|
+
* AND framework dispatch infrastructure (in `AdcpToolMap`):
|
|
10
|
+
*
|
|
11
|
+
* - `get_brand_identity` — sync read; brand catalog + identity record
|
|
12
|
+
* - `get_rights` — sync read; rights matching a brand + use query
|
|
13
|
+
* - `acquire_rights` — buyer commits to an offering. Async outcomes
|
|
14
|
+
* are delivered via the buyer-supplied `push_notification_config`
|
|
15
|
+
* webhook (NOT a polling tool — the spec doesn't define one for
|
|
16
|
+
* this surface).
|
|
17
|
+
*
|
|
18
|
+
* The two other surfaces in this domain (`update_rights`,
|
|
19
|
+
* `creative_approval`) are spec-published but not yet in `AdcpToolMap`;
|
|
20
|
+
* adopters wire them via the merge seam (`opts.brandRights.*`) until
|
|
21
|
+
* they land in v6.1.
|
|
22
|
+
*
|
|
23
|
+
* Status: Preview / 6.0.
|
|
24
|
+
*
|
|
25
|
+
* @public
|
|
26
|
+
*/
|
|
27
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
|
+
//# sourceMappingURL=brand-rights.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"brand-rights.js","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/brand-rights.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CampaignGovernancePlatform — runtime governance decisioning for advertiser
|
|
3
|
+
* campaigns (v6.0).
|
|
4
|
+
*
|
|
5
|
+
* Today's AdCP 3.0 GA enum splits this role across two specialism values:
|
|
6
|
+
*
|
|
7
|
+
* - `governance-spend-authority` — agent gates spending decisions
|
|
8
|
+
* - `governance-delivery-monitor` — agent monitors delivery actuals
|
|
9
|
+
*
|
|
10
|
+
* Both describe one role (a governance agent that makes runtime decisions
|
|
11
|
+
* for advertiser campaigns), differing only by capability. This single
|
|
12
|
+
* interface covers both. When `adcontextprotocol/adcp#3329` lands and the
|
|
13
|
+
* spec consolidates to `campaign-governance`, we rename the type without
|
|
14
|
+
* shape changes.
|
|
15
|
+
*
|
|
16
|
+
* Shape: a decision API. The agent inspects a proposed action (or running
|
|
17
|
+
* delivery) and returns `approved`, `denied`, or `conditions` (approved-if).
|
|
18
|
+
* Status changes (plan moving from `pending_approval` → `active` → `closed`)
|
|
19
|
+
* flow via `publishStatusChange({ resource_type: 'plan', ... })`.
|
|
20
|
+
*
|
|
21
|
+
* Sync at the wire level — `CheckGovernanceResponse` has no `Submitted`
|
|
22
|
+
* arm. Slow approval pipelines (operator review) return current state
|
|
23
|
+
* (e.g., `pending`) and emit status changes when the human decision lands.
|
|
24
|
+
*
|
|
25
|
+
* Status: Preview / 6.0.
|
|
26
|
+
*
|
|
27
|
+
* @public
|
|
28
|
+
*/
|
|
29
|
+
import type { Account } from '../account';
|
|
30
|
+
import type { RequestContext } from '../context';
|
|
31
|
+
import type { CheckGovernanceRequest, CheckGovernanceResponse, SyncPlansRequest, SyncPlansResponse, ReportPlanOutcomeRequest, ReportPlanOutcomeResponse, GetPlanAuditLogsRequest, GetPlanAuditLogsResponse } from '../../../types/tools.generated';
|
|
32
|
+
type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
|
|
33
|
+
export interface CampaignGovernancePlatform<TCtxMeta = Record<string, unknown>> {
|
|
34
|
+
/**
|
|
35
|
+
* Runtime governance decision. Buyer (or seller, on the seller's behalf)
|
|
36
|
+
* sends a proposed action; the agent inspects it against the plan and
|
|
37
|
+
* returns approved / denied / conditions.
|
|
38
|
+
*
|
|
39
|
+
* The `phase` field discriminates the context: `'intent'` (pre-action),
|
|
40
|
+
* `'delivery'` (running campaign with actuals), `'reconciliation'`
|
|
41
|
+
* (post-flight). The agent's logic varies by phase.
|
|
42
|
+
*
|
|
43
|
+
* Throw `AdcpError` for buyer-fixable rejection
|
|
44
|
+
* (`'PLAN_NOT_FOUND'`, `'INVALID_REQUEST'`, etc.). Use the response
|
|
45
|
+
* `status: 'denied'` for governance decisions that ARE the answer
|
|
46
|
+
* (the plan exists and the agent is rejecting the action).
|
|
47
|
+
*/
|
|
48
|
+
checkGovernance(req: CheckGovernanceRequest, ctx: Ctx<TCtxMeta>): Promise<CheckGovernanceResponse>;
|
|
49
|
+
/**
|
|
50
|
+
* Plan CRUD. Buyers sync their campaign plans into the governance
|
|
51
|
+
* agent so the agent can maintain spend authority + delivery context.
|
|
52
|
+
*/
|
|
53
|
+
syncPlans(req: SyncPlansRequest, ctx: Ctx<TCtxMeta>): Promise<SyncPlansResponse>;
|
|
54
|
+
/**
|
|
55
|
+
* Outcome reporting. Sellers report what actually happened (impressions
|
|
56
|
+
* delivered, spend incurred, status transitions) so the agent can
|
|
57
|
+
* calibrate future decisions.
|
|
58
|
+
*/
|
|
59
|
+
reportPlanOutcome(req: ReportPlanOutcomeRequest, ctx: Ctx<TCtxMeta>): Promise<ReportPlanOutcomeResponse>;
|
|
60
|
+
/**
|
|
61
|
+
* Audit log read. Returns the chronological history of governance
|
|
62
|
+
* decisions + outcome reports for a plan.
|
|
63
|
+
*/
|
|
64
|
+
getPlanAuditLogs(req: GetPlanAuditLogsRequest, ctx: Ctx<TCtxMeta>): Promise<GetPlanAuditLogsResponse>;
|
|
65
|
+
}
|
|
66
|
+
export {};
|
|
67
|
+
//# sourceMappingURL=campaign-governance.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"campaign-governance.d.ts","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/campaign-governance.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,KAAK,EACV,sBAAsB,EACtB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,wBAAwB,EACxB,yBAAyB,EACzB,uBAAuB,EACvB,wBAAwB,EACzB,MAAM,gCAAgC,CAAC;AAExC,KAAK,GAAG,CAAC,QAAQ,IAAI,cAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;AAEvD,MAAM,WAAW,0BAA0B,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC5E;;;;;;;;;;;;;OAaG;IACH,eAAe,CAAC,GAAG,EAAE,sBAAsB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAEnG;;;OAGG;IACH,SAAS,CAAC,GAAG,EAAE,gBAAgB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;IAEjF;;;;OAIG;IACH,iBAAiB,CAAC,GAAG,EAAE,wBAAwB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,yBAAyB,CAAC,CAAC;IAEzG;;;OAGG;IACH,gBAAgB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,wBAAwB,CAAC,CAAC;CACvG"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* CampaignGovernancePlatform — runtime governance decisioning for advertiser
|
|
4
|
+
* campaigns (v6.0).
|
|
5
|
+
*
|
|
6
|
+
* Today's AdCP 3.0 GA enum splits this role across two specialism values:
|
|
7
|
+
*
|
|
8
|
+
* - `governance-spend-authority` — agent gates spending decisions
|
|
9
|
+
* - `governance-delivery-monitor` — agent monitors delivery actuals
|
|
10
|
+
*
|
|
11
|
+
* Both describe one role (a governance agent that makes runtime decisions
|
|
12
|
+
* for advertiser campaigns), differing only by capability. This single
|
|
13
|
+
* interface covers both. When `adcontextprotocol/adcp#3329` lands and the
|
|
14
|
+
* spec consolidates to `campaign-governance`, we rename the type without
|
|
15
|
+
* shape changes.
|
|
16
|
+
*
|
|
17
|
+
* Shape: a decision API. The agent inspects a proposed action (or running
|
|
18
|
+
* delivery) and returns `approved`, `denied`, or `conditions` (approved-if).
|
|
19
|
+
* Status changes (plan moving from `pending_approval` → `active` → `closed`)
|
|
20
|
+
* flow via `publishStatusChange({ resource_type: 'plan', ... })`.
|
|
21
|
+
*
|
|
22
|
+
* Sync at the wire level — `CheckGovernanceResponse` has no `Submitted`
|
|
23
|
+
* arm. Slow approval pipelines (operator review) return current state
|
|
24
|
+
* (e.g., `pending`) and emit status changes when the human decision lands.
|
|
25
|
+
*
|
|
26
|
+
* Status: Preview / 6.0.
|
|
27
|
+
*
|
|
28
|
+
* @public
|
|
29
|
+
*/
|
|
30
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
31
|
+
//# sourceMappingURL=campaign-governance.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"campaign-governance.js","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/campaign-governance.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ContentStandardsPlatform — `content-standards` specialism (v6.0).
|
|
3
|
+
*
|
|
4
|
+
* Content standards enforcement: brand safety policies, content adjacency
|
|
5
|
+
* rules, and per-creative compliance verification. Adopters who claim
|
|
6
|
+
* `content-standards` in `capabilities.specialisms[]` implement this
|
|
7
|
+
* interface; the framework wires the 6 wire tools that make up the
|
|
8
|
+
* content-standards surface.
|
|
9
|
+
*
|
|
10
|
+
* Two adopter shapes:
|
|
11
|
+
*
|
|
12
|
+
* - **Standalone content-standards agent** (Innovid-style): runs apart
|
|
13
|
+
* from a sales agent; buyers call `list_content_standards` /
|
|
14
|
+
* `get_content_standards` / `validate_content_delivery` directly.
|
|
15
|
+
* - **Composed within a seller** (governance overlay): seller imports
|
|
16
|
+
* content-standards into its agent surface, calls `calibrate_content`
|
|
17
|
+
* internally during creative review, and surfaces violations through
|
|
18
|
+
* `sync_creatives` review state.
|
|
19
|
+
*
|
|
20
|
+
* Both shapes use the same interface; difference is whether the platform
|
|
21
|
+
* field is populated alongside `sales` or as the only specialism.
|
|
22
|
+
*
|
|
23
|
+
* The two analyzer methods (`getMediaBuyArtifacts`, `getCreativeFeatures`)
|
|
24
|
+
* are listed under the same surface in the framework's `GovernanceHandlers`
|
|
25
|
+
* because they're content-feature reads adopters typically expose alongside
|
|
26
|
+
* the policy CRUD. Optional — adopters who don't run analyzer pipelines
|
|
27
|
+
* leave them undefined.
|
|
28
|
+
*
|
|
29
|
+
* Status: Preview / 6.0.
|
|
30
|
+
*
|
|
31
|
+
* @public
|
|
32
|
+
*/
|
|
33
|
+
import type { Account } from '../account';
|
|
34
|
+
import type { RequestContext } from '../context';
|
|
35
|
+
import type { ListContentStandardsRequest, ListContentStandardsResponse, GetContentStandardsRequest, GetContentStandardsResponse, CreateContentStandardsRequest, CreateContentStandardsResponse, UpdateContentStandardsRequest, UpdateContentStandardsResponse, CalibrateContentRequest, CalibrateContentResponse, ValidateContentDeliveryRequest, ValidateContentDeliveryResponse, GetMediaBuyArtifactsRequest, GetMediaBuyArtifactsResponse, GetCreativeFeaturesRequest, GetCreativeFeaturesResponse } from '../../../types/tools.generated';
|
|
36
|
+
type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
|
|
37
|
+
export interface ContentStandardsPlatform<TCtxMeta = Record<string, unknown>> {
|
|
38
|
+
/** Discover content standards published by this agent. */
|
|
39
|
+
listContentStandards(req: ListContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<ListContentStandardsResponse>;
|
|
40
|
+
/** Read a single content standard by id. */
|
|
41
|
+
getContentStandards(req: GetContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<GetContentStandardsResponse>;
|
|
42
|
+
/**
|
|
43
|
+
* Create a new content standard. Adopter validates the policy schema
|
|
44
|
+
* and returns the persisted record. Idempotent on the buyer's
|
|
45
|
+
* `idempotency_key`.
|
|
46
|
+
*/
|
|
47
|
+
createContentStandards(req: CreateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<CreateContentStandardsResponse>;
|
|
48
|
+
/** Update an existing content standard. */
|
|
49
|
+
updateContentStandards(req: UpdateContentStandardsRequest, ctx: Ctx<TCtxMeta>): Promise<UpdateContentStandardsResponse>;
|
|
50
|
+
/**
|
|
51
|
+
* Calibrate content against the published standards. Returns the
|
|
52
|
+
* standard's current calibration profile + any flags raised against
|
|
53
|
+
* the submitted content.
|
|
54
|
+
*/
|
|
55
|
+
calibrateContent(req: CalibrateContentRequest, ctx: Ctx<TCtxMeta>): Promise<CalibrateContentResponse>;
|
|
56
|
+
/**
|
|
57
|
+
* Validate that a delivered media-buy / creative meets the buyer's
|
|
58
|
+
* declared content-standards. Sellers call this post-flight to confirm
|
|
59
|
+
* adjacency and policy conformance before issuing a
|
|
60
|
+
* `validate_content_delivery_artifact` to a governance agent.
|
|
61
|
+
*/
|
|
62
|
+
validateContentDelivery(req: ValidateContentDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<ValidateContentDeliveryResponse>;
|
|
63
|
+
/**
|
|
64
|
+
* Read content artifacts produced during a media buy's flight (creative
|
|
65
|
+
* proofs, ad-server tags, completed log captures). Optional — adopters
|
|
66
|
+
* who don't expose artifact archival omit. Required by governance
|
|
67
|
+
* receivers running adjacency validation.
|
|
68
|
+
*/
|
|
69
|
+
getMediaBuyArtifacts?(req: GetMediaBuyArtifactsRequest, ctx: Ctx<TCtxMeta>): Promise<GetMediaBuyArtifactsResponse>;
|
|
70
|
+
/**
|
|
71
|
+
* Read per-creative analyzed features (object detection, scene
|
|
72
|
+
* classification, transcript) the agent extracted during calibration.
|
|
73
|
+
* Optional — adopters without analyzer pipelines omit.
|
|
74
|
+
*/
|
|
75
|
+
getCreativeFeatures?(req: GetCreativeFeaturesRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeFeaturesResponse>;
|
|
76
|
+
}
|
|
77
|
+
export {};
|
|
78
|
+
//# sourceMappingURL=content-standards.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
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,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,KAAK,EACV,2BAA2B,EAC3B,4BAA4B,EAC5B,0BAA0B,EAC1B,2BAA2B,EAC3B,6BAA6B,EAC7B,8BAA8B,EAC9B,6BAA6B,EAC7B,8BAA8B,EAC9B,uBAAuB,EACvB,wBAAwB,EACxB,8BAA8B,EAC9B,+BAA+B,EAC/B,2BAA2B,EAC3B,4BAA4B,EAC5B,0BAA0B,EAC1B,2BAA2B,EAC5B,MAAM,gCAAgC,CAAC;AAExC,KAAK,GAAG,CAAC,QAAQ,IAAI,cAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;AAEvD,MAAM,WAAW,wBAAwB,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC1E,0DAA0D;IAC1D,oBAAoB,CAAC,GAAG,EAAE,2BAA2B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,4BAA4B,CAAC,CAAC;IAElH,4CAA4C;IAC5C,mBAAmB,CAAC,GAAG,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,2BAA2B,CAAC,CAAC;IAE/G;;;;OAIG;IACH,sBAAsB,CACpB,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,8BAA8B,CAAC,CAAC;IAE3C,2CAA2C;IAC3C,sBAAsB,CACpB,GAAG,EAAE,6BAA6B,EAClC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,8BAA8B,CAAC,CAAC;IAE3C;;;;OAIG;IACH,gBAAgB,CAAC,GAAG,EAAE,uBAAuB,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,wBAAwB,CAAC,CAAC;IAEtG;;;;;OAKG;IACH,uBAAuB,CACrB,GAAG,EAAE,8BAA8B,EACnC,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GACjB,OAAO,CAAC,+BAA+B,CAAC,CAAC;IAE5C;;;;;OAKG;IACH,oBAAoB,CAAC,CAAC,GAAG,EAAE,2BAA2B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,4BAA4B,CAAC,CAAC;IAEnH;;;;OAIG;IACH,mBAAmB,CAAC,CAAC,GAAG,EAAE,0BAA0B,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,2BAA2B,CAAC,CAAC;CACjH"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* ContentStandardsPlatform — `content-standards` specialism (v6.0).
|
|
4
|
+
*
|
|
5
|
+
* Content standards enforcement: brand safety policies, content adjacency
|
|
6
|
+
* rules, and per-creative compliance verification. Adopters who claim
|
|
7
|
+
* `content-standards` in `capabilities.specialisms[]` implement this
|
|
8
|
+
* interface; the framework wires the 6 wire tools that make up the
|
|
9
|
+
* content-standards surface.
|
|
10
|
+
*
|
|
11
|
+
* Two adopter shapes:
|
|
12
|
+
*
|
|
13
|
+
* - **Standalone content-standards agent** (Innovid-style): runs apart
|
|
14
|
+
* from a sales agent; buyers call `list_content_standards` /
|
|
15
|
+
* `get_content_standards` / `validate_content_delivery` directly.
|
|
16
|
+
* - **Composed within a seller** (governance overlay): seller imports
|
|
17
|
+
* content-standards into its agent surface, calls `calibrate_content`
|
|
18
|
+
* internally during creative review, and surfaces violations through
|
|
19
|
+
* `sync_creatives` review state.
|
|
20
|
+
*
|
|
21
|
+
* Both shapes use the same interface; difference is whether the platform
|
|
22
|
+
* field is populated alongside `sales` or as the only specialism.
|
|
23
|
+
*
|
|
24
|
+
* The two analyzer methods (`getMediaBuyArtifacts`, `getCreativeFeatures`)
|
|
25
|
+
* are listed under the same surface in the framework's `GovernanceHandlers`
|
|
26
|
+
* because they're content-feature reads adopters typically expose alongside
|
|
27
|
+
* the policy CRUD. Optional — adopters who don't run analyzer pipelines
|
|
28
|
+
* leave them undefined.
|
|
29
|
+
*
|
|
30
|
+
* Status: Preview / 6.0.
|
|
31
|
+
*
|
|
32
|
+
* @public
|
|
33
|
+
*/
|
|
34
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
|
+
//# sourceMappingURL=content-standards.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content-standards.js","sourceRoot":"","sources":["../../../../../src/lib/server/decisioning/specialisms/content-standards.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG"}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CreativeAdServerPlatform — third creative archetype (v6.0).
|
|
3
|
+
*
|
|
4
|
+
* Stateful creative library + per-creative pricing + tag generation. The
|
|
5
|
+
* canonical shape for creative-ad-server adopters: Innovid, Flashtalking,
|
|
6
|
+
* GAM-creative, CMP-style platforms.
|
|
7
|
+
*
|
|
8
|
+
* Distinct from `CreativeTemplatePlatform` (stateless transform) and
|
|
9
|
+
* `CreativeGenerativePlatform` (brief-driven generation):
|
|
10
|
+
*
|
|
11
|
+
* - **Stateful** — adopter persists creatives in a library; `syncCreatives`
|
|
12
|
+
* pushes assets in, `listCreatives` reads them back, `buildCreative`
|
|
13
|
+
* either looks up an existing creative by id OR pushes a new one
|
|
14
|
+
* - **Pricing per creative** — vendor pricing options on each creative;
|
|
15
|
+
* `pricing_option_id` selected at activation, billed via `report_usage`
|
|
16
|
+
* - **Tag generation** — `buildCreative` returns ad-server tags (VAST,
|
|
17
|
+
* placement-specific tracking pixels, macro-substituted creative HTML)
|
|
18
|
+
* when invoked with `media_buy_id` + `package_id` context
|
|
19
|
+
* - **Per-creative delivery reports** — `get_creative_delivery` returns
|
|
20
|
+
* pacing data per creative across the library
|
|
21
|
+
*
|
|
22
|
+
* Status: Preview / 6.0.
|
|
23
|
+
*
|
|
24
|
+
* @public
|
|
25
|
+
*/
|
|
26
|
+
import type { Account } from '../account';
|
|
27
|
+
import type { RequestContext } from '../context';
|
|
28
|
+
import type { TaskHandoff } from '../async-outcome';
|
|
29
|
+
import type { BuildCreativeRequest, CreativeManifest, PreviewCreativeRequest, PreviewCreativeResponse, ListCreativesRequest, ListCreativesResponse, GetCreativeDeliveryRequest, GetCreativeDeliveryResponse, CreativeAsset, BuildCreativeSuccess, BuildCreativeMultiSuccess } from '../../../types/tools.generated';
|
|
30
|
+
import type { SyncCreativesRow } from './sales';
|
|
31
|
+
type Creative = CreativeAsset;
|
|
32
|
+
type Ctx<TCtxMeta> = RequestContext<Account<TCtxMeta>>;
|
|
33
|
+
export interface CreativeAdServerPlatform<TCtxMeta = Record<string, unknown>> {
|
|
34
|
+
/**
|
|
35
|
+
* Build / retrieve creative tags. Two invocation modes per the spec:
|
|
36
|
+
*
|
|
37
|
+
* - **Library lookup**: `req.creative_id` references an existing
|
|
38
|
+
* creative; return the manifest with tag fields populated
|
|
39
|
+
* (`vast_tag`, click trackers, etc.). When `req.media_buy_id` +
|
|
40
|
+
* `req.package_id` are also set, generate placement-specific tags
|
|
41
|
+
* with macro substitution baked in.
|
|
42
|
+
* - **Inline build**: `req.creative_manifest` is provided directly;
|
|
43
|
+
* transform / wrap it (similar to template archetype but with
|
|
44
|
+
* ad-server side effects: register the creative in the library,
|
|
45
|
+
* generate the tag, etc.).
|
|
46
|
+
*
|
|
47
|
+
* Spec defines a Submitted arm via `async-response-data.json` but the
|
|
48
|
+
* per-tool `build-creative-response.json` `oneOf` doesn't include it,
|
|
49
|
+
* so codegen produces a `BuildCreativeResponse` without Submitted —
|
|
50
|
+
* a SPEC inconsistency, tracked as adcontextprotocol/adcp#3392. Until
|
|
51
|
+
* that lands, slow tag-generation pipelines await in-request; status
|
|
52
|
+
* changes flow via `publishStatusChange`.
|
|
53
|
+
*/
|
|
54
|
+
buildCreative(req: BuildCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<CreativeManifest | CreativeManifest[] | BuildCreativeSuccess | BuildCreativeMultiSuccess>;
|
|
55
|
+
/** Preview-only variant — sandbox URL or inline HTML, expires. Always sync. */
|
|
56
|
+
previewCreative(req: PreviewCreativeRequest, ctx: Ctx<TCtxMeta>): Promise<PreviewCreativeResponse>;
|
|
57
|
+
/**
|
|
58
|
+
* Push creatives. Return per-creative result rows (sync fast path) OR
|
|
59
|
+
* `ctx.handoffToTask(fn)` to promote to a background task (HITL —
|
|
60
|
+
* brand-suitability, S&P review). `action: 'created'` for new entries,
|
|
61
|
+
* `'updated'` for replacements, `'unchanged'` when matching. Optional
|
|
62
|
+
* `status: 'pending_review'` for sync-arm rows awaiting manual review.
|
|
63
|
+
*/
|
|
64
|
+
syncCreatives?(creatives: Creative[], ctx: Ctx<TCtxMeta>): Promise<SyncCreativesRow[] | TaskHandoff<SyncCreativesRow[]>>;
|
|
65
|
+
/**
|
|
66
|
+
* Read creatives from the library. Filters + pagination. When
|
|
67
|
+
* `req.include_assignments`, include the buyer's package-assignment
|
|
68
|
+
* graph. When `req.include_pricing`, include vendor pricing options
|
|
69
|
+
* on each creative.
|
|
70
|
+
*/
|
|
71
|
+
listCreatives(req: ListCreativesRequest, ctx: Ctx<TCtxMeta>): Promise<ListCreativesResponse>;
|
|
72
|
+
/**
|
|
73
|
+
* Per-creative delivery actuals (impressions, spend, pacing). Sync —
|
|
74
|
+
* report-running platforms with manual report cycles return the
|
|
75
|
+
* latest cached actuals and emit `delivery_report` status changes
|
|
76
|
+
* via `publishStatusChange` when fresh reports are available.
|
|
77
|
+
*/
|
|
78
|
+
getCreativeDelivery(filter: GetCreativeDeliveryRequest, ctx: Ctx<TCtxMeta>): Promise<GetCreativeDeliveryResponse>;
|
|
79
|
+
}
|
|
80
|
+
export {};
|
|
81
|
+
//# sourceMappingURL=creative-ad-server.d.ts.map
|