google-ads-googleads 3.0.1 → 3.1.0
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.
- checksums.yaml +4 -4
- data/ChangeLog +3 -0
- data/lib/google/ads/google_ads/factories/v1/enums.rb +1170 -1170
- data/lib/google/ads/google_ads/factories/v1/operations.rb +1236 -1236
- data/lib/google/ads/google_ads/factories/v1/resources.rb +2366 -2366
- data/lib/google/ads/google_ads/factories/v1/services.rb +298 -298
- data/lib/google/ads/google_ads/factories/v2/enums.rb +1140 -1116
- data/lib/google/ads/google_ads/factories/v2/operations.rb +1331 -1331
- data/lib/google/ads/google_ads/factories/v2/resources.rb +2573 -2417
- data/lib/google/ads/google_ads/factories/v2/services.rb +329 -309
- data/lib/google/ads/google_ads/v2/common/ad_type_infos_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/common/metrics_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/enums/policy_review_status_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/enums/reach_plan_ad_length_pb.rb +22 -0
- data/lib/google/ads/google_ads/v2/enums/reach_plan_age_range_pb.rb +45 -0
- data/lib/google/ads/google_ads/v2/errors/authorization_error_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/errors/billing_setup_error_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/errors/errors_pb.rb +2 -0
- data/lib/google/ads/google_ads/v2/errors/feed_item_validation_error_pb.rb +2 -0
- data/lib/google/ads/google_ads/v2/errors/reach_plan_error_pb.rb +19 -0
- data/lib/google/ads/google_ads/v2/resources/campaign_criterion_pb.rb +1 -0
- data/lib/google/ads/google_ads/v2/resources/campaign_pb.rb +13 -13
- data/lib/google/ads/google_ads/v2/resources/customer_client_pb.rb +6 -0
- data/lib/google/ads/google_ads/v2/resources/recommendation_pb.rb +19 -19
- data/lib/google/ads/google_ads/v2/services/billing_setup_service_client.rb +2 -2
- data/lib/google/ads/google_ads/v2/services/billing_setup_service_services_pb.rb +2 -2
- data/lib/google/ads/google_ads/v2/services/campaign_draft_service_client.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/campaign_experiment_service_client.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/label_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/media_file_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/mutate_job_service_client.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/payments_account_service_client.rb +2 -2
- data/lib/google/ads/google_ads/v2/services/payments_account_service_services_pb.rb +3 -3
- data/lib/google/ads/google_ads/v2/services/reach_plan_service_client.rb +436 -0
- data/lib/google/ads/google_ads/v2/services/reach_plan_service_client_config.json +46 -0
- data/lib/google/ads/google_ads/v2/services/reach_plan_service_pb.rb +126 -0
- data/lib/google/ads/google_ads/v2/services/reach_plan_service_services_pb.rb +55 -0
- data/lib/google/ads/google_ads/v2/services/remarketing_action_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/shared_criterion_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/shared_set_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/v2/services/user_list_service_pb.rb +0 -1
- data/lib/google/ads/google_ads/version.rb +1 -1
- metadata +10 -3
@@ -42,6 +42,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
42
42
|
end
|
43
43
|
add_message "google.ads.googleads.v2.common.ExpandedDynamicSearchAdInfo" do
|
44
44
|
optional :description, :message, 1, "google.protobuf.StringValue"
|
45
|
+
optional :description2, :message, 2, "google.protobuf.StringValue"
|
45
46
|
end
|
46
47
|
add_message "google.ads.googleads.v2.common.HotelAdInfo" do
|
47
48
|
end
|
@@ -67,6 +67,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
67
67
|
optional :engagement_rate, :message, 31, "google.protobuf.DoubleValue"
|
68
68
|
optional :engagements, :message, 32, "google.protobuf.Int64Value"
|
69
69
|
optional :hotel_average_lead_value_micros, :message, 75, "google.protobuf.DoubleValue"
|
70
|
+
optional :hotel_price_difference_percentage, :message, 129, "google.protobuf.DoubleValue"
|
70
71
|
optional :historical_creative_quality_score, :enum, 80, "google.ads.googleads.v2.enums.QualityScoreBucketEnum.QualityScoreBucket"
|
71
72
|
optional :historical_landing_page_quality_score, :enum, 81, "google.ads.googleads.v2.enums.QualityScoreBucketEnum.QualityScoreBucket"
|
72
73
|
optional :historical_quality_score, :message, 82, "google.protobuf.Int64Value"
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/ads/google_ads/v2/enums/reach_plan_ad_length.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
|
+
add_message "google.ads.googleads.v2.enums.ReachPlanAdLengthEnum" do
|
9
|
+
end
|
10
|
+
add_enum "google.ads.googleads.v2.enums.ReachPlanAdLengthEnum.ReachPlanAdLength" do
|
11
|
+
value :UNSPECIFIED, 0
|
12
|
+
value :UNKNOWN, 1
|
13
|
+
value :SIX_SECONDS, 2
|
14
|
+
value :FIFTEEN_OR_TWENTY_SECONDS, 3
|
15
|
+
value :TWENTY_SECONDS_OR_MORE, 4
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
module Google::Ads::GoogleAds::V2::Enums
|
20
|
+
ReachPlanAdLengthEnum = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.enums.ReachPlanAdLengthEnum").msgclass
|
21
|
+
ReachPlanAdLengthEnum::ReachPlanAdLength = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.enums.ReachPlanAdLengthEnum.ReachPlanAdLength").enummodule
|
22
|
+
end
|
@@ -0,0 +1,45 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/ads/google_ads/v2/enums/reach_plan_age_range.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
|
+
add_message "google.ads.googleads.v2.enums.ReachPlanAgeRangeEnum" do
|
9
|
+
end
|
10
|
+
add_enum "google.ads.googleads.v2.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange" do
|
11
|
+
value :UNSPECIFIED, 0
|
12
|
+
value :UNKNOWN, 1
|
13
|
+
value :AGE_RANGE_18_24, 503001
|
14
|
+
value :AGE_RANGE_18_34, 2
|
15
|
+
value :AGE_RANGE_18_44, 3
|
16
|
+
value :AGE_RANGE_18_49, 4
|
17
|
+
value :AGE_RANGE_18_54, 5
|
18
|
+
value :AGE_RANGE_18_64, 6
|
19
|
+
value :AGE_RANGE_18_65_UP, 7
|
20
|
+
value :AGE_RANGE_21_34, 8
|
21
|
+
value :AGE_RANGE_25_34, 503002
|
22
|
+
value :AGE_RANGE_25_44, 9
|
23
|
+
value :AGE_RANGE_25_49, 10
|
24
|
+
value :AGE_RANGE_25_54, 11
|
25
|
+
value :AGE_RANGE_25_64, 12
|
26
|
+
value :AGE_RANGE_25_65_UP, 13
|
27
|
+
value :AGE_RANGE_35_44, 503003
|
28
|
+
value :AGE_RANGE_35_49, 14
|
29
|
+
value :AGE_RANGE_35_54, 15
|
30
|
+
value :AGE_RANGE_35_64, 16
|
31
|
+
value :AGE_RANGE_35_65_UP, 17
|
32
|
+
value :AGE_RANGE_45_54, 503004
|
33
|
+
value :AGE_RANGE_45_64, 18
|
34
|
+
value :AGE_RANGE_45_65_UP, 19
|
35
|
+
value :AGE_RANGE_50_65_UP, 20
|
36
|
+
value :AGE_RANGE_55_64, 503005
|
37
|
+
value :AGE_RANGE_55_65_UP, 21
|
38
|
+
value :AGE_RANGE_65_UP, 503006
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
module Google::Ads::GoogleAds::V2::Enums
|
43
|
+
ReachPlanAgeRangeEnum = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.enums.ReachPlanAgeRangeEnum").msgclass
|
44
|
+
ReachPlanAgeRangeEnum::ReachPlanAgeRange = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange").enummodule
|
45
|
+
end
|
@@ -95,6 +95,7 @@ require 'google/ads/google_ads/v2/errors/policy_violation_error_pb'
|
|
95
95
|
require 'google/ads/google_ads/v2/errors/query_error_pb'
|
96
96
|
require 'google/ads/google_ads/v2/errors/quota_error_pb'
|
97
97
|
require 'google/ads/google_ads/v2/errors/range_error_pb'
|
98
|
+
require 'google/ads/google_ads/v2/errors/reach_plan_error_pb'
|
98
99
|
require 'google/ads/google_ads/v2/errors/recommendation_error_pb'
|
99
100
|
require 'google/ads/google_ads/v2/errors/region_code_error_pb'
|
100
101
|
require 'google/ads/google_ads/v2/errors/request_error_pb'
|
@@ -228,6 +229,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
228
229
|
optional :manager_link_error, :enum, 121, "google.ads.googleads.v2.errors.ManagerLinkErrorEnum.ManagerLinkError"
|
229
230
|
optional :currency_code_error, :enum, 122, "google.ads.googleads.v2.errors.CurrencyCodeErrorEnum.CurrencyCodeError"
|
230
231
|
optional :access_invitation_error, :enum, 124, "google.ads.googleads.v2.errors.AccessInvitationErrorEnum.AccessInvitationError"
|
232
|
+
optional :reach_plan_error, :enum, 125, "google.ads.googleads.v2.errors.ReachPlanErrorEnum.ReachPlanError"
|
231
233
|
end
|
232
234
|
end
|
233
235
|
add_message "google.ads.googleads.v2.errors.ErrorLocation" do
|
@@ -105,6 +105,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
105
105
|
value :INVALID_IMAGE_URL, 94
|
106
106
|
value :MISSING_LATITUDE_VALUE, 95
|
107
107
|
value :MISSING_LONGITUDE_VALUE, 96
|
108
|
+
value :ADDRESS_NOT_FOUND, 97
|
109
|
+
value :ADDRESS_NOT_TARGETABLE, 98
|
108
110
|
end
|
109
111
|
end
|
110
112
|
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/ads/google_ads/v2/errors/reach_plan_error.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
|
+
add_message "google.ads.googleads.v2.errors.ReachPlanErrorEnum" do
|
9
|
+
end
|
10
|
+
add_enum "google.ads.googleads.v2.errors.ReachPlanErrorEnum.ReachPlanError" do
|
11
|
+
value :UNSPECIFIED, 0
|
12
|
+
value :UNKNOWN, 1
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
module Google::Ads::GoogleAds::V2::Errors
|
17
|
+
ReachPlanErrorEnum = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.errors.ReachPlanErrorEnum").msgclass
|
18
|
+
ReachPlanErrorEnum::ReachPlanError = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.errors.ReachPlanErrorEnum.ReachPlanError").enummodule
|
19
|
+
end
|
@@ -44,6 +44,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
44
44
|
optional :operating_system_version, :message, 32, "google.ads.googleads.v2.common.OperatingSystemVersionInfo"
|
45
45
|
optional :mobile_device, :message, 33, "google.ads.googleads.v2.common.MobileDeviceInfo"
|
46
46
|
optional :location_group, :message, 34, "google.ads.googleads.v2.common.LocationGroupInfo"
|
47
|
+
optional :custom_affinity, :message, 36, "google.ads.googleads.v2.common.CustomAffinityInfo"
|
47
48
|
end
|
48
49
|
end
|
49
50
|
end
|
@@ -84,20 +84,18 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
84
84
|
add_message "google.ads.googleads.v2.resources.Campaign.HotelSettingInfo" do
|
85
85
|
optional :hotel_center_id, :message, 1, "google.protobuf.Int64Value"
|
86
86
|
end
|
87
|
-
add_message "google.ads.googleads.v2.resources.Campaign.VanityPharma" do
|
88
|
-
optional :vanity_pharma_display_url_mode, :enum, 1, "google.ads.googleads.v2.enums.VanityPharmaDisplayUrlModeEnum.VanityPharmaDisplayUrlMode"
|
89
|
-
optional :vanity_pharma_text, :enum, 2, "google.ads.googleads.v2.enums.VanityPharmaTextEnum.VanityPharmaText"
|
90
|
-
end
|
91
87
|
add_message "google.ads.googleads.v2.resources.Campaign.DynamicSearchAdsSetting" do
|
92
88
|
optional :domain_name, :message, 1, "google.protobuf.StringValue"
|
93
89
|
optional :language_code, :message, 2, "google.protobuf.StringValue"
|
94
90
|
optional :use_supplied_urls_only, :message, 3, "google.protobuf.BoolValue"
|
95
91
|
repeated :feeds, :message, 5, "google.protobuf.StringValue"
|
96
92
|
end
|
97
|
-
add_message "google.ads.googleads.v2.resources.Campaign.
|
98
|
-
optional :
|
99
|
-
|
100
|
-
|
93
|
+
add_message "google.ads.googleads.v2.resources.Campaign.TrackingSetting" do
|
94
|
+
optional :tracking_url, :message, 1, "google.protobuf.StringValue"
|
95
|
+
end
|
96
|
+
add_message "google.ads.googleads.v2.resources.Campaign.VanityPharma" do
|
97
|
+
optional :vanity_pharma_display_url_mode, :enum, 1, "google.ads.googleads.v2.enums.VanityPharmaDisplayUrlModeEnum.VanityPharmaDisplayUrlMode"
|
98
|
+
optional :vanity_pharma_text, :enum, 2, "google.ads.googleads.v2.enums.VanityPharmaTextEnum.VanityPharmaText"
|
101
99
|
end
|
102
100
|
add_message "google.ads.googleads.v2.resources.Campaign.ShoppingSetting" do
|
103
101
|
optional :merchant_id, :message, 1, "google.protobuf.Int64Value"
|
@@ -105,8 +103,10 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
105
103
|
optional :campaign_priority, :message, 3, "google.protobuf.Int32Value"
|
106
104
|
optional :enable_local, :message, 4, "google.protobuf.BoolValue"
|
107
105
|
end
|
108
|
-
add_message "google.ads.googleads.v2.resources.Campaign.
|
109
|
-
optional :
|
106
|
+
add_message "google.ads.googleads.v2.resources.Campaign.AppCampaignSetting" do
|
107
|
+
optional :bidding_strategy_goal_type, :enum, 1, "google.ads.googleads.v2.enums.AppCampaignBiddingStrategyGoalTypeEnum.AppCampaignBiddingStrategyGoalType"
|
108
|
+
optional :app_id, :message, 2, "google.protobuf.StringValue"
|
109
|
+
optional :app_store, :enum, 3, "google.ads.googleads.v2.enums.AppCampaignAppStoreEnum.AppCampaignAppStore"
|
110
110
|
end
|
111
111
|
add_message "google.ads.googleads.v2.resources.Campaign.GeoTargetTypeSetting" do
|
112
112
|
optional :positive_geo_target_type, :enum, 1, "google.ads.googleads.v2.enums.PositiveGeoTargetTypeEnum.PositiveGeoTargetType"
|
@@ -121,11 +121,11 @@ module Google::Ads::GoogleAds::V2::Resources
|
|
121
121
|
Campaign = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign").msgclass
|
122
122
|
Campaign::NetworkSettings = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.NetworkSettings").msgclass
|
123
123
|
Campaign::HotelSettingInfo = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.HotelSettingInfo").msgclass
|
124
|
-
Campaign::VanityPharma = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.VanityPharma").msgclass
|
125
124
|
Campaign::DynamicSearchAdsSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.DynamicSearchAdsSetting").msgclass
|
126
|
-
Campaign::AppCampaignSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.AppCampaignSetting").msgclass
|
127
|
-
Campaign::ShoppingSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.ShoppingSetting").msgclass
|
128
125
|
Campaign::TrackingSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.TrackingSetting").msgclass
|
126
|
+
Campaign::VanityPharma = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.VanityPharma").msgclass
|
127
|
+
Campaign::ShoppingSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.ShoppingSetting").msgclass
|
128
|
+
Campaign::AppCampaignSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.AppCampaignSetting").msgclass
|
129
129
|
Campaign::GeoTargetTypeSetting = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.GeoTargetTypeSetting").msgclass
|
130
130
|
Campaign::SelectiveOptimization = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Campaign.SelectiveOptimization").msgclass
|
131
131
|
end
|
@@ -11,6 +11,12 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
11
11
|
optional :client_customer, :message, 3, "google.protobuf.StringValue"
|
12
12
|
optional :hidden, :message, 4, "google.protobuf.BoolValue"
|
13
13
|
optional :level, :message, 5, "google.protobuf.Int64Value"
|
14
|
+
optional :time_zone, :message, 6, "google.protobuf.StringValue"
|
15
|
+
optional :test_account, :message, 7, "google.protobuf.BoolValue"
|
16
|
+
optional :manager, :message, 8, "google.protobuf.BoolValue"
|
17
|
+
optional :descriptive_name, :message, 9, "google.protobuf.StringValue"
|
18
|
+
optional :currency_code, :message, 10, "google.protobuf.StringValue"
|
19
|
+
optional :id, :message, 11, "google.protobuf.Int64Value"
|
14
20
|
end
|
15
21
|
end
|
16
22
|
|
@@ -61,13 +61,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
61
61
|
optional :keyword, :message, 1, "google.ads.googleads.v2.common.KeywordInfo"
|
62
62
|
optional :recommended_cpc_bid_micros, :message, 2, "google.protobuf.Int64Value"
|
63
63
|
end
|
64
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.
|
65
|
-
|
66
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.CalloutExtensionRecommendation" do
|
67
|
-
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.CalloutFeedItem"
|
68
|
-
end
|
69
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.SitelinkExtensionRecommendation" do
|
70
|
-
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.SitelinkFeedItem"
|
64
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.MaximizeClicksOptInRecommendation" do
|
65
|
+
optional :recommended_budget_amount_micros, :message, 1, "google.protobuf.Int64Value"
|
71
66
|
end
|
72
67
|
add_message "google.ads.googleads.v2.resources.Recommendation.TextAdRecommendation" do
|
73
68
|
optional :ad, :message, 1, "google.ads.googleads.v2.resources.Ad"
|
@@ -87,24 +82,29 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
87
82
|
add_message "google.ads.googleads.v2.resources.Recommendation.MaximizeConversionsOptInRecommendation" do
|
88
83
|
optional :recommended_budget_amount_micros, :message, 1, "google.protobuf.Int64Value"
|
89
84
|
end
|
90
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.
|
85
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.SitelinkExtensionRecommendation" do
|
86
|
+
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.SitelinkFeedItem"
|
91
87
|
end
|
92
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.
|
88
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.EnhancedCpcOptInRecommendation" do
|
93
89
|
end
|
94
90
|
add_message "google.ads.googleads.v2.resources.Recommendation.KeywordMatchTypeRecommendation" do
|
95
91
|
optional :keyword, :message, 1, "google.ads.googleads.v2.common.KeywordInfo"
|
96
92
|
optional :recommended_match_type, :enum, 2, "google.ads.googleads.v2.enums.KeywordMatchTypeEnum.KeywordMatchType"
|
97
93
|
end
|
98
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.
|
99
|
-
optional :recommended_budget_amount_micros, :message, 1, "google.protobuf.Int64Value"
|
94
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.SearchPartnersOptInRecommendation" do
|
100
95
|
end
|
101
|
-
add_message "google.ads.googleads.v2.resources.Recommendation.
|
102
|
-
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.CallFeedItem"
|
96
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.OptimizeAdRotationRecommendation" do
|
103
97
|
end
|
104
98
|
add_message "google.ads.googleads.v2.resources.Recommendation.MoveUnusedBudgetRecommendation" do
|
105
99
|
optional :excess_campaign_budget, :message, 1, "google.protobuf.StringValue"
|
106
100
|
optional :budget_recommendation, :message, 2, "google.ads.googleads.v2.resources.Recommendation.CampaignBudgetRecommendation"
|
107
101
|
end
|
102
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.CalloutExtensionRecommendation" do
|
103
|
+
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.CalloutFeedItem"
|
104
|
+
end
|
105
|
+
add_message "google.ads.googleads.v2.resources.Recommendation.CallExtensionRecommendation" do
|
106
|
+
repeated :recommended_extensions, :message, 1, "google.ads.googleads.v2.common.CallFeedItem"
|
107
|
+
end
|
108
108
|
end
|
109
109
|
|
110
110
|
module Google::Ads::GoogleAds::V2::Resources
|
@@ -114,17 +114,17 @@ module Google::Ads::GoogleAds::V2::Resources
|
|
114
114
|
Recommendation::CampaignBudgetRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.CampaignBudgetRecommendation").msgclass
|
115
115
|
Recommendation::CampaignBudgetRecommendation::CampaignBudgetRecommendationOption = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.CampaignBudgetRecommendation.CampaignBudgetRecommendationOption").msgclass
|
116
116
|
Recommendation::KeywordRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.KeywordRecommendation").msgclass
|
117
|
-
Recommendation::
|
118
|
-
Recommendation::CalloutExtensionRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.CalloutExtensionRecommendation").msgclass
|
119
|
-
Recommendation::SitelinkExtensionRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.SitelinkExtensionRecommendation").msgclass
|
117
|
+
Recommendation::MaximizeClicksOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.MaximizeClicksOptInRecommendation").msgclass
|
120
118
|
Recommendation::TextAdRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.TextAdRecommendation").msgclass
|
121
119
|
Recommendation::TargetCpaOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.TargetCpaOptInRecommendation").msgclass
|
122
120
|
Recommendation::TargetCpaOptInRecommendation::TargetCpaOptInRecommendationOption = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.TargetCpaOptInRecommendation.TargetCpaOptInRecommendationOption").msgclass
|
123
121
|
Recommendation::MaximizeConversionsOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.MaximizeConversionsOptInRecommendation").msgclass
|
122
|
+
Recommendation::SitelinkExtensionRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.SitelinkExtensionRecommendation").msgclass
|
124
123
|
Recommendation::EnhancedCpcOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.EnhancedCpcOptInRecommendation").msgclass
|
125
|
-
Recommendation::SearchPartnersOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.SearchPartnersOptInRecommendation").msgclass
|
126
124
|
Recommendation::KeywordMatchTypeRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.KeywordMatchTypeRecommendation").msgclass
|
127
|
-
Recommendation::
|
128
|
-
Recommendation::
|
125
|
+
Recommendation::SearchPartnersOptInRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.SearchPartnersOptInRecommendation").msgclass
|
126
|
+
Recommendation::OptimizeAdRotationRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.OptimizeAdRotationRecommendation").msgclass
|
129
127
|
Recommendation::MoveUnusedBudgetRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.MoveUnusedBudgetRecommendation").msgclass
|
128
|
+
Recommendation::CalloutExtensionRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.CalloutExtensionRecommendation").msgclass
|
129
|
+
Recommendation::CallExtensionRecommendation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.ads.googleads.v2.resources.Recommendation.CallExtensionRecommendation").msgclass
|
130
130
|
end
|
@@ -34,8 +34,8 @@ module Google
|
|
34
34
|
module Services
|
35
35
|
# A service for designating the business entity responsible for accrued costs.
|
36
36
|
#
|
37
|
-
# A billing setup is associated with a
|
38
|
-
# activity for all billing setups associated with a particular
|
37
|
+
# A billing setup is associated with a payments account. Billing-related
|
38
|
+
# activity for all billing setups associated with a particular payments account
|
39
39
|
# will appear on a single invoice generated monthly.
|
40
40
|
#
|
41
41
|
# Mutates:
|
@@ -26,8 +26,8 @@ module Google::Ads::GoogleAds::V2::Services
|
|
26
26
|
#
|
27
27
|
# A service for designating the business entity responsible for accrued costs.
|
28
28
|
#
|
29
|
-
# A billing setup is associated with a
|
30
|
-
# activity for all billing setups associated with a particular
|
29
|
+
# A billing setup is associated with a payments account. Billing-related
|
30
|
+
# activity for all billing setups associated with a particular payments account
|
31
31
|
# will appear on a single invoice generated monthly.
|
32
32
|
#
|
33
33
|
# Mutates:
|
@@ -6,7 +6,6 @@ require 'google/protobuf'
|
|
6
6
|
require 'google/ads/google_ads/v2/resources/label_pb'
|
7
7
|
require 'google/api/annotations_pb'
|
8
8
|
require 'google/protobuf/field_mask_pb'
|
9
|
-
require 'google/protobuf/wrappers_pb'
|
10
9
|
require 'google/rpc/status_pb'
|
11
10
|
require 'google/api/client_pb'
|
12
11
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
@@ -5,7 +5,6 @@ require 'google/protobuf'
|
|
5
5
|
|
6
6
|
require 'google/ads/google_ads/v2/resources/media_file_pb'
|
7
7
|
require 'google/api/annotations_pb'
|
8
|
-
require 'google/protobuf/wrappers_pb'
|
9
8
|
require 'google/rpc/status_pb'
|
10
9
|
require 'google/api/client_pb'
|
11
10
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
@@ -32,7 +32,7 @@ module Google
|
|
32
32
|
module GoogleAds
|
33
33
|
module V2
|
34
34
|
module Services
|
35
|
-
# Service to provide
|
35
|
+
# Service to provide payments accounts that can be used to set up consolidated
|
36
36
|
# billing.
|
37
37
|
#
|
38
38
|
# @!attribute [r] payments_account_service_stub
|
@@ -171,7 +171,7 @@ module Google
|
|
171
171
|
|
172
172
|
# Service calls
|
173
173
|
|
174
|
-
# Returns all
|
174
|
+
# Returns all payments accounts associated with all managers
|
175
175
|
# between the login customer ID and specified serving customer in the
|
176
176
|
# hierarchy, inclusive.
|
177
177
|
#
|
@@ -22,9 +22,9 @@ require 'google/ads/google_ads/v2/services/payments_account_service_pb'
|
|
22
22
|
|
23
23
|
module Google::Ads::GoogleAds::V2::Services
|
24
24
|
module PaymentsAccountService
|
25
|
-
# Proto file describing the
|
25
|
+
# Proto file describing the payments account service.
|
26
26
|
#
|
27
|
-
# Service to provide
|
27
|
+
# Service to provide payments accounts that can be used to set up consolidated
|
28
28
|
# billing.
|
29
29
|
class Service
|
30
30
|
|
@@ -34,7 +34,7 @@ module Google::Ads::GoogleAds::V2::Services
|
|
34
34
|
self.unmarshal_class_method = :decode
|
35
35
|
self.service_name = 'google.ads.googleads.v2.services.PaymentsAccountService'
|
36
36
|
|
37
|
-
# Returns all
|
37
|
+
# Returns all payments accounts associated with all managers
|
38
38
|
# between the login customer ID and specified serving customer in the
|
39
39
|
# hierarchy, inclusive.
|
40
40
|
rpc :ListPaymentsAccounts, ListPaymentsAccountsRequest, ListPaymentsAccountsResponse
|
@@ -0,0 +1,436 @@
|
|
1
|
+
# Copyright 2019 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
#
|
15
|
+
# EDITING INSTRUCTIONS
|
16
|
+
# This file was generated from the file
|
17
|
+
# https://github.com/googleapis/googleapis/blob/master/google/ads/google_ads/v2/services/reach_plan_service.proto,
|
18
|
+
# and updates to that file get reflected here through a refresh process.
|
19
|
+
# For the short term, the refresh process will only be runnable by Google
|
20
|
+
# engineers.
|
21
|
+
|
22
|
+
require "json"
|
23
|
+
require "pathname"
|
24
|
+
|
25
|
+
require "google/gax"
|
26
|
+
|
27
|
+
require "google/ads/google_ads/v2/services/reach_plan_service_pb"
|
28
|
+
require "google/ads/google_ads/v2/services/credentials"
|
29
|
+
|
30
|
+
module Google
|
31
|
+
module Ads
|
32
|
+
module GoogleAds
|
33
|
+
module V2
|
34
|
+
module Services
|
35
|
+
# Reach Plan Service gives users information about audience size that can
|
36
|
+
# be reached through advertisement on YouTube. In particular,
|
37
|
+
# GenerateReachForecast provides estimated number of people of specified
|
38
|
+
# demographics that can be reached by an ad in a given market by a campaign of
|
39
|
+
# certain duration with a defined budget.
|
40
|
+
#
|
41
|
+
# @!attribute [r] reach_plan_service_stub
|
42
|
+
# @return [Google::Ads::GoogleAds::V2::Services::ReachPlanService::Stub]
|
43
|
+
class ReachPlanServiceClient
|
44
|
+
attr_reader :reach_plan_service_stub
|
45
|
+
|
46
|
+
# The default address of the service.
|
47
|
+
SERVICE_ADDRESS = "googleads.googleapis.com".freeze
|
48
|
+
|
49
|
+
# The default port of the service.
|
50
|
+
DEFAULT_SERVICE_PORT = 443
|
51
|
+
|
52
|
+
# The default set of gRPC interceptors.
|
53
|
+
GRPC_INTERCEPTORS = []
|
54
|
+
|
55
|
+
DEFAULT_TIMEOUT = 30
|
56
|
+
|
57
|
+
# The scopes needed to make gRPC calls to all of the methods defined in
|
58
|
+
# this service.
|
59
|
+
ALL_SCOPES = [
|
60
|
+
].freeze
|
61
|
+
|
62
|
+
|
63
|
+
# @param credentials [Google::Auth::Credentials, String, Hash, GRPC::Core::Channel, GRPC::Core::ChannelCredentials, Proc]
|
64
|
+
# Provides the means for authenticating requests made by the client. This parameter can
|
65
|
+
# be many types.
|
66
|
+
# A `Google::Auth::Credentials` uses a the properties of its represented keyfile for
|
67
|
+
# authenticating requests made by this client.
|
68
|
+
# A `String` will be treated as the path to the keyfile to be used for the construction of
|
69
|
+
# credentials for this client.
|
70
|
+
# A `Hash` will be treated as the contents of a keyfile to be used for the construction of
|
71
|
+
# credentials for this client.
|
72
|
+
# A `GRPC::Core::Channel` will be used to make calls through.
|
73
|
+
# A `GRPC::Core::ChannelCredentials` for the setting up the RPC client. The channel credentials
|
74
|
+
# should already be composed with a `GRPC::Core::CallCredentials` object.
|
75
|
+
# A `Proc` will be used as an updater_proc for the Grpc channel. The proc transforms the
|
76
|
+
# metadata for requests, generally, to give OAuth credentials.
|
77
|
+
# @param scopes [Array<String>]
|
78
|
+
# The OAuth scopes for this service. This parameter is ignored if
|
79
|
+
# an updater_proc is supplied.
|
80
|
+
# @param client_config [Hash]
|
81
|
+
# A Hash for call options for each method. See
|
82
|
+
# Google::Gax#construct_settings for the structure of
|
83
|
+
# this data. Falls back to the default config if not specified
|
84
|
+
# or the specified config is missing data points.
|
85
|
+
# @param timeout [Numeric]
|
86
|
+
# The default timeout, in seconds, for calls made through this client.
|
87
|
+
# @param metadata [Hash]
|
88
|
+
# Default metadata to be sent with each request. This can be overridden on a per call basis.
|
89
|
+
# @param exception_transformer [Proc]
|
90
|
+
# An optional proc that intercepts any exceptions raised during an API call to inject
|
91
|
+
# custom error handling.
|
92
|
+
def initialize \
|
93
|
+
credentials: nil,
|
94
|
+
scopes: ALL_SCOPES,
|
95
|
+
client_config: {},
|
96
|
+
timeout: DEFAULT_TIMEOUT,
|
97
|
+
metadata: nil,
|
98
|
+
exception_transformer: nil,
|
99
|
+
lib_name: nil,
|
100
|
+
lib_version: ""
|
101
|
+
# These require statements are intentionally placed here to initialize
|
102
|
+
# the gRPC module only when it's required.
|
103
|
+
# See https://github.com/googleapis/toolkit/issues/446
|
104
|
+
require "google/gax/grpc"
|
105
|
+
require "google/ads/google_ads/v2/services/reach_plan_service_services_pb"
|
106
|
+
|
107
|
+
credentials ||= Google::Ads::GoogleAds::V2::Services::Credentials.default
|
108
|
+
|
109
|
+
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
110
|
+
updater_proc = Google::Ads::GoogleAds::V2::Services::Credentials.new(credentials).updater_proc
|
111
|
+
end
|
112
|
+
if credentials.is_a?(GRPC::Core::Channel)
|
113
|
+
channel = credentials
|
114
|
+
end
|
115
|
+
if credentials.is_a?(GRPC::Core::ChannelCredentials)
|
116
|
+
chan_creds = credentials
|
117
|
+
end
|
118
|
+
if credentials.is_a?(Proc)
|
119
|
+
updater_proc = credentials
|
120
|
+
end
|
121
|
+
if credentials.is_a?(Google::Auth::Credentials)
|
122
|
+
updater_proc = credentials.updater_proc
|
123
|
+
end
|
124
|
+
|
125
|
+
package_version = Gem.loaded_specs['google-ads-googleads'].version.version
|
126
|
+
|
127
|
+
google_api_client = "gl-ruby/#{RUBY_VERSION}"
|
128
|
+
google_api_client << " #{lib_name}/#{lib_version}" if lib_name
|
129
|
+
google_api_client << " gapic/#{package_version} gax/#{Google::Gax::VERSION}"
|
130
|
+
google_api_client << " grpc/#{GRPC::VERSION}"
|
131
|
+
google_api_client.freeze
|
132
|
+
|
133
|
+
headers = { :"x-goog-api-client" => google_api_client }
|
134
|
+
headers.merge!(metadata) unless metadata.nil?
|
135
|
+
client_config_file = Pathname.new(__dir__).join(
|
136
|
+
"reach_plan_service_client_config.json"
|
137
|
+
)
|
138
|
+
defaults = client_config_file.open do |f|
|
139
|
+
Google::Gax.construct_settings(
|
140
|
+
"google.ads.googleads.v2.services.ReachPlanService",
|
141
|
+
JSON.parse(f.read),
|
142
|
+
client_config,
|
143
|
+
Google::Gax::Grpc::STATUS_CODE_NAMES,
|
144
|
+
timeout,
|
145
|
+
errors: Google::Gax::Grpc::API_ERRORS,
|
146
|
+
metadata: headers
|
147
|
+
)
|
148
|
+
end
|
149
|
+
|
150
|
+
# Allow overriding the service path/port in subclasses.
|
151
|
+
service_path = self.class::SERVICE_ADDRESS
|
152
|
+
port = self.class::DEFAULT_SERVICE_PORT
|
153
|
+
interceptors = self.class::GRPC_INTERCEPTORS
|
154
|
+
@reach_plan_service_stub = Google::Gax::Grpc.create_stub(
|
155
|
+
service_path,
|
156
|
+
port,
|
157
|
+
chan_creds: chan_creds,
|
158
|
+
channel: channel,
|
159
|
+
updater_proc: updater_proc,
|
160
|
+
scopes: scopes,
|
161
|
+
interceptors: interceptors,
|
162
|
+
&Google::Ads::GoogleAds::V2::Services::ReachPlanService::Stub.method(:new)
|
163
|
+
)
|
164
|
+
|
165
|
+
@list_plannable_locations = Google::Gax.create_api_call(
|
166
|
+
@reach_plan_service_stub.method(:list_plannable_locations),
|
167
|
+
defaults["list_plannable_locations"],
|
168
|
+
exception_transformer: exception_transformer
|
169
|
+
)
|
170
|
+
@list_plannable_products = Google::Gax.create_api_call(
|
171
|
+
@reach_plan_service_stub.method(:list_plannable_products),
|
172
|
+
defaults["list_plannable_products"],
|
173
|
+
exception_transformer: exception_transformer
|
174
|
+
)
|
175
|
+
@generate_product_mix_ideas = Google::Gax.create_api_call(
|
176
|
+
@reach_plan_service_stub.method(:generate_product_mix_ideas),
|
177
|
+
defaults["generate_product_mix_ideas"],
|
178
|
+
exception_transformer: exception_transformer,
|
179
|
+
params_extractor: proc do |request|
|
180
|
+
{'customer_id' => request.customer_id}
|
181
|
+
end
|
182
|
+
)
|
183
|
+
@generate_reach_forecast = Google::Gax.create_api_call(
|
184
|
+
@reach_plan_service_stub.method(:generate_reach_forecast),
|
185
|
+
defaults["generate_reach_forecast"],
|
186
|
+
exception_transformer: exception_transformer,
|
187
|
+
params_extractor: proc do |request|
|
188
|
+
{'customer_id' => request.customer_id}
|
189
|
+
end
|
190
|
+
)
|
191
|
+
end
|
192
|
+
|
193
|
+
# Service calls
|
194
|
+
|
195
|
+
# Returns the list of plannable locations (e.g. countries, DMAs).
|
196
|
+
#
|
197
|
+
# @param options [Google::Gax::CallOptions]
|
198
|
+
# Overrides the default settings for this call, e.g, timeout,
|
199
|
+
# retries, etc.
|
200
|
+
# @yield [result, operation] Access the result along with the RPC operation
|
201
|
+
# @yieldparam result [Google::Ads::GoogleAds::V2::Services::ListPlannableLocationsResponse]
|
202
|
+
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
203
|
+
# @return [Google::Ads::GoogleAds::V2::Services::ListPlannableLocationsResponse]
|
204
|
+
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
205
|
+
# @example
|
206
|
+
# require "google/ads/google_ads"
|
207
|
+
#
|
208
|
+
# reach_plan_client = Google::Ads::GoogleAds::ReachPlan.new(version: :v2)
|
209
|
+
# response = reach_plan_client.list_plannable_locations
|
210
|
+
|
211
|
+
def list_plannable_locations options: nil, &block
|
212
|
+
req = Google::Ads::GoogleAds::V2::Services::ListPlannableLocationsRequest.new
|
213
|
+
@list_plannable_locations.call(req, options, &block)
|
214
|
+
end
|
215
|
+
|
216
|
+
# Returns the list of per-location plannable YouTube ad formats with allowed
|
217
|
+
# targeting.
|
218
|
+
#
|
219
|
+
# @param plannable_location_id [Google::Protobuf::StringValue | Hash]
|
220
|
+
# The ID of the selected location for planning. To list the available
|
221
|
+
# plannable location ids use ListPlannableLocations.
|
222
|
+
# A hash of the same form as `Google::Protobuf::StringValue`
|
223
|
+
# can also be provided.
|
224
|
+
# @param options [Google::Gax::CallOptions]
|
225
|
+
# Overrides the default settings for this call, e.g, timeout,
|
226
|
+
# retries, etc.
|
227
|
+
# @yield [result, operation] Access the result along with the RPC operation
|
228
|
+
# @yieldparam result [Google::Ads::GoogleAds::V2::Services::ListPlannableProductsResponse]
|
229
|
+
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
230
|
+
# @return [Google::Ads::GoogleAds::V2::Services::ListPlannableProductsResponse]
|
231
|
+
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
232
|
+
# @example
|
233
|
+
# require "google/ads/google_ads"
|
234
|
+
#
|
235
|
+
# reach_plan_client = Google::Ads::GoogleAds::ReachPlan.new(version: :v2)
|
236
|
+
#
|
237
|
+
# # TODO: Initialize `plannable_location_id`:
|
238
|
+
# plannable_location_id = {}
|
239
|
+
# response = reach_plan_client.list_plannable_products(plannable_location_id)
|
240
|
+
|
241
|
+
def list_plannable_products \
|
242
|
+
plannable_location_id,
|
243
|
+
options: nil,
|
244
|
+
&block
|
245
|
+
req = {
|
246
|
+
plannable_location_id: plannable_location_id
|
247
|
+
}.delete_if { |_, v| v.nil? }
|
248
|
+
req = Google::Gax::to_proto(req, Google::Ads::GoogleAds::V2::Services::ListPlannableProductsRequest)
|
249
|
+
@list_plannable_products.call(req, options, &block)
|
250
|
+
end
|
251
|
+
|
252
|
+
# Generates a product mix ideas given a set of preferences. This method
|
253
|
+
# helps the advertiser to obtain a good mix of ad formats and budget
|
254
|
+
# allocations based on its preferences.
|
255
|
+
#
|
256
|
+
# @param customer_id [String]
|
257
|
+
# The ID of the customer.
|
258
|
+
# @param plannable_location_id [Google::Protobuf::StringValue | Hash]
|
259
|
+
# Required. The ID of the location, this is one of the ids returned by
|
260
|
+
# ListPlannableLocations.
|
261
|
+
# A hash of the same form as `Google::Protobuf::StringValue`
|
262
|
+
# can also be provided.
|
263
|
+
# @param currency_code [Google::Protobuf::StringValue | Hash]
|
264
|
+
# Required. Currency code.
|
265
|
+
# Three-character ISO 4217 currency code.
|
266
|
+
# A hash of the same form as `Google::Protobuf::StringValue`
|
267
|
+
# can also be provided.
|
268
|
+
# @param budget_micros [Google::Protobuf::Int64Value | Hash]
|
269
|
+
# Required. Total budget.
|
270
|
+
# Amount in micros. One million is equivalent to one unit.
|
271
|
+
# A hash of the same form as `Google::Protobuf::Int64Value`
|
272
|
+
# can also be provided.
|
273
|
+
# @param preferences [Google::Ads::GoogleAds::V2::Services::Preferences | Hash]
|
274
|
+
# The preferences of the suggested product mix.
|
275
|
+
# An unset preference is interpreted as all possible values are allowed,
|
276
|
+
# unless explicitly specified.
|
277
|
+
# A hash of the same form as `Google::Ads::GoogleAds::V2::Services::Preferences`
|
278
|
+
# can also be provided.
|
279
|
+
# @param options [Google::Gax::CallOptions]
|
280
|
+
# Overrides the default settings for this call, e.g, timeout,
|
281
|
+
# retries, etc.
|
282
|
+
# @yield [result, operation] Access the result along with the RPC operation
|
283
|
+
# @yieldparam result [Google::Ads::GoogleAds::V2::Services::GenerateProductMixIdeasResponse]
|
284
|
+
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
285
|
+
# @return [Google::Ads::GoogleAds::V2::Services::GenerateProductMixIdeasResponse]
|
286
|
+
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
287
|
+
# @example
|
288
|
+
# require "google/ads/google_ads"
|
289
|
+
#
|
290
|
+
# reach_plan_client = Google::Ads::GoogleAds::ReachPlan.new(version: :v2)
|
291
|
+
#
|
292
|
+
# # TODO: Initialize `customer_id`:
|
293
|
+
# customer_id = ''
|
294
|
+
#
|
295
|
+
# # TODO: Initialize `plannable_location_id`:
|
296
|
+
# plannable_location_id = {}
|
297
|
+
#
|
298
|
+
# # TODO: Initialize `currency_code`:
|
299
|
+
# currency_code = {}
|
300
|
+
#
|
301
|
+
# # TODO: Initialize `budget_micros`:
|
302
|
+
# budget_micros = {}
|
303
|
+
#
|
304
|
+
# # TODO: Initialize `preferences`:
|
305
|
+
# preferences = {}
|
306
|
+
# response = reach_plan_client.generate_product_mix_ideas(customer_id, plannable_location_id, currency_code, budget_micros, preferences)
|
307
|
+
|
308
|
+
def generate_product_mix_ideas \
|
309
|
+
customer_id,
|
310
|
+
plannable_location_id,
|
311
|
+
currency_code,
|
312
|
+
budget_micros,
|
313
|
+
preferences,
|
314
|
+
options: nil,
|
315
|
+
&block
|
316
|
+
req = {
|
317
|
+
customer_id: customer_id,
|
318
|
+
plannable_location_id: plannable_location_id,
|
319
|
+
currency_code: currency_code,
|
320
|
+
budget_micros: budget_micros,
|
321
|
+
preferences: preferences
|
322
|
+
}.delete_if { |_, v| v.nil? }
|
323
|
+
req = Google::Gax::to_proto(req, Google::Ads::GoogleAds::V2::Services::GenerateProductMixIdeasRequest)
|
324
|
+
@generate_product_mix_ideas.call(req, options, &block)
|
325
|
+
end
|
326
|
+
|
327
|
+
# Generates a reach forecast for a given targeting / product mix.
|
328
|
+
#
|
329
|
+
# @param customer_id [String]
|
330
|
+
# The ID of the customer.
|
331
|
+
# @param currency_code [Google::Protobuf::StringValue | Hash]
|
332
|
+
# Required. The currency code.
|
333
|
+
# Three-character ISO 4217 currency code.
|
334
|
+
# A hash of the same form as `Google::Protobuf::StringValue`
|
335
|
+
# can also be provided.
|
336
|
+
# @param campaign_duration [Google::Ads::GoogleAds::V2::Services::CampaignDuration | Hash]
|
337
|
+
# Campaign duration.
|
338
|
+
# A hash of the same form as `Google::Ads::GoogleAds::V2::Services::CampaignDuration`
|
339
|
+
# can also be provided.
|
340
|
+
# @param cookie_frequency_cap [Google::Protobuf::Int32Value | Hash]
|
341
|
+
# Desired cookie frequency cap that will be applied to each planned product.
|
342
|
+
# This is equivalent to the frequency cap exposed in Google Ads when creating
|
343
|
+
# a campaign, it represents the maximum number of times an ad can be shown to
|
344
|
+
# the same user.
|
345
|
+
# If not specified no cap is applied.
|
346
|
+
# A hash of the same form as `Google::Protobuf::Int32Value`
|
347
|
+
# can also be provided.
|
348
|
+
# @param min_effective_frequency [Google::Protobuf::Int32Value | Hash]
|
349
|
+
# Desired minimum effective frequency (the number of times a person was
|
350
|
+
# exposed to the ad) for the reported reach metrics [1-10].
|
351
|
+
# This won't affect the targeting, but just the reporting.
|
352
|
+
# If not specified, a default of 1 is applied.
|
353
|
+
# A hash of the same form as `Google::Protobuf::Int32Value`
|
354
|
+
# can also be provided.
|
355
|
+
# @param targeting [Google::Ads::GoogleAds::V2::Services::Targeting | Hash]
|
356
|
+
# The targeting to be applied to all products selected in the product mix.
|
357
|
+
#
|
358
|
+
# This is planned targeting: execution details might vary based on the
|
359
|
+
# advertising product, please consult an implementation specialist.
|
360
|
+
#
|
361
|
+
# If no targeting dimensions are specified, then campaigns will target
|
362
|
+
# everywhere and everyone.
|
363
|
+
#
|
364
|
+
# See specific metrics for details on how targeting affects them.
|
365
|
+
#
|
366
|
+
# In some cases, targeting may be overridden using the
|
367
|
+
# PlannedProduct.advanced_product_targeting field.
|
368
|
+
# A hash of the same form as `Google::Ads::GoogleAds::V2::Services::Targeting`
|
369
|
+
# can also be provided.
|
370
|
+
# @param planned_products [Array<Google::Ads::GoogleAds::V2::Services::PlannedProduct | Hash>]
|
371
|
+
# The product to be planned.
|
372
|
+
# A hash of the same form as `Google::Ads::GoogleAds::V2::Services::PlannedProduct`
|
373
|
+
# can also be provided.
|
374
|
+
# @param options [Google::Gax::CallOptions]
|
375
|
+
# Overrides the default settings for this call, e.g, timeout,
|
376
|
+
# retries, etc.
|
377
|
+
# @yield [result, operation] Access the result along with the RPC operation
|
378
|
+
# @yieldparam result [Google::Ads::GoogleAds::V2::Services::GenerateReachForecastResponse]
|
379
|
+
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
380
|
+
# @return [Google::Ads::GoogleAds::V2::Services::GenerateReachForecastResponse]
|
381
|
+
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
382
|
+
# @example
|
383
|
+
# require "google/ads/google_ads"
|
384
|
+
#
|
385
|
+
# reach_plan_client = Google::Ads::GoogleAds::ReachPlan.new(version: :v2)
|
386
|
+
#
|
387
|
+
# # TODO: Initialize `customer_id`:
|
388
|
+
# customer_id = ''
|
389
|
+
#
|
390
|
+
# # TODO: Initialize `currency_code`:
|
391
|
+
# currency_code = {}
|
392
|
+
#
|
393
|
+
# # TODO: Initialize `campaign_duration`:
|
394
|
+
# campaign_duration = {}
|
395
|
+
#
|
396
|
+
# # TODO: Initialize `cookie_frequency_cap`:
|
397
|
+
# cookie_frequency_cap = {}
|
398
|
+
#
|
399
|
+
# # TODO: Initialize `min_effective_frequency`:
|
400
|
+
# min_effective_frequency = {}
|
401
|
+
#
|
402
|
+
# # TODO: Initialize `targeting`:
|
403
|
+
# targeting = {}
|
404
|
+
#
|
405
|
+
# # TODO: Initialize `planned_products`:
|
406
|
+
# planned_products = []
|
407
|
+
# response = reach_plan_client.generate_reach_forecast(customer_id, currency_code, campaign_duration, cookie_frequency_cap, min_effective_frequency, targeting, planned_products)
|
408
|
+
|
409
|
+
def generate_reach_forecast \
|
410
|
+
customer_id,
|
411
|
+
currency_code,
|
412
|
+
campaign_duration,
|
413
|
+
cookie_frequency_cap,
|
414
|
+
min_effective_frequency,
|
415
|
+
targeting,
|
416
|
+
planned_products,
|
417
|
+
options: nil,
|
418
|
+
&block
|
419
|
+
req = {
|
420
|
+
customer_id: customer_id,
|
421
|
+
currency_code: currency_code,
|
422
|
+
campaign_duration: campaign_duration,
|
423
|
+
cookie_frequency_cap: cookie_frequency_cap,
|
424
|
+
min_effective_frequency: min_effective_frequency,
|
425
|
+
targeting: targeting,
|
426
|
+
planned_products: planned_products
|
427
|
+
}.delete_if { |_, v| v.nil? }
|
428
|
+
req = Google::Gax::to_proto(req, Google::Ads::GoogleAds::V2::Services::GenerateReachForecastRequest)
|
429
|
+
@generate_reach_forecast.call(req, options, &block)
|
430
|
+
end
|
431
|
+
end
|
432
|
+
end
|
433
|
+
end
|
434
|
+
end
|
435
|
+
end
|
436
|
+
end
|