feat: sync upstream schemas from PR 1252#139
Merged
Conversation
- Synced 315 schemas from adcontextprotocol.org (61 updated, 10 new) - Regenerated Pydantic models from updated schemas - Added backward compat stubs for removed types: DeliverTo, DeliverTo1, Pricing - Exposed new public types: GetAccountFinancialsRequest/Response, ReportUsageRequest/Response, SyncAudiencesRequest/Response, GetCreativeFeaturesRequest/Response, CpaPricingOption, TimeBasedPricingOption, TimeUnit, SignalPricing, SignalPricingOption, OptimizationGoal, CreativeVariant, ArtifactWebhookPayload - Added aliases for new discriminated union responses - Updated tests for schema breaking changes (account/buying_mode now required) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add AccountReference, Overlay, CatalogFieldMapping, CatalogFieldBinding, and Transform to the public API - all were used as field types in exported request/response types but were not directly importable. Add AccountReferenceById / AccountReferenceByNaturalKey aliases for the two identification methods (by seller-assigned ID vs. brand+operator natural key). Clarify DeliverTo/Pricing compat stub comments: the GetSignalsRequest wire format changed (deliver_to.deployments+countries → top-level destinations+countries), so the stubs preserve import compatibility only and cannot restore the old request behavior. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
From code and ad tech expert reviews: 1. Add CpaPricingOption + TimeBasedPricingOption to PricingOption union (they were exported individually but omitted from the union alias) 2. Add SignalPricingOption variant aliases: CpmSignalPricingOption, PercentOfMediaSignalPricingOption, FlatFeeSignalPricingOption (consistent with other discriminated union pattern in aliases.py) 3. Export SyncAudiencesAudience + ConsentBasis for SyncAudiencesRequest construction (same pattern as SyncCreativeResult, SyncCatalogResult) 4. Expose all new/missing types from adcp top-level package: AccountReference, CpaPricingOption, TimeBasedPricingOption, TimeUnit, SignalPricing, SignalPricingOption, GetAccountFinancialsRequest/Response, ReportUsageRequest/Response, SyncAudiencesRequest/Response, GetCreativeFeaturesRequest/Response, CreativeVariant, ArtifactWebhookPayload, OptimizationGoal, CatalogFieldMapping, CatalogFieldBinding, Overlay, Transform, ConsentBasis, SyncCreativeResult 5. Fix __init__.py docstring: correct module reference (_ergonomic not coercion), restore "never import from generated_poc" architectural note Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…eview Sync 315 upstream schemas (61 updated, 10 new) from adcontextprotocol/adcp PR 1252 which fixed 17 schema gaps and 7 consistency issues. Key changes: - Regenerate all types from updated schemas - Add backward compat aliases for pricing renames (CpmAuction/Fixed -> Cpm) - Add backward compat aliases for activation key renames (PropertyId -> SegmentId) - Add backward compat aliases for preview request renames (Format -> Single) - Add compat stubs for removed types (ListAuthorizedProperties, PackageStatus) - Fix SyncAudiencesAudience pointing at wrong Audience type (name collision) - Add new semantic aliases (GetProductsBriefRequest, GetSignalsDiscoveryRequest, etc.) - Export new enums (BuyingMode, MediaChannel, DeviceType, etc.) - Export new models (PaginationRequest, BrandReference, Proposal, etc.) - Re-export DeliverTo, Pricing, Measurement from top-level adcp package - Fix stale stable.py reference in consolidate_exports template - Fix lint violations in consolidate_exports.py Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix silent Status type shadowing: override with MediaBuyDeliveryStatus (delivery status was silently swapped to invoice status due to alphabetical module sort order in _generated.py) - Add CatalogGroupBinding semantic alias for CatalogFieldBinding1 - Add 19 missing types to adcp.__all__ (AccountScope, BuyingMode, AudienceSource, CreativeApprovalStatus, DevicePlatform, DeviceType, EventType, MediaChannel, WcagLevel, ContextObject, ExtensionObject, PaginationRequest, Proposal, BrandReference, DateRange, DatetimeRange, Duration, ErrorCode, Refine) - Remove duplicate PercentOfMediaSignalPricingOption from adcp.__all__ - Move Measurement, DeliverTo, Pricing to backward-compat section - Add 31 backward-compat alias tests covering all 13+ deprecated names - Strengthen weak assertion in test_str_returns_pydantic_default Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Import Status directly from delivery response module instead of reassigning, which mypy rejects as incompatible type assignment. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Backward compat (prevents downstream breakage)
CpmAuctionPricingOptionCpmPricingOptionCpmFixedRatePricingOptionCpmPricingOptionVcpmAuctionPricingOptionVcpmPricingOptionVcpmFixedRatePricingOptionVcpmPricingOptionPropertyIdActivationKeySegmentIdActivationKeyPropertyTagActivationKeyKeyValueActivationKeyPreviewCreativeFormatRequestPreviewCreativeSingleRequestPreviewCreativeManifestRequestPreviewCreativeBatchRequestPreviewCreativeStaticResponsePreviewCreativeSingleResponsePreviewCreativeInteractiveResponsePreviewCreativeBatchResponseListAuthorizedPropertiesRequestextra="allow")ListAuthorizedPropertiesResponseextra="allow")PackageStatusNew public API exports
GetProductsBriefRequest,GetProductsWholesaleRequest,GetSignalsDiscoveryRequest,GetSignalsLookupRequest,SiSendTextMessageRequest,SiSendActionResponseRequest,SegmentIdActivationKey,KeyValueActivationKey,PreviewCreativeSingleRequest/Response,PreviewCreativeBatchRequest/Response,PreviewCreativeVariantRequest/ResponseAudienceSource,BuyingMode,CreativeApprovalStatus,DevicePlatform,DeviceType,EventType,MediaChannel,WcagLevelBrandReference,ContextObject,ExtensionObject,PaginationRequest,ProposalBreaking field-level changes (no backward compat possible)
optimization_goal->optimization_goals(array)catalog->catalogs(array)measurement->outcome_measurementdeployments->destinationsTest plan
ruff check src/ scripts/)adcp.__all__(298 names) andadcp.types.__all__(445 names) fully importableadcppackagefrom adcp import DeliverTo, Pricing, Measurementworks (was missing)🤖 Generated with Claude Code