Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/response-adcp-version-echo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"adcontextprotocol": patch
---

Every task response schema now accepts and declares the `adcp_version` echo that `versioning.mdx` requires on every response (#8518). Closed responses that rejected it now declare `adcp_version` as a `$ref` to `core/version-envelope.json#/properties/adcp_version`: `control_media_buy`, `decline_proposals`, `get_media_buy_issue`, `report_media_buy_issue`, `list_collections`, `list_proposals`, and `media-buy-commitment-response.json`, which covers `buy_products` and `accept_proposal`. Open status payloads that tolerated it without declaring it now compose `core/version-envelope.json` via root `allOf`: `core/compact-task-working.json`, `core/compact-task-input-required.json`, and the non-compact `*-async-response-{submitted,working,input-required}` payloads. The `list_products` echo drops its `x-added-in: 3.3.0` marker because the echo is backported to 3.2.x. A conforming seller already emits the echo, so no seller becomes non-conformant; a malformed echo (for example `"3.3.0"`) now fails validation where these schemas declare it. `tests/response-version-echo.test.cjs` enumerates every tool's response and async status schemas from the tool registry and fails when one rejects the echo, leaves it undeclared, or declares it with a different shape.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
"test:storyboard-doc-parity": "node --test --test-force-exit --test-timeout=30000 tests/lint-universal-storyboard-doc-parity.test.cjs",
"test:v4-compatibility-registry": "node --test --test-force-exit --test-timeout=30000 tests/lint-v4-compatibility-registry.test.cjs",
"test:pagination-invariant": "node --test --test-force-exit --test-timeout=30000 tests/lint-pagination-invariant.test.cjs",
"test:version-envelope": "node --test --test-force-exit --test-timeout=30000 tests/lint-version-envelope.test.cjs tests/compact-version-envelope.test.cjs",
"test:version-envelope": "node --test --test-force-exit --test-timeout=30000 tests/lint-version-envelope.test.cjs tests/compact-version-envelope.test.cjs tests/response-version-echo.test.cjs",
"test:test-dynamic-imports": "node --test --test-force-exit --test-timeout=30000 tests/lint-test-dynamic-imports.test.cjs",
"test:sdk-shims": "node --test --test-force-exit --test-timeout=30000 tests/lint-sdk-shims.test.cjs tests/sdk-runtime-compat.test.cjs",
"test:tenant-routing": "vitest run --config server/vitest.config.ts server/src/training-agent/tenants/tenant-smoke.test.ts",
Expand Down
3 changes: 3 additions & 0 deletions static/schemas/source/core/compact-task-input-required.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/core/compact-task-input-required.json",
"title": "Compact Task Input Required",
"description": "Bounded payload for a compact lifecycle task paused for buyer input or approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": { "type": "string", "minLength": 1, "maxLength": 200 },
Expand Down
3 changes: 3 additions & 0 deletions static/schemas/source/core/compact-task-working.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/core/compact-task-working.json",
"title": "Compact Task Working",
"description": "Bounded progress payload shared by the compact lifecycle tools.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": { "type": "number", "minimum": 0, "maximum": 100 },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/creative/get-creative-features-async-response-submitted.json",
"title": "Get Creative Features - Submitted",
"description": "Async acknowledgement returned after get_creative_features accepts a provider evaluation but cannot complete it within the response window. Exact keyed request replays return this original acknowledgement with replayed: true and the same task_id. In AdCP 3.x providers SHOULD also return evaluation_id; it becomes required in AdCP 4.0. When present, exact replays and terminal results preserve it. The caller polls get_task_status using task_id.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/creative/sync-creatives-async-response-input-required.json",
"title": "Sync Creatives - Input Required",
"description": "Payload when sync_creatives task is paused waiting for buyer clarification or approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/creative/sync-creatives-async-response-submitted.json",
"title": "Sync Creatives - Submitted",
"description": "Async task envelope returned when the whole sync_creatives operation cannot be confirmed before the response is emitted — for example, when the seller batches ingestion or when async review must settle before per-item results can be issued. The buyer invokes get_task_status with task_id or receives a webhook when the task completes; the creatives array lands in the terminal result, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/creative/sync-creatives-async-response-working.json",
"title": "Sync Creatives - Working",
"description": "Progress payload for active sync_creatives task.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/build-creative-async-response-input-required.json",
"title": "Build Creative - Input Required",
"description": "Payload when build_creative is paused waiting for user input. May occur during generation when the agent needs creative direction, or when brand guidelines require approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/build-creative-async-response-submitted.json",
"title": "Build Creative - Submitted",
"description": "Async task envelope returned when build_creative cannot be confirmed before the response — for example, when a slow generative pipeline or multi-minute LLM workflow is queued. The buyer invokes get_task_status with task_id or receives a webhook when the task completes; the creative_manifest(s) land in the terminal result, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/build-creative-async-response-working.json",
"title": "Build Creative - Working",
"description": "Progress payload for active build_creative task. Returned during AI generation, format transformation, or complex library retrieval with macro resolution.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"title": "Control Applied",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MUST FIX: adcp_version is added to all three oneOf arms here, but each arm is additionalProperties: false in 3.2.7 (dist/schemas/3.2.7/media-buy/control-media-buy-response.json) and stays closed in this PR. scripts/lint-additive-minor-corrections.json is empty and the baseline carries no entry for these, so the DR-0036 additive-minor lint reports property-added-to-closed for adcp_version on /oneOf/0,/oneOf/1,/oneOf/2. "Build and static checks" is red. DR-0036's own design requires either reopening these roots (correction (a), property *) or recording the adcp_version correction (b) in corrections.json plus the DR-0036 table — the correction entries #8523 was meant to add are missing. Same gap on decline-proposals-response.json and media-buy-commitment-response.json.

"status": { "type": "string", "const": "completed" },
"media_buy_id": { "type": "string", "minLength": 1, "x-entity": "media_buy" },
"revision": { "type": "integer", "minimum": 1 },
Expand Down Expand Up @@ -54,6 +55,7 @@
"title": "Control Error",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"status": { "type": "string", "const": "failed" },
"errors": { "type": "array", "items": { "$ref": "/schemas/core/error.json" }, "minItems": 1 },
"context": { "$ref": "/schemas/core/context.json" },
Expand All @@ -68,6 +70,7 @@
"title": "Control Submitted",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"status": { "type": "string", "const": "submitted" },
"task_id": { "type": "string", "minLength": 1, "x-entity": "task" },
"message": { "type": "string", "maxLength": 2000 },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/create-media-buy-async-response-input-required.json",
"title": "Create Media Buy - Input Required",
"description": "Payload when task is paused waiting for user input or approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/create-media-buy-async-response-submitted.json",
"title": "Create Media Buy - Submitted",
"description": "Async task envelope returned when create_media_buy cannot be confirmed before the response is emitted. The buyer invokes get_task_status with task_id or receives a webhook when the task completes; the media_buy_id and packages land in the terminal result, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/create-media-buy-async-response-working.json",
"title": "Create Media Buy - Working",
"description": "Progress payload for active create_media_buy task.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
}
],
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MUST FIX: This root is additionalProperties: false in 3.2.7 and stays closed here, so adding adcp_version is a property-added-to-closed change under DR-0036. With corrections.json empty and no baseline entry, the additive-minor lint fails. Reopen the root (correction (a)) or record the adcp_version correction (b) in scripts/lint-additive-minor-corrections.json and the DR-0036 Corrections table.

