tax_cloud 0.1.1 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.rdoc +11 -0
- data/Rakefile +8 -6
- data/lib/tax_cloud/transaction.rb +15 -0
- data/lib/tax_cloud/version.rb +1 -1
- data/tax_cloud.gemspec +9 -8
- data/test/cassettes/authorized.yml +63 -0
- data/test/cassettes/authorized_with_capture.yml +63 -0
- data/test/cassettes/captured.yml +94 -0
- data/test/cassettes/lookup.yml +32 -0
- data/test/cassettes/returned.yml +94 -0
- data/test/cassettes/verify_bad_address.yml +993 -0
- data/test/cassettes/verify_good_address.yml +32 -0
- data/test/helper.rb +9 -0
- data/test/test_address.rb +16 -6
- data/test/test_transaction.rb +29 -12
- metadata +44 -18
data/README.rdoc
CHANGED
@@ -28,6 +28,17 @@ After you've authorized and captured the transaction via your merchant account,
|
|
28
28
|
transaction.order_id = 100
|
29
29
|
transaction.authorized_with_capture # return Savon response object
|
30
30
|
|
31
|
+
Later, you may need to mark some cart items as returned. TaxCloud will ignore any cart items that you don't include
|
32
|
+
transaction.order_id = 100
|
33
|
+
transaction.cart_items << TaxCloud::CartItem.new(:index => 0, :item_id => 'SKU-100', :tic => TaxCloud::TaxCodes::GENERAL, :price => 10.00, :quantity => 1)
|
34
|
+
transaction.returned # return Savon response object
|
35
|
+
|
36
|
+
=== Running Tests
|
37
|
+
* Add your config details to *test/helper*
|
38
|
+
* VCR and WebMock are used to replay requests and avoid hitting the API each time. To refresh the mocks, simply delete the *test/cassettes* directory.
|
39
|
+
* The mocks will filter out your config details, but remember not to commit them!
|
40
|
+
* run <tt>rake test</tt>
|
41
|
+
|
31
42
|
=== Todo
|
32
43
|
* Instead of returning Savon response objects, it should return TransactionLookupResponse, TransactionAuthorizedResponse, TransactionCapturedResponse, etc.
|
33
44
|
* Add all tax codes to TaxCloud::TaxCodes
|
data/Rakefile
CHANGED
@@ -2,21 +2,23 @@ require 'bundler/gem_tasks'
|
|
2
2
|
require 'rake/testtask'
|
3
3
|
require 'rdoc/task'
|
4
4
|
|
5
|
+
gemspec = eval(File.read(Dir["*.gemspec"].first))
|
6
|
+
|
5
7
|
Rake::TestTask.new(:test) do |test|
|
6
8
|
test.libs << 'lib' << 'test'
|
7
9
|
test.pattern = 'test/test_*.rb'
|
8
10
|
test.verbose = false
|
9
11
|
end
|
10
12
|
|
11
|
-
|
13
|
+
RDoc::Task.new do |rd|
|
12
14
|
README = 'README.rdoc'
|
13
15
|
rd.main = README
|
14
16
|
rd.rdoc_files.include(README, "lib/**/*.rb")
|
15
17
|
rd.rdoc_dir = 'doc'
|
16
|
-
rd.title = '
|
17
|
-
rd.options << '-f' << 'horo'
|
18
|
-
rd.options << '-c' << 'utf-8'
|
19
|
-
rd.options << '-m' << README
|
18
|
+
rd.title = 'tax_cloud'
|
20
19
|
end
|
21
20
|
|
22
|
-
|
21
|
+
desc "Validate the gemspec"
|
22
|
+
task :gemspec do
|
23
|
+
puts gemspec.validate
|
24
|
+
end
|
@@ -87,5 +87,20 @@ module TaxCloud
|
|
87
87
|
|
88
88
|
response = TaxCloud.client.request :authorized_with_capture, :body => request_params
|
89
89
|
end
|
90
|
+
|
91
|
+
# Marks any included cart items as returned.
|
92
|
+
#
|
93
|
+
# === Options
|
94
|
+
# * <tt>returned_date</tt> - The date the return occured. Default is today.
|
95
|
+
def returned(options = {})
|
96
|
+
options = { :returned_date => Date.today }.merge(options)
|
97
|
+
request_params = {
|
98
|
+
'orderID' => order_id,
|
99
|
+
'cartItems' => { 'CartItem' => cart_items.map(&:to_hash) },
|
100
|
+
'returnedDate' => options[:returned_date]
|
101
|
+
}.merge(TaxCloud.auth_params)
|
102
|
+
|
103
|
+
TaxCloud.client.request :returned, :body => request_params
|
104
|
+
end
|
90
105
|
end
|
91
106
|
end
|
data/lib/tax_cloud/version.rb
CHANGED
data/tax_cloud.gemspec
CHANGED
@@ -4,22 +4,23 @@ require "tax_cloud/version"
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "tax_cloud"
|
6
6
|
s.version = TaxCloud::VERSION
|
7
|
+
s.date = %q{2011-10-20}
|
7
8
|
s.authors = ["Drew Tempelmeyer"]
|
8
9
|
s.email = ["drewtemp@gmail.com"]
|
9
10
|
s.homepage = "https://github.com/drewtempelmeyer/tax_cloud"
|
10
|
-
s.summary = %q{Calculate sales tax using
|
11
|
+
s.summary = %q{Calculate sales tax using TaxCloud}
|
11
12
|
s.description = %q{Calculate sales tax using the TaxCloud.net API}
|
12
13
|
|
13
|
-
s.
|
14
|
-
|
14
|
+
s.required_rubygems_version = '>= 1.3.6'
|
15
15
|
s.files = `git ls-files`.split("\n")
|
16
16
|
s.test_files = `git ls-files -- {test}/*`.split("\n")
|
17
|
-
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
18
17
|
s.require_paths = ["lib"]
|
19
18
|
|
20
|
-
s.add_runtime_dependency
|
19
|
+
s.add_runtime_dependency 'savon', '0.9.6'
|
21
20
|
|
22
|
-
# Development
|
23
|
-
s.add_development_dependency
|
24
|
-
s.add_development_dependency
|
21
|
+
# Development dependencies
|
22
|
+
s.add_development_dependency 'rake', '>= 0.9.2'
|
23
|
+
s.add_development_dependency 'rdoc', '>= 2.5.0'
|
24
|
+
s.add_development_dependency 'vcr', '>= 1.11.3'
|
25
|
+
s.add_development_dependency 'webmock', '>= 1.7.6'
|
25
26
|
end
|
@@ -0,0 +1,63 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
6
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Lookup><ins0:customerID>2583</ins0:customerID><ins0:cartID>708</ins0:cartID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:origin><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:origin><ins0:destination><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:destination><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Lookup></env:Body></env:Envelope>
|
7
|
+
headers:
|
8
|
+
soapaction:
|
9
|
+
- "\"http://taxcloud.net/Lookup\""
|
10
|
+
content-type:
|
11
|
+
- text/xml;charset=UTF-8
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
cache-control:
|
18
|
+
- private, max-age=0
|
19
|
+
content-type:
|
20
|
+
- text/xml; charset=utf-8
|
21
|
+
server:
|
22
|
+
- Microsoft-IIS/7.0
|
23
|
+
x-aspnet-version:
|
24
|
+
- 2.0.50727
|
25
|
+
x-powered-by:
|
26
|
+
- TaxCloud
|
27
|
+
date:
|
28
|
+
- Sat, 17 Sep 2011 19:21:55 GMT
|
29
|
+
content-length:
|
30
|
+
- "869"
|
31
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><LookupResponse xmlns="http://taxcloud.net"><LookupResult><ResponseType>Informational</ResponseType><Messages><ResponseMessage><ResponseType>Informational</ResponseType><Message>The transaction occurred in a non-SSUTA State. TaxCloud will not collect or remit the tax amount for this transaction.</Message></ResponseMessage></Messages><CartID>708</CartID><CartItemsResponse><CartItemResponse><CartItemIndex>0</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse><CartItemResponse><CartItemIndex>1</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse></CartItemsResponse></LookupResult></LookupResponse></soap:Body></soap:Envelope>
|
32
|
+
http_version: "1.1"
|
33
|
+
- !ruby/struct:VCR::HTTPInteraction
|
34
|
+
request: !ruby/struct:VCR::Request
|
35
|
+
method: :post
|
36
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
37
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Authorized><ins0:customerID>2583</ins0:customerID><ins0:cartID>708</ins0:cartID><ins0:orderID>2361</ins0:orderID><ins0:dateAuthorized>2011-09-17</ins0:dateAuthorized><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Authorized></env:Body></env:Envelope>
|
38
|
+
headers:
|
39
|
+
soapaction:
|
40
|
+
- "\"http://taxcloud.net/Authorized\""
|
41
|
+
content-type:
|
42
|
+
- text/xml;charset=UTF-8
|
43
|
+
response: !ruby/struct:VCR::Response
|
44
|
+
status: !ruby/struct:VCR::ResponseStatus
|
45
|
+
code: 200
|
46
|
+
message: OK
|
47
|
+
headers:
|
48
|
+
cache-control:
|
49
|
+
- private, max-age=0
|
50
|
+
content-type:
|
51
|
+
- text/xml; charset=utf-8
|
52
|
+
server:
|
53
|
+
- Microsoft-IIS/7.0
|
54
|
+
x-aspnet-version:
|
55
|
+
- 2.0.50727
|
56
|
+
x-powered-by:
|
57
|
+
- TaxCloud
|
58
|
+
date:
|
59
|
+
- Sat, 17 Sep 2011 19:21:56 GMT
|
60
|
+
content-length:
|
61
|
+
- "395"
|
62
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><AuthorizedResponse xmlns="http://taxcloud.net"><AuthorizedResult><ResponseType>OK</ResponseType><Messages /></AuthorizedResult></AuthorizedResponse></soap:Body></soap:Envelope>
|
63
|
+
http_version: "1.1"
|
@@ -0,0 +1,63 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
6
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Lookup><ins0:customerID>1644</ins0:customerID><ins0:cartID>8291</ins0:cartID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:origin><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:origin><ins0:destination><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:destination><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Lookup></env:Body></env:Envelope>
|
7
|
+
headers:
|
8
|
+
soapaction:
|
9
|
+
- "\"http://taxcloud.net/Lookup\""
|
10
|
+
content-type:
|
11
|
+
- text/xml;charset=UTF-8
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
cache-control:
|
18
|
+
- private, max-age=0
|
19
|
+
content-type:
|
20
|
+
- text/xml; charset=utf-8
|
21
|
+
server:
|
22
|
+
- Microsoft-IIS/7.0
|
23
|
+
x-aspnet-version:
|
24
|
+
- 2.0.50727
|
25
|
+
x-powered-by:
|
26
|
+
- TaxCloud
|
27
|
+
date:
|
28
|
+
- Sat, 17 Sep 2011 19:21:56 GMT
|
29
|
+
content-length:
|
30
|
+
- "870"
|
31
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><LookupResponse xmlns="http://taxcloud.net"><LookupResult><ResponseType>Informational</ResponseType><Messages><ResponseMessage><ResponseType>Informational</ResponseType><Message>The transaction occurred in a non-SSUTA State. TaxCloud will not collect or remit the tax amount for this transaction.</Message></ResponseMessage></Messages><CartID>8291</CartID><CartItemsResponse><CartItemResponse><CartItemIndex>0</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse><CartItemResponse><CartItemIndex>1</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse></CartItemsResponse></LookupResult></LookupResponse></soap:Body></soap:Envelope>
|
32
|
+
http_version: "1.1"
|
33
|
+
- !ruby/struct:VCR::HTTPInteraction
|
34
|
+
request: !ruby/struct:VCR::Request
|
35
|
+
method: :post
|
36
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
37
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:AuthorizedWithCapture><ins0:customerID>1644</ins0:customerID><ins0:cartID>8291</ins0:cartID><ins0:orderID>4804</ins0:orderID><ins0:dateAuthorized>2011-09-17</ins0:dateAuthorized><ins0:dateCaptured>2011-09-17</ins0:dateCaptured><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:AuthorizedWithCapture></env:Body></env:Envelope>
|
38
|
+
headers:
|
39
|
+
soapaction:
|
40
|
+
- "\"http://taxcloud.net/AuthorizedWithCapture\""
|
41
|
+
content-type:
|
42
|
+
- text/xml;charset=UTF-8
|
43
|
+
response: !ruby/struct:VCR::Response
|
44
|
+
status: !ruby/struct:VCR::ResponseStatus
|
45
|
+
code: 200
|
46
|
+
message: OK
|
47
|
+
headers:
|
48
|
+
cache-control:
|
49
|
+
- private, max-age=0
|
50
|
+
content-type:
|
51
|
+
- text/xml; charset=utf-8
|
52
|
+
server:
|
53
|
+
- Microsoft-IIS/7.0
|
54
|
+
x-aspnet-version:
|
55
|
+
- 2.0.50727
|
56
|
+
x-powered-by:
|
57
|
+
- TaxCloud
|
58
|
+
date:
|
59
|
+
- Sat, 17 Sep 2011 19:21:58 GMT
|
60
|
+
content-length:
|
61
|
+
- "439"
|
62
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><AuthorizedWithCaptureResponse xmlns="http://taxcloud.net"><AuthorizedWithCaptureResult><ResponseType>OK</ResponseType><Messages /></AuthorizedWithCaptureResult></AuthorizedWithCaptureResponse></soap:Body></soap:Envelope>
|
63
|
+
http_version: "1.1"
|
@@ -0,0 +1,94 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
6
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Lookup><ins0:customerID>8062</ins0:customerID><ins0:cartID>1097</ins0:cartID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:origin><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:origin><ins0:destination><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:destination><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Lookup></env:Body></env:Envelope>
|
7
|
+
headers:
|
8
|
+
soapaction:
|
9
|
+
- "\"http://taxcloud.net/Lookup\""
|
10
|
+
content-type:
|
11
|
+
- text/xml;charset=UTF-8
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
cache-control:
|
18
|
+
- private, max-age=0
|
19
|
+
content-type:
|
20
|
+
- text/xml; charset=utf-8
|
21
|
+
server:
|
22
|
+
- Microsoft-IIS/7.0
|
23
|
+
x-aspnet-version:
|
24
|
+
- 2.0.50727
|
25
|
+
x-powered-by:
|
26
|
+
- TaxCloud
|
27
|
+
date:
|
28
|
+
- Sat, 17 Sep 2011 19:21:58 GMT
|
29
|
+
content-length:
|
30
|
+
- "870"
|
31
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><LookupResponse xmlns="http://taxcloud.net"><LookupResult><ResponseType>Informational</ResponseType><Messages><ResponseMessage><ResponseType>Informational</ResponseType><Message>The transaction occurred in a non-SSUTA State. TaxCloud will not collect or remit the tax amount for this transaction.</Message></ResponseMessage></Messages><CartID>1097</CartID><CartItemsResponse><CartItemResponse><CartItemIndex>0</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse><CartItemResponse><CartItemIndex>1</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse></CartItemsResponse></LookupResult></LookupResponse></soap:Body></soap:Envelope>
|
32
|
+
http_version: "1.1"
|
33
|
+
- !ruby/struct:VCR::HTTPInteraction
|
34
|
+
request: !ruby/struct:VCR::Request
|
35
|
+
method: :post
|
36
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
37
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Authorized><ins0:customerID>8062</ins0:customerID><ins0:cartID>1097</ins0:cartID><ins0:orderID>3260</ins0:orderID><ins0:dateAuthorized>2011-09-17</ins0:dateAuthorized><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Authorized></env:Body></env:Envelope>
|
38
|
+
headers:
|
39
|
+
soapaction:
|
40
|
+
- "\"http://taxcloud.net/Authorized\""
|
41
|
+
content-type:
|
42
|
+
- text/xml;charset=UTF-8
|
43
|
+
response: !ruby/struct:VCR::Response
|
44
|
+
status: !ruby/struct:VCR::ResponseStatus
|
45
|
+
code: 200
|
46
|
+
message: OK
|
47
|
+
headers:
|
48
|
+
cache-control:
|
49
|
+
- private, max-age=0
|
50
|
+
content-type:
|
51
|
+
- text/xml; charset=utf-8
|
52
|
+
server:
|
53
|
+
- Microsoft-IIS/7.0
|
54
|
+
x-aspnet-version:
|
55
|
+
- 2.0.50727
|
56
|
+
x-powered-by:
|
57
|
+
- TaxCloud
|
58
|
+
date:
|
59
|
+
- Sat, 17 Sep 2011 19:21:59 GMT
|
60
|
+
content-length:
|
61
|
+
- "395"
|
62
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><AuthorizedResponse xmlns="http://taxcloud.net"><AuthorizedResult><ResponseType>OK</ResponseType><Messages /></AuthorizedResult></AuthorizedResponse></soap:Body></soap:Envelope>
|
63
|
+
http_version: "1.1"
|
64
|
+
- !ruby/struct:VCR::HTTPInteraction
|
65
|
+
request: !ruby/struct:VCR::Request
|
66
|
+
method: :post
|
67
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
68
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Captured><wsdl:customerID>8062</wsdl:customerID><wsdl:cartID>1097</wsdl:cartID><ins0:orderID>3260</ins0:orderID><wsdl:dateCaptured>2011-09-17T00:00:00+00:00</wsdl:dateCaptured><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Captured></env:Body></env:Envelope>
|
69
|
+
headers:
|
70
|
+
soapaction:
|
71
|
+
- "\"http://taxcloud.net/Captured\""
|
72
|
+
content-type:
|
73
|
+
- text/xml;charset=UTF-8
|
74
|
+
response: !ruby/struct:VCR::Response
|
75
|
+
status: !ruby/struct:VCR::ResponseStatus
|
76
|
+
code: 200
|
77
|
+
message: OK
|
78
|
+
headers:
|
79
|
+
cache-control:
|
80
|
+
- private, max-age=0
|
81
|
+
content-type:
|
82
|
+
- text/xml; charset=utf-8
|
83
|
+
server:
|
84
|
+
- Microsoft-IIS/7.0
|
85
|
+
x-aspnet-version:
|
86
|
+
- 2.0.50727
|
87
|
+
x-powered-by:
|
88
|
+
- TaxCloud
|
89
|
+
date:
|
90
|
+
- Sat, 17 Sep 2011 19:21:59 GMT
|
91
|
+
content-length:
|
92
|
+
- "387"
|
93
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><CapturedResponse xmlns="http://taxcloud.net"><CapturedResult><ResponseType>OK</ResponseType><Messages /></CapturedResult></CapturedResponse></soap:Body></soap:Envelope>
|
94
|
+
http_version: "1.1"
|
@@ -0,0 +1,32 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
6
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Lookup><ins0:customerID>1212</ins0:customerID><ins0:cartID>1152</ins0:cartID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:origin><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:origin><ins0:destination><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:destination><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Lookup></env:Body></env:Envelope>
|
7
|
+
headers:
|
8
|
+
soapaction:
|
9
|
+
- "\"http://taxcloud.net/Lookup\""
|
10
|
+
content-type:
|
11
|
+
- text/xml;charset=UTF-8
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
cache-control:
|
18
|
+
- private, max-age=0
|
19
|
+
content-type:
|
20
|
+
- text/xml; charset=utf-8
|
21
|
+
server:
|
22
|
+
- Microsoft-IIS/7.0
|
23
|
+
x-aspnet-version:
|
24
|
+
- 2.0.50727
|
25
|
+
x-powered-by:
|
26
|
+
- TaxCloud
|
27
|
+
date:
|
28
|
+
- Sat, 17 Sep 2011 19:22:00 GMT
|
29
|
+
content-length:
|
30
|
+
- "870"
|
31
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><LookupResponse xmlns="http://taxcloud.net"><LookupResult><ResponseType>Informational</ResponseType><Messages><ResponseMessage><ResponseType>Informational</ResponseType><Message>The transaction occurred in a non-SSUTA State. TaxCloud will not collect or remit the tax amount for this transaction.</Message></ResponseMessage></Messages><CartID>1152</CartID><CartItemsResponse><CartItemResponse><CartItemIndex>0</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse><CartItemResponse><CartItemIndex>1</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse></CartItemsResponse></LookupResult></LookupResponse></soap:Body></soap:Envelope>
|
32
|
+
http_version: "1.1"
|
@@ -0,0 +1,94 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
6
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Lookup><ins0:customerID>9860</ins0:customerID><ins0:cartID>941</ins0:cartID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:origin><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:origin><ins0:destination><ins0:Address1>888 6th Ave</ins0:Address1><ins0:Address2 xsi:nil="true"/><ins0:City>New York</ins0:City><ins0:State>NY</ins0:State><ins0:Zip5>10001</ins0:Zip5><ins0:Zip4 xsi:nil="true"/></ins0:destination><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Lookup></env:Body></env:Envelope>
|
7
|
+
headers:
|
8
|
+
soapaction:
|
9
|
+
- "\"http://taxcloud.net/Lookup\""
|
10
|
+
content-type:
|
11
|
+
- text/xml;charset=UTF-8
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
cache-control:
|
18
|
+
- private, max-age=0
|
19
|
+
content-type:
|
20
|
+
- text/xml; charset=utf-8
|
21
|
+
server:
|
22
|
+
- Microsoft-IIS/7.0
|
23
|
+
x-aspnet-version:
|
24
|
+
- 2.0.50727
|
25
|
+
x-powered-by:
|
26
|
+
- TaxCloud
|
27
|
+
date:
|
28
|
+
- Sat, 17 Sep 2011 19:22:00 GMT
|
29
|
+
content-length:
|
30
|
+
- "869"
|
31
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><LookupResponse xmlns="http://taxcloud.net"><LookupResult><ResponseType>Informational</ResponseType><Messages><ResponseMessage><ResponseType>Informational</ResponseType><Message>The transaction occurred in a non-SSUTA State. TaxCloud will not collect or remit the tax amount for this transaction.</Message></ResponseMessage></Messages><CartID>941</CartID><CartItemsResponse><CartItemResponse><CartItemIndex>0</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse><CartItemResponse><CartItemIndex>1</CartItemIndex><TaxAmount>4.4375</TaxAmount></CartItemResponse></CartItemsResponse></LookupResult></LookupResponse></soap:Body></soap:Envelope>
|
32
|
+
http_version: "1.1"
|
33
|
+
- !ruby/struct:VCR::HTTPInteraction
|
34
|
+
request: !ruby/struct:VCR::Request
|
35
|
+
method: :post
|
36
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
37
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:AuthorizedWithCapture><ins0:customerID>9860</ins0:customerID><ins0:cartID>941</ins0:cartID><ins0:orderID>9393</ins0:orderID><ins0:dateAuthorized>2011-09-17</ins0:dateAuthorized><ins0:dateCaptured>2011-09-17</ins0:dateCaptured><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:AuthorizedWithCapture></env:Body></env:Envelope>
|
38
|
+
headers:
|
39
|
+
soapaction:
|
40
|
+
- "\"http://taxcloud.net/AuthorizedWithCapture\""
|
41
|
+
content-type:
|
42
|
+
- text/xml;charset=UTF-8
|
43
|
+
response: !ruby/struct:VCR::Response
|
44
|
+
status: !ruby/struct:VCR::ResponseStatus
|
45
|
+
code: 200
|
46
|
+
message: OK
|
47
|
+
headers:
|
48
|
+
cache-control:
|
49
|
+
- private, max-age=0
|
50
|
+
content-type:
|
51
|
+
- text/xml; charset=utf-8
|
52
|
+
server:
|
53
|
+
- Microsoft-IIS/7.0
|
54
|
+
x-aspnet-version:
|
55
|
+
- 2.0.50727
|
56
|
+
x-powered-by:
|
57
|
+
- TaxCloud
|
58
|
+
date:
|
59
|
+
- Sat, 17 Sep 2011 19:22:01 GMT
|
60
|
+
content-length:
|
61
|
+
- "439"
|
62
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><AuthorizedWithCaptureResponse xmlns="http://taxcloud.net"><AuthorizedWithCaptureResult><ResponseType>OK</ResponseType><Messages /></AuthorizedWithCaptureResult></AuthorizedWithCaptureResponse></soap:Body></soap:Envelope>
|
63
|
+
http_version: "1.1"
|
64
|
+
- !ruby/struct:VCR::HTTPInteraction
|
65
|
+
request: !ruby/struct:VCR::Request
|
66
|
+
method: :post
|
67
|
+
uri: https://api.taxcloud.net:443/1.0/TaxCloud.asmx
|
68
|
+
body: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://taxcloud.net" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ins0="http://taxcloud.net"><env:Body><ins0:Returned><ins0:orderID>9393</ins0:orderID><ins0:cartItems><ins0:CartItem><wsdl:Index>0</wsdl:Index><wsdl:ItemID>SKU-TEST</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem><ins0:CartItem><wsdl:Index>1</wsdl:Index><wsdl:ItemID>SKU-TEST1</wsdl:ItemID><wsdl:TIC>00000</wsdl:TIC><wsdl:Price>50.0</wsdl:Price><wsdl:Qty>1</wsdl:Qty></ins0:CartItem></ins0:cartItems><ins0:returnedDate>2011-09-17</ins0:returnedDate><ins0:apiLoginID>api-login-id</ins0:apiLoginID><ins0:apiKey>api-key</ins0:apiKey></ins0:Returned></env:Body></env:Envelope>
|
69
|
+
headers:
|
70
|
+
soapaction:
|
71
|
+
- "\"http://taxcloud.net/Returned\""
|
72
|
+
content-type:
|
73
|
+
- text/xml;charset=UTF-8
|
74
|
+
response: !ruby/struct:VCR::Response
|
75
|
+
status: !ruby/struct:VCR::ResponseStatus
|
76
|
+
code: 200
|
77
|
+
message: OK
|
78
|
+
headers:
|
79
|
+
cache-control:
|
80
|
+
- private, max-age=0
|
81
|
+
content-type:
|
82
|
+
- text/xml; charset=utf-8
|
83
|
+
server:
|
84
|
+
- Microsoft-IIS/7.0
|
85
|
+
x-aspnet-version:
|
86
|
+
- 2.0.50727
|
87
|
+
x-powered-by:
|
88
|
+
- TaxCloud
|
89
|
+
date:
|
90
|
+
- Sat, 17 Sep 2011 19:22:01 GMT
|
91
|
+
content-length:
|
92
|
+
- "387"
|
93
|
+
body: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><ReturnedResponse xmlns="http://taxcloud.net"><ReturnedResult><ResponseType>OK</ResponseType><Messages /></ReturnedResult></ReturnedResponse></soap:Body></soap:Envelope>
|
94
|
+
http_version: "1.1"
|