1<html><body> 2<style> 3 4body, h1, h2, h3, div, span, p, pre, a { 5 margin: 0; 6 padding: 0; 7 border: 0; 8 font-weight: inherit; 9 font-style: inherit; 10 font-size: 100%; 11 font-family: inherit; 12 vertical-align: baseline; 13} 14 15body { 16 font-size: 13px; 17 padding: 1em; 18} 19 20h1 { 21 font-size: 26px; 22 margin-bottom: 1em; 23} 24 25h2 { 26 font-size: 24px; 27 margin-bottom: 1em; 28} 29 30h3 { 31 font-size: 20px; 32 margin-bottom: 1em; 33 margin-top: 1em; 34} 35 36pre, code { 37 line-height: 1.5; 38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; 39} 40 41pre { 42 margin-top: 0.5em; 43} 44 45h1, h2, h3, p { 46 font-family: Arial, sans serif; 47} 48 49h1, h2, h3 { 50 border-bottom: solid #CCC 1px; 51} 52 53.toc_element { 54 margin-top: 0.5em; 55} 56 57.firstline { 58 margin-left: 2 em; 59} 60 61.method { 62 margin-top: 1em; 63 border: solid 1px #CCC; 64 padding: 1em; 65 background: #EEE; 66} 67 68.details { 69 font-weight: bold; 70 font-size: 14px; 71} 72 73</style> 74 75<h1><a href="content_v2_1.html">Content API for Shopping</a> . <a href="content_v2_1.repricingrules.html">repricingrules</a></h1> 76<h2>Instance Methods</h2> 77<p class="toc_element"> 78 <code><a href="content_v2_1.repricingrules.repricingreports.html">repricingreports()</a></code> 79</p> 80<p class="firstline">Returns the repricingreports Resource.</p> 81 82<p class="toc_element"> 83 <code><a href="#close">close()</a></code></p> 84<p class="firstline">Close httplib2 connections.</p> 85<p class="toc_element"> 86 <code><a href="#create">create(merchantId, body=None, ruleId=None, x__xgafv=None)</a></code></p> 87<p class="firstline">Creates a repricing rule for your Merchant Center account.</p> 88<p class="toc_element"> 89 <code><a href="#delete">delete(merchantId, ruleId, x__xgafv=None)</a></code></p> 90<p class="firstline">Deletes a repricing rule in your Merchant Center account.</p> 91<p class="toc_element"> 92 <code><a href="#get">get(merchantId, ruleId, x__xgafv=None)</a></code></p> 93<p class="firstline">Retrieves a repricing rule from your Merchant Center account.</p> 94<p class="toc_element"> 95 <code><a href="#list">list(merchantId, countryCode=None, languageCode=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p> 96<p class="firstline">Lists the repricing rules in your Merchant Center account.</p> 97<p class="toc_element"> 98 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 99<p class="firstline">Retrieves the next page of results.</p> 100<p class="toc_element"> 101 <code><a href="#patch">patch(merchantId, ruleId, body=None, x__xgafv=None)</a></code></p> 102<p class="firstline">Updates a repricing rule in your Merchant Center account. All mutable fields will be overwritten in each update request. In each update, you must provide all required mutable fields, or an error will be thrown. If you do not provide an optional field in the update request, if that field currently exists, it will be deleted from the rule.</p> 103<h3>Method Details</h3> 104<div class="method"> 105 <code class="details" id="close">close()</code> 106 <pre>Close httplib2 connections.</pre> 107</div> 108 109<div class="method"> 110 <code class="details" id="create">create(merchantId, body=None, ruleId=None, x__xgafv=None)</code> 111 <pre>Creates a repricing rule for your Merchant Center account. 112 113Args: 114 merchantId: string, Required. The id of the merchant who owns the repricing rule. (required) 115 body: object, The request body. 116 The object takes the form of: 117 118{ # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 119 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 120 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 121 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 122 }, 123 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 124 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 125 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 126 { # Definition of a fixed time period. 127 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 128 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 129 }, 130 ], 131 }, 132 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 133 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 134 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 135 "A String", 136 ], 137 }, 138 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 139 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 140 "A String", 141 ], 142 }, 143 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 144 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 145 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 146 "A String", 147 ], 148 }, 149 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 150 }, 151 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 152 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 153 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 154 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 155 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 156 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 157 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 158 }, 159 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 160 }, 161 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 162 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 163 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 164 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 165 }, 166 "title": "A String", # The title for the rule. 167 "type": "A String", # Required. Immutable. The type of the rule. 168} 169 170 ruleId: string, Required. The id of the rule to create. 171 x__xgafv: string, V1 error format. 172 Allowed values 173 1 - v1 error format 174 2 - v2 error format 175 176Returns: 177 An object of the form: 178 179 { # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 180 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 181 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 182 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 183 }, 184 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 185 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 186 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 187 { # Definition of a fixed time period. 188 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 189 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 190 }, 191 ], 192 }, 193 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 194 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 195 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 196 "A String", 197 ], 198 }, 199 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 200 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 201 "A String", 202 ], 203 }, 204 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 205 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 206 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 207 "A String", 208 ], 209 }, 210 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 211 }, 212 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 213 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 214 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 215 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 216 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 217 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 218 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 219 }, 220 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 221 }, 222 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 223 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 224 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 225 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 226 }, 227 "title": "A String", # The title for the rule. 228 "type": "A String", # Required. Immutable. The type of the rule. 229}</pre> 230</div> 231 232<div class="method"> 233 <code class="details" id="delete">delete(merchantId, ruleId, x__xgafv=None)</code> 234 <pre>Deletes a repricing rule in your Merchant Center account. 235 236Args: 237 merchantId: string, Required. The id of the merchant who owns the repricing rule. (required) 238 ruleId: string, Required. The id of the rule to Delete. (required) 239 x__xgafv: string, V1 error format. 240 Allowed values 241 1 - v1 error format 242 2 - v2 error format 243</pre> 244</div> 245 246<div class="method"> 247 <code class="details" id="get">get(merchantId, ruleId, x__xgafv=None)</code> 248 <pre>Retrieves a repricing rule from your Merchant Center account. 249 250Args: 251 merchantId: string, Required. The id of the merchant who owns the repricing rule. (required) 252 ruleId: string, Required. The id of the rule to retrieve. (required) 253 x__xgafv: string, V1 error format. 254 Allowed values 255 1 - v1 error format 256 2 - v2 error format 257 258Returns: 259 An object of the form: 260 261 { # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 262 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 263 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 264 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 265 }, 266 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 267 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 268 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 269 { # Definition of a fixed time period. 270 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 271 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 272 }, 273 ], 274 }, 275 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 276 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 277 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 278 "A String", 279 ], 280 }, 281 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 282 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 283 "A String", 284 ], 285 }, 286 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 287 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 288 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 289 "A String", 290 ], 291 }, 292 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 293 }, 294 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 295 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 296 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 297 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 298 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 299 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 300 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 301 }, 302 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 303 }, 304 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 305 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 306 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 307 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 308 }, 309 "title": "A String", # The title for the rule. 310 "type": "A String", # Required. Immutable. The type of the rule. 311}</pre> 312</div> 313 314<div class="method"> 315 <code class="details" id="list">list(merchantId, countryCode=None, languageCode=None, pageSize=None, pageToken=None, x__xgafv=None)</code> 316 <pre>Lists the repricing rules in your Merchant Center account. 317 318Args: 319 merchantId: string, Required. The id of the merchant who owns the repricing rule. (required) 320 countryCode: string, [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"), used as a filter on repricing rules. 321 languageCode: string, The two-letter ISO 639-1 language code associated with the repricing rule, used as a filter. 322 pageSize: integer, The maximum number of repricing rules to return. The service may return fewer than this value. If unspecified, at most 50 rules will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000. 323 pageToken: string, A page token, received from a previous `ListRepricingRules` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListRepricingRules` must match the call that provided the page token. 324 x__xgafv: string, V1 error format. 325 Allowed values 326 1 - v1 error format 327 2 - v2 error format 328 329Returns: 330 An object of the form: 331 332 { # Response message for the `ListRepricingRules` method. 333 "nextPageToken": "A String", # A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages. 334 "repricingRules": [ # The rules from the specified merchant. 335 { # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 336 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 337 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 338 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 339 }, 340 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 341 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 342 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 343 { # Definition of a fixed time period. 344 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 345 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 346 }, 347 ], 348 }, 349 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 350 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 351 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 352 "A String", 353 ], 354 }, 355 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 356 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 357 "A String", 358 ], 359 }, 360 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 361 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 362 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 363 "A String", 364 ], 365 }, 366 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 367 }, 368 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 369 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 370 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 371 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 372 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 373 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 374 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 375 }, 376 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 377 }, 378 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 379 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 380 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 381 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 382 }, 383 "title": "A String", # The title for the rule. 384 "type": "A String", # Required. Immutable. The type of the rule. 385 }, 386 ], 387}</pre> 388</div> 389 390<div class="method"> 391 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 392 <pre>Retrieves the next page of results. 393 394Args: 395 previous_request: The request for the previous page. (required) 396 previous_response: The response from the request for the previous page. (required) 397 398Returns: 399 A request object that you can call 'execute()' on to request the next 400 page. Returns None if there are no more items in the collection. 401 </pre> 402</div> 403 404<div class="method"> 405 <code class="details" id="patch">patch(merchantId, ruleId, body=None, x__xgafv=None)</code> 406 <pre>Updates a repricing rule in your Merchant Center account. All mutable fields will be overwritten in each update request. In each update, you must provide all required mutable fields, or an error will be thrown. If you do not provide an optional field in the update request, if that field currently exists, it will be deleted from the rule. 407 408Args: 409 merchantId: string, Required. The id of the merchant who owns the repricing rule. (required) 410 ruleId: string, Required. The id of the rule to update. (required) 411 body: object, The request body. 412 The object takes the form of: 413 414{ # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 415 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 416 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 417 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 418 }, 419 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 420 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 421 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 422 { # Definition of a fixed time period. 423 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 424 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 425 }, 426 ], 427 }, 428 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 429 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 430 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 431 "A String", 432 ], 433 }, 434 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 435 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 436 "A String", 437 ], 438 }, 439 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 440 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 441 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 442 "A String", 443 ], 444 }, 445 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 446 }, 447 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 448 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 449 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 450 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 451 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 452 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 453 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 454 }, 455 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 456 }, 457 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 458 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 459 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 460 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 461 }, 462 "title": "A String", # The title for the rule. 463 "type": "A String", # Required. Immutable. The type of the rule. 464} 465 466 x__xgafv: string, V1 error format. 467 Allowed values 468 1 - v1 error format 469 2 - v2 error format 470 471Returns: 472 An object of the form: 473 474 { # Represents a repricing rule. A repricing rule is used by shopping serving to adjust transactable offer prices if conditions are met. Next ID: 24 475 "cogsBasedRule": { # A repricing rule that changes the sale price based on cost of goods sale. # The rule definition for TYPE_COGS_BASED. Required when the rule type is TYPE_COGS_BASED. 476 "percentageDelta": 42, # The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. 477 "priceDelta": "A String", # The price delta against the COGS. E.g. 2 means $2 more of the COGS. 478 }, 479 "countryCode": "A String", # Required. Immutable. [CLDR country code](http://www.unicode.org/repos/cldr/tags/latest/common/main/en.xml) (e.g. "US"). 480 "effectiveTimePeriod": { # Required. Time period when the rule should take effect. 481 "fixedTimePeriods": [ # A list of fixed time periods combined with OR. The maximum number of entries is limited to 5. 482 { # Definition of a fixed time period. 483 "endTime": "A String", # The end time (exclusive) of the period. It can only be hour granularity. 484 "startTime": "A String", # The start time (inclusive) of the period. It can only be hour granularity. 485 }, 486 ], 487 }, 488 "eligibleOfferMatcher": { # Matcher that specifies eligible offers. When the USE_FEED_ATTRIBUTE option is selected, only the repricing_rule_id attribute on the product feed is used to specify offer-rule mapping. When the CUSTOM_FILTER option is selected, only the *_matcher fields are used to filter the offers for offer-rule mapping. If the CUSTOM_FILTER option is selected, an offer needs to satisfy each custom filter matcher to be eligible for a rule. Size limit: the sum of the number of entries in all the matchers should not exceed 20. For example, there can be 15 product ids and 5 brands, but not 10 product ids and 11 brands. # Required. Match criteria for the eligible offers. 489 "brandMatcher": { # Matcher by string attributes. # Filter by the brand. 490 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 491 "A String", 492 ], 493 }, 494 "itemGroupIdMatcher": { # Matcher by string attributes. # Filter by the item group id. 495 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 496 "A String", 497 ], 498 }, 499 "matcherOption": "A String", # Determines whether to use the custom matchers or the product feed attribute "repricing_rule_id" to specify offer-rule mapping. 500 "offerIdMatcher": { # Matcher by string attributes. # Filter by the offer id. 501 "strAttributes": [ # String attributes, as long as such attribute of an offer is one of the string attribute values, the offer is considered as passing the matcher. The string matcher checks an offer for inclusivity in the string attributes, not equality. Only literal string matching is supported, no regex. 502 "A String", 503 ], 504 }, 505 "skipWhenOnPromotion": True or False, # When true, the rule won't be applied to offers with active promotions. 506 }, 507 "languageCode": "A String", # Required. Immutable. The two-letter ISO 639-1 language code associated with the repricing rule. 508 "merchantId": "A String", # Output only. Immutable. Merchant that owns the repricing rule. 509 "paused": True or False, # Represents whether a rule is paused. A paused rule will behave like a non-paused rule within CRUD operations, with the major difference that a paused rule will not be evaluated and will have no effect on offers. 510 "restriction": { # Definition of a rule restriction. At least one of the following needs to be true: (1) use_auto_pricing_min_price is true (2) floor.price_delta exists (3) floor.percentage_delta exists If floor.price_delta and floor.percentage_delta are both set on a rule, the highest value will be chosen by the Repricer. In other words, for a product with a price of $50, if the `floor.percentage_delta` is "-10" and the floor.price_delta is "-12", the offer price will only be lowered $5 (10% lower than the original offer price). # Required. Restriction of the rule appliance. 511 "floor": { # Definition of a boundary. # The inclusive floor lower bound. The repricing rule only applies when new price >= floor. 512 "percentageDelta": 42, # The percentage delta relative to the offer selling price. This field is signed. It must be negative in floor. When it is used in floor, it should be > -100. For example, if an offer is selling at $10 and this field is -30 in floor, the repricing rule only applies if the calculated new price is >= $7. 513 "priceDelta": "A String", # The price micros relative to the offer selling price. This field is signed. It must be negative in floor. For example, if an offer is selling at $10 and this field is -$2 in floor, the repricing rule only applies if the calculated new price is >= $8. 514 }, 515 "useAutoPricingMinPrice": True or False, # If true, use the AUTO_PRICING_MIN_PRICE offer attribute as the lower bound of the rule. If use_auto_pricing_min_price is true, then only offers with `AUTO_PRICING_MIN_PRICE` existing on the offer will get Repricer treatment, even if a floor value is set on the rule. Also, if use_auto_pricing_min_price is true, the floor restriction will be ignored. 516 }, 517 "ruleId": "A String", # Output only. Immutable. The ID to uniquely identify each repricing rule. 518 "statsBasedRule": { # Definition of stats based rule. # The rule definition for TYPE_STATS_BASED. Required when the rule type is TYPE_STATS_BASED. 519 "percentageDelta": 42, # The percent change against the price target. Valid from 0 to 100 inclusively. 520 "priceDelta": "A String", # The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. 521 }, 522 "title": "A String", # The title for the rule. 523 "type": "A String", # Required. Immutable. The type of the rule. 524}</pre> 525</div> 526 527</body></html>