Skip to content
Merged
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ repos:
- id: black
language_version: python3.11
args: [--line-length=100]
exclude: ^src/adcp/types/generated_poc/

# Ruff linting (ignoring line-length for now - black handles it)
- repo: https://github.com/astral-sh/ruff-pre-commit
Expand Down
10 changes: 1 addition & 9 deletions schemas/cache/account/get-account-financials-response.json
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,7 @@
"description": "Overall payment status. current: all obligations met. past_due: one or more invoices overdue. suspended: account suspended due to payment issues."
},
"payment_terms": {
"type": "string",
"enum": [
"net_15",
"net_30",
"net_45",
"net_60",
"net_90",
"prepay"
],
"$ref": "../enums/payment-terms.json",
"description": "Payment terms in effect for this account"
},
"invoices": {
Expand Down
19 changes: 3 additions & 16 deletions schemas/cache/account/sync-accounts-request.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,28 +35,15 @@
"pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$"
},
"billing": {
"type": "string",
"enum": [
"operator",
"agent",
"advertiser"
],
"description": "Who should be invoiced. operator: seller invoices the operator (agency or brand buying direct). agent: agent consolidates billing across brands. advertiser: seller invoices the advertiser directly, even when a different operator places orders on their behalf. The seller must either accept this billing model or reject the request."
"$ref": "../enums/billing-party.json",
"description": "Who should be invoiced. The seller must either accept this billing model or reject the request."
},
"billing_entity": {
"$ref": "../core/business-entity.json",
"description": "Business entity details for the party responsible for payment. The agent provides this so the seller has the legal name, tax IDs, address, and bank details needed for formal B2B invoicing."
},
"payment_terms": {
"type": "string",
"enum": [
"net_15",
"net_30",
"net_45",
"net_60",
"net_90",
"prepay"
],
"$ref": "../enums/payment-terms.json",
"description": "Payment terms for this account. The seller must either accept these terms or reject the account \u2014 terms are never silently remapped. When omitted, the seller applies its default terms."
},
"sandbox": {
Expand Down
26 changes: 3 additions & 23 deletions schemas/cache/account/sync-accounts-response.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,27 +59,15 @@
"description": "Account status. active: ready for use. pending_approval: seller reviewing (credit, legal). rejected: seller declined the account request. payment_required: credit limit reached or funds depleted. suspended: was active, now paused. closed: was active, now terminated."
},
"billing": {
"type": "string",
"enum": [
"operator",
"agent",
"advertiser"
],
"$ref": "../enums/billing-party.json",
"description": "Who is invoiced on this account. Matches the requested billing model."
},
"billing_entity": {
"$ref": "../core/business-entity.json",
"description": "Business entity details for the party responsible for payment, echoed from the request. Sellers MAY add fields the agent omitted (e.g., filling in registration_number from a credit check), but MUST NOT return data from a different entity. Bank details are omitted (write-only)."
},
"account_scope": {
"type": "string",
"enum": [
"operator",
"brand",
"operator_brand",
"agent"
],
"description": "How the seller scoped this account. operator: shared across all brands for this operator. brand: shared across all operators for this brand. operator_brand: dedicated to this operator+brand pair. agent: the agent's default account."
"$ref": "../enums/account-scope.json"
},
"setup": {
"type": "object",
Expand Down Expand Up @@ -110,15 +98,7 @@
"description": "Rate card applied to this account"
},
"payment_terms": {
"type": "string",
"enum": [
"net_15",
"net_30",
"net_45",
"net_60",
"net_90",
"prepay"
],
"$ref": "../enums/payment-terms.json",
"description": "Payment terms agreed for this account. When the account is active, these are the binding terms for all invoices on this account."
},
"credit_limit": {
Expand Down
28 changes: 14 additions & 14 deletions schemas/cache/adagents.json
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized agent's API endpoint URL"
"description": "The authorized agent's API endpoint URL. Callers looking up an agent against this list (e.g., TMP providers validating `seller_agent.agent_url`) MUST compare using the AdCP URL canonicalization rules, not byte-equality \u2014 two URLs that differ only in case, default port, or percent-encoding of unreserved characters are the same agent. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -269,7 +269,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized agent's API endpoint URL"
"description": "The authorized agent's API endpoint URL. Callers looking up an agent against this list (e.g., TMP providers validating `seller_agent.agent_url`) MUST compare using the AdCP URL canonicalization rules, not byte-equality \u2014 two URLs that differ only in case, default port, or percent-encoding of unreserved characters are the same agent. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -379,7 +379,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized agent's API endpoint URL"
"description": "The authorized agent's API endpoint URL. Callers looking up an agent against this list (e.g., TMP providers validating `seller_agent.agent_url`) MUST compare using the AdCP URL canonicalization rules, not byte-equality \u2014 two URLs that differ only in case, default port, or percent-encoding of unreserved characters are the same agent. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -489,7 +489,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized agent's API endpoint URL"
"description": "The authorized agent's API endpoint URL. Callers looking up an agent against this list (e.g., TMP providers validating `seller_agent.agent_url`) MUST compare using the AdCP URL canonicalization rules, not byte-equality \u2014 two URLs that differ only in case, default port, or percent-encoding of unreserved characters are the same agent. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -600,7 +600,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized signals agent's API endpoint URL"
"description": "The authorized signals agent's API endpoint URL. Callers comparing this URL against a signal-provider registry MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -654,7 +654,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The authorized signals agent's API endpoint URL"
"description": "The authorized signals agent's API endpoint URL. Callers comparing this URL against a signal-provider registry MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"authorized_for": {
"type": "string",
Expand Down Expand Up @@ -719,7 +719,7 @@
"url": {
"type": "string",
"format": "uri",
"description": "The agent's API endpoint URL"
"description": "The agent's API endpoint URL. Callers comparing this URL against a feature-provider registry MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"name": {
"type": "string",
Expand Down Expand Up @@ -785,12 +785,12 @@
],
"examples": [
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"authoritative_location": "https://cdn.example.com/adagents/v2/adagents.json",
"last_updated": "2025-01-15T10:00:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"properties": [
{
"property_id": "example_site",
Expand Down Expand Up @@ -868,7 +868,7 @@
"last_updated": "2025-01-10T12:00:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"contact": {
"name": "Meta Advertising Operations",
"email": "adops@meta.com",
Expand Down Expand Up @@ -977,7 +977,7 @@
"last_updated": "2025-01-10T15:30:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"contact": {
"name": "Tumblr Advertising"
},
Expand Down Expand Up @@ -1016,7 +1016,7 @@
"last_updated": "2025-01-10T16:00:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"contact": {
"name": "Example Third-Party Sales Agent",
"email": "sales@agent.example",
Expand Down Expand Up @@ -1062,7 +1062,7 @@
"last_updated": "2025-01-10T17:00:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"contact": {
"name": "Premium News Publisher",
"email": "adops@news.example.com",
Expand Down Expand Up @@ -1137,7 +1137,7 @@
"last_updated": "2025-01-10T18:00:00Z"
},
{
"$schema": "/schemas/3.0.0/adagents.json",
"$schema": "/schemas/3.0.1/adagents.json",
"contact": {
"name": "Polk Automotive Data",
"email": "partnerships@polk.com",
Expand Down
18 changes: 9 additions & 9 deletions schemas/cache/brand.json
Original file line number Diff line number Diff line change
Expand Up @@ -831,7 +831,7 @@
"type": "string",
"format": "uri",
"pattern": "^https://",
"description": "Brand agent MCP endpoint URL"
"description": "Brand agent MCP endpoint URL. Callers comparing this URL against another value (e.g., resolving 'is this the brand's declared agent?' against a discovery cache) MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"id": {
"type": "string",
Expand All @@ -853,7 +853,7 @@
"type": "string",
"format": "uri",
"pattern": "^https://",
"description": "Rights agent MCP endpoint URL"
"description": "Rights agent MCP endpoint URL. Callers comparing this URL against another value (e.g., matching against a brand's declared rights endpoint) MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"id": {
"type": "string",
Expand Down Expand Up @@ -904,7 +904,7 @@
"type": "string",
"format": "uri",
"pattern": "^https://",
"description": "Agent endpoint URL (MCP or A2A)"
"description": "Agent endpoint URL (MCP or A2A). Callers comparing a brand's declared agent URL against another value (e.g., resolving 'is this the agent that signed this artifact?' or matching against a discovery cache) MUST canonicalize both sides per the AdCP URL canonicalization rules, not byte-equality. See docs/reference/url-canonicalization."
},
"id": {
"type": "string",
Expand Down Expand Up @@ -2032,16 +2032,16 @@
],
"examples": [
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"authoritative_location": "https://adcontextprotocol.org/brand/abc123/brand.json"
},
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"house": "nikeinc.com",
"note": "Redirect to house domain for full brand portfolio"
},
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"version": "1.0",
"agents": [
{
Expand All @@ -2052,7 +2052,7 @@
]
},
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"version": "1.0",
"house": {
"domain": "pg.com",
Expand Down Expand Up @@ -2358,7 +2358,7 @@
"last_updated": "2026-01-15T10:00:00Z"
},
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"version": "1.0",
"house": {
"domain": "nikeinc.com",
Expand Down Expand Up @@ -2527,7 +2527,7 @@
"last_updated": "2026-01-15T10:00:00Z"
},
{
"$schema": "/schemas/3.0.0/brand.json",
"$schema": "/schemas/3.0.1/brand.json",
"version": "1.0",
"house": {
"domain": "mediavine.com",
Expand Down
4 changes: 2 additions & 2 deletions schemas/cache/brand/acquire-rights-request.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"estimated_impressions": {
"type": "integer",
"minimum": 0,
"description": "Estimated total impressions for the campaign"
"description": "Estimated total impressions for the campaign. Required when the request carries an intent-phase governance_context token AND the selected pricing_option has model: 'cpm' \u2014 the brand agent projects commitment as (pricing_option.price / 1000) \u00d7 estimated_impressions evaluated in pricing_option.currency. Brand agents MUST reject with INVALID_REQUEST (field: campaign.estimated_impressions) when CPM-priced rights are requested under a governance_context and this field is omitted or zero; implementer-chosen defaults are non-conformant. See the acquire_rights task reference for the full validation contract including currency-mismatch handling."
},
"start_date": {
"type": "string",
Expand All @@ -70,7 +70,7 @@
"end_date": {
"type": "string",
"format": "date",
"description": "Campaign end date (ISO 8601)"
"description": "Campaign end date (ISO 8601). Brand agents MUST reject with INVALID_REQUEST (field: campaign.end_date) when end_date is in the past at the time of the request \u2014 acquiring rights for an elapsed window produces a zero-duration grant and is almost always a buyer-side bug."
}
},
"required": [
Expand Down
10 changes: 1 addition & 9 deletions schemas/cache/brand/rights-pricing-option.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,7 @@
"minItems": 1
},
"period": {
"type": "string",
"enum": [
"daily",
"weekly",
"monthly",
"quarterly",
"annual",
"one_time"
],
"$ref": "../enums/rights-billing-period.json",
"description": "Billing period for flat_rate and time-based models"
},
"impression_cap": {
Expand Down
10 changes: 1 addition & 9 deletions schemas/cache/brand/rights-terms.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,7 @@
"pattern": "^[A-Z]{3}$"
},
"period": {
"type": "string",
"enum": [
"daily",
"weekly",
"monthly",
"quarterly",
"annual",
"one_time"
]
"$ref": "../enums/rights-billing-period.json"
},
"uses": {
"type": "array",
Expand Down
Loading
Loading