Class: Google::Apis::MerchantapiAccountsV1beta::AccountTax

Inherits:
Object
  • Object
show all
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

The tax settings of a merchant account. All methods require the admin role.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ AccountTax

Returns a new instance of AccountTax.



226
227
228
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 226

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#accountFixnum

Output only. The ID of the account to which these account tax settings belong. Corresponds to the JSON property account

Returns:

  • (Fixnum)


212
213
214
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 212

def 
  @account
end

#nameString

Identifier. The name of the tax setting. Format: "account_tax.name=accounts/ account`" Corresponds to the JSON propertyname`

Returns:

  • (String)


218
219
220
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 218

def name
  @name
end

#tax_rulesArray<Google::Apis::MerchantapiAccountsV1beta::TaxRule>

Tax rules. "Define the tax rules in each region. No tax will be presented if a region has no rule." Corresponds to the JSON property taxRules



224
225
226
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 224

def tax_rules
  @tax_rules
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



231
232
233
234
235
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 231

def update!(**args)
  @account = args[:account] if args.key?(:account)
  @name = args[:name] if args.key?(:name)
  @tax_rules = args[:tax_rules] if args.key?(:tax_rules)
end