Skip to content

Commit edbe5b8

Browse files
Merge pull request #82 from avadev/19.12.1
19.12.1 update
2 parents 01eec73 + 40b600b commit edbe5b8

File tree

2 files changed

+33
-18
lines changed

2 files changed

+33
-18
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
setup(
1111
name='Avalara',
12-
version='19.11.0',
12+
version='19.12.0',
1313
url='https://github.com/avadev/AvaTax-REST-V2-Python-SDK',
1414
package_dir={'': 'src'},
1515
packages=['avalara'],

src/client_methods.py

Lines changed: 32 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,6 @@ def resolve_address_post(self, model):
231231
### Security Policies
232232
* This API requires the user role Compliance Root User.
233233
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
234-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
235234
236235
:param model [AvaFileFormModel] The AvaFileForm you wish to create.
237236
:return AvaFileFormModel
@@ -248,7 +247,6 @@ def create_ava_file_forms(self, model):
248247
### Security Policies
249248
* This API requires one of the following user roles: Compliance Root User, ComplianceUser, FirmAdmin.
250249
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
251-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
252250
253251
:param id_ [int] The ID of the AvaFileForm you wish to delete.
254252
:return ErrorDetail
@@ -264,7 +262,6 @@ def delete_ava_file_form(self, id_):
264262
Get the AvaFileForm object identified by this URL.
265263
### Security Policies
266264
* This API requires one of the following user roles: AccountAdmin, AccountOperator, CompanyAdmin, CompanyUser, Compliance Root User, Compliance Temp User, ComplianceAdmin, ComplianceUser, FirmAdmin, FirmUser, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin.
267-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
268265
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
269266
270267
:param id_ [int] The primary key of this AvaFileForm
@@ -283,7 +280,6 @@ def get_ava_file_form(self, id_):
283280
### Security Policies
284281
* This API requires one of the following user roles: AccountAdmin, AccountOperator, CompanyAdmin, CompanyUser, Compliance Root User, Compliance Temp User, ComplianceAdmin, ComplianceUser, FirmAdmin, FirmUser, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin.
285282
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
286-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
287283
288284
: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/).<br />*Not filterable:* outletTypeId
289285
:param top [int] If nonzero, return no more than this number of results. Used with `$skip` to provide pagination for large datasets. Unless otherwise specified, the maximum number of records that can be returned from an API call is 1,000 records.
@@ -304,7 +300,6 @@ def query_ava_file_forms(self, include=None):
304300
### Security Policies
305301
* This API requires the user role Compliance Root User.
306302
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
307-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
308303
309304
:param id_ [int] The ID of the AvaFileForm you wish to update
310305
:param model [AvaFileFormModel] The AvaFileForm model you wish to update.
@@ -1141,7 +1136,6 @@ def delete_company(self, id_):
11411136
### Security Policies
11421137
* This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, CompanyAdmin, CompanyUser, Compliance Root User, ComplianceAdmin, ComplianceUser, CSPAdmin, CSPTester, FirmAdmin, FirmUser, ProStoresOperator, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser.
11431138
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
1144-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
11451139
11461140
:param companyId [int] The unique identifier of the company
11471141
:return FundingConfigurationModel
@@ -1161,7 +1155,6 @@ def funding_configuration_by_company(self, companyId):
11611155
### Security Policies
11621156
* This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, CompanyAdmin, CompanyUser, Compliance Root User, ComplianceAdmin, ComplianceUser, CSPAdmin, CSPTester, FirmAdmin, FirmUser, ProStoresOperator, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser.
11631157
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
1164-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
11651158
11661159
:param companyId [int] The unique identifier of the company
11671160
:param currency [string] The currency of the funding. USD and CAD are the only valid currencies
@@ -1533,7 +1526,7 @@ def create_customers(self, companyId, model):
15331526
15341527
:param companyId [int] The unique ID number of the company that recorded this customer
15351528
:param customerCode [string] The unique code representing this customer
1536-
:return ErrorDetail
1529+
:return CustomerModel
15371530
"""
15381531
def delete_customer(self, companyId, customerCode):
15391532
return requests.delete('{}/api/v2/companies/{}/customers/{}'.format(self.base_url, companyId, customerCode),
@@ -2031,12 +2024,13 @@ def list_ava_file_forms(self, include=None):
20312024
r"""
20322025
List certificate attributes used by a company
20332026
2034-
List the certificate attributes defined by a company.
2027+
List the certificate attributes defined by a company either specified by the user or the user's default company.
20352028
A certificate may have multiple attributes that control its behavior. You may apply or remove attributes to a
20362029
certificate at any time.
20372030
If you see the 'CertCaptureNotConfiguredError', please use CheckProvision and RequestProvision endpoints to
20382031
check and provision account.
20392032
2033+
:param companyid [int] Id of the company the user wish to fetch the certificates' attributes from. If not specified the API will use user's default company.
20402034
: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/).
20412035
:param top [int] If nonzero, return no more than this number of results. Used with `$skip` to provide pagination for large datasets. Unless otherwise specified, the maximum number of records that can be returned from an API call is 1,000 records.
20422036
:param skip [int] If nonzero, skip this number of results before returning data. Used with `$top` to provide pagination for large datasets.
@@ -3165,6 +3159,30 @@ def update_distance_threshold(self, companyId, id_, model):
31653159
auth=self.auth, headers=self.client_header, json=model,
31663160
timeout=self.timeout_limit if self.timeout_limit else 10)
31673161

3162+
r"""
3163+
Retrieve a list of filed returns for the specified company in the year and month of a given filing period.
3164+
3165+
### Security Policies
3166+
* This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, CompanyAdmin, CompanyUser, Compliance Root User, ComplianceAdmin, ComplianceUser, CSPAdmin, CSPTester, FirmAdmin, FirmUser, ProStoresOperator, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser.
3167+
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser, CompanyUser, AccountUser, CompanyAdmin, AccountAdmin.
3168+
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
3169+
3170+
:param companyId [int] The ID of the company that owns these batches
3171+
:param endPeriodMonth [int] The month of the period you are trying to retrieve
3172+
:param endPeriodYear [int] The year of the period you are trying to retrieve
3173+
:param frequency [FilingFrequencyId] The frequency of the return you are trying to retrieve (See FilingFrequencyId::* for a list of allowable values)
3174+
:param status [FilingStatusId] The status of the return(s) you are trying to retrieve (See FilingStatusId::* for a list of allowable values)
3175+
:param country [string] The country of the return(s) you are trying to retrieve
3176+
:param region [string] The region of the return(s) you are trying to retrieve
3177+
:param filingCalendarId [int] The filing calendar id of the return you are trying to retrieve
3178+
:param taxformCode [string] The unique tax form code of the form.
3179+
:return FetchResult
3180+
"""
3181+
def get_filed_returns(self, companyId, include=None):
3182+
return requests.get('{}/api/v2/companies/{}/filings/returns/filed'.format(self.base_url, companyId),
3183+
auth=self.auth, headers=self.client_header, params=include,
3184+
timeout=self.timeout_limit if self.timeout_limit else 10)
3185+
31683186
r"""
31693187
Approves linkage to a firm for a client account
31703188
@@ -3415,7 +3433,6 @@ def tax_rates_by_postal_code(self, include=None):
34153433
### Security Policies
34163434
* This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, CompanyAdmin, CompanyUser, Compliance Root User, ComplianceAdmin, ComplianceUser, CSPAdmin, CSPTester, FirmAdmin, FirmUser, ProStoresOperator, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser.
34173435
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
3418-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
34193436
34203437
:param id_ [int] The unique ID number of this funding request
34213438
:return FundingStatusModel
@@ -3441,7 +3458,6 @@ def activate_funding_request(self, id_):
34413458
### Security Policies
34423459
* This API requires one of the following user roles: AccountAdmin, CompanyAdmin, CSPTester, FirmAdmin, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin.
34433460
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
3444-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
34453461
34463462
:param id_ [int] The unique ID number of this funding request
34473463
:return FundingStatusModel
@@ -4698,7 +4714,7 @@ def list_notifications(self, include=None):
46984714
r"""
46994715
Request a new Avalara account
47004716
4701-
This API is for use by partner onboarding services customers only.
4717+
This API is for use by partner provisioning services customers only.
47024718
Avalara invites select partners to refer new customers to the AvaTax service using the onboarding features
47034719
of AvaTax. These partners can create accounts for new customers using this API.
47044720
Calling this API creates an account with the specified product subscriptions, but does not configure billing.
@@ -4712,7 +4728,7 @@ def list_notifications(self, include=None):
47124728
### Security Policies
47134729
* This API requires one of the following user roles: AccountAdmin, CompanyAdmin, CSPTester, FirmAdmin, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin.
47144730
* This API is available by invitation only.
4715-
* This API is available by invitation only. To request access to this feature, please speak to a business development manager and request access to [Onboarding:RequestNewAccount].
4731+
* This API is available by invitation only. To request access to this feature, please speak to a business development manager and request access to [Provisioning:RequestNewAccount].
47164732
47174733
:param model [NewAccountRequestModel] Information about the account you wish to create and the selected product offerings.
47184734
:return NewAccountModel
@@ -4725,12 +4741,12 @@ def request_new_account(self, model):
47254741
r"""
47264742
Request a new entitilement to an existing customer
47274743
4728-
This API is for use by partner onboarding services customers only. This will allow the partners to allow
4744+
This API is for use by partner provisioning services customers only. This will allow the partners to allow
47294745
the add new entitlement to an existing customer
47304746
### Security Policies
47314747
* This API requires one of the following user roles: AccountAdmin, CompanyAdmin, CSPTester, FirmAdmin, Registrar, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin.
47324748
* This API is available by invitation only.
4733-
* This API is available by invitation only. To request access to this feature, please speak to a business development manager and request access to [Onboarding:RequestNewAccount].
4749+
* This API is available by invitation only. To request access to this feature, please speak to a business development manager and request access to [Provisioning:RequestNewAccount].
47344750
47354751
:param id_ [int] The avatax account id of the customer
47364752
:param offer [string] The offer to be added to an already existing customer
@@ -5807,7 +5823,6 @@ def audit_transaction_with_type(self, companyCode, transactionCode, documentType
58075823
### Security Policies
58085824
* This API requires the user role Compliance Root User.
58095825
* This API depends on the following active services<br />*Returns* (at least one of): Mrs, MRSComplianceManager, AvaTaxCsp.<br />*Firm Managed* (for accounts managed by a firm): ARA, ARAManaged.
5810-
* This API is available by invitation only.<br />*Exempt security roles*: ComplianceRootUser, ComplianceAdmin, ComplianceUser, TechnicalSupportAdmin, TechnicalSupportUser.
58115826
58125827
:param model [BulkLockTransactionModel] bulk lock request
58135828
:return BulkLockTransactionResult
@@ -6705,7 +6720,7 @@ def update_user(self, id_, accountId, model):
67056720
or subscription to provide useful information to the current user as to whether they are entitled to use
67066721
specific features of AvaTax.
67076722
6708-
:param serviceTypeId [ServiceTypeId] The service to check (See ServiceTypeId::* for a list of allowable values)
6723+
:param serviceTypeId [string] The service to check
67096724
:return SubscriptionModel
67106725
"""
67116726
def get_my_subscription(self, serviceTypeId):

0 commit comments

Comments
 (0)