adcp 3.0.0__py3-none-any.whl → 3.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
adcp/__init__.py CHANGED
@@ -139,6 +139,8 @@ from adcp.types.aliases import (
139
139
  BuildCreativeSuccessResponse,
140
140
  CreateMediaBuyErrorResponse,
141
141
  CreateMediaBuySuccessResponse,
142
+ Deployment,
143
+ Destination,
142
144
  HtmlPreviewRender,
143
145
  InlineDaastAsset,
144
146
  InlineVastAsset,
@@ -149,10 +151,12 @@ from adcp.types.aliases import (
149
151
  PreviewCreativeInteractiveResponse,
150
152
  PreviewCreativeManifestRequest,
151
153
  PreviewCreativeStaticResponse,
154
+ PricingOption,
152
155
  PropertyId,
153
156
  PropertyTag,
154
157
  ProvidePerformanceFeedbackErrorResponse,
155
158
  ProvidePerformanceFeedbackSuccessResponse,
159
+ PublisherProperties,
156
160
  PublisherPropertiesAll,
157
161
  PublisherPropertiesById,
158
162
  PublisherPropertiesByTag,
@@ -193,7 +197,7 @@ from adcp.webhooks import (
193
197
  get_adcp_signed_headers_for_webhook,
194
198
  )
195
199
 
196
- __version__ = "3.0.0"
200
+ __version__ = "3.1.0"
197
201
 
198
202
 
199
203
  def get_adcp_version() -> str:
@@ -362,6 +366,8 @@ __all__ = [
362
366
  "BuildCreativeErrorResponse",
363
367
  "CreateMediaBuySuccessResponse",
364
368
  "CreateMediaBuyErrorResponse",
369
+ "Deployment",
370
+ "Destination",
365
371
  "HtmlPreviewRender",
366
372
  "InlineDaastAsset",
367
373
  "InlineVastAsset",
@@ -372,10 +378,12 @@ __all__ = [
372
378
  "PreviewCreativeManifestRequest",
373
379
  "PreviewCreativeStaticResponse",
374
380
  "PreviewCreativeInteractiveResponse",
381
+ "PricingOption",
375
382
  "PropertyId",
376
383
  "PropertyTag",
377
384
  "ProvidePerformanceFeedbackSuccessResponse",
378
385
  "ProvidePerformanceFeedbackErrorResponse",
386
+ "PublisherProperties",
379
387
  "PublisherPropertiesAll",
380
388
  "PublisherPropertiesById",
381
389
  "PublisherPropertiesByTag",
adcp/types/__init__.py CHANGED
@@ -289,10 +289,12 @@ from adcp.types.aliases import (
289
289
  PreviewCreativeInteractiveResponse,
290
290
  PreviewCreativeManifestRequest,
291
291
  PreviewCreativeStaticResponse,
292
+ PricingOption,
292
293
  PropertyId,
293
294
  PropertyTag,
294
295
  ProvidePerformanceFeedbackErrorResponse,
295
296
  ProvidePerformanceFeedbackSuccessResponse,
297
+ PublisherProperties,
296
298
  PublisherPropertiesAll,
297
299
  PublisherPropertiesById,
298
300
  PublisherPropertiesByTag,
@@ -602,10 +604,12 @@ __all__ = [
602
604
  "PreviewCreativeInteractiveResponse",
603
605
  "PreviewCreativeManifestRequest",
604
606
  "PreviewCreativeStaticResponse",
607
+ "PricingOption",
605
608
  "PropertyId",
606
609
  "PropertyTag",
607
610
  "ProvidePerformanceFeedbackErrorResponse",
608
611
  "ProvidePerformanceFeedbackSuccessResponse",
612
+ "PublisherProperties",
609
613
  "PublisherPropertiesAll",
610
614
  "PublisherPropertiesById",
611
615
  "PublisherPropertiesByTag",
adcp/types/aliases.py CHANGED
@@ -43,6 +43,11 @@ from adcp.types._generated import (
43
43
  # Build creative responses
44
44
  BuildCreativeResponse1,
45
45
  BuildCreativeResponse2,
46
+ CpcPricingOption,
47
+ CpcvPricingOption,
48
+ CpmPricingOption,
49
+ CppPricingOption,
50
+ CpvPricingOption,
46
51
  # Create media buy responses
47
52
  CreateMediaBuyResponse1,
48
53
  CreateMediaBuyResponse2,
@@ -55,6 +60,7 @@ from adcp.types._generated import (
55
60
  # Destination types
56
61
  Destination1,
57
62
  Destination2,
63
+ FlatRatePricingOption,
58
64
  # Preview creative requests
59
65
  PreviewCreativeRequest1,
60
66
  PreviewCreativeRequest2,
@@ -86,6 +92,7 @@ from adcp.types._generated import (
86
92
  # VAST assets
87
93
  VastAsset1,
88
94
  VastAsset2,
95
+ VcpmPricingOption,
89
96
  )
90
97
  from adcp.types._generated import (
91
98
  PublisherPropertySelector1 as PublisherPropertiesInternal,
@@ -688,6 +695,52 @@ Example:
688
695
  ```
689
696
  """
690
697
 
698
+ # ============================================================================
699
+ # PRICING OPTION UNION TYPE - For Type Hints Without RootModel Wrapper
700
+ # ============================================================================
701
+ # The generated PricingOption is a RootModel wrapper that mypy doesn't recognize
702
+ # as compatible with the individual variant types. This union alias provides a
703
+ # way to type-hint pricing options without the wrapper, fixing mypy list-item errors.
704
+
705
+ PricingOption = (
706
+ CpmPricingOption
707
+ | VcpmPricingOption
708
+ | CpcPricingOption
709
+ | CpcvPricingOption
710
+ | CpvPricingOption
711
+ | CppPricingOption
712
+ | FlatRatePricingOption
713
+ )
714
+ """Union type for all pricing option variants.
715
+
716
+ Use this for type hints when constructing Product.pricing_options or any field
717
+ that accepts pricing options. This fixes mypy list-item errors that occur when
718
+ using the individual variant types.
719
+
720
+ Example:
721
+ ```python
722
+ from adcp.types import Product, CpmPricingOption, PricingOption
723
+
724
+ # Type hint for a list of pricing options
725
+ def get_pricing(options: list[PricingOption]) -> None:
726
+ for opt in options:
727
+ print(f"Model: {opt.pricing_model}")
728
+
729
+ # Use in Product construction (no more mypy errors!)
730
+ product = Product(
731
+ product_id="test",
732
+ name="Test Product",
733
+ pricing_options=[
734
+ CpmPricingOption(
735
+ pricing_model="cpm",
736
+ floor_price=1.50,
737
+ currency="USD"
738
+ )
739
+ ]
740
+ )
741
+ ```
742
+ """
743
+
691
744
  # ============================================================================
692
745
  # EXPORTS
693
746
  # ============================================================================
@@ -759,4 +812,6 @@ __all__ = [
759
812
  "AgentDestination",
760
813
  # Destination union
761
814
  "Destination",
815
+ # Pricing option union
816
+ "PricingOption",
762
817
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: adcp
3
- Version: 3.0.0
3
+ Version: 3.1.0
4
4
  Summary: Official Python client for the Ad Context Protocol (AdCP)
5
5
  Author-email: AdCP Community <maintainers@adcontextprotocol.org>
6
6
  License: Apache-2.0
@@ -1,5 +1,5 @@
1
1
  adcp/ADCP_VERSION,sha256=4oW6SC1eiIraOZfdnNCe_Qfd0_isXJURPFlA7Ec6-vI,13
2
- adcp/__init__.py,sha256=MddC2F2Oe6ugxs-mxvVa7ZOtoq5lpGD2KzPcasgFjgk,10568
2
+ adcp/__init__.py,sha256=pOnFiH-JVPBLm9HZrlDgKsY1_a3tIMoBNqzf-3_S8X0,10730
3
3
  adcp/__main__.py,sha256=wFKbYXRr1nPG9QYMK-fiSJJmkph8WEM8E-fDK8aOF-U,19615
4
4
  adcp/adagents.py,sha256=4mB_OLLZN0tOF7exTkY1GvcztvMPK9s9vgs0WhYytiI,27272
5
5
  adcp/client.py,sha256=zNV8JVb3b2NVlt35600bgoBE-9_JODGuEID3KvmsGZQ,80648
@@ -22,10 +22,10 @@ adcp/server/proposal.py,sha256=Rt2alZk9Zbr23caprg-O2221o9jGgAEmMkCl_VT-z-Q,10482
22
22
  adcp/server/sponsored_intelligence.py,sha256=KzPrISHsI0GqdDO6KJcniQF-3FHHG5AUGBWtuNPDrYI,16500
23
23
  adcp/testing/__init__.py,sha256=ZWp_floWjVZfy8RBG5v_FUXQ8YbN7xjXvVcX-_zl_HU,1416
24
24
  adcp/testing/test_helpers.py,sha256=-UKuxxyKQald5EvXxguQH34b3J0JdsxKH_nRT6GTjkQ,10029
25
- adcp/types/__init__.py,sha256=952bTkc-gqbXZhmedS97OTMFKmn7qtqruiHcPqGXsQ0,16349
25
+ adcp/types/__init__.py,sha256=wWZrkGxbK2jedqa2zxW5NiJZcdzqesylZR2MVGx0KFY,16441
26
26
  adcp/types/_ergonomic.py,sha256=yK1t90GQdnT5fm558Y6vPsDBATaTDJVAbn45QrPfrhY,16732
27
27
  adcp/types/_generated.py,sha256=ktJtTcXj-9fh1hBW1Srj22kqkpL6yTyC5tGfkAl0TYU,34592
28
- adcp/types/aliases.py,sha256=N8uEnCgIOGS5l2uzq76LvLr1Ota9DyycsqC_qj05BBg,26232
28
+ adcp/types/aliases.py,sha256=t0uWtNDggzz3tMgnTNijSI8rTFeB4IY4LBbkcO0dfgg,27958
29
29
  adcp/types/base.py,sha256=R1xPqM4d-SkXae0DB-YJMmneeCrTNZFrQtRlvi5L3KI,8233
30
30
  adcp/types/coercion.py,sha256=gCxMvxcj7sTx75AgEMkdN-xjlYBBH_d9xnvE76NEe4c,6081
31
31
  adcp/types/core.py,sha256=RXkKCWCXS9BVJTNpe3Opm5O1I_LaQPMUuVwa-ipvS1Q,4839
@@ -256,9 +256,9 @@ adcp/utils/format_assets.py,sha256=-0el9vIE_x0j4iEhc8ufIC2AQWZY-YxFBqyCRYfiJDg,6
256
256
  adcp/utils/operation_id.py,sha256=wQX9Bb5epXzRq23xoeYPTqzu5yLuhshg7lKJZihcM2k,294
257
257
  adcp/utils/preview_cache.py,sha256=_zLHqA2SXbV0dCgyy2_Di477RXKnEwPNLEgDoA1uh_A,19966
258
258
  adcp/utils/response_parser.py,sha256=WBYq8bZpPiVrG70PNhHDyE5_NyexS1qlsA8YRkxpZaQ,8986
259
- adcp-3.0.0.dist-info/licenses/LICENSE,sha256=PF39NR3Ae8PLgBhg3Uxw6ju7iGVIf8hfv9LRWQdii_U,629
260
- adcp-3.0.0.dist-info/METADATA,sha256=yvwjpsMw772AA3CecF_SgMn0KHQF_4pawXmX9Jvvu0g,31358
261
- adcp-3.0.0.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
262
- adcp-3.0.0.dist-info/entry_points.txt,sha256=DQKpcGsJX8DtVI_SGApQ7tNvqUB4zkTLaTAEpFgmi3U,44
263
- adcp-3.0.0.dist-info/top_level.txt,sha256=T1_NF0GefncFU9v_k56oDwKSJREyCqIM8lAwNZf0EOs,5
264
- adcp-3.0.0.dist-info/RECORD,,
259
+ adcp-3.1.0.dist-info/licenses/LICENSE,sha256=PF39NR3Ae8PLgBhg3Uxw6ju7iGVIf8hfv9LRWQdii_U,629
260
+ adcp-3.1.0.dist-info/METADATA,sha256=ynnQm8zB1-YsZhC-Jn6XtSOFR1SgCQW-HSzp5AsaE7Y,31358
261
+ adcp-3.1.0.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
262
+ adcp-3.1.0.dist-info/entry_points.txt,sha256=DQKpcGsJX8DtVI_SGApQ7tNvqUB4zkTLaTAEpFgmi3U,44
263
+ adcp-3.1.0.dist-info/top_level.txt,sha256=T1_NF0GefncFU9v_k56oDwKSJREyCqIM8lAwNZf0EOs,5
264
+ adcp-3.1.0.dist-info/RECORD,,
File without changes