@adcp/sdk API Reference - v10.0.1
    Preparing search index...

    Interface WebhookMetadata

    Metadata provided with webhook responses

    interface WebhookMetadata {
        operation_id: string;
        task_id: string;
        agent_id: string;
        task_type: string;
        status: TaskStatus;
        context_id?: string;
        message?: string;
        timestamp: string;
        rawHTTPPayload?: any;
        protocol?: "mcp" | "a2a";
        idempotency_key?: string;
        productPropertyPolicy?: {
            mode: ProductPropertyPolicyMode;
            ok: boolean;
            accepted_count: number;
            rejected_count: number;
            flagged_count: number;
            message?: string;
            request_property_list?: {
                list_id: string;
                agent_url: string;
                identifier_count?: number;
                cache_valid_until?: string;
                resolution_error?: string;
            };
            diagnostics: ProductPropertyPolicyDiagnostic[];
        };
        productPricingPolicy?: {
            ok: boolean;
            accepted_count: number;
            rejected_count: number;
            rejected_products: { index: number; product_id?: string }[];
        };
    }

    Hierarchy (View Summary)

    Index

    Properties

    operation_id: string

    Client-provided operation ID

    task_id: string

    Server's task ID

    agent_id: string

    Agent ID

    task_type: string

    Task type/tool name

    status: TaskStatus

    Task status (completed, failed, needs_input, working, etc)

    context_id?: string

    Server's context ID

    message?: string

    Human-readable context about the status change

    timestamp: string

    Timestamp

    rawHTTPPayload?: any

    raw HTTP payload

    protocol?: "mcp" | "a2a"

    Wire protocol that delivered this webhook. Useful for handler code that needs to treat MCP and A2A transports differently (e.g., idempotency_key is only present on MCP payloads).

    idempotency_key?: string

    Sender-generated key stable across retries of the same webhook event (MCP envelope only — A2A webhooks do not carry this field). Use this as the canonical dedup key; see AsyncHandlerConfig.webhookDedup.

    productPropertyPolicy?: {
        mode: ProductPropertyPolicyMode;
        ok: boolean;
        accepted_count: number;
        rejected_count: number;
        flagged_count: number;
        message?: string;
        request_property_list?: {
            list_id: string;
            agent_url: string;
            identifier_count?: number;
            cache_valid_until?: string;
            resolution_error?: string;
        };
        diagnostics: ProductPropertyPolicyDiagnostic[];
    }

    Buyer-side product property policy evaluation for completed get_products webhooks. Present when the client filters, audits, or rejects a webhook result before dispatching it to handlers.

    productPricingPolicy?: {
        ok: boolean;
        accepted_count: number;
        rejected_count: number;
        rejected_products: { index: number; product_id?: string }[];
    }

    Buyer-side pricing-options enforcement summary for completed get_products webhooks. Present when the client drops products that arrived without a usable pricing_options[] array before dispatching to handlers.