@adcp/sdk API Reference - v7.9.0
    Preparing search index...

    Interface AdAgentsValidationResult

    interface AdAgentsValidationResult {
        valid: boolean;
        publisher_domain: string;
        discovery_method: DiscoveryMethod;
        manager_domain?: string;
        resolved_url?: string;
        adagents?: AdAgentsJson;
        errors: string[];
    }
    Index

    Properties

    valid: boolean

    Whether a valid adagents.json was discovered for this publisher.

    publisher_domain: string

    The publisher domain the caller asked us to validate.

    discovery_method: DiscoveryMethod

    Which discovery path was used. Defaults to 'direct': a failure on the publisher's own .well-known/adagents.json reports 'direct' even when no file was retrieved. 'authoritative_location' and 'ads_txt_managerdomain' only appear once the validator has committed to that path (followed the pointer / parsed a directive).

    manager_domain?: string

    The manager domain consulted when discovery_method === 'ads_txt_managerdomain'. Populated even on manager-domain failure so callers can surface "we tried " in error reports.

    Note for chained validators: re-invoking validateAdAgents against manager_domain to walk N hops re-enters the discovery flow from scratch. This validator's one-hop guarantee is per-call, not per-chain — callers stringing multiple invocations together are responsible for their own loop guard.

    resolved_url?: string

    URL the adagents.json was ultimately loaded from. Omitted when nothing loaded.

    adagents?: AdAgentsJson

    Parsed authoritative file. Omitted on failure.

    Counterparty-controlled. This JSON came verbatim from the publisher (or their declared manager domain). Treat as untrusted input: do NOT splice into LLM system prompts, log-aggregator indices, or any context that interprets text as instructions without first stripping or sanitizing. Field names like authorized_for (free-text) and properties[].name are obvious vectors; less-obvious ones include arbitrary $schema URLs and structured tags.

    errors: string[]

    One or more reasons validation failed. Empty when valid === true.