super_good-solidus_taxjar 0.18.2 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +48 -6
- data/CHANGELOG.md +103 -1
- data/Gemfile +26 -10
- data/PULL_REQUEST_TEMPLATE.md +0 -1
- data/README.md +299 -39
- data/Rakefile +3 -0
- data/app/controllers/spree/admin/taxjar_settings_controller.rb +86 -1
- data/app/controllers/spree/admin/taxjar_transactions_controller.rb +37 -0
- data/app/controllers/spree/admin/transaction_sync_batches_controller.rb +18 -0
- data/app/jobs/super_good/solidus_taxjar/backfill_transaction_sync_batch_job.rb +23 -0
- data/app/jobs/super_good/solidus_taxjar/replace_transaction_job.rb +26 -0
- data/app/jobs/super_good/solidus_taxjar/report_transaction_job.rb +22 -0
- data/app/models/super_good/solidus_taxjar/configuration.rb +27 -0
- data/app/models/super_good/solidus_taxjar/order_transaction.rb +16 -0
- data/app/models/super_good/solidus_taxjar/refund_transaction.rb +13 -0
- data/app/models/super_good/solidus_taxjar/transaction_sync_batch.rb +11 -0
- data/app/models/super_good/solidus_taxjar/transaction_sync_log.rb +8 -0
- data/app/overrides/spree/admin/orders_controller_override.rb +12 -0
- data/app/overrides/spree/admin/shared/_order_submenu/add_taxjar_sync_history_tab.html.erb.deface +6 -0
- data/app/overrides/spree/admin/shared/_order_summary/add_taxjar_reported_at.html.erb.deface +30 -0
- data/app/overrides/spree/admin/shared/_taxes_tabs/add_configuration_menu_items.html.erb.deface +5 -0
- data/app/overrides/super_good/solidus_taxjar/spree/order_override.rb +21 -0
- data/app/views/spree/admin/orders/taxjar_transactions.html.erb +4 -0
- data/app/views/spree/admin/shared/_transaction_sync_log_table.html.erb +35 -0
- data/app/views/spree/admin/taxjar_settings/_nexus_regions.html.erb +23 -0
- data/app/views/spree/admin/taxjar_settings/_tax_categories.html.erb +41 -0
- data/app/views/spree/admin/taxjar_settings/edit.html.erb +17 -0
- data/app/views/spree/admin/taxjar_settings/edit_no_api_key.html.erb +21 -0
- data/app/views/spree/admin/transaction_sync_batches/index.html.erb +50 -0
- data/app/views/spree/admin/transaction_sync_batches/show.html.erb +7 -0
- data/bin/console +2 -0
- data/bin/rails-engine +1 -1
- data/bin/sandbox +43 -36
- data/bin/setup +3 -3
- data/config/routes.rb +13 -1
- data/db/migrate/20210908205201_create_taxjar_order_transactions.rb +16 -0
- data/db/migrate/20211008175113_create_taxjar_refund_transaction.rb +15 -0
- data/db/migrate/20211008183858_add_transaction_date_to_order_transaction.rb +5 -0
- data/db/migrate/20211119143354_create_configuration.rb +8 -0
- data/db/migrate/20220405213958_create_transaction_sync_batches.rb +7 -0
- data/db/migrate/20220405215225_create_transaction_sync_logs.rb +14 -0
- data/db/migrate/20220908181655_add_dates_to_transaction_sync_batch.rb +6 -0
- data/db/migrate/20220912182210_allow_null_transaction_sync_batches_on_logs.rb +5 -0
- data/db/migrate/20230320211309_add_refund_transaction_to_sync_logs.rb +5 -0
- data/lib/generators/super_good/solidus_taxjar/install/install_generator.rb +68 -0
- data/lib/super_good/solidus_taxjar/api.rb +41 -9
- data/lib/super_good/solidus_taxjar/api_params.rb +92 -25
- data/lib/super_good/solidus_taxjar/backfill_transactions.rb +11 -0
- data/lib/super_good/solidus_taxjar/cached_api.rb +23 -0
- data/lib/super_good/solidus_taxjar/calculator_helper.rb +33 -4
- data/lib/super_good/solidus_taxjar/discount_calculator.rb +1 -1
- data/lib/super_good/solidus_taxjar/overrides/request_override.rb +15 -0
- data/lib/super_good/solidus_taxjar/reportable.rb +91 -0
- data/lib/super_good/solidus_taxjar/reporting.rb +44 -0
- data/lib/super_good/solidus_taxjar/spree/legacy_reporting_subscriber.rb +41 -0
- data/lib/super_good/solidus_taxjar/spree/reporting_subscriber.rb +40 -0
- data/lib/super_good/solidus_taxjar/tax_calculator.rb +7 -1
- data/lib/super_good/solidus_taxjar/testing_support/factories/address_factory.rb +11 -0
- data/lib/super_good/solidus_taxjar/testing_support/factories/configuration_factory.rb +11 -0
- data/lib/super_good/solidus_taxjar/testing_support/factories/order_transaction_factory.rb +22 -0
- data/lib/super_good/solidus_taxjar/testing_support/factories/refund_transaction_factory.rb +7 -0
- data/lib/super_good/solidus_taxjar/testing_support/factories/transaction_sync_batch_factory.rb +9 -0
- data/lib/super_good/solidus_taxjar/testing_support/factories/transaction_sync_log_factory.rb +18 -0
- data/lib/super_good/solidus_taxjar/transaction_id_generator.rb +45 -0
- data/lib/super_good/solidus_taxjar/version.rb +1 -1
- data/lib/super_good/solidus_taxjar.rb +29 -2
- data/spec/features/spree/admin/backfill_transactions_spec.rb +138 -0
- data/spec/features/spree/admin/refund_spec.rb +167 -0
- data/spec/features/spree/admin/reporting_to_taxjar_spec.rb +156 -0
- data/spec/features/spree/admin/taxjar_settings_spec.rb +58 -16
- data/spec/features/spree/checkout_spec.rb +58 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/GET_sync_nexus_regions/Taxjar_API_token_is_not_set/doesn_t_make_a_request_for_the_nexus_regions.yml +57 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/GET_sync_tax_categories/Taxjar_API_token_is_not_set/doesn_t_make_a_request_for_the_tax_categories.yml +57 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/Taxjar_API_token_is_set/shows_the_settings_page.yml +2437 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/Taxjar_API_token_isn_t_set/doesn_t_show_any_other_TaxJar_features.yml +57 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/Taxjar_API_token_isn_t_set/shows_a_descriptive_error_message.yml +57 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/Taxjar_reporting_is_enabled/shows_that_reporting_is_enabled.yml +2382 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/order_is_shipped/the_user_backfills_their_transactions.yml +2511 -0
- data/spec/fixtures/cassettes/Admin_TaxJar_Settings/Taxjar_settings_tab/the_user_navigates_to_the_TaxJar_Settings.yml +2382 -0
- data/spec/fixtures/cassettes/Admin_Transaction_Sync_Batches/user_has_a_shipped_order/starts_a_transaction_backfill.yml +370 -0
- data/spec/fixtures/cassettes/Reporting_orders_to_TaxJar/shipping_a_complete_and_paid_order.yml +310 -0
- data/spec/fixtures/cassettes/Reporting_orders_to_TaxJar/updating_an_order_which_was_not_reported_due_to_failure/it_reports_the_order_instead_of_trying_to_replace_it.yml +794 -0
- data/spec/fixtures/cassettes/Reporting_orders_to_TaxJar/with_an_order_with_invalid_zipcode/retry_of_a_previously_failed_transaction_sync.yml +418 -0
- data/spec/fixtures/cassettes/Spree_Admin_TransactionSyncBatchesController/_create/creates_a_batch.yml +250 -0
- data/spec/fixtures/cassettes/Spree_Admin_TransactionSyncBatchesController/_create/creates_a_log_in_the_batch_with_an_order.yml +250 -0
- data/spec/fixtures/cassettes/Spree_Admin_TransactionSyncBatchesController/_create/user_supplies_a_start_date/creates_a_batch.yml +250 -0
- data/spec/fixtures/cassettes/Spree_Admin_TransactionSyncBatchesController/_create/user_supplies_a_start_date/user_supplies_start_and_end_date/creates_a_batch.yml +250 -0
- data/spec/fixtures/cassettes/SuperGood_SolidusTaxjar_CalculatorHelper/_taxable_address_/when_taxable_address_check_returns_true/with_US_address/when_the_address_is_not_within_a_nexus_region/1_3_2_2_2_1.yml +58 -0
- data/spec/fixtures/cassettes/SuperGood_SolidusTaxjar_CalculatorHelper/_taxable_address_/when_taxable_address_check_returns_true/with_US_address/when_the_address_is_within_a_nexus_region/1_3_2_2_1_1.yml +58 -0
- data/spec/fixtures/cassettes/SuperGood_SolidusTaxjar_Reporting/_refund_and_create_transaction/when_Taxjar_cannot_create_a_refund_transaction/doesn_t_create_a_new_transaction.yml +393 -0
- data/spec/fixtures/cassettes/SuperGood_SolidusTaxjar_Reporting/_refund_and_create_transaction/when_Taxjar_cannot_create_a_refund_transaction/raises_an_error.yml +393 -0
- data/spec/fixtures/cassettes/Taxjar_API_Request/logging_is_disabled/doesn_t_call_the_logger.yml +158 -0
- data/spec/fixtures/cassettes/Taxjar_API_Request/logging_is_enabled/calls_the_logger.yml +158 -0
- data/spec/fixtures/cassettes/features/spree/admin/checkout.yml +238 -0
- data/spec/fixtures/cassettes/features/spree/admin/refund.yml +1162 -0
- data/spec/jobs/super_good/solidus_taxjar/backfill_transaction_sync_batch_job_spec.rb +117 -0
- data/spec/jobs/super_good/solidus_taxjar/replace_transaction_job_spec.rb +95 -0
- data/spec/jobs/super_good/solidus_taxjar/report_transaction_job_spec.rb +76 -0
- data/spec/models/super_good/solidus_taxjar/configuration_spec.rb +79 -0
- data/spec/models/super_good/solidus_taxjar/order_transaction_spec.rb +36 -0
- data/spec/models/super_good/solidus_taxjar/transaction_sync_batch_spec.rb +48 -0
- data/spec/requests/spree/admin/order_request_spec.rb +121 -0
- data/spec/requests/spree/admin/taxjar_settings_request_spec.rb +198 -0
- data/spec/requests/spree/admin/taxjar_transactions_request_spec.rb +62 -0
- data/spec/requests/spree/admin/transaction_sync_batches_request_spec.rb +82 -0
- data/spec/spec_helper.rb +46 -3
- data/spec/subscribers/super_good/solidus_taxjar/spree/reporting_subscriber_spec.rb +278 -0
- data/spec/super_good/solidus_taxjar/addresses_spec.rb +0 -14
- data/spec/super_good/solidus_taxjar/api_params_spec.rb +261 -89
- data/spec/super_good/solidus_taxjar/api_spec.rb +152 -29
- data/spec/super_good/solidus_taxjar/backfill_transactions_spec.rb +24 -0
- data/spec/super_good/solidus_taxjar/cached_api_spec.rb +58 -0
- data/spec/super_good/solidus_taxjar/calculator_helper_spec.rb +131 -0
- data/spec/super_good/solidus_taxjar/discount_calculator_spec.rb +19 -2
- data/spec/super_good/solidus_taxjar/reportable_spec.rb +194 -0
- data/spec/super_good/solidus_taxjar/reporting_spec.rb +243 -0
- data/spec/super_good/solidus_taxjar/tax_calculator_spec.rb +19 -19
- data/spec/super_good/solidus_taxjar/tax_rate_calculator_spec.rb +8 -3
- data/spec/super_good/solidus_taxjar/transaction_id_generator_spec.rb +77 -0
- data/spec/super_good/solidus_taxjar_spec.rb +84 -0
- data/spec/support/checkoutable_store_shared_context.rb +19 -0
- data/spec/support/solidus_events_helper.rb +26 -0
- data/spec/taxjar/api/request_spec.rb +52 -0
- data/super_good-solidus_taxjar.gemspec +3 -2
- metadata +169 -17
- data/app/decorators/super_good/solidus_taxjar/spree/order_updater/fire_recalculated_event.rb +0 -18
- data/app/overrides/spree/admin/shared/_configuration_menu.rb +0 -11
- data/app/views/spree/admin/taxjar_settings/show.html.erb +0 -13
- data/spec/models/spree/order_updater_spec.rb +0 -12
@@ -0,0 +1,418 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: https://api.taxjar.com/v2/nexus/regions
|
6
|
+
body:
|
7
|
+
encoding: ASCII-8BIT
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
User-Agent:
|
11
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
12
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
13
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
14
|
+
Authorization:
|
15
|
+
- Bearer <BEARER_TOKEN>
|
16
|
+
X-Api-Version:
|
17
|
+
- '2020-08-07'
|
18
|
+
Plugin:
|
19
|
+
- supergoodsolidustaxjar
|
20
|
+
Connection:
|
21
|
+
- close
|
22
|
+
Host:
|
23
|
+
- api.taxjar.com
|
24
|
+
response:
|
25
|
+
status:
|
26
|
+
code: 200
|
27
|
+
message: OK
|
28
|
+
headers:
|
29
|
+
Content-Type:
|
30
|
+
- application/json; charset=utf-8
|
31
|
+
Content-Length:
|
32
|
+
- '277'
|
33
|
+
Connection:
|
34
|
+
- close
|
35
|
+
Date:
|
36
|
+
- Fri, 15 Dec 2023 20:38:42 GMT
|
37
|
+
X-Amzn-Requestid:
|
38
|
+
- c67921d2-5236-4585-9492-1f695c369c62
|
39
|
+
X-Amz-Apigw-Id:
|
40
|
+
- QAHlAHBZoAMEQYQ=
|
41
|
+
X-Amzn-Trace-Id:
|
42
|
+
- Root=1-657cb952-1260ead76104c43e6abf75de
|
43
|
+
X-Cache:
|
44
|
+
- Miss from cloudfront
|
45
|
+
Via:
|
46
|
+
- 1.1 45d6a557ecb29942f314e3dd736d817a.cloudfront.net (CloudFront)
|
47
|
+
X-Amz-Cf-Pop:
|
48
|
+
- SEA73-P2
|
49
|
+
X-Amz-Cf-Id:
|
50
|
+
- 72Is89-961itqD-RRC0Y9mSahs4zOvzqM-k07UgLzWYqz0FCKSKl2w==
|
51
|
+
body:
|
52
|
+
encoding: UTF-8
|
53
|
+
string: '{"regions":[{"region_code":"BC","region":"British Columbia","country_code":"CA","country":"Canada"},{"region_code":"CA","region":"California","country_code":"US","country":"United
|
54
|
+
States"},{"region_code":"NY","region":"New York","country_code":"US","country":"United
|
55
|
+
States"}]}'
|
56
|
+
http_version:
|
57
|
+
recorded_at: Fri, 15 Dec 2023 20:38:42 GMT
|
58
|
+
- request:
|
59
|
+
method: post
|
60
|
+
uri: https://api.taxjar.com/v2/taxes
|
61
|
+
body:
|
62
|
+
encoding: ASCII-8BIT
|
63
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
64
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
65
|
+
- 410113"}],"shipping":"100.0"}'
|
66
|
+
headers:
|
67
|
+
User-Agent:
|
68
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
69
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
70
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
71
|
+
Authorization:
|
72
|
+
- Bearer <BEARER_TOKEN>
|
73
|
+
X-Api-Version:
|
74
|
+
- '2020-08-07'
|
75
|
+
Plugin:
|
76
|
+
- supergoodsolidustaxjar
|
77
|
+
Connection:
|
78
|
+
- close
|
79
|
+
Content-Type:
|
80
|
+
- application/json; charset=UTF-8
|
81
|
+
Host:
|
82
|
+
- api.taxjar.com
|
83
|
+
response:
|
84
|
+
status:
|
85
|
+
code: 400
|
86
|
+
message: Bad Request
|
87
|
+
headers:
|
88
|
+
Content-Type:
|
89
|
+
- application/json; charset=utf-8
|
90
|
+
Content-Length:
|
91
|
+
- '91'
|
92
|
+
Connection:
|
93
|
+
- close
|
94
|
+
Date:
|
95
|
+
- Fri, 15 Dec 2023 20:38:43 GMT
|
96
|
+
X-Amzn-Requestid:
|
97
|
+
- 274e2b32-fb34-44b4-bb1b-8fdb5d3513fc
|
98
|
+
X-Amz-Apigw-Id:
|
99
|
+
- QAHlDH0YIAMEicQ=
|
100
|
+
X-Amzn-Trace-Id:
|
101
|
+
- Root=1-657cb953-4082dd5510aa91b4048e2754
|
102
|
+
X-Cache:
|
103
|
+
- Error from cloudfront
|
104
|
+
Via:
|
105
|
+
- 1.1 73b60e9a9fd08eae9e034cedba707280.cloudfront.net (CloudFront)
|
106
|
+
X-Amz-Cf-Pop:
|
107
|
+
- SEA73-P2
|
108
|
+
X-Amz-Cf-Id:
|
109
|
+
- 92pSNJxwx3xSqEJsuY-qn4AJ4QkWUBz3DTrhXCbSlzWEY0Gbo45Wjw==
|
110
|
+
body:
|
111
|
+
encoding: UTF-8
|
112
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
113
|
+
within to_state NY"}'
|
114
|
+
http_version:
|
115
|
+
recorded_at: Fri, 15 Dec 2023 20:38:43 GMT
|
116
|
+
- request:
|
117
|
+
method: post
|
118
|
+
uri: https://api.taxjar.com/v2/taxes
|
119
|
+
body:
|
120
|
+
encoding: ASCII-8BIT
|
121
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
122
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
123
|
+
- 410113"}],"shipping":"100.0"}'
|
124
|
+
headers:
|
125
|
+
User-Agent:
|
126
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
127
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
128
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
129
|
+
Authorization:
|
130
|
+
- Bearer <BEARER_TOKEN>
|
131
|
+
X-Api-Version:
|
132
|
+
- '2020-08-07'
|
133
|
+
Plugin:
|
134
|
+
- supergoodsolidustaxjar
|
135
|
+
Connection:
|
136
|
+
- close
|
137
|
+
Content-Type:
|
138
|
+
- application/json; charset=UTF-8
|
139
|
+
Host:
|
140
|
+
- api.taxjar.com
|
141
|
+
response:
|
142
|
+
status:
|
143
|
+
code: 400
|
144
|
+
message: Bad Request
|
145
|
+
headers:
|
146
|
+
Content-Type:
|
147
|
+
- application/json; charset=utf-8
|
148
|
+
Content-Length:
|
149
|
+
- '91'
|
150
|
+
Connection:
|
151
|
+
- close
|
152
|
+
Date:
|
153
|
+
- Fri, 15 Dec 2023 20:38:43 GMT
|
154
|
+
X-Amzn-Requestid:
|
155
|
+
- 445e9d76-304d-417f-9cff-6f58a4c3f381
|
156
|
+
X-Amz-Apigw-Id:
|
157
|
+
- QAHlGHR1IAMEvXg=
|
158
|
+
X-Amzn-Trace-Id:
|
159
|
+
- Root=1-657cb953-5692ffc134979f4411f4d2ed
|
160
|
+
X-Cache:
|
161
|
+
- Error from cloudfront
|
162
|
+
Via:
|
163
|
+
- 1.1 27f6faf9790b5a2877fb528fa31f7922.cloudfront.net (CloudFront)
|
164
|
+
X-Amz-Cf-Pop:
|
165
|
+
- SEA73-P2
|
166
|
+
X-Amz-Cf-Id:
|
167
|
+
- t8tWyL2TQI2RFnYuJNwklIkFaWjPMyWYF3uZz8gHfIG3q3PC0GmoQQ==
|
168
|
+
body:
|
169
|
+
encoding: UTF-8
|
170
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
171
|
+
within to_state NY"}'
|
172
|
+
http_version:
|
173
|
+
recorded_at: Fri, 15 Dec 2023 20:38:43 GMT
|
174
|
+
- request:
|
175
|
+
method: post
|
176
|
+
uri: https://api.taxjar.com/v2/taxes
|
177
|
+
body:
|
178
|
+
encoding: ASCII-8BIT
|
179
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
180
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
181
|
+
- 410113"}],"shipping":"100.0"}'
|
182
|
+
headers:
|
183
|
+
User-Agent:
|
184
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
185
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
186
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
187
|
+
Authorization:
|
188
|
+
- Bearer <BEARER_TOKEN>
|
189
|
+
X-Api-Version:
|
190
|
+
- '2020-08-07'
|
191
|
+
Plugin:
|
192
|
+
- supergoodsolidustaxjar
|
193
|
+
Connection:
|
194
|
+
- close
|
195
|
+
Content-Type:
|
196
|
+
- application/json; charset=UTF-8
|
197
|
+
Host:
|
198
|
+
- api.taxjar.com
|
199
|
+
response:
|
200
|
+
status:
|
201
|
+
code: 400
|
202
|
+
message: Bad Request
|
203
|
+
headers:
|
204
|
+
Content-Type:
|
205
|
+
- application/json; charset=utf-8
|
206
|
+
Content-Length:
|
207
|
+
- '91'
|
208
|
+
Connection:
|
209
|
+
- close
|
210
|
+
Date:
|
211
|
+
- Fri, 15 Dec 2023 20:38:43 GMT
|
212
|
+
X-Amzn-Requestid:
|
213
|
+
- d1ba91e8-ec4c-48ee-87db-0b20fd90d191
|
214
|
+
X-Amz-Apigw-Id:
|
215
|
+
- QAHlJEhcIAMEUnQ=
|
216
|
+
X-Amzn-Trace-Id:
|
217
|
+
- Root=1-657cb953-07bd97724c076b23745ea0e1
|
218
|
+
X-Cache:
|
219
|
+
- Error from cloudfront
|
220
|
+
Via:
|
221
|
+
- 1.1 d1d67b07408bba8c682597d8303642e2.cloudfront.net (CloudFront)
|
222
|
+
X-Amz-Cf-Pop:
|
223
|
+
- SEA73-P2
|
224
|
+
X-Amz-Cf-Id:
|
225
|
+
- fxZ68Q6XpWi5mSllVFo5NqA4frDyfdYsVJG0VzHgcPxHvZc9s3r9Sg==
|
226
|
+
body:
|
227
|
+
encoding: UTF-8
|
228
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
229
|
+
within to_state NY"}'
|
230
|
+
http_version:
|
231
|
+
recorded_at: Fri, 15 Dec 2023 20:38:43 GMT
|
232
|
+
- request:
|
233
|
+
method: post
|
234
|
+
uri: https://api.taxjar.com/v2/taxes
|
235
|
+
body:
|
236
|
+
encoding: ASCII-8BIT
|
237
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
238
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
239
|
+
- 410113"}],"shipping":"100.0"}'
|
240
|
+
headers:
|
241
|
+
User-Agent:
|
242
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
243
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
244
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
245
|
+
Authorization:
|
246
|
+
- Bearer <BEARER_TOKEN>
|
247
|
+
X-Api-Version:
|
248
|
+
- '2020-08-07'
|
249
|
+
Plugin:
|
250
|
+
- supergoodsolidustaxjar
|
251
|
+
Connection:
|
252
|
+
- close
|
253
|
+
Content-Type:
|
254
|
+
- application/json; charset=UTF-8
|
255
|
+
Host:
|
256
|
+
- api.taxjar.com
|
257
|
+
response:
|
258
|
+
status:
|
259
|
+
code: 400
|
260
|
+
message: Bad Request
|
261
|
+
headers:
|
262
|
+
Content-Type:
|
263
|
+
- application/json; charset=utf-8
|
264
|
+
Content-Length:
|
265
|
+
- '91'
|
266
|
+
Connection:
|
267
|
+
- close
|
268
|
+
Date:
|
269
|
+
- Fri, 15 Dec 2023 20:38:44 GMT
|
270
|
+
X-Amzn-Requestid:
|
271
|
+
- c968b234-c010-4ffe-9525-1a9b4a64f6c7
|
272
|
+
X-Amz-Apigw-Id:
|
273
|
+
- QAHlLGcmIAMEVDQ=
|
274
|
+
X-Amzn-Trace-Id:
|
275
|
+
- Root=1-657cb954-24b3351170d028f941f14305
|
276
|
+
X-Cache:
|
277
|
+
- Error from cloudfront
|
278
|
+
Via:
|
279
|
+
- 1.1 1352c0a623ff0601dd16439f3f225f70.cloudfront.net (CloudFront)
|
280
|
+
X-Amz-Cf-Pop:
|
281
|
+
- SEA73-P2
|
282
|
+
X-Amz-Cf-Id:
|
283
|
+
- m1YkIm6eD11WqU3Q-yPys1xXG9bz0g-MZD3e7eZRXtsRwErVmSBelg==
|
284
|
+
body:
|
285
|
+
encoding: UTF-8
|
286
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
287
|
+
within to_state NY"}'
|
288
|
+
http_version:
|
289
|
+
recorded_at: Fri, 15 Dec 2023 20:38:44 GMT
|
290
|
+
- request:
|
291
|
+
method: post
|
292
|
+
uri: https://api.taxjar.com/v2/taxes
|
293
|
+
body:
|
294
|
+
encoding: ASCII-8BIT
|
295
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
296
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
297
|
+
- 410113"}],"shipping":"100.0"}'
|
298
|
+
headers:
|
299
|
+
User-Agent:
|
300
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
301
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
302
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
303
|
+
Authorization:
|
304
|
+
- Bearer <BEARER_TOKEN>
|
305
|
+
X-Api-Version:
|
306
|
+
- '2020-08-07'
|
307
|
+
Plugin:
|
308
|
+
- supergoodsolidustaxjar
|
309
|
+
Connection:
|
310
|
+
- close
|
311
|
+
Content-Type:
|
312
|
+
- application/json; charset=UTF-8
|
313
|
+
Host:
|
314
|
+
- api.taxjar.com
|
315
|
+
response:
|
316
|
+
status:
|
317
|
+
code: 400
|
318
|
+
message: Bad Request
|
319
|
+
headers:
|
320
|
+
Content-Type:
|
321
|
+
- application/json; charset=utf-8
|
322
|
+
Content-Length:
|
323
|
+
- '91'
|
324
|
+
Connection:
|
325
|
+
- close
|
326
|
+
Date:
|
327
|
+
- Fri, 15 Dec 2023 20:38:44 GMT
|
328
|
+
X-Amzn-Requestid:
|
329
|
+
- 3a7769ef-378b-4dae-bcf3-c3a135f69c54
|
330
|
+
X-Amz-Apigw-Id:
|
331
|
+
- QAHlTGyzoAMEa1g=
|
332
|
+
X-Amzn-Trace-Id:
|
333
|
+
- Root=1-657cb954-3a6fb2fe69c036a8052b4cfb
|
334
|
+
X-Cache:
|
335
|
+
- Error from cloudfront
|
336
|
+
Via:
|
337
|
+
- 1.1 de8fc80b494d3d381f7e006918dcc588.cloudfront.net (CloudFront)
|
338
|
+
X-Amz-Cf-Pop:
|
339
|
+
- SEA73-P2
|
340
|
+
X-Amz-Cf-Id:
|
341
|
+
- JrIhhRdFPrzJ4wA75yHoxI2jkNsmnDwNTdDrWuINUsuw3r_fiNt6ng==
|
342
|
+
body:
|
343
|
+
encoding: UTF-8
|
344
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
345
|
+
within to_state NY"}'
|
346
|
+
http_version:
|
347
|
+
recorded_at: Fri, 15 Dec 2023 20:38:44 GMT
|
348
|
+
- request:
|
349
|
+
method: post
|
350
|
+
uri: https://api.taxjar.com/v2/transactions/orders
|
351
|
+
body:
|
352
|
+
encoding: ASCII-8BIT
|
353
|
+
string: '{"customer_id":"1","to_country":"US","to_zip":"99999","to_city":"Herndon","to_state":"NY","to_street":"10
|
354
|
+
Lovely Street","line_items":[{"id":1,"quantity":1,"product_identifier":"SKU-1","description":"Product
|
355
|
+
#1 - 4937 - Master","product_tax_code":"TaxCode - 410113","unit_price":"10.0","discount":0,"sales_tax":"0.0"}],"transaction_id":"R075824223","transaction_date":"2023-12-15T20:38:43Z","amount":"110.0","shipping":"100.0","sales_tax":"0.0"}'
|
356
|
+
headers:
|
357
|
+
User-Agent:
|
358
|
+
- 'TaxJar/Ruby (Darwin Noahs-MBP.lan 21.6.0 Darwin Kernel Version 21.6.0: Mon
|
359
|
+
Apr 24 21:11:17 PDT 2023; root:xnu-8020.240.18.701.5~1/RELEASE_ARM64_T6000
|
360
|
+
arm64; ruby 3.2.2-p53; OpenSSL 3.1.2 1 Aug 2023) taxjar-ruby/3.0.4'
|
361
|
+
Authorization:
|
362
|
+
- Bearer <BEARER_TOKEN>
|
363
|
+
X-Api-Version:
|
364
|
+
- '2020-08-07'
|
365
|
+
Plugin:
|
366
|
+
- supergoodsolidustaxjar
|
367
|
+
Connection:
|
368
|
+
- close
|
369
|
+
Content-Type:
|
370
|
+
- application/json; charset=UTF-8
|
371
|
+
Host:
|
372
|
+
- api.taxjar.com
|
373
|
+
response:
|
374
|
+
status:
|
375
|
+
code: 400
|
376
|
+
message: Bad Request
|
377
|
+
headers:
|
378
|
+
Content-Type:
|
379
|
+
- application/json; charset=utf-8
|
380
|
+
Content-Length:
|
381
|
+
- '91'
|
382
|
+
Connection:
|
383
|
+
- close
|
384
|
+
Date:
|
385
|
+
- Fri, 15 Dec 2023 20:38:45 GMT
|
386
|
+
X-Amzn-Requestid:
|
387
|
+
- 32deea5e-6dba-4a2c-9d64-aac0732cbf4b
|
388
|
+
X-Amzn-Remapped-Content-Length:
|
389
|
+
- '91'
|
390
|
+
X-Amzn-Remapped-Connection:
|
391
|
+
- keep-alive
|
392
|
+
X-Request-Id:
|
393
|
+
- F6Eb0oba6S1Jh2UQO0_B
|
394
|
+
X-Api-Version:
|
395
|
+
- '2020-08-07'
|
396
|
+
X-Amz-Apigw-Id:
|
397
|
+
- QAHlWGRjIAMEcog=
|
398
|
+
Cache-Control:
|
399
|
+
- max-age=0, private, must-revalidate
|
400
|
+
X-Amzn-Remapped-Server:
|
401
|
+
- Cowboy
|
402
|
+
X-Amzn-Remapped-Date:
|
403
|
+
- Fri, 15 Dec 2023 20:38:45 GMT
|
404
|
+
X-Cache:
|
405
|
+
- Error from cloudfront
|
406
|
+
Via:
|
407
|
+
- 1.1 95785220a566cd050f3ad80928463374.cloudfront.net (CloudFront)
|
408
|
+
X-Amz-Cf-Pop:
|
409
|
+
- SEA73-P2
|
410
|
+
X-Amz-Cf-Id:
|
411
|
+
- hks_AewDz_vReaAoPP6arYF99D_IdtKshtq4g-0VSz6ml9UE-quJUw==
|
412
|
+
body:
|
413
|
+
encoding: UTF-8
|
414
|
+
string: '{"status":400,"error":"Bad Request","detail":"to_zip 99999 is not used
|
415
|
+
within to_state NY"}'
|
416
|
+
http_version:
|
417
|
+
recorded_at: Fri, 15 Dec 2023 20:38:45 GMT
|
418
|
+
recorded_with: VCR 4.0.0
|
@@ -0,0 +1,250 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: https://api.taxjar.com/v2/nexus/regions
|
6
|
+
body:
|
7
|
+
encoding: UTF-8
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
User-Agent:
|
11
|
+
- 'TaxJar/Ruby (Darwin Noahs-MacBook-Pro.local 20.6.0 Darwin Kernel Version
|
12
|
+
20.6.0: Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64
|
13
|
+
x86_64; ruby 2.7.6-p219; OpenSSL 1.1.1n 15 Mar 2022) taxjar-ruby/3.0.4'
|
14
|
+
Authorization:
|
15
|
+
- Bearer <BEARER_TOKEN>
|
16
|
+
X-Api-Version:
|
17
|
+
- '2020-08-07'
|
18
|
+
Plugin:
|
19
|
+
- supergoodsolidustaxjar
|
20
|
+
Connection:
|
21
|
+
- close
|
22
|
+
Host:
|
23
|
+
- api.taxjar.com
|
24
|
+
response:
|
25
|
+
status:
|
26
|
+
code: 200
|
27
|
+
message: OK
|
28
|
+
headers:
|
29
|
+
Content-Type:
|
30
|
+
- application/json; charset=utf-8
|
31
|
+
Content-Length:
|
32
|
+
- '277'
|
33
|
+
Connection:
|
34
|
+
- close
|
35
|
+
Date:
|
36
|
+
- Mon, 12 Dec 2022 19:28:55 GMT
|
37
|
+
X-Amzn-Requestid:
|
38
|
+
- 06d5ebef-068b-474f-abad-232e16817aae
|
39
|
+
X-Amz-Apigw-Id:
|
40
|
+
- dDEWsGv7IAMFzoA=
|
41
|
+
X-Amzn-Trace-Id:
|
42
|
+
- Root=1-639780f7-0d3f8f043091fff334ea3cc2
|
43
|
+
X-Cache:
|
44
|
+
- Miss from cloudfront
|
45
|
+
Via:
|
46
|
+
- 1.1 637ef0a7bc474e9a314fa064b65e8082.cloudfront.net (CloudFront)
|
47
|
+
X-Amz-Cf-Pop:
|
48
|
+
- SEA73-P2
|
49
|
+
X-Amz-Cf-Id:
|
50
|
+
- L5w_WkqnWc-td4yC3geJ6ewZ8meLyEjhfmDlG9GMz14c_5b8YrcvCw==
|
51
|
+
body:
|
52
|
+
encoding: UTF-8
|
53
|
+
string: '{"regions":[{"region_code":"BC","region":"British Columbia","country_code":"CA","country":"Canada"},{"region_code":"CA","region":"California","country_code":"US","country":"United
|
54
|
+
States"},{"region_code":"NY","region":"New York","country_code":"US","country":"United
|
55
|
+
States"}]}'
|
56
|
+
http_version:
|
57
|
+
recorded_at: Mon, 12 Dec 2022 19:28:55 GMT
|
58
|
+
- request:
|
59
|
+
method: post
|
60
|
+
uri: https://api.taxjar.com/v2/taxes
|
61
|
+
body:
|
62
|
+
encoding: UTF-8
|
63
|
+
string: '{"customer_id":"2","to_country":"US","to_zip":"11430","to_city":"Herndon","to_state":"NY","to_street":"A
|
64
|
+
Different Road","line_items":[{"id":2,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
65
|
+
- 232603"}],"shipping":"100.0"}'
|
66
|
+
headers:
|
67
|
+
User-Agent:
|
68
|
+
- 'TaxJar/Ruby (Darwin Noahs-MacBook-Pro.local 20.6.0 Darwin Kernel Version
|
69
|
+
20.6.0: Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64
|
70
|
+
x86_64; ruby 2.7.6-p219; OpenSSL 1.1.1n 15 Mar 2022) taxjar-ruby/3.0.4'
|
71
|
+
Authorization:
|
72
|
+
- Bearer <BEARER_TOKEN>
|
73
|
+
X-Api-Version:
|
74
|
+
- '2020-08-07'
|
75
|
+
Plugin:
|
76
|
+
- supergoodsolidustaxjar
|
77
|
+
Connection:
|
78
|
+
- close
|
79
|
+
Content-Type:
|
80
|
+
- application/json; charset=UTF-8
|
81
|
+
Host:
|
82
|
+
- api.taxjar.com
|
83
|
+
response:
|
84
|
+
status:
|
85
|
+
code: 200
|
86
|
+
message: OK
|
87
|
+
headers:
|
88
|
+
Content-Type:
|
89
|
+
- application/json; charset=utf-8
|
90
|
+
Content-Length:
|
91
|
+
- '1487'
|
92
|
+
Connection:
|
93
|
+
- close
|
94
|
+
Date:
|
95
|
+
- Mon, 12 Dec 2022 19:28:55 GMT
|
96
|
+
X-Amzn-Requestid:
|
97
|
+
- 7276c99c-8f0c-4197-8a31-8efa59253590
|
98
|
+
Access-Control-Allow-Origin:
|
99
|
+
- https://developers.taxjar.com
|
100
|
+
X-Amz-Apigw-Id:
|
101
|
+
- dDEWuE04IAMFxMw=
|
102
|
+
X-Amzn-Trace-Id:
|
103
|
+
- Root=1-639780f7-4eda74fa25f424a32507c1f4
|
104
|
+
X-Cache:
|
105
|
+
- Miss from cloudfront
|
106
|
+
Via:
|
107
|
+
- 1.1 27fe6f224e0cfa3f3a446471ee256e56.cloudfront.net (CloudFront)
|
108
|
+
X-Amz-Cf-Pop:
|
109
|
+
- SEA73-P2
|
110
|
+
X-Amz-Cf-Id:
|
111
|
+
- DopTz6Lw6gbf6BNUWHhYEIYpZD1N7wC__xhHKn8vfVzDL1daxL6VIg==
|
112
|
+
body:
|
113
|
+
encoding: UTF-8
|
114
|
+
string: '{"tax":{"amount_to_collect":9.76,"breakdown":{"city_tax_collectable":5.36,"city_tax_rate":0.04875,"city_taxable_amount":110.0,"combined_tax_rate":0.08875,"county_tax_collectable":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"line_items":[{"city_amount":0.49,"city_tax_rate":0.04875,"city_taxable_amount":10.0,"combined_tax_rate":0.08875,"county_amount":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"id":"2","special_district_amount":0.0,"special_district_taxable_amount":0.0,"special_tax_rate":0.0,"state_amount":0.4,"state_sales_tax_rate":0.04,"state_taxable_amount":10.0,"tax_collectable":0.89,"taxable_amount":10.0}],"shipping":{"city_amount":4.88,"city_tax_rate":0.04875,"city_taxable_amount":100.0,"combined_tax_rate":0.08875,"county_amount":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"special_district_amount":0.0,"special_tax_rate":0.0,"special_taxable_amount":0.0,"state_amount":4.0,"state_sales_tax_rate":0.04,"state_taxable_amount":100.0,"tax_collectable":8.88,"taxable_amount":100.0},"special_district_tax_collectable":0.0,"special_district_taxable_amount":0.0,"special_tax_rate":0.0,"state_tax_collectable":4.4,"state_tax_rate":0.04,"state_taxable_amount":110.0,"tax_collectable":9.76,"taxable_amount":110.0},"freight_taxable":true,"has_nexus":true,"jurisdictions":{"city":"NEW
|
115
|
+
YORK CITY","country":"US","county":"QUEENS","state":"NY"},"order_total_amount":110.0,"rate":0.08875,"shipping":100.0,"tax_source":"destination","taxable_amount":110.0}}'
|
116
|
+
http_version:
|
117
|
+
recorded_at: Mon, 12 Dec 2022 19:28:55 GMT
|
118
|
+
- request:
|
119
|
+
method: post
|
120
|
+
uri: https://api.taxjar.com/v2/taxes
|
121
|
+
body:
|
122
|
+
encoding: UTF-8
|
123
|
+
string: '{"customer_id":"2","to_country":"US","to_zip":"11430","to_city":"Herndon","to_state":"NY","to_street":"A
|
124
|
+
Different Road","line_items":[{"id":2,"quantity":1,"unit_price":"10.0","discount":0,"product_tax_code":"TaxCode
|
125
|
+
- 232603"}],"shipping":"100.0"}'
|
126
|
+
headers:
|
127
|
+
User-Agent:
|
128
|
+
- 'TaxJar/Ruby (Darwin Noahs-MacBook-Pro.local 20.6.0 Darwin Kernel Version
|
129
|
+
20.6.0: Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64
|
130
|
+
x86_64; ruby 2.7.6-p219; OpenSSL 1.1.1n 15 Mar 2022) taxjar-ruby/3.0.4'
|
131
|
+
Authorization:
|
132
|
+
- Bearer <BEARER_TOKEN>
|
133
|
+
X-Api-Version:
|
134
|
+
- '2020-08-07'
|
135
|
+
Plugin:
|
136
|
+
- supergoodsolidustaxjar
|
137
|
+
Connection:
|
138
|
+
- close
|
139
|
+
Content-Type:
|
140
|
+
- application/json; charset=UTF-8
|
141
|
+
Host:
|
142
|
+
- api.taxjar.com
|
143
|
+
response:
|
144
|
+
status:
|
145
|
+
code: 200
|
146
|
+
message: OK
|
147
|
+
headers:
|
148
|
+
Content-Type:
|
149
|
+
- application/json; charset=utf-8
|
150
|
+
Content-Length:
|
151
|
+
- '1487'
|
152
|
+
Connection:
|
153
|
+
- close
|
154
|
+
Date:
|
155
|
+
- Mon, 12 Dec 2022 19:28:55 GMT
|
156
|
+
X-Amzn-Requestid:
|
157
|
+
- dba4a74d-5a32-41f7-aaf4-e22b9da36569
|
158
|
+
Access-Control-Allow-Origin:
|
159
|
+
- https://developers.taxjar.com
|
160
|
+
X-Amz-Apigw-Id:
|
161
|
+
- dDEWxEknIAMFupg=
|
162
|
+
X-Amzn-Trace-Id:
|
163
|
+
- Root=1-639780f7-6904af885563ff2578fe7294
|
164
|
+
X-Cache:
|
165
|
+
- Miss from cloudfront
|
166
|
+
Via:
|
167
|
+
- 1.1 34c44cb7892e57a3b6c51812bcf68ee4.cloudfront.net (CloudFront)
|
168
|
+
X-Amz-Cf-Pop:
|
169
|
+
- SEA73-P2
|
170
|
+
X-Amz-Cf-Id:
|
171
|
+
- DIbncrEPimCzNdJOp34kt1uouNQhzd2vWabg19ooFStag6MrLJ9hzA==
|
172
|
+
body:
|
173
|
+
encoding: UTF-8
|
174
|
+
string: '{"tax":{"amount_to_collect":9.76,"breakdown":{"city_tax_collectable":5.36,"city_tax_rate":0.04875,"city_taxable_amount":110.0,"combined_tax_rate":0.08875,"county_tax_collectable":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"line_items":[{"city_amount":0.49,"city_tax_rate":0.04875,"city_taxable_amount":10.0,"combined_tax_rate":0.08875,"county_amount":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"id":"2","special_district_amount":0.0,"special_district_taxable_amount":0.0,"special_tax_rate":0.0,"state_amount":0.4,"state_sales_tax_rate":0.04,"state_taxable_amount":10.0,"tax_collectable":0.89,"taxable_amount":10.0}],"shipping":{"city_amount":4.88,"city_tax_rate":0.04875,"city_taxable_amount":100.0,"combined_tax_rate":0.08875,"county_amount":0.0,"county_tax_rate":0.0,"county_taxable_amount":0.0,"special_district_amount":0.0,"special_tax_rate":0.0,"special_taxable_amount":0.0,"state_amount":4.0,"state_sales_tax_rate":0.04,"state_taxable_amount":100.0,"tax_collectable":8.88,"taxable_amount":100.0},"special_district_tax_collectable":0.0,"special_district_taxable_amount":0.0,"special_tax_rate":0.0,"state_tax_collectable":4.4,"state_tax_rate":0.04,"state_taxable_amount":110.0,"tax_collectable":9.76,"taxable_amount":110.0},"freight_taxable":true,"has_nexus":true,"jurisdictions":{"city":"NEW
|
175
|
+
YORK CITY","country":"US","county":"QUEENS","state":"NY"},"order_total_amount":110.0,"rate":0.08875,"shipping":100.0,"tax_source":"destination","taxable_amount":110.0}}'
|
176
|
+
http_version:
|
177
|
+
recorded_at: Mon, 12 Dec 2022 19:28:55 GMT
|
178
|
+
- request:
|
179
|
+
method: post
|
180
|
+
uri: https://api.taxjar.com/v2/transactions/orders
|
181
|
+
body:
|
182
|
+
encoding: UTF-8
|
183
|
+
string: '{"customer_id":"2","to_country":"US","to_zip":"11430","to_city":"Herndon","to_state":"NY","to_street":"A
|
184
|
+
Different Road","line_items":[{"id":2,"quantity":1,"product_identifier":"SKU-2","description":"Product
|
185
|
+
#2 - 9536 - Master","product_tax_code":"TaxCode - 232603","unit_price":"10.0","discount":0,"sales_tax":"0.89"}],"transaction_id":"R938957979","transaction_date":"2022-12-12T19:28:55Z","amount":"110.0","shipping":"100.0","sales_tax":"9.77"}'
|
186
|
+
headers:
|
187
|
+
User-Agent:
|
188
|
+
- 'TaxJar/Ruby (Darwin Noahs-MacBook-Pro.local 20.6.0 Darwin Kernel Version
|
189
|
+
20.6.0: Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64
|
190
|
+
x86_64; ruby 2.7.6-p219; OpenSSL 1.1.1n 15 Mar 2022) taxjar-ruby/3.0.4'
|
191
|
+
Authorization:
|
192
|
+
- Bearer <BEARER_TOKEN>
|
193
|
+
X-Api-Version:
|
194
|
+
- '2020-08-07'
|
195
|
+
Plugin:
|
196
|
+
- supergoodsolidustaxjar
|
197
|
+
Connection:
|
198
|
+
- close
|
199
|
+
Content-Type:
|
200
|
+
- application/json; charset=UTF-8
|
201
|
+
Host:
|
202
|
+
- api.taxjar.com
|
203
|
+
response:
|
204
|
+
status:
|
205
|
+
code: 201
|
206
|
+
message: Created
|
207
|
+
headers:
|
208
|
+
Content-Type:
|
209
|
+
- application/json; charset=utf-8
|
210
|
+
Content-Length:
|
211
|
+
- '643'
|
212
|
+
Connection:
|
213
|
+
- close
|
214
|
+
Date:
|
215
|
+
- Mon, 12 Dec 2022 19:28:56 GMT
|
216
|
+
X-Amzn-Requestid:
|
217
|
+
- 213a455c-d877-445b-9a4d-396e7ef6689f
|
218
|
+
X-Amzn-Remapped-Content-Length:
|
219
|
+
- '643'
|
220
|
+
X-Amzn-Remapped-Connection:
|
221
|
+
- keep-alive
|
222
|
+
X-Request-Id:
|
223
|
+
- FzAiclh6cbaVtCDHQC0D
|
224
|
+
X-Api-Version:
|
225
|
+
- '2020-08-07'
|
226
|
+
X-Amz-Apigw-Id:
|
227
|
+
- dDEW0Hg5IAMFnLg=
|
228
|
+
Cache-Control:
|
229
|
+
- max-age=0, private, must-revalidate
|
230
|
+
X-Amzn-Remapped-Server:
|
231
|
+
- Cowboy
|
232
|
+
X-Amzn-Remapped-Date:
|
233
|
+
- Mon, 12 Dec 2022 19:28:56 GMT
|
234
|
+
X-Cache:
|
235
|
+
- Miss from cloudfront
|
236
|
+
Via:
|
237
|
+
- 1.1 33d72803ad26b392c1b578a2b1276580.cloudfront.net (CloudFront)
|
238
|
+
X-Amz-Cf-Pop:
|
239
|
+
- SEA73-P2
|
240
|
+
X-Amz-Cf-Id:
|
241
|
+
- jx7hCP4oyumMawA8FxSB2_THTDzFaWriaUNVLy-PrGPx_zT14IN1xA==
|
242
|
+
body:
|
243
|
+
encoding: UTF-8
|
244
|
+
string: '{"order":{"user_id":225397,"transaction_reference_id":null,"transaction_id":"R938957979","transaction_date":"2022-12-12T19:28:55.000Z","to_zip":"11430","to_street":"A
|
245
|
+
Different Road","to_state":"NY","to_country":"US","to_city":"HERNDON","shipping":"100.0","sales_tax":"9.77","provider":"api","line_items":[{"unit_price":"10.0","sales_tax":"0.89","quantity":1,"product_tax_code":"TaxCode
|
246
|
+
- 232603","product_identifier":"SKU-2","id":0,"discount":"0.0","description":"Product
|
247
|
+
#2 - 9536 - Master"}],"from_zip":null,"from_street":null,"from_state":null,"from_country":"US","from_city":null,"exemption_type":null,"customer_id":"2","amount":"110.0"}}'
|
248
|
+
http_version:
|
249
|
+
recorded_at: Mon, 12 Dec 2022 19:28:56 GMT
|
250
|
+
recorded_with: VCR 4.0.0
|