Content API for Shopping . returnpolicyonline

Instance Methods

close()

Close httplib2 connections.

create(merchantId, body=None, x__xgafv=None)

Creates a new return policy.

delete(merchantId, returnPolicyId, x__xgafv=None)

Deletes an existing return policy.

get(merchantId, returnPolicyId, x__xgafv=None)

Gets an existing return policy.

list(merchantId, x__xgafv=None)

Lists all existing return policies.

patch(merchantId, returnPolicyId, body=None, x__xgafv=None)

Updates an existing return policy.

Method Details

close()
Close httplib2 connections.
create(merchantId, body=None, x__xgafv=None)
Creates a new return policy.

Args:
  merchantId: string, Required. The id of the merchant for which to retrieve the return policy online object. (required)
  body: object, The request body.
    The object takes the form of:

{ # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
  "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
    "A String",
  ],
  "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
  "name": "A String", # The name of the policy as shown in Merchant Center.
  "policy": { # The available policies. # The return policy.
    "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
    "type": "A String", # Policy type.
  },
  "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
    "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
      "currency": "A String", # The currency of the price.
      "value": "A String", # The price represented as a number.
    },
    "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
  },
  "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
  "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
  "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
    { # The return reason category info wrapper.
      "returnLabelSource": "A String", # The corresponding return label source.
      "returnReasonCategory": "A String", # The return reason category.
      "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
        "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "type": "A String", # Type of return shipping fee.
      },
    },
  ],
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
  "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
    "A String",
  ],
  "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
  "name": "A String", # The name of the policy as shown in Merchant Center.
  "policy": { # The available policies. # The return policy.
    "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
    "type": "A String", # Policy type.
  },
  "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
    "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
      "currency": "A String", # The currency of the price.
      "value": "A String", # The price represented as a number.
    },
    "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
  },
  "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
  "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
  "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
    { # The return reason category info wrapper.
      "returnLabelSource": "A String", # The corresponding return label source.
      "returnReasonCategory": "A String", # The return reason category.
      "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
        "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "type": "A String", # Type of return shipping fee.
      },
    },
  ],
}
delete(merchantId, returnPolicyId, x__xgafv=None)
Deletes an existing return policy.

Args:
  merchantId: string, Required. The id of the merchant for which to retrieve the return policy online object. (required)
  returnPolicyId: string, Required. The id of the return policy to delete. (required)
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format
get(merchantId, returnPolicyId, x__xgafv=None)
Gets an existing return policy.

Args:
  merchantId: string, Required. The id of the merchant for which to retrieve the return policy online object. (required)
  returnPolicyId: string, Required. The id of the return policy to retrieve. (required)
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
  "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
    "A String",
  ],
  "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
  "name": "A String", # The name of the policy as shown in Merchant Center.
  "policy": { # The available policies. # The return policy.
    "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
    "type": "A String", # Policy type.
  },
  "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
    "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
      "currency": "A String", # The currency of the price.
      "value": "A String", # The price represented as a number.
    },
    "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
  },
  "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
  "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
  "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
    { # The return reason category info wrapper.
      "returnLabelSource": "A String", # The corresponding return label source.
      "returnReasonCategory": "A String", # The return reason category.
      "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
        "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "type": "A String", # Type of return shipping fee.
      },
    },
  ],
}
list(merchantId, x__xgafv=None)
Lists all existing return policies.

Args:
  merchantId: string, Required. The id of the merchant for which to retrieve the return policy online object. (required)
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Response message for the `ListReturnPolicyOnline` method.
  "returnPolicies": [ # The retrieved return policies.
    { # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
      "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
        "A String",
      ],
      "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
        "A String",
      ],
      "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
      "name": "A String", # The name of the policy as shown in Merchant Center.
      "policy": { # The available policies. # The return policy.
        "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
        "type": "A String", # Policy type.
      },
      "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
        "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
      },
      "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
        "A String",
      ],
      "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
      "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
      "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
        { # The return reason category info wrapper.
          "returnLabelSource": "A String", # The corresponding return label source.
          "returnReasonCategory": "A String", # The return reason category.
          "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
            "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
              "currency": "A String", # The currency of the price.
              "value": "A String", # The price represented as a number.
            },
            "type": "A String", # Type of return shipping fee.
          },
        },
      ],
    },
  ],
}
patch(merchantId, returnPolicyId, body=None, x__xgafv=None)
Updates an existing return policy.

Args:
  merchantId: string, Required. The id of the merchant for which to retrieve the return policy online object. (required)
  returnPolicyId: string, Required. The id of the return policy to update. (required)
  body: object, The request body.
    The object takes the form of:

{ # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
  "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
    "A String",
  ],
  "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
  "name": "A String", # The name of the policy as shown in Merchant Center.
  "policy": { # The available policies. # The return policy.
    "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
    "type": "A String", # Policy type.
  },
  "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
    "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
      "currency": "A String", # The currency of the price.
      "value": "A String", # The price represented as a number.
    },
    "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
  },
  "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
  "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
  "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
    { # The return reason category info wrapper.
      "returnLabelSource": "A String", # The corresponding return label source.
      "returnReasonCategory": "A String", # The return reason category.
      "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
        "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "type": "A String", # Type of return shipping fee.
      },
    },
  ],
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Return policy online object. This is currently used to represent return policies for ads and free listings programs.
  "countries": [ # The countries of sale where the return policy is applicable. The values must be a valid 2 letter ISO 3166 code, e.g. "US".
    "A String",
  ],
  "itemConditions": [ # The item conditions that are accepted for returns. This is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "label": "A String", # The unique user-defined label of the return policy. The same label cannot be used in different return policies for the same country. Policies with the label 'default' will apply to all products, unless a product specifies a return_policy_label attribute.
  "name": "A String", # The name of the policy as shown in Merchant Center.
  "policy": { # The available policies. # The return policy.
    "days": "A String", # The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. Required for `numberOfDaysAfterDelivery` returns.
    "type": "A String", # Policy type.
  },
  "restockingFee": { # The restocking fee. This can either be a fixed fee or a micro percent. # The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set.
    "fixedFee": { # The price represented as a number and currency. # Fixed restocking fee.
      "currency": "A String", # The currency of the price.
      "value": "A String", # The price represented as a number.
    },
    "microPercent": 42, # Percent of total price in micros. 15,000,000 means 15% of the total price would be charged.
  },
  "returnMethods": [ # The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns.
    "A String",
  ],
  "returnPolicyId": "A String", # Output only. Return policy ID generated by Google.
  "returnPolicyUri": "A String", # The return policy uri. This can used by Google to do a sanity check for the policy.
  "returnReasonCategoryInfo": [ # The return reason category information. This required to not be empty unless the type of return policy is noReturns.
    { # The return reason category info wrapper.
      "returnLabelSource": "A String", # The corresponding return label source.
      "returnReasonCategory": "A String", # The return reason category.
      "returnShippingFee": { # The return shipping fee. This can either be a fixed fee or a boolean to indicate that the customer pays the actual shipping cost. # The corresponding return shipping fee. This is only applicable when returnLabelSource is not the customer's responsibility.
        "fixedFee": { # The price represented as a number and currency. # Fixed return shipping fee amount. This value is only applicable when type is FIXED. We will treat the return shipping fee as free if type is FIXED and this value is not set.
          "currency": "A String", # The currency of the price.
          "value": "A String", # The price represented as a number.
        },
        "type": "A String", # Type of return shipping fee.
      },
    },
  ],
}