"results": {
"type": "array",
"minItems": 0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
{
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"const": "found"
Expand All @@ -35,6 +36,7 @@
{
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"const": "failed"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/get-products-async-response-input-required.json",
"title": "Get Products - Input Required",
"description": "Payload when search is paused waiting for user clarification.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/get-products-async-response-submitted.json",
"title": "Get Products - Submitted",
"description": "Async task envelope returned when get_products cannot be confirmed before the response — for example, when custom or bespoke product curation is queued for processing. This envelope is valid only for `buying_mode: \"brief\"` and `buying_mode: \"refine\"`; `buying_mode: \"wholesale\"` is a synchronous wholesale product feed read and MUST NOT use the Submitted arm. The buyer can always poll `get_task_status` (legacy `tasks/get`) with `task_id`. If the originating request carried `push_notification_config`, the seller also delivers at least the terminal completion/failure notification to that webhook URL; intermediate progress notifications are MAY. The products array lands on the completion artifact, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/get-products-async-response-working.json",
"title": "Get Products - Working",
"description": "Progress payload for active get_products task.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,8 @@
"title": "Unavailable lookup",
"type": "object",
"properties": {
"adcp_version": { "type": "string" },
"adcp_major_version": { "type": "integer" },
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"adcp_major_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_major_version" },
"status": { "type": "string", "const": "failed" },
"view": { "enum": ["summary", "periods", "revision"] },
"failure_kind": { "type": "string", "const": "lookup_unavailable" },
Expand Down Expand Up @@ -194,8 +194,8 @@
"title": "Operational failure",
"type": "object",
"properties": {
"adcp_version": { "type": "string" },
"adcp_major_version": { "type": "integer" },
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"adcp_major_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_major_version" },
"status": { "type": "string", "const": "failed" },
"view": { "enum": ["summary", "periods", "revision"] },
"failure_kind": { "type": "string", "const": "operational" },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"propertyName": "outcome"
},
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"enum": ["listed", "unchanged"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"propertyName": "outcome"
},
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version", "x-added-in": "3.3.0" },
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"enum": ["listed", "unchanged"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"description": "One page of proposals for the requested account with their seller-tracked dispositions, plus the current state of every opportunity those proposals belong to. Each snapshot is returned byte-for-byte as issued, so terms_digest still verifies; lifecycle state lives beside it, never inside it. Experimental (media_buy.open_opportunities).",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": { "type": "string", "const": "listed" },
"proposals": {
"type": "array",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
}
},
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MUST FIX: adcp_version is added to the closed commitment arms here (and at the error/submitted arms, new lines ~130 and ~149). This schema is additionalProperties: false per arm in 3.2.7 and stays closed, so each addition is property-added-to-closed under DR-0036. Only /oneOf/2's expected_confirmation_at is baselined; adcp_version is not. With corrections.json empty, the additive-minor lint fails. Reopen (correction (a)) or record the correction (b) entries.

"status": { "type": "string", "const": "completed" },
"media_buy_id": {
"type": "string",
Expand Down Expand Up @@ -126,6 +127,7 @@
"title": "Commitment Error",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"status": { "type": "string", "const": "failed" },
"errors": {
"type": "array",
Expand All @@ -144,6 +146,7 @@
"title": "Commitment Submitted",
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"status": { "type": "string", "const": "submitted" },
"task_id": { "type": "string", "minLength": 1, "x-entity": "task" },
"message": { "type": "string", "maxLength": 2000 },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
{
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"const": "recorded"
Expand All @@ -35,6 +36,7 @@
{
"type": "object",
"properties": {
"adcp_version": { "$ref": "/schemas/core/version-envelope.json#/properties/adcp_version" },
"outcome": {
"type": "string",
"const": "failed"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/sync-catalogs-async-response-input-required.json",
"title": "Sync Catalogs - Input Required",
"description": "Payload when sync_catalogs task is paused waiting for buyer clarification or approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/sync-catalogs-async-response-submitted.json",
"title": "Sync Catalogs - Submitted",
"description": "Async task envelope returned when sync_catalogs cannot be confirmed before the response — for example, when catalog ingestion and deduplication are queued for batch processing. The buyer invokes get_task_status with task_id or receives a webhook when the task completes; the per-catalog results land in the terminal result, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/sync-catalogs-async-response-working.json",
"title": "Sync Catalogs - Working",
"description": "Progress payload for active sync_catalogs task.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/update-media-buy-async-response-input-required.json",
"title": "Update Media Buy - Input Required",
"description": "Payload when update_media_buy task is paused waiting for user input or approval.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"reason": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/update-media-buy-async-response-submitted.json",
"title": "Update Media Buy - Submitted",
"description": "Async task envelope returned when update_media_buy cannot be confirmed before the response — for example, when operator re-approval is required for mid-flight changes. The buyer invokes get_task_status with task_id or receives a webhook when the task completes; the updated media buy state lands in the terminal result, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/media-buy/update-media-buy-async-response-working.json",
"title": "Update Media Buy - Working",
"description": "Progress payload for active update_media_buy task.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/signals/get-signals-async-response-submitted.json",
"title": "Get Signals - Submitted",
"description": "Async task envelope returned when get_signals cannot be confirmed before the response — for example, when semantic discovery depends on slow provider queries or review. This envelope is valid only for `discovery_mode: \"brief\"`; `discovery_mode: \"wholesale\"` is a synchronous wholesale signals feed read and MUST NOT use the Submitted arm. The caller can always poll `get_task_status` (legacy `tasks/get`) with `task_id`. If the originating request carried `push_notification_config`, the agent also delivers at least the terminal completion/failure notification to that webhook URL; intermediate progress notifications are MAY. The signals array lands on the completion artifact, not this envelope.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"status": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"$id": "/schemas/signals/get-signals-async-response-working.json",
"title": "Get Signals - Working",
"description": "Progress payload for an active get_signals task after a submitted semantic discovery request has started processing. Valid only for `discovery_mode: \"brief\"`; wholesale signals feed reads report partial completion via `incomplete[]`, not async task progress.",
"allOf": [
{ "$ref": "/schemas/core/version-envelope.json" }
],
"type": "object",
"properties": {
"percentage": {
Expand Down
Loading
Loading