Class: Google::Apis::MerchantapiAccountsV1beta::OnlineReturnPolicy
- Inherits:
-
Object
- Object
- Google::Apis::MerchantapiAccountsV1beta::OnlineReturnPolicy
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/merchantapi_accounts_v1beta/classes.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb
Overview
Online return policy object. This is currently used to represent return policies for ads and free listings programs.
Instance Attribute Summary collapse
-
#accept_defective_only ⇒ Boolean
(also: #accept_defective_only?)
Optional.
-
#accept_exchange ⇒ Boolean
(also: #accept_exchange?)
Optional.
-
#countries ⇒ Array<String>
Required.
-
#item_conditions ⇒ Array<String>
Optional.
-
#label ⇒ String
Optional.
-
#name ⇒ String
Identifier.
-
#policy ⇒ Google::Apis::MerchantapiAccountsV1beta::Policy
The available policies.
-
#process_refund_days ⇒ Fixnum
Optional.
-
#restocking_fee ⇒ Google::Apis::MerchantapiAccountsV1beta::RestockingFee
The restocking fee.
-
#return_label_source ⇒ String
Optional.
-
#return_methods ⇒ Array<String>
Optional.
-
#return_policy_id ⇒ String
Output only.
-
#return_policy_uri ⇒ String
Required.
-
#return_shipping_fee ⇒ Google::Apis::MerchantapiAccountsV1beta::ReturnShippingFee
The return shipping fee.
-
#seasonal_overrides ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::SeasonalOverride>
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ OnlineReturnPolicy
constructor
A new instance of OnlineReturnPolicy.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ OnlineReturnPolicy
Returns a new instance of OnlineReturnPolicy.
2858 2859 2860 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2858 def initialize(**args) update!(**args) end |
Instance Attribute Details
#accept_defective_only ⇒ Boolean Also known as: accept_defective_only?
Optional. This field specifies if business only accepts defective products for
returns.
Corresponds to the JSON property acceptDefectiveOnly
2768 2769 2770 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2768 def accept_defective_only @accept_defective_only end |
#accept_exchange ⇒ Boolean Also known as: accept_exchange?
Optional. This field specifies if business allows customers to exchange
products.
Corresponds to the JSON property acceptExchange
2775 2776 2777 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2775 def accept_exchange @accept_exchange end |
#countries ⇒ Array<String>
Required. Immutable. The countries of sale where the return policy applies.
The values must be a valid 2 letter ISO 3166 code.
Corresponds to the JSON property countries
2782 2783 2784 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2782 def countries @countries end |
#item_conditions ⇒ Array<String>
Optional. The item conditions accepted for returns must not be empty unless
the type of return policy is 'noReturns'.
Corresponds to the JSON property itemConditions
2788 2789 2790 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2788 def item_conditions @item_conditions end |
#label ⇒ String
Optional. Immutable. This field represents the unique user-defined label of
the return policy for the given country. It is important to note that the same
label cannot be used in different return policies for the same country. If not
given, policies will be automatically treated as the 'default' for the country.
When using label, you are creating an exception policy in that country to
assign a custom return policy to certain product groups, follow the
instructions provided in the Return policy label. The label can contain up to 50 characters.
Corresponds to the JSON property label
2800 2801 2802 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2800 def label @label end |
#name ⇒ String
Identifier. The name of the OnlineReturnPolicy resource. Format: accounts/
account/onlineReturnPolicies/return_policy`
Corresponds to the JSON propertyname`
2806 2807 2808 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2806 def name @name end |
#policy ⇒ Google::Apis::MerchantapiAccountsV1beta::Policy
The available policies.
Corresponds to the JSON property policy
2811 2812 2813 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2811 def policy @policy end |
#process_refund_days ⇒ Fixnum
Optional. The field specifies the number of days it takes for business to
process refunds.
Corresponds to the JSON property processRefundDays
2817 2818 2819 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2817 def process_refund_days @process_refund_days end |
#restocking_fee ⇒ Google::Apis::MerchantapiAccountsV1beta::RestockingFee
The restocking fee. This can be a flat fee or a micro percent.
Corresponds to the JSON property restockingFee
2822 2823 2824 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2822 def restocking_fee @restocking_fee end |
#return_label_source ⇒ String
Optional. The field specifies the return label source.
Corresponds to the JSON property returnLabelSource
2827 2828 2829 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2827 def return_label_source @return_label_source end |
#return_methods ⇒ Array<String>
Optional. 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.
Corresponds to the JSON property returnMethods
2833 2834 2835 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2833 def return_methods @return_methods end |
#return_policy_id ⇒ String
Output only. Return policy ID generated by Google.
Corresponds to the JSON property returnPolicyId
2838 2839 2840 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2838 def return_policy_id @return_policy_id end |
#return_policy_uri ⇒ String
Required. The return policy uri. This can used by Google to do a sanity check
for the policy. It must be a valid URL.
Corresponds to the JSON property returnPolicyUri
2844 2845 2846 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2844 def return_policy_uri @return_policy_uri end |
#return_shipping_fee ⇒ Google::Apis::MerchantapiAccountsV1beta::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.
Corresponds to the JSON property returnShippingFee
2850 2851 2852 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2850 def return_shipping_fee @return_shipping_fee end |
#seasonal_overrides ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::SeasonalOverride>
Optional. Overrides to the general policy for orders placed during a specific
set of time intervals.
Corresponds to the JSON property seasonalOverrides
2856 2857 2858 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2856 def seasonal_overrides @seasonal_overrides end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 2863 def update!(**args) @accept_defective_only = args[:accept_defective_only] if args.key?(:accept_defective_only) @accept_exchange = args[:accept_exchange] if args.key?(:accept_exchange) @countries = args[:countries] if args.key?(:countries) @item_conditions = args[:item_conditions] if args.key?(:item_conditions) @label = args[:label] if args.key?(:label) @name = args[:name] if args.key?(:name) @policy = args[:policy] if args.key?(:policy) @process_refund_days = args[:process_refund_days] if args.key?(:process_refund_days) @restocking_fee = args[:restocking_fee] if args.key?(:restocking_fee) @return_label_source = args[:return_label_source] if args.key?(:return_label_source) @return_methods = args[:return_methods] if args.key?(:return_methods) @return_policy_id = args[:return_policy_id] if args.key?(:return_policy_id) @return_policy_uri = args[:return_policy_uri] if args.key?(:return_policy_uri) @return_shipping_fee = args[:return_shipping_fee] if args.key?(:return_shipping_fee) @seasonal_overrides = args[:seasonal_overrides] if args.key?(:seasonal_overrides) end |