@adcp/sdk API Reference - v17.0.0-rc.0
    Preparing search index...

    Interface ProposalPurchase

    A purchase inside proposal commercial terms. Every field comes from the generated ProductPurchase wire type, so fields the pinned schemas add reach this type without edits here. Only pricing is widened.

    interface ProposalPurchase {
        pricing?:
            | {
                pricing_option_id: string;
                pricing_model: | "cpm"
                | "vcpm"
                | "cpc"
                | "cpcv"
                | "cpv"
                | "cpp"
                | "cpa"
                | "revenue_share"
                | "flat_rate"
                | "time";
                currency: string;
                fixed_price?: number;
                floor_price?: number;
                price_guidance?: PriceGuidance;
                min_spend_per_package?: number;
                price_breakdown?: PriceBreakdown;
                eligible_adjustments?: PriceAdjustmentKind[];
                parameters?: {};
                event_type?: EventType;
                custom_event_name?: string;
                event_source_id?: string;
                commission_rate?: number;
                commission_basis_description?: string;
            }
            | ProposalResolvedPricing;
        product_id: string;
        pricing_option_id: string;
        format_option_refs?: [FormatOptionReference, ...FormatOptionReference[]];
        catalog_ids?: [string, ...string[]];
        budget?: number;
        daily_budget_cap?: number;
        min_spend_target?: number;
        impressions?: number;
        start_time?: string;
        end_time?: string;
        pacing?: Pacing;
        bidding?: {
            automatic?: true;
            bid_amount?: number;
            max_bid?: number;
            cost_per?: { amount: number; strength: "cap" | "target" };
            roas?: { value: number; strength: "target" | "floor" };
        };
        targeting_overlay?: TargetingOverlay;
        optimization_goals?: [
            CanonicalOptimizationGoal,
            ...CanonicalOptimizationGoal[],
        ];
        audience_evidence_requirements?: {
            requirement_mode: "required"
            | "preferred";
            evidence_presence: "required" | "when_available";
            accepted_methodologies?: [
                AudienceEvidenceMethodology,
                ...AudienceEvidenceMethodology[],
            ];
            excluded_methodologies?: [
                AudienceEvidenceMethodology,
                ...AudienceEvidenceMethodology[],
            ];
            accepted_evidence_types?: [
                "forecast"
                | "measured"
                | "seller_declared",
                ...("forecast" | "measured" | "seller_declared")[],
            ];
            accepted_providers?: [BrandKey, ...BrandKey[]];
            excluded_providers?: [BrandKey, ...BrandKey[]];
            accepted_subject_types?: [AudienceSubjectType, ...AudienceSubjectType[]];
            accepted_resolution_methods?: [
                AudienceResolutionMethod,
                ...AudienceResolutionMethod[],
            ];
            minimum_confidence?: number;
            maximum_age?: Duration & {
                unit?: "seconds"
                | "minutes"
                | "hours"
                | "days";
            };
            methodology_documentation_required?: boolean;
            independent_attestation_required?: boolean;
            accepted_attestation_issuers?: [
                | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
                | { type: "agent"; agent_url: string; ext?: ExtensionObject }
                | { type: "origin"; origin: string; ext?: ExtensionObject },
                ...(
                    | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
                    | { type: "agent"; agent_url: string; ext?: ExtensionObject }
                    | { type: "origin"; origin: string; ext?: ExtensionObject }
                )[],
            ];
            accepted_attestation_claim_types?: [string, ...string[]];
            ext?: ExtensionObject;
        };
        audience_evidence_pins?: [AudienceEvidencePin, ...AudienceEvidencePin[]];
        agency_estimate_number?: string;
        context?: ContextObject;
        ext?: ExtensionObject;
        measurement_terms?: ProductPurchaseMeasurementTerms;
        performance_standards?: [
            CanonicalPerformanceStandard,
            ...CanonicalPerformanceStandard[],
        ];
    }

    Hierarchy

    • Omit<GeneratedProductPurchase, ProposalPurchaseOverriddenKey>
      • ProposalPurchase
    Index
    pricing?:
        | {
            pricing_option_id: string;
            pricing_model: | "cpm"
            | "vcpm"
            | "cpc"
            | "cpcv"
            | "cpv"
            | "cpp"
            | "cpa"
            | "revenue_share"
            | "flat_rate"
            | "time";
            currency: string;
            fixed_price?: number;
            floor_price?: number;
            price_guidance?: PriceGuidance;
            min_spend_per_package?: number;
            price_breakdown?: PriceBreakdown;
            eligible_adjustments?: PriceAdjustmentKind[];
            parameters?: {};
            event_type?: EventType;
            custom_event_name?: string;
            event_source_id?: string;
            commission_rate?: number;
            commission_basis_description?: string;
        }
        | ProposalResolvedPricing

    Resolved pricing is required in accepted snapshots but optional on direct-purchase inputs.

    product_id: string
    pricing_option_id: string
    format_option_refs?: [FormatOptionReference, ...FormatOptionReference[]]

    Canonical format options selected from the published product offer. Legacy named-format identifiers are not accepted.

    1

    catalog_ids?: [string, ...string[]]

    Previously synchronized account catalog IDs promoted by this selection. Callers manage catalog bodies through sync_catalogs rather than inlining them here.

    1

    budget?: number

    Hard spend cap for this selection in the media-buy currency. In seller-optimized allocation it is an optional ceiling, not a reserved allocation, and requires advertised media_buy.features.seller_optimized_package_budgets; otherwise rejected with UNSUPPORTED_FEATURE before any over-subscription validation.

    daily_budget_cap?: number

    Optional hard daily spend ceiling for this purchase. It is subordinate to the media-buy aggregate daily cap and is not a reserved daily allocation. Its day boundary is the media buy's budget_cap_timezone.

    min_spend_target?: number

    Soft lifetime spend target for seller-optimized allocation. Requires advertised media_buy.features.seller_optimized_min_spend_targets; otherwise rejected with UNSUPPORTED_FEATURE before any over-subscription validation.

    impressions?: number
    start_time?: string

    Resolved package flight start. On direct-purchase input, omission inherits the MediaBuy start; accepted proposal snapshots carry the resolved timestamp.

    end_time?: string

    Resolved package flight end. On direct-purchase input, omission inherits the MediaBuy end; accepted proposal snapshots carry the resolved timestamp.

    pacing?: Pacing
    bidding?: {
        automatic?: true;
        bid_amount?: number;
        max_bid?: number;
        cost_per?: { amount: number; strength: "cap" | "target" };
        roas?: { value: number; strength: "target" | "floor" };
    }

    Type Declaration

    • Optionalautomatic?: true

      Explicitly use seller/provider automatic bidding at this authored scope. At package scope this is a complete override of a media-buy policy, not inheritance. It MUST be the only field in the block and MUST be preserved on readback.

    • Optionalbid_amount?: number

      Manual auction bid denominated in the media-buy currency and expressed per the selected pricing option's auction unit. For example, a CPM option interprets the amount per thousand impressions. This is the amount submitted to the auction, not a promise that the clearing price equals it. Requires an auction-priced pricing option whose currency equals the media-buy currency.

    • Optionalmax_bid?: number

      Hard per-auction ceiling denominated in the media-buy currency and expressed per the selected pricing option's auction unit. This is the only canonical hard auction ceiling and MUST NOT be translated into an average outcome-cost control. Requires an auction-priced pricing option whose currency equals the media-buy currency. May stand alone or supplement cost_per/roas only when the relevant scope capability advertises that combination.

    • Optionalcost_per?: { amount: number; strength: "cap" | "target" }

      Average cost control per result of the scope-bound primary optimization goal. At seller-optimized media-buy scope it binds to budget_allocation.optimization_goals; at package scope it binds to that package's optimization_goals; at fixed media-buy scope it binds independently to each inheriting package and is valid only when their primary-goal result units are compatible. Metric goals are compatible only when metric and every result-defining qualifier match; vendor_metric goals only when vendor and metric_id match; event goals only when the event_type/custom_event_name set and resolved attribution_window match. Primary is the earliest array entry among goals tied for the lowest explicit numeric priority; unprioritized goals follow explicitly prioritized goals; when all priorities are absent, the first entry is primary.

      • amount: number

        Average cost amount per scope-bound primary-goal result, denominated in the media-buy currency.

      • strength: "cap" | "target"

        cap optimizes for an average at or below the amount and accepts underdelivery when necessary; target optimizes around the amount while balancing volume and spend. Neither is a per-result or per-auction guarantee.

    • Optionalroas?: { value: number; strength: "target" | "floor" }

      Dimensionless return-on-ad-spend control bound to the same scope-specific primary goal rules as cost_per. The bound goal must be value-bearing; a fixed media-buy default requires a value-bearing primary goal on every inheriting package. Every referenced value-bearing event source MUST declare value_currencies containing the media-buy currency. The seller validates this at buy creation; each buy consumes only exact-currency records, while other declared currencies remain available to other buys. Sellers MUST NOT perform currency conversion.

      • value: number

        Return per unit of ad spend; 4 means 4 units of value per 1 unit spent.

      • strength: "target" | "floor"

        floor prefers underdelivery to knowingly optimizing below the requested return; target optimizes around the requested return. Neither guarantees realized return.

    targeting_overlay?: TargetingOverlay
    optimization_goals?: [CanonicalOptimizationGoal, ...CanonicalOptimizationGoal[]]

    1

    audience_evidence_requirements?: {
        requirement_mode: "required" | "preferred";
        evidence_presence: "required" | "when_available";
        accepted_methodologies?: [
            AudienceEvidenceMethodology,
            ...AudienceEvidenceMethodology[],
        ];
        excluded_methodologies?: [
            AudienceEvidenceMethodology,
            ...AudienceEvidenceMethodology[],
        ];
        accepted_evidence_types?: [
            "forecast"
            | "measured"
            | "seller_declared",
            ...("forecast" | "measured" | "seller_declared")[],
        ];
        accepted_providers?: [BrandKey, ...BrandKey[]];
        excluded_providers?: [BrandKey, ...BrandKey[]];
        accepted_subject_types?: [AudienceSubjectType, ...AudienceSubjectType[]];
        accepted_resolution_methods?: [
            AudienceResolutionMethod,
            ...AudienceResolutionMethod[],
        ];
        minimum_confidence?: number;
        maximum_age?: Duration & {
            unit?: "seconds"
            | "minutes"
            | "hours"
            | "days";
        };
        methodology_documentation_required?: boolean;
        independent_attestation_required?: boolean;
        accepted_attestation_issuers?: [
            | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
            | { type: "agent"; agent_url: string; ext?: ExtensionObject }
            | { type: "origin"; origin: string; ext?: ExtensionObject },
            ...(
                | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
                | { type: "agent"; agent_url: string; ext?: ExtensionObject }
                | { type: "origin"; origin: string; ext?: ExtensionObject }
            )[],
        ];
        accepted_attestation_claim_types?: [string, ...string[]];
        ext?: ExtensionObject;
    }

    Type Declaration

    • requirement_mode: "required" | "preferred"
    • evidence_presence: "required" | "when_available"
    • Optionalaccepted_methodologies?: [AudienceEvidenceMethodology, ...AudienceEvidenceMethodology[]]

      1

    • Optionalexcluded_methodologies?: [AudienceEvidenceMethodology, ...AudienceEvidenceMethodology[]]

      1

    • Optionalaccepted_evidence_types?: [
          "forecast"
          | "measured"
          | "seller_declared",
          ...("forecast" | "measured" | "seller_declared")[],
      ]

      1

    • Optionalaccepted_providers?: [BrandKey, ...BrandKey[]]

      1

    • Optionalexcluded_providers?: [BrandKey, ...BrandKey[]]

      1

    • Optionalaccepted_subject_types?: [AudienceSubjectType, ...AudienceSubjectType[]]

      1

    • Optionalaccepted_resolution_methods?: [AudienceResolutionMethod, ...AudienceResolutionMethod[]]

      1

    • Optionalminimum_confidence?: number
    • Optionalmaximum_age?: Duration & { unit?: "seconds" | "minutes" | "hours" | "days" }
    • Optionalmethodology_documentation_required?: boolean
    • Optionalindependent_attestation_required?: boolean
    • Optionalaccepted_attestation_issuers?: [
          | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
          | { type: "agent"; agent_url: string; ext?: ExtensionObject }
          | { type: "origin"; origin: string; ext?: ExtensionObject },
          ...(
              | { type: "brand"; brand: BrandKey; ext?: ExtensionObject }
              | { type: "agent"; agent_url: string; ext?: ExtensionObject }
              | { type: "origin"; origin: string; ext?: ExtensionObject }
          )[],
      ]

      1

    • Optionalaccepted_attestation_claim_types?: [string, ...string[]]

      1

    • Optionalext?: ExtensionObject
    audience_evidence_pins?: [AudienceEvidencePin, ...AudienceEvidencePin[]]

    Exact immutable audience-evidence snapshots selected for package construction.

    1

    agency_estimate_number?: string

    Package-level agency estimate or authorization reference.

    context?: ContextObject
    measurement_terms?: ProductPurchaseMeasurementTerms
    performance_standards?: [
        CanonicalPerformanceStandard,
        ...CanonicalPerformanceStandard[],
    ]

    Published or negotiated metric thresholds and measurement vendors. Direct buyers may omit this to inherit the product defaults; accepted proposal snapshots preserve every applicable standard.

    1