avatax 17.7.3 → 17.8.1
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.
- checksums.yaml +4 -4
- data/lib/avatax/client/accounts.rb +5 -5
- data/lib/avatax/client/batches.rb +5 -5
- data/lib/avatax/client/certexpressinvites.rb +77 -0
- data/lib/avatax/client/certificates.rb +291 -0
- data/lib/avatax/client/companies.rb +21 -21
- data/lib/avatax/client/contacts.rb +5 -5
- data/lib/avatax/client/customers.rb +195 -0
- data/lib/avatax/client/definitions.rb +71 -2
- data/lib/avatax/client/filingcalendars.rb +8 -8
- data/lib/avatax/client/filings.rb +12 -12
- data/lib/avatax/client/items.rb +5 -5
- data/lib/avatax/client/jurisdictionoverrides.rb +5 -5
- data/lib/avatax/client/locations.rb +6 -6
- data/lib/avatax/client/nexus.rb +5 -5
- data/lib/avatax/client/notices.rb +15 -15
- data/lib/avatax/client/onboarding.rb +10 -0
- data/lib/avatax/client/registrar.rb +8 -8
- data/lib/avatax/client/reports.rb +19 -0
- data/lib/avatax/client/settings.rb +5 -5
- data/lib/avatax/client/taxcodes.rb +5 -5
- data/lib/avatax/client/taxrules.rb +5 -5
- data/lib/avatax/client/transactions.rb +67 -49
- data/lib/avatax/client/upcs.rb +5 -5
- data/lib/avatax/client/users.rb +3 -3
- data/lib/avatax/version.rb +1 -1
- metadata +6 -2
@@ -53,8 +53,8 @@ module AvaTax
|
|
53
53
|
# Create one or more new company objects.
|
54
54
|
# A 'company' represents a single corporation or individual that is registered to handle transactional taxes.
|
55
55
|
# You may attach nested data objects such as contacts, locations, and nexus with this CREATE call, and those objects will be created with the company.
|
56
|
-
# @param model [
|
57
|
-
# @return [
|
56
|
+
# @param model [CompanyModel[]] Either a single company object or an array of companies to create
|
57
|
+
# @return [CompanyModel[]]
|
58
58
|
def create_companies(model)
|
59
59
|
path = "/api/v2/companies"
|
60
60
|
post(path, model)
|
@@ -86,7 +86,7 @@ module AvaTax
|
|
86
86
|
#
|
87
87
|
# Deleting a company will delete all child companies, and all users attached to this company.
|
88
88
|
# @param id [Integer] The ID of the company you wish to delete.
|
89
|
-
# @return [
|
89
|
+
# @return [ErrorDetail[]]
|
90
90
|
def delete_company(id)
|
91
91
|
path = "/api/v2/companies/#{id}"
|
92
92
|
delete(path)
|
@@ -107,9 +107,8 @@ module AvaTax
|
|
107
107
|
# * TaxCodes
|
108
108
|
# * TaxRules
|
109
109
|
# * UPC
|
110
|
-
# * ECMS
|
111
110
|
# @param id [Integer] The ID of the company to retrieve.
|
112
|
-
# @param include [String] A comma separated list of
|
111
|
+
# @param include [String] OPTIONAL: A comma separated list of special fetch options. * Child objects - Specify one or more of the following to retrieve objects related to each company: "Contacts", "FilingCalendars", "Items", "Locations", "Nexus", "TaxCodes", or "TaxRules". * Deleted objects - Specify "FetchDeleted" to retrieve information about previously deleted objects.
|
113
112
|
# @return [Object]
|
114
113
|
def get_company(id, options={})
|
115
114
|
path = "/api/v2/companies/#{id}"
|
@@ -117,16 +116,6 @@ module AvaTax
|
|
117
116
|
end
|
118
117
|
|
119
118
|
|
120
|
-
#
|
121
|
-
#
|
122
|
-
#
|
123
|
-
# @return [FetchResult]
|
124
|
-
def get_company()
|
125
|
-
path = "/api/v2/companies/mrs"
|
126
|
-
get(path)
|
127
|
-
end
|
128
|
-
|
129
|
-
|
130
119
|
# Get configuration settings for this company
|
131
120
|
#
|
132
121
|
# Retrieve a list of all configuration settings tied to this company.
|
@@ -142,7 +131,7 @@ module AvaTax
|
|
142
131
|
# Avalara-based account settings for `AvaCertServiceConfig` affect your account's exemption certificate
|
143
132
|
# processing, and should only be changed with care.
|
144
133
|
# @param id [Integer]
|
145
|
-
# @return [
|
134
|
+
# @return [CompanyConfigurationModel[]]
|
146
135
|
def get_company_configuration(id)
|
147
136
|
path = "/api/v2/companies/#{id}/configuration"
|
148
137
|
get(path)
|
@@ -179,13 +168,25 @@ module AvaTax
|
|
179
168
|
# Returns a list of funding setup requests and their current status.
|
180
169
|
# Each object in the result is a request that was made to setup or adjust funding configuration for this company.
|
181
170
|
# @param id [Integer] The unique identifier of the company
|
182
|
-
# @return [
|
171
|
+
# @return [FundingStatusModel[]]
|
183
172
|
def list_funding_requests_by_company(id)
|
184
173
|
path = "/api/v2/companies/#{id}/funding"
|
185
174
|
get(path)
|
186
175
|
end
|
187
176
|
|
188
177
|
|
178
|
+
# Retrieve a list of MRS Companies with account
|
179
|
+
#
|
180
|
+
# This API is available by invitation only.
|
181
|
+
#
|
182
|
+
# Get a list of companies with an active MRS service.
|
183
|
+
# @return [FetchResult]
|
184
|
+
def list_mrs_companies()
|
185
|
+
path = "/api/v2/companies/mrs"
|
186
|
+
get(path)
|
187
|
+
end
|
188
|
+
|
189
|
+
|
189
190
|
# Retrieve all companies
|
190
191
|
#
|
191
192
|
# Get multiple company objects.
|
@@ -202,8 +203,7 @@ module AvaTax
|
|
202
203
|
# * TaxCodes
|
203
204
|
# * TaxRules
|
204
205
|
# * UPC
|
205
|
-
#
|
206
|
-
# @param include [String] A comma separated list of child objects to return underneath the primary object.
|
206
|
+
# @param include [String] A comma separated list of objects to fetch underneath this company. Any object with a URL path underneath this company can be fetched by specifying its name.
|
207
207
|
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
208
208
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
209
209
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
@@ -230,8 +230,8 @@ module AvaTax
|
|
230
230
|
# Avalara-based account settings for `AvaCertServiceConfig` affect your account's exemption certificate
|
231
231
|
# processing, and should only be changed with care.
|
232
232
|
# @param id [Integer]
|
233
|
-
# @param model [
|
234
|
-
# @return [
|
233
|
+
# @param model [CompanyConfigurationModel[]]
|
234
|
+
# @return [CompanyConfigurationModel[]]
|
235
235
|
def set_company_configuration(id, model)
|
236
236
|
path = "/api/v2/companies/#{id}/configuration"
|
237
237
|
post(path, model)
|
@@ -9,8 +9,8 @@ module AvaTax
|
|
9
9
|
# A 'contact' is a person associated with a company who is designated to handle certain responsibilities of
|
10
10
|
# a tax collecting and filing entity.
|
11
11
|
# @param companyId [Integer] The ID of the company that owns this contact.
|
12
|
-
# @param model [
|
13
|
-
# @return [
|
12
|
+
# @param model [ContactModel[]] The contacts you wish to create.
|
13
|
+
# @return [ContactModel[]]
|
14
14
|
def create_contacts(companyId, model)
|
15
15
|
path = "/api/v2/companies/#{companyId}/contacts"
|
16
16
|
post(path, model)
|
@@ -22,7 +22,7 @@ module AvaTax
|
|
22
22
|
# Mark the existing contact object at this URL as deleted.
|
23
23
|
# @param companyId [Integer] The ID of the company that owns this contact.
|
24
24
|
# @param id [Integer] The ID of the contact you wish to delete.
|
25
|
-
# @return [
|
25
|
+
# @return [ErrorDetail[]]
|
26
26
|
def delete_contact(companyId, id)
|
27
27
|
path = "/api/v2/companies/#{companyId}/contacts/#{id}"
|
28
28
|
delete(path)
|
@@ -51,7 +51,7 @@ module AvaTax
|
|
51
51
|
# Paginate your results using the `$top`, `$skip`, and `$orderby` parameters.
|
52
52
|
# @param companyId [Integer] The ID of the company that owns these contacts
|
53
53
|
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
54
|
-
# @param include [String] A comma separated list of
|
54
|
+
# @param include [String] A comma separated list of additional data to retrieve.
|
55
55
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
56
56
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
57
57
|
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
@@ -71,7 +71,7 @@ module AvaTax
|
|
71
71
|
# Search for specific objects using the criteria in the `$filter` parameter; full documentation is available on [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
72
72
|
# Paginate your results using the `$top`, `$skip`, and `$orderby` parameters.
|
73
73
|
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
74
|
-
# @param include [String] A comma separated list of
|
74
|
+
# @param include [String] A comma separated list of additional data to retrieve.
|
75
75
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
76
76
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
77
77
|
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
@@ -0,0 +1,195 @@
|
|
1
|
+
module AvaTax
|
2
|
+
class Client
|
3
|
+
module Customers
|
4
|
+
|
5
|
+
|
6
|
+
# Create customers for this company
|
7
|
+
#
|
8
|
+
# Create one or more customers for this company.
|
9
|
+
#
|
10
|
+
# A customer object defines information about a person or business that purchases products from your
|
11
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
12
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
13
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
14
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
15
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
16
|
+
# @param model [CustomerModel[]] The list of customer objects to be created
|
17
|
+
# @return [CustomerModel[]]
|
18
|
+
def create_customers(companyId, model)
|
19
|
+
path = "/api/v2/companies/#{companyId}/customers"
|
20
|
+
post(path, model)
|
21
|
+
end
|
22
|
+
|
23
|
+
|
24
|
+
# Delete a customer record
|
25
|
+
#
|
26
|
+
# Deletes the customer object referenced by this URL.
|
27
|
+
#
|
28
|
+
# A customer object defines information about a person or business that purchases products from your
|
29
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
30
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
31
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
32
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
33
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
34
|
+
# @param customerCode [String] The unique code representing this customer
|
35
|
+
# @return [Object]
|
36
|
+
def delete_customer(companyId, customerCode)
|
37
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}"
|
38
|
+
delete(path)
|
39
|
+
end
|
40
|
+
|
41
|
+
|
42
|
+
# Retrieve a single customer
|
43
|
+
#
|
44
|
+
# Retrieve the customer identified by this URL.
|
45
|
+
#
|
46
|
+
# A customer object defines information about a person or business that purchases products from your
|
47
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
48
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
49
|
+
# identify any certificates linked to this customer object. If any certificate applies to the transaction,
|
50
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
51
|
+
#
|
52
|
+
# You can use the `$include` parameter to fetch the following additional objects for expansion:
|
53
|
+
#
|
54
|
+
# * Certificates - Fetch a list of certificates linked to this customer.
|
55
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
56
|
+
# @param customerCode [String] The unique code representing this customer
|
57
|
+
# @param include [String] Specify optional additional objects to include in this fetch request
|
58
|
+
# @return [Object]
|
59
|
+
def get_customer(companyId, customerCode, options={})
|
60
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}"
|
61
|
+
get(path, options)
|
62
|
+
end
|
63
|
+
|
64
|
+
|
65
|
+
# Link certificates to a customer
|
66
|
+
#
|
67
|
+
# Link one or more certificates to a customer.
|
68
|
+
#
|
69
|
+
# A customer object defines information about a person or business that purchases products from your
|
70
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
71
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
72
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
73
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
74
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
75
|
+
# @param customerCode [String] The unique code representing this customer
|
76
|
+
# @param model [Object] The list of certificates to link to this customer
|
77
|
+
# @return [FetchResult]
|
78
|
+
def link_certificates_to_customer(companyId, customerCode, model)
|
79
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certificates/link"
|
80
|
+
post(path, model)
|
81
|
+
end
|
82
|
+
|
83
|
+
|
84
|
+
# List certificates linked to a customer
|
85
|
+
#
|
86
|
+
# List all certificates linked to a customer.
|
87
|
+
#
|
88
|
+
# A customer object defines information about a person or business that purchases products from your
|
89
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
90
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
91
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
92
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
93
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
94
|
+
# @param customerCode [String] The unique code representing this customer
|
95
|
+
# @param include [String] OPTIONAL: A comma separated list of special fetch options. You can specify one or more of the following: * Customers - Retrieves the list of customers linked to the certificate. * PoNumbers - Retrieves all PO numbers tied to the certificate. * Attributes - Retrieves all attributes applied to the certificate.
|
96
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
97
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
98
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
99
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
100
|
+
# @return [FetchResult]
|
101
|
+
def list_certificates_for_customer(companyId, customerCode, options={})
|
102
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certificates"
|
103
|
+
get(path, options)
|
104
|
+
end
|
105
|
+
|
106
|
+
|
107
|
+
# List active certificates for a location
|
108
|
+
#
|
109
|
+
# List valid certificates linked to a customer in a particular country and region.
|
110
|
+
#
|
111
|
+
# This API is intended to help identify whether a customer has already provided a certificate that
|
112
|
+
# applies to a particular country and region. This API is intended to help you remind a customer
|
113
|
+
# when they have or have not provided copies of their exemption certificates to you during the sales
|
114
|
+
# order process.
|
115
|
+
#
|
116
|
+
# If a customer does not have a certificate on file and they wish to provide one, you should send the customer
|
117
|
+
# a CertExpress invitation link so that the customer can upload proof of their exemption certificate. Please
|
118
|
+
# see the `CreateCertExpressInvitation` API to create an invitation link for this customer.
|
119
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
120
|
+
# @param customerCode [String] The unique code representing this customer
|
121
|
+
# @param country [String] Search for certificates matching this country. Uses the ISO 3166 two character country code.
|
122
|
+
# @param region [String] Search for certificates matching this region. Uses the ISO 3166 two or three character state, region, or province code.
|
123
|
+
# @return [Object]
|
124
|
+
def list_valid_certificates_for_customer(companyId, customerCode, country, region)
|
125
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certificates/#{country}/#{region}"
|
126
|
+
get(path)
|
127
|
+
end
|
128
|
+
|
129
|
+
|
130
|
+
# List all customers for this company
|
131
|
+
#
|
132
|
+
# List all customers recorded by this company matching the specified criteria.
|
133
|
+
#
|
134
|
+
# A customer object defines information about a person or business that purchases products from your
|
135
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
136
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
137
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
138
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
139
|
+
#
|
140
|
+
# You can use the `$include` parameter to fetch the following additional objects for expansion:
|
141
|
+
#
|
142
|
+
# * Certificates - Fetch a list of certificates linked to this customer.
|
143
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
144
|
+
# @param include [String] OPTIONAL - You can specify the value `certificates` to fetch information about certificates linked to the customer.
|
145
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
146
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
147
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
148
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
149
|
+
# @return [FetchResult]
|
150
|
+
def query_customers(companyId, options={})
|
151
|
+
path = "/api/v2/companies/#{companyId}/customers"
|
152
|
+
get(path, options)
|
153
|
+
end
|
154
|
+
|
155
|
+
|
156
|
+
# Unlink certificates from a customer
|
157
|
+
#
|
158
|
+
# Remove one or more certificates to a customer.
|
159
|
+
#
|
160
|
+
# A customer object defines information about a person or business that purchases products from your
|
161
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
162
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
163
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
164
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
165
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
166
|
+
# @param customerCode [String] The unique code representing this customer
|
167
|
+
# @param model [Object] The list of certificates to link to this customer
|
168
|
+
# @return [FetchResult]
|
169
|
+
def unlink_certificates_from_customer(companyId, customerCode, model)
|
170
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certificates/unlink"
|
171
|
+
post(path, model)
|
172
|
+
end
|
173
|
+
|
174
|
+
|
175
|
+
# Update a single customer
|
176
|
+
#
|
177
|
+
# Replace the customer object at this URL with a new record.
|
178
|
+
#
|
179
|
+
# A customer object defines information about a person or business that purchases products from your
|
180
|
+
# company. When you create a tax transaction in AvaTax, you can use the `customerCode` from this
|
181
|
+
# record in your `CreateTransaction` API call. AvaTax will search for this `customerCode` value and
|
182
|
+
# identify any certificates linked to this `customer` object. If any certificate applies to the transaction,
|
183
|
+
# AvaTax will record the appropriate elements of the transaction as exempt and link it to the `certificate`.
|
184
|
+
# @param companyId [Integer] The unique ID number of the company that recorded this customer
|
185
|
+
# @param customerCode [String] The unique code representing this customer
|
186
|
+
# @param model [Object] The new customer model that will replace the existing record at this URL
|
187
|
+
# @return [Object]
|
188
|
+
def update_customer(companyId, customerCode, model)
|
189
|
+
path = "/api/v2/companies/#{companyId}/customers/#{customerCode}"
|
190
|
+
put(path, model)
|
191
|
+
end
|
192
|
+
|
193
|
+
end
|
194
|
+
end
|
195
|
+
end
|
@@ -34,11 +34,62 @@ module AvaTax
|
|
34
34
|
end
|
35
35
|
|
36
36
|
|
37
|
+
# List certificate attributes used by a company
|
38
|
+
#
|
39
|
+
# List the certificate attributes defined by a company.
|
40
|
+
#
|
41
|
+
# A certificate may have multiple attributes that control its behavior. You may apply or remove attributes to a
|
42
|
+
# certificate at any time.
|
43
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
44
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
45
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
46
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
47
|
+
# @return [FetchResult]
|
48
|
+
def list_certificate_attributes(options={})
|
49
|
+
path = "/api/v2/definitions/certificateattributes"
|
50
|
+
get(path, options)
|
51
|
+
end
|
52
|
+
|
53
|
+
|
54
|
+
# List certificate attributes used by a company
|
55
|
+
#
|
56
|
+
# List the certificate exempt reasons defined by a company.
|
57
|
+
#
|
58
|
+
# An exemption reason defines why a certificate allows a customer to be exempt
|
59
|
+
# for purposes of tax calculation.
|
60
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
61
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
62
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
63
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
64
|
+
# @return [FetchResult]
|
65
|
+
def list_certificate_exempt_reasons(options={})
|
66
|
+
path = "/api/v2/definitions/certificateexemptreasons"
|
67
|
+
get(path, options)
|
68
|
+
end
|
69
|
+
|
70
|
+
|
71
|
+
# List certificate exposure zones used by a company
|
72
|
+
#
|
73
|
+
# List the certificate exposure zones defined by a company.
|
74
|
+
#
|
75
|
+
# An exposure zone is a location where a certificate can be valid. Exposure zones may indicate a taxing
|
76
|
+
# authority or other legal entity to which a certificate may apply.
|
77
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
78
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
79
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
80
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
81
|
+
# @return [FetchResult]
|
82
|
+
def list_certificate_exposure_zones(options={})
|
83
|
+
path = "/api/v2/definitions/certificateexposurezones"
|
84
|
+
get(path, options)
|
85
|
+
end
|
86
|
+
|
87
|
+
|
37
88
|
# Retrieve the full list of communications transactiontypes
|
38
89
|
#
|
39
90
|
# Returns full list of communications transaction types which
|
40
91
|
# are accepted in communication tax calculation requests.
|
41
|
-
# @param id [Integer]
|
92
|
+
# @param id [Integer] The transaction type ID to examine
|
42
93
|
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
43
94
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
44
95
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
@@ -96,6 +147,24 @@ module AvaTax
|
|
96
147
|
end
|
97
148
|
|
98
149
|
|
150
|
+
# List certificate exposure zones used by a company
|
151
|
+
#
|
152
|
+
# List available cover letters that can be used when sending invitation to use CertExpress to upload certificates.
|
153
|
+
#
|
154
|
+
# The CoverLetter model represents a message sent along with an invitation to use CertExpress to
|
155
|
+
# upload certificates. An invitation allows customers to use CertExpress to upload their exemption
|
156
|
+
# certificates directly; this cover letter explains why the invitation was sent.
|
157
|
+
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
158
|
+
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
159
|
+
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
160
|
+
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
161
|
+
# @return [FetchResult]
|
162
|
+
def list_cover_letters(options={})
|
163
|
+
path = "/api/v2/definitions/coverletters"
|
164
|
+
get(path, options)
|
165
|
+
end
|
166
|
+
|
167
|
+
|
99
168
|
# Retrieve the full list of Avalara-supported entity use codes
|
100
169
|
#
|
101
170
|
# Returns the full list of Avalara-supported entity use codes.
|
@@ -500,7 +569,7 @@ module AvaTax
|
|
500
569
|
#
|
501
570
|
# Returns the full list of Avalara-supported rate type file types
|
502
571
|
# This API is intended to be useful to identify all the different rate types.
|
503
|
-
# @param country [String]
|
572
|
+
# @param country [String] The country to examine for rate types
|
504
573
|
# @param filter [String] A filter statement to identify specific records to retrieve. For more information on filtering, see [Filtering in REST](http://developer.avalara.com/avatax/filtering-in-rest/) .
|
505
574
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
506
575
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
@@ -40,7 +40,7 @@ module AvaTax
|
|
40
40
|
# are reviewed and validated by Avalara Compliance before being implemented.
|
41
41
|
# @param companyId [Integer] The unique ID of the company that owns the filing calendar object
|
42
42
|
# @param id [Integer] The unique ID number of the filing calendar to cancel
|
43
|
-
# @param model [
|
43
|
+
# @param model [FilingRequestModel[]] The cancellation request for this filing calendar
|
44
44
|
# @return [Object]
|
45
45
|
def cancel_filing_requests(companyId, id, model)
|
46
46
|
path = "/api/v2/companies/#{companyId}/filingcalendars/#{id}/cancel/request"
|
@@ -54,7 +54,7 @@ module AvaTax
|
|
54
54
|
# A "filing request" represents a request to change an existing filing calendar. Filing requests
|
55
55
|
# are reviewed and validated by Avalara Compliance before being implemented.
|
56
56
|
# @param companyId [Integer] The unique ID of the company that will add the new filing calendar
|
57
|
-
# @param model [
|
57
|
+
# @param model [FilingRequestModel[]] Information about the proposed new filing calendar
|
58
58
|
# @return [Object]
|
59
59
|
def create_filing_requests(companyId, model)
|
60
60
|
path = "/api/v2/companies/#{companyId}/filingcalendars/add/request"
|
@@ -67,7 +67,7 @@ module AvaTax
|
|
67
67
|
# This API is available by invitation only.
|
68
68
|
# @param companyId [Integer] The unique ID of the company that owns the filing calendar object
|
69
69
|
# @param formCode [String] The unique code of the form
|
70
|
-
# @return [
|
70
|
+
# @return [CycleAddOptionModel[]]
|
71
71
|
def cycle_safe_add(companyId, options={})
|
72
72
|
path = "/api/v2/companies/#{companyId}/filingcalendars/add/options"
|
73
73
|
get(path, options)
|
@@ -79,7 +79,7 @@ module AvaTax
|
|
79
79
|
# This API is available by invitation only.
|
80
80
|
# @param companyId [Integer] The unique ID of the company that owns the filing calendar object
|
81
81
|
# @param id [Integer] The unique ID of the filing calendar object
|
82
|
-
# @param model [
|
82
|
+
# @param model [FilingCalendarEditModel[]] A list of filing calendar edits to be made
|
83
83
|
# @return [Object]
|
84
84
|
def cycle_safe_edit(companyId, id, model)
|
85
85
|
path = "/api/v2/companies/#{companyId}/filingcalendars/#{id}/edit/options"
|
@@ -107,7 +107,7 @@ module AvaTax
|
|
107
107
|
# Returns customers often receive support and assistance from the Compliance Notices team in handling notices received by taxing authorities.
|
108
108
|
# @param companyId [Integer] The ID of the company that owns this filing calendar.
|
109
109
|
# @param id [Integer] The ID of the filing calendar you wish to delete.
|
110
|
-
# @return [
|
110
|
+
# @return [ErrorDetail[]]
|
111
111
|
def delete_filing_calendar(companyId, id)
|
112
112
|
path = "/api/v2/companies/#{companyId}/filingcalendars/#{id}"
|
113
113
|
delete(path)
|
@@ -208,8 +208,8 @@ module AvaTax
|
|
208
208
|
# @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
|
209
209
|
# @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
|
210
210
|
# @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
|
211
|
-
# @param returnCountry [String]
|
212
|
-
# @param returnRegion [String]
|
211
|
+
# @param returnCountry [String] If specified, fetches only filing calendars that apply to tax filings in this specific country. Uses ISO 3166 country codes.
|
212
|
+
# @param returnRegion [String] If specified, fetches only filing calendars that apply to tax filings in this specific region. Uses ISO 3166 region codes.
|
213
213
|
# @return [FetchResult]
|
214
214
|
def query_filing_calendars(options={})
|
215
215
|
path = "/api/v2/filingcalendars"
|
@@ -247,7 +247,7 @@ module AvaTax
|
|
247
247
|
# to modify the value of a filing calendar using this API.
|
248
248
|
# @param companyId [Integer] The unique ID of the company that owns the filing calendar object
|
249
249
|
# @param id [Integer] The unique ID number of the filing calendar to edit
|
250
|
-
# @param model [
|
250
|
+
# @param model [FilingRequestModel[]] A list of filing calendar edits to be made
|
251
251
|
# @return [Object]
|
252
252
|
def request_filing_calendar_update(companyId, id, model)
|
253
253
|
path = "/api/v2/companies/#{companyId}/filingcalendars/#{id}/edit/request"
|