{"openapi":"3.1.0","info":{"title":"SearchSeal API","version":"1.0.0","description":"Provider-independent AI-crawler observability. Every number is observed evidence: unknown is never presented as zero, an unobserved response is never presented as a status code, and totals equal the dashboard's totals for the same window and purpose filter."},"servers":[{"url":"https://api.searchseal.com"}],"security":[{"apiKey":[]}],"paths":{"/v1/sites":{"get":{"operationId":"listSites","summary":"Sites this API key can read","responses":{"200":{"description":"Site memberships.","content":{"application/json":{"schema":{"type":"object","required":["sites"],"properties":{"sites":{"type":"array","items":{"type":"object","required":["id","root_domain","role"],"properties":{"id":{"type":"string","format":"uuid","description":"Immutable site identifier — usable anywhere {site} appears in a path. Domains are mutable data."},"root_domain":{"type":"string"},"role":{"type":"string","enum":["owner","editor","viewer"]}}}}}}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/performance":{"get":{"operationId":"getPerformance","summary":"Totals, flat daily rows, and HTTP outcomes","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"purpose","in":"query","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string","enum":["search","assistant","training","unknown"]},"default":["search","assistant","unknown"]},"description":"Crawler purposes to include, comma-separated. Default search,assistant,unknown — training is opt-in, undeclared purpose is included, invalid values are a 400 (never silently corrected)."}],"responses":{"200":{"description":"Windowed performance.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Performance"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/crawlers":{"get":{"operationId":"getCrawlers","summary":"Per-crawler totals and shares","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"purpose","in":"query","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string","enum":["search","assistant","training","unknown"]},"default":["search","assistant","unknown"]},"description":"Crawler purposes to include, comma-separated. Default search,assistant,unknown — training is opt-in, undeclared purpose is included, invalid values are a 400 (never silently corrected)."}],"responses":{"200":{"description":"Per-crawler totals.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Crawlers"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/top-pages":{"get":{"operationId":"getTopPages","summary":"Ranked pages (capped, truncation explicit)","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"purpose","in":"query","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string","enum":["search","assistant","training","unknown"]},"default":["search","assistant","unknown"]},"description":"Crawler purposes to include, comma-separated. Default search,assistant,unknown — training is opt-in, undeclared purpose is included, invalid values are a 400 (never silently corrected)."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":50,"default":50}}],"responses":{"200":{"description":"Ranked pages.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TopPages"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/issues":{"get":{"operationId":"getIssues","summary":"Open issues (observed harm only)","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":50,"default":8}}],"responses":{"200":{"description":"Open issues.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Issues"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/sources":{"get":{"operationId":"getSources","summary":"Connected evidence sources","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."}],"responses":{"200":{"description":"Evidence sources.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Sources"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/overview":{"get":{"operationId":"getAnalyticsOverview","summary":"Tracker-only Overview with its canonical truth envelope","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Canonical tracker-only Overview. The primary/default response is analytics-overview/v1; the default-off server rollout may enable the additive analytics-overview/v2 contract.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsOverview"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Overview v2 uses the exact header record_type,meta_json,day,metric,value and losslessly reconstructs meta, current metrics, evidence-bearing trend rows, and comparison. A v2 rollback preserves the existing v1 four-column CSV byte-for-byte."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Overview reader disabled (title: analytics overview unavailable).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/analytics-sources":{"get":{"operationId":"getAnalyticsSources","summary":"Tracker-only acquisition and campaign Sources with a canonical truth envelope","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Canonical tracker-only acquisition, AI referral, and five-UTM Sources object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsSources"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 CSV with the exact header record_type,meta_json,dimension,identity_json,metric,value. It contains one meta row, a denominator row for null blocks and for the five UTM dimensions (number or null), and stable metric rows. Acquisition and AI referral rows carry no denominator, matching the canonical object."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Analytics Sources reader disabled (title: analytics sources unavailable).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/pages":{"get":{"operationId":"getAnalyticsPages","summary":"Hostname-aware tracker Pages with independent crawler evidence truth","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":50},"description":"Maximum tracker Page identities returned after canonical ordering."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Canonical hostname-aware tracker Pages with independent crawler evidence state.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsPages"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 CSV with the exact header record_type,meta_json,hostname,path,path_fidelity,payload_json. Stable meta, summary, Page, and crawler-pattern records reconstruct the canonical JSON object exactly."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Analytics Pages reader disabled (title: analytics pages unavailable).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/conversions":{"get":{"operationId":"getAnalyticsConversions","summary":"Configured named-Event or exact privacy-safe Pageview Conversion revisions","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"],"default":"30d"},"description":"UTC day window ending today."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100},"description":"Maximum immutable revision rows selected before metric joins."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Canonical configured named-Event Conversion revision rows.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsConversions"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 with exact header record_type,meta_json,conversion_json,source_json and fixed record order: meta, conversion, conversion_property_rule, conversion_source."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Conversions reader disabled (title: analytics conversions unavailable).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/funnels":{"get":{"operationId":"getAnalyticsFunnels","summary":"Exact ordered same-session Funnel revision summaries","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d"],"default":"30d"},"description":"Exact Funnel evaluation window. Longer analytics windows are refused with 422, never truncated."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100}},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Visible immutable Funnel revision summaries.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsFunnels"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 with exact header record_type,meta_json,funnel_json and stable meta, funnel record order."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"422":{"description":"The requested analytics window exceeds 30 days.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Funnel reader disabled or its strict evidence snapshot is unavailable.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/funnels/{funnel}":{"get":{"operationId":"getAnalyticsFunnel","summary":"One exact Funnel revision with ordered step prefixes","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"funnel","in":"path","required":true,"schema":{"type":"string","minLength":34,"maxLength":64,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*-[0-9a-f]{32}$"},"description":"Immutable public Funnel slug."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d"],"default":"30d"},"description":"Exact Funnel evaluation window. Longer analytics windows are refused with 422, never truncated."},{"name":"revision","in":"query","schema":{"type":"integer","minimum":1,"maximum":2147483647},"description":"Exact immutable revision. Omit for the current active or latest archived revision."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"One exact Funnel revision and its ordered step prefixes.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsFunnel"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 with exact header record_type,meta_json,funnel_json,step_json and stable meta, funnel, funnel_step record order."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"422":{"description":"The requested analytics window exceeds 30 days.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Funnel reader disabled or its strict evidence snapshot is unavailable.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/journeys":{"get":{"operationId":"getAnalyticsJourneys","summary":"Privacy-safe aggregate Pageview sequences from closed tracker sessions","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d"],"default":"30d"},"description":"Exact Journey evaluation window. Longer analytics windows are refused with 422, never truncated."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100},"description":"Maximum individually displayable sequence rows. The grouped privacy row does not consume this limit."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Privacy-safe aggregate Pageview sequences from closed tracker sessions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsJourneys"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 with exact header record_type,meta_json,journey_json and stable meta, journey record order."}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"422":{"description":"The requested analytics window exceeds 30 days.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Journey reader disabled or its strict evidence snapshot is unavailable.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/revenue":{"get":{"operationId":"getAnalyticsRevenue","summary":"Customer-Reported revenue by currency with reconciliation truth","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."},{"name":"window","in":"query","schema":{"type":"string","enum":["3d","7d","30d"],"default":"30d"},"description":"Exact Reported-revenue window. Longer analytics windows are refused with 400, never truncated."},{"name":"format","in":"query","schema":{"type":"string","enum":["json","csv"],"default":"json"},"description":"Response encoding. JSON returns the canonical object; CSV is a lossless RFC 4180 representation of it."}],"responses":{"200":{"description":"Customer-Reported revenue by currency with browser/server provenance and bounded reconciliation diagnostics. It is not payment-provider verification.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsRevenue"}},"text/csv; charset=utf-8":{"schema":{"type":"string"},"description":"Lossless RFC 4180 with exact header record_type,meta_json,reconciliation_json,reported_json and stable meta, reconciliation, reported record order."}}},"400":{"description":"Invalid parameters, including any analytics window longer than 30 days.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"503":{"description":"Reported-revenue reader disabled or its strict snapshot is unavailable.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/v1/sites/{site}/access-checks":{"post":{"operationId":"runAccessCheck","summary":"Live policy check for one URL (current state only)","parameters":[{"name":"site","in":"path","required":true,"schema":{"type":"string"},"description":"Site id (uuid, immutable — preferred) or root domain, e.g. dino.markets."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["url"],"properties":{"url":{"type":"string","format":"uri","pattern":"^[Hh][Tt][Tt][Pp][Ss]?://","description":"HTTP or HTTPS URL on this site."}}}}}},"responses":{"200":{"description":"Current policy evidence.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessCheck"}}}},"400":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"401":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"405":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}},"headers":{"Allow":{"schema":{"type":"string"},"description":"Methods supported by this resource."}}},"422":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"500":{"description":"Error (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}}},"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"ssk_read_ API key from the dashboard. It grants reads plus owner-gated fix verification."}},"schemas":{"Problem":{"type":"object","required":["title","status"],"properties":{"type":{"type":"string"},"title":{"type":"string"},"status":{"type":"integer"},"detail":{"type":"string"}}},"Meta":{"type":"object","required":["as_of","window","coverage_state","purpose_filter","registry_version","sources","data_through","gaps"],"properties":{"as_of":{"type":"string","format":"date-time","description":"Instant this response was computed. Surfaces queried seconds apart can differ by live ingestion; compare as_of before comparing totals."},"coverage_state":{"type":"string","enum":["complete","partial","unknown"],"description":"THE truth signal — read this before any count. unknown: no primary source has ever reported; every count in this response is null, never zero. partial: coverage exists but is impaired in this window (gap days, backfilled days, a partial or sampled source). complete: full coverage. Under crawler authority v2, a computed zero is null unless every assigned host/day is complete, unsampled, uncapped, and gap-free."},"registry_version":{"type":["string","null"],"description":"Crawler-registry version that labeled purposes/identities in this response. A registry change re-labels history."},"window":{"type":"object","required":["from","to","timezone"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"},"timezone":{"type":"string","const":"UTC"}}},"purpose_filter":{"type":"array","items":{"type":"string","enum":["search","assistant","training","unknown"]},"description":"The effective (expanded) purpose filter this response was computed with."},"sources":{"type":"array","items":{"$ref":"#/components/schemas/Source"}},"data_through":{"type":["string","null"],"format":"date-time","description":"Freshest instant every primary source has reported through; null when unknown (never zero)."},"gaps":{"type":"array","items":{"type":"object","required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"description":"In-window day ranges where no primary source reported coverage — unknown, never zero traffic. Only meaningful when primary sources exist: with sources empty (data_through null) the ENTIRE window is unknown and gaps is empty — check sources/data_through before trusting any zero."},"authority":{"$ref":"#/components/schemas/CrawlerAuthority"}}},"CrawlerAuthority":{"type":"object","description":"Additive crawler-authority metadata, present only when the default-off v2 reader gate is enabled. Shadow diagnostics never contribute to totals.","required":["metric","evidence_state","available_from","hosts","shadow_diagnostics"],"properties":{"metric":{"type":"string","const":"observed_request_count"},"evidence_state":{"type":"string","enum":["complete","partial","gap","stale","unavailable","unknown"]},"available_from":{"type":["string","null"],"format":"date-time","description":"First v2 authority assignment boundary."},"hosts":{"type":"array","items":{"type":"object","required":["hostname","metric","authority_state","contract_revision_id","source_connection_id","provider","adapter","interval_start","interval_end","effective_boundary","available_from","evidence_state","sampling","path_fidelity","status_fidelity","limitation","coverage_limitations","disconnect"],"properties":{"hostname":{"type":"string"},"metric":{"type":"string","const":"observed_request_count"},"authority_state":{"type":"string","enum":["assigned","unknown"]},"contract_revision_id":{"type":["string","null"],"format":"uuid"},"source_connection_id":{"type":["string","null"],"format":"uuid"},"provider":{"type":["string","null"]},"adapter":{"type":["string","null"]},"interval_start":{"type":"string","format":"date-time"},"interval_end":{"type":"string","format":"date-time"},"effective_boundary":{"type":["string","null"],"format":"date-time"},"available_from":{"type":["string","null"],"format":"date-time"},"evidence_state":{"type":"string","enum":["complete","partial","gap","stale","unavailable","unknown"]},"sampling":{"type":["number","null"],"minimum":0,"maximum":1},"path_fidelity":{"type":["string","null"],"enum":["exact","grouped","unavailable",null]},"status_fidelity":{"type":["string","null"],"enum":["exact","grouped","unavailable",null]},"limitation":{"type":["string","null"]},"coverage_limitations":{"type":"array","items":{"type":"string"}},"disconnect":{"oneOf":[{"type":"null"},{"type":"object","required":["interruption_id","disconnected_at","effective_at"],"properties":{"interruption_id":{"type":"string","format":"uuid"},"disconnected_at":{"type":"string","format":"date-time"},"effective_at":{"type":"string","format":"date-time"}}}]}}}},"shadow_diagnostics":{"type":"array","description":"Exact overlap diagnostics only. comparable=false names a reason; delta is null. These values never enter crawler totals.","items":{"type":"object","required":["hostname","metric","day","authority_contract_revision_id","shadow_contract_revision_id","authority_provider","shadow_provider","interval_start","interval_end","authority_coverage_state","shadow_coverage_state","eligible","comparable","exact_equal","reason","authority_count","shadow_count","delta"],"properties":{"hostname":{"type":"string"},"metric":{"type":"string","const":"observed_request_count"},"day":{"type":"string","format":"date"},"authority_contract_revision_id":{"type":["string","null"],"format":"uuid"},"shadow_contract_revision_id":{"type":"string","format":"uuid"},"authority_provider":{"type":["string","null"]},"shadow_provider":{"type":"string"},"interval_start":{"type":"string","format":"date-time"},"interval_end":{"type":"string","format":"date-time"},"authority_coverage_state":{"type":"string","enum":["complete","partial","gap","stale","unavailable","unknown"]},"shadow_coverage_state":{"type":"string","enum":["complete","partial","gap","stale","unavailable","unknown"]},"eligible":{"type":"boolean"},"comparable":{"type":"boolean"},"exact_equal":{"type":["boolean","null"]},"reason":{"type":["string","null"]},"authority_count":{"type":["integer","null"],"minimum":0},"shadow_count":{"type":["integer","null"],"minimum":0},"delta":{"type":["integer","null"]}}}}}},"Source":{"type":"object","required":["id","source_type","connection_status","is_primary","connected_at","data_through","evidence_from","backfill","hostname_coverage","completeness","sampling","http_status_fidelity"],"properties":{"id":{"type":"string","format":"uuid"},"source_type":{"type":"string","enum":["cloudflare_zone","https_intake","log_upload"]},"connection_status":{"type":"string","enum":["pending","live","error","revoked","disconnected"]},"is_primary":{"type":"boolean","description":"Legacy reader-off selection. When crawler authority v2 is enabled, meta.authority is the counting truth and this field remains rollback provenance only."},"connected_at":{"type":["string","null"],"format":"date-time"},"data_through":{"type":["string","null"],"format":"date-time"},"evidence_from":{"type":["string","null"],"format":"date","description":"Earliest evidence day this source holds; null when none yet."},"backfill":{"oneOf":[{"type":"object","required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},{"type":"null"}],"description":"Inclusive day range of provider backfill: evidence imported at connect time that PRECEDES the connection day, labeled from the actual evidence interval. History observed by SearchSeal starts at connected_at; backfilled days are the provider's history, not ours."},"hostname_coverage":{"type":"object","description":"Hostnames this source can and cannot see (source-declared).","properties":{"proxied":{"type":"array","items":{"type":"string"}},"unproxied":{"type":"array","items":{"type":"string"}},"checked_at":{"type":"string","format":"date-time"}}},"completeness":{"type":["string","null"],"enum":["complete","partial","unknown",null]},"sampling":{"type":["number","null"],"minimum":0,"maximum":1},"http_status_fidelity":{"type":["string","null"],"enum":["exact","grouped","unavailable",null]}}},"DailyRow":{"type":"object","required":["date","crawler_id","observed_request_count"],"properties":{"date":{"type":"string","format":"date"},"crawler_id":{"type":"string"},"observed_request_count":{"type":"integer","minimum":0}}},"Outcome":{"description":"Discriminated on `outcome`: a null http_status is STRUCTURALLY impossible under an observed class — only response_unobserved carries it.","oneOf":[{"type":"object","required":["outcome","observed_request_count","statuses"],"properties":{"outcome":{"type":"string","enum":["2xx","3xx","4xx","5xx","other"]},"observed_request_count":{"type":"integer","minimum":0},"statuses":{"type":"array","items":{"type":"object","required":["http_status","observed_request_count"],"properties":{"http_status":{"type":"integer","minimum":100},"observed_request_count":{"type":"integer","minimum":0}}}}}},{"type":"object","required":["outcome","observed_request_count","statuses"],"properties":{"outcome":{"type":"string","const":"response_unobserved","description":"The source saw the request but never the response — never folded into 2xx."},"observed_request_count":{"type":"integer","minimum":0},"statuses":{"type":"array","items":{"type":"object","required":["http_status","observed_request_count"],"properties":{"http_status":{"type":"null"},"observed_request_count":{"type":"integer","minimum":0}}}}}}]},"Crawler":{"type":"object","required":["crawler_id","platform","display_name","purpose","identity","observed_request_count","observed_share"],"properties":{"crawler_id":{"type":"string"},"platform":{"type":["string","null"]},"display_name":{"type":["string","null"]},"purpose":{"type":"string","enum":["search","assistant","training","unknown"],"description":"Vendor-declared via the registry; unknown when undeclared, never guessed."},"identity":{"type":"string","enum":["ua_identified","provider_verified","network_verified","unknown"],"description":"Aggregation never upgrades identity: mixed rows collapse to the weakest present."},"observed_request_count":{"type":"integer","minimum":0},"observed_share":{"type":"number","minimum":0,"maximum":1}}},"Page":{"type":"object","required":["host","path","observed_request_count","observed_share","observed_crawler_count","observed_response_count"],"properties":{"host":{"type":"string"},"path":{"type":"string"},"observed_request_count":{"type":"integer","minimum":0},"observed_share":{"type":"number","minimum":0,"maximum":1},"observed_crawler_count":{"type":"integer","minimum":0},"observed_response_count":{"type":"integer","minimum":0,"description":"Of the observed requests, how many had an HTTP response observed (request-only feeds see the request, never the response)."}}},"Performance":{"type":"object","required":["meta","observed_request_count","daily","http_outcomes"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"observed_request_count":{"type":["integer","null"],"minimum":0,"description":"Observed evidence in the window under the effective purpose filter — never claimed total crawler traffic. null when meta.coverage_state is unknown, and under authority v2 when zero is not proven by complete unsampled uncapped full-day host coverage."},"daily":{"type":"array","items":{"$ref":"#/components/schemas/DailyRow"}},"http_outcomes":{"type":"array","items":{"$ref":"#/components/schemas/Outcome"}}}},"Crawlers":{"type":"object","required":["meta","crawlers"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"crawlers":{"type":"array","items":{"$ref":"#/components/schemas/Crawler"}}}},"TopPages":{"type":"object","required":["meta","limit","returned_count","total_count","truncated","pages"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"limit":{"type":"integer"},"returned_count":{"type":"integer"},"total_count":{"type":["integer","null"],"minimum":0,"description":"Uncapped distinct-page count — a capped ranking always names the real total. null when coverage is unknown, and under authority v2 when zero is not proven by complete full-day host coverage."},"truncated":{"type":"boolean"},"pages":{"type":"array","items":{"$ref":"#/components/schemas/Page"}}}},"Issues":{"type":"object","required":["limit","returned_count","total_count","truncated","issues"],"properties":{"limit":{"type":"integer","minimum":1,"maximum":50},"returned_count":{"type":"integer","minimum":0},"total_count":{"type":"integer","minimum":0},"truncated":{"type":"boolean"},"issues":{"type":"array","items":{"type":"object","required":["id","title","state","cause","confidence","description","path","crawler_id","detected_at","fix_confirmed_at","evidence_refs","fix_prompt"],"properties":{"id":{"type":"string","format":"uuid"},"title":{"type":"string","description":"States the observation (\"received HTTP 405\"), never a conclusion."},"state":{"type":"string","enum":["open","fix_detected","regressed"],"description":"fix_detected means SearchSeal's own inspection came back clean. Fresh observed harm can move it to regressed."},"cause":{"type":"string","enum":["robots_rule","http_status","waf_or_challenge","redirect_chain","dns","tls","origin_error","unknown"],"description":"unknown is legal; an evidence-free assessment is not."},"confidence":{"type":"string","enum":["high","medium","low"]},"description":{"type":"string"},"path":{"type":["string","null"]},"crawler_id":{"type":["string","null"]},"detected_at":{"type":"string","format":"date-time"},"fix_confirmed_at":{"type":["string","null"],"format":"date-time","description":"Set only by subsequent organic evidence succeeding (layer 2) — never by our own inspection."},"evidence_refs":{"type":"array","minItems":1,"description":"Evidence-free assessments are illegal (DB-enforced non-empty).","items":{"oneOf":[{"type":"object","required":["kind","host","path_key","status","count","window"],"properties":{"kind":{"type":"string","enum":["rollup_daily","crawler_rollup_daily_v2"]},"host":{"type":"string"},"path_key":{"type":"string"},"status":{"type":"integer"},"count":{"type":"integer","minimum":1},"window":{"type":"string"}}},{"type":"object","required":["kind","id"],"properties":{"kind":{"type":"string","const":"inspection"},"id":{"type":"string","format":"uuid"}}}]}},"fix_prompt":{"type":["string","null"]}}}}}},"Sources":{"type":"object","required":["sources"],"properties":{"sources":{"type":"array","items":{"$ref":"#/components/schemas/Source"}},"authority":{"$ref":"#/components/schemas/CrawlerAuthority"}}},"AnalyticsFunnels":{"type":"object","additionalProperties":false,"required":["meta","funnels"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance","configuration","pagination"],"properties":{"contract_version":{"type":"string","const":"analytics-funnels/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to","cutoff"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"},"cutoff":{"type":"string","format":"date-time"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","evaluator_version","order_basis","session_scope"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"evaluator_version":{"type":"string","const":"funnel-evaluator/v1"},"order_basis":{"type":"string","const":"worker_receipt_time_then_persisted_funnel_order_v1"},"session_scope":{"type":"string","const":"same_utc_day_30_minute_inactivity"}}},"configuration":{"type":"object","additionalProperties":false,"required":["state","active_count"],"properties":{"state":{"type":"string","enum":["not_configured","configured"]},"active_count":{"type":"integer","minimum":0,"maximum":30}}},"pagination":{"type":"object","additionalProperties":false,"required":["limit","returned_count","total_count","truncated"],"properties":{"limit":{"type":"integer","minimum":1,"maximum":100},"returned_count":{"type":"integer","minimum":0,"maximum":100},"total_count":{"type":"integer","minimum":0},"truncated":{"type":"boolean"}}}}},"funnels":{"type":"array","maxItems":100,"items":{"type":"object","additionalProperties":false,"required":["slug","revision_id","revision","name","definition_state","effective_from","effective_to","step_count","evidence_state","evaluation_coverage","available_from","data_through","metrics","completeness"],"properties":{"slug":{"type":"string","minLength":34,"maxLength":64,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*-[0-9a-f]{32}$"},"revision_id":{"type":"string","format":"uuid"},"revision":{"type":"integer","minimum":1},"name":{"type":"string","minLength":1,"maxLength":64},"definition_state":{"type":"string","enum":["active","archived"]},"effective_from":{"type":"string","format":"date-time"},"effective_to":{"type":["string","null"],"format":"date-time"},"step_count":{"type":"integer","minimum":2,"maximum":5},"evidence_state":{"type":"string","enum":["not_effective","unknown","measured","partial","suppressed"]},"evaluation_coverage":{"type":"object","additionalProperties":false,"required":["state","raw_events","core_collection","conversion_steps","session_integrity","event_order","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"raw_events":{"type":"string","enum":["complete","partial","unknown"]},"core_collection":{"type":"string","enum":["complete","partial","unknown"]},"conversion_steps":{"type":"string","enum":["complete","partial","unknown","not_applicable"]},"session_integrity":{"type":"string","enum":["exact","ambiguous","unknown"]},"event_order":{"type":"string","enum":["exact","ambiguous","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"metrics":{"type":"object","additionalProperties":false,"required":["entered_sessions","entered_quality","completed_sessions","completed_quality","completion_rate"],"properties":{"entered_sessions":{"type":["integer","null"],"minimum":0},"entered_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"completed_sessions":{"type":["integer","null"],"minimum":0},"completed_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"completion_rate":{"type":["number","null"],"minimum":0,"maximum":1}}},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}}}}}}},"AnalyticsFunnel":{"type":"object","additionalProperties":false,"required":["meta","funnel"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance","configuration"],"properties":{"contract_version":{"type":"string","const":"analytics-funnel/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to","cutoff"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"},"cutoff":{"type":"string","format":"date-time"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","evaluator_version","order_basis","session_scope"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"evaluator_version":{"type":"string","const":"funnel-evaluator/v1"},"order_basis":{"type":"string","const":"worker_receipt_time_then_persisted_funnel_order_v1"},"session_scope":{"type":"string","const":"same_utc_day_30_minute_inactivity"}}},"configuration":{"type":"object","additionalProperties":false,"required":["state","active_count"],"properties":{"state":{"type":"string","enum":["not_configured","configured"]},"active_count":{"type":"integer","minimum":0,"maximum":30}}}}},"funnel":{"type":"object","additionalProperties":false,"required":["slug","revision_id","revision","name","definition_state","effective_from","effective_to","step_count","evidence_state","evaluation_coverage","available_from","data_through","metrics","completeness","steps"],"properties":{"slug":{"type":"string","minLength":34,"maxLength":64,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*-[0-9a-f]{32}$"},"revision_id":{"type":"string","format":"uuid"},"revision":{"type":"integer","minimum":1},"name":{"type":"string","minLength":1,"maxLength":64},"definition_state":{"type":"string","enum":["active","archived"]},"effective_from":{"type":"string","format":"date-time"},"effective_to":{"type":["string","null"],"format":"date-time"},"step_count":{"type":"integer","minimum":2,"maximum":5},"evidence_state":{"type":"string","enum":["not_effective","unknown","measured","partial","suppressed"]},"evaluation_coverage":{"type":"object","additionalProperties":false,"required":["state","raw_events","core_collection","conversion_steps","session_integrity","event_order","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"raw_events":{"type":"string","enum":["complete","partial","unknown"]},"core_collection":{"type":"string","enum":["complete","partial","unknown"]},"conversion_steps":{"type":"string","enum":["complete","partial","unknown","not_applicable"]},"session_integrity":{"type":"string","enum":["exact","ambiguous","unknown"]},"event_order":{"type":"string","enum":["exact","ambiguous","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"metrics":{"type":"object","additionalProperties":false,"required":["entered_sessions","entered_quality","completed_sessions","completed_quality","completion_rate"],"properties":{"entered_sessions":{"type":["integer","null"],"minimum":0},"entered_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"completed_sessions":{"type":["integer","null"],"minimum":0},"completed_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"completion_rate":{"type":["number","null"],"minimum":0,"maximum":1}}},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"steps":{"type":"array","minItems":2,"maxItems":5,"items":{"type":"object","additionalProperties":false,"required":["position","definition","reached_sessions","reached_quality","rate_from_previous"],"properties":{"position":{"type":"integer","minimum":1,"maximum":5},"definition":{"oneOf":[{"type":"object","additionalProperties":false,"required":["kind","hostname","path","path_fidelity","path_transform_version"],"properties":{"kind":{"type":"string","const":"page"},"hostname":{"type":"string","minLength":1,"maxLength":253},"path":{"type":"string","minLength":1,"maxLength":1024},"path_fidelity":{"type":"string","enum":["exact","redacted"]},"path_transform_version":{"type":"string","const":"path/v1"}}},{"type":"object","additionalProperties":false,"required":["kind","conversion_id","revision_id","revision","name","matcher"],"properties":{"kind":{"type":"string","const":"conversion"},"conversion_id":{"type":"string","format":"uuid"},"revision_id":{"type":"string","format":"uuid"},"revision":{"type":"integer","minimum":1},"name":{"type":"string","minLength":1,"maxLength":64},"matcher":{"oneOf":[{"type":"object","additionalProperties":false,"required":["kind","event_name","property_rules"],"properties":{"kind":{"type":"string","const":"event"},"event_name":{"type":"string","minLength":1,"maxLength":64},"property_rules":{"type":"array","maxItems":8,"items":{"type":"object","additionalProperties":false,"required":["event_name","property_key","property_revision","scalar_kind","operator","comparison"],"properties":{"event_name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[A-Za-z][A-Za-z0-9 _.-]{0,63}$"},"property_key":{"type":"string","minLength":1,"maxLength":48,"pattern":"^[a-z][a-z0-9_.-]{0,47}$"},"property_revision":{"type":"integer","minimum":1},"scalar_kind":{"type":"string","enum":["enum","integer","boolean"]},"operator":{"type":"string","enum":["equals","one_of","between"]},"comparison":{"oneOf":[{"type":"object","additionalProperties":false,"required":["value"],"properties":{"value":{"type":["string","integer","boolean"]}}},{"type":"object","additionalProperties":false,"required":["values"],"properties":{"values":{"type":"array","minItems":1,"maxItems":50,"items":{"type":"string","minLength":1,"maxLength":64}}}},{"type":"object","additionalProperties":false,"required":["lower","upper"],"properties":{"lower":{"type":"integer"},"upper":{"type":"integer"}}}]}}}}}},{"type":"object","additionalProperties":false,"required":["kind","hostname","path","path_fidelity","path_transform_version","property_rules"],"properties":{"kind":{"type":"string","const":"pageview"},"hostname":{"type":"string","minLength":1,"maxLength":253},"path":{"type":"string","minLength":1,"maxLength":1024},"path_fidelity":{"type":"string","enum":["exact","redacted"]},"path_transform_version":{"type":"string","const":"path/v1"},"property_rules":{"type":"array","minItems":0,"maxItems":0}}}]}}}]},"reached_sessions":{"type":["integer","null"],"minimum":0},"reached_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"rate_from_previous":{"type":["number","null"],"minimum":0,"maximum":1}}}}}}}},"AnalyticsJourneys":{"type":"object","additionalProperties":false,"required":["meta","journeys"],"description":"Strict Journey envelope. This schema caps the grouped row at one; the canonical runtime parser additionally enforces grouped-last, sequence uniqueness, and exact row/share algebra.","properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance","evaluation_coverage","summary","pagination"],"properties":{"contract_version":{"type":"string","const":"analytics-journeys/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to","cutoff"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"},"cutoff":{"type":"string","format":"date-time"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","evaluator_version","order_basis","session_scope","population","signature","rare_sequence_floor"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"evaluator_version":{"type":"string","const":"journey-evaluator/v1"},"order_basis":{"type":"string","const":"worker_receipt_time_then_persisted_funnel_order_v1"},"session_scope":{"type":"string","const":"same_utc_day_30_minute_inactivity"},"population":{"type":"string","const":"closed_sessions_at_cutoff"},"signature":{"type":"string","const":"first_five_pageviews_with_continuation/v1"},"rare_sequence_floor":{"type":"integer","const":5}}},"evaluation_coverage":{"type":"object","additionalProperties":false,"required":["state","raw_events","core_collection","page_identity","session_linkage","session_integrity","event_order","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"raw_events":{"type":"string","enum":["complete","partial","unknown"]},"core_collection":{"type":"string","enum":["complete","partial","unknown"]},"page_identity":{"type":"string","enum":["complete","partial","unknown"]},"session_linkage":{"type":"string","enum":["complete","partial","unknown"]},"session_integrity":{"type":"string","enum":["exact","ambiguous","unknown"]},"event_order":{"type":"string","enum":["exact","ambiguous","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"summary":{"type":"object","additionalProperties":false,"required":["measured_sessions","measured_sessions_quality"],"properties":{"measured_sessions":{"type":["integer","null"],"minimum":0},"measured_sessions_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown"]}}},"pagination":{"type":"object","additionalProperties":false,"required":["individual_limit","individual_returned_count","individual_total_count","truncated","grouped_included"],"properties":{"individual_limit":{"type":"integer","minimum":1,"maximum":100},"individual_returned_count":{"type":"integer","minimum":0,"maximum":100},"individual_total_count":{"type":"integer","minimum":0},"truncated":{"type":"boolean"},"grouped_included":{"type":"boolean"}}}}},"journeys":{"type":"array","maxItems":101,"items":{"oneOf":[{"type":"object","additionalProperties":false,"required":["kind","steps","termination","sessions","sessions_quality","share_of_measured_sessions"],"properties":{"kind":{"type":"string","const":"sequence"},"steps":{"type":"array","minItems":1,"maxItems":5,"prefixItems":[{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":1},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":2},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":3},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":4},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":5},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]}],"items":false},"termination":{"type":"string","const":"ended"},"sessions":{"type":"integer","minimum":5},"sessions_quality":{"type":"string","enum":["exact","observed_lower_bound"]},"share_of_measured_sessions":{"type":["number","null"],"minimum":0,"maximum":1}}},{"type":"object","additionalProperties":false,"required":["kind","steps","termination","sessions","sessions_quality","share_of_measured_sessions"],"properties":{"kind":{"type":"string","const":"sequence"},"steps":{"type":"array","minItems":5,"maxItems":5,"prefixItems":[{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":1},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":2},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":3},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":4},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]},{"type":"object","additionalProperties":false,"required":["position","hostname","path","path_fidelity","path_transform_version"],"properties":{"position":{"type":"integer","const":5},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$"},"path":{"type":"string","minLength":1,"maxLength":1024,"description":"Canonical path/v1 identity without query or fragment; grouped fidelity uses exactly /[grouped]."},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"path_transform_version":{"type":"string","const":"path/v1"}},"allOf":[{"if":{"properties":{"path_fidelity":{"const":"grouped"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"const":"/[grouped]"}}}},{"if":{"properties":{"path_fidelity":{"const":"redacted"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"allOf":[{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"},{"pattern":"(?:^|/)%5Bredacted%5D(?:/|$)"}]}}}},{"if":{"properties":{"path_fidelity":{"const":"exact"}},"required":["path_fidelity"]},"then":{"properties":{"path":{"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$"}}}}]}],"items":false},"termination":{"type":"string","const":"continued"},"sessions":{"type":"integer","minimum":5},"sessions_quality":{"type":"string","enum":["exact","observed_lower_bound"]},"share_of_measured_sessions":{"type":["number","null"],"minimum":0,"maximum":1}}},{"type":"object","additionalProperties":false,"required":["kind","steps","termination","sessions","sessions_quality","share_of_measured_sessions"],"properties":{"kind":{"type":"string","const":"grouped"},"steps":{"type":"array","maxItems":0},"termination":{"type":"string","const":"grouped"},"sessions":{"type":"integer","minimum":1},"sessions_quality":{"type":"string","enum":["exact","observed_lower_bound"]},"share_of_measured_sessions":{"type":["number","null"],"minimum":0,"maximum":1}}}]},"contains":{"type":"object","properties":{"kind":{"const":"grouped"}},"required":["kind"]},"minContains":0,"maxContains":1}},"allOf":[{"if":{"properties":{"meta":{"properties":{"evaluation_coverage":{"properties":{"state":{"const":"unknown"}},"required":["state"]}},"required":["evaluation_coverage"]}},"required":["meta"]},"then":{"properties":{"meta":{"properties":{"data_through":{"const":null},"freshness":{"properties":{"state":{"const":"unavailable"}},"required":["state"]},"summary":{"properties":{"measured_sessions":{"const":null},"measured_sessions_quality":{"const":"unknown"}},"required":["measured_sessions","measured_sessions_quality"]},"pagination":{"properties":{"individual_returned_count":{"const":0},"individual_total_count":{"const":0},"truncated":{"const":false},"grouped_included":{"const":false}}}}},"journeys":{"maxItems":0}}}},{"if":{"properties":{"meta":{"properties":{"summary":{"properties":{"measured_sessions":{"const":0}},"required":["measured_sessions"]}},"required":["summary"]}},"required":["meta"]},"then":{"properties":{"meta":{"properties":{"data_through":{"const":null},"freshness":{"properties":{"state":{"const":"unavailable"},"limitations":{"contains":{"const":"no_closed_journey_evidence"}}}},"evaluation_coverage":{"properties":{"state":{"const":"complete"}}}}},"journeys":{"maxItems":0}}}},{"if":{"properties":{"meta":{"properties":{"evaluation_coverage":{"properties":{"state":{"const":"complete"}},"required":["state"]},"summary":{"properties":{"measured_sessions":{"type":"integer","minimum":1}},"required":["measured_sessions"]}},"required":["evaluation_coverage","summary"]}},"required":["meta"]},"then":{"properties":{"meta":{"properties":{"data_through":{"type":"string","format":"date-time"},"summary":{"properties":{"measured_sessions_quality":{"const":"exact"}}}}},"journeys":{"items":{"properties":{"sessions_quality":{"const":"exact"},"share_of_measured_sessions":{"type":"number"}}}}}}},{"if":{"properties":{"meta":{"properties":{"evaluation_coverage":{"properties":{"state":{"const":"partial"}},"required":["state"]}},"required":["evaluation_coverage"]}},"required":["meta"]},"then":{"properties":{"meta":{"properties":{"data_through":{"const":null},"summary":{"properties":{"measured_sessions_quality":{"const":"observed_lower_bound"}}}}},"journeys":{"items":{"properties":{"sessions_quality":{"const":"observed_lower_bound"},"share_of_measured_sessions":{"const":null}}}}}}}]},"AnalyticsRevenue":{"type":"object","additionalProperties":false,"required":["meta","reconciliation","reported"],"allOf":[{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"complete"}}}}}}},"then":{"properties":{"meta":{"properties":{"available_from":{"type":"string","format":"date"},"value_quality":{"const":"exact"},"has_revenue_aware_receipt":{"const":true},"measurement_state":{"const":"measured"},"completeness":{"properties":{"state":{"const":"complete"},"gaps":{"maxItems":0},"limitations":{"maxItems":0}}},"collection_coverage":{"properties":{"browser_receipts":{"const":"complete"},"server_receipts":{"const":"complete"},"aggregate_integrity":{"const":"exact"},"gaps":{"maxItems":0},"limitations":{"maxItems":0}}}}},"reconciliation":{"properties":{"quality":{"const":"exact"}}},"reported":{"type":"array"}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}},"has_revenue_aware_receipt":{"const":false},"operational":{"properties":{"state":{"enum":["not_set_up"]}}}}}}},"then":{"properties":{"meta":{"properties":{"measurement_state":{"const":"uninstalled"}}}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}},"has_revenue_aware_receipt":{"const":false},"operational":{"properties":{"state":{"enum":["live","connecting"]}}}}}}},"then":{"properties":{"meta":{"properties":{"measurement_state":{"const":"awaiting_first_evidence"}}}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}},"has_revenue_aware_receipt":{"const":false},"operational":{"properties":{"state":{"enum":["needs_attention","disabled"]}}}}}}},"then":{"properties":{"meta":{"properties":{"measurement_state":{"const":"unavailable"}}}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"partial"}}}}}}},"then":{"properties":{"meta":{"properties":{"available_from":{"type":"string","format":"date"},"value_quality":{"const":"observed_lower_bound"},"has_revenue_aware_receipt":{"const":true},"measurement_state":{"const":"measured"},"completeness":{"properties":{"state":{"const":"partial"},"gaps":{"minItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_collection_gap"}],"items":false,"minItems":1,"maxItems":1}}},"collection_coverage":{"oneOf":[{"properties":{"browser_receipts":{"const":"partial"},"server_receipts":{"const":"complete"}}},{"properties":{"browser_receipts":{"const":"complete"},"server_receipts":{"const":"partial"}}},{"properties":{"browser_receipts":{"const":"partial"},"server_receipts":{"const":"partial"}}}],"properties":{"aggregate_integrity":{"const":"exact"},"gaps":{"minItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_collection_gap"}],"items":false,"minItems":1,"maxItems":1}}}}},"reconciliation":{"properties":{"quality":{"const":"observed_lower_bound"}}},"reported":{"type":"array"}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}}}}}},"then":{"properties":{"meta":{"properties":{"value_quality":{"const":"unknown"},"completeness":{"properties":{"state":{"const":"unknown"}}},"freshness":{"properties":{"state":{"const":"unavailable"}}},"collection_coverage":{"properties":{"aggregate_integrity":{"const":"unknown"}}}}},"reconciliation":{"properties":{"state":{"const":"unknown"},"quality":{"const":"unknown"},"conflicting_transactions":{"type":"null"},"missing_transaction_key_reports":{"type":"null"},"limitations":{"maxItems":0}}},"reported":{"type":"null"}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}},"has_revenue_aware_receipt":{"const":false}}}}},"then":{"properties":{"meta":{"properties":{"available_from":{"type":"null"},"data_through":{"type":"null"},"completeness":{"properties":{"gaps":{"minItems":1,"maxItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"awaiting_first_revenue_aware_receipt"}],"items":false,"minItems":1,"maxItems":1}}},"collection_coverage":{"properties":{"browser_receipts":{"const":"unknown"},"server_receipts":{"const":"unknown"},"gaps":{"minItems":1,"maxItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"awaiting_first_revenue_aware_receipt"}],"items":false,"minItems":1,"maxItems":1}}}}}}}},{"if":{"properties":{"meta":{"properties":{"collection_coverage":{"properties":{"state":{"const":"unknown"}}},"has_revenue_aware_receipt":{"const":true}}}}},"then":{"properties":{"meta":{"properties":{"available_from":{"type":"string","format":"date"},"data_through":{"type":"string","format":"date-time"},"measurement_state":{"const":"unavailable"},"completeness":{"oneOf":[{"properties":{"gaps":{"maxItems":0},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_unavailable"}],"items":false,"minItems":1,"maxItems":1}}},{"properties":{"gaps":{"minItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_collection_gap"},{"type":"string","const":"reported_revenue_unavailable"}],"items":false,"minItems":2,"maxItems":2}}}]},"collection_coverage":{"oneOf":[{"properties":{"browser_receipts":{"const":"complete"},"server_receipts":{"const":"complete"},"gaps":{"maxItems":0},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_unavailable"}],"items":false,"minItems":1,"maxItems":1}}},{"oneOf":[{"properties":{"browser_receipts":{"const":"partial"},"server_receipts":{"const":"complete"}}},{"properties":{"browser_receipts":{"const":"complete"},"server_receipts":{"const":"partial"}}},{"properties":{"browser_receipts":{"const":"partial"},"server_receipts":{"const":"partial"}}}],"properties":{"gaps":{"minItems":1},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_revenue_collection_gap"},{"type":"string","const":"reported_revenue_unavailable"}],"items":false,"minItems":2,"maxItems":2}}}]}}}}}},{"if":{"properties":{"reconciliation":{"properties":{"conflicting_transactions":{"type":"integer","minimum":1}}}}},"then":{"properties":{"reconciliation":{"properties":{"state":{"const":"needs_attention"},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"reported_evidence_needs_reconciliation"}],"items":false,"minItems":1,"maxItems":1}}}}}},{"if":{"properties":{"reconciliation":{"properties":{"conflicting_transactions":{"const":0},"missing_transaction_key_reports":{"type":"integer","minimum":1}}}}},"then":{"properties":{"reconciliation":{"properties":{"state":{"const":"needs_attention"},"limitations":{"type":"array","prefixItems":[{"type":"string","const":"transaction_key_required"}],"items":false,"minItems":1,"maxItems":1}}}}}},{"if":{"properties":{"reconciliation":{"properties":{"quality":{"const":"exact"},"conflicting_transactions":{"const":0},"missing_transaction_key_reports":{"const":0}}}}},"then":{"properties":{"reconciliation":{"properties":{"state":{"const":"clean"},"limitations":{"maxItems":0}}}}}},{"if":{"properties":{"reconciliation":{"properties":{"quality":{"const":"observed_lower_bound"},"conflicting_transactions":{"const":0},"missing_transaction_key_reports":{"const":0}}}}},"then":{"properties":{"reconciliation":{"properties":{"state":{"const":"unknown"},"limitations":{"maxItems":0}}}}}}],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","completeness","freshness","provenance","collection_coverage","value_quality","has_revenue_aware_receipt","measurement_state","operational"],"properties":{"contract_version":{"type":"string","const":"analytics-revenue/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to","cutoff"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"},"cutoff":{"type":"string","format":"date-time"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","verification","amount_unit","transaction_identity"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"customer_reported"},"verification":{"type":"string","const":"not_payment_verified"},"amount_unit":{"type":"string","const":"currency_minor_unit"},"transaction_identity":{"type":"string","const":"site_scoped_sha256_uuidv4_30_utc_dates/v1"}}},"collection_coverage":{"type":"object","additionalProperties":false,"required":["state","browser_receipts","server_receipts","aggregate_integrity","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"browser_receipts":{"type":"string","enum":["complete","partial","unknown"]},"server_receipts":{"type":"string","enum":["complete","partial","unknown"]},"aggregate_integrity":{"type":"string","enum":["exact","ambiguous","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"value_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown"]},"has_revenue_aware_receipt":{"type":"boolean"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}}}},"reconciliation":{"type":"object","additionalProperties":false,"required":["state","quality","conflicting_transactions","missing_transaction_key_reports","limitations"],"properties":{"state":{"type":"string","enum":["clean","needs_attention","unknown"]},"quality":{"type":"string","enum":["exact","observed_lower_bound","unknown"]},"conflicting_transactions":{"type":["integer","null"],"minimum":0,"maximum":9007199254740991},"missing_transaction_key_reports":{"type":["integer","null"],"minimum":0,"maximum":9007199254740991},"limitations":{"type":"array","items":{"type":"string"}}}},"reported":{"type":["array","null"],"items":{"type":"object","additionalProperties":false,"required":["currency","amount_minor","payment_count","segments"],"properties":{"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRU","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SLE","SLL","SOS","SRD","SSP","STN","SVC","SYP","SZL","THB","TJS","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYU","UYW","UZS","VES","VND","VUV","WST","XAF","XCD","XCG","XDR","XOF","XPF","XSU","YER","ZAR","ZMW","ZWG","ZWL"]},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991},"segments":{"oneOf":[{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":1,"maxItems":1},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"server-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"unattributed"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":1,"maxItems":1},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"},{"type":"string","const":"server-reported"}],"items":false,"minItems":2,"maxItems":2},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":1,"maxItems":1},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}},{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"server-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"unattributed"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":2,"maxItems":2},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}},{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"},{"type":"string","const":"server-reported"}],"items":false,"minItems":2,"maxItems":2},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":2,"maxItems":2},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"server-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"unattributed"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}},{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"},{"type":"string","const":"server-reported"}],"items":false,"minItems":2,"maxItems":2},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":2,"maxItems":2},{"type":"array","prefixItems":[{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}},{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"server-reported"}],"items":false,"minItems":1,"maxItems":1},"attribution_state":{"type":"string","const":"unattributed"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}},{"type":"object","additionalProperties":false,"required":["provenance","attribution_state","amount_minor","payment_count"],"properties":{"provenance":{"type":"array","prefixItems":[{"type":"string","const":"browser-reported"},{"type":"string","const":"server-reported"}],"items":false,"minItems":2,"maxItems":2},"attribution_state":{"type":"string","const":"tracker-event-linked"},"amount_minor":{"type":"string","pattern":"^[1-9][0-9]*$"},"payment_count":{"type":"integer","minimum":1,"maximum":9007199254740991}}}],"items":false,"minItems":3,"maxItems":3}]}}}}}},"AnalyticsConversions":{"type":"object","additionalProperties":false,"required":["meta","conversions"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance","configuration","pagination"],"properties":{"contract_version":{"type":"string","enum":["analytics-conversions/v1","analytics-conversions/v2"]},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","matcher_version","session_scope","attribution_basis"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"matcher_version":{"oneOf":[{"type":"string","const":"conversion-matcher/v1"},{"type":"null"}]},"session_scope":{"type":"string","const":"same_utc_day_30_minute_inactivity"},"attribution_basis":{"type":"string","const":"immutable_session_entry"}}},"configuration":{"type":"object","additionalProperties":false,"required":["state","active_count"],"properties":{"state":{"type":"string","enum":["not_configured","configured"]},"active_count":{"type":"integer","minimum":0,"maximum":30}}},"pagination":{"type":"object","additionalProperties":false,"required":["limit","returned_count","total_count","truncated"],"properties":{"limit":{"type":"integer","minimum":1,"maximum":100},"returned_count":{"type":"integer","minimum":0,"maximum":100},"total_count":{"type":"integer","minimum":0},"truncated":{"type":"boolean"}}}}},"conversions":{"type":"array","items":{"type":"object","required":["conversion_id","revision_id","revision","name","definition_state","matcher","effective_from","effective_to","evidence_state","matching_coverage","available_from","data_through","metrics","completeness","source_total_count","sources"],"additionalProperties":false,"properties":{"conversion_id":{"type":"string","format":"uuid"},"revision_id":{"type":"string","format":"uuid"},"revision":{"type":"integer","minimum":1},"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[A-Za-z][A-Za-z0-9 _.-]{0,63}$"},"definition_state":{"type":"string","enum":["active","archived"]},"effective_from":{"type":"string","format":"date-time"},"effective_to":{"type":["string","null"],"format":"date-time"},"matcher":{"oneOf":[{"type":"object","additionalProperties":false,"required":["kind","event_name"],"properties":{"kind":{"type":"string","const":"event"},"event_name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[A-Za-z][A-Za-z0-9 _.-]{0,63}$"}}},{"type":"object","additionalProperties":false,"required":["kind","hostname","path","path_fidelity","path_transform_version"],"properties":{"kind":{"type":"string","const":"pageview"},"hostname":{"type":"string","minLength":1,"maxLength":253,"pattern":"^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$","description":"Canonical lowercase DNS hostname. Site admission is enforced by the canonical reader."},"path":{"type":"string","minLength":1,"maxLength":1024,"pattern":"^/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})*(?:/(?:[A-Za-z0-9\\-_.!~*'()]|%[0-9A-F]{2})+)*$","description":"Canonical path/v1 output only: ASCII, uppercase percent bytes, no query, fragment, repeated slash, trailing slash, or dot traversal. The database revalidates the complete privacy transform."},"path_fidelity":{"type":"string","enum":["exact","redacted"]},"path_transform_version":{"type":"string","const":"path/v1"}}}]},"property_rules":{"type":"array","maxItems":8,"items":{"type":"object","additionalProperties":false,"required":["event_name","property_key","property_revision","scalar_kind","operator","comparison"],"properties":{"event_name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[A-Za-z][A-Za-z0-9 _.-]{0,63}$"},"property_key":{"type":"string","minLength":1,"maxLength":48,"pattern":"^[a-z][a-z0-9_.-]{0,47}$"},"property_revision":{"type":"integer","minimum":1},"scalar_kind":{"type":"string","enum":["enum","integer","boolean"]},"operator":{"type":"string","enum":["equals","one_of","between"]},"comparison":{"oneOf":[{"type":"object","additionalProperties":false,"required":["value"],"properties":{"value":{"type":["string","integer","boolean"]}}},{"type":"object","additionalProperties":false,"required":["values"],"properties":{"values":{"type":"array","minItems":1,"maxItems":50,"items":{"type":"string","minLength":1,"maxLength":64}}}},{"type":"object","additionalProperties":false,"required":["lower","upper"],"properties":{"lower":{"type":"integer"},"upper":{"type":"integer"}}}]}}}},"evidence_state":{"type":"string","enum":["not_effective","unknown","measured","partial","unavailable","suppressed"]},"matching_coverage":{"type":"object","additionalProperties":false,"required":["state","event_matching","session_integrity","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"event_matching":{"type":"string","enum":["complete","partial","unknown"]},"session_integrity":{"type":"string","enum":["exact","ambiguous","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"metrics":{"type":"object","additionalProperties":false,"required":["occurrences","occurrences_quality","converting_sessions","eligible_sessions","conversion_rate"],"properties":{"occurrences":{"type":["integer","null"],"minimum":0},"occurrences_quality":{"type":"string","enum":["exact","observed_lower_bound","unknown","suppressed"]},"converting_sessions":{"type":["integer","null"],"minimum":0},"eligible_sessions":{"type":["integer","null"],"minimum":0},"conversion_rate":{"type":["number","null"],"minimum":0,"maximum":1}}},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"source_total_count":{"type":["integer","null"],"minimum":0},"sources":{"type":["array","null"],"items":{"type":"object","additionalProperties":false,"required":["family","occurrences","converting_sessions","eligible_sessions","conversion_rate"],"properties":{"family":{"type":"string","enum":["direct","ai","campaign","search","social","referral"]},"occurrences":{"type":"integer","minimum":0},"converting_sessions":{"type":"integer","minimum":0},"eligible_sessions":{"type":"integer","minimum":0},"conversion_rate":{"type":["number","null"],"minimum":0,"maximum":1}}}}}}}}},"AnalyticsPages":{"type":"object","additionalProperties":false,"required":["meta","summary","pages","crawler_patterns"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","tracker","crawler","pagination"],"properties":{"contract_version":{"type":"string","const":"analytics-pages/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"tracker":{"type":"object","additionalProperties":false,"required":["measurement_state","available_from","data_through","completeness","provenance"],"properties":{"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","no_evidence_in_window","unavailable"]},"available_from":{"type":["string","null"],"format":"date","description":"Earliest retained v4 Page-coverage day. The lifetime marker is never substituted."},"data_through":{"type":["string","null"],"format":"date-time"},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"provenance":{"type":"object","additionalProperties":false,"required":["evidence","ingest_contract_version","path_transform_version"],"properties":{"evidence":{"type":"string","const":"browser_tracker"},"ingest_contract_version":{"type":["string","null"],"enum":["analytics-ingest/v4","analytics-ingest/v5",null]},"path_transform_version":{"type":["string","null"],"enum":["path/v1",null]}}}}},"crawler":{"type":"object","additionalProperties":false,"required":["connection_state","evidence_state","available_from","data_through","completeness","provenance"],"properties":{"connection_state":{"type":"string","enum":["not_configured","connected","disconnected","unavailable"]},"evidence_state":{"type":"string","enum":["complete","partial","gap","stale","unknown","unavailable","not_comparable"]},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"provenance":{"type":"object","additionalProperties":false,"required":["evidence","authority_contract_version","path_transform_version"],"properties":{"evidence":{"type":"string","const":"crawler"},"authority_contract_version":{"type":["string","null"]},"path_transform_version":{"type":["string","null"],"enum":["path/v1",null]}}}}},"pagination":{"type":"object","additionalProperties":false,"required":["limit","returned","total","truncated"],"properties":{"limit":{"type":"integer","minimum":1,"maximum":100},"returned":{"type":"integer","minimum":0,"maximum":100},"total":{"type":"integer","minimum":0},"truncated":{"type":"boolean"}}}}},"summary":{"type":"object","additionalProperties":false,"required":["pageviews","visitors"],"properties":{"pageviews":{"type":["integer","null"],"minimum":0},"visitors":{"type":["integer","null"],"minimum":0,"description":"Sum of site/day unique visitors, not a cross-window unique."}}},"pages":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["hostname","path","path_fidelity","pageviews","visitors","share","crawler"],"properties":{"hostname":{"type":"string"},"path":{"type":"string","pattern":"^/[^?#]*$","maxLength":1024},"path_fidelity":{"type":"string","enum":["exact","redacted","grouped"]},"pageviews":{"type":"integer","minimum":1},"visitors":{"type":"integer","minimum":0,"description":"Daily unique visitors summed across the requested UTC days."},"share":{"type":["number","null"],"minimum":0,"maximum":1},"crawler":{"type":"object","additionalProperties":false,"required":["count","connection_state","evidence_state","limitations"],"properties":{"count":{"type":["integer","null"],"minimum":0},"connection_state":{"type":"string","enum":["not_configured","connected","disconnected","unavailable"]},"evidence_state":{"type":"string","enum":["complete","partial","gap","stale","unknown","unavailable","not_comparable"]},"limitations":{"type":"array","items":{"type":"string"}}}}}}},"crawler_patterns":{"type":"array","description":"Crawler redacted/grouped evidence remains separate and never decorates an exact tracker Page.","items":{"type":"object","additionalProperties":false,"required":["hostname","path","path_fidelity","count","connection_state","evidence_state","limitations"],"properties":{"hostname":{"type":"string"},"path":{"type":"string","pattern":"^/[^?#]*$","maxLength":1024},"path_fidelity":{"type":"string","enum":["redacted","grouped"]},"count":{"type":["integer","null"],"minimum":0},"connection_state":{"type":"string","enum":["not_configured","connected","disconnected","unavailable"]},"evidence_state":{"type":"string","enum":["complete","partial","gap","stale","unknown","unavailable","not_comparable"]},"limitations":{"type":"array","items":{"type":"string"}}}}}}},"AnalyticsSourcesV1":{"type":"object","additionalProperties":false,"required":["meta","acquisition","ai_referrals","utm_source","utm_medium","utm_campaign","utm_term","utm_content"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance"],"properties":{"contract_version":{"type":"string","const":"analytics-sources/v1"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"available_from":{"type":["string","null"],"format":"date","description":"Earliest complete analytics-sources/v1 UTC rollup day; legacy history is never backfilled."},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","source_rollup_version","utm_transform_version","attribution_basis","visitor_scope"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"source_rollup_version":{"type":["string","null"],"enum":["analytics-sources/v1",null]},"utm_transform_version":{"type":["string","null"],"enum":["utm/v1",null]},"attribution_basis":{"type":"string","const":"immutable_session_entry"},"visitor_scope":{"type":"string","const":"per_utc_day_per_dimension","description":"Visitors are unique per UTC day within each displayed row. Row sums are not site uniques."}}}}},"acquisition":{"oneOf":[{"type":"array","items":{"type":"object","additionalProperties":false,"required":["family","product","host","daily_unique_visitors","sessions"],"properties":{"family":{"type":"string","enum":["direct","ai","campaign","search","social","referral"]},"product":{"type":["string","null"]},"host":{"type":["string","null"]},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}},{"type":"null"}]},"ai_referrals":{"oneOf":[{"type":"array","items":{"type":"object","additionalProperties":false,"required":["product","daily_unique_visitors","sessions"],"properties":{"product":{"type":"string","minLength":1},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}},{"type":"null"}]},"utm_source":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_medium":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_campaign":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_term":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_content":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]}}},"AccessCheck":{"type":"object","required":["evidence_type","url","checked_at","http_probe","robots"],"properties":{"evidence_type":{"type":"string","const":"current_policy_check"},"url":{"type":"string","format":"uri"},"checked_at":{"type":"string","format":"date-time"},"http_probe":{"type":"object","required":["requested_url","final_url","http_status","error","redirect_count"],"properties":{"requested_url":{"type":"string","format":"uri"},"final_url":{"type":"string","format":"uri"},"http_status":{"type":["integer","null"]},"error":{"type":["string","null"]},"redirect_count":{"type":"integer"}}},"robots":{"type":"object","required":["fetched","crawlers"],"properties":{"fetched":{"type":"boolean"},"crawlers":{"type":"array","items":{"type":"object","required":["crawler_id","token","decision","matched_rule"],"properties":{"crawler_id":{"type":"string"},"token":{"type":"string"},"decision":{"type":"string","enum":["allowed","disallowed","unknown"],"description":"unknown = robots.txt unreachable — never presented as allowed."},"matched_rule":{"type":["string","null"]}}}}}}}},"AnalyticsOverview":{"type":"object","additionalProperties":false,"required":["meta","metrics"],"oneOf":[{"properties":{"meta":{"properties":{"contract_version":{"type":"string","const":"analytics-overview/v1"}}}},"not":{"anyOf":[{"required":["trend"]},{"required":["comparison"]}]}},{"required":["trend","comparison"],"properties":{"meta":{"properties":{"contract_version":{"type":"string","const":"analytics-overview/v2"}}}}}],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance"],"properties":{"contract_version":{"type":"string","enum":["analytics-overview/v1","analytics-overview/v2"]},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"available_from":{"type":["string","null"],"format":"date"},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["complete","partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","analytics_schema_version","path_transform_version","path_fidelity"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"analytics_schema_version":{"type":["string","null"]},"path_transform_version":{"type":["string","null"]},"path_fidelity":{"type":"string","const":"not_applicable"}}}}},"metrics":{"type":"object","additionalProperties":false,"required":["visitors","pageviews","sessions"],"oneOf":[{"properties":{"visitors":{"type":"integer","minimum":0},"pageviews":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}},{"properties":{"visitors":{"type":"null"},"pageviews":{"type":"null"},"sessions":{"type":"null"}}}]},"trend":{"type":"array","description":"Evidence-bearing UTC days only. Missing days are declared in meta.completeness.gaps and are never synthesized as zero points.","items":{"type":"object","additionalProperties":false,"required":["day","visitors","pageviews","sessions"],"properties":{"day":{"type":"string","format":"date"},"visitors":{"type":"integer","minimum":0},"pageviews":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}},"comparison":{"type":"object","additionalProperties":false,"required":["window","metrics","limitations"],"properties":{"window":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"metrics":{"$ref":"#/components/schemas/AnalyticsOverview/properties/metrics"},"limitations":{"type":"array","items":{"type":"string"}}}}}},"AnalyticsSourcesV2":{"type":"object","additionalProperties":false,"required":["meta","acquisition","ai_referrals","utm_source","utm_medium","utm_campaign","utm_term","utm_content","gsc"],"properties":{"meta":{"type":"object","additionalProperties":false,"required":["contract_version","as_of","window","available_from","data_through","measurement_state","completeness","freshness","operational","provenance","enrichments"],"properties":{"contract_version":{"type":"string","const":"analytics-sources/v2"},"as_of":{"type":"string","format":"date-time"},"window":{"type":"object","additionalProperties":false,"required":["preset","from","to"],"properties":{"preset":{"type":"string","enum":["3d","7d","30d","90d","180d","365d"]},"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}},"available_from":{"type":["string","null"],"format":"date","description":"Earliest complete analytics-sources/v1 UTC rollup day; legacy history is never backfilled."},"data_through":{"type":["string","null"],"format":"date-time"},"measurement_state":{"type":"string","enum":["uninstalled","awaiting_first_evidence","measured","unavailable"]},"completeness":{"type":"object","additionalProperties":false,"required":["state","gaps","limitations"],"properties":{"state":{"type":"string","enum":["partial","unknown"]},"gaps":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date"},"to":{"type":"string","format":"date"}}}},"limitations":{"type":"array","items":{"type":"string"}}}},"freshness":{"type":"object","additionalProperties":false,"required":["state","limitations"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]},"limitations":{"type":"array","items":{"type":"string"}}}},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"core_collection"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention","disabled"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","observed_only"],"properties":{"mode":{"type":"string","const":"browser_tracker"},"observed_only":{"type":"boolean","const":true}}}}},"provenance":{"type":"object","additionalProperties":false,"required":["module","evidence","source_rollup_version","utm_transform_version","attribution_basis","visitor_scope"],"properties":{"module":{"type":"string","const":"analytics"},"evidence":{"type":"string","const":"browser_tracker"},"source_rollup_version":{"type":["string","null"],"enum":["analytics-sources/v1",null]},"utm_transform_version":{"type":["string","null"],"enum":["utm/v1",null]},"attribution_basis":{"type":"string","const":"immutable_session_entry"},"visitor_scope":{"type":"string","const":"per_utc_day_per_dimension","description":"Visitors are unique per UTC day within each displayed row. Row sums are not site uniques."}}},"enrichments":{"type":"object","additionalProperties":false,"required":["gsc"],"properties":{"gsc":{"type":"boolean","const":true}}}}},"acquisition":{"oneOf":[{"type":"array","items":{"type":"object","additionalProperties":false,"required":["family","product","host","daily_unique_visitors","sessions"],"properties":{"family":{"type":"string","enum":["direct","ai","campaign","search","social","referral"]},"product":{"type":["string","null"]},"host":{"type":["string","null"]},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}},{"type":"null"}]},"ai_referrals":{"oneOf":[{"type":"array","items":{"type":"object","additionalProperties":false,"required":["product","daily_unique_visitors","sessions"],"properties":{"product":{"type":"string","minLength":1},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}},{"type":"null"}]},"utm_source":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_medium":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_campaign":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_term":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"utm_content":{"oneOf":[{"type":"object","additionalProperties":false,"required":["eligible_sessions","rows"],"properties":{"eligible_sessions":{"type":"integer","minimum":0,"description":"Sessions whose value was safely observable, including known no-tag sessions."},"rows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["value","daily_unique_visitors","sessions"],"properties":{"value":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9 ._-]*$","description":"Canonical privacy-safe utm/v1 exact value. Non-ASCII values are redacted before storage."},"daily_unique_visitors":{"type":"integer","minimum":0},"sessions":{"type":"integer","minimum":0}}}}}},{"type":"null"}]},"gsc":{"type":"object","additionalProperties":false,"required":["provider","property_uri","date_basis","available_from","data_through_day","operational","freshness","limitations","days"],"properties":{"provider":{"type":"string","const":"google_search_console"},"freshness":{"type":"object","additionalProperties":false,"required":["state"],"properties":{"state":{"type":"string","enum":["current","stale","unavailable"]}}},"property_uri":{"type":["string","null"]},"date_basis":{"type":"string","const":"provider_pacific_day","description":"GSC dates are Google's Pacific-time days with their provider label; they are never converted into tracker UTC dates. Only Pacific days fully inside the requested UTC window appear."},"available_from":{"type":["string","null"],"format":"date"},"data_through_day":{"type":["string","null"],"format":"date"},"operational":{"type":"object","additionalProperties":false,"required":["contract_version","subject","state","reason_code","checked_at","coverage"],"properties":{"contract_version":{"type":"string","const":"operational/v1"},"subject":{"type":"string","const":"gsc_enrichment"},"state":{"type":"string","enum":["not_set_up","connecting","live","needs_attention"]},"reason_code":{"type":["string","null"]},"checked_at":{"type":["string","null"],"format":"date-time"},"coverage":{"type":"object","additionalProperties":false,"required":["mode","top_n_only"],"properties":{"mode":{"type":"string","const":"provider_search_enrichment"},"top_n_only":{"type":"boolean","const":true}}}}},"limitations":{"type":"array","items":{"type":"string"}},"days":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["pacific_day","clicks","impressions","ctr","position","is_final"],"properties":{"pacific_day":{"type":"string","format":"date"},"clicks":{"type":"integer","minimum":0},"impressions":{"type":"integer","minimum":0},"ctr":{"type":"number","minimum":0,"maximum":1},"position":{"type":"number","minimum":0},"is_final":{"type":"boolean"}}}}}}}},"AnalyticsSources":{"description":"Discriminated on meta.contract_version: analytics-sources/v1 (tracker only; served while the GSC enrichment flag is off, which is the current production state) or analytics-sources/v2 (adds the provider-labelled gsc block).","oneOf":[{"$ref":"#/components/schemas/AnalyticsSourcesV1"},{"$ref":"#/components/schemas/AnalyticsSourcesV2"}]}}}}