1// Copyright 2023 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// http://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 15syntax = "proto3"; 16 17package google.ads.googleads.v16.resources; 18 19import "google/ads/googleads/v16/enums/conversion_value_rule_status.proto"; 20import "google/ads/googleads/v16/enums/value_rule_device_type.proto"; 21import "google/ads/googleads/v16/enums/value_rule_geo_location_match_type.proto"; 22import "google/ads/googleads/v16/enums/value_rule_operation.proto"; 23import "google/api/field_behavior.proto"; 24import "google/api/resource.proto"; 25 26option csharp_namespace = "Google.Ads.GoogleAds.V16.Resources"; 27option go_package = "google.golang.org/genproto/googleapis/ads/googleads/v16/resources;resources"; 28option java_multiple_files = true; 29option java_outer_classname = "ConversionValueRuleProto"; 30option java_package = "com.google.ads.googleads.v16.resources"; 31option objc_class_prefix = "GAA"; 32option php_namespace = "Google\\Ads\\GoogleAds\\V16\\Resources"; 33option ruby_package = "Google::Ads::GoogleAds::V16::Resources"; 34 35// Proto file describing the Conversion Value Rule resource. 36 37// A conversion value rule 38message ConversionValueRule { 39 option (google.api.resource) = { 40 type: "googleads.googleapis.com/ConversionValueRule" 41 pattern: "customers/{customer_id}/conversionValueRules/{conversion_value_rule_id}" 42 }; 43 44 // Action applied when rule is applied. 45 message ValueRuleAction { 46 // Specifies applied operation. 47 google.ads.googleads.v16.enums.ValueRuleOperationEnum.ValueRuleOperation 48 operation = 1; 49 50 // Specifies applied value. 51 double value = 2; 52 } 53 54 // Condition on Geo dimension. 55 message ValueRuleGeoLocationCondition { 56 // Geo locations that advertisers want to exclude. 57 repeated string excluded_geo_target_constants = 1 58 [(google.api.resource_reference) = { 59 type: "googleads.googleapis.com/GeoTargetConstant" 60 }]; 61 62 // Excluded Geo location match type. 63 google.ads.googleads.v16.enums.ValueRuleGeoLocationMatchTypeEnum 64 .ValueRuleGeoLocationMatchType excluded_geo_match_type = 2; 65 66 // Geo locations that advertisers want to include. 67 repeated string geo_target_constants = 3 68 [(google.api.resource_reference) = { 69 type: "googleads.googleapis.com/GeoTargetConstant" 70 }]; 71 72 // Included Geo location match type. 73 google.ads.googleads.v16.enums.ValueRuleGeoLocationMatchTypeEnum 74 .ValueRuleGeoLocationMatchType geo_match_type = 4; 75 } 76 77 // Condition on Device dimension. 78 message ValueRuleDeviceCondition { 79 // Value for device type condition. 80 repeated google.ads.googleads.v16.enums.ValueRuleDeviceTypeEnum 81 .ValueRuleDeviceType device_types = 1; 82 } 83 84 // Condition on Audience dimension. 85 message ValueRuleAudienceCondition { 86 // User Lists. 87 repeated string user_lists = 1 [(google.api.resource_reference) = { 88 type: "googleads.googleapis.com/UserList" 89 }]; 90 91 // User Interests. 92 repeated string user_interests = 2 [(google.api.resource_reference) = { 93 type: "googleads.googleapis.com/UserInterest" 94 }]; 95 } 96 97 // Immutable. The resource name of the conversion value rule. 98 // Conversion value rule resource names have the form: 99 // 100 // `customers/{customer_id}/conversionValueRules/{conversion_value_rule_id}` 101 string resource_name = 1 [ 102 (google.api.field_behavior) = IMMUTABLE, 103 (google.api.resource_reference) = { 104 type: "googleads.googleapis.com/ConversionValueRule" 105 } 106 ]; 107 108 // Output only. The ID of the conversion value rule. 109 int64 id = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; 110 111 // Action applied when the rule is triggered. 112 ValueRuleAction action = 3; 113 114 // Condition for Geo location that must be satisfied for the value rule to 115 // apply. 116 ValueRuleGeoLocationCondition geo_location_condition = 4; 117 118 // Condition for device type that must be satisfied for the value rule to 119 // apply. 120 ValueRuleDeviceCondition device_condition = 5; 121 122 // Condition for audience that must be satisfied for the value rule to apply. 123 ValueRuleAudienceCondition audience_condition = 6; 124 125 // Output only. The resource name of the conversion value rule's owner 126 // customer. When the value rule is inherited from a manager customer, 127 // owner_customer will be the resource name of the manager whereas the 128 // customer in the resource_name will be of the requesting serving customer. 129 // ** Read-only ** 130 string owner_customer = 7 [ 131 (google.api.field_behavior) = OUTPUT_ONLY, 132 (google.api.resource_reference) = { 133 type: "googleads.googleapis.com/Customer" 134 } 135 ]; 136 137 // The status of the conversion value rule. 138 google.ads.googleads.v16.enums.ConversionValueRuleStatusEnum 139 .ConversionValueRuleStatus status = 8; 140} 141