Module: TaxCloud

Defined in:
lib/tax_cloud.rb,
lib/tax_cloud/client.rb,
lib/tax_cloud/record.rb,
lib/tax_cloud/address.rb,
lib/tax_cloud/version.rb,
lib/tax_cloud/tax_code.rb,
lib/tax_cloud/cart_item.rb,
lib/tax_cloud/tax_codes.rb,
lib/tax_cloud/transaction.rb,
lib/tax_cloud/configuration.rb,
lib/tax_cloud/responses/base.rb,
lib/tax_cloud/responses/ping.rb,
lib/tax_cloud/tax_code_group.rb,
lib/tax_cloud/tax_code_groups.rb,
lib/tax_cloud/errors/api_error.rb,
lib/tax_cloud/responses/lookup.rb,
lib/tax_cloud/errors/soap_error.rb,
lib/tax_cloud/responses/generic.rb,
lib/tax_cloud/responses/captured.rb,
lib/tax_cloud/responses/returned.rb,
lib/tax_cloud/tax_code_constants.rb,
lib/tax_cloud/responses/cart_item.rb,
lib/tax_cloud/responses/tax_codes.rb,
lib/tax_cloud/responses/authorized.rb,
lib/tax_cloud/errors/tax_cloud_error.rb,
lib/tax_cloud/responses/verify_address.rb,
lib/tax_cloud/tax_code_group_constants.rb,
lib/tax_cloud/responses/tax_code_groups.rb,
lib/tax_cloud/errors/missing_config_error.rb,
lib/tax_cloud/responses/tax_codes_by_group.rb,
lib/tax_cloud/responses/authorized_with_capture.rb,
lib/tax_cloud/errors/missing_config_option_error.rb,
lib/tax_cloud/errors/unexpected_soap_response_error.rb

Overview

:nodoc:

Defined Under Namespace

Modules: Errors, Responses Classes: Address, CartItem, Client, Configuration, Record, TaxCode, TaxCodeGroup, TaxCodes, Transaction

Constant Summary collapse

WSDL_URL =

WSDL location for TaxCloud API.

'https://api.taxcloud.com/1.0/?wsdl'
API_VERSION =

TaxCloud API version.

'1.0'
VERSION =

The version of the tax_cloud gem.

'0.6.0'

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configurationObject

TaxCloud gem configuration.



39
40
41
# File 'lib/tax_cloud.rb', line 39

def configuration
  @configuration
end

Class Method Details

.clientObject

The configured SOAP client to the TaxCloud service.



59
60
61
62
# File 'lib/tax_cloud.rb', line 59

def client
  check_configuration!
  @client ||= TaxCloud::Client.new
end

.configure {|configuration| ... } ⇒ Object

Configure the gem.

Yields:



47
48
49
50
# File 'lib/tax_cloud.rb', line 47

def configure
  self.configuration ||= Configuration.new
  yield configuration
end

.configured?Boolean

Returns true if the gem has been configured.



42
43
44
# File 'lib/tax_cloud.rb', line 42

def configured?
  configuration.present?
end

.reset!Object

Reset the current configuration.



53
54
55
56
# File 'lib/tax_cloud.rb', line 53

def reset!
  self.configuration = nil
  @client = nil
end