Skip to content

feat(media-buy): resolve seller acceptance-policy catalogs #1069

Description

@bokelley

Summary

Add Python SDK parity for seller acceptance-policy catalog discovery from adcontextprotocol/adcp#6749 and adcontextprotocol/adcp#6794.

Required behavior

  • Generate models for acceptance context, catalogs, profile references, profiles, requirements, and rules.
  • Safely fetch the advertised HTTPS catalog with no credentials or redirects, public-address/DNS protections, and response/time bounds.
  • Verify catalog_digest against exact response bytes before parsing and schema/model validation.
  • Resolve seller-default and product profile IDs with cross-list uniqueness and exact policy/profile version and digest checks.
  • Compose rules restrictively and preserve unknown for partial coverage, omissions, unavailable catalogs, and undisclosed seller policy.
  • Expose an idiomatic buyer helper that explains likely allowed, prohibited, requires_disclosure, requires_setup, and requires_review outcomes while clearly marking discovery as advisory.
  • Cache within the advertised capability lifetime and support capabilities-change invalidation.

Compatibility and tests

  • valid reference-seller catalog and cross-SDK golden fixtures;
  • exact-byte digest mismatch;
  • redirects, URL credentials, private addresses, DNS rebinding, timeout, and oversized bodies;
  • duplicate IDs and unresolved or digest-mismatched policy/profile pins;
  • complete vs. partial coverage and restrictive default/product composition;
  • stable, typed diagnostics for fetch, safety, digest, schema, and resolution failures.

Acceptance criteria

  • Python buyers get the same normalized acceptance assessment as JavaScript buyers from identical capability, product, catalog, and context inputs.
  • Missing or undisclosed information never becomes an implicit allow decision.
  • Legacy sellers without the capability remain supported as unknown.

Upstream: adcontextprotocol/adcp#6749
Implementation: adcontextprotocol/adcp#6794

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions