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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f91622695347c4040a71f175e5b217c4a90049a2
4
- data.tar.gz: 4fdcbb988386306d7d8d1e4871fcc7b8a8cfdb01
3
+ metadata.gz: 9ff123feb21d5c4095101de3bd2374dd451eb3dd
4
+ data.tar.gz: 8d30daf442c6dc18fa66195e305c128d83cdc6a2
5
5
  SHA512:
6
- metadata.gz: bd4cc8cefb18f556b6dbe8bf29375bed4da326c282bbfc74c4763b810b82a807836a9fa3daed3c445c1d18977f04f3cf91aae4c217a78f3d7705576ee86e43c3
7
- data.tar.gz: fba6bea77a3fc36619eb1efe3accd0561137c0ff8655493e4f79f3a8c397c3b7b2e5467a0bd951dba7af104385c71a0bedc56e41f68086a074d7e148335d2528
6
+ metadata.gz: 36a96bbe9fa0cddb55147de9f7be3a14cf911537e6ae6327dafe10451b0df9ed9aee082d7246951cbcb645909aa705b918f46f88bc868e515fc6b16c04e06a54
7
+ data.tar.gz: 6879d45e224836daddd1e4869bc2c6871e00e3926d924d8c84dfae254035687edaa4a7b959238a09bf0dd0d42df9f346c891d0785b97b8dcd554dbbc736a8dd6
@@ -27,7 +27,7 @@ module AvaTax
27
27
  # If you have not read or accepted the terms and conditions, this API call will return the
28
28
  # unchanged account model.
29
29
  # @param id [Integer] The ID of the account to activate
30
- # @param include [String] A comma separated list of child objects to return underneath the primary object.
30
+ # @param include [String] Elements to include when fetching the account
31
31
  # @param model [Object] The activation request
32
32
  # @return [Object]
33
33
  def activate_account(id, model, options={})
@@ -44,7 +44,7 @@ module AvaTax
44
44
  # * Subscriptions
45
45
  # * Users
46
46
  # @param id [Integer] The ID of the account to retrieve
47
- # @param include [String] A comma separated list of child objects to return underneath the primary object.
47
+ # @param include [String] A comma separated list of special fetch options
48
48
  # @return [Object]
49
49
  def get_account(id, options={})
50
50
  path = "/api/v2/accounts/#{id}"
@@ -67,7 +67,7 @@ module AvaTax
67
67
  # Avalara-based account settings for `TaxServiceConfig` and `AddressServiceConfig` affect your account's
68
68
  # tax calculation and address resolution, and should only be changed with care.
69
69
  # @param id [Integer]
70
- # @return [object[]]
70
+ # @return [AccountConfigurationModel[]]
71
71
  def get_account_configuration(id)
72
72
  path = "/api/v2/accounts/#{id}/configuration"
73
73
  get(path)
@@ -89,8 +89,8 @@ module AvaTax
89
89
  # Avalara-based account settings for `TaxServiceConfig` and `AddressServiceConfig` affect your account's
90
90
  # tax calculation and address resolution, and should only be changed with care.
91
91
  # @param id [Integer]
92
- # @param model [object[]]
93
- # @return [object[]]
92
+ # @param model [AccountConfigurationModel[]]
93
+ # @return [AccountConfigurationModel[]]
94
94
  def set_account_configuration(id, model)
95
95
  path = "/api/v2/accounts/#{id}/configuration"
96
96
  post(path, model)
@@ -10,8 +10,8 @@ module AvaTax
10
10
  # You may fetch a batch to check on its status and retrieve the results of the batch operation.
11
11
  # Each batch object may have one or more file objects (currently only one file is supported).
12
12
  # @param companyId [Integer] The ID of the company that owns this batch.
13
- # @param model [object[]] The batch you wish to create.
14
- # @return [object[]]
13
+ # @param model [BatchModel[]] The batch you wish to create.
14
+ # @return [BatchModel[]]
15
15
  def create_batches(companyId, model)
16
16
  path = "/api/v2/companies/#{companyId}/batches"
17
17
  post(path, model)
@@ -23,7 +23,7 @@ module AvaTax
23
23
  #
24
24
  # @param companyId [Integer] The ID of the company that owns this batch.
25
25
  # @param id [Integer] The ID of the batch you wish to delete.
26
- # @return [object[]]
26
+ # @return [ErrorDetail[]]
27
27
  def delete_batch(companyId, id)
28
28
  path = "/api/v2/companies/#{companyId}/batches/#{id}"
29
29
  delete(path)
@@ -68,7 +68,7 @@ module AvaTax
68
68
  # Paginate your results using the `$top`, `$skip`, and `$orderby` parameters.
69
69
  # @param companyId [Integer] The ID of the company that owns these batches
70
70
  # @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/) .
71
- # @param include [String] A comma separated list of child objects to return underneath the primary object.
71
+ # @param include [String] A comma separated list of additional data to retrieve.
72
72
  # @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
73
73
  # @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
74
74
  # @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
@@ -89,7 +89,7 @@ module AvaTax
89
89
  # 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/) .
90
90
  # Paginate your results using the `$top`, `$skip`, and `$orderby` parameters.
91
91
  # @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/) .
92
- # @param include [String] A comma separated list of child objects to return underneath the primary object.
92
+ # @param include [String] A comma separated list of additional data to retrieve.
93
93
  # @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
94
94
  # @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
95
95
  # @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
@@ -0,0 +1,77 @@
1
+ module AvaTax
2
+ class Client
3
+ module CertExpressInvites
4
+
5
+
6
+ # Create a CertExpress invitation
7
+ #
8
+ # Creates an invitation for a customer to self-report certificates using the CertExpress website.
9
+ #
10
+ # This invitation is delivered by your choice of method, or you can present a hyperlink to the user
11
+ # directly in your connector. Your customer will be redirected to https://app.certexpress.com/ where
12
+ # they can follow a step-by-step guide to enter information about their exemption certificates. The
13
+ # certificates entered will be recorded and automatically linked to their customer record.
14
+ #
15
+ # The [CertExpress website](https://app.certexpress.com/home) is available for customers to use at any time.
16
+ # Using CertExpress with this API will ensure that your certificates are automatically linked correctly into
17
+ # your company so that they can be used for tax exemptions.
18
+ # @param companyId [Integer] The unique ID number of the company that will record certificates
19
+ # @param customerCode [String] The number of the customer where the request is sent to
20
+ # @param model [CreateCertExpressInvitationModel[]] the requests to send out to customers
21
+ # @return [CertExpressInvitationStatusModel[]]
22
+ def create_cert_express_invitation(companyId, customerCode, model)
23
+ path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certexpressinvites"
24
+ post(path, model)
25
+ end
26
+
27
+
28
+ # Retrieve a single CertExpress invitation
29
+ #
30
+ # Retrieve an existing CertExpress invitation sent to a customer.
31
+ #
32
+ # A CertExpression invitation allows a customer to follow a helpful step-by-step guide to provide information
33
+ # about their certificates. This step by step guide allows the customer to complete and upload the full
34
+ # certificate in a convenient, friendly web browser experience. When the customer completes their certificates,
35
+ # they will automatically be recorded to your company and linked to the customer record.
36
+ #
37
+ # The [CertExpress website](https://app.certexpress.com/home) is available for customers to use at any time.
38
+ # Using CertExpress with this API will ensure that your certificates are automatically linked correctly into
39
+ # your company so that they can be used for tax exemptions.
40
+ # @param companyId [Integer] The unique ID number of the company that issued this invitation
41
+ # @param customerCode [String] The number of the customer where the request is sent to
42
+ # @param id [Integer] The unique ID number of this CertExpress invitation
43
+ # @param include [String] OPTIONAL: A comma separated list of special fetch options. No options are defined at this time.
44
+ # @return [Object]
45
+ def get_cert_express_invitation(companyId, customerCode, id, options={})
46
+ path = "/api/v2/companies/#{companyId}/customers/#{customerCode}/certexpressinvites/#{id}"
47
+ get(path, options)
48
+ end
49
+
50
+
51
+ # List CertExpress invitations
52
+ #
53
+ # Retrieve CertExpress invitations sent by this company.
54
+ #
55
+ # A CertExpression invitation allows a customer to follow a helpful step-by-step guide to provide information
56
+ # about their certificates. This step by step guide allows the customer to complete and upload the full
57
+ # certificate in a convenient, friendly web browser experience. When the customer completes their certificates,
58
+ # they will automatically be recorded to your company and linked to the customer record.
59
+ #
60
+ # The [CertExpress website](https://app.certexpress.com/home) is available for customers to use at any time.
61
+ # Using CertExpress with this API will ensure that your certificates are automatically linked correctly into
62
+ # your company so that they can be used for tax exemptions.
63
+ # @param companyId [Integer] The unique ID number of the company that issued this invitation
64
+ # @param include [String] OPTIONAL: A comma separated list of special fetch options. No options are defined at this time.
65
+ # @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/) .
66
+ # @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
67
+ # @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
68
+ # @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
69
+ # @return [FetchResult]
70
+ def list_cert_express_invitations(companyId, options={})
71
+ path = "/api/v2/companies/#{companyId}/certexpressinvites"
72
+ get(path, options)
73
+ end
74
+
75
+ end
76
+ end
77
+ end
@@ -0,0 +1,291 @@
1
+ module AvaTax
2
+ class Client
3
+ module Certificates
4
+
5
+
6
+ # Create certificates for this company
7
+ #
8
+ # Record one or more certificates document for this company.
9
+ #
10
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
11
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
12
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
13
+ # log onto the administrative website for the product you purchased.
14
+ #
15
+ # When you create a certificate, it will be processed by Avalara and will become available for use in
16
+ # calculating tax exemptions when processing is complete. For a certificate to be used in calculating exemptions,
17
+ # it must have the following:
18
+ #
19
+ # * A list of exposure zones indicating where the certificate is valid
20
+ # * A link to the customer that is allowed to use this certificate
21
+ # * Your tax transaction must contain the correct customer code
22
+ # @param companyId [Integer] The ID number of the company recording this certificate
23
+ # @param model [CertificateModel[]] Certificates to be created
24
+ # @return [CertificateModel[]]
25
+ def create_certificates(companyId, model)
26
+ path = "/api/v2/companies/#{companyId}/certificates"
27
+ post(path, model)
28
+ end
29
+
30
+
31
+ # Revoke and delete a certificate
32
+ #
33
+ # Revoke the certificate identified by this URL, then delete it.
34
+ #
35
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
36
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
37
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
38
+ # log onto the administrative website for the product you purchased.
39
+ #
40
+ # Revoked certificates can no longer be used.
41
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
42
+ # @param id [Integer] The unique ID number of this certificate
43
+ # @return [Object]
44
+ def delete_certificate(companyId, id)
45
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}"
46
+ delete(path)
47
+ end
48
+
49
+
50
+ # Download an image for this certificate
51
+ #
52
+ # Download an image or PDF file for this certificate.
53
+ #
54
+ # This API can be used to download either a single-page preview of the certificate or a full PDF document.
55
+ # To retrieve a preview image, set the `$type` parameter to `Jpeg` and the `$page` parameter to `1`.
56
+ #
57
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
58
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
59
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
60
+ # log onto the administrative website for the product you purchased.
61
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
62
+ # @param id [Integer] The unique ID number of this certificate
63
+ # @param page [Integer] If you choose `$type`=`Jpeg`, you must specify which page number to retrieve.
64
+ # @param type [String] The data format in which to retrieve the certificate image (See CertificatePreviewType::* for a list of allowable values)
65
+ # @return [Object]
66
+ def download_certificate_image(companyId, id, options={})
67
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/attachment"
68
+ get(path, options)
69
+ end
70
+
71
+
72
+ # Retrieve a single certificate
73
+ #
74
+ # Get the current certificate identified by this URL.
75
+ #
76
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
77
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
78
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
79
+ # log onto the administrative website for the product you purchased.
80
+ #
81
+ # You can use the `$include` parameter to fetch the following additional objects for expansion:
82
+ #
83
+ # * Customers - Retrieves the list of customers linked to the certificate.
84
+ # * PoNumbers - Retrieves all PO numbers tied to the certificate.
85
+ # * Attributes - Retrieves all attributes applied to the certificate.
86
+ # @param companyId [Integer] The ID number of the company that recorded this certificate
87
+ # @param id [Integer] The unique ID number of this certificate
88
+ # @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.
89
+ # @return [Object]
90
+ def get_certificate(companyId, id, options={})
91
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}"
92
+ get(path, options)
93
+ end
94
+
95
+
96
+ # Link attributes to a certificate
97
+ #
98
+ # Link one or many attributes to a certificate.
99
+ #
100
+ # A certificate may have multiple attributes that control its behavior. You may link or unlink attributes to a
101
+ # certificate at any time. The full list of defined attributes may be found using `ListCertificateAttributes`.
102
+ #
103
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
104
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
105
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
106
+ # log onto the administrative website for the product you purchased.
107
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
108
+ # @param id [Integer] The unique ID number of this certificate
109
+ # @param model [CertificateAttributeModel[]] The list of attributes to link to this certificate.
110
+ # @return [FetchResult]
111
+ def link_attributes_to_certificate(companyId, id, model)
112
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/attributes/link"
113
+ post(path, model)
114
+ end
115
+
116
+
117
+ # Link customers to a certificate
118
+ #
119
+ # Link one or more customers to an existing certificate.
120
+ #
121
+ # Customers and certificates must be linked before a customer can make use of a certificate to obtain
122
+ # a tax exemption in AvaTax. Since some certificates may cover more than one business entity, a certificate
123
+ # can be connected to multiple customer records using the `LinkCustomersToCertificate` API.
124
+ #
125
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
126
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
127
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
128
+ # log onto the administrative website for the product you purchased.
129
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
130
+ # @param id [Integer] The unique ID number of this certificate
131
+ # @param model [Object] The list of customers needed be added to the Certificate for exemption
132
+ # @return [FetchResult]
133
+ def link_customers_to_certificate(companyId, id, model)
134
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/customers/link"
135
+ post(path, model)
136
+ end
137
+
138
+
139
+ # List all attributes applied to this certificate
140
+ #
141
+ # Retrieve the list of attributes that are linked to this certificate.
142
+ #
143
+ # A certificate may have multiple attributes that control its behavior. You may link or unlink attributes to a
144
+ # certificate at any time. The full list of defined attributes may be found using `/api/v2/definitions/certificateattributes`.
145
+ #
146
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
147
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
148
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
149
+ # log onto the administrative website for the product you purchased.
150
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
151
+ # @param id [Integer] The unique ID number of this certificate
152
+ # @return [FetchResult]
153
+ def list_attributes_for_certificate(companyId, id)
154
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/attributes"
155
+ get(path)
156
+ end
157
+
158
+
159
+ # List customers linked to this certificate
160
+ #
161
+ # List all customers linked to this certificate.
162
+ #
163
+ # Customers must be linked to a certificate in order to make use of its tax exemption features. You
164
+ # can link or unlink customers to a certificate at any time.
165
+ #
166
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
167
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
168
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
169
+ # log onto the administrative website for the product you purchased.
170
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
171
+ # @param id [Integer] The unique ID number of this certificate
172
+ # @param include [String] OPTIONAL: A comma separated list of special fetch options. No options are currently available when fetching customers.
173
+ # @return [FetchResult]
174
+ def list_customers_for_certificate(companyId, id, options={})
175
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/customers"
176
+ get(path, options)
177
+ end
178
+
179
+
180
+ # List all certificates for a company
181
+ #
182
+ # List all certificates recorded by a company
183
+ #
184
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
185
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
186
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
187
+ # log onto the administrative website for the product you purchased.
188
+ #
189
+ # You can use the `$include` parameter to fetch the following additional objects for expansion:
190
+ #
191
+ # * Customers - Retrieves the list of customers linked to the certificate.
192
+ # * PoNumbers - Retrieves all PO numbers tied to the certificate.
193
+ # * Attributes - Retrieves all attributes applied to the certificate.
194
+ # @param companyId [Integer] The ID number of the company to search
195
+ # @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.
196
+ # @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/) .
197
+ # @param top [Integer] If nonzero, return no more than this number of results. Used with $skip to provide pagination for large datasets.
198
+ # @param skip [Integer] If nonzero, skip this number of results before returning data. Used with $top to provide pagination for large datasets.
199
+ # @param orderBy [String] A comma separated list of sort statements in the format `(fieldname) [ASC|DESC]`, for example `id ASC`.
200
+ # @return [FetchResult]
201
+ def query_certificates(companyId, options={})
202
+ path = "/api/v2/companies/#{companyId}/certificates"
203
+ get(path, options)
204
+ end
205
+
206
+
207
+ # Unlink attributes from a certificate
208
+ #
209
+ # Unlink one or many attributes from a certificate.
210
+ #
211
+ # A certificate may have multiple attributes that control its behavior. You may link or unlink attributes to a
212
+ # certificate at any time. The full list of defined attributes may be found using `ListCertificateAttributes`.
213
+ #
214
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
215
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
216
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
217
+ # log onto the administrative website for the product you purchased.
218
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
219
+ # @param id [Integer] The unique ID number of this certificate
220
+ # @param model [CertificateAttributeModel[]] The list of attributes to unlink from this certificate.
221
+ # @return [FetchResult]
222
+ def unlink_attributes_from_certificate(companyId, id, model)
223
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/attributes/unlink"
224
+ post(path, model)
225
+ end
226
+
227
+
228
+ # Unlink customers from a certificate
229
+ #
230
+ # Unlinks one or more customers from a certificate.
231
+ #
232
+ # Unlinking a certificate from a customer will prevent the certificate from being used to generate
233
+ # tax exemptions for the customer in the future. If any previous transactions for this customer had
234
+ # used this linked certificate, those transactions will be unchanged and will still have a link to the
235
+ # exemption certificate in question.
236
+ #
237
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
238
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
239
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
240
+ # log onto the administrative website for the product you purchased.
241
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
242
+ # @param id [Integer] The unique ID number of this certificate
243
+ # @param model [Object] The list of customers to unlink from this certificate
244
+ # @return [FetchResult]
245
+ def unlink_customers_from_certificate(companyId, id, model)
246
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/customers/unlink"
247
+ post(path, model)
248
+ end
249
+
250
+
251
+ # Update a single certificate
252
+ #
253
+ # Replace the certificate identified by this URL with a new one.
254
+ #
255
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
256
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
257
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
258
+ # log onto the administrative website for the product you purchased.
259
+ # @param companyId [Integer] The ID number of the company that recorded this certificate
260
+ # @param id [Integer] The unique ID number of this certificate
261
+ # @param model [Object] The new certificate object that will replace the existing one
262
+ # @return [Object]
263
+ def update_certificate(companyId, id, model)
264
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}"
265
+ put(path, model)
266
+ end
267
+
268
+
269
+ # Upload an image or PDF attachment for this certificate
270
+ #
271
+ # Upload an image or PDF attachment for this certificate.
272
+ #
273
+ # Image attachments can be of the format `PDF`, `JPEG`, `TIFF`, or `PNG`. To upload a multi-page image, please
274
+ # use the `PDF` data type.
275
+ #
276
+ # A certificate is a document stored in either AvaTax Exemptions or CertCapture. The certificate document
277
+ # can contain information about a customer's eligibility for exemption from sales or use taxes based on
278
+ # criteria you specify when you store the certificate. To view or manage your certificates directly, please
279
+ # log onto the administrative website for the product you purchased.
280
+ # @param companyId [Integer] The unique ID number of the company that recorded this certificate
281
+ # @param id [Integer] The unique ID number of this certificate
282
+ # @param file [Object] The exemption certificate file you wanted to upload. Accepted formats are: PDF, JPEG, TIFF, PNG.
283
+ # @return [String]
284
+ def upload_certificate_image(companyId, id)
285
+ path = "/api/v2/companies/#{companyId}/certificates/#{id}/attachment"
286
+ post(path)
287
+ end
288
+
289
+ end
290
+ end
291
+ end