adcp 1.6.0__py3-none-any.whl → 2.0.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 +19 -221
- adcp/adagents.py +11 -12
- adcp/client.py +16 -11
- adcp/types/generated.py +540 -1129
- adcp/types/generated_poc/__init__.py +3 -0
- adcp/types/generated_poc/activate_signal_request.py +34 -0
- adcp/types/generated_poc/activate_signal_response.py +57 -0
- adcp/types/generated_poc/activation_key.py +30 -0
- adcp/types/generated_poc/adagents.py +266 -0
- adcp/types/generated_poc/asset_type.py +100 -0
- adcp/types/generated_poc/audio_asset.py +26 -0
- adcp/types/generated_poc/brand_manifest.py +260 -0
- adcp/types/generated_poc/brand_manifest_ref.py +361 -0
- adcp/types/generated_poc/build_creative_request.py +43 -0
- adcp/types/generated_poc/build_creative_response.py +57 -0
- adcp/types/generated_poc/channels.py +19 -0
- adcp/types/generated_poc/cpc_option.py +39 -0
- adcp/types/generated_poc/cpcv_option.py +41 -0
- adcp/types/generated_poc/cpm_auction_option.py +54 -0
- adcp/types/generated_poc/cpm_fixed_option.py +39 -0
- adcp/types/generated_poc/cpp_option.py +60 -0
- adcp/types/generated_poc/cpv_option.py +73 -0
- adcp/types/generated_poc/create_media_buy_request.py +96 -0
- adcp/types/generated_poc/create_media_buy_response.py +66 -0
- adcp/types/generated_poc/creative_asset.py +83 -0
- adcp/types/generated_poc/creative_assignment.py +27 -0
- adcp/types/generated_poc/creative_manifest.py +61 -0
- adcp/types/generated_poc/creative_policy.py +34 -0
- adcp/types/generated_poc/creative_status.py +14 -0
- adcp/types/generated_poc/css_asset.py +20 -0
- adcp/types/generated_poc/daast_asset.py +76 -0
- adcp/types/generated_poc/delivery_metrics.py +111 -0
- adcp/types/generated_poc/delivery_type.py +12 -0
- adcp/types/generated_poc/deployment.py +78 -0
- adcp/types/generated_poc/destination.py +43 -0
- adcp/types/generated_poc/error.py +29 -0
- adcp/types/generated_poc/flat_rate_option.py +93 -0
- adcp/types/generated_poc/format.py +260 -0
- adcp/types/generated_poc/format_id.py +29 -0
- adcp/types/generated_poc/frequency_cap.py +19 -0
- adcp/types/generated_poc/frequency_cap_scope.py +16 -0
- adcp/types/generated_poc/get_media_buy_delivery_request.py +65 -0
- adcp/types/generated_poc/get_media_buy_delivery_response.py +220 -0
- adcp/types/generated_poc/get_products_request.py +83 -0
- adcp/types/generated_poc/get_products_response.py +29 -0
- adcp/types/generated_poc/get_signals_request.py +77 -0
- adcp/types/generated_poc/get_signals_response.py +65 -0
- adcp/types/generated_poc/html_asset.py +18 -0
- adcp/types/generated_poc/identifier_types.py +29 -0
- adcp/types/generated_poc/image_asset.py +23 -0
- adcp/types/generated_poc/index.py +17 -0
- adcp/types/generated_poc/javascript_asset.py +25 -0
- adcp/types/generated_poc/list_authorized_properties_request.py +39 -0
- adcp/types/generated_poc/list_authorized_properties_response.py +85 -0
- adcp/types/generated_poc/list_creative_formats_request.py +93 -0
- adcp/types/generated_poc/list_creative_formats_response.py +63 -0
- adcp/types/generated_poc/list_creatives_request.py +154 -0
- adcp/types/generated_poc/list_creatives_response.py +234 -0
- adcp/types/generated_poc/markdown_asset.py +43 -0
- adcp/types/generated_poc/measurement.py +40 -0
- adcp/types/generated_poc/media_buy.py +37 -0
- adcp/types/generated_poc/media_buy_status.py +14 -0
- adcp/types/generated_poc/pacing.py +13 -0
- adcp/types/generated_poc/package.py +61 -0
- adcp/types/generated_poc/package_request.py +61 -0
- adcp/types/generated_poc/package_status.py +14 -0
- adcp/types/generated_poc/performance_feedback.py +89 -0
- adcp/types/generated_poc/placement.py +37 -0
- adcp/types/generated_poc/preview_creative_request.py +163 -0
- adcp/types/generated_poc/preview_creative_response.py +175 -0
- adcp/types/generated_poc/preview_render.py +144 -0
- adcp/types/generated_poc/pricing_model.py +17 -0
- adcp/types/generated_poc/pricing_option.py +365 -0
- adcp/types/generated_poc/product.py +211 -0
- adcp/types/generated_poc/promoted_offerings.py +102 -0
- adcp/types/generated_poc/promoted_products.py +38 -0
- adcp/types/generated_poc/property.py +79 -0
- adcp/types/generated_poc/protocol_envelope.py +61 -0
- adcp/types/generated_poc/provide_performance_feedback_request.py +85 -0
- adcp/types/generated_poc/provide_performance_feedback_response.py +59 -0
- adcp/types/generated_poc/publisher_identifier_types.py +15 -0
- adcp/types/generated_poc/push_notification_config.py +55 -0
- adcp/types/generated_poc/reporting_capabilities.py +68 -0
- adcp/types/generated_poc/response.py +24 -0
- adcp/types/generated_poc/standard_format_ids.py +45 -0
- adcp/types/generated_poc/start_timing.py +13 -0
- adcp/types/generated_poc/sub_asset.py +55 -0
- adcp/types/generated_poc/sync_creatives_request.py +69 -0
- adcp/types/generated_poc/sync_creatives_response.py +117 -0
- adcp/types/generated_poc/targeting.py +53 -0
- adcp/types/generated_poc/task_status.py +19 -0
- adcp/types/generated_poc/task_type.py +15 -0
- adcp/types/generated_poc/tasks_get_request.py +29 -0
- adcp/types/generated_poc/tasks_get_response.py +112 -0
- adcp/types/generated_poc/tasks_list_request.py +121 -0
- adcp/types/generated_poc/tasks_list_response.py +122 -0
- adcp/types/generated_poc/text_asset.py +20 -0
- adcp/types/generated_poc/update_media_buy_request.py +160 -0
- adcp/types/generated_poc/update_media_buy_response.py +67 -0
- adcp/types/generated_poc/url_asset.py +33 -0
- adcp/types/generated_poc/vast_asset.py +86 -0
- adcp/types/generated_poc/vcpm_auction_option.py +57 -0
- adcp/types/generated_poc/vcpm_fixed_option.py +43 -0
- adcp/types/generated_poc/video_asset.py +28 -0
- adcp/types/generated_poc/webhook_asset.py +65 -0
- adcp/types/generated_poc/webhook_payload.py +102 -0
- adcp/utils/preview_cache.py +57 -39
- adcp/validation.py +172 -0
- {adcp-1.6.0.dist-info → adcp-2.0.0.dist-info}/METADATA +3 -1
- adcp-2.0.0.dist-info/RECORD +130 -0
- adcp/types/tasks.py +0 -511
- adcp-1.6.0.dist-info/RECORD +0 -28
- {adcp-1.6.0.dist-info → adcp-2.0.0.dist-info}/WHEEL +0 -0
- {adcp-1.6.0.dist-info → adcp-2.0.0.dist-info}/entry_points.txt +0 -0
- {adcp-1.6.0.dist-info → adcp-2.0.0.dist-info}/licenses/LICENSE +0 -0
- {adcp-1.6.0.dist-info → adcp-2.0.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: creative-manifest.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
from . import audio_asset, css_asset, daast_asset
|
|
13
|
+
from . import format_id as format_id_1
|
|
14
|
+
from . import (
|
|
15
|
+
html_asset,
|
|
16
|
+
image_asset,
|
|
17
|
+
javascript_asset,
|
|
18
|
+
promoted_offerings,
|
|
19
|
+
text_asset,
|
|
20
|
+
url_asset,
|
|
21
|
+
vast_asset,
|
|
22
|
+
video_asset,
|
|
23
|
+
webhook_asset,
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
class CreativeManifest(AdCPBaseModel):
|
|
28
|
+
model_config = ConfigDict(
|
|
29
|
+
extra="forbid",
|
|
30
|
+
)
|
|
31
|
+
assets: Annotated[
|
|
32
|
+
dict[
|
|
33
|
+
str,
|
|
34
|
+
image_asset.ImageAsset
|
|
35
|
+
| video_asset.VideoAsset
|
|
36
|
+
| audio_asset.AudioAsset
|
|
37
|
+
| text_asset.TextAsset
|
|
38
|
+
| url_asset.UrlAsset
|
|
39
|
+
| html_asset.HtmlAsset
|
|
40
|
+
| javascript_asset.JavascriptAsset
|
|
41
|
+
| webhook_asset.WebhookAsset
|
|
42
|
+
| css_asset.CssAsset
|
|
43
|
+
| promoted_offerings.PromotedOfferings
|
|
44
|
+
| vast_asset.VastAsset1
|
|
45
|
+
| vast_asset.VastAsset2
|
|
46
|
+
| daast_asset.DaastAsset1
|
|
47
|
+
| daast_asset.DaastAsset2,
|
|
48
|
+
],
|
|
49
|
+
Field(
|
|
50
|
+
description="Map of asset IDs to actual asset content. Each key MUST match an asset_id from the format's assets_required array (e.g., 'banner_image', 'clickthrough_url', 'video_file', 'vast_tag'). The asset_id is the technical identifier used to match assets to format requirements.\n\nIMPORTANT: Creative manifest validation MUST be performed in the context of the format specification. The format defines what type each asset_id should be, which eliminates any validation ambiguity."
|
|
51
|
+
),
|
|
52
|
+
]
|
|
53
|
+
format_id: Annotated[
|
|
54
|
+
format_id_1.FormatId, Field(description="Format identifier this manifest is for")
|
|
55
|
+
]
|
|
56
|
+
promoted_offering: Annotated[
|
|
57
|
+
str | None,
|
|
58
|
+
Field(
|
|
59
|
+
description="Product name or offering being advertised. Maps to promoted_offerings in create_media_buy request to associate creative with the product being promoted."
|
|
60
|
+
),
|
|
61
|
+
] = None
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: creative-policy.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from enum import Enum
|
|
8
|
+
from typing import Annotated
|
|
9
|
+
|
|
10
|
+
from adcp.types.base import AdCPBaseModel
|
|
11
|
+
from pydantic import ConfigDict, Field
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class CoBranding(Enum):
|
|
15
|
+
required = "required"
|
|
16
|
+
optional = "optional"
|
|
17
|
+
none = "none"
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
class LandingPage(Enum):
|
|
21
|
+
any = "any"
|
|
22
|
+
retailer_site_only = "retailer_site_only"
|
|
23
|
+
must_include_retailer = "must_include_retailer"
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class CreativePolicy(AdCPBaseModel):
|
|
27
|
+
model_config = ConfigDict(
|
|
28
|
+
extra="forbid",
|
|
29
|
+
)
|
|
30
|
+
co_branding: Annotated[CoBranding, Field(description="Co-branding requirement")]
|
|
31
|
+
landing_page: Annotated[LandingPage, Field(description="Landing page requirements")]
|
|
32
|
+
templates_available: Annotated[
|
|
33
|
+
bool, Field(description="Whether creative templates are provided")
|
|
34
|
+
]
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: creative-status.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from enum import Enum
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class CreativeStatus(Enum):
|
|
11
|
+
processing = "processing"
|
|
12
|
+
approved = "approved"
|
|
13
|
+
rejected = "rejected"
|
|
14
|
+
pending_review = "pending_review"
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: css-asset.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class CssAsset(AdCPBaseModel):
|
|
14
|
+
model_config = ConfigDict(
|
|
15
|
+
extra="forbid",
|
|
16
|
+
)
|
|
17
|
+
content: Annotated[str, Field(description="CSS content")]
|
|
18
|
+
media: Annotated[
|
|
19
|
+
str | None, Field(description="CSS media query context (e.g., 'screen', 'print')")
|
|
20
|
+
] = None
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: daast-asset.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from enum import Enum
|
|
8
|
+
from typing import Annotated, Literal
|
|
9
|
+
|
|
10
|
+
from adcp.types.base import AdCPBaseModel
|
|
11
|
+
from pydantic import AnyUrl, ConfigDict, Field
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DaastVersion(Enum):
|
|
15
|
+
field_1_0 = "1.0"
|
|
16
|
+
field_1_1 = "1.1"
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class TrackingEvent(Enum):
|
|
20
|
+
start = "start"
|
|
21
|
+
firstQuartile = "firstQuartile"
|
|
22
|
+
midpoint = "midpoint"
|
|
23
|
+
thirdQuartile = "thirdQuartile"
|
|
24
|
+
complete = "complete"
|
|
25
|
+
impression = "impression"
|
|
26
|
+
pause = "pause"
|
|
27
|
+
resume = "resume"
|
|
28
|
+
skip = "skip"
|
|
29
|
+
mute = "mute"
|
|
30
|
+
unmute = "unmute"
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
class DaastAsset1(AdCPBaseModel):
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
extra="forbid",
|
|
36
|
+
)
|
|
37
|
+
companion_ads: Annotated[
|
|
38
|
+
bool | None, Field(description="Whether companion display ads are included")
|
|
39
|
+
] = None
|
|
40
|
+
daast_version: Annotated[
|
|
41
|
+
DaastVersion | None, Field(description="DAAST specification version")
|
|
42
|
+
] = None
|
|
43
|
+
delivery_type: Annotated[
|
|
44
|
+
Literal["url"],
|
|
45
|
+
Field(description="Discriminator indicating DAAST is delivered via URL endpoint"),
|
|
46
|
+
]
|
|
47
|
+
duration_ms: Annotated[
|
|
48
|
+
int | None, Field(description="Expected audio duration in milliseconds (if known)", ge=0)
|
|
49
|
+
] = None
|
|
50
|
+
tracking_events: Annotated[
|
|
51
|
+
list[TrackingEvent] | None, Field(description="Tracking events supported by this DAAST tag")
|
|
52
|
+
] = None
|
|
53
|
+
url: Annotated[AnyUrl, Field(description="URL endpoint that returns DAAST XML")]
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
class DaastAsset2(AdCPBaseModel):
|
|
57
|
+
model_config = ConfigDict(
|
|
58
|
+
extra="forbid",
|
|
59
|
+
)
|
|
60
|
+
companion_ads: Annotated[
|
|
61
|
+
bool | None, Field(description="Whether companion display ads are included")
|
|
62
|
+
] = None
|
|
63
|
+
content: Annotated[str, Field(description="Inline DAAST XML content")]
|
|
64
|
+
daast_version: Annotated[
|
|
65
|
+
DaastVersion | None, Field(description="DAAST specification version")
|
|
66
|
+
] = None
|
|
67
|
+
delivery_type: Annotated[
|
|
68
|
+
Literal["inline"],
|
|
69
|
+
Field(description="Discriminator indicating DAAST is delivered as inline XML content"),
|
|
70
|
+
]
|
|
71
|
+
duration_ms: Annotated[
|
|
72
|
+
int | None, Field(description="Expected audio duration in milliseconds (if known)", ge=0)
|
|
73
|
+
] = None
|
|
74
|
+
tracking_events: Annotated[
|
|
75
|
+
list[TrackingEvent] | None, Field(description="Tracking events supported by this DAAST tag")
|
|
76
|
+
] = None
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: delivery-metrics.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class VenueBreakdownItem(AdCPBaseModel):
|
|
14
|
+
model_config = ConfigDict(
|
|
15
|
+
extra="forbid",
|
|
16
|
+
)
|
|
17
|
+
impressions: Annotated[int, Field(description="Impressions delivered at this venue", ge=0)]
|
|
18
|
+
loop_plays: Annotated[int | None, Field(description="Loop plays at this venue", ge=0)] = None
|
|
19
|
+
screens_used: Annotated[
|
|
20
|
+
int | None, Field(description="Number of screens used at this venue", ge=0)
|
|
21
|
+
] = None
|
|
22
|
+
venue_id: Annotated[str, Field(description="Venue identifier")]
|
|
23
|
+
venue_name: Annotated[str | None, Field(description="Human-readable venue name")] = None
|
|
24
|
+
venue_type: Annotated[
|
|
25
|
+
str | None,
|
|
26
|
+
Field(description="Venue type (e.g., 'airport', 'transit', 'retail', 'billboard')"),
|
|
27
|
+
] = None
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class DoohMetrics(AdCPBaseModel):
|
|
31
|
+
model_config = ConfigDict(
|
|
32
|
+
extra="forbid",
|
|
33
|
+
)
|
|
34
|
+
calculation_notes: Annotated[
|
|
35
|
+
str | None, Field(description="Explanation of how DOOH impressions were calculated")
|
|
36
|
+
] = None
|
|
37
|
+
loop_plays: Annotated[
|
|
38
|
+
int | None, Field(description="Number of times ad played in rotation", ge=0)
|
|
39
|
+
] = None
|
|
40
|
+
screen_time_seconds: Annotated[
|
|
41
|
+
int | None, Field(description="Total display time in seconds", ge=0)
|
|
42
|
+
] = None
|
|
43
|
+
screens_used: Annotated[
|
|
44
|
+
int | None, Field(description="Number of unique screens displaying the ad", ge=0)
|
|
45
|
+
] = None
|
|
46
|
+
sov_achieved: Annotated[
|
|
47
|
+
float | None,
|
|
48
|
+
Field(description="Actual share of voice delivered (0.0 to 1.0)", ge=0.0, le=1.0),
|
|
49
|
+
] = None
|
|
50
|
+
venue_breakdown: Annotated[
|
|
51
|
+
list[VenueBreakdownItem] | None, Field(description="Per-venue performance breakdown")
|
|
52
|
+
] = None
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
class QuartileData(AdCPBaseModel):
|
|
56
|
+
q1_views: Annotated[float | None, Field(description="25% completion views", ge=0.0)] = None
|
|
57
|
+
q2_views: Annotated[float | None, Field(description="50% completion views", ge=0.0)] = None
|
|
58
|
+
q3_views: Annotated[float | None, Field(description="75% completion views", ge=0.0)] = None
|
|
59
|
+
q4_views: Annotated[float | None, Field(description="100% completion views", ge=0.0)] = None
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
class DeliveryMetrics(AdCPBaseModel):
|
|
63
|
+
model_config = ConfigDict(
|
|
64
|
+
extra="allow",
|
|
65
|
+
)
|
|
66
|
+
clicks: Annotated[float | None, Field(description="Total clicks", ge=0.0)] = None
|
|
67
|
+
completed_views: Annotated[
|
|
68
|
+
float | None, Field(description="100% completions (for CPCV)", ge=0.0)
|
|
69
|
+
] = None
|
|
70
|
+
completion_rate: Annotated[
|
|
71
|
+
float | None,
|
|
72
|
+
Field(description="Completion rate (completed_views/impressions)", ge=0.0, le=1.0),
|
|
73
|
+
] = None
|
|
74
|
+
conversions: Annotated[
|
|
75
|
+
float | None,
|
|
76
|
+
Field(description="Conversions (reserved for future CPA pricing support)", ge=0.0),
|
|
77
|
+
] = None
|
|
78
|
+
ctr: Annotated[
|
|
79
|
+
float | None, Field(description="Click-through rate (clicks/impressions)", ge=0.0, le=1.0)
|
|
80
|
+
] = None
|
|
81
|
+
dooh_metrics: Annotated[
|
|
82
|
+
DoohMetrics | None,
|
|
83
|
+
Field(description="DOOH-specific metrics (only included for DOOH campaigns)"),
|
|
84
|
+
] = None
|
|
85
|
+
frequency: Annotated[
|
|
86
|
+
float | None,
|
|
87
|
+
Field(
|
|
88
|
+
description="Average frequency per individual (typically measured over campaign duration, but can vary by measurement provider)",
|
|
89
|
+
ge=0.0,
|
|
90
|
+
),
|
|
91
|
+
] = None
|
|
92
|
+
grps: Annotated[
|
|
93
|
+
float | None, Field(description="Gross Rating Points delivered (for CPP)", ge=0.0)
|
|
94
|
+
] = None
|
|
95
|
+
impressions: Annotated[float | None, Field(description="Impressions delivered", ge=0.0)] = None
|
|
96
|
+
leads: Annotated[
|
|
97
|
+
float | None,
|
|
98
|
+
Field(description="Leads generated (reserved for future CPL pricing support)", ge=0.0),
|
|
99
|
+
] = None
|
|
100
|
+
quartile_data: Annotated[
|
|
101
|
+
QuartileData | None, Field(description="Video quartile completion data")
|
|
102
|
+
] = None
|
|
103
|
+
reach: Annotated[
|
|
104
|
+
float | None,
|
|
105
|
+
Field(
|
|
106
|
+
description="Unique reach - units depend on measurement provider (e.g., individuals, households, devices, cookies). See delivery_measurement.provider for methodology.",
|
|
107
|
+
ge=0.0,
|
|
108
|
+
),
|
|
109
|
+
] = None
|
|
110
|
+
spend: Annotated[float | None, Field(description="Amount spent", ge=0.0)] = None
|
|
111
|
+
views: Annotated[float | None, Field(description="Views at threshold (for CPV)", ge=0.0)] = None
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: delivery-type.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from enum import Enum
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class DeliveryType(Enum):
|
|
11
|
+
guaranteed = "guaranteed"
|
|
12
|
+
non_guaranteed = "non_guaranteed"
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: deployment.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated, Literal
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import AnyUrl, AwareDatetime, ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
from . import activation_key as activation_key_1
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class Deployment1(AdCPBaseModel):
|
|
16
|
+
model_config = ConfigDict(
|
|
17
|
+
extra="forbid",
|
|
18
|
+
)
|
|
19
|
+
account: Annotated[str | None, Field(description="Account identifier if applicable")] = None
|
|
20
|
+
activation_key: Annotated[
|
|
21
|
+
activation_key_1.ActivationKey1 | activation_key_1.ActivationKey2 | None,
|
|
22
|
+
Field(
|
|
23
|
+
description="The key to use for targeting. Only present if is_live=true AND requester has access to this destination.",
|
|
24
|
+
title="Activation Key",
|
|
25
|
+
),
|
|
26
|
+
] = None
|
|
27
|
+
deployed_at: Annotated[
|
|
28
|
+
AwareDatetime | None,
|
|
29
|
+
Field(description="Timestamp when activation completed (if is_live=true)"),
|
|
30
|
+
] = None
|
|
31
|
+
estimated_activation_duration_minutes: Annotated[
|
|
32
|
+
float | None,
|
|
33
|
+
Field(
|
|
34
|
+
description="Estimated time to activate if not live, or to complete activation if in progress",
|
|
35
|
+
ge=0.0,
|
|
36
|
+
),
|
|
37
|
+
] = None
|
|
38
|
+
is_live: Annotated[
|
|
39
|
+
bool, Field(description="Whether signal is currently active on this destination")
|
|
40
|
+
]
|
|
41
|
+
platform: Annotated[str, Field(description="Platform identifier for DSPs")]
|
|
42
|
+
type: Annotated[
|
|
43
|
+
Literal["platform"],
|
|
44
|
+
Field(description="Discriminator indicating this is a platform-based deployment"),
|
|
45
|
+
]
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
class Deployment2(AdCPBaseModel):
|
|
49
|
+
model_config = ConfigDict(
|
|
50
|
+
extra="forbid",
|
|
51
|
+
)
|
|
52
|
+
account: Annotated[str | None, Field(description="Account identifier if applicable")] = None
|
|
53
|
+
activation_key: Annotated[
|
|
54
|
+
activation_key_1.ActivationKey1 | activation_key_1.ActivationKey2 | None,
|
|
55
|
+
Field(
|
|
56
|
+
description="The key to use for targeting. Only present if is_live=true AND requester has access to this destination.",
|
|
57
|
+
title="Activation Key",
|
|
58
|
+
),
|
|
59
|
+
] = None
|
|
60
|
+
agent_url: Annotated[AnyUrl, Field(description="URL identifying the destination agent")]
|
|
61
|
+
deployed_at: Annotated[
|
|
62
|
+
AwareDatetime | None,
|
|
63
|
+
Field(description="Timestamp when activation completed (if is_live=true)"),
|
|
64
|
+
] = None
|
|
65
|
+
estimated_activation_duration_minutes: Annotated[
|
|
66
|
+
float | None,
|
|
67
|
+
Field(
|
|
68
|
+
description="Estimated time to activate if not live, or to complete activation if in progress",
|
|
69
|
+
ge=0.0,
|
|
70
|
+
),
|
|
71
|
+
] = None
|
|
72
|
+
is_live: Annotated[
|
|
73
|
+
bool, Field(description="Whether signal is currently active on this destination")
|
|
74
|
+
]
|
|
75
|
+
type: Annotated[
|
|
76
|
+
Literal["agent"],
|
|
77
|
+
Field(description="Discriminator indicating this is an agent URL-based deployment"),
|
|
78
|
+
]
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: destination.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated, Literal
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import AnyUrl, ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Destination1(AdCPBaseModel):
|
|
14
|
+
model_config = ConfigDict(
|
|
15
|
+
extra="forbid",
|
|
16
|
+
)
|
|
17
|
+
account: Annotated[
|
|
18
|
+
str | None, Field(description="Optional account identifier on the platform")
|
|
19
|
+
] = None
|
|
20
|
+
platform: Annotated[
|
|
21
|
+
str,
|
|
22
|
+
Field(description="Platform identifier for DSPs (e.g., 'the-trade-desk', 'amazon-dsp')"),
|
|
23
|
+
]
|
|
24
|
+
type: Annotated[
|
|
25
|
+
Literal["platform"],
|
|
26
|
+
Field(description="Discriminator indicating this is a platform-based destination"),
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class Destination2(AdCPBaseModel):
|
|
31
|
+
model_config = ConfigDict(
|
|
32
|
+
extra="forbid",
|
|
33
|
+
)
|
|
34
|
+
account: Annotated[
|
|
35
|
+
str | None, Field(description="Optional account identifier on the agent")
|
|
36
|
+
] = None
|
|
37
|
+
agent_url: Annotated[
|
|
38
|
+
AnyUrl, Field(description="URL identifying the destination agent (for sales agents, etc.)")
|
|
39
|
+
]
|
|
40
|
+
type: Annotated[
|
|
41
|
+
Literal["agent"],
|
|
42
|
+
Field(description="Discriminator indicating this is an agent URL-based destination"),
|
|
43
|
+
]
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: error.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated, Any
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Error(AdCPBaseModel):
|
|
14
|
+
model_config = ConfigDict(
|
|
15
|
+
extra="forbid",
|
|
16
|
+
)
|
|
17
|
+
code: Annotated[str, Field(description="Error code for programmatic handling")]
|
|
18
|
+
details: Annotated[Any | None, Field(description="Additional task-specific error details")] = (
|
|
19
|
+
None
|
|
20
|
+
)
|
|
21
|
+
field: Annotated[
|
|
22
|
+
str | None,
|
|
23
|
+
Field(description="Field path associated with the error (e.g., 'packages[0].targeting')"),
|
|
24
|
+
] = None
|
|
25
|
+
message: Annotated[str, Field(description="Human-readable error message")]
|
|
26
|
+
retry_after: Annotated[
|
|
27
|
+
float | None, Field(description="Seconds to wait before retrying the operation", ge=0.0)
|
|
28
|
+
] = None
|
|
29
|
+
suggestion: Annotated[str | None, Field(description="Suggested fix for the error")] = None
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# generated by datamodel-codegen:
|
|
2
|
+
# filename: flat-rate-option.json
|
|
3
|
+
# timestamp: 2025-11-15T22:03:55+00:00
|
|
4
|
+
|
|
5
|
+
from __future__ import annotations
|
|
6
|
+
|
|
7
|
+
from typing import Annotated, Literal
|
|
8
|
+
|
|
9
|
+
from adcp.types.base import AdCPBaseModel
|
|
10
|
+
from pydantic import ConfigDict, Field
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Parameters(AdCPBaseModel):
|
|
14
|
+
model_config = ConfigDict(
|
|
15
|
+
extra="forbid",
|
|
16
|
+
)
|
|
17
|
+
daypart: Annotated[
|
|
18
|
+
str | None,
|
|
19
|
+
Field(
|
|
20
|
+
description="Specific daypart for time-based pricing (e.g., 'morning_commute', 'evening_prime', 'overnight')"
|
|
21
|
+
),
|
|
22
|
+
] = None
|
|
23
|
+
duration_hours: Annotated[
|
|
24
|
+
float | None,
|
|
25
|
+
Field(description="Duration in hours for time-based flat rate pricing (DOOH)", ge=0.0),
|
|
26
|
+
] = None
|
|
27
|
+
estimated_impressions: Annotated[
|
|
28
|
+
int | None,
|
|
29
|
+
Field(
|
|
30
|
+
description="Estimated impressions for this flat rate option (informational, commonly used with SOV or time-based DOOH)",
|
|
31
|
+
ge=0,
|
|
32
|
+
),
|
|
33
|
+
] = None
|
|
34
|
+
loop_duration_seconds: Annotated[
|
|
35
|
+
int | None, Field(description="Duration of ad loop rotation in seconds (DOOH)", ge=1)
|
|
36
|
+
] = None
|
|
37
|
+
min_plays_per_hour: Annotated[
|
|
38
|
+
int | None,
|
|
39
|
+
Field(
|
|
40
|
+
description="Minimum number of times ad plays per hour (DOOH frequency guarantee)", ge=0
|
|
41
|
+
),
|
|
42
|
+
] = None
|
|
43
|
+
sov_percentage: Annotated[
|
|
44
|
+
float | None,
|
|
45
|
+
Field(
|
|
46
|
+
description="Guaranteed share of voice as percentage (DOOH, 0-100)", ge=0.0, le=100.0
|
|
47
|
+
),
|
|
48
|
+
] = None
|
|
49
|
+
venue_package: Annotated[
|
|
50
|
+
str | None,
|
|
51
|
+
Field(
|
|
52
|
+
description="Named venue package identifier for DOOH (e.g., 'times_square_network', 'airport_terminals')"
|
|
53
|
+
),
|
|
54
|
+
] = None
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
class FlatRatePricingOption(AdCPBaseModel):
|
|
58
|
+
model_config = ConfigDict(
|
|
59
|
+
extra="forbid",
|
|
60
|
+
)
|
|
61
|
+
currency: Annotated[
|
|
62
|
+
str,
|
|
63
|
+
Field(
|
|
64
|
+
description="ISO 4217 currency code",
|
|
65
|
+
examples=["USD", "EUR", "GBP", "JPY"],
|
|
66
|
+
pattern="^[A-Z]{3}$",
|
|
67
|
+
),
|
|
68
|
+
]
|
|
69
|
+
is_fixed: Annotated[
|
|
70
|
+
Literal[True],
|
|
71
|
+
Field(description="Whether this is a fixed rate (true) or auction-based (false)"),
|
|
72
|
+
]
|
|
73
|
+
min_spend_per_package: Annotated[
|
|
74
|
+
float | None,
|
|
75
|
+
Field(
|
|
76
|
+
description="Minimum spend requirement per package using this pricing option, in the specified currency",
|
|
77
|
+
ge=0.0,
|
|
78
|
+
),
|
|
79
|
+
] = None
|
|
80
|
+
parameters: Annotated[
|
|
81
|
+
Parameters | None,
|
|
82
|
+
Field(description="Flat rate parameters for DOOH and time-based campaigns"),
|
|
83
|
+
] = None
|
|
84
|
+
pricing_model: Annotated[
|
|
85
|
+
Literal["flat_rate"], Field(description="Fixed cost regardless of delivery volume")
|
|
86
|
+
]
|
|
87
|
+
pricing_option_id: Annotated[
|
|
88
|
+
str,
|
|
89
|
+
Field(
|
|
90
|
+
description="Unique identifier for this pricing option within the product (e.g., 'flat_rate_usd_24h_takeover')"
|
|
91
|
+
),
|
|
92
|
+
]
|
|
93
|
+
rate: Annotated[float, Field(description="Flat rate cost", ge=0.0)]
|