Skip to content

Commit 8028228

Browse files
committed
Ad Manager v202402 release.
1 parent d112539 commit 8028228

File tree

203 files changed

+316
-333
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

203 files changed

+316
-333
lines changed

ChangeLog

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
41.0.0 -- 02/06/2024
2+
* Added support for v202402.
3+
* Removed support for v202302.
4+
* Removed examples for v202305.
5+
16
40.0.0 -- 11/03/2023
27
* Added support for v202311.
38
* Removed support for v202211.

examples/ad_manager/v202305/activity_group_service/create_activity_groups.py renamed to examples/ad_manager/v202402/activity_group_service/create_activity_groups.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
def main(client, advertiser_company_id):
3939
# Initialize appropriate service.
4040
activity_group_service = client.GetService('ActivityGroupService',
41-
version='v202305')
41+
version='v202402')
4242

4343
# Create a short-term activity group.
4444
short_term_activity_group = {

examples/ad_manager/v202305/activity_group_service/get_active_activity_groups.py renamed to examples/ad_manager/v202402/activity_group_service/get_active_activity_groups.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
def main(client):
2424
# Initialize appropriate service.
2525
activity_group_service = client.GetService(
26-
'ActivityGroupService', version='v202305')
26+
'ActivityGroupService', version='v202402')
2727
# Create a statement to select activity groups.
28-
statement = (ad_manager.StatementBuilder(version='v202305')
28+
statement = (ad_manager.StatementBuilder(version='v202402')
2929
.Where('status = :status')
3030
.WithBindVariable('status', 'ACTIVE'))
3131

examples/ad_manager/v202305/activity_group_service/get_all_activity_groups.py renamed to examples/ad_manager/v202402/activity_group_service/get_all_activity_groups.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
def main(client):
2424
# Initialize appropriate service.
2525
activity_group_service = client.GetService(
26-
'ActivityGroupService', version='v202305')
26+
'ActivityGroupService', version='v202402')
2727

2828
# Create a statement to select activity groups.
29-
statement = ad_manager.StatementBuilder(version='v202305')
29+
statement = ad_manager.StatementBuilder(version='v202402')
3030

3131
# Retrieve a small amount of activity groups at a time, paging
3232
# through until all activity groups have been retrieved.

examples/ad_manager/v202305/activity_group_service/update_activity_groups.py renamed to examples/ad_manager/v202402/activity_group_service/update_activity_groups.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@
3737
def main(client, activity_group_id, advertiser_company_id):
3838
# Initialize appropriate service.
3939
activity_group_service = client.GetService('ActivityGroupService',
40-
version='v202305')
40+
version='v202402')
4141

