Skip to content

JSON schemas for registry change-feed event payloads (wholesale feed covered) #4792

Closed

Description

@bokelley

Why

Both specs/catalog-change-feed.md (landed in PR #4767) and specs/registry-change-feed.md (shipped) define event payload shapes in markdown prose + examples only — there is no static/schemas/source/core/catalog-event.json or per-event-type schema for product.priced, signal.priced, *.removed, catalog.bulk_change, applies_to, removal_reason, previous_pricing_option_ids, etc.

Surfaced during second-pass review of PR #4767. Quote: "the capability stanza enumerates event types but no schema exists. Without a schema, conformance runs can't validate event payloads and removal_reason is unenforced."

The catalog feed and registry feed share this gap. Spec'ing them together keeps the two surfaces parallel.

Scope

Catalog feed (PR #4767 surface)

Define a discriminated core/catalog-event.json keyed on event_type:

  • product.created, product.updated, product.priced, product.removed
  • signal.created, signal.updated, signal.priced, signal.removed
  • catalog.bulk_change

Each event payload needs:

  • event_id (UUID v7), event_type, entity_type, entity_id, created_at
  • Type-specific payload union, validating fields like:
    • applies_to: { scope: \"public\" | \"account\", account_ids?: string[] } — discriminator on scope
    • removal_reason enum: withdrawn / cancellation / expired / depublication / policy_takedown
    • previous_pricing_option_ids: string[]
    • changed_fields: string[]
    • effective_at: string (date-time)
    • For *.updated / *.priced: full or partial entity payload
    • For catalog.bulk_change: summary, affected_entity_types[], affected_count, recommendation

Conformance: response from GET /catalog/events validates against the schema; SDKs (@adcp/client's CatalogSync) consume the schema rather than parsing prose.

Registry feed (existing, parallel work)

Same treatment for the events in specs/registry-change-feed.md:

  • property.created, property.updated, property.merged, property.stale, property.reactivated
  • agent.discovered, agent.removed, agent.profile_updated, agent.compliance_changed
  • publisher.adagents_changed
  • authorization.granted, authorization.revoked

The registry feed's agent.compliance_changed and authorization.granted payloads are the most field-heavy (tracks, storyboards, full authorization scoping model) — those are the priority for schema treatment because consumers (TMP routers, RegistrySync clients) make routing decisions off them.

Acceptance

  • core/catalog-event.json + per-event-type variants live in static/schemas/source/core/
  • core/registry-event.json + per-event-type variants ditto
  • GET /catalog/events and GET /api/registry/feed responses cite the event schemas
  • Conformance assertion: events in storyboard fixtures validate against schemas
  • SDK type generation picks up the new schemas (TS first, then Go and Python)

Dependencies

Related

Activity

  1. added
    claude-triaging
    on May 19, 2026
  2. bokelley commented on May 19, 2026

    @bokelley
    ContributorAuthor

    Triage

    Classification: Feature request (schema addition)
    Bucket(s): spec / protocol, registry / discovery
    Status: deferred

    Blocked-on: #4767 — resurfaces on merge


    Triaged by Claude Code. Session: https://claude.ai/code/session_01DZRgqy3RL17LepL6pBaSqo


    Generated by Claude Code

  3. added
    claude-triaged
    schema
    and removed
    claude-triaging
    on May 19, 2026
  4. added this to the 3.1.0 milestone on May 22, 2026
  5. bokelley commented on May 27, 2026

    @bokelley
    ContributorAuthor

    Status update after the v3.1 catalog-sync merge:

    • The catalog/wholesale-feed side is now covered on main by static/schemas/source/core/wholesale-feed-event.json plus static/schemas/source/core/wholesale-feed-webhook.json. Those schemas cover product.*, signal.*, wholesale_feed.bulk_change, applies_to, removal_reason, previous_pricing_option_ids, and the enclosing account-level webhook payload.
    • The remaining gap is the registry change-feed side. specs/registry-change-feed.md still defines property.*, agent.*, publisher.adagents_changed, authorization.*, and agent.compliance_changed payloads in prose/examples, but there is no corresponding registry feed event schema under static/schemas/source/.

    Leaving this open, narrowed to the registry payload schema work. The title has been updated accordingly.

  6. changed the title [-]JSON Schemas for change-feed event payloads (catalog + registry)[/-] [+]JSON schemas for registry change-feed event payloads (wholesale feed covered)[/+] on May 27, 2026
  7. added
    claude-triaging
    and removed
    claude-triaged
    on May 27, 2026
  8. bokelley commented on May 27, 2026

    @bokelley
    ContributorAuthor

    Triage

    Classification: Feature request (schema addition)
    Bucket(s): spec / protocol, registry / discovery
    Status: ready-to-implement
    Milestone: 3.1.0

    What the experts said:

    • ad-tech-protocol-expert: Discriminated-union pattern is sound; three spec ambiguities need answering before authoring — change_kind placement (two spec files conflict), authorization_type enum scope (v1-emitting variants unclear), tracks{} typing strategy in agent.compliance_changed.
    • adtech-product-expert: Ready to implement; authorization.granted/authorization.revoked shapes must be validated against server/tests/integration/registry-feed-authorization.test.ts — triggers emit agent_url_canonical, override_applied, override_reason absent from spec prose examples, so the schema must either include them or set additionalProperties: true.

    My take: Both experts confirm the approach and 3.1.0 placement are sound. Three spec questions need @bokelley's answer before authoring to prevent implementer divergence on the most field-heavy payload branches.

    Scope:

    • New static/schemas/source/core/registry-event.json — 12-branch discriminated union keyed on event_type, following wholesale-feed-event.json exactly; no applies_to (registry events are member-scoped)
    • signing_keys in authorization.granted → $ref agent-signing-key.json; MUST-NOT-trust language in description
    • Changeset: minor (new normative schema); main only, no 3.0.x cherry-pick

    Three questions before the PR opens:

    1. change_kind placement: registry-change-feed.md puts it inside payload; registry-authorization-model.md puts it at the envelope level alongside event_type. Which spec is authoritative?
    2. authorization_type enum: 6 variants are defined; which actually emit events in the 3.1.0 implementation — restrict the schema enum to those, or use an open string with a note?
    3. tracks{} shape: constrain track names to a defined enum, or keep record(string, string) with the enum only on per-track status values (pass/fail/degraded)?

    Triaged by Claude Code. Session: https://claude.ai/code/session_01RrNmCqxriUK1iFdpFx9KuM


    Generated by Claude Code

  9. added
    claude-triaged
    and removed
    claude-triaging
    on May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    claude-triagedschema

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions