class UltracartClient::TaxApi

Attributes

api_client[RW]

Public Class Methods

new(api_client = ApiClient.default) click to toggle source
# File lib/ultracart_api/api/tax_api.rb, line 19
def initialize(api_client = ApiClient.default)
  @api_client = api_client
end
new_using_api_key(simple_key, verify_ssl = true, debugging = false) click to toggle source
# File lib/ultracart_api/api/tax_api.rb, line 23
def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
  api_config = Configuration.new
  api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
  api_config.api_version = '2017-03-01'
  api_config.verify_ssl = verify_ssl

  api_client = ApiClient.new(api_config)
  api_client.config.debugging = debugging

  UltracartClient::TaxApi.new(api_client)
end

Public Instance Methods

delete_tax_provider_self_city(city, tax_city, opts = {}) click to toggle source

Deletes a Self tax provider city Deletes a Self tax provider city. @param city The city being deleted. @param tax_city tax city to be deleted @param [Hash] opts the optional parameters @return [nil]

# File lib/ultracart_api/api/tax_api.rb, line 41
def delete_tax_provider_self_city(city, tax_city, opts = {})
  delete_tax_provider_self_city_with_http_info(city, tax_city, opts)
  nil
end
delete_tax_provider_self_city_with_http_info(city, tax_city, opts = {}) click to toggle source

Deletes a Self tax provider city Deletes a Self tax provider city. @param city The city being deleted. @param tax_city tax city to be deleted @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 52
def delete_tax_provider_self_city_with_http_info(city, tax_city, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.delete_tax_provider_self_city ...'
  end
  # verify the required parameter 'city' is set
  if @api_client.config.client_side_validation && city.nil?
    fail ArgumentError, "Missing the required parameter 'city' when calling TaxApi.delete_tax_provider_self_city"
  end
  # verify the required parameter 'tax_city' is set
  if @api_client.config.client_side_validation && tax_city.nil?
    fail ArgumentError, "Missing the required parameter 'tax_city' when calling TaxApi.delete_tax_provider_self_city"
  end
  # resource path
  local_var_path = '/tax/providers/self/city/{city}'.sub('{' + 'city' + '}', city.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_city)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#delete_tax_provider_self_city\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_tax_provider_self_country(country_code, tax_country, opts = {}) click to toggle source

Deletes a Self tax provider country Deletes a Self tax provider country. @param country_code The country code being deleted. @param tax_country tax country to be deleted @param [Hash] opts the optional parameters @return [nil]

# File lib/ultracart_api/api/tax_api.rb, line 101
def delete_tax_provider_self_country(country_code, tax_country, opts = {})
  delete_tax_provider_self_country_with_http_info(country_code, tax_country, opts)
  nil
end
delete_tax_provider_self_country_with_http_info(country_code, tax_country, opts = {}) click to toggle source

Deletes a Self tax provider country Deletes a Self tax provider country. @param country_code The country code being deleted. @param tax_country tax country to be deleted @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 112
def delete_tax_provider_self_country_with_http_info(country_code, tax_country, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.delete_tax_provider_self_country ...'
  end
  # verify the required parameter 'country_code' is set
  if @api_client.config.client_side_validation && country_code.nil?
    fail ArgumentError, "Missing the required parameter 'country_code' when calling TaxApi.delete_tax_provider_self_country"
  end
  # verify the required parameter 'tax_country' is set
  if @api_client.config.client_side_validation && tax_country.nil?
    fail ArgumentError, "Missing the required parameter 'tax_country' when calling TaxApi.delete_tax_provider_self_country"
  end
  # resource path
  local_var_path = '/tax/providers/self/country/{countryCode}'.sub('{' + 'countryCode' + '}', country_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_country)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#delete_tax_provider_self_country\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_tax_provider_self_county(county, tax_county, opts = {}) click to toggle source

Deletes a Self tax provider county Deletes a Self tax provider county. @param county The county being deleted. @param tax_county tax county to be deleted @param [Hash] opts the optional parameters @return [nil]

# File lib/ultracart_api/api/tax_api.rb, line 161
def delete_tax_provider_self_county(county, tax_county, opts = {})
  delete_tax_provider_self_county_with_http_info(county, tax_county, opts)
  nil
end
delete_tax_provider_self_county_with_http_info(county, tax_county, opts = {}) click to toggle source

Deletes a Self tax provider county Deletes a Self tax provider county. @param county The county being deleted. @param tax_county tax county to be deleted @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 172
def delete_tax_provider_self_county_with_http_info(county, tax_county, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.delete_tax_provider_self_county ...'
  end
  # verify the required parameter 'county' is set
  if @api_client.config.client_side_validation && county.nil?
    fail ArgumentError, "Missing the required parameter 'county' when calling TaxApi.delete_tax_provider_self_county"
  end
  # verify the required parameter 'tax_county' is set
  if @api_client.config.client_side_validation && tax_county.nil?
    fail ArgumentError, "Missing the required parameter 'tax_county' when calling TaxApi.delete_tax_provider_self_county"
  end
  # resource path
  local_var_path = '/tax/providers/self/county/{county}'.sub('{' + 'county' + '}', county.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_county)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#delete_tax_provider_self_county\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_tax_provider_self_postal_code(postal_code, tax_postal_code, opts = {}) click to toggle source

Deletes a Self tax provider postalCode Deletes a Self tax provider postalCode. @param postal_code The postal code being deleted. @param tax_postal_code tax postal code to be deleted @param [Hash] opts the optional parameters @return [nil]

# File lib/ultracart_api/api/tax_api.rb, line 221
def delete_tax_provider_self_postal_code(postal_code, tax_postal_code, opts = {})
  delete_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts)
  nil
end
delete_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts = {}) click to toggle source

Deletes a Self tax provider postalCode Deletes a Self tax provider postalCode. @param postal_code The postal code being deleted. @param tax_postal_code tax postal code to be deleted @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 232
def delete_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.delete_tax_provider_self_postal_code ...'
  end
  # verify the required parameter 'postal_code' is set
  if @api_client.config.client_side_validation && postal_code.nil?
    fail ArgumentError, "Missing the required parameter 'postal_code' when calling TaxApi.delete_tax_provider_self_postal_code"
  end
  # verify the required parameter 'tax_postal_code' is set
  if @api_client.config.client_side_validation && tax_postal_code.nil?
    fail ArgumentError, "Missing the required parameter 'tax_postal_code' when calling TaxApi.delete_tax_provider_self_postal_code"
  end
  # resource path
  local_var_path = '/tax/providers/self/postalCode/{postal_code}'.sub('{' + 'postal_code' + '}', postal_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_postal_code)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#delete_tax_provider_self_postal_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_tax_provider_self_state(state_code, tax_state, opts = {}) click to toggle source

Deletes a Self tax provider state Deletes a Self tax provider state. @param state_code The state code being deleted. @param tax_state tax state to be deleted @param [Hash] opts the optional parameters @return [nil]

# File lib/ultracart_api/api/tax_api.rb, line 281
def delete_tax_provider_self_state(state_code, tax_state, opts = {})
  delete_tax_provider_self_state_with_http_info(state_code, tax_state, opts)
  nil
end
delete_tax_provider_self_state_with_http_info(state_code, tax_state, opts = {}) click to toggle source

Deletes a Self tax provider state Deletes a Self tax provider state. @param state_code The state code being deleted. @param tax_state tax state to be deleted @param [Hash] opts the optional parameters @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 292
def delete_tax_provider_self_state_with_http_info(state_code, tax_state, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.delete_tax_provider_self_state ...'
  end
  # verify the required parameter 'state_code' is set
  if @api_client.config.client_side_validation && state_code.nil?
    fail ArgumentError, "Missing the required parameter 'state_code' when calling TaxApi.delete_tax_provider_self_state"
  end
  # verify the required parameter 'tax_state' is set
  if @api_client.config.client_side_validation && tax_state.nil?
    fail ArgumentError, "Missing the required parameter 'tax_state' when calling TaxApi.delete_tax_provider_self_state"
  end
  # resource path
  local_var_path = '/tax/providers/self/state/{stateCode}'.sub('{' + 'stateCode' + '}', state_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_state)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#delete_tax_provider_self_state\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_avalara(opts = {}) click to toggle source

Retrieve the Avalara tax provider Retrieves the Avalara tax provider. @param [Hash] opts the optional parameters @return [TaxProviderAvalara]

# File lib/ultracart_api/api/tax_api.rb, line 339
def get_tax_provider_avalara(opts = {})
  data, _status_code, _headers = get_tax_provider_avalara_with_http_info(opts)
  data
end
get_tax_provider_avalara_companies(tax_provider_avalara, opts = {}) click to toggle source

Returns Avalara Tax companies configured by the merchant Returns Avalara Tax companies configured by the merchant @param tax_provider_avalara TaxProviderAvalara object @param [Hash] opts the optional parameters @return [TaxProviderAvalaraCompaniesResult]

# File lib/ultracart_api/api/tax_api.rb, line 389
def get_tax_provider_avalara_companies(tax_provider_avalara, opts = {})
  data, _status_code, _headers = get_tax_provider_avalara_companies_with_http_info(tax_provider_avalara, opts)
  data
end
get_tax_provider_avalara_companies_with_http_info(tax_provider_avalara, opts = {}) click to toggle source

Returns Avalara Tax companies configured by the merchant Returns Avalara Tax companies configured by the merchant @param tax_provider_avalara TaxProviderAvalara object @param [Hash] opts the optional parameters @return [Array<(TaxProviderAvalaraCompaniesResult, Fixnum, Hash)>] TaxProviderAvalaraCompaniesResult data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 399
def get_tax_provider_avalara_companies_with_http_info(tax_provider_avalara, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_avalara_companies ...'
  end
  # verify the required parameter 'tax_provider_avalara' is set
  if @api_client.config.client_side_validation && tax_provider_avalara.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_avalara' when calling TaxApi.get_tax_provider_avalara_companies"
  end
  # resource path
  local_var_path = '/tax/providers/avalara/companies'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_avalara)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderAvalaraCompaniesResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_avalara_companies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_avalara_test(opts = {}) click to toggle source

Attempts to connect to Avalara and returns back the response Attempts to connect to Avalara and returns back the response. @param [Hash] opts the optional parameters @return [TaxProviderTestResult]

# File lib/ultracart_api/api/tax_api.rb, line 443
def get_tax_provider_avalara_test(opts = {})
  data, _status_code, _headers = get_tax_provider_avalara_test_with_http_info(opts)
  data
end
get_tax_provider_avalara_test_with_http_info(opts = {}) click to toggle source

Attempts to connect to Avalara and returns back the response Attempts to connect to Avalara and returns back the response. @param [Hash] opts the optional parameters @return [Array<(TaxProviderTestResult, Fixnum, Hash)>] TaxProviderTestResult data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 452
def get_tax_provider_avalara_test_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_avalara_test ...'
  end
  # resource path
  local_var_path = '/tax/providers/avalara/test'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderTestResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_avalara_test\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_avalara_with_http_info(opts = {}) click to toggle source

Retrieve the Avalara tax provider Retrieves the Avalara tax provider. @param [Hash] opts the optional parameters @return [Array<(TaxProviderAvalara, Fixnum, Hash)>] TaxProviderAvalara data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 348
def get_tax_provider_avalara_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_avalara ...'
  end
  # resource path
  local_var_path = '/tax/providers/avalara'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderAvalara')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_avalara\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_self(opts = {}) click to toggle source

Retrieve the Self tax provider Retrieves the Self tax provider. @param [Hash] opts the optional parameters @return [TaxProviderSelf]

# File lib/ultracart_api/api/tax_api.rb, line 492
def get_tax_provider_self(opts = {})
  data, _status_code, _headers = get_tax_provider_self_with_http_info(opts)
  data
end
get_tax_provider_self_countries(opts = {}) click to toggle source

Retrieve the Self tax provider countries Retrieves the Self tax provider countries. @param [Hash] opts the optional parameters @return [TaxProviderSelfCountriesResponse]

# File lib/ultracart_api/api/tax_api.rb, line 541
def get_tax_provider_self_countries(opts = {})
  data, _status_code, _headers = get_tax_provider_self_countries_with_http_info(opts)
  data
end
get_tax_provider_self_countries_with_http_info(opts = {}) click to toggle source

Retrieve the Self tax provider countries Retrieves the Self tax provider countries. @param [Hash] opts the optional parameters @return [Array<(TaxProviderSelfCountriesResponse, Fixnum, Hash)>] TaxProviderSelfCountriesResponse data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 550
def get_tax_provider_self_countries_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_self_countries ...'
  end
  # resource path
  local_var_path = '/tax/providers/self/countries'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSelfCountriesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_self_countries\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_self_regions_by_country_code(country_code, opts = {}) click to toggle source

Retrieve the Self tax provider regions for a given country code Retrieves the Self tax provider regions for a given country code. @param country_code The country code regions desired. @param [Hash] opts the optional parameters @return [TaxProviderSelfRegionsResponse]

# File lib/ultracart_api/api/tax_api.rb, line 591
def get_tax_provider_self_regions_by_country_code(country_code, opts = {})
  data, _status_code, _headers = get_tax_provider_self_regions_by_country_code_with_http_info(country_code, opts)
  data
end
get_tax_provider_self_regions_by_country_code_with_http_info(country_code, opts = {}) click to toggle source

Retrieve the Self tax provider regions for a given country code Retrieves the Self tax provider regions for a given country code. @param country_code The country code regions desired. @param [Hash] opts the optional parameters @return [Array<(TaxProviderSelfRegionsResponse, Fixnum, Hash)>] TaxProviderSelfRegionsResponse data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 601
def get_tax_provider_self_regions_by_country_code_with_http_info(country_code, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_self_regions_by_country_code ...'
  end
  # verify the required parameter 'country_code' is set
  if @api_client.config.client_side_validation && country_code.nil?
    fail ArgumentError, "Missing the required parameter 'country_code' when calling TaxApi.get_tax_provider_self_regions_by_country_code"
  end
  # resource path
  local_var_path = '/tax/providers/self/regions/{countryCode}'.sub('{' + 'countryCode' + '}', country_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSelfRegionsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_self_regions_by_country_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_self_with_http_info(opts = {}) click to toggle source

Retrieve the Self tax provider Retrieves the Self tax provider. @param [Hash] opts the optional parameters @return [Array<(TaxProviderSelf, Fixnum, Hash)>] TaxProviderSelf data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 501
def get_tax_provider_self_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_self ...'
  end
  # resource path
  local_var_path = '/tax/providers/self'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSelf')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_self\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_sovos(opts = {}) click to toggle source

Retrieve the Sovos tax provider Retrieves the Sovos tax provider. @param [Hash] opts the optional parameters @return [TaxProviderSovos]

# File lib/ultracart_api/api/tax_api.rb, line 645
def get_tax_provider_sovos(opts = {})
  data, _status_code, _headers = get_tax_provider_sovos_with_http_info(opts)
  data
end
get_tax_provider_sovos_test(opts = {}) click to toggle source

Attempts to connect to Sovos and returns back the response Attempts to connect to Sovos and returns back the response. @param [Hash] opts the optional parameters @return [TaxProviderTestResult]

# File lib/ultracart_api/api/tax_api.rb, line 694
def get_tax_provider_sovos_test(opts = {})
  data, _status_code, _headers = get_tax_provider_sovos_test_with_http_info(opts)
  data
end
get_tax_provider_sovos_test_with_http_info(opts = {}) click to toggle source

Attempts to connect to Sovos and returns back the response Attempts to connect to Sovos and returns back the response. @param [Hash] opts the optional parameters @return [Array<(TaxProviderTestResult, Fixnum, Hash)>] TaxProviderTestResult data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 703
def get_tax_provider_sovos_test_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_sovos_test ...'
  end
  # resource path
  local_var_path = '/tax/providers/sovos/test'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderTestResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_sovos_test\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_sovos_with_http_info(opts = {}) click to toggle source

Retrieve the Sovos tax provider Retrieves the Sovos tax provider. @param [Hash] opts the optional parameters @return [Array<(TaxProviderSovos, Fixnum, Hash)>] TaxProviderSovos data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 654
def get_tax_provider_sovos_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_sovos ...'
  end
  # resource path
  local_var_path = '/tax/providers/sovos'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSovos')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_sovos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_tax_jar(opts = {}) click to toggle source

Retrieve the TaxJar tax provider Retrieves the TaxJar tax provider. @param [Hash] opts the optional parameters @return [TaxProviderTaxJar]

# File lib/ultracart_api/api/tax_api.rb, line 743
def get_tax_provider_tax_jar(opts = {})
  data, _status_code, _headers = get_tax_provider_tax_jar_with_http_info(opts)
  data
end
get_tax_provider_tax_jar_test(opts = {}) click to toggle source

Attempts to connect to TaxJar and returns back the response Attempts to connect to TaxJar and returns back the response. @param [Hash] opts the optional parameters @return [TaxProviderTestResult]

# File lib/ultracart_api/api/tax_api.rb, line 792
def get_tax_provider_tax_jar_test(opts = {})
  data, _status_code, _headers = get_tax_provider_tax_jar_test_with_http_info(opts)
  data
end
get_tax_provider_tax_jar_test_with_http_info(opts = {}) click to toggle source

Attempts to connect to TaxJar and returns back the response Attempts to connect to TaxJar and returns back the response. @param [Hash] opts the optional parameters @return [Array<(TaxProviderTestResult, Fixnum, Hash)>] TaxProviderTestResult data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 801
def get_tax_provider_tax_jar_test_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_tax_jar_test ...'
  end
  # resource path
  local_var_path = '/tax/providers/taxjar/test'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderTestResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_tax_jar_test\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_tax_jar_with_http_info(opts = {}) click to toggle source

Retrieve the TaxJar tax provider Retrieves the TaxJar tax provider. @param [Hash] opts the optional parameters @return [Array<(TaxProviderTaxJar, Fixnum, Hash)>] TaxProviderTaxJar data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 752
def get_tax_provider_tax_jar_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_tax_jar ...'
  end
  # resource path
  local_var_path = '/tax/providers/taxjar'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderTaxJar')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_tax_jar\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_provider_ultra_cart(opts = {}) click to toggle source

Retrieve the UltraCart tax provider Retrieves the UltraCart tax provider. @param [Hash] opts the optional parameters @return [TaxProviderUltraCart]

# File lib/ultracart_api/api/tax_api.rb, line 841
def get_tax_provider_ultra_cart(opts = {})
  data, _status_code, _headers = get_tax_provider_ultra_cart_with_http_info(opts)
  data
end
get_tax_provider_ultra_cart_with_http_info(opts = {}) click to toggle source

Retrieve the UltraCart tax provider Retrieves the UltraCart tax provider. @param [Hash] opts the optional parameters @return [Array<(TaxProviderUltraCart, Fixnum, Hash)>] TaxProviderUltraCart data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 850
def get_tax_provider_ultra_cart_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_provider_ultra_cart ...'
  end
  # resource path
  local_var_path = '/tax/providers/ultracart'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderUltraCart')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_provider_ultra_cart\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_tax_providers(opts = {}) click to toggle source

Retrieve tax methods Retrieves tax methods for this account. @param [Hash] opts the optional parameters @option opts [Integer] :_limit The maximum number of records to return on this one API call. (Max 200) (default to 100) @option opts [Integer] :_offset Pagination of the record set. Offset is a zero based index. (default to 0) @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples @return [TaxProvidersResponse]

# File lib/ultracart_api/api/tax_api.rb, line 893
def get_tax_providers(opts = {})
  data, _status_code, _headers = get_tax_providers_with_http_info(opts)
  data
end
get_tax_providers_with_http_info(opts = {}) click to toggle source

Retrieve tax methods Retrieves tax methods for this account. @param [Hash] opts the optional parameters @option opts [Integer] :_limit The maximum number of records to return on this one API call. (Max 200) @option opts [Integer] :_offset Pagination of the record set. Offset is a zero based index. @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples @return [Array<(TaxProvidersResponse, Fixnum, Hash)>] TaxProvidersResponse data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 905
def get_tax_providers_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.get_tax_providers ...'
  end
  # resource path
  local_var_path = '/tax/providers'

  # query parameters
  query_params = {}
  query_params[:'_limit'] = opts[:'_limit'] if !opts[:'_limit'].nil?
  query_params[:'_offset'] = opts[:'_offset'] if !opts[:'_offset'].nil?
  query_params[:'_expand'] = opts[:'_expand'] if !opts[:'_expand'].nil?

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProvidersResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#get_tax_providers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
set_active_tax_provider(provider_name, opts = {}) click to toggle source

Toggle a tax provider to active Toggle a tax provider to active. @param provider_name The tax provider to set active. @param [Hash] opts the optional parameters @return [TaxProviderActivateResult]

# File lib/ultracart_api/api/tax_api.rb, line 949
def set_active_tax_provider(provider_name, opts = {})
  data, _status_code, _headers = set_active_tax_provider_with_http_info(provider_name, opts)
  data
end
set_active_tax_provider_with_http_info(provider_name, opts = {}) click to toggle source

Toggle a tax provider to active Toggle a tax provider to active. @param provider_name The tax provider to set active. @param [Hash] opts the optional parameters @return [Array<(TaxProviderActivateResult, Fixnum, Hash)>] TaxProviderActivateResult data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 959
def set_active_tax_provider_with_http_info(provider_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.set_active_tax_provider ...'
  end
  # verify the required parameter 'provider_name' is set
  if @api_client.config.client_side_validation && provider_name.nil?
    fail ArgumentError, "Missing the required parameter 'provider_name' when calling TaxApi.set_active_tax_provider"
  end
  # resource path
  local_var_path = '/tax/providers/setActive/{providerName}'.sub('{' + 'providerName' + '}', provider_name.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderActivateResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#set_active_tax_provider\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_avalara(tax_provider_avalara, opts = {}) click to toggle source

Update the Avalara tax provider Update the Avalara tax provider. @param tax_provider_avalara TaxProviderAvalara object @param [Hash] opts the optional parameters @return [TaxProviderAvalara]

# File lib/ultracart_api/api/tax_api.rb, line 1004
def update_tax_provider_avalara(tax_provider_avalara, opts = {})
  data, _status_code, _headers = update_tax_provider_avalara_with_http_info(tax_provider_avalara, opts)
  data
end
update_tax_provider_avalara_with_http_info(tax_provider_avalara, opts = {}) click to toggle source

Update the Avalara tax provider Update the Avalara tax provider. @param tax_provider_avalara TaxProviderAvalara object @param [Hash] opts the optional parameters @return [Array<(TaxProviderAvalara, Fixnum, Hash)>] TaxProviderAvalara data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1014
def update_tax_provider_avalara_with_http_info(tax_provider_avalara, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_avalara ...'
  end
  # verify the required parameter 'tax_provider_avalara' is set
  if @api_client.config.client_side_validation && tax_provider_avalara.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_avalara' when calling TaxApi.update_tax_provider_avalara"
  end
  # resource path
  local_var_path = '/tax/providers/avalara'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_avalara)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderAvalara')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_avalara\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self(tax_provider_self, opts = {}) click to toggle source

Update the Self tax provider Update the Self tax provider. @param tax_provider_self TaxProviderSelf object @param [Hash] opts the optional parameters @return [TaxProviderSelf]

# File lib/ultracart_api/api/tax_api.rb, line 1059
def update_tax_provider_self(tax_provider_self, opts = {})
  data, _status_code, _headers = update_tax_provider_self_with_http_info(tax_provider_self, opts)
  data
end
update_tax_provider_self_city(city, tax_city, opts = {}) click to toggle source

Updates a Self tax provider city Updates a Self tax provider city. @param city The city being updated. @param tax_city tax city to be updated @param [Hash] opts the optional parameters @return [TaxCity]

# File lib/ultracart_api/api/tax_api.rb, line 1115
def update_tax_provider_self_city(city, tax_city, opts = {})
  data, _status_code, _headers = update_tax_provider_self_city_with_http_info(city, tax_city, opts)
  data
end
update_tax_provider_self_city_with_http_info(city, tax_city, opts = {}) click to toggle source

Updates a Self tax provider city Updates a Self tax provider city. @param city The city being updated. @param tax_city tax city to be updated @param [Hash] opts the optional parameters @return [Array<(TaxCity, Fixnum, Hash)>] TaxCity data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1126
def update_tax_provider_self_city_with_http_info(city, tax_city, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self_city ...'
  end
  # verify the required parameter 'city' is set
  if @api_client.config.client_side_validation && city.nil?
    fail ArgumentError, "Missing the required parameter 'city' when calling TaxApi.update_tax_provider_self_city"
  end
  # verify the required parameter 'tax_city' is set
  if @api_client.config.client_side_validation && tax_city.nil?
    fail ArgumentError, "Missing the required parameter 'tax_city' when calling TaxApi.update_tax_provider_self_city"
  end
  # resource path
  local_var_path = '/tax/providers/self/city/{city}'.sub('{' + 'city' + '}', city.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_city)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxCity')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self_city\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self_country(country_code, tax_country, opts = {}) click to toggle source

Updates a Self tax provider country Updates a Self tax provider country. @param country_code The country code being updated. @param tax_country tax country to be updated @param [Hash] opts the optional parameters @return [TaxCountry]

# File lib/ultracart_api/api/tax_api.rb, line 1176
def update_tax_provider_self_country(country_code, tax_country, opts = {})
  data, _status_code, _headers = update_tax_provider_self_country_with_http_info(country_code, tax_country, opts)
  data
end
update_tax_provider_self_country_with_http_info(country_code, tax_country, opts = {}) click to toggle source

Updates a Self tax provider country Updates a Self tax provider country. @param country_code The country code being updated. @param tax_country tax country to be updated @param [Hash] opts the optional parameters @return [Array<(TaxCountry, Fixnum, Hash)>] TaxCountry data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1187
def update_tax_provider_self_country_with_http_info(country_code, tax_country, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self_country ...'
  end
  # verify the required parameter 'country_code' is set
  if @api_client.config.client_side_validation && country_code.nil?
    fail ArgumentError, "Missing the required parameter 'country_code' when calling TaxApi.update_tax_provider_self_country"
  end
  # verify the required parameter 'tax_country' is set
  if @api_client.config.client_side_validation && tax_country.nil?
    fail ArgumentError, "Missing the required parameter 'tax_country' when calling TaxApi.update_tax_provider_self_country"
  end
  # resource path
  local_var_path = '/tax/providers/self/country/{countryCode}'.sub('{' + 'countryCode' + '}', country_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_country)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxCountry')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self_country\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self_county(county, tax_county, opts = {}) click to toggle source

Updates a Self tax provider county Updates a Self tax provider county. @param county The county being updated. @param tax_county tax county to be updated @param [Hash] opts the optional parameters @return [TaxCounty]

# File lib/ultracart_api/api/tax_api.rb, line 1237
def update_tax_provider_self_county(county, tax_county, opts = {})
  data, _status_code, _headers = update_tax_provider_self_county_with_http_info(county, tax_county, opts)
  data
end
update_tax_provider_self_county_with_http_info(county, tax_county, opts = {}) click to toggle source

Updates a Self tax provider county Updates a Self tax provider county. @param county The county being updated. @param tax_county tax county to be updated @param [Hash] opts the optional parameters @return [Array<(TaxCounty, Fixnum, Hash)>] TaxCounty data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1248
def update_tax_provider_self_county_with_http_info(county, tax_county, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self_county ...'
  end
  # verify the required parameter 'county' is set
  if @api_client.config.client_side_validation && county.nil?
    fail ArgumentError, "Missing the required parameter 'county' when calling TaxApi.update_tax_provider_self_county"
  end
  # verify the required parameter 'tax_county' is set
  if @api_client.config.client_side_validation && tax_county.nil?
    fail ArgumentError, "Missing the required parameter 'tax_county' when calling TaxApi.update_tax_provider_self_county"
  end
  # resource path
  local_var_path = '/tax/providers/self/county/{county}'.sub('{' + 'county' + '}', county.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_county)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxCounty')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self_county\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self_postal_code(postal_code, tax_postal_code, opts = {}) click to toggle source

Updates a Self tax provider postalCode Updates a Self tax provider postalCode. @param postal_code The postal code being updated. @param tax_postal_code tax postal code to be updated @param [Hash] opts the optional parameters @return [TaxPostalCode]

# File lib/ultracart_api/api/tax_api.rb, line 1298
def update_tax_provider_self_postal_code(postal_code, tax_postal_code, opts = {})
  data, _status_code, _headers = update_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts)
  data
end
update_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts = {}) click to toggle source

Updates a Self tax provider postalCode Updates a Self tax provider postalCode. @param postal_code The postal code being updated. @param tax_postal_code tax postal code to be updated @param [Hash] opts the optional parameters @return [Array<(TaxPostalCode, Fixnum, Hash)>] TaxPostalCode data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1309
def update_tax_provider_self_postal_code_with_http_info(postal_code, tax_postal_code, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self_postal_code ...'
  end
  # verify the required parameter 'postal_code' is set
  if @api_client.config.client_side_validation && postal_code.nil?
    fail ArgumentError, "Missing the required parameter 'postal_code' when calling TaxApi.update_tax_provider_self_postal_code"
  end
  # verify the required parameter 'tax_postal_code' is set
  if @api_client.config.client_side_validation && tax_postal_code.nil?
    fail ArgumentError, "Missing the required parameter 'tax_postal_code' when calling TaxApi.update_tax_provider_self_postal_code"
  end
  # resource path
  local_var_path = '/tax/providers/self/postalCode/{postal_code}'.sub('{' + 'postal_code' + '}', postal_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_postal_code)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxPostalCode')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self_postal_code\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self_state(state_code, tax_state, opts = {}) click to toggle source

Updates a Self tax provider state Updates a Self tax provider state. @param state_code The state code being updated. @param tax_state tax state to be updated @param [Hash] opts the optional parameters @return [TaxState]

# File lib/ultracart_api/api/tax_api.rb, line 1359
def update_tax_provider_self_state(state_code, tax_state, opts = {})
  data, _status_code, _headers = update_tax_provider_self_state_with_http_info(state_code, tax_state, opts)
  data
end
update_tax_provider_self_state_with_http_info(state_code, tax_state, opts = {}) click to toggle source

Updates a Self tax provider state Updates a Self tax provider state. @param state_code The state code being updated. @param tax_state tax state to be updated @param [Hash] opts the optional parameters @return [Array<(TaxState, Fixnum, Hash)>] TaxState data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1370
def update_tax_provider_self_state_with_http_info(state_code, tax_state, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self_state ...'
  end
  # verify the required parameter 'state_code' is set
  if @api_client.config.client_side_validation && state_code.nil?
    fail ArgumentError, "Missing the required parameter 'state_code' when calling TaxApi.update_tax_provider_self_state"
  end
  # verify the required parameter 'tax_state' is set
  if @api_client.config.client_side_validation && tax_state.nil?
    fail ArgumentError, "Missing the required parameter 'tax_state' when calling TaxApi.update_tax_provider_self_state"
  end
  # resource path
  local_var_path = '/tax/providers/self/state/{stateCode}'.sub('{' + 'stateCode' + '}', state_code.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_state)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxState')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self_state\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_self_with_http_info(tax_provider_self, opts = {}) click to toggle source

Update the Self tax provider Update the Self tax provider. @param tax_provider_self TaxProviderSelf object @param [Hash] opts the optional parameters @return [Array<(TaxProviderSelf, Fixnum, Hash)>] TaxProviderSelf data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1069
def update_tax_provider_self_with_http_info(tax_provider_self, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_self ...'
  end
  # verify the required parameter 'tax_provider_self' is set
  if @api_client.config.client_side_validation && tax_provider_self.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_self' when calling TaxApi.update_tax_provider_self"
  end
  # resource path
  local_var_path = '/tax/providers/self'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_self)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSelf')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_self\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_sovos(tax_provider_sovos, opts = {}) click to toggle source

Update the Sovos tax provider Update the Sovos tax provider. @param tax_provider_sovos TaxProviderSovos object @param [Hash] opts the optional parameters @return [TaxProviderSovos]

# File lib/ultracart_api/api/tax_api.rb, line 1419
def update_tax_provider_sovos(tax_provider_sovos, opts = {})
  data, _status_code, _headers = update_tax_provider_sovos_with_http_info(tax_provider_sovos, opts)
  data
end
update_tax_provider_sovos_with_http_info(tax_provider_sovos, opts = {}) click to toggle source

Update the Sovos tax provider Update the Sovos tax provider. @param tax_provider_sovos TaxProviderSovos object @param [Hash] opts the optional parameters @return [Array<(TaxProviderSovos, Fixnum, Hash)>] TaxProviderSovos data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1429
def update_tax_provider_sovos_with_http_info(tax_provider_sovos, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_sovos ...'
  end
  # verify the required parameter 'tax_provider_sovos' is set
  if @api_client.config.client_side_validation && tax_provider_sovos.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_sovos' when calling TaxApi.update_tax_provider_sovos"
  end
  # resource path
  local_var_path = '/tax/providers/sovos'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_sovos)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderSovos')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_sovos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_tax_jar(tax_provider_tax_jar, opts = {}) click to toggle source

Update the TaxJar tax provider Update the TaxJar tax provider. @param tax_provider_tax_jar TaxProviderTaxJar object @param [Hash] opts the optional parameters @return [TaxProviderTaxJar]

# File lib/ultracart_api/api/tax_api.rb, line 1474
def update_tax_provider_tax_jar(tax_provider_tax_jar, opts = {})
  data, _status_code, _headers = update_tax_provider_tax_jar_with_http_info(tax_provider_tax_jar, opts)
  data
end
update_tax_provider_tax_jar_with_http_info(tax_provider_tax_jar, opts = {}) click to toggle source

Update the TaxJar tax provider Update the TaxJar tax provider. @param tax_provider_tax_jar TaxProviderTaxJar object @param [Hash] opts the optional parameters @return [Array<(TaxProviderTaxJar, Fixnum, Hash)>] TaxProviderTaxJar data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1484
def update_tax_provider_tax_jar_with_http_info(tax_provider_tax_jar, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_tax_jar ...'
  end
  # verify the required parameter 'tax_provider_tax_jar' is set
  if @api_client.config.client_side_validation && tax_provider_tax_jar.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_tax_jar' when calling TaxApi.update_tax_provider_tax_jar"
  end
  # resource path
  local_var_path = '/tax/providers/taxjar'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_tax_jar)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderTaxJar')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_tax_jar\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tax_provider_ultra_cart(tax_provider_ultracart, opts = {}) click to toggle source

Update the UltraCart tax provider Update the UltraCart tax provider. @param tax_provider_ultracart TaxProviderUltraCart object @param [Hash] opts the optional parameters @return [TaxProviderUltraCart]

# File lib/ultracart_api/api/tax_api.rb, line 1529
def update_tax_provider_ultra_cart(tax_provider_ultracart, opts = {})
  data, _status_code, _headers = update_tax_provider_ultra_cart_with_http_info(tax_provider_ultracart, opts)
  data
end
update_tax_provider_ultra_cart_with_http_info(tax_provider_ultracart, opts = {}) click to toggle source

Update the UltraCart tax provider Update the UltraCart tax provider. @param tax_provider_ultracart TaxProviderUltraCart object @param [Hash] opts the optional parameters @return [Array<(TaxProviderUltraCart, Fixnum, Hash)>] TaxProviderUltraCart data, response status code and response headers

# File lib/ultracart_api/api/tax_api.rb, line 1539
def update_tax_provider_ultra_cart_with_http_info(tax_provider_ultracart, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TaxApi.update_tax_provider_ultra_cart ...'
  end
  # verify the required parameter 'tax_provider_ultracart' is set
  if @api_client.config.client_side_validation && tax_provider_ultracart.nil?
    fail ArgumentError, "Missing the required parameter 'tax_provider_ultracart' when calling TaxApi.update_tax_provider_ultra_cart"
  end
  # resource path
  local_var_path = '/tax/providers/ultracart'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tax_provider_ultracart)
  auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TaxProviderUltraCart')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TaxApi#update_tax_provider_ultra_cart\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end