4242
# Create statement object to select a single activity groups by ID.
43-
statement = (ad_manager.StatementBuilder(version='v202305')
43+
statement = (ad_manager.StatementBuilder(version='v202402')
4444
.Where('id = :activityGroupId')
4545
.WithBindVariable('activityGroupId', int(activity_group_id))
4646
.Limit(1))

examples/ad_manager/v202305/activity_service/create_activities.py renamed to examples/ad_manager/v202402/activity_service/create_activities.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737

3838
def main(client, activity_group_id):
3939
# Initialize appropriate service.
40-
activity_service = client.GetService('ActivityService', version='v202305')
40+
activity_service = client.GetService('ActivityService', version='v202402')
4141

4242
# Create a daily visits activity.
4343
daily_visits_activity = {

examples/ad_manager/v202305/activity_service/get_active_activities.py renamed to examples/ad_manager/v202402/activity_service/get_active_activities.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
activity_service = client.GetService('ActivityService', version='v202305')
25+
activity_service = client.GetService('ActivityService', version='v202402')
2626
# Create a statement to select activities.
27-
statement = (ad_manager.StatementBuilder(version='v202305')
27+
statement = (ad_manager.StatementBuilder(version='v202402')
2828
.Where('status = :status')
2929
.WithBindVariable('status', 'ACTIVE'))
3030

examples/ad_manager/v202305/activity_service/get_all_activities.py renamed to examples/ad_manager/v202402/activity_service/get_all_activities.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
activity_service = client.GetService('ActivityService', version='v202305')
25+
activity_service = client.GetService('ActivityService', version='v202402')
2626

2727
# Create a statement to select activities.
28-
statement = ad_manager.StatementBuilder(version='v202305')
28+
statement = ad_manager.StatementBuilder(version='v202402')
2929

3030
# Retrieve a small amount of activities at a time, paging
3131
# through until all activities have been retrieved.

examples/ad_manager/v202305/activity_service/update_activities.py renamed to examples/ad_manager/v202402/activity_service/update_activities.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@
3535

3636
def main(client, activity_id):
3737
# Initialize appropriate service.
38-
activity_service = client.GetService('ActivityService', version='v202305')
38+
activity_service = client.GetService('ActivityService', version='v202402')
3939

4040
# Create statement object to select one activity by ID to update.
41-
statement = (ad_manager.StatementBuilder(version='v202305')
41+
statement = (ad_manager.StatementBuilder(version='v202402')
4242
.Where('id = :activityId')
4343
.WithBindVariable('activityId', int(activity_id))
4444
.Limit(1))

examples/ad_manager/v202305/adjustment_service/create_forecast_adjustments.py renamed to examples/ad_manager/v202402/adjustment_service/create_forecast_adjustments.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
def main(client, traffic_forecast_segment_id):
2929
# Initialize the adjustment service.
30-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
30+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
3131

3232
# Create a new forecast adjustment for New Year's Day traffic.
3333
this_new_years = datetime.date(datetime.date.today().year, 1, 1)

examples/ad_manager/v202305/adjustment_service/create_traffic_forecast_segments.py renamed to examples/ad_manager/v202402/adjustment_service/create_traffic_forecast_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525

2626
def main(client):
2727
# Initialize the adjustment service and the network service.
28-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
29-
network_service = client.GetService('NetworkService', version='v202305')
28+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
29+
network_service = client.GetService('NetworkService', version='v202402')
3030

3131
# Get the root ad unit id to target the whole site.
3232
current_network = network_service.getCurrentNetwork()

examples/ad_manager/v202305/adjustment_service/get_all_forecast_adjustments.py renamed to examples/ad_manager/v202402/adjustment_service/get_all_forecast_adjustments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
def main(client):
2424
# Initialize the adjustment service.
25-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
25+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
2626

2727
# Create a statement to get all forecast adjustments.
28-
statement = ad_manager.StatementBuilder(version='v202305')
28+
statement = ad_manager.StatementBuilder(version='v202402')
2929

3030
# Retrieve a small number of forecast adjustments at a time, paging
3131
# through until all forecast adjustments have been retrieved.

examples/ad_manager/v202305/adjustment_service/get_all_traffic_forecast_segments.py renamed to examples/ad_manager/v202402/adjustment_service/get_all_traffic_forecast_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
def main(client):
2424
# Initialize the adjustment service.
25-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
25+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
2626

2727
# Create a statement to get all traffic forecast segments.
28-
statement = ad_manager.StatementBuilder(version='v202305')
28+
statement = ad_manager.StatementBuilder(version='v202402')
2929

3030
# Retrieve a small number of segments at a time, paging through until all
3131
# segments have been retrieved.
+2-2
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@
2424

2525
def main(client, traffic_forecast_segment_id):
2626
# Initialize the adjustment service.
27-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
27+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
2828

2929
# Create a statement to get forecast adjustments for a given traffic forecast
3030
# segment id.
31-
statement = ad_manager.StatementBuilder(version='v202305').Where(
31+
statement = ad_manager.StatementBuilder(version='v202402').Where(
3232
'trafficForecastSegmentId = :segmentId').WithBindVariable(
3333
'segmentId', traffic_forecast_segment_id)
3434

examples/ad_manager/v202305/adjustment_service/update_forecast_adjustments.py renamed to examples/ad_manager/v202402/adjustment_service/update_forecast_adjustments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@
2424

2525
def main(client, adjustment_id):
2626
# Initialize the adjustment service.
27-
adjustment_service = client.GetService('AdjustmentService', version='v202305')
27+
adjustment_service = client.GetService('AdjustmentService', version='v202402')
2828

2929
# Create a statement to select a single forecast adjustment by id.
3030
statement = (
3131
ad_manager.StatementBuilder(
32-
version='v202305').Where('id = :id').WithBindVariable(
32+
version='v202402').Where('id = :id').WithBindVariable(
3333
'id', adjustment_id))
3434

3535
# Get the forecast adjustment.

examples/ad_manager/v202305/audience_segment_service/create_audience_segments.py renamed to examples/ad_manager/v202402/audience_segment_service/create_audience_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@
3030
def main(client, custom_targeting_key_id, custom_targeting_value_id):
3131
# Initialize appropriate services.
3232
audience_segment_service = client.GetService(
33-
'AudienceSegmentService', version='v202305')
34-
network_service = client.GetService('NetworkService', version='v202305')
33+
'AudienceSegmentService', version='v202402')
34+
network_service = client.GetService('NetworkService', version='v202402')
3535

3636
# Get the root ad unit ID used to target the entire network.
3737
root_ad_unit_id = (

examples/ad_manager/v202305/audience_segment_service/get_all_audience_segments.py renamed to examples/ad_manager/v202402/audience_segment_service/get_all_audience_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
def main(client):
2424
# Initialize appropriate service.
2525
audience_segment_service = client.GetService(
26-
'AudienceSegmentService', version='v202305')
26+
'AudienceSegmentService', version='v202402')
2727

2828
# Create a statement to select audience segments.
29-
statement = ad_manager.StatementBuilder(version='v202305')
29+
statement = ad_manager.StatementBuilder(version='v202402')
3030

3131
# Retrieve a small amount of audience segments at a time, paging
3232
# through until all audience segments have been retrieved.

examples/ad_manager/v202305/audience_segment_service/get_first_party_audience_segments.py renamed to examples/ad_manager/v202402/audience_segment_service/get_first_party_audience_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
def main(client):
2424
# Initialize appropriate service.
2525
audience_segment_service = client.GetService(
26-
'AudienceSegmentService', version='v202305')
26+
'AudienceSegmentService', version='v202402')
2727
# Create a statement to select audience segments.
28-
statement = (ad_manager.StatementBuilder(version='v202305')
28+
statement = (ad_manager.StatementBuilder(version='v202402')
2929
.Where('type = :type')
3030
.WithBindVariable('type', 'FIRST_PARTY'))
3131

examples/ad_manager/v202305/audience_segment_service/populate_first_party_audience_segments.py renamed to examples/ad_manager/v202402/audience_segment_service/populate_first_party_audience_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@
3030
def main(client, audience_segment_id):
3131
# Initialize appropriate service.
3232
audience_segment_service = client.GetService(
33-
'AudienceSegmentService', version='v202305')
33+
'AudienceSegmentService', version='v202402')
3434

3535
# Create statement object to get the specified first party audience segment.
36-
statement = (ad_manager.StatementBuilder(version='v202305')
36+
statement = (ad_manager.StatementBuilder(version='v202402')
3737
.Where('Type = :type AND Id = :audience_segment_id')
3838
.WithBindVariable('audience_segment_id',
3939
int(audience_segment_id))

examples/ad_manager/v202305/audience_segment_service/update_audience_segments.py renamed to examples/ad_manager/v202402/audience_segment_service/update_audience_segments.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@
2929
def main(client, audience_segment_id):
3030
# Initialize appropriate service.
3131
audience_segment_service = client.GetService(
32-
'AudienceSegmentService', version='v202305')
32+
'AudienceSegmentService', version='v202402')
3333

3434
# Create statement object to get the specified first party audience segment.
35-
statement = (ad_manager.StatementBuilder(version='v202305')
35+
statement = (ad_manager.StatementBuilder(version='v202402')
3636
.Where('Type = :type AND Id = :audience_segment_id')
3737
.WithBindVariable('audience_segment_id',
3838
int(audience_segment_id))

examples/ad_manager/v202305/cdn_configuration_service/create_cdn_configurations.py renamed to examples/ad_manager/v202402/cdn_configuration_service/create_cdn_configurations.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
def main(client):
2828
# Initialize appropriate service.
2929
cdn_config_service = client.GetService('CdnConfigurationService',
30-
version='v202305')
30+
version='v202402')
3131

3232
# Create cdn config objects.
3333
# Only LIVE_STREAM_SOURCE_CONTENT is currently supported by the API.

examples/ad_manager/v202305/cdn_configuration_service/get_all_cdn_configurations.py renamed to examples/ad_manager/v202402/cdn_configuration_service/get_all_cdn_configurations.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@
2626
def main(client):
2727
# Initialize appropriate service.
2828
cdn_config_service = client.GetService('CdnConfigurationService',
29-
version='v202305')
29+
version='v202402')
3030

3131
# Create a statement to select cdn configurations.
32-
statement = ad_manager.StatementBuilder(version='v202305')
32+
statement = ad_manager.StatementBuilder(version='v202402')
3333

3434
# Retrieve a small number of configs at a time, paging
3535
# through until all have been retrieved.

examples/ad_manager/v202305/cms_metadata_service/activate_cms_metadata_values.py renamed to examples/ad_manager/v202402/cms_metadata_service/activate_cms_metadata_values.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
def main(client, cms_metadata_key_id):
2929
# Initialize appropriate service.
3030
cms_metadata_service = client.GetService('CmsMetadataService',
31-
version='v202305')
31+
version='v202402')
3232

3333
# Create query.
34-
statement = (ad_manager.StatementBuilder(version='v202305')
34+
statement = (ad_manager.StatementBuilder(version='v202402')
3535
.Where('cmsKeyId = :cmsKeyId AND status = :status')
3636
.WithBindVariable('status', 'INACTIVE')
3737
.WithBindVariable('cmsKeyId', int(cms_metadata_key_id)))

examples/ad_manager/v202305/cms_metadata_service/get_all_cms_metadata_keys.py renamed to examples/ad_manager/v202402/cms_metadata_service/get_all_cms_metadata_keys.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@
2424
def main(client):
2525
# Initialize appropriate service.
2626
cms_metadata_service = client.GetService(
27-
'CmsMetadataService', version='v202305')
27+
'CmsMetadataService', version='v202402')
2828

2929
# Create a statement to select CmsMetadataKeys.
30-
statement = ad_manager.StatementBuilder(version='v202305')
30+
statement = ad_manager.StatementBuilder(version='v202402')
3131

3232
# Retrieve a small amount of keys at a time, paging
3333
# through until all keys have been retrieved.

examples/ad_manager/v202305/cms_metadata_service/get_all_cms_metadata_values.py renamed to examples/ad_manager/v202402/cms_metadata_service/get_all_cms_metadata_values.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@
2424
def main(client):
2525
# Initialize appropriate service.
2626
cms_metadata_service = client.GetService(
27-
'CmsMetadataService', version='v202305')
27+
'CmsMetadataService', version='v202402')
2828

2929
# Create a statement to select CmsMetadataValues.
30-
statement = ad_manager.StatementBuilder(version='v202305')
30+
statement = ad_manager.StatementBuilder(version='v202402')
3131

3232
# Retrieve a small amount of values at a time, paging
3333
# through until all values have been retrieved.

examples/ad_manager/v202305/cms_metadata_service/get_cms_metadata_values_for_key.py renamed to examples/ad_manager/v202402/cms_metadata_service/get_cms_metadata_values_for_key.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@
2626
def main(client, cms_metadata_key_name):
2727
# Initialize appropriate service.
2828
cms_metadata_service = client.GetService(
29-
'CmsMetadataService', version='v202305')
29+
'CmsMetadataService', version='v202402')
3030

3131
# Create a statement to select CmsMetadataValues for a particular key.
3232
statement = (
33-
ad_manager.StatementBuilder(version='v202305').Where(
33+
ad_manager.StatementBuilder(version='v202402').Where(
3434
'cmsKey = :cmsMetadataKeyName').WithBindVariable(
3535
'cmsMetadataKeyName', cms_metadata_key_name))
3636

examples/ad_manager/v202305/company_service/create_companies.py renamed to examples/ad_manager/v202402/company_service/create_companies.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434

3535
def main(client):
3636
# Initialize appropriate service.
37-
company_service = client.GetService('CompanyService', version='v202305')
37+
company_service = client.GetService('CompanyService', version='v202402')
3838

3939
# Create company objects.
4040
companies = [

examples/ad_manager/v202305/company_service/get_advertisers.py renamed to examples/ad_manager/v202402/company_service/get_advertisers.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
company_service = client.GetService('CompanyService', version='v202305')
25+
company_service = client.GetService('CompanyService', version='v202402')
2626
# Create a statement to select companies.
27-
statement = (ad_manager.StatementBuilder(version='v202305')
27+
statement = (ad_manager.StatementBuilder(version='v202402')
2828
.Where('type = :type')
2929
.WithBindVariable('type', 'ADVERTISER'))
3030

examples/ad_manager/v202305/company_service/get_all_companies.py renamed to examples/ad_manager/v202402/company_service/get_all_companies.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
company_service = client.GetService('CompanyService', version='v202305')
25+
company_service = client.GetService('CompanyService', version='v202402')
2626

2727
# Create a statement to select companies.
28-
statement = ad_manager.StatementBuilder(version='v202305')
28+
statement = ad_manager.StatementBuilder(version='v202402')
2929

3030
# Retrieve a small amount of companies at a time, paging
3131
# through until all companies have been retrieved.

examples/ad_manager/v202305/company_service/update_companies.py renamed to examples/ad_manager/v202402/company_service/update_companies.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@
3535

3636
def main(client, company_id):
3737
# Initialize appropriate service.
38-
company_service = client.GetService('CompanyService', version='v202305')
38+
company_service = client.GetService('CompanyService', version='v202402')
3939

4040
# Create statement object to only select a single company by ID.
41-
statement = (ad_manager.StatementBuilder(version='v202305')
41+
statement = (ad_manager.StatementBuilder(version='v202402')
4242
.Where('id = :id')
4343
.WithBindVariable('id', int(company_id))
4444
.Limit(1))

examples/ad_manager/v202305/contact_service/create_contacts.py renamed to examples/ad_manager/v202402/contact_service/create_contacts.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040

4141
def main(client, advertiser_company_id, agency_company_id):
4242
# Initialize appropriate service.
43-
contact_service = client.GetService('ContactService', version='v202305')
43+
contact_service = client.GetService('ContactService', version='v202402')
4444

4545
# Create an advertiser contact.
4646
advertiser_contact = {

examples/ad_manager/v202305/contact_service/get_all_contacts.py renamed to examples/ad_manager/v202402/contact_service/get_all_contacts.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
contact_service = client.GetService('ContactService', version='v202305')
25+
contact_service = client.GetService('ContactService', version='v202402')
2626

2727
# Create a statement to select contacts.
28-
statement = ad_manager.StatementBuilder(version='v202305')
28+
statement = ad_manager.StatementBuilder(version='v202402')
2929

3030
# Retrieve a small amount of contacts at a time, paging
3131
# through until all contacts have been retrieved.

examples/ad_manager/v202305/contact_service/get_uninvited_contacts.py renamed to examples/ad_manager/v202402/contact_service/get_uninvited_contacts.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222

2323
def main(client):
2424
# Initialize appropriate service.
25-
contact_service = client.GetService('ContactService', version='v202305')
25+
contact_service = client.GetService('ContactService', version='v202402')
2626
# Create a statement to select contacts.
27-
statement = (ad_manager.StatementBuilder(version='v202305')
27+
statement = (ad_manager.StatementBuilder(version='v202402')
2828
.Where('status = :status')
2929
.WithBindVariable('status', 'UNINVITED'))
3030

0 commit comments

Comments
 (0)