diff --git a/Avalara/SDK/api/A1099/V2/companies_w9_api.py b/Avalara/SDK/api/A1099/V2/companies_w9_api.py index 30229a3..d790503 100644 --- a/Avalara/SDK/api/A1099/V2/companies_w9_api.py +++ b/Avalara/SDK/api/A1099/V2/companies_w9_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -61,7 +61,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.create_company_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/A1099/V2/forms1099_api.py b/Avalara/SDK/api/A1099/V2/forms1099_api.py index cb5227b..a5822a5 100644 --- a/Avalara/SDK/api/A1099/V2/forms1099_api.py +++ b/Avalara/SDK/api/A1099/V2/forms1099_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -65,7 +65,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.bulk_upsert1099_forms_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/A1099/V2/forms_w9_api.py b/Avalara/SDK/api/A1099/V2/forms_w9_api.py index 98e7d16..f2ecf66 100644 --- a/Avalara/SDK/api/A1099/V2/forms_w9_api.py +++ b/Avalara/SDK/api/A1099/V2/forms_w9_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -46,7 +46,7 @@ from Avalara.SDK.models.A1099.V2.create_w9_form201_response import CreateW9Form201Response from Avalara.SDK.models.A1099.V2.create_w9_form_request import CreateW9FormRequest from Avalara.SDK.models.A1099.V2.iw9_form_data_models_one_of import IW9FormDataModelsOneOf -from Avalara.SDK.models.A1099.V2.paginated_w9_forms_model import PaginatedW9FormsModel +from Avalara.SDK.models.A1099.V2.paginated_query_result_model_w9_form_base_response import PaginatedQueryResultModelW9FormBaseResponse from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth @@ -61,7 +61,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.create_w9_form_endpoint = _Endpoint( @@ -278,7 +278,7 @@ def __set_configuration(self, api_client): ) self.list_w9_forms_endpoint = _Endpoint( settings={ - 'response_type': (PaginatedW9FormsModel,), + 'response_type': (PaginatedQueryResultModelW9FormBaseResponse,), 'auth': [ 'bearer' ], @@ -295,6 +295,7 @@ def __set_configuration(self, api_client): 'skip', 'order_by', 'count', + 'count_only', 'x_correlation_id', 'x_avalara_client', ], @@ -326,6 +327,8 @@ def __set_configuration(self, api_client): (str,), 'count': (bool,), + 'count_only': + (bool,), 'x_correlation_id': (str,), 'x_avalara_client': @@ -338,6 +341,7 @@ def __set_configuration(self, api_client): 'skip': '$skip', 'order_by': '$orderBy', 'count': 'count', + 'count_only': 'countOnly', 'x_correlation_id': 'X-Correlation-Id', 'x_avalara_client': 'X-Avalara-Client', }, @@ -348,6 +352,7 @@ def __set_configuration(self, api_client): 'skip': 'query', 'order_by': 'query', 'count': 'query', + 'count_only': 'query', 'x_correlation_id': 'header', 'x_avalara_client': 'header', }, @@ -813,7 +818,7 @@ def list_w9_forms( ): """List W9/W4/W8 forms # noqa: E501 - List W9/W4/W8 forms. # noqa: E501 + List W9/W4/W8 forms. Filterable/Sortable fields are: \"companyId\", \"type\", \"displayName\", \"entryStatus\", \"email\", \"archived\" and \"referenceId\". # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True @@ -824,11 +829,12 @@ def list_w9_forms( avalara_version (str): API version Keyword Args: - filter (str): A filter statement to identify specific records to retrieve. For more information on filtering, see Filtering in REST.. [optional] - 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.. [optional] if omitted the server will use the default value of 10 - skip (int): If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets.. [optional] if omitted the server will use the default value of 0 + filter (str): A filter statement to identify specific records to retrieve. For more information on filtering, see Filtering in REST.. [optional] + top (int): If zero or greater than 1000, return at most 1000 results. Otherwise, return this number of results. Used with skip to provide pagination for large datasets.. [optional] + skip (int): If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets.. [optional] order_by (str): A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC.. [optional] - count (bool): When true, returns a @recordSetCount in the result set. [optional] + count (bool): If true, return the global count of elements in the collection.. [optional] + count_only (bool): If true, return ONLY the global count of elements in the collection. It only applies when count=true.. [optional] x_correlation_id (str): Unique correlation Id in a GUID format. [optional] x_avalara_client (str): Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) .. [optional] _return_http_data_only (bool): response data without head status @@ -852,7 +858,7 @@ def list_w9_forms( async_req (bool): execute request asynchronously Returns: - PaginatedW9FormsModel + PaginatedQueryResultModelW9FormBaseResponse If the method is called asynchronously, returns the request thread. """ diff --git a/Avalara/SDK/api/A1099/V2/issuers1099_api.py b/Avalara/SDK/api/A1099/V2/issuers1099_api.py index 8ca7fc6..e4900fa 100644 --- a/Avalara/SDK/api/A1099/V2/issuers1099_api.py +++ b/Avalara/SDK/api/A1099/V2/issuers1099_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -60,7 +60,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.create_issuer_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/A1099/V2/jobs1099_api.py b/Avalara/SDK/api/A1099/V2/jobs1099_api.py index 88d02e0..53384db 100644 --- a/Avalara/SDK/api/A1099/V2/jobs1099_api.py +++ b/Avalara/SDK/api/A1099/V2/jobs1099_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -58,7 +58,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.get_job_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/data_input_fields_api.py b/Avalara/SDK/api/EInvoicing/V1/data_input_fields_api.py index f30edcb..34eeed1 100644 --- a/Avalara/SDK/api/EInvoicing/V1/data_input_fields_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/data_input_fields_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -58,7 +58,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.get_data_input_fields_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/documents_api.py b/Avalara/SDK/api/EInvoicing/V1/documents_api.py index 62e920e..04a2bc7 100644 --- a/Avalara/SDK/api/EInvoicing/V1/documents_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/documents_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -64,7 +64,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.download_document_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/interop_api.py b/Avalara/SDK/api/EInvoicing/V1/interop_api.py index 843c4f3..a59e6ba 100644 --- a/Avalara/SDK/api/EInvoicing/V1/interop_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/interop_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -58,7 +58,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.submit_interop_document_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/mandates_api.py b/Avalara/SDK/api/EInvoicing/V1/mandates_api.py index b3704a3..4bcd86e 100644 --- a/Avalara/SDK/api/EInvoicing/V1/mandates_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/mandates_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -59,7 +59,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.get_mandate_data_input_fields_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/subscriptions_api.py b/Avalara/SDK/api/EInvoicing/V1/subscriptions_api.py index ffaafb0..e6030f8 100644 --- a/Avalara/SDK/api/EInvoicing/V1/subscriptions_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/subscriptions_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -61,7 +61,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.create_webhook_subscription_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/tax_identifiers_api.py b/Avalara/SDK/api/EInvoicing/V1/tax_identifiers_api.py index 6171566..71554c0 100644 --- a/Avalara/SDK/api/EInvoicing/V1/tax_identifiers_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/tax_identifiers_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -60,7 +60,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.tax_identifier_schema_by_country_endpoint = _Endpoint( diff --git a/Avalara/SDK/api/EInvoicing/V1/trading_partners_api.py b/Avalara/SDK/api/EInvoicing/V1/trading_partners_api.py index e32db6d..599694d 100644 --- a/Avalara/SDK/api/EInvoicing/V1/trading_partners_api.py +++ b/Avalara/SDK/api/EInvoicing/V1/trading_partners_api.py @@ -22,7 +22,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -66,7 +66,7 @@ def __verify_api_client(self,api_client): def __set_configuration(self, api_client): self.__verify_api_client(api_client) - api_client.set_sdk_version("25.8.1") + api_client.set_sdk_version("25.8.2") self.api_client = api_client self.batch_search_participants_endpoint = _Endpoint( diff --git a/Avalara/SDK/models/A1099/V2/attribute.py b/Avalara/SDK/models/A1099/V2/attribute.py index e19a8fe..05767bd 100644 --- a/Avalara/SDK/models/A1099/V2/attribute.py +++ b/Avalara/SDK/models/A1099/V2/attribute.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/authorized_api_request_model.py b/Avalara/SDK/models/A1099/V2/authorized_api_request_model.py index 1d81ebc..22b9fc5 100644 --- a/Avalara/SDK/models/A1099/V2/authorized_api_request_model.py +++ b/Avalara/SDK/models/A1099/V2/authorized_api_request_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/authorized_api_request_v2_data_model.py b/Avalara/SDK/models/A1099/V2/authorized_api_request_v2_data_model.py index 2a6ed71..7493274 100644 --- a/Avalara/SDK/models/A1099/V2/authorized_api_request_v2_data_model.py +++ b/Avalara/SDK/models/A1099/V2/authorized_api_request_v2_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/base_company_model.py b/Avalara/SDK/models/A1099/V2/base_company_model.py index 6f5ff24..a511803 100644 --- a/Avalara/SDK/models/A1099/V2/base_company_model.py +++ b/Avalara/SDK/models/A1099/V2/base_company_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/base_form_list_request.py b/Avalara/SDK/models/A1099/V2/base_form_list_request.py index bb8045c..35e090c 100644 --- a/Avalara/SDK/models/A1099/V2/base_form_list_request.py +++ b/Avalara/SDK/models/A1099/V2/base_form_list_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py b/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py index 18f2872..bc83e3b 100644 --- a/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py +++ b/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -37,6 +37,7 @@ from Avalara.SDK.models.A1099.V2.form1095_b_list import Form1095BList from Avalara.SDK.models.A1099.V2.form1095_c_list import Form1095CList from Avalara.SDK.models.A1099.V2.form1099_div_list import Form1099DivList +from Avalara.SDK.models.A1099.V2.form1099_int_list import Form1099IntList from Avalara.SDK.models.A1099.V2.form1099_k_list import Form1099KList from Avalara.SDK.models.A1099.V2.form1099_misc_list import Form1099MiscList from Avalara.SDK.models.A1099.V2.form1099_nec_list import Form1099NecList @@ -45,7 +46,7 @@ from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -BULKUPSERT1099FORMSREQUEST_ONE_OF_SCHEMAS = ["Form1042SList", "Form1095BList", "Form1095CList", "Form1099DivList", "Form1099KList", "Form1099MiscList", "Form1099NecList", "Form1099RList"] +BULKUPSERT1099FORMSREQUEST_ONE_OF_SCHEMAS = ["Form1042SList", "Form1095BList", "Form1095CList", "Form1099DivList", "Form1099IntList", "Form1099KList", "Form1099MiscList", "Form1099NecList", "Form1099RList"] class BulkUpsert1099FormsRequest(BaseModel): """ @@ -59,16 +60,18 @@ class BulkUpsert1099FormsRequest(BaseModel): oneof_schema_3_validator: Optional[Form1095CList] = None # data type: Form1099DivList oneof_schema_4_validator: Optional[Form1099DivList] = None + # data type: Form1099IntList + oneof_schema_5_validator: Optional[Form1099IntList] = None # data type: Form1099KList - oneof_schema_5_validator: Optional[Form1099KList] = None + oneof_schema_6_validator: Optional[Form1099KList] = None # data type: Form1099MiscList - oneof_schema_6_validator: Optional[Form1099MiscList] = None + oneof_schema_7_validator: Optional[Form1099MiscList] = None # data type: Form1099NecList - oneof_schema_7_validator: Optional[Form1099NecList] = None + oneof_schema_8_validator: Optional[Form1099NecList] = None # data type: Form1099RList - oneof_schema_8_validator: Optional[Form1099RList] = None - actual_instance: Optional[Union[Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList]] = None - one_of_schemas: Set[str] = { "Form1042SList", "Form1095BList", "Form1095CList", "Form1099DivList", "Form1099KList", "Form1099MiscList", "Form1099NecList", "Form1099RList" } + oneof_schema_9_validator: Optional[Form1099RList] = None + actual_instance: Optional[Union[Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList]] = None + one_of_schemas: Set[str] = { "Form1042SList", "Form1095BList", "Form1095CList", "Form1099DivList", "Form1099IntList", "Form1099KList", "Form1099MiscList", "Form1099NecList", "Form1099RList" } model_config = ConfigDict( validate_assignment=True, @@ -111,6 +114,11 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivList`") else: match += 1 + # validate data type: Form1099IntList + if not isinstance(v, Form1099IntList): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntList`") + else: + match += 1 # validate data type: Form1099KList if not isinstance(v, Form1099KList): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KList`") @@ -133,10 +141,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) else: return v @@ -175,6 +183,12 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099IntList + try: + instance.actual_instance = Form1099IntList.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099KList try: instance.actual_instance = Form1099KList.from_json(json_str) @@ -202,10 +216,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into BulkUpsert1099FormsRequest with oneOf schemas: Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList. Details: " + ", ".join(error_messages)) else: return instance @@ -219,7 +233,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SList, Form1095BList, Form1095CList, Form1099DivList, Form1099IntList, Form1099KList, Form1099MiscList, Form1099NecList, Form1099RList]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/Avalara/SDK/models/A1099/V2/company_create_update_request_model.py b/Avalara/SDK/models/A1099/V2/company_create_update_request_model.py index 5db5f7d..41c22c8 100644 --- a/Avalara/SDK/models/A1099/V2/company_create_update_request_model.py +++ b/Avalara/SDK/models/A1099/V2/company_create_update_request_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/company_model.py b/Avalara/SDK/models/A1099/V2/company_model.py index 4169eff..27f3a9e 100644 --- a/Avalara/SDK/models/A1099/V2/company_model.py +++ b/Avalara/SDK/models/A1099/V2/company_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/company_response.py b/Avalara/SDK/models/A1099/V2/company_response.py index 90972f7..4cc53f0 100644 --- a/Avalara/SDK/models/A1099/V2/company_response.py +++ b/Avalara/SDK/models/A1099/V2/company_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/company_response_model.py b/Avalara/SDK/models/A1099/V2/company_response_model.py index 36e6945..9071981 100644 --- a/Avalara/SDK/models/A1099/V2/company_response_model.py +++ b/Avalara/SDK/models/A1099/V2/company_response_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/covered_individual_reference.py b/Avalara/SDK/models/A1099/V2/covered_individual_reference.py index 45f23a0..a5ad7f9 100644 --- a/Avalara/SDK/models/A1099/V2/covered_individual_reference.py +++ b/Avalara/SDK/models/A1099/V2/covered_individual_reference.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/covered_individual_reference_response.py b/Avalara/SDK/models/A1099/V2/covered_individual_reference_response.py index c9445ab..a0e8e42 100644 --- a/Avalara/SDK/models/A1099/V2/covered_individual_reference_response.py +++ b/Avalara/SDK/models/A1099/V2/covered_individual_reference_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/covered_individual_request.py b/Avalara/SDK/models/A1099/V2/covered_individual_request.py index 551a4ff..7c99164 100644 --- a/Avalara/SDK/models/A1099/V2/covered_individual_request.py +++ b/Avalara/SDK/models/A1099/V2/covered_individual_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/create1099_form201_response.py b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py index 1ec5165..1a840b8 100644 --- a/Avalara/SDK/models/A1099/V2/create1099_form201_response.py +++ b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -37,6 +37,7 @@ from Avalara.SDK.models.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse from Avalara.SDK.models.A1099.V2.form1099_base_response import Form1099BaseResponse from Avalara.SDK.models.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse from Avalara.SDK.models.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse from Avalara.SDK.models.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse from Avalara.SDK.models.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse @@ -45,7 +46,7 @@ from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -CREATE1099FORM201RESPONSE_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] +CREATE1099FORM201RESPONSE_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] class Create1099Form201Response(BaseModel): """ @@ -59,16 +60,18 @@ class Create1099Form201Response(BaseModel): oneof_schema_3_validator: Optional[Form1095BListItemResponse] = None # data type: Form1099DivListItemResponse oneof_schema_4_validator: Optional[Form1099DivListItemResponse] = None + # data type: Form1099IntListItemResponse + oneof_schema_5_validator: Optional[Form1099IntListItemResponse] = None # data type: Form1099KListItemResponse - oneof_schema_5_validator: Optional[Form1099KListItemResponse] = None + oneof_schema_6_validator: Optional[Form1099KListItemResponse] = None # data type: Form1099MiscListItemResponse - oneof_schema_6_validator: Optional[Form1099MiscListItemResponse] = None + oneof_schema_7_validator: Optional[Form1099MiscListItemResponse] = None # data type: Form1099NecListItemResponse - oneof_schema_7_validator: Optional[Form1099NecListItemResponse] = None + oneof_schema_8_validator: Optional[Form1099NecListItemResponse] = None # data type: Form1099RListItemResponse - oneof_schema_8_validator: Optional[Form1099RListItemResponse] = None - actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None - one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } + oneof_schema_9_validator: Optional[Form1099RListItemResponse] = None + actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None + one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } model_config = ConfigDict( validate_assignment=True, @@ -111,6 +114,11 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivListItemResponse`") else: match += 1 + # validate data type: Form1099IntListItemResponse + if not isinstance(v, Form1099IntListItemResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntListItemResponse`") + else: + match += 1 # validate data type: Form1099KListItemResponse if not isinstance(v, Form1099KListItemResponse): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KListItemResponse`") @@ -133,10 +141,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return v @@ -175,6 +183,12 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099IntListItemResponse + try: + instance.actual_instance = Form1099IntListItemResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099KListItemResponse try: instance.actual_instance = Form1099KListItemResponse.from_json(json_str) @@ -202,10 +216,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into Create1099Form201Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return instance @@ -219,7 +233,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/Avalara/SDK/models/A1099/V2/create_w9_form201_response.py b/Avalara/SDK/models/A1099/V2/create_w9_form201_response.py index 5251440..2196ed6 100644 --- a/Avalara/SDK/models/A1099/V2/create_w9_form201_response.py +++ b/Avalara/SDK/models/A1099/V2/create_w9_form201_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -67,6 +67,9 @@ class CreateW9Form201Response(BaseModel): ) + discriminator_value_class_map: Dict[str, str] = { + } + def __init__(self, *args, **kwargs) -> None: if args: if len(args) > 1: diff --git a/Avalara/SDK/models/A1099/V2/create_w9_form_request.py b/Avalara/SDK/models/A1099/V2/create_w9_form_request.py index f221c93..ddd7d47 100644 --- a/Avalara/SDK/models/A1099/V2/create_w9_form_request.py +++ b/Avalara/SDK/models/A1099/V2/create_w9_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/data.py b/Avalara/SDK/models/A1099/V2/data.py index 4d8d77d..477c787 100644 --- a/Avalara/SDK/models/A1099/V2/data.py +++ b/Avalara/SDK/models/A1099/V2/data.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/error_model.py b/Avalara/SDK/models/A1099/V2/error_model.py index 7405205..8feb43f 100644 --- a/Avalara/SDK/models/A1099/V2/error_model.py +++ b/Avalara/SDK/models/A1099/V2/error_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/error_response.py b/Avalara/SDK/models/A1099/V2/error_response.py index f7e5feb..f6ef04a 100644 --- a/Avalara/SDK/models/A1099/V2/error_response.py +++ b/Avalara/SDK/models/A1099/V2/error_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.error_response_errors_inner import ErrorResponseErrorsInner +from Avalara.SDK.models.A1099.V2.error_response_item import ErrorResponseItem from typing import Optional, Set from typing_extensions import Self @@ -44,7 +44,7 @@ class ErrorResponse(BaseModel): ErrorResponse """ # noqa: E501 title: Optional[StrictStr] = None - errors: Optional[List[ErrorResponseErrorsInner]] = None + errors: Optional[List[ErrorResponseItem]] = None __properties: ClassVar[List[str]] = ["title", "errors"] model_config = ConfigDict( @@ -116,7 +116,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "title": obj.get("title"), - "errors": [ErrorResponseErrorsInner.from_dict(_item) for _item in obj["errors"]] if obj.get("errors") is not None else None + "errors": [ErrorResponseItem.from_dict(_item) for _item in obj["errors"]] if obj.get("errors") is not None else None }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/error_response_errors_inner.py b/Avalara/SDK/models/A1099/V2/error_response_errors_inner.py index 205e695..36445af 100644 --- a/Avalara/SDK/models/A1099/V2/error_response_errors_inner.py +++ b/Avalara/SDK/models/A1099/V2/error_response_errors_inner.py @@ -33,8 +33,8 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails -from Avalara.SDK.models.A1099.V2.problem_details import ProblemDetails +from Avalara.SDK.models.A1099.V2.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails +from Avalara.SDK.models.A1099.V2.A1099.V2.problem_details import ProblemDetails from pydantic import StrictStr, Field from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self diff --git a/Avalara/SDK/models/A1099/V2/error_response_item.py b/Avalara/SDK/models/A1099/V2/error_response_item.py new file mode 100644 index 0000000..ac3af6e --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/error_response_item.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self + +class ErrorResponseItem(BaseModel): + """ + ErrorResponseItem + """ # noqa: E501 + type: Optional[StrictStr] = None + detail: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["type", "detail"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ErrorResponseItem from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if type (nullable) is None + # and model_fields_set contains the field + if self.type is None and "type" in self.model_fields_set: + _dict['type'] = None + + # set to None if detail (nullable) is None + # and model_fields_set contains the field + if self.detail is None and "detail" in self.model_fields_set: + _dict['detail'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ErrorResponseItem from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "type": obj.get("type"), + "detail": obj.get("detail") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1042_s.py b/Avalara/SDK/models/A1099/V2/form1042_s.py new file mode 100644 index 0000000..a4ab92c --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1042_s.py @@ -0,0 +1,371 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.form1099_status_detail import Form1099StatusDetail +from Avalara.SDK.models.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough +from Avalara.SDK.models.A1099.V2.primary_withholding_agent import PrimaryWithholdingAgent +from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding +from Avalara.SDK.models.A1099.V2.state_efile_status_detail import StateEfileStatusDetail +from Avalara.SDK.models.A1099.V2.validation_error import ValidationError +from typing import Optional, Set +from typing_extensions import Self + +class Form1042S(BaseModel): + """ + Form1042S + """ # noqa: E501 + unique_form_id: Optional[StrictStr] = Field(default=None, alias="uniqueFormId") + recipient_date_of_birth: Optional[datetime] = Field(default=None, alias="recipientDateOfBirth") + recipient_giin: Optional[StrictStr] = Field(default=None, alias="recipientGiin") + recipient_foreign_tin: Optional[StrictStr] = Field(default=None, alias="recipientForeignTin") + lob_code: Optional[StrictStr] = Field(default=None, alias="lobCode") + income_code: Optional[StrictStr] = Field(default=None, alias="incomeCode") + gross_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="grossIncome") + withholding_indicator: Optional[StrictStr] = Field(default=None, alias="withholdingIndicator") + tax_country_code: Optional[StrictStr] = Field(default=None, alias="taxCountryCode") + exemption_code_chap3: Optional[StrictStr] = Field(default=None, alias="exemptionCodeChap3") + exemption_code_chap4: Optional[StrictStr] = Field(default=None, alias="exemptionCodeChap4") + tax_rate_chap3: Optional[StrictStr] = Field(default=None, alias="taxRateChap3") + withholding_allowance: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="withholdingAllowance") + federal_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalTaxWithheld") + tax_not_deposited_indicator: Optional[StrictBool] = Field(default=None, alias="taxNotDepositedIndicator") + academic_indicator: Optional[StrictBool] = Field(default=None, alias="academicIndicator") + tax_withheld_other_agents: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="taxWithheldOtherAgents") + amount_repaid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="amountRepaid") + tax_paid_agent: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="taxPaidAgent") + chap3_status_code: Optional[StrictStr] = Field(default=None, alias="chap3StatusCode") + chap4_status_code: Optional[StrictStr] = Field(default=None, alias="chap4StatusCode") + primary_withholding_agent: Optional[PrimaryWithholdingAgent] = Field(default=None, alias="primaryWithholdingAgent") + intermediary_or_flow_through: Optional[IntermediaryOrFlowThrough] = Field(default=None, alias="intermediaryOrFlowThrough") + id: Optional[StrictStr] = None + type: Optional[StrictStr] = None + issuer_id: Optional[StrictInt] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + federal_efile: Optional[StrictBool] = Field(default=None, alias="federalEfile") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, alias="federalEfileStatus") + state_efile: Optional[StrictBool] = Field(default=None, alias="stateEfile") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, alias="stateEfileStatus") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + email: Optional[StrictStr] = None + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") + tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1042S from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if tin_type (nullable) is None + # and model_fields_set contains the field + if self.tin_type is None and "tin_type" in self.model_fields_set: + _dict['tinType'] = None + + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + + # set to None if tin (nullable) is None + # and model_fields_set contains the field + if self.tin is None and "tin" in self.model_fields_set: + _dict['tin'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1042S from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "federalEfile": obj.get("federalEfile"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfile": obj.get("stateEfile"), + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMail": obj.get("postalMail"), + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatch": obj.get("tinMatch"), + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerification": obj.get("addressVerification"), + "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "referenceId": obj.get("referenceId"), + "email": obj.get("email"), + "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "recipientName": obj.get("recipientName"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_list.py b/Avalara/SDK/models/A1099/V2/form1042_s_list.py index e862457..585b672 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py b/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py index b714b54..9607059 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough from Avalara.SDK.models.A1099.V2.primary_withholding_agent import PrimaryWithholdingAgent from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest @@ -77,24 +76,25 @@ class Form1042SListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('lob_code') def lob_code_validate_enum(cls, value): @@ -208,6 +208,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -218,11 +223,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -243,6 +268,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -287,6 +317,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1042_s_list_item_response.py index 9fd2af2..2333e3a 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_request.py b/Avalara/SDK/models/A1099/V2/form1042_s_request.py index b875fb7..ea59b13 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_request.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.intermediary_or_flow_through_request import IntermediaryOrFlowThroughRequest from Avalara.SDK.models.A1099.V2.primary_withholding_agent_request import PrimaryWithholdingAgentRequest from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest @@ -78,24 +77,25 @@ class Form1042SRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -103,8 +103,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -169,6 +169,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -179,11 +184,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -204,6 +229,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -249,6 +279,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_response.py b/Avalara/SDK/models/A1099/V2/form1042_s_response.py index 698ae6a..e54be08 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_response.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -93,8 +93,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form1095_b.py b/Avalara/SDK/models/A1099/V2/form1095_b.py index 5fe2f91..66ce98d 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -66,10 +66,14 @@ class Form1095B(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -77,13 +81,15 @@ class Form1095B(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] model_config = ConfigDict( populate_by_name=True, @@ -143,6 +149,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -183,6 +192,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -198,11 +212,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -238,16 +262,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -286,10 +320,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -297,8 +335,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_list.py b/Avalara/SDK/models/A1099/V2/form1095_b_list.py index 12efa3e..8116382 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py b/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py index 6284438..49a6a7c 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.covered_individual_request import CoveredIndividualRequest from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set @@ -59,25 +58,26 @@ class Form1095BListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('origin_of_health_coverage_code') def origin_of_health_coverage_code_validate_enum(cls, value): @@ -151,6 +151,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -161,11 +166,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -186,6 +211,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -230,6 +260,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1095_b_list_item_response.py index b4df000..b26b04d 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_request.py b/Avalara/SDK/models/A1099/V2/form1095_b_request.py index 5923fed..389940f 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_request.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.covered_individual_request import CoveredIndividualRequest from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set @@ -60,25 +59,26 @@ class Form1095BRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('origin_of_health_coverage_code') def origin_of_health_coverage_code_validate_enum(cls, value): @@ -96,8 +96,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -162,6 +162,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -172,11 +177,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -197,6 +222,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -242,6 +272,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_response.py b/Avalara/SDK/models/A1099/V2/form1095_b_response.py new file mode 100644 index 0000000..d9c45b1 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1095_b_response.py @@ -0,0 +1,289 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.validation_error_response import ValidationErrorResponse +from typing import Optional, Set +from typing_extensions import Self + +class Form1095BResponse(BaseModel): + """ + Form1095BResponse + """ # noqa: E501 + employee_first_name: Optional[StrictStr] = Field(default=None, alias="employeeFirstName") + employee_middle_name: Optional[StrictStr] = Field(default=None, alias="employeeMiddleName") + employee_last_name: Optional[StrictStr] = Field(default=None, alias="employeeLastName") + employee_name_suffix: Optional[StrictStr] = Field(default=None, alias="employeeNameSuffix") + employee_date_of_birth: Optional[datetime] = Field(default=None, alias="employeeDateOfBirth") + origin_of_health_coverage_code: Optional[StrictStr] = Field(default=None, alias="originOfHealthCoverageCode") + covered_individuals: Optional[List[CoveredIndividualRequest]] = Field(default=None, alias="coveredIndividuals") + type: Optional[StrictStr] = None + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholdingResponse] = Field(default=None, alias="stateAndLocalWithholding") + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + id: Optional[StrictStr] = None + issuer_id: Optional[StrictStr] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_tin: Optional[StrictStr] = Field(default=None, alias="recipientTin") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + email: Optional[StrictStr] = None + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + federal_e_file: Optional[StrictBool] = Field(default=None, alias="federalEFile") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + state_e_file: Optional[StrictBool] = Field(default=None, alias="stateEFile") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + federal_efile_status: Optional[StatusDetail] = Field(default=None, alias="federalEfileStatus") + e_delivery_status: Optional[StatusDetail] = Field(default=None, alias="eDeliveryStatus") + state_efile_status: Optional[List[StateEfileStatusDetailResponse]] = Field(default=None, alias="stateEfileStatus") + postal_mail_status: Optional[StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match_status: Optional[StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification_status: Optional[StatusDetail] = Field(default=None, alias="addressVerificationStatus") + validation_errors: Optional[List[ValidationErrorResponse]] = Field(default=None, alias="validationErrors") + __properties: ClassVar[List[str]] = ["type", "createdAt", "updatedAt", "stateAndLocalWithholding", "tinType", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "recipientName", "recipientTin", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "federalEfileStatus", "eDeliveryStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "validationErrors"] + + @field_validator('origin_of_health_coverage_code') + def origin_of_health_coverage_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['A', 'B', 'C', 'D', 'E', 'F', 'G']): + raise ValueError("must be one of enum values ('A', 'B', 'C', 'D', 'E', 'F', 'G')") + return value + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") + return value + + @field_validator('tin_type') + def tin_type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1095BResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "type", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # set to None if federal_efile_status (nullable) is None + # and model_fields_set contains the field + if self.federal_efile_status is None and "federal_efile_status" in self.model_fields_set: + _dict['federalEfileStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1095BResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "type": obj.get("type"), + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholdingResponse.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "tinType": obj.get("tinType"), + "id": obj.get("id"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "referenceId": obj.get("referenceId"), + "recipientName": obj.get("recipientName"), + "recipientTin": obj.get("recipientTin"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "email": obj.get("email"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEFile": obj.get("federalEFile"), + "postalMail": obj.get("postalMail"), + "stateEFile": obj.get("stateEFile"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "addressVerification": obj.get("addressVerification"), + "federalEfileStatus": StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "eDeliveryStatus": StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetailResponse.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerificationStatus": StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "validationErrors": [ValidationErrorResponse.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1095_c_list.py b/Avalara/SDK/models/A1099/V2/form1095_c_list.py index 6e108d1..fe92046 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py b/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py index 547bb5b..bff40cb 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.covered_individual_request import CoveredIndividualRequest from Avalara.SDK.models.A1099.V2.offer_and_coverage_request import OfferAndCoverageRequest from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest @@ -65,25 +64,26 @@ class Form1095CListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -137,6 +137,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -147,6 +157,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -157,11 +172,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -182,6 +217,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -229,6 +269,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_base.py b/Avalara/SDK/models/A1099/V2/form1099_base.py index ca0fcd2..72c31a6 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_base.py +++ b/Avalara/SDK/models/A1099/V2/form1099_base.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -63,10 +63,14 @@ class Form1099Base(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -74,13 +78,15 @@ class Form1099Base(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] model_config = ConfigDict( populate_by_name=True, @@ -140,6 +146,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -180,6 +189,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -195,11 +209,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -235,16 +259,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -283,10 +317,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -294,8 +332,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1099_base_response.py b/Avalara/SDK/models/A1099/V2/form1099_base_response.py index 86474bc..1dceb2b 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_base_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_base_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_div.py b/Avalara/SDK/models/A1099/V2/form1099_div.py new file mode 100644 index 0000000..161c726 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_div.py @@ -0,0 +1,364 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.form1099_status_detail import Form1099StatusDetail +from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding +from Avalara.SDK.models.A1099.V2.state_efile_status_detail import StateEfileStatusDetail +from Avalara.SDK.models.A1099.V2.validation_error import ValidationError +from typing import Optional, Set +from typing_extensions import Self + +class Form1099Div(BaseModel): + """ + Form1099Div + """ # noqa: E501 + total_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalOrdinaryDividends") + qualified_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="qualifiedDividends") + total_capital_gain_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalCapitalGainDistributions") + unrecaptured_section1250_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="unrecapturedSection1250Gain") + section1202_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section1202Gain") + collectibles_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="collectiblesGain") + section897_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section897OrdinaryDividends") + section897_capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section897CapitalGain") + nondividend_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="nondividendDistributions") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalIncomeTaxWithheld") + section199_a_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section199ADividends") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="foreignTaxPaid") + foreign_country_or_us_possession: Optional[StrictStr] = Field(default=None, alias="foreignCountryOrUSPossession") + cash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="cashLiquidationDistributions") + noncash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="noncashLiquidationDistributions") + exempt_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="exemptInterestDividends") + specified_private_activity_bond_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="specifiedPrivateActivityBondInterestDividends") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") + id: Optional[StrictStr] = None + type: Optional[StrictStr] = None + issuer_id: Optional[StrictInt] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + federal_efile: Optional[StrictBool] = Field(default=None, alias="federalEfile") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, alias="federalEfileStatus") + state_efile: Optional[StrictBool] = Field(default=None, alias="stateEfile") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, alias="stateEfileStatus") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + email: Optional[StrictStr] = None + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099Div from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if tin_type (nullable) is None + # and model_fields_set contains the field + if self.tin_type is None and "tin_type" in self.model_fields_set: + _dict['tinType'] = None + + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + + # set to None if tin (nullable) is None + # and model_fields_set contains the field + if self.tin is None and "tin" in self.model_fields_set: + _dict['tin'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099Div from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "federalEfile": obj.get("federalEfile"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfile": obj.get("stateEfile"), + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMail": obj.get("postalMail"), + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatch": obj.get("tinMatch"), + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerification": obj.get("addressVerification"), + "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "referenceId": obj.get("referenceId"), + "email": obj.get("email"), + "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "recipientName": obj.get("recipientName"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_list.py b/Avalara/SDK/models/A1099/V2/form1099_div_list.py index e98c7f0..77f39b2 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py index 751e4e2..4761236 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,9 +33,8 @@ import re # noqa: F401 import json -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator -from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -44,24 +43,24 @@ class Form1099DivListItem(BaseModel): """ Form1099DivListItem """ # noqa: E501 - total_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") - qualified_dividends: Optional[StrictStr] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") - total_capital_gain_distributions: Optional[StrictStr] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") - unrecaptured_section1250_gain: Optional[StrictStr] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") - section1202_gain: Optional[StrictStr] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") - collectibles_gain: Optional[StrictStr] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") - section897_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") - section897_capital_gain: Optional[StrictStr] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") - nondividend_distributions: Optional[StrictStr] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") - federal_income_tax_withheld: Optional[StrictStr] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") - section199_a_dividends: Optional[StrictStr] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") - investment_expenses: Optional[StrictStr] = Field(default=None, description="Investment expenses", alias="investmentExpenses") - foreign_tax_paid: Optional[StrictStr] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + total_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") + qualified_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") + total_capital_gain_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") + unrecaptured_section1250_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") + section1202_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") + collectibles_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") + section897_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") + section897_capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") + nondividend_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + section199_a_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") foreign_country_or_us_possession: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountryOrUSPossession") - cash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") - noncash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") - exempt_interest_dividends: Optional[StrictStr] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") - specified_private_activity_bond_interest_dividends: Optional[StrictStr] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") + cash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") + noncash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") + exempt_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") + specified_private_activity_bond_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID. One of `issuerReferenceId` or `issuerTin` is required.", alias="issuerReferenceId") issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN. One of `issuerReferenceId` or `issuerTin` is required.", alias="issuerTin") @@ -72,16 +71,16 @@ class Form1099DivListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -90,7 +89,7 @@ class Form1099DivListItem(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -144,6 +143,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -154,6 +163,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -164,11 +178,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -189,6 +223,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -236,6 +275,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_div_list_item_response.py index d339f95..5ff6c60 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -34,8 +34,8 @@ import json from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr -from typing import Any, ClassVar, Dict, List, Optional +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse @@ -48,24 +48,24 @@ class Form1099DivListItemResponse(BaseModel): """ Form1099DivListItemResponse """ # noqa: E501 - total_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") - qualified_dividends: Optional[StrictStr] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") - total_capital_gain_distributions: Optional[StrictStr] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") - unrecaptured_section1250_gain: Optional[StrictStr] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") - section1202_gain: Optional[StrictStr] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") - collectibles_gain: Optional[StrictStr] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") - section897_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") - section897_capital_gain: Optional[StrictStr] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") - nondividend_distributions: Optional[StrictStr] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") - federal_income_tax_withheld: Optional[StrictStr] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") - section199_a_dividends: Optional[StrictStr] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") - investment_expenses: Optional[StrictStr] = Field(default=None, description="Investment expenses", alias="investmentExpenses") - foreign_tax_paid: Optional[StrictStr] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + total_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") + qualified_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") + total_capital_gain_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") + unrecaptured_section1250_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") + section1202_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") + collectibles_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") + section897_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") + section897_capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") + nondividend_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + section199_a_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") foreign_country_or_us_possession: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountryOrUSPossession") - cash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") - noncash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") - exempt_interest_dividends: Optional[StrictStr] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") - specified_private_activity_bond_interest_dividends: Optional[StrictStr] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") + cash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") + noncash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") + exempt_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") + specified_private_activity_bond_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="ID of the form") type: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC") diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_request.py b/Avalara/SDK/models/A1099/V2/form1099_div_request.py index c3c3c3d..4e2aa6d 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,9 +33,8 @@ import re # noqa: F401 import json -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator -from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -44,24 +43,24 @@ class Form1099DivRequest(BaseModel): """ Form1099DivRequest """ # noqa: E501 - total_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") - qualified_dividends: Optional[StrictStr] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") - total_capital_gain_distributions: Optional[StrictStr] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") - unrecaptured_section1250_gain: Optional[StrictStr] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") - section1202_gain: Optional[StrictStr] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") - collectibles_gain: Optional[StrictStr] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") - section897_ordinary_dividends: Optional[StrictStr] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") - section897_capital_gain: Optional[StrictStr] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") - nondividend_distributions: Optional[StrictStr] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") - federal_income_tax_withheld: Optional[StrictStr] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") - section199_a_dividends: Optional[StrictStr] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") - investment_expenses: Optional[StrictStr] = Field(default=None, description="Investment expenses", alias="investmentExpenses") - foreign_tax_paid: Optional[StrictStr] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + total_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total ordinary dividends", alias="totalOrdinaryDividends") + qualified_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Qualified dividends", alias="qualifiedDividends") + total_capital_gain_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total capital gain distributions", alias="totalCapitalGainDistributions") + unrecaptured_section1250_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Unrecaptured Section 1250 gain", alias="unrecapturedSection1250Gain") + section1202_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 1202 gain", alias="section1202Gain") + collectibles_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Collectibles (28%) gain", alias="collectiblesGain") + section897_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 ordinary dividends", alias="section897OrdinaryDividends") + section897_capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 897 capital gain", alias="section897CapitalGain") + nondividend_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Nondividend distributions", alias="nondividendDistributions") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + section199_a_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 199A dividends", alias="section199ADividends") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") foreign_country_or_us_possession: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountryOrUSPossession") - cash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") - noncash_liquidation_distributions: Optional[StrictStr] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") - exempt_interest_dividends: Optional[StrictStr] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") - specified_private_activity_bond_interest_dividends: Optional[StrictStr] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") + cash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Cash liquidation distributions", alias="cashLiquidationDistributions") + noncash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Noncash liquidation distributions", alias="noncashLiquidationDistributions") + exempt_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Exempt-interest dividends", alias="exemptInterestDividends") + specified_private_activity_bond_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified private activity bond interest dividends", alias="specifiedPrivateActivityBondInterestDividends") fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") type: Optional[StrictStr] = None issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID", alias="issuerId") @@ -70,16 +69,16 @@ class Form1099DivRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -88,7 +87,7 @@ class Form1099DivRequest(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -96,8 +95,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -162,6 +161,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -172,11 +176,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -197,6 +221,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -242,6 +271,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_response.py b/Avalara/SDK/models/A1099/V2/form1099_div_response.py index c6ce4c0..aefde76 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -34,8 +34,8 @@ import json from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator -from typing import Any, ClassVar, Dict, List, Optional +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse from Avalara.SDK.models.A1099.V2.status_detail import StatusDetail @@ -47,6 +47,25 @@ class Form1099DivResponse(BaseModel): """ Form1099DivResponse """ # noqa: E501 + total_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalOrdinaryDividends") + qualified_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="qualifiedDividends") + total_capital_gain_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalCapitalGainDistributions") + unrecaptured_section1250_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="unrecapturedSection1250Gain") + section1202_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section1202Gain") + collectibles_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="collectiblesGain") + section897_ordinary_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section897OrdinaryDividends") + section897_capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section897CapitalGain") + nondividend_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="nondividendDistributions") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalIncomeTaxWithheld") + section199_a_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section199ADividends") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="foreignTaxPaid") + foreign_country_or_us_possession: Optional[StrictStr] = Field(default=None, alias="foreignCountryOrUSPossession") + cash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="cashLiquidationDistributions") + noncash_liquidation_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="noncashLiquidationDistributions") + exempt_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="exemptInterestDividends") + specified_private_activity_bond_interest_dividends: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="specifiedPrivateActivityBondInterestDividends") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") type: Optional[StrictStr] = None created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") @@ -93,8 +112,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form1099_int.py b/Avalara/SDK/models/A1099/V2/form1099_int.py new file mode 100644 index 0000000..dc1b1d2 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int.py @@ -0,0 +1,360 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.form1099_status_detail import Form1099StatusDetail +from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding +from Avalara.SDK.models.A1099.V2.state_efile_status_detail import StateEfileStatusDetail +from Avalara.SDK.models.A1099.V2.validation_error import ValidationError +from typing import Optional, Set +from typing_extensions import Self + +class Form1099Int(BaseModel): + """ + Form1099Int + """ # noqa: E501 + interest_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="interestIncome") + early_withdrawal_penalty: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="earlyWithdrawalPenalty") + us_savings_bonds_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="usSavingsBondsInterest") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalIncomeTaxWithheld") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="foreignTaxPaid") + foreign_country: Optional[StrictStr] = Field(default=None, alias="foreignCountry") + tax_exempt_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="taxExemptInterest") + specified_private_activity_bond_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="specifiedPrivateActivityBondInterest") + market_discount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="marketDiscount") + bond_premium: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="bondPremium") + bond_premium_on_treasury_obligations: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="bondPremiumOnTreasuryObligations") + bond_premium_on_tax_exempt_bond: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="bondPremiumOnTaxExemptBond") + tax_exempt_bond_cusip_number: Optional[StrictStr] = Field(default=None, alias="taxExemptBondCusipNumber") + id: Optional[StrictStr] = None + type: Optional[StrictStr] = None + issuer_id: Optional[StrictInt] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + federal_efile: Optional[StrictBool] = Field(default=None, alias="federalEfile") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, alias="federalEfileStatus") + state_efile: Optional[StrictBool] = Field(default=None, alias="stateEfile") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, alias="stateEfileStatus") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + email: Optional[StrictStr] = None + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") + tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099Int from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if tin_type (nullable) is None + # and model_fields_set contains the field + if self.tin_type is None and "tin_type" in self.model_fields_set: + _dict['tinType'] = None + + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + + # set to None if tin (nullable) is None + # and model_fields_set contains the field + if self.tin is None and "tin" in self.model_fields_set: + _dict['tin'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099Int from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "federalEfile": obj.get("federalEfile"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfile": obj.get("stateEfile"), + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMail": obj.get("postalMail"), + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatch": obj.get("tinMatch"), + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerification": obj.get("addressVerification"), + "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "referenceId": obj.get("referenceId"), + "email": obj.get("email"), + "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "recipientName": obj.get("recipientName"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list.py b/Avalara/SDK/models/A1099/V2/form1099_int_list.py new file mode 100644 index 0000000..0f83219 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.form1099_int_list_item import Form1099IntListItem +from typing import Optional, Set +from typing_extensions import Self + +class Form1099IntList(BaseModel): + """ + Form1099IntList + """ # noqa: E501 + forms: Optional[List[Form1099IntListItem]] = None + form_type: Optional[StrictStr] = Field(default=None, alias="formType") + __properties: ClassVar[List[str]] = ["formType"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099IntList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099IntList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "formType": obj.get("formType") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py new file mode 100644 index 0000000..c40ce48 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py @@ -0,0 +1,280 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from typing import Optional, Set +from typing_extensions import Self + +class Form1099IntListItem(BaseModel): + """ + Form1099IntListItem + """ # noqa: E501 + interest_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest Income", alias="interestIncome") + early_withdrawal_penalty: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Early Withdrawal Penalty", alias="earlyWithdrawalPenalty") + us_savings_bonds_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest on U.S. Savings Bonds and Treasury obligations", alias="usSavingsBondsInterest") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment Expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + foreign_country: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountry") + tax_exempt_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax-Exempt Interest", alias="taxExemptInterest") + specified_private_activity_bond_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified Private activity", alias="specifiedPrivateActivityBondInterest") + market_discount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Market Discount", alias="marketDiscount") + bond_premium: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium", alias="bondPremium") + bond_premium_on_treasury_obligations: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on Treasury obligations", alias="bondPremiumOnTreasuryObligations") + bond_premium_on_tax_exempt_bond: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on tax exempt bond", alias="bondPremiumOnTaxExemptBond") + tax_exempt_bond_cusip_number: Optional[StrictStr] = Field(default=None, description="Tax exempt bond CUSIP no.", alias="taxExemptBondCusipNumber") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID. One of `issuerReferenceId` or `issuerTin` is required.", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN. One of `issuerReferenceId` or `issuerTin` is required.", alias="issuerTin") + tax_year: StrictInt = Field(description="Tax year", alias="taxYear") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID", alias="issuerId") + reference_id: Optional[StrictStr] = Field(default=None, description="Reference ID", alias="referenceId") + recipient_tin: Optional[StrictStr] = Field(default=None, description="Recipient Tax ID Number", alias="recipientTin") + recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(default=None, description="Address") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2") + city: Optional[StrictStr] = Field(default=None, description="City") + state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") + zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") + email: Optional[StrictStr] = Field(default=None, description="Recipient email address") + account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") + non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") + postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") + state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") + tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") + no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") + address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") + state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] + + @field_validator('tin_type') + def tin_type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099IntListItem from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + + # set to None if issuer_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_id is None and "issuer_id" in self.model_fields_set: + _dict['issuerId'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099IntListItem from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "issuerId": obj.get("issuerId"), + "referenceId": obj.get("referenceId"), + "recipientTin": obj.get("recipientTin"), + "recipientName": obj.get("recipientName"), + "tinType": obj.get("tinType"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "email": obj.get("email"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEFile": obj.get("federalEFile"), + "postalMail": obj.get("postalMail"), + "stateEFile": obj.get("stateEFile"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py new file mode 100644 index 0000000..bd9c732 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py @@ -0,0 +1,381 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.validation_error_response import ValidationErrorResponse +from typing import Optional, Set +from typing_extensions import Self + +class Form1099IntListItemResponse(BaseModel): + """ + Form1099IntListItemResponse + """ # noqa: E501 + interest_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest Income", alias="interestIncome") + early_withdrawal_penalty: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Early withdrawal penalty", alias="earlyWithdrawalPenalty") + us_savings_bonds_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest on U.S. Savings Bonds and Treasury obligations", alias="usSavingsBondsInterest") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + foreign_country: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountry") + tax_exempt_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax-exempt interest", alias="taxExemptInterest") + specified_private_activity_bond_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified private activity bond interest", alias="specifiedPrivateActivityBondInterest") + market_discount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Market discount", alias="marketDiscount") + bond_premium: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond premium", alias="bondPremium") + bond_premium_on_treasury_obligations: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond premium on Treasury obligations", alias="bondPremiumOnTreasuryObligations") + bond_premium_on_tax_exempt_bond: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond premium on tax exempt bond", alias="bondPremiumOnTaxExemptBond") + tax_exempt_bond_cusip_number: Optional[StrictStr] = Field(default=None, description="Tax exempt bond CUSIP number", alias="taxExemptBondCusipNumber") + id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="ID of the form") + type: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC") + issuer_id: StrictInt = Field(description="Issuer ID", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax year", alias="taxYear") + federal_efile: StrictBool = Field(description="Boolean indicating that federal e-filing has been scheduled for this form", alias="federalEfile") + federal_efile_status: Optional[StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile: StrictBool = Field(description="Boolean indicating that state e-filing has been scheduled for this form", alias="stateEfile") + state_efile_status: Optional[List[StateEfileStatusDetailResponse]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail: StrictBool = Field(description="Boolean indicating that postal mailing to the recipient has been scheduled for this form", alias="postalMail") + postal_mail_status: Optional[StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match: StrictBool = Field(description="Boolean indicating that TIN Matching has been scheduled for this form", alias="tinMatch") + tin_match_status: Optional[StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification: StrictBool = Field(description="Boolean indicating that address verification has been scheduled for this form", alias="addressVerification") + address_verification_status: Optional[StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + reference_id: Optional[StrictStr] = Field(default=None, description="Reference ID", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="Recipient email address") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") + tin: Optional[StrictStr] = Field(default=None, description="Recipient Tax ID Number") + no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second Tin Notice", alias="secondTinNotice") + recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(default=None, description="Address") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2") + city: Optional[StrictStr] = Field(default=None, description="City") + state: Optional[StrictStr] = Field(default=None, description="US state") + zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") + non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, description="Account Number", alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, description="Office Code", alias="officeCode") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") + validation_errors: Optional[List[ValidationErrorResponse]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Creation time", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Update time", alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholdingResponse] = Field(default=None, alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "fatcaFilingRequirement", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099IntListItemResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "federal_efile_status", + "state_efile_status", + "postal_mail_status", + "tin_match_status", + "address_verification_status", + "e_delivery_status", + "validation_errors", + "created_at", + "updated_at", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if tin_type (nullable) is None + # and model_fields_set contains the field + if self.tin_type is None and "tin_type" in self.model_fields_set: + _dict['tinType'] = None + + # set to None if tin (nullable) is None + # and model_fields_set contains the field + if self.tin is None and "tin" in self.model_fields_set: + _dict['tin'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099IntListItemResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "federalEfile": obj.get("federalEfile"), + "federalEfileStatus": StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfile": obj.get("stateEfile"), + "stateEfileStatus": [StateEfileStatusDetailResponse.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMail": obj.get("postalMail"), + "postalMailStatus": StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatch": obj.get("tinMatch"), + "tinMatchStatus": StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerification": obj.get("addressVerification"), + "addressVerificationStatus": StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "referenceId": obj.get("referenceId"), + "email": obj.get("email"), + "tinType": obj.get("tinType"), + "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "recipientName": obj.get("recipientName"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "validationErrors": [ValidationErrorResponse.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholdingResponse.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_request.py b/Avalara/SDK/models/A1099/V2/form1099_int_request.py new file mode 100644 index 0000000..ce4265b --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int_request.py @@ -0,0 +1,276 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from typing import Optional, Set +from typing_extensions import Self + +class Form1099IntRequest(BaseModel): + """ + Form1099IntRequest + """ # noqa: E501 + interest_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest Income", alias="interestIncome") + early_withdrawal_penalty: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Early Withdrawl Penalty", alias="earlyWithdrawalPenalty") + us_savings_bonds_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest on U.S. Savings Bonds and Treasury obligations", alias="usSavingsBondsInterest") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment Expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + foreign_country: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountry") + tax_exempt_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax-Exempt Interest", alias="taxExemptInterest") + specified_private_activity_bond_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified Private activity", alias="specifiedPrivateActivityBondInterest") + market_discount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Market Discount", alias="marketDiscount") + bond_premium: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium", alias="bondPremium") + bond_premium_on_treasury_obligations: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on Treasury obligations", alias="bondPremiumOnTreasuryObligations") + bond_premium_on_tax_exempt_bond: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on tax exempt bond", alias="bondPremiumOnTaxExemptBond") + tax_exempt_bond_cusip_number: Optional[StrictStr] = Field(default=None, description="Tax exempt bond CUSIP no.", alias="taxExemptBondCusipNumber") + type: Optional[StrictStr] = None + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID", alias="issuerId") + reference_id: Optional[StrictStr] = Field(default=None, description="Reference ID", alias="referenceId") + recipient_tin: Optional[StrictStr] = Field(default=None, description="Recipient Tax ID Number", alias="recipientTin") + recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(default=None, description="Address") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2") + city: Optional[StrictStr] = Field(default=None, description="City") + state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") + zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") + email: Optional[StrictStr] = Field(default=None, description="Recipient email address") + account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") + non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") + postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") + state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") + tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") + no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") + address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") + state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") + return value + + @field_validator('tin_type') + def tin_type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099IntRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_id is None and "issuer_id" in self.model_fields_set: + _dict['issuerId'] = None + + # set to None if reference_id (nullable) is None + # and model_fields_set contains the field + if self.reference_id is None and "reference_id" in self.model_fields_set: + _dict['referenceId'] = None + + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + + # set to None if recipient_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_name is None and "recipient_name" in self.model_fields_set: + _dict['recipientName'] = None + + # set to None if recipient_second_name (nullable) is None + # and model_fields_set contains the field + if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: + _dict['recipientSecondName'] = None + + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + + # set to None if address2 (nullable) is None + # and model_fields_set contains the field + if self.address2 is None and "address2" in self.model_fields_set: + _dict['address2'] = None + + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + + # set to None if non_us_province (nullable) is None + # and model_fields_set contains the field + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None + + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + + # set to None if state_and_local_withholding (nullable) is None + # and model_fields_set contains the field + if self.state_and_local_withholding is None and "state_and_local_withholding" in self.model_fields_set: + _dict['stateAndLocalWithholding'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099IntRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "type": obj.get("type"), + "issuerId": obj.get("issuerId"), + "referenceId": obj.get("referenceId"), + "recipientTin": obj.get("recipientTin"), + "recipientName": obj.get("recipientName"), + "tinType": obj.get("tinType"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "email": obj.get("email"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEFile": obj.get("federalEFile"), + "postalMail": obj.get("postalMail"), + "stateEFile": obj.get("stateEFile"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_response.py b/Avalara/SDK/models/A1099/V2/form1099_int_response.py new file mode 100644 index 0000000..9982f3d --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_int_response.py @@ -0,0 +1,285 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.validation_error_response import ValidationErrorResponse +from typing import Optional, Set +from typing_extensions import Self + +class Form1099IntResponse(BaseModel): + """ + Form1099IntResponse + """ # noqa: E501 + interest_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest Income", alias="interestIncome") + early_withdrawal_penalty: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Early Withdrawal Penalty", alias="earlyWithdrawalPenalty") + us_savings_bonds_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Interest on U.S. Savings Bonds and Treasury obligations", alias="usSavingsBondsInterest") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + investment_expenses: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Investment Expenses", alias="investmentExpenses") + foreign_tax_paid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Foreign tax paid", alias="foreignTaxPaid") + foreign_country: Optional[StrictStr] = Field(default=None, description="Foreign country or U.S. possession", alias="foreignCountry") + tax_exempt_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax-Exempt Interest", alias="taxExemptInterest") + specified_private_activity_bond_interest: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Specified Private activity", alias="specifiedPrivateActivityBondInterest") + market_discount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Market Discount", alias="marketDiscount") + bond_premium: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium", alias="bondPremium") + bond_premium_on_treasury_obligations: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on Treasury obligations", alias="bondPremiumOnTreasuryObligations") + bond_premium_on_tax_exempt_bond: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Bond Premium on tax exempt bond", alias="bondPremiumOnTaxExemptBond") + tax_exempt_bond_cusip_number: Optional[StrictStr] = Field(default=None, description="Tax exempt bond CUSIP no.", alias="taxExemptBondCusipNumber") + type: Optional[StrictStr] = None + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholdingResponse] = Field(default=None, alias="stateAndLocalWithholding") + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + id: Optional[StrictStr] = None + issuer_id: Optional[StrictStr] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_tin: Optional[StrictStr] = Field(default=None, alias="recipientTin") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + email: Optional[StrictStr] = None + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + federal_e_file: Optional[StrictBool] = Field(default=None, alias="federalEFile") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + state_e_file: Optional[StrictBool] = Field(default=None, alias="stateEFile") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + federal_efile_status: Optional[StatusDetail] = Field(default=None, alias="federalEfileStatus") + e_delivery_status: Optional[StatusDetail] = Field(default=None, alias="eDeliveryStatus") + state_efile_status: Optional[List[StateEfileStatusDetailResponse]] = Field(default=None, alias="stateEfileStatus") + postal_mail_status: Optional[StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match_status: Optional[StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification_status: Optional[StatusDetail] = Field(default=None, alias="addressVerificationStatus") + validation_errors: Optional[List[ValidationErrorResponse]] = Field(default=None, alias="validationErrors") + __properties: ClassVar[List[str]] = ["type", "createdAt", "updatedAt", "stateAndLocalWithholding", "tinType", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "recipientName", "recipientTin", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "federalEfileStatus", "eDeliveryStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "validationErrors"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") + return value + + @field_validator('tin_type') + def tin_type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099IntResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "type", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # set to None if federal_efile_status (nullable) is None + # and model_fields_set contains the field + if self.federal_efile_status is None and "federal_efile_status" in self.model_fields_set: + _dict['federalEfileStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099IntResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "type": obj.get("type"), + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholdingResponse.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "tinType": obj.get("tinType"), + "id": obj.get("id"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "referenceId": obj.get("referenceId"), + "recipientName": obj.get("recipientName"), + "recipientTin": obj.get("recipientTin"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "email": obj.get("email"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEFile": obj.get("federalEFile"), + "postalMail": obj.get("postalMail"), + "stateEFile": obj.get("stateEFile"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "addressVerification": obj.get("addressVerification"), + "federalEfileStatus": StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "eDeliveryStatus": StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetailResponse.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerificationStatus": StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "validationErrors": [ValidationErrorResponse.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_k.py b/Avalara/SDK/models/A1099/V2/form1099_k.py index 2cc819f..6199607 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -83,10 +83,14 @@ class Form1099K(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -94,13 +98,15 @@ class Form1099K(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] @field_validator('filer_type') def filer_type_validate_enum(cls, value): @@ -180,6 +186,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -220,6 +229,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -235,11 +249,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -275,16 +299,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -323,10 +357,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -334,8 +372,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_list.py b/Avalara/SDK/models/A1099/V2/form1099_k_list.py index 4182219..0b9b215 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py index 39eeeeb..bd8c455 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -73,25 +72,26 @@ class Form1099KListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('filer_type') def filer_type_validate_enum(cls, value): @@ -165,6 +165,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -175,6 +185,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -185,11 +200,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -210,6 +245,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -257,6 +297,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_k_list_item_response.py index b2147e1..9660bf9 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_request.py b/Avalara/SDK/models/A1099/V2/form1099_k_request.py index 037d03a..cc6aae6 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -71,25 +70,26 @@ class Form1099KRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('filer_type') def filer_type_validate_enum(cls, value): @@ -117,8 +117,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -183,6 +183,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -193,11 +198,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -218,6 +243,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -263,6 +293,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_response.py b/Avalara/SDK/models/A1099/V2/form1099_k_response.py index c90ee2b..eb48a2b 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -133,8 +133,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form1099_list_response.py b/Avalara/SDK/models/A1099/V2/form1099_list_response.py index a3706c0..d988a94 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_list_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_list_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_list_response_value_inner.py b/Avalara/SDK/models/A1099/V2/form1099_list_response_value_inner.py index b1741e7..0cfa497 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_list_response_value_inner.py +++ b/Avalara/SDK/models/A1099/V2/form1099_list_response_value_inner.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -37,6 +37,7 @@ from Avalara.SDK.models.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse from Avalara.SDK.models.A1099.V2.form1099_base_response import Form1099BaseResponse from Avalara.SDK.models.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse from Avalara.SDK.models.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse from Avalara.SDK.models.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse from Avalara.SDK.models.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse @@ -45,7 +46,7 @@ from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -FORM1099LISTRESPONSEVALUEINNER_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] +FORM1099LISTRESPONSEVALUEINNER_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] class Form1099ListResponseValueInner(BaseModel): """ @@ -59,16 +60,18 @@ class Form1099ListResponseValueInner(BaseModel): oneof_schema_3_validator: Optional[Form1095BListItemResponse] = None # data type: Form1099DivListItemResponse oneof_schema_4_validator: Optional[Form1099DivListItemResponse] = None + # data type: Form1099IntListItemResponse + oneof_schema_5_validator: Optional[Form1099IntListItemResponse] = None # data type: Form1099KListItemResponse - oneof_schema_5_validator: Optional[Form1099KListItemResponse] = None + oneof_schema_6_validator: Optional[Form1099KListItemResponse] = None # data type: Form1099MiscListItemResponse - oneof_schema_6_validator: Optional[Form1099MiscListItemResponse] = None + oneof_schema_7_validator: Optional[Form1099MiscListItemResponse] = None # data type: Form1099NecListItemResponse - oneof_schema_7_validator: Optional[Form1099NecListItemResponse] = None + oneof_schema_8_validator: Optional[Form1099NecListItemResponse] = None # data type: Form1099RListItemResponse - oneof_schema_8_validator: Optional[Form1099RListItemResponse] = None - actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None - one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } + oneof_schema_9_validator: Optional[Form1099RListItemResponse] = None + actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None + one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } model_config = ConfigDict( validate_assignment=True, @@ -111,6 +114,11 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivListItemResponse`") else: match += 1 + # validate data type: Form1099IntListItemResponse + if not isinstance(v, Form1099IntListItemResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntListItemResponse`") + else: + match += 1 # validate data type: Form1099KListItemResponse if not isinstance(v, Form1099KListItemResponse): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KListItemResponse`") @@ -133,10 +141,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return v @@ -175,6 +183,12 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099IntListItemResponse + try: + instance.actual_instance = Form1099IntListItemResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099KListItemResponse try: instance.actual_instance = Form1099KListItemResponse.from_json(json_str) @@ -202,10 +216,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into Form1099ListResponseValueInner with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return instance @@ -219,7 +233,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc.py b/Avalara/SDK/models/A1099/V2/form1099_misc.py index b9451c8..475f85f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -52,15 +52,15 @@ class Form1099Misc(BaseModel): other_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="otherIncome") fed_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="fedIncomeTaxWithheld") fishing_boat_proceeds: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="fishingBoatProceeds") - medical_and_health_care: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="medicalAndHealthCare") - nonemployee_compensation: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="nonemployeeCompensation") + medical_and_health_care_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="medicalAndHealthCarePayments") substitute_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="substitutePayments") direct_sales_indicator: Optional[StrictBool] = Field(default=None, alias="directSalesIndicator") crop_insurance_proceeds: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="cropInsuranceProceeds") - excess_golden_parachute: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="excessGoldenParachute") - gross_amount_paid_attorney: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="grossAmountPaidAttorney") + excess_golden_parachute_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="excessGoldenParachutePayments") + gross_proceeds_paid_to_attorney: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="grossProceedsPaidToAttorney") + fish_purchased_for_resale: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="fishPurchasedForResale") section409_a_deferrals: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section409ADeferrals") - section409_a_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="section409AIncome") + nonqualified_deferred_compensation: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="nonqualifiedDeferredCompensation") id: Optional[StrictStr] = None type: Optional[StrictStr] = None issuer_id: Optional[StrictInt] = Field(default=None, alias="issuerId") @@ -77,10 +77,14 @@ class Form1099Misc(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -88,13 +92,15 @@ class Form1099Misc(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] model_config = ConfigDict( populate_by_name=True, @@ -154,6 +160,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -194,6 +203,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -209,11 +223,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -249,16 +273,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -297,10 +331,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -308,8 +346,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_list.py b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py index 482736f..324ee21 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py index fcc4541..d1ce0ff 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -68,16 +67,16 @@ class Form1099MiscListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -86,7 +85,7 @@ class Form1099MiscListItem(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -140,6 +139,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -150,6 +159,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -160,11 +174,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -185,6 +219,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -232,6 +271,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item_response.py index e1eb179..30db98c 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py index 3a53987..7927879 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -66,16 +65,16 @@ class Form1099MiscRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -84,7 +83,7 @@ class Form1099MiscRequest(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -92,8 +91,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -158,6 +157,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -168,11 +172,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -193,6 +217,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -238,6 +267,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py index 47acf4a..f72fe5b 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -108,8 +108,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec.py b/Avalara/SDK/models/A1099/V2/form1099_nec.py index 0fb0fa9..b5dc1b4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -66,10 +66,14 @@ class Form1099Nec(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -77,13 +81,15 @@ class Form1099Nec(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] model_config = ConfigDict( populate_by_name=True, @@ -143,6 +149,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -183,6 +192,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -198,11 +212,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -238,16 +262,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -286,10 +320,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -297,8 +335,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py index 7dbe137..7b5da5d 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py index fa96192..7684c42 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -56,25 +55,26 @@ class Form1099NecListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -128,6 +128,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -138,6 +148,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -148,11 +163,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -173,6 +208,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -220,6 +260,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item_response.py index 9e4280b..aa66f55 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py index 3a203e7..f94418f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -54,25 +53,26 @@ class Form1099NecRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -80,8 +80,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -146,6 +146,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -156,11 +161,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -181,6 +206,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -226,6 +256,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py index c33707f..800d7e4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -96,8 +96,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py index 3b1d92f..0be1168 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py +++ b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List, Optional from Avalara.SDK.models.A1099.V2.data import Data +from Avalara.SDK.models.A1099.V2.form1099_proccess_result_processed_forms_inner import Form1099ProccessResultProcessedFormsInner from typing import Optional, Set from typing_extensions import Self @@ -44,7 +45,8 @@ class Form1099ProccessResult(BaseModel): Form1099ProccessResult """ # noqa: E501 job_data: Optional[Data] = Field(default=None, alias="jobData") - __properties: ClassVar[List[str]] = ["jobData"] + processed_forms: Optional[List[Form1099ProccessResultProcessedFormsInner]] = Field(default=None, alias="processedForms") + __properties: ClassVar[List[str]] = ["jobData", "processedForms"] model_config = ConfigDict( populate_by_name=True, @@ -88,6 +90,18 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of job_data if self.job_data: _dict['jobData'] = self.job_data.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in processed_forms (list) + _items = [] + if self.processed_forms: + for _item in self.processed_forms: + if _item: + _items.append(_item.to_dict()) + _dict['processedForms'] = _items + # set to None if processed_forms (nullable) is None + # and model_fields_set contains the field + if self.processed_forms is None and "processed_forms" in self.model_fields_set: + _dict['processedForms'] = None + return _dict @classmethod @@ -100,7 +114,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "jobData": Data.from_dict(obj["jobData"]) if obj.get("jobData") is not None else None + "jobData": Data.from_dict(obj["jobData"]) if obj.get("jobData") is not None else None, + "processedForms": [Form1099ProccessResultProcessedFormsInner.from_dict(_item) for _item in obj["processedForms"]] if obj.get("processedForms") is not None else None }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_proccess_result_processed_forms_inner.py b/Avalara/SDK/models/A1099/V2/form1099_proccess_result_processed_forms_inner.py new file mode 100644 index 0000000..8a475f5 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_proccess_result_processed_forms_inner.py @@ -0,0 +1,237 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import json +import pprint +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Any, List, Optional +from Avalara.SDK.models.A1099.V2.form1042_s import Form1042S +from Avalara.SDK.models.A1099.V2.form1095_b import Form1095B +from Avalara.SDK.models.A1099.V2.form1099_div import Form1099Div +from Avalara.SDK.models.A1099.V2.form1099_int import Form1099Int +from Avalara.SDK.models.A1099.V2.form1099_k import Form1099K +from Avalara.SDK.models.A1099.V2.form1099_misc import Form1099Misc +from Avalara.SDK.models.A1099.V2.form1099_nec import Form1099Nec +from Avalara.SDK.models.A1099.V2.form1099_r import Form1099R +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +FORM1099PROCCESSRESULTPROCESSEDFORMSINNER_ONE_OF_SCHEMAS = ["Form1042S", "Form1095B", "Form1099Div", "Form1099Int", "Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R"] + +class Form1099ProccessResultProcessedFormsInner(BaseModel): + """ + Form1099ProccessResultProcessedFormsInner + """ + # data type: Form1042S + oneof_schema_1_validator: Optional[Form1042S] = None + # data type: Form1095B + oneof_schema_2_validator: Optional[Form1095B] = None + # data type: Form1099Div + oneof_schema_3_validator: Optional[Form1099Div] = None + # data type: Form1099Int + oneof_schema_4_validator: Optional[Form1099Int] = None + # data type: Form1099K + oneof_schema_5_validator: Optional[Form1099K] = None + # data type: Form1099Misc + oneof_schema_6_validator: Optional[Form1099Misc] = None + # data type: Form1099Nec + oneof_schema_7_validator: Optional[Form1099Nec] = None + # data type: Form1099R + oneof_schema_8_validator: Optional[Form1099R] = None + actual_instance: Optional[Union[Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R]] = None + one_of_schemas: Set[str] = { "Form1042S", "Form1095B", "Form1099Div", "Form1099Int", "Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R" } + + model_config = ConfigDict( + validate_assignment=True, + protected_namespaces=(), + ) + + + def __init__(self, *args, **kwargs) -> None: + if args: + if len(args) > 1: + raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`") + if kwargs: + raise ValueError("If a position argument is used, keyword arguments cannot be used.") + super().__init__(actual_instance=args[0]) + else: + super().__init__(**kwargs) + + @field_validator('actual_instance') + def actual_instance_must_validate_oneof(cls, v): + instance = Form1099ProccessResultProcessedFormsInner.model_construct() + error_messages = [] + match = 0 + # validate data type: Form1042S + if not isinstance(v, Form1042S): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1042S`") + else: + match += 1 + # validate data type: Form1095B + if not isinstance(v, Form1095B): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1095B`") + else: + match += 1 + # validate data type: Form1099Div + if not isinstance(v, Form1099Div): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099Div`") + else: + match += 1 + # validate data type: Form1099Int + if not isinstance(v, Form1099Int): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099Int`") + else: + match += 1 + # validate data type: Form1099K + if not isinstance(v, Form1099K): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099K`") + else: + match += 1 + # validate data type: Form1099Misc + if not isinstance(v, Form1099Misc): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099Misc`") + else: + match += 1 + # validate data type: Form1099Nec + if not isinstance(v, Form1099Nec): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099Nec`") + else: + match += 1 + # validate data type: Form1099R + if not isinstance(v, Form1099R): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099R`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in Form1099ProccessResultProcessedFormsInner with oneOf schemas: Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in Form1099ProccessResultProcessedFormsInner with oneOf schemas: Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self: + return cls.from_json(json.dumps(obj)) + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Returns the object represented by the json string""" + instance = cls.model_construct() + error_messages = [] + match = 0 + + # deserialize data into Form1042S + try: + instance.actual_instance = Form1042S.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1095B + try: + instance.actual_instance = Form1095B.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099Div + try: + instance.actual_instance = Form1099Div.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099Int + try: + instance.actual_instance = Form1099Int.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099K + try: + instance.actual_instance = Form1099K.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099Misc + try: + instance.actual_instance = Form1099Misc.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099Nec + try: + instance.actual_instance = Form1099Nec.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into Form1099R + try: + instance.actual_instance = Form1099R.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when deserializing the JSON string into Form1099ProccessResultProcessedFormsInner with oneOf schemas: Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into Form1099ProccessResultProcessedFormsInner with oneOf schemas: Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) + else: + return instance + + def to_json(self) -> str: + """Returns the JSON representation of the actual instance""" + if self.actual_instance is None: + return "null" + + if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json): + return self.actual_instance.to_json() + else: + return json.dumps(self.actual_instance) + + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042S, Form1095B, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R]]: + """Returns the dict representation of the actual instance""" + if self.actual_instance is None: + return None + + if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict): + return self.actual_instance.to_dict() + else: + # primitive type + return self.actual_instance + + def to_str(self) -> str: + """Returns the string representation of the actual instance""" + return pprint.pformat(self.model_dump()) + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_r.py b/Avalara/SDK/models/A1099/V2/form1099_r.py index 34eb774..12a2921 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -65,7 +65,6 @@ class Form1099R(BaseModel): total_employee_contributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalEmployeeContributions") amount_allocable_to_irr: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="amountAllocableToIrr") first_year_designated_roth_contrib: Optional[StrictStr] = Field(default=None, alias="firstYearDesignatedRothContrib") - fatca_requirement_indicator: Optional[StrictBool] = Field(default=None, alias="fatcaRequirementIndicator") date_of_payment: Optional[StrictStr] = Field(default=None, alias="dateOfPayment") id: Optional[StrictStr] = None type: Optional[StrictStr] = None @@ -83,10 +82,14 @@ class Form1099R(BaseModel): tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, alias="tinMatchStatus") address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, alias="eDeliveryStatus") reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") email: Optional[StrictStr] = None tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, alias="fatcaFilingRequirement") tin: Optional[StrictStr] = None + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") address: Optional[StrictStr] = None @@ -94,13 +97,15 @@ class Form1099R(BaseModel): city: Optional[StrictStr] = None state: Optional[StrictStr] = None zip: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") validation_errors: Optional[List[ValidationError]] = Field(default=None, alias="validationErrors") created_at: Optional[datetime] = Field(default=None, alias="createdAt") updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") state_and_local_withholding: Optional[StateAndLocalWithholding] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "referenceId", "email", "tinType", "tin", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "foreignProvince", "countryCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["id", "type", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "federalEfile", "federalEfileStatus", "stateEfile", "stateEfileStatus", "postalMail", "postalMailStatus", "tinMatch", "tinMatchStatus", "addressVerification", "addressVerificationStatus", "eDeliveryStatus", "referenceId", "email", "tinType", "fatcaFilingRequirement", "tin", "noTin", "secondTinNotice", "recipientName", "recipientSecondName", "address", "address2", "city", "state", "zip", "nonUsProvince", "countryCode", "accountNumber", "officeCode", "validationErrors", "createdAt", "updatedAt", "stateAndLocalWithholding"] model_config = ConfigDict( populate_by_name=True, @@ -160,6 +165,9 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of address_verification_status if self.address_verification_status: _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) _items = [] if self.validation_errors: @@ -200,6 +208,11 @@ def to_dict(self) -> Dict[str, Any]: if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: _dict['addressVerificationStatus'] = None + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + # set to None if reference_id (nullable) is None # and model_fields_set contains the field if self.reference_id is None and "reference_id" in self.model_fields_set: @@ -215,11 +228,21 @@ def to_dict(self) -> Dict[str, Any]: if self.tin_type is None and "tin_type" in self.model_fields_set: _dict['tinType'] = None + # set to None if fatca_filing_requirement (nullable) is None + # and model_fields_set contains the field + if self.fatca_filing_requirement is None and "fatca_filing_requirement" in self.model_fields_set: + _dict['fatcaFilingRequirement'] = None + # set to None if tin (nullable) is None # and model_fields_set contains the field if self.tin is None and "tin" in self.model_fields_set: _dict['tin'] = None + # set to None if second_tin_notice (nullable) is None + # and model_fields_set contains the field + if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: + _dict['secondTinNotice'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -255,16 +278,26 @@ def to_dict(self) -> Dict[str, Any]: if self.zip is None and "zip" in self.model_fields_set: _dict['zip'] = None - # set to None if foreign_province (nullable) is None + # set to None if non_us_province (nullable) is None # and model_fields_set contains the field - if self.foreign_province is None and "foreign_province" in self.model_fields_set: - _dict['foreignProvince'] = None + if self.non_us_province is None and "non_us_province" in self.model_fields_set: + _dict['nonUsProvince'] = None # set to None if country_code (nullable) is None # and model_fields_set contains the field if self.country_code is None and "country_code" in self.model_fields_set: _dict['countryCode'] = None + # set to None if account_number (nullable) is None + # and model_fields_set contains the field + if self.account_number is None and "account_number" in self.model_fields_set: + _dict['accountNumber'] = None + + # set to None if office_code (nullable) is None + # and model_fields_set contains the field + if self.office_code is None and "office_code" in self.model_fields_set: + _dict['officeCode'] = None + # set to None if validation_errors (nullable) is None # and model_fields_set contains the field if self.validation_errors is None and "validation_errors" in self.model_fields_set: @@ -303,10 +336,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, "addressVerification": obj.get("addressVerification"), "addressVerificationStatus": Form1099StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "eDeliveryStatus": Form1099StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, "referenceId": obj.get("referenceId"), "email": obj.get("email"), "tinType": obj.get("tinType"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "tin": obj.get("tin"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), "recipientName": obj.get("recipientName"), "recipientSecondName": obj.get("recipientSecondName"), "address": obj.get("address"), @@ -314,8 +351,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "city": obj.get("city"), "state": obj.get("state"), "zip": obj.get("zip"), - "foreignProvince": obj.get("foreignProvince"), + "nonUsProvince": obj.get("nonUsProvince"), "countryCode": obj.get("countryCode"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), "validationErrors": [ValidationError.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None, "createdAt": obj.get("createdAt"), "updatedAt": obj.get("updatedAt"), diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_list.py b/Avalara/SDK/models/A1099/V2/form1099_r_list.py index 30662bc..07fa473 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py index 7c32b9b..9bba843 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -74,16 +73,16 @@ class Form1099RListItem(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -92,7 +91,7 @@ class Form1099RListItem(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerReferenceId", "issuerTin", "taxYear", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('distribution_code') def distribution_code_validate_enum(cls, value): @@ -166,6 +165,16 @@ def to_dict(self) -> Dict[str, Any]: # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding if self.state_and_local_withholding: _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # set to None if issuer_reference_id (nullable) is None + # and model_fields_set contains the field + if self.issuer_reference_id is None and "issuer_reference_id" in self.model_fields_set: + _dict['issuerReferenceId'] = None + + # set to None if issuer_tin (nullable) is None + # and model_fields_set contains the field + if self.issuer_tin is None and "issuer_tin" in self.model_fields_set: + _dict['issuerTin'] = None + # set to None if issuer_id (nullable) is None # and model_fields_set contains the field if self.issuer_id is None and "issuer_id" in self.model_fields_set: @@ -176,6 +185,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -186,11 +200,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -211,6 +245,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -258,6 +297,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_list_item_response.py b/Avalara/SDK/models/A1099/V2/form1099_r_list_item_response.py index f7a0d93..dff739c 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list_item_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -66,7 +66,6 @@ class Form1099RListItemResponse(BaseModel): total_employee_contributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total employee contributions", alias="totalEmployeeContributions") amount_allocable_to_irr: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount allocable to IRR within 5 years", alias="amountAllocableToIrr") first_year_designated_roth_contrib: Optional[StrictStr] = Field(default=None, description="First year of designated Roth contribution", alias="firstYearDesignatedRothContrib") - fatca_requirement_indicator: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaRequirementIndicator") date_of_payment: Optional[StrictStr] = Field(default=None, description="Date of payment", alias="dateOfPayment") id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="ID of the form") type: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC") diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_request.py b/Avalara/SDK/models/A1099/V2/form1099_r_request.py index b65def9..04b2d10 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,7 +36,6 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional, Union -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -72,16 +71,16 @@ class Form1099RRequest(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") @@ -90,7 +89,7 @@ class Form1099RRequest(BaseModel): second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["type", "issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -98,8 +97,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -164,6 +163,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -174,11 +178,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -199,6 +223,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -244,6 +273,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_response.py b/Avalara/SDK/models/A1099/V2/form1099_r_response.py new file mode 100644 index 0000000..fbb42f0 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_r_response.py @@ -0,0 +1,291 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.validation_error_response import ValidationErrorResponse +from typing import Optional, Set +from typing_extensions import Self + +class Form1099RResponse(BaseModel): + """ + Form1099RResponse + """ # noqa: E501 + gross_distribution: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Gross distribution", alias="grossDistribution") + taxable_amount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Taxable amount", alias="taxableAmount") + taxable_amount_not_determined: Optional[StrictBool] = Field(default=None, description="Taxable amount not determined", alias="taxableAmountNotDetermined") + total_distribution_determined: Optional[StrictBool] = Field(default=None, description="Total distribution", alias="totalDistributionDetermined") + capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Capital gain (included in Box 2a)", alias="capitalGain") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + employee_contributions_or_designated_roth_or_insurance_premiums: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Employee contributions/Designated Roth contributions or insurance premiums", alias="employeeContributionsOrDesignatedRothOrInsurancePremiums") + net_unrealized_appreciation_in_employer_securities: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Net unrealized appreciation in employer's securities", alias="netUnrealizedAppreciationInEmployerSecurities") + distribution_code: Optional[StrictStr] = Field(default=None, description="Distribution code", alias="distributionCode") + second_distribution_code: Optional[StrictStr] = Field(default=None, description="Second distribution code", alias="secondDistributionCode") + ira_sep_simple: Optional[StrictBool] = Field(default=None, description="IRA/SEP/SIMPLE", alias="iraSepSimple") + traditional_ira_sep_simple_or_roth_conversion_amount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Traditional IRA/SEP/SIMPLE or Roth conversion amount", alias="traditionalIraSepSimpleOrRothConversionAmount") + other_amount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Other amount", alias="otherAmount") + other_percentage: Optional[StrictStr] = Field(default=None, description="Other percentage", alias="otherPercentage") + total_distribution_percentage: Optional[StrictStr] = Field(default=None, description="Total distribution percentage", alias="totalDistributionPercentage") + total_employee_contributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Total employee contributions", alias="totalEmployeeContributions") + amount_allocable_to_irr_within5_years: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount allocable to IRR within 5 years", alias="amountAllocableToIrrWithin5Years") + first_year_of_designated_roth_contribution: Optional[StrictStr] = Field(default=None, description="First year of designated Roth contribution", alias="firstYearOfDesignatedRothContribution") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") + date_of_payment: Optional[datetime] = Field(default=None, description="Date of payment", alias="dateOfPayment") + type: Optional[StrictStr] = None + created_at: Optional[datetime] = Field(default=None, alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") + state_and_local_withholding: Optional[StateAndLocalWithholdingResponse] = Field(default=None, alias="stateAndLocalWithholding") + tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") + id: Optional[StrictStr] = None + issuer_id: Optional[StrictStr] = Field(default=None, alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") + recipient_name: Optional[StrictStr] = Field(default=None, alias="recipientName") + recipient_tin: Optional[StrictStr] = Field(default=None, alias="recipientTin") + recipient_second_name: Optional[StrictStr] = Field(default=None, alias="recipientSecondName") + address: Optional[StrictStr] = None + address2: Optional[StrictStr] = None + city: Optional[StrictStr] = None + state: Optional[StrictStr] = None + zip: Optional[StrictStr] = None + email: Optional[StrictStr] = None + account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") + office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") + non_us_province: Optional[StrictStr] = Field(default=None, alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") + federal_e_file: Optional[StrictBool] = Field(default=None, alias="federalEFile") + postal_mail: Optional[StrictBool] = Field(default=None, alias="postalMail") + state_e_file: Optional[StrictBool] = Field(default=None, alias="stateEFile") + tin_match: Optional[StrictBool] = Field(default=None, alias="tinMatch") + no_tin: Optional[StrictBool] = Field(default=None, alias="noTin") + second_tin_notice: Optional[StrictBool] = Field(default=None, alias="secondTinNotice") + address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") + federal_efile_status: Optional[StatusDetail] = Field(default=None, alias="federalEfileStatus") + e_delivery_status: Optional[StatusDetail] = Field(default=None, alias="eDeliveryStatus") + state_efile_status: Optional[List[StateEfileStatusDetailResponse]] = Field(default=None, alias="stateEfileStatus") + postal_mail_status: Optional[StatusDetail] = Field(default=None, alias="postalMailStatus") + tin_match_status: Optional[StatusDetail] = Field(default=None, alias="tinMatchStatus") + address_verification_status: Optional[StatusDetail] = Field(default=None, alias="addressVerificationStatus") + validation_errors: Optional[List[ValidationErrorResponse]] = Field(default=None, alias="validationErrors") + __properties: ClassVar[List[str]] = ["type", "createdAt", "updatedAt", "stateAndLocalWithholding", "tinType", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "recipientName", "recipientTin", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "federalEfileStatus", "eDeliveryStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "validationErrors"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") + return value + + @field_validator('tin_type') + def tin_type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Form1099RResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "type", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of state_and_local_withholding + if self.state_and_local_withholding: + _dict['stateAndLocalWithholding'] = self.state_and_local_withholding.to_dict() + # override the default output from pydantic by calling `to_dict()` of federal_efile_status + if self.federal_efile_status: + _dict['federalEfileStatus'] = self.federal_efile_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of e_delivery_status + if self.e_delivery_status: + _dict['eDeliveryStatus'] = self.e_delivery_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in state_efile_status (list) + _items = [] + if self.state_efile_status: + for _item in self.state_efile_status: + if _item: + _items.append(_item.to_dict()) + _dict['stateEfileStatus'] = _items + # override the default output from pydantic by calling `to_dict()` of postal_mail_status + if self.postal_mail_status: + _dict['postalMailStatus'] = self.postal_mail_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of tin_match_status + if self.tin_match_status: + _dict['tinMatchStatus'] = self.tin_match_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of address_verification_status + if self.address_verification_status: + _dict['addressVerificationStatus'] = self.address_verification_status.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in validation_errors (list) + _items = [] + if self.validation_errors: + for _item in self.validation_errors: + if _item: + _items.append(_item.to_dict()) + _dict['validationErrors'] = _items + # set to None if federal_efile_status (nullable) is None + # and model_fields_set contains the field + if self.federal_efile_status is None and "federal_efile_status" in self.model_fields_set: + _dict['federalEfileStatus'] = None + + # set to None if e_delivery_status (nullable) is None + # and model_fields_set contains the field + if self.e_delivery_status is None and "e_delivery_status" in self.model_fields_set: + _dict['eDeliveryStatus'] = None + + # set to None if state_efile_status (nullable) is None + # and model_fields_set contains the field + if self.state_efile_status is None and "state_efile_status" in self.model_fields_set: + _dict['stateEfileStatus'] = None + + # set to None if postal_mail_status (nullable) is None + # and model_fields_set contains the field + if self.postal_mail_status is None and "postal_mail_status" in self.model_fields_set: + _dict['postalMailStatus'] = None + + # set to None if tin_match_status (nullable) is None + # and model_fields_set contains the field + if self.tin_match_status is None and "tin_match_status" in self.model_fields_set: + _dict['tinMatchStatus'] = None + + # set to None if address_verification_status (nullable) is None + # and model_fields_set contains the field + if self.address_verification_status is None and "address_verification_status" in self.model_fields_set: + _dict['addressVerificationStatus'] = None + + # set to None if validation_errors (nullable) is None + # and model_fields_set contains the field + if self.validation_errors is None and "validation_errors" in self.model_fields_set: + _dict['validationErrors'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099RResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "type": obj.get("type"), + "createdAt": obj.get("createdAt"), + "updatedAt": obj.get("updatedAt"), + "stateAndLocalWithholding": StateAndLocalWithholdingResponse.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "tinType": obj.get("tinType"), + "id": obj.get("id"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "referenceId": obj.get("referenceId"), + "recipientName": obj.get("recipientName"), + "recipientTin": obj.get("recipientTin"), + "recipientSecondName": obj.get("recipientSecondName"), + "address": obj.get("address"), + "address2": obj.get("address2"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "email": obj.get("email"), + "accountNumber": obj.get("accountNumber"), + "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEFile": obj.get("federalEFile"), + "postalMail": obj.get("postalMail"), + "stateEFile": obj.get("stateEFile"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "secondTinNotice": obj.get("secondTinNotice"), + "addressVerification": obj.get("addressVerification"), + "federalEfileStatus": StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "eDeliveryStatus": StatusDetail.from_dict(obj["eDeliveryStatus"]) if obj.get("eDeliveryStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetailResponse.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "addressVerificationStatus": StatusDetail.from_dict(obj["addressVerificationStatus"]) if obj.get("addressVerificationStatus") is not None else None, + "validationErrors": [ValidationErrorResponse.from_dict(_item) for _item in obj["validationErrors"]] if obj.get("validationErrors") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_status_detail.py b/Avalara/SDK/models/A1099/V2/form1099_status_detail.py index a8b6306..ffd316e 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_status_detail.py +++ b/Avalara/SDK/models/A1099/V2/form1099_status_detail.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form_request_base.py b/Avalara/SDK/models/A1099/V2/form_request_base.py index 17699d5..59d7c21 100644 --- a/Avalara/SDK/models/A1099/V2/form_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_request_base.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -50,25 +49,26 @@ class FormRequestBase(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -132,6 +132,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -142,11 +147,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -167,6 +192,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -211,6 +241,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form_request_list_item_base.py b/Avalara/SDK/models/A1099/V2/form_request_list_item_base.py index 2c7d2a1..d19891d 100644 --- a/Avalara/SDK/models/A1099/V2/form_request_list_item_base.py +++ b/Avalara/SDK/models/A1099/V2/form_request_list_item_base.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -53,25 +52,26 @@ class FormRequestListItemBase(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('tin_type') def tin_type_validate_enum(cls, value): @@ -135,6 +135,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -145,11 +150,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -170,6 +195,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -214,6 +244,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/form_response_base.py b/Avalara/SDK/models/A1099/V2/form_response_base.py index 946b5f1..b8e66b2 100644 --- a/Avalara/SDK/models/A1099/V2/form_response_base.py +++ b/Avalara/SDK/models/A1099/V2/form_response_base.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -93,8 +93,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') diff --git a/Avalara/SDK/models/A1099/V2/form_single_request_base.py b/Avalara/SDK/models/A1099/V2/form_single_request_base.py index 499db23..9ef6f7f 100644 --- a/Avalara/SDK/models/A1099/V2/form_single_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_single_request_base.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,7 +35,6 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from typing_extensions import Annotated from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self @@ -51,25 +50,26 @@ class FormSingleRequestBase(BaseModel): recipient_name: Optional[StrictStr] = Field(default=None, description="Recipient name", alias="recipientName") tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN", alias="tinType") recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") - address: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Address") + address: Optional[StrictStr] = Field(default=None, description="Address") address2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Annotated[str, Field(min_length=1, strict=True)] = Field(description="City") + city: Optional[StrictStr] = Field(default=None, description="City") state: Optional[StrictStr] = Field(default=None, description="US state. Required if CountryCode is \"US\".") zip: Optional[StrictStr] = Field(default=None, description="Zip/postal code") email: Optional[StrictStr] = Field(default=None, description="Recipient email address") account_number: Optional[StrictStr] = Field(default=None, description="Account number", alias="accountNumber") office_code: Optional[StrictStr] = Field(default=None, description="Office code", alias="officeCode") non_us_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="nonUsProvince") - country_code: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") + country_code: Optional[StrictStr] = Field(default=None, description="Country code, as defined at https://www.irs.gov/e-file-providers/country-codes", alias="countryCode") federal_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that federal e-filing should be scheduled for this form", alias="federalEFile") postal_mail: Optional[StrictBool] = Field(default=None, description="Boolean indicating that postal mailing to the recipient should be scheduled for this form", alias="postalMail") state_e_file: Optional[StrictBool] = Field(default=None, description="Boolean indicating that state e-filing should be scheduled for this form", alias="stateEFile") tin_match: Optional[StrictBool] = Field(default=None, description="Boolean indicating that TIN Matching should be scheduled for this form", alias="tinMatch") no_tin: Optional[StrictBool] = Field(default=None, description="Indicates whether the recipient has no TIN", alias="noTin") second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice in three years", alias="secondTinNotice") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="Fatca filing requirement", alias="fatcaFilingRequirement") address_verification: Optional[StrictBool] = Field(default=None, description="Boolean indicating that address verification should be scheduled for this form", alias="addressVerification") state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "addressVerification", "stateAndLocalWithholding"] + __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientTin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "noTin", "secondTinNotice", "fatcaFilingRequirement", "addressVerification", "stateAndLocalWithholding"] @field_validator('type') def type_validate_enum(cls, value): @@ -77,8 +77,8 @@ def type_validate_enum(cls, value): if value is None: return value - if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C']): - raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C')") + if value not in set(['1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT']): + raise ValueError("must be one of enum values ('1099-NEC', '1099-MISC', '1099-DIV', '1099-R', '1099-K', '1095-B', '1042-S', '1095-C', '1099-INT')") return value @field_validator('tin_type') @@ -143,6 +143,11 @@ def to_dict(self) -> Dict[str, Any]: if self.reference_id is None and "reference_id" in self.model_fields_set: _dict['referenceId'] = None + # set to None if recipient_tin (nullable) is None + # and model_fields_set contains the field + if self.recipient_tin is None and "recipient_tin" in self.model_fields_set: + _dict['recipientTin'] = None + # set to None if recipient_name (nullable) is None # and model_fields_set contains the field if self.recipient_name is None and "recipient_name" in self.model_fields_set: @@ -153,11 +158,31 @@ def to_dict(self) -> Dict[str, Any]: if self.recipient_second_name is None and "recipient_second_name" in self.model_fields_set: _dict['recipientSecondName'] = None + # set to None if address (nullable) is None + # and model_fields_set contains the field + if self.address is None and "address" in self.model_fields_set: + _dict['address'] = None + # set to None if address2 (nullable) is None # and model_fields_set contains the field if self.address2 is None and "address2" in self.model_fields_set: _dict['address2'] = None + # set to None if city (nullable) is None + # and model_fields_set contains the field + if self.city is None and "city" in self.model_fields_set: + _dict['city'] = None + + # set to None if state (nullable) is None + # and model_fields_set contains the field + if self.state is None and "state" in self.model_fields_set: + _dict['state'] = None + + # set to None if zip (nullable) is None + # and model_fields_set contains the field + if self.zip is None and "zip" in self.model_fields_set: + _dict['zip'] = None + # set to None if email (nullable) is None # and model_fields_set contains the field if self.email is None and "email" in self.model_fields_set: @@ -178,6 +203,11 @@ def to_dict(self) -> Dict[str, Any]: if self.non_us_province is None and "non_us_province" in self.model_fields_set: _dict['nonUsProvince'] = None + # set to None if country_code (nullable) is None + # and model_fields_set contains the field + if self.country_code is None and "country_code" in self.model_fields_set: + _dict['countryCode'] = None + # set to None if second_tin_notice (nullable) is None # and model_fields_set contains the field if self.second_tin_notice is None and "second_tin_notice" in self.model_fields_set: @@ -222,6 +252,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "tinMatch": obj.get("tinMatch"), "noTin": obj.get("noTin"), "secondTinNotice": obj.get("secondTinNotice"), + "fatcaFilingRequirement": obj.get("fatcaFilingRequirement"), "addressVerification": obj.get("addressVerification"), "stateAndLocalWithholding": StateAndLocalWithholdingRequest.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None }) diff --git a/Avalara/SDK/models/A1099/V2/get1099_form200_response.py b/Avalara/SDK/models/A1099/V2/get1099_form200_response.py index aa0cec4..e4ea5b8 100644 --- a/Avalara/SDK/models/A1099/V2/get1099_form200_response.py +++ b/Avalara/SDK/models/A1099/V2/get1099_form200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -37,6 +37,7 @@ from Avalara.SDK.models.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse from Avalara.SDK.models.A1099.V2.form1099_base_response import Form1099BaseResponse from Avalara.SDK.models.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse from Avalara.SDK.models.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse from Avalara.SDK.models.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse from Avalara.SDK.models.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse @@ -45,7 +46,7 @@ from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -GET1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] +GET1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] class Get1099Form200Response(BaseModel): """ @@ -59,16 +60,18 @@ class Get1099Form200Response(BaseModel): oneof_schema_3_validator: Optional[Form1095BListItemResponse] = None # data type: Form1099DivListItemResponse oneof_schema_4_validator: Optional[Form1099DivListItemResponse] = None + # data type: Form1099IntListItemResponse + oneof_schema_5_validator: Optional[Form1099IntListItemResponse] = None # data type: Form1099KListItemResponse - oneof_schema_5_validator: Optional[Form1099KListItemResponse] = None + oneof_schema_6_validator: Optional[Form1099KListItemResponse] = None # data type: Form1099MiscListItemResponse - oneof_schema_6_validator: Optional[Form1099MiscListItemResponse] = None + oneof_schema_7_validator: Optional[Form1099MiscListItemResponse] = None # data type: Form1099NecListItemResponse - oneof_schema_7_validator: Optional[Form1099NecListItemResponse] = None + oneof_schema_8_validator: Optional[Form1099NecListItemResponse] = None # data type: Form1099RListItemResponse - oneof_schema_8_validator: Optional[Form1099RListItemResponse] = None - actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None - one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } + oneof_schema_9_validator: Optional[Form1099RListItemResponse] = None + actual_instance: Optional[Union[Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]] = None + one_of_schemas: Set[str] = { "Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse" } model_config = ConfigDict( validate_assignment=True, @@ -111,6 +114,11 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivListItemResponse`") else: match += 1 + # validate data type: Form1099IntListItemResponse + if not isinstance(v, Form1099IntListItemResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntListItemResponse`") + else: + match += 1 # validate data type: Form1099KListItemResponse if not isinstance(v, Form1099KListItemResponse): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KListItemResponse`") @@ -133,10 +141,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return v @@ -175,6 +183,12 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099IntListItemResponse + try: + instance.actual_instance = Form1099IntListItemResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099KListItemResponse try: instance.actual_instance = Form1099KListItemResponse.from_json(json_str) @@ -202,10 +216,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) else: return instance @@ -219,7 +233,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py b/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py index 4c24f89..fe3c4ea 100644 --- a/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py index 3c3991d..d278c71 100644 --- a/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/included_base.py b/Avalara/SDK/models/A1099/V2/included_base.py index 0ada348..bf8422b 100644 --- a/Avalara/SDK/models/A1099/V2/included_base.py +++ b/Avalara/SDK/models/A1099/V2/included_base.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through.py b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through.py index ab9a24a..81e2bfd 100644 --- a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through.py +++ b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_request.py b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_request.py index 4f8a5b6..c535301 100644 --- a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_request.py +++ b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_response.py b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_response.py index d4421f4..f7dbf32 100644 --- a/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_response.py +++ b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/irs_response.py b/Avalara/SDK/models/A1099/V2/irs_response.py index 06a20e0..d536cfa 100644 --- a/Avalara/SDK/models/A1099/V2/irs_response.py +++ b/Avalara/SDK/models/A1099/V2/irs_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/issuer_command.py b/Avalara/SDK/models/A1099/V2/issuer_command.py index b060407..6b63ca9 100644 --- a/Avalara/SDK/models/A1099/V2/issuer_command.py +++ b/Avalara/SDK/models/A1099/V2/issuer_command.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -98,6 +98,11 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) + # set to None if name (nullable) is None + # and model_fields_set contains the field + if self.name is None and "name" in self.model_fields_set: + _dict['name'] = None + # set to None if name_dba (nullable) is None # and model_fields_set contains the field if self.name_dba is None and "name_dba" in self.model_fields_set: diff --git a/Avalara/SDK/models/A1099/V2/issuer_response.py b/Avalara/SDK/models/A1099/V2/issuer_response.py index 764b868..447de66 100644 --- a/Avalara/SDK/models/A1099/V2/issuer_response.py +++ b/Avalara/SDK/models/A1099/V2/issuer_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/iw9_form_data_models_one_of.py b/Avalara/SDK/models/A1099/V2/iw9_form_data_models_one_of.py index d2d5390..af1b975 100644 --- a/Avalara/SDK/models/A1099/V2/iw9_form_data_models_one_of.py +++ b/Avalara/SDK/models/A1099/V2/iw9_form_data_models_one_of.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/job_result.py b/Avalara/SDK/models/A1099/V2/job_result.py index 9a9f2a7..622ec59 100644 --- a/Avalara/SDK/models/A1099/V2/job_result.py +++ b/Avalara/SDK/models/A1099/V2/job_result.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/link.py b/Avalara/SDK/models/A1099/V2/link.py index 918defb..94d19d1 100644 --- a/Avalara/SDK/models/A1099/V2/link.py +++ b/Avalara/SDK/models/A1099/V2/link.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/offer_and_coverage_request.py b/Avalara/SDK/models/A1099/V2/offer_and_coverage_request.py index 24b50be..7000262 100644 --- a/Avalara/SDK/models/A1099/V2/offer_and_coverage_request.py +++ b/Avalara/SDK/models/A1099/V2/offer_and_coverage_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_company_response.py b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_company_response.py index 62c5ca4..605b108 100644 --- a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_company_response.py +++ b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_company_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_issuer_response.py b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_issuer_response.py index b50bae6..b355b70 100644 --- a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_issuer_response.py +++ b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_issuer_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_w9_form_base_response.py b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_w9_form_base_response.py new file mode 100644 index 0000000..9574660 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_w9_form_base_response.py @@ -0,0 +1,130 @@ +# coding: utf-8 + +""" +AvaTax Software Development Kit for Python. + + Copyright 2022 Avalara, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Avalara 1099 & W-9 API Definition + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + +@author Sachin Baijal +@author Jonathan Wenger +@copyright 2022 Avalara, Inc. +@license https://www.apache.org/licenses/LICENSE-2.0 +@version 25.8.2 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.create_w9_form201_response import CreateW9Form201Response +from typing import Optional, Set +from typing_extensions import Self + +class PaginatedQueryResultModelW9FormBaseResponse(BaseModel): + """ + Generic paginated model to wrap query response data + """ # noqa: E501 + recordset_count: Optional[StrictInt] = Field(default=None, alias="@recordsetCount") + value: Optional[List[CreateW9Form201Response]] = None + next_link: Optional[StrictStr] = Field(default=None, alias="@nextLink") + __properties: ClassVar[List[str]] = ["@recordsetCount", "value", "@nextLink"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedQueryResultModelW9FormBaseResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in value (list) + _items = [] + if self.value: + for _item in self.value: + if _item: + _items.append(_item.to_dict()) + _dict['value'] = _items + # set to None if recordset_count (nullable) is None + # and model_fields_set contains the field + if self.recordset_count is None and "recordset_count" in self.model_fields_set: + _dict['@recordsetCount'] = None + + # set to None if value (nullable) is None + # and model_fields_set contains the field + if self.value is None and "value" in self.model_fields_set: + _dict['value'] = None + + # set to None if next_link (nullable) is None + # and model_fields_set contains the field + if self.next_link is None and "next_link" in self.model_fields_set: + _dict['@nextLink'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedQueryResultModelW9FormBaseResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "@recordsetCount": obj.get("@recordsetCount"), + "value": [CreateW9Form201Response.from_dict(_item) for _item in obj["value"]] if obj.get("value") is not None else None, + "@nextLink": obj.get("@nextLink") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/paginated_w9_forms_model.py b/Avalara/SDK/models/A1099/V2/paginated_w9_forms_model.py index f34f307..157794d 100644 --- a/Avalara/SDK/models/A1099/V2/paginated_w9_forms_model.py +++ b/Avalara/SDK/models/A1099/V2/paginated_w9_forms_model.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.iw9_form_data_models_one_of import IW9FormDataModelsOneOf +from Avalara.SDK.models.A1099.V2.A1099.V2.iw9_form_data_models_one_of import IW9FormDataModelsOneOf from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/primary_withholding_agent.py b/Avalara/SDK/models/A1099/V2/primary_withholding_agent.py index b959a09..34c89ee 100644 --- a/Avalara/SDK/models/A1099/V2/primary_withholding_agent.py +++ b/Avalara/SDK/models/A1099/V2/primary_withholding_agent.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/primary_withholding_agent_request.py b/Avalara/SDK/models/A1099/V2/primary_withholding_agent_request.py index 26c2776..a67e9a0 100644 --- a/Avalara/SDK/models/A1099/V2/primary_withholding_agent_request.py +++ b/Avalara/SDK/models/A1099/V2/primary_withholding_agent_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/primary_withholding_agent_response.py b/Avalara/SDK/models/A1099/V2/primary_withholding_agent_response.py index 536767e..bb24017 100644 --- a/Avalara/SDK/models/A1099/V2/primary_withholding_agent_response.py +++ b/Avalara/SDK/models/A1099/V2/primary_withholding_agent_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py b/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py index ea11c01..6eb3749 100644 --- a/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py +++ b/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/state_and_local_withholding_request.py b/Avalara/SDK/models/A1099/V2/state_and_local_withholding_request.py index f5976d7..c5d2933 100644 --- a/Avalara/SDK/models/A1099/V2/state_and_local_withholding_request.py +++ b/Avalara/SDK/models/A1099/V2/state_and_local_withholding_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/state_and_local_withholding_response.py b/Avalara/SDK/models/A1099/V2/state_and_local_withholding_response.py index ceccc3e..7e6363b 100644 --- a/Avalara/SDK/models/A1099/V2/state_and_local_withholding_response.py +++ b/Avalara/SDK/models/A1099/V2/state_and_local_withholding_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/state_efile_status_detail.py b/Avalara/SDK/models/A1099/V2/state_efile_status_detail.py index 4a7ff6c..7081a2e 100644 --- a/Avalara/SDK/models/A1099/V2/state_efile_status_detail.py +++ b/Avalara/SDK/models/A1099/V2/state_efile_status_detail.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/state_efile_status_detail_response.py b/Avalara/SDK/models/A1099/V2/state_efile_status_detail_response.py index 6680a90..c19d30f 100644 --- a/Avalara/SDK/models/A1099/V2/state_efile_status_detail_response.py +++ b/Avalara/SDK/models/A1099/V2/state_efile_status_detail_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/status_detail.py b/Avalara/SDK/models/A1099/V2/status_detail.py index 9793d07..fe7527e 100644 --- a/Avalara/SDK/models/A1099/V2/status_detail.py +++ b/Avalara/SDK/models/A1099/V2/status_detail.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/substantial_us_owner_request.py b/Avalara/SDK/models/A1099/V2/substantial_us_owner_request.py index d0ffba4..ae79e0c 100644 --- a/Avalara/SDK/models/A1099/V2/substantial_us_owner_request.py +++ b/Avalara/SDK/models/A1099/V2/substantial_us_owner_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/substantial_us_owner_response.py b/Avalara/SDK/models/A1099/V2/substantial_us_owner_response.py index 983ce5a..6022072 100644 --- a/Avalara/SDK/models/A1099/V2/substantial_us_owner_response.py +++ b/Avalara/SDK/models/A1099/V2/substantial_us_owner_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/tin_match_status_response.py b/Avalara/SDK/models/A1099/V2/tin_match_status_response.py index dc7a376..a6f96a1 100644 --- a/Avalara/SDK/models/A1099/V2/tin_match_status_response.py +++ b/Avalara/SDK/models/A1099/V2/tin_match_status_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/update1099_form200_response.py b/Avalara/SDK/models/A1099/V2/update1099_form200_response.py index db0e9a0..02b82cf 100644 --- a/Avalara/SDK/models/A1099/V2/update1099_form200_response.py +++ b/Avalara/SDK/models/A1099/V2/update1099_form200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -34,16 +34,19 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional from Avalara.SDK.models.A1099.V2.form1042_s_response import Form1042SResponse +from Avalara.SDK.models.A1099.V2.form1095_b_response import Form1095BResponse from Avalara.SDK.models.A1099.V2.form1099_div_response import Form1099DivResponse +from Avalara.SDK.models.A1099.V2.form1099_int_response import Form1099IntResponse from Avalara.SDK.models.A1099.V2.form1099_k_response import Form1099KResponse from Avalara.SDK.models.A1099.V2.form1099_misc_response import Form1099MiscResponse from Avalara.SDK.models.A1099.V2.form1099_nec_response import Form1099NecResponse +from Avalara.SDK.models.A1099.V2.form1099_r_response import Form1099RResponse from Avalara.SDK.models.A1099.V2.form_response_base import FormResponseBase from pydantic import StrictStr, Field from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -UPDATE1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042SResponse", "Form1099DivResponse", "Form1099KResponse", "Form1099MiscResponse", "Form1099NecResponse", "FormResponseBase"] +UPDATE1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042SResponse", "Form1095BResponse", "Form1099DivResponse", "Form1099IntResponse", "Form1099KResponse", "Form1099MiscResponse", "Form1099NecResponse", "Form1099RResponse", "FormResponseBase"] class Update1099Form200Response(BaseModel): """ @@ -53,16 +56,22 @@ class Update1099Form200Response(BaseModel): oneof_schema_1_validator: Optional[FormResponseBase] = None # data type: Form1042SResponse oneof_schema_2_validator: Optional[Form1042SResponse] = None + # data type: Form1095BResponse + oneof_schema_3_validator: Optional[Form1095BResponse] = None # data type: Form1099DivResponse - oneof_schema_3_validator: Optional[Form1099DivResponse] = None + oneof_schema_4_validator: Optional[Form1099DivResponse] = None + # data type: Form1099IntResponse + oneof_schema_5_validator: Optional[Form1099IntResponse] = None # data type: Form1099KResponse - oneof_schema_4_validator: Optional[Form1099KResponse] = None + oneof_schema_6_validator: Optional[Form1099KResponse] = None # data type: Form1099MiscResponse - oneof_schema_5_validator: Optional[Form1099MiscResponse] = None + oneof_schema_7_validator: Optional[Form1099MiscResponse] = None # data type: Form1099NecResponse - oneof_schema_6_validator: Optional[Form1099NecResponse] = None - actual_instance: Optional[Union[Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase]] = None - one_of_schemas: Set[str] = { "Form1042SResponse", "Form1099DivResponse", "Form1099KResponse", "Form1099MiscResponse", "Form1099NecResponse", "FormResponseBase" } + oneof_schema_8_validator: Optional[Form1099NecResponse] = None + # data type: Form1099RResponse + oneof_schema_9_validator: Optional[Form1099RResponse] = None + actual_instance: Optional[Union[Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase]] = None + one_of_schemas: Set[str] = { "Form1042SResponse", "Form1095BResponse", "Form1099DivResponse", "Form1099IntResponse", "Form1099KResponse", "Form1099MiscResponse", "Form1099NecResponse", "Form1099RResponse", "FormResponseBase" } model_config = ConfigDict( validate_assignment=True, @@ -95,11 +104,21 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1042SResponse`") else: match += 1 + # validate data type: Form1095BResponse + if not isinstance(v, Form1095BResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1095BResponse`") + else: + match += 1 # validate data type: Form1099DivResponse if not isinstance(v, Form1099DivResponse): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivResponse`") else: match += 1 + # validate data type: Form1099IntResponse + if not isinstance(v, Form1099IntResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntResponse`") + else: + match += 1 # validate data type: Form1099KResponse if not isinstance(v, Form1099KResponse): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KResponse`") @@ -115,12 +134,17 @@ def actual_instance_must_validate_oneof(cls, v): error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099NecResponse`") else: match += 1 + # validate data type: Form1099RResponse + if not isinstance(v, Form1099RResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099RResponse`") + else: + match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase. Details: " + ", ".join(error_messages)) else: return v @@ -147,12 +171,24 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1095BResponse + try: + instance.actual_instance = Form1095BResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099DivResponse try: instance.actual_instance = Form1099DivResponse.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099IntResponse + try: + instance.actual_instance = Form1099IntResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) # deserialize data into Form1099KResponse try: instance.actual_instance = Form1099KResponse.from_json(json_str) @@ -171,13 +207,19 @@ def from_json(cls, json_str: str) -> Self: match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # deserialize data into Form1099RResponse + try: + instance.actual_instance = Form1099RResponse.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into Update1099Form200Response with oneOf schemas: Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase. Details: " + ", ".join(error_messages)) else: return instance @@ -191,7 +233,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SResponse, Form1099DivResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, FormResponseBase]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042SResponse, Form1095BResponse, Form1099DivResponse, Form1099IntResponse, Form1099KResponse, Form1099MiscResponse, Form1099NecResponse, Form1099RResponse, FormResponseBase]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/Avalara/SDK/models/A1099/V2/validation_error.py b/Avalara/SDK/models/A1099/V2/validation_error.py index 0a1914a..bdd2f96 100644 --- a/Avalara/SDK/models/A1099/V2/validation_error.py +++ b/Avalara/SDK/models/A1099/V2/validation_error.py @@ -18,13 +18,13 @@ limitations under the License. Avalara 1099 & W-9 API Definition - ## 🔐 Authentication Use **username/password** or generate a **license key** from: *Avalara Portal → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) + ## 🔐 Authentication Generate a **license key** from: *[Avalara Portal](https://www.avalara.com/us/en/signin.html) → Settings → License and API Keys*. [More on authentication methods](https://developer.avalara.com/avatax-dm-combined-erp/common-setup/authentication/authentication-methods/) [Test your credentials](https://developer.avalara.com/avatax/test-credentials/) ## 📘 API & SDK Documentation [Avalara SDK (.NET) on GitHub](https://github.com/avadev/Avalara-SDK-DotNet#avalarasdk--the-unified-c-library-for-next-gen-avalara-services) [Code Examples – 1099 API](https://github.com/avadev/Avalara-SDK-DotNet/blob/main/docs/A1099/V2/Class1099IssuersApi.md#call1099issuersget) @author Sachin Baijal @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.2 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/validation_error_response.py b/Avalara/SDK/models/A1099/V2/validation_error_response.py index b7c9cf5..cf05b86 100644 --- a/Avalara/SDK/models/A1099/V2/validation_error_response.py +++ b/Avalara/SDK/models/A1099/V2/validation_error_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w4_form_data_model.py b/Avalara/SDK/models/A1099/V2/w4_form_data_model.py index aa675eb..9443b0b 100644 --- a/Avalara/SDK/models/A1099/V2/w4_form_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w4_form_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w4_form_request.py b/Avalara/SDK/models/A1099/V2/w4_form_request.py index eeafb15..0a748f6 100644 --- a/Avalara/SDK/models/A1099/V2/w4_form_request.py +++ b/Avalara/SDK/models/A1099/V2/w4_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w4_form_response.py b/Avalara/SDK/models/A1099/V2/w4_form_response.py index cc96b31..d5d9b13 100644 --- a/Avalara/SDK/models/A1099/V2/w4_form_response.py +++ b/Avalara/SDK/models/A1099/V2/w4_form_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,13 +33,13 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from pydantic import ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self -class W4FormResponse(BaseModel): +class W4FormResponse(W9FormBaseResponse): """ W4FormResponse """ # noqa: E501 @@ -62,21 +62,7 @@ class W4FormResponse(BaseModel): additional_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="The additional amount withheld.", alias="additionalWithheld") exempt_from_withholding: Optional[StrictBool] = Field(default=None, description="Indicates whether the employee is exempt from withholding.", alias="exemptFromWithholding") office_code: Optional[StrictStr] = Field(default=None, description="The office code associated with the form.", alias="officeCode") - id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") - entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") - entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - display_name: Optional[StrictStr] = Field(default=None, description="The display name associated with the form.", alias="displayName") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - archived: Optional[StrictBool] = Field(default=None, description="Indicates whether the form is archived.") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - signed_date: Optional[datetime] = Field(default=None, description="The date the form was signed.", alias="signedDate") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") - __properties: ClassVar[List[str]] = ["id", "type", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -160,7 +146,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "type": obj.get("type"), "entryStatus": obj.get("entryStatus"), "entryStatusDate": obj.get("entryStatusDate"), "referenceId": obj.get("referenceId"), @@ -172,7 +157,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), "createdAt": obj.get("createdAt"), - "updatedAt": obj.get("updatedAt") + "updatedAt": obj.get("updatedAt"), + "type": obj.get("type") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_e_form_request.py b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_request.py index f0a51ff..e4ddcde 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_e_form_request.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_e_form_response.py b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_response.py index 6314347..dc6cb20 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_e_form_response.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,14 +33,15 @@ import re # noqa: F401 import json -from datetime import date, datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from datetime import date +from pydantic import ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional from Avalara.SDK.models.A1099.V2.substantial_us_owner_response import SubstantialUsOwnerResponse +from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self -class W8BenEFormResponse(BaseModel): +class W8BenEFormResponse(W9FormBaseResponse): """ W8BenEFormResponse """ # noqa: E501 @@ -140,21 +141,7 @@ class W8BenEFormResponse(BaseModel): substantial_us_owners: Optional[List[SubstantialUsOwnerResponse]] = Field(default=None, description="The list of substantial U.S. owners of passive NFFE.", alias="substantialUsOwners") signer_name: Optional[StrictStr] = Field(default=None, description="The name of the signer.", alias="signerName") capacity_to_sign_certification: Optional[StrictBool] = Field(default=None, description="Certifies signer has the capacity to sign for the beneficial owner.", alias="capacityToSignCertification") - id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") - entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") - entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - display_name: Optional[StrictStr] = Field(default=None, description="The display name associated with the form.", alias="displayName") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - archived: Optional[StrictBool] = Field(default=None, description="Indicates whether the form is archived.") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - signed_date: Optional[datetime] = Field(default=None, description="The date the form was signed.", alias="signedDate") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") - __properties: ClassVar[List[str]] = ["id", "type", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -238,7 +225,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "type": obj.get("type"), "entryStatus": obj.get("entryStatus"), "entryStatusDate": obj.get("entryStatusDate"), "referenceId": obj.get("referenceId"), @@ -250,7 +236,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), "createdAt": obj.get("createdAt"), - "updatedAt": obj.get("updatedAt") + "updatedAt": obj.get("updatedAt"), + "type": obj.get("type") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_e_substantial_us_owner_data_model.py b/Avalara/SDK/models/A1099/V2/w8_ben_e_substantial_us_owner_data_model.py index 031e2ed..9a7f223 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_e_substantial_us_owner_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_e_substantial_us_owner_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_form_data_model.py b/Avalara/SDK/models/A1099/V2/w8_ben_form_data_model.py index 3b93345..d34af21 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_form_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_form_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_form_request.py b/Avalara/SDK/models/A1099/V2/w8_ben_form_request.py index 823d0d0..1f394b0 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_form_request.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_form_response.py b/Avalara/SDK/models/A1099/V2/w8_ben_form_response.py index afc3780..bbf3074 100644 --- a/Avalara/SDK/models/A1099/V2/w8_ben_form_response.py +++ b/Avalara/SDK/models/A1099/V2/w8_ben_form_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,13 +33,14 @@ import re # noqa: F401 import json -from datetime import date, datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from datetime import date +from pydantic import ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self -class W8BenFormResponse(BaseModel): +class W8BenFormResponse(W9FormBaseResponse): """ W8BenFormResponse """ # noqa: E501 @@ -69,21 +70,7 @@ class W8BenFormResponse(BaseModel): income_type: Optional[StrictStr] = Field(default=None, description="The type of income covered by the treaty.", alias="incomeType") signer_name: Optional[StrictStr] = Field(default=None, description="The name of the signer of the form.", alias="signerName") signer_capacity: Optional[StrictStr] = Field(default=None, description="The capacity in which the signer is signing the form.", alias="signerCapacity") - id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") - entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") - entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - display_name: Optional[StrictStr] = Field(default=None, description="The display name associated with the form.", alias="displayName") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - archived: Optional[StrictBool] = Field(default=None, description="Indicates whether the form is archived.") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - signed_date: Optional[datetime] = Field(default=None, description="The date the form was signed.", alias="signedDate") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") - __properties: ClassVar[List[str]] = ["id", "type", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -167,7 +154,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "type": obj.get("type"), "entryStatus": obj.get("entryStatus"), "entryStatusDate": obj.get("entryStatusDate"), "referenceId": obj.get("referenceId"), @@ -179,7 +165,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), "createdAt": obj.get("createdAt"), - "updatedAt": obj.get("updatedAt") + "updatedAt": obj.get("updatedAt"), + "type": obj.get("type") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w8_bene_form_data_model.py b/Avalara/SDK/models/A1099/V2/w8_bene_form_data_model.py index 1b5d7ca..f1397fe 100644 --- a/Avalara/SDK/models/A1099/V2/w8_bene_form_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w8_bene_form_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_imy_form_data_model.py b/Avalara/SDK/models/A1099/V2/w8_imy_form_data_model.py index 8bc5d33..c0947f1 100644 --- a/Avalara/SDK/models/A1099/V2/w8_imy_form_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w8_imy_form_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_imy_form_request.py b/Avalara/SDK/models/A1099/V2/w8_imy_form_request.py index 29529e3..3561222 100644 --- a/Avalara/SDK/models/A1099/V2/w8_imy_form_request.py +++ b/Avalara/SDK/models/A1099/V2/w8_imy_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_imy_form_response.py b/Avalara/SDK/models/A1099/V2/w8_imy_form_response.py index bc925e3..1482837 100644 --- a/Avalara/SDK/models/A1099/V2/w8_imy_form_response.py +++ b/Avalara/SDK/models/A1099/V2/w8_imy_form_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,13 +33,14 @@ import re # noqa: F401 import json -from datetime import date, datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from datetime import date +from pydantic import ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self -class W8ImyFormResponse(BaseModel): +class W8ImyFormResponse(W9FormBaseResponse): """ W8ImyFormResponse """ # noqa: E501 @@ -154,21 +155,7 @@ class W8ImyFormResponse(BaseModel): sponsored_direct_reporting_nffe_certification: Optional[StrictBool] = Field(default=None, description="Certifies that the entity is a sponsored direct reporting NFFE.", alias="sponsoredDirectReportingNffeCertification") direct_reporting_nffe_sponsoring_entity: Optional[StrictStr] = Field(default=None, description="The name of the entity that sponsors the direct reporting NFFE.", alias="directReportingNffeSponsoringEntity") signer_name: Optional[StrictStr] = Field(default=None, description="The name of the signer.", alias="signerName") - id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") - entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") - entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - display_name: Optional[StrictStr] = Field(default=None, description="The display name associated with the form.", alias="displayName") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - archived: Optional[StrictBool] = Field(default=None, description="Indicates whether the form is archived.") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - signed_date: Optional[datetime] = Field(default=None, description="The date the form was signed.", alias="signedDate") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") - __properties: ClassVar[List[str]] = ["id", "type", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -252,7 +239,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "type": obj.get("type"), "entryStatus": obj.get("entryStatus"), "entryStatusDate": obj.get("entryStatusDate"), "referenceId": obj.get("referenceId"), @@ -264,7 +250,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), "createdAt": obj.get("createdAt"), - "updatedAt": obj.get("updatedAt") + "updatedAt": obj.get("updatedAt"), + "type": obj.get("type") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w9_form_base_request.py b/Avalara/SDK/models/A1099/V2/w9_form_base_request.py index fff39ee..514686b 100644 --- a/Avalara/SDK/models/A1099/V2/w9_form_base_request.py +++ b/Avalara/SDK/models/A1099/V2/w9_form_base_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w9_form_base_response.py b/Avalara/SDK/models/A1099/V2/w9_form_base_response.py index 601eceb..eef8159 100644 --- a/Avalara/SDK/models/A1099/V2/w9_form_base_response.py +++ b/Avalara/SDK/models/A1099/V2/w9_form_base_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -34,17 +34,25 @@ import json from datetime import datetime +from importlib import import_module from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr -from typing import Any, ClassVar, Dict, List, Optional +from typing import Any, ClassVar, Dict, List, Optional, Union from typing import Optional, Set from typing_extensions import Self +from typing import TYPE_CHECKING +if TYPE_CHECKING: + from Avalara.SDK.models.A1099.V2.w4_form_response import W4FormResponse + from Avalara.SDK.models.A1099.V2.w8_ben_e_form_response import W8BenEFormResponse + from Avalara.SDK.models.A1099.V2.w8_ben_form_response import W8BenFormResponse + from Avalara.SDK.models.A1099.V2.w8_imy_form_response import W8ImyFormResponse + from Avalara.SDK.models.A1099.V2.w9_form_response import W9FormResponse + class W9FormBaseResponse(BaseModel): """ W9FormBaseResponse """ # noqa: E501 id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") @@ -57,6 +65,7 @@ class W9FormBaseResponse(BaseModel): e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") + type: Optional[StrictStr] = Field(default=None, description="The type of the response object.") __properties: ClassVar[List[str]] = [] model_config = ConfigDict( @@ -66,6 +75,23 @@ class W9FormBaseResponse(BaseModel): ) + # JSON field name that stores the object type + __discriminator_property_name: ClassVar[str] = 'type' + + # discriminator mappings + __discriminator_value_class_map: ClassVar[Dict[str, str]] = { + 'W4FormResponse': 'W4FormResponse','W8BenEFormResponse': 'W8BenEFormResponse','W8BenFormResponse': 'W8BenFormResponse','W8ImyFormResponse': 'W8ImyFormResponse','W9FormResponse': 'W9FormResponse' + } + + @classmethod + def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]: + """Returns the discriminator value (object type) of the data""" + discriminator_value = obj[cls.__discriminator_property_name] + if discriminator_value: + return cls.__discriminator_value_class_map.get(discriminator_value) + else: + return None + def to_str(self) -> str: """Returns the string representation of the model using alias""" return pprint.pformat(self.model_dump(by_alias=True)) @@ -76,7 +102,7 @@ def to_json(self) -> str: return json.dumps(self.to_dict()) @classmethod - def from_json(cls, json_str: str) -> Optional[Self]: + def from_json(cls, json_str: str) -> Optional[Union[W4FormResponse, W8BenEFormResponse, W8BenFormResponse, W8ImyFormResponse, W9FormResponse]]: """Create an instance of W9FormBaseResponse from a JSON string""" return cls.from_dict(json.loads(json_str)) @@ -101,16 +127,23 @@ def to_dict(self) -> Dict[str, Any]: return _dict @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[W4FormResponse, W8BenEFormResponse, W8BenFormResponse, W8ImyFormResponse, W9FormResponse]]: """Create an instance of W9FormBaseResponse from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - }) - return _obj + # look up the object type based on discriminator mapping + object_type = cls.get_discriminator_value(obj) + if object_type == 'W4FormResponse': + return import_module("Avalara.SDK.models.A1099.V2.w4_form_response").W4FormResponse.from_dict(obj) + if object_type == 'W8BenEFormResponse': + return import_module("Avalara.SDK.models.A1099.V2.w8_ben_e_form_response").W8BenEFormResponse.from_dict(obj) + if object_type == 'W8BenFormResponse': + return import_module("Avalara.SDK.models.A1099.V2.w8_ben_form_response").W8BenFormResponse.from_dict(obj) + if object_type == 'W8ImyFormResponse': + return import_module("Avalara.SDK.models.A1099.V2.w8_imy_form_response").W8ImyFormResponse.from_dict(obj) + if object_type == 'W9FormResponse': + return import_module("Avalara.SDK.models.A1099.V2.w9_form_response").W9FormResponse.from_dict(obj) + + raise ValueError("W9FormBaseResponse failed to lookup discriminator value from " + + json.dumps(obj) + ". Discriminator property name: " + cls.__discriminator_property_name + + ", mapping: " + json.dumps(cls.__discriminator_value_class_map)) diff --git a/Avalara/SDK/models/A1099/V2/w9_form_data_model.py b/Avalara/SDK/models/A1099/V2/w9_form_data_model.py index 06338e6..2eb0dc8 100644 --- a/Avalara/SDK/models/A1099/V2/w9_form_data_model.py +++ b/Avalara/SDK/models/A1099/V2/w9_form_data_model.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w9_form_request.py b/Avalara/SDK/models/A1099/V2/w9_form_request.py index 8b0f50e..e5fdb55 100644 --- a/Avalara/SDK/models/A1099/V2/w9_form_request.py +++ b/Avalara/SDK/models/A1099/V2/w9_form_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w9_form_response.py b/Avalara/SDK/models/A1099/V2/w9_form_response.py index 881cff9..a08f43d 100644 --- a/Avalara/SDK/models/A1099/V2/w9_form_response.py +++ b/Avalara/SDK/models/A1099/V2/w9_form_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,14 +33,14 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from pydantic import ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional from Avalara.SDK.models.A1099.V2.tin_match_status_response import TinMatchStatusResponse +from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self -class W9FormResponse(BaseModel): +class W9FormResponse(W9FormBaseResponse): """ W9FormResponse """ # noqa: E501 @@ -63,21 +63,7 @@ class W9FormResponse(BaseModel): backup_withholding: Optional[StrictBool] = Field(default=None, description="Indicates whether backup withholding applies.", alias="backupWithholding") is1099able: Optional[StrictBool] = Field(default=None, description="Indicates whether the individual or entity should be issued a 1099 form.") tin_match_status: Optional[TinMatchStatusResponse] = Field(default=None, description="The TIN Match status from IRS.", alias="tinMatchStatus") - id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - type: Optional[StrictStr] = Field(default=None, description="The form type.") - entry_status: Optional[StrictStr] = Field(default=None, description="The form status.", alias="entryStatus") - entry_status_date: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.", alias="entryStatusDate") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - display_name: Optional[StrictStr] = Field(default=None, description="The display name associated with the form.", alias="displayName") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - archived: Optional[StrictBool] = Field(default=None, description="Indicates whether the form is archived.") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - signed_date: Optional[datetime] = Field(default=None, description="The date the form was signed.", alias="signedDate") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - created_at: Optional[datetime] = Field(default=None, description="The creation date of the form.", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="The last updated date of the form.", alias="updatedAt") - __properties: ClassVar[List[str]] = ["id", "type", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -161,7 +147,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "type": obj.get("type"), "entryStatus": obj.get("entryStatus"), "entryStatusDate": obj.get("entryStatusDate"), "referenceId": obj.get("referenceId"), @@ -173,7 +158,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), "createdAt": obj.get("createdAt"), - "updatedAt": obj.get("updatedAt") + "updatedAt": obj.get("updatedAt"), + "type": obj.get("type") }) return _obj diff --git a/Avalara/SDK/models/EInvoicing/V1/address.py b/Avalara/SDK/models/EInvoicing/V1/address.py index 5c9cd92..b1e7643 100644 --- a/Avalara/SDK/models/EInvoicing/V1/address.py +++ b/Avalara/SDK/models/EInvoicing/V1/address.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/bad_download_request.py b/Avalara/SDK/models/EInvoicing/V1/bad_download_request.py index 4e670e1..fcceab4 100644 --- a/Avalara/SDK/models/EInvoicing/V1/bad_download_request.py +++ b/Avalara/SDK/models/EInvoicing/V1/bad_download_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/bad_request.py b/Avalara/SDK/models/EInvoicing/V1/bad_request.py index 8a987a7..4cb4f7b 100644 --- a/Avalara/SDK/models/EInvoicing/V1/bad_request.py +++ b/Avalara/SDK/models/EInvoicing/V1/bad_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/batch_error_detail.py b/Avalara/SDK/models/EInvoicing/V1/batch_error_detail.py index 723faa0..b282386 100644 --- a/Avalara/SDK/models/EInvoicing/V1/batch_error_detail.py +++ b/Avalara/SDK/models/EInvoicing/V1/batch_error_detail.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/batch_search.py b/Avalara/SDK/models/EInvoicing/V1/batch_search.py index fbf3264..04097ed 100644 --- a/Avalara/SDK/models/EInvoicing/V1/batch_search.py +++ b/Avalara/SDK/models/EInvoicing/V1/batch_search.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/batch_search_list_response.py b/Avalara/SDK/models/EInvoicing/V1/batch_search_list_response.py index 1167bcd..3a342c1 100644 --- a/Avalara/SDK/models/EInvoicing/V1/batch_search_list_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/batch_search_list_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/batch_search_participants202_response.py b/Avalara/SDK/models/EInvoicing/V1/batch_search_participants202_response.py index b3b536d..1d3a8fa 100644 --- a/Avalara/SDK/models/EInvoicing/V1/batch_search_participants202_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/batch_search_participants202_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/conditional_for_field.py b/Avalara/SDK/models/EInvoicing/V1/conditional_for_field.py index 2ac655b..cab1a1d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/conditional_for_field.py +++ b/Avalara/SDK/models/EInvoicing/V1/conditional_for_field.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/consents.py b/Avalara/SDK/models/EInvoicing/V1/consents.py index 68e6436..3f6fa5c 100644 --- a/Avalara/SDK/models/EInvoicing/V1/consents.py +++ b/Avalara/SDK/models/EInvoicing/V1/consents.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/create_trading_partner201_response.py b/Avalara/SDK/models/EInvoicing/V1/create_trading_partner201_response.py index 2d8799f..7503ba6 100644 --- a/Avalara/SDK/models/EInvoicing/V1/create_trading_partner201_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/create_trading_partner201_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response.py b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response.py index 761ae7b..12bfbce 100644 --- a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response_value_inner.py b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response_value_inner.py index 17ffc5d..cf2038b 100644 --- a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response_value_inner.py +++ b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch200_response_value_inner.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch_request.py b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch_request.py index c6be117..8d90f1d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch_request.py +++ b/Avalara/SDK/models/EInvoicing/V1/create_trading_partners_batch_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/data_input_field.py b/Avalara/SDK/models/EInvoicing/V1/data_input_field.py index e368448..dba2491 100644 --- a/Avalara/SDK/models/EInvoicing/V1/data_input_field.py +++ b/Avalara/SDK/models/EInvoicing/V1/data_input_field.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/data_input_field_not_used_for.py b/Avalara/SDK/models/EInvoicing/V1/data_input_field_not_used_for.py index 7be957c..1c250ef 100644 --- a/Avalara/SDK/models/EInvoicing/V1/data_input_field_not_used_for.py +++ b/Avalara/SDK/models/EInvoicing/V1/data_input_field_not_used_for.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/data_input_field_optional_for.py b/Avalara/SDK/models/EInvoicing/V1/data_input_field_optional_for.py index d87759a..c8e6c18 100644 --- a/Avalara/SDK/models/EInvoicing/V1/data_input_field_optional_for.py +++ b/Avalara/SDK/models/EInvoicing/V1/data_input_field_optional_for.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/data_input_field_required_for.py b/Avalara/SDK/models/EInvoicing/V1/data_input_field_required_for.py index 8c1ba9f..b0814cc 100644 --- a/Avalara/SDK/models/EInvoicing/V1/data_input_field_required_for.py +++ b/Avalara/SDK/models/EInvoicing/V1/data_input_field_required_for.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/data_input_fields_response.py b/Avalara/SDK/models/EInvoicing/V1/data_input_fields_response.py index a448c2e..7364a09 100644 --- a/Avalara/SDK/models/EInvoicing/V1/data_input_fields_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/data_input_fields_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_fetch.py b/Avalara/SDK/models/EInvoicing/V1/document_fetch.py index acb4d94..e32d8b9 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_fetch.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_fetch.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_list_response.py b/Avalara/SDK/models/EInvoicing/V1/document_list_response.py index ce9ddb3..ee8faa7 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_list_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_list_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_status_response.py b/Avalara/SDK/models/EInvoicing/V1/document_status_response.py index cbd5106..f4c07d9 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_status_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_status_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_submission_error.py b/Avalara/SDK/models/EInvoicing/V1/document_submission_error.py index 98adbf0..7cc405d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_submission_error.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_submission_error.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_submit_response.py b/Avalara/SDK/models/EInvoicing/V1/document_submit_response.py index 8bbe0f1..d7a2f2e 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_submit_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_submit_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/document_summary.py b/Avalara/SDK/models/EInvoicing/V1/document_summary.py index db9e4ea..c5c0602 100644 --- a/Avalara/SDK/models/EInvoicing/V1/document_summary.py +++ b/Avalara/SDK/models/EInvoicing/V1/document_summary.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/error_response.py b/Avalara/SDK/models/EInvoicing/V1/error_response.py index 8f78203..94700e9 100644 --- a/Avalara/SDK/models/EInvoicing/V1/error_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/error_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/event_id.py b/Avalara/SDK/models/EInvoicing/V1/event_id.py index ba294b4..caa0d76 100644 --- a/Avalara/SDK/models/EInvoicing/V1/event_id.py +++ b/Avalara/SDK/models/EInvoicing/V1/event_id.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/event_message.py b/Avalara/SDK/models/EInvoicing/V1/event_message.py index 4982708..dd2aa71 100644 --- a/Avalara/SDK/models/EInvoicing/V1/event_message.py +++ b/Avalara/SDK/models/EInvoicing/V1/event_message.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/event_payload.py b/Avalara/SDK/models/EInvoicing/V1/event_payload.py index f028154..deba433 100644 --- a/Avalara/SDK/models/EInvoicing/V1/event_payload.py +++ b/Avalara/SDK/models/EInvoicing/V1/event_payload.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/event_subscription.py b/Avalara/SDK/models/EInvoicing/V1/event_subscription.py index 540311f..403a857 100644 --- a/Avalara/SDK/models/EInvoicing/V1/event_subscription.py +++ b/Avalara/SDK/models/EInvoicing/V1/event_subscription.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/extension.py b/Avalara/SDK/models/EInvoicing/V1/extension.py index 23931a8..27b84d6 100644 --- a/Avalara/SDK/models/EInvoicing/V1/extension.py +++ b/Avalara/SDK/models/EInvoicing/V1/extension.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request.py b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request.py index 16b013e..338db83 100644 --- a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request.py +++ b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_data_inner.py b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_data_inner.py index 2d0ad3f..3b4ba69 100644 --- a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_data_inner.py +++ b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_data_inner.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_metadata.py b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_metadata.py index df51df1..f99a9d0 100644 --- a/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_metadata.py +++ b/Avalara/SDK/models/EInvoicing/V1/fetch_documents_request_metadata.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/forbidden_error.py b/Avalara/SDK/models/EInvoicing/V1/forbidden_error.py index 58b6329..4440b6d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/forbidden_error.py +++ b/Avalara/SDK/models/EInvoicing/V1/forbidden_error.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/hmac_signature.py b/Avalara/SDK/models/EInvoicing/V1/hmac_signature.py index 488d74a..35c0c1a 100644 --- a/Avalara/SDK/models/EInvoicing/V1/hmac_signature.py +++ b/Avalara/SDK/models/EInvoicing/V1/hmac_signature.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/hmac_signature_value.py b/Avalara/SDK/models/EInvoicing/V1/hmac_signature_value.py index 61ebeca..775c586 100644 --- a/Avalara/SDK/models/EInvoicing/V1/hmac_signature_value.py +++ b/Avalara/SDK/models/EInvoicing/V1/hmac_signature_value.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/id.py b/Avalara/SDK/models/EInvoicing/V1/id.py index 5cf300f..f8c95f8 100644 --- a/Avalara/SDK/models/EInvoicing/V1/id.py +++ b/Avalara/SDK/models/EInvoicing/V1/id.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/identifier.py b/Avalara/SDK/models/EInvoicing/V1/identifier.py index f8b1ae9..fe8e895 100644 --- a/Avalara/SDK/models/EInvoicing/V1/identifier.py +++ b/Avalara/SDK/models/EInvoicing/V1/identifier.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/input_data_formats.py b/Avalara/SDK/models/EInvoicing/V1/input_data_formats.py index 230c306..334a89d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/input_data_formats.py +++ b/Avalara/SDK/models/EInvoicing/V1/input_data_formats.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/internal_server_error.py b/Avalara/SDK/models/EInvoicing/V1/internal_server_error.py index 45ce43f..ddef552 100644 --- a/Avalara/SDK/models/EInvoicing/V1/internal_server_error.py +++ b/Avalara/SDK/models/EInvoicing/V1/internal_server_error.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/mandate.py b/Avalara/SDK/models/EInvoicing/V1/mandate.py index ad508ae..e5a2161 100644 --- a/Avalara/SDK/models/EInvoicing/V1/mandate.py +++ b/Avalara/SDK/models/EInvoicing/V1/mandate.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field.py b/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field.py index d126b7e..07b5c64 100644 --- a/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field.py +++ b/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field_namespace.py b/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field_namespace.py index 3f6ae4f..79da3a8 100644 --- a/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field_namespace.py +++ b/Avalara/SDK/models/EInvoicing/V1/mandate_data_input_field_namespace.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/mandates_response.py b/Avalara/SDK/models/EInvoicing/V1/mandates_response.py index b73718c..b4dc3bd 100644 --- a/Avalara/SDK/models/EInvoicing/V1/mandates_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/mandates_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/not_found_error.py b/Avalara/SDK/models/EInvoicing/V1/not_found_error.py index a3511db..09d76f2 100644 --- a/Avalara/SDK/models/EInvoicing/V1/not_found_error.py +++ b/Avalara/SDK/models/EInvoicing/V1/not_found_error.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/not_used_for_field.py b/Avalara/SDK/models/EInvoicing/V1/not_used_for_field.py index da4a41d..2660e43 100644 --- a/Avalara/SDK/models/EInvoicing/V1/not_used_for_field.py +++ b/Avalara/SDK/models/EInvoicing/V1/not_used_for_field.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/output_data_formats.py b/Avalara/SDK/models/EInvoicing/V1/output_data_formats.py index ed1ffdd..003514b 100644 --- a/Avalara/SDK/models/EInvoicing/V1/output_data_formats.py +++ b/Avalara/SDK/models/EInvoicing/V1/output_data_formats.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/pagination.py b/Avalara/SDK/models/EInvoicing/V1/pagination.py index 691d26d..47831bc 100644 --- a/Avalara/SDK/models/EInvoicing/V1/pagination.py +++ b/Avalara/SDK/models/EInvoicing/V1/pagination.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/required_when_field.py b/Avalara/SDK/models/EInvoicing/V1/required_when_field.py index 29e265c..4e6974c 100644 --- a/Avalara/SDK/models/EInvoicing/V1/required_when_field.py +++ b/Avalara/SDK/models/EInvoicing/V1/required_when_field.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/search_participants200_response.py b/Avalara/SDK/models/EInvoicing/V1/search_participants200_response.py index 48ec179..1c958a0 100644 --- a/Avalara/SDK/models/EInvoicing/V1/search_participants200_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/search_participants200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/signature.py b/Avalara/SDK/models/EInvoicing/V1/signature.py index 2d44421..2157621 100644 --- a/Avalara/SDK/models/EInvoicing/V1/signature.py +++ b/Avalara/SDK/models/EInvoicing/V1/signature.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/signature_signature.py b/Avalara/SDK/models/EInvoicing/V1/signature_signature.py index ffbc62e..0c22be6 100644 --- a/Avalara/SDK/models/EInvoicing/V1/signature_signature.py +++ b/Avalara/SDK/models/EInvoicing/V1/signature_signature.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/signature_value.py b/Avalara/SDK/models/EInvoicing/V1/signature_value.py index af6cac0..ed8822d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/signature_value.py +++ b/Avalara/SDK/models/EInvoicing/V1/signature_value.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/signature_value_signature.py b/Avalara/SDK/models/EInvoicing/V1/signature_value_signature.py index 24bd6ab..3ed8f3b 100644 --- a/Avalara/SDK/models/EInvoicing/V1/signature_value_signature.py +++ b/Avalara/SDK/models/EInvoicing/V1/signature_value_signature.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/status_event.py b/Avalara/SDK/models/EInvoicing/V1/status_event.py index 25bcbbd..a658d82 100644 --- a/Avalara/SDK/models/EInvoicing/V1/status_event.py +++ b/Avalara/SDK/models/EInvoicing/V1/status_event.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/submit_document_metadata.py b/Avalara/SDK/models/EInvoicing/V1/submit_document_metadata.py index 69efe3e..ef6193b 100644 --- a/Avalara/SDK/models/EInvoicing/V1/submit_document_metadata.py +++ b/Avalara/SDK/models/EInvoicing/V1/submit_document_metadata.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/submit_interop_document202_response.py b/Avalara/SDK/models/EInvoicing/V1/submit_interop_document202_response.py index f62e3ed..7a87aa2 100644 --- a/Avalara/SDK/models/EInvoicing/V1/submit_interop_document202_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/submit_interop_document202_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/subscription_common.py b/Avalara/SDK/models/EInvoicing/V1/subscription_common.py index b9a34b4..909b40d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/subscription_common.py +++ b/Avalara/SDK/models/EInvoicing/V1/subscription_common.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/subscription_detail.py b/Avalara/SDK/models/EInvoicing/V1/subscription_detail.py index f61bd0e..cd5ea38 100644 --- a/Avalara/SDK/models/EInvoicing/V1/subscription_detail.py +++ b/Avalara/SDK/models/EInvoicing/V1/subscription_detail.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/subscription_list_response.py b/Avalara/SDK/models/EInvoicing/V1/subscription_list_response.py index 161c772..a1dd14a 100644 --- a/Avalara/SDK/models/EInvoicing/V1/subscription_list_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/subscription_list_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/subscription_registration.py b/Avalara/SDK/models/EInvoicing/V1/subscription_registration.py index d667e41..b59334e 100644 --- a/Avalara/SDK/models/EInvoicing/V1/subscription_registration.py +++ b/Avalara/SDK/models/EInvoicing/V1/subscription_registration.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/success_response.py b/Avalara/SDK/models/EInvoicing/V1/success_response.py index 2211422..5cf3cdc 100644 --- a/Avalara/SDK/models/EInvoicing/V1/success_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/success_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/supported_document_types.py b/Avalara/SDK/models/EInvoicing/V1/supported_document_types.py index 0e3cfcd..287b55d 100644 --- a/Avalara/SDK/models/EInvoicing/V1/supported_document_types.py +++ b/Avalara/SDK/models/EInvoicing/V1/supported_document_types.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_request.py b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_request.py index 91b2bfc..1787110 100644 --- a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_request.py +++ b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_request.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response.py b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response.py index 471cf38..cfe89db 100644 --- a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response_value.py b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response_value.py index b07575c..02b5c43 100644 --- a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response_value.py +++ b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_response_value.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_schema_by_country200_response.py b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_schema_by_country200_response.py index 43ee287..31cc534 100644 --- a/Avalara/SDK/models/EInvoicing/V1/tax_identifier_schema_by_country200_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/tax_identifier_schema_by_country200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/trading_partner.py b/Avalara/SDK/models/EInvoicing/V1/trading_partner.py index 9e58576..9a92d78 100644 --- a/Avalara/SDK/models/EInvoicing/V1/trading_partner.py +++ b/Avalara/SDK/models/EInvoicing/V1/trading_partner.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/update_trading_partner200_response.py b/Avalara/SDK/models/EInvoicing/V1/update_trading_partner200_response.py index bca5f97..ae4365c 100644 --- a/Avalara/SDK/models/EInvoicing/V1/update_trading_partner200_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/update_trading_partner200_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/validation_error.py b/Avalara/SDK/models/EInvoicing/V1/validation_error.py index 57d13da..e2dc685 100644 --- a/Avalara/SDK/models/EInvoicing/V1/validation_error.py +++ b/Avalara/SDK/models/EInvoicing/V1/validation_error.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/webhook_invocation.py b/Avalara/SDK/models/EInvoicing/V1/webhook_invocation.py index 0ebd13b..daca410 100644 --- a/Avalara/SDK/models/EInvoicing/V1/webhook_invocation.py +++ b/Avalara/SDK/models/EInvoicing/V1/webhook_invocation.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/webhooks_error_info.py b/Avalara/SDK/models/EInvoicing/V1/webhooks_error_info.py index 6cfc29f..509201c 100644 --- a/Avalara/SDK/models/EInvoicing/V1/webhooks_error_info.py +++ b/Avalara/SDK/models/EInvoicing/V1/webhooks_error_info.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/webhooks_error_response.py b/Avalara/SDK/models/EInvoicing/V1/webhooks_error_response.py index 1e18763..c4be4e2 100644 --- a/Avalara/SDK/models/EInvoicing/V1/webhooks_error_response.py +++ b/Avalara/SDK/models/EInvoicing/V1/webhooks_error_response.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/EInvoicing/V1/workflow_ids.py b/Avalara/SDK/models/EInvoicing/V1/workflow_ids.py index 704628a..9f05a65 100644 --- a/Avalara/SDK/models/EInvoicing/V1/workflow_ids.py +++ b/Avalara/SDK/models/EInvoicing/V1/workflow_ids.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/README.md b/README.md index 81b11b2..34eebf7 100644 --- a/README.md +++ b/README.md @@ -297,6 +297,7 @@ Class | Method | HTTP request | Description - [Avalara.SDK.models.A1099.V2.CompanyModel](docs/A1099/V2/CompanyModel.md) - [Avalara.SDK.models.A1099.V2.CompanyResponse](docs/A1099/V2/CompanyResponse.md) - [Avalara.SDK.models.A1099.V2.CompanyResponseModel](docs/A1099/V2/CompanyResponseModel.md) + - [Avalara.SDK.models.A1099.V2.CoveredIndividualReference](docs/A1099/V2/CoveredIndividualReference.md) - [Avalara.SDK.models.A1099.V2.CoveredIndividualReferenceResponse](docs/A1099/V2/CoveredIndividualReferenceResponse.md) - [Avalara.SDK.models.A1099.V2.CoveredIndividualRequest](docs/A1099/V2/CoveredIndividualRequest.md) - [Avalara.SDK.models.A1099.V2.Create1099Form201Response](docs/A1099/V2/Create1099Form201Response.md) @@ -305,24 +306,36 @@ Class | Method | HTTP request | Description - [Avalara.SDK.models.A1099.V2.Data](docs/A1099/V2/Data.md) - [Avalara.SDK.models.A1099.V2.ErrorModel](docs/A1099/V2/ErrorModel.md) - [Avalara.SDK.models.A1099.V2.ErrorResponse](docs/A1099/V2/ErrorResponse.md) - - [Avalara.SDK.models.A1099.V2.ErrorResponseErrorsInner](docs/A1099/V2/ErrorResponseErrorsInner.md) + - [Avalara.SDK.models.A1099.V2.ErrorResponseItem](docs/A1099/V2/ErrorResponseItem.md) + - [Avalara.SDK.models.A1099.V2.Form1042S](docs/A1099/V2/Form1042S.md) - [Avalara.SDK.models.A1099.V2.Form1042SList](docs/A1099/V2/Form1042SList.md) - [Avalara.SDK.models.A1099.V2.Form1042SListItem](docs/A1099/V2/Form1042SListItem.md) - [Avalara.SDK.models.A1099.V2.Form1042SListItemResponse](docs/A1099/V2/Form1042SListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1042SRequest](docs/A1099/V2/Form1042SRequest.md) - [Avalara.SDK.models.A1099.V2.Form1042SResponse](docs/A1099/V2/Form1042SResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1095B](docs/A1099/V2/Form1095B.md) - [Avalara.SDK.models.A1099.V2.Form1095BList](docs/A1099/V2/Form1095BList.md) - [Avalara.SDK.models.A1099.V2.Form1095BListItem](docs/A1099/V2/Form1095BListItem.md) - [Avalara.SDK.models.A1099.V2.Form1095BListItemResponse](docs/A1099/V2/Form1095BListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1095BRequest](docs/A1099/V2/Form1095BRequest.md) + - [Avalara.SDK.models.A1099.V2.Form1095BResponse](docs/A1099/V2/Form1095BResponse.md) - [Avalara.SDK.models.A1099.V2.Form1095CList](docs/A1099/V2/Form1095CList.md) - [Avalara.SDK.models.A1099.V2.Form1095CListItem](docs/A1099/V2/Form1095CListItem.md) + - [Avalara.SDK.models.A1099.V2.Form1099Base](docs/A1099/V2/Form1099Base.md) - [Avalara.SDK.models.A1099.V2.Form1099BaseResponse](docs/A1099/V2/Form1099BaseResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099Div](docs/A1099/V2/Form1099Div.md) - [Avalara.SDK.models.A1099.V2.Form1099DivList](docs/A1099/V2/Form1099DivList.md) - [Avalara.SDK.models.A1099.V2.Form1099DivListItem](docs/A1099/V2/Form1099DivListItem.md) - [Avalara.SDK.models.A1099.V2.Form1099DivListItemResponse](docs/A1099/V2/Form1099DivListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099DivRequest](docs/A1099/V2/Form1099DivRequest.md) - [Avalara.SDK.models.A1099.V2.Form1099DivResponse](docs/A1099/V2/Form1099DivResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099Int](docs/A1099/V2/Form1099Int.md) + - [Avalara.SDK.models.A1099.V2.Form1099IntList](docs/A1099/V2/Form1099IntList.md) + - [Avalara.SDK.models.A1099.V2.Form1099IntListItem](docs/A1099/V2/Form1099IntListItem.md) + - [Avalara.SDK.models.A1099.V2.Form1099IntListItemResponse](docs/A1099/V2/Form1099IntListItemResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099IntRequest](docs/A1099/V2/Form1099IntRequest.md) + - [Avalara.SDK.models.A1099.V2.Form1099IntResponse](docs/A1099/V2/Form1099IntResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099K](docs/A1099/V2/Form1099K.md) - [Avalara.SDK.models.A1099.V2.Form1099KList](docs/A1099/V2/Form1099KList.md) - [Avalara.SDK.models.A1099.V2.Form1099KListItem](docs/A1099/V2/Form1099KListItem.md) - [Avalara.SDK.models.A1099.V2.Form1099KListItemResponse](docs/A1099/V2/Form1099KListItemResponse.md) @@ -330,30 +343,36 @@ Class | Method | HTTP request | Description - [Avalara.SDK.models.A1099.V2.Form1099KResponse](docs/A1099/V2/Form1099KResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099ListResponse](docs/A1099/V2/Form1099ListResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099ListResponseValueInner](docs/A1099/V2/Form1099ListResponseValueInner.md) + - [Avalara.SDK.models.A1099.V2.Form1099Misc](docs/A1099/V2/Form1099Misc.md) - [Avalara.SDK.models.A1099.V2.Form1099MiscList](docs/A1099/V2/Form1099MiscList.md) - [Avalara.SDK.models.A1099.V2.Form1099MiscListItem](docs/A1099/V2/Form1099MiscListItem.md) - [Avalara.SDK.models.A1099.V2.Form1099MiscListItemResponse](docs/A1099/V2/Form1099MiscListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099MiscRequest](docs/A1099/V2/Form1099MiscRequest.md) - [Avalara.SDK.models.A1099.V2.Form1099MiscResponse](docs/A1099/V2/Form1099MiscResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099Nec](docs/A1099/V2/Form1099Nec.md) - [Avalara.SDK.models.A1099.V2.Form1099NecList](docs/A1099/V2/Form1099NecList.md) - [Avalara.SDK.models.A1099.V2.Form1099NecListItem](docs/A1099/V2/Form1099NecListItem.md) - [Avalara.SDK.models.A1099.V2.Form1099NecListItemResponse](docs/A1099/V2/Form1099NecListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099NecRequest](docs/A1099/V2/Form1099NecRequest.md) - [Avalara.SDK.models.A1099.V2.Form1099NecResponse](docs/A1099/V2/Form1099NecResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099ProccessResult](docs/A1099/V2/Form1099ProccessResult.md) + - [Avalara.SDK.models.A1099.V2.Form1099ProccessResultProcessedFormsInner](docs/A1099/V2/Form1099ProccessResultProcessedFormsInner.md) + - [Avalara.SDK.models.A1099.V2.Form1099R](docs/A1099/V2/Form1099R.md) - [Avalara.SDK.models.A1099.V2.Form1099RList](docs/A1099/V2/Form1099RList.md) - [Avalara.SDK.models.A1099.V2.Form1099RListItem](docs/A1099/V2/Form1099RListItem.md) - [Avalara.SDK.models.A1099.V2.Form1099RListItemResponse](docs/A1099/V2/Form1099RListItemResponse.md) - [Avalara.SDK.models.A1099.V2.Form1099RRequest](docs/A1099/V2/Form1099RRequest.md) + - [Avalara.SDK.models.A1099.V2.Form1099RResponse](docs/A1099/V2/Form1099RResponse.md) + - [Avalara.SDK.models.A1099.V2.Form1099StatusDetail](docs/A1099/V2/Form1099StatusDetail.md) - [Avalara.SDK.models.A1099.V2.FormRequestBase](docs/A1099/V2/FormRequestBase.md) - [Avalara.SDK.models.A1099.V2.FormRequestListItemBase](docs/A1099/V2/FormRequestListItemBase.md) - [Avalara.SDK.models.A1099.V2.FormResponseBase](docs/A1099/V2/FormResponseBase.md) - [Avalara.SDK.models.A1099.V2.FormSingleRequestBase](docs/A1099/V2/FormSingleRequestBase.md) - [Avalara.SDK.models.A1099.V2.Get1099Form200Response](docs/A1099/V2/Get1099Form200Response.md) - - [Avalara.SDK.models.A1099.V2.HttpValidationProblemDetails](docs/A1099/V2/HttpValidationProblemDetails.md) - [Avalara.SDK.models.A1099.V2.ICreateForm1099Request](docs/A1099/V2/ICreateForm1099Request.md) - [Avalara.SDK.models.A1099.V2.IUpdateForm1099Request](docs/A1099/V2/IUpdateForm1099Request.md) - [Avalara.SDK.models.A1099.V2.IW9FormDataModelsOneOf](docs/A1099/V2/IW9FormDataModelsOneOf.md) + - [Avalara.SDK.models.A1099.V2.IncludedBase](docs/A1099/V2/IncludedBase.md) - [Avalara.SDK.models.A1099.V2.IntermediaryOrFlowThrough](docs/A1099/V2/IntermediaryOrFlowThrough.md) - [Avalara.SDK.models.A1099.V2.IntermediaryOrFlowThroughRequest](docs/A1099/V2/IntermediaryOrFlowThroughRequest.md) - [Avalara.SDK.models.A1099.V2.IntermediaryOrFlowThroughResponse](docs/A1099/V2/IntermediaryOrFlowThroughResponse.md) @@ -363,22 +382,23 @@ Class | Method | HTTP request | Description - [Avalara.SDK.models.A1099.V2.JobResult](docs/A1099/V2/JobResult.md) - [Avalara.SDK.models.A1099.V2.Link](docs/A1099/V2/Link.md) - [Avalara.SDK.models.A1099.V2.OfferAndCoverageRequest](docs/A1099/V2/OfferAndCoverageRequest.md) - - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModel](docs/A1099/V2/PaginatedQueryResultModel.md) - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelCompanyResponse](docs/A1099/V2/PaginatedQueryResultModelCompanyResponse.md) - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelIssuerResponse](docs/A1099/V2/PaginatedQueryResultModelIssuerResponse.md) - - [Avalara.SDK.models.A1099.V2.PaginatedW9FormsModel](docs/A1099/V2/PaginatedW9FormsModel.md) + - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelW9FormBaseResponse](docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md) - [Avalara.SDK.models.A1099.V2.PrimaryWithholdingAgent](docs/A1099/V2/PrimaryWithholdingAgent.md) - [Avalara.SDK.models.A1099.V2.PrimaryWithholdingAgentRequest](docs/A1099/V2/PrimaryWithholdingAgentRequest.md) - [Avalara.SDK.models.A1099.V2.PrimaryWithholdingAgentResponse](docs/A1099/V2/PrimaryWithholdingAgentResponse.md) - - [Avalara.SDK.models.A1099.V2.ProblemDetails](docs/A1099/V2/ProblemDetails.md) + - [Avalara.SDK.models.A1099.V2.StateAndLocalWithholding](docs/A1099/V2/StateAndLocalWithholding.md) - [Avalara.SDK.models.A1099.V2.StateAndLocalWithholdingRequest](docs/A1099/V2/StateAndLocalWithholdingRequest.md) - [Avalara.SDK.models.A1099.V2.StateAndLocalWithholdingResponse](docs/A1099/V2/StateAndLocalWithholdingResponse.md) + - [Avalara.SDK.models.A1099.V2.StateEfileStatusDetail](docs/A1099/V2/StateEfileStatusDetail.md) - [Avalara.SDK.models.A1099.V2.StateEfileStatusDetailResponse](docs/A1099/V2/StateEfileStatusDetailResponse.md) - [Avalara.SDK.models.A1099.V2.StatusDetail](docs/A1099/V2/StatusDetail.md) - [Avalara.SDK.models.A1099.V2.SubstantialUsOwnerRequest](docs/A1099/V2/SubstantialUsOwnerRequest.md) - [Avalara.SDK.models.A1099.V2.SubstantialUsOwnerResponse](docs/A1099/V2/SubstantialUsOwnerResponse.md) - [Avalara.SDK.models.A1099.V2.TinMatchStatusResponse](docs/A1099/V2/TinMatchStatusResponse.md) - [Avalara.SDK.models.A1099.V2.Update1099Form200Response](docs/A1099/V2/Update1099Form200Response.md) + - [Avalara.SDK.models.A1099.V2.ValidationError](docs/A1099/V2/ValidationError.md) - [Avalara.SDK.models.A1099.V2.ValidationErrorResponse](docs/A1099/V2/ValidationErrorResponse.md) - [Avalara.SDK.models.A1099.V2.W4FormDataModel](docs/A1099/V2/W4FormDataModel.md) - [Avalara.SDK.models.A1099.V2.W4FormRequest](docs/A1099/V2/W4FormRequest.md) diff --git a/docs/A1099/V2/CompaniesW9Api.md b/docs/A1099/V2/CompaniesW9Api.md index 48be9b6..184776a 100644 --- a/docs/A1099/V2/CompaniesW9Api.md +++ b/docs/A1099/V2/CompaniesW9Api.md @@ -45,7 +45,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = companies_w9_api.CompaniesW9Api(api_client) avalara_version = '2.0.0' # str | API version - x_correlation_id = '097506be-b40b-4107-8d62-206070d11548' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '5ba3a8b6-bf05-4aaa-b8cb-d06c7cfea0f7' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) company_create_update_request_model = Avalara.SDK.CompanyCreateUpdateRequestModel() # CompanyCreateUpdateRequestModel | The company to create (optional) # example passing only required values which don't have defaults set @@ -132,7 +132,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = companies_w9_api.CompaniesW9Api(api_client) id = 'id_example' # str | The company to delete avalara_version = '2.0.0' # str | API version - x_correlation_id = '3af2abb1-7024-4cc7-9c52-53e793e1c863' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '07a8ecdb-0465-469d-8bff-49fce135d5e4' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -224,7 +224,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: order_by = 'order_by_example' # str | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. (optional) count = True # bool | If true, return the global count of elements in the collection. (optional) count_only = True # bool | If true, return ONLY the global count of elements in the collection. It only applies when count=true. (optional) - x_correlation_id = 'bbe9eb96-736f-4c5c-99d7-9df8f66819b3' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'f047fdc5-a6e4-4290-8c5c-d4da96ad0699' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -318,7 +318,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = companies_w9_api.CompaniesW9Api(api_client) id = 'id_example' # str | Id of the company avalara_version = '2.0.0' # str | API version - x_correlation_id = 'e6013371-7d72-4c3d-8a5f-c4e08177c3ae' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '3f7b5971-06e7-4459-84af-61db7fdcb027' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -408,7 +408,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = companies_w9_api.CompaniesW9Api(api_client) id = 'id_example' # str | The ID of the company to update avalara_version = '2.0.0' # str | API version - x_correlation_id = 'd8a0cb91-eb8b-4bd6-8812-2b690995afcc' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '1cd32062-b0bc-46a0-8311-a973b8fb3d56' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) company_create_update_request_model = Avalara.SDK.CompanyCreateUpdateRequestModel() # CompanyCreateUpdateRequestModel | The updated company data (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/Create1099Form201Response.md b/docs/A1099/V2/Create1099Form201Response.md index a129b40..e92b6c0 100644 --- a/docs/A1099/V2/Create1099Form201Response.md +++ b/docs/A1099/V2/Create1099Form201Response.md @@ -69,24 +69,35 @@ Name | Type | Description | Notes **intermediary_or_flow_through** | [**IntermediaryOrFlowThroughResponse**](IntermediaryOrFlowThroughResponse.md) | Intermediary or flow-through entity information | [optional] **origin_of_health_coverage_code** | **str** | Origin of health coverage code | [optional] **covered_individuals** | [**List[CoveredIndividualReferenceResponse]**](CoveredIndividualReferenceResponse.md) | Covered individuals information | [optional] -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] **federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early withdrawal penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-exempt interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified private activity bond interest | [optional] +**market_discount** | **float** | Market discount | [optional] +**bond_premium** | **float** | Bond premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP number | [optional] **filer_type** | **str** | Filer type (PSE or EPF) | [optional] **payment_type** | **str** | Payment type (payment card or third party network) | [optional] **payment_settlement_entity_name_phone_number** | **str** | Payment settlement entity name and phone number | [optional] @@ -138,7 +149,6 @@ Name | Type | Description | Notes **total_employee_contributions** | **float** | Total employee contributions | [optional] **amount_allocable_to_irr** | **float** | Amount allocable to IRR within 5 years | [optional] **first_year_designated_roth_contrib** | **str** | First year of designated Roth contribution | [optional] -**fatca_requirement_indicator** | **bool** | FATCA filing requirement | [optional] **date_of_payment** | **str** | Date of payment | [optional] ## Example diff --git a/docs/A1099/V2/CreateW9Form201Response.md b/docs/A1099/V2/CreateW9Form201Response.md index 4c95fd6..aba5827 100644 --- a/docs/A1099/V2/CreateW9Form201Response.md +++ b/docs/A1099/V2/CreateW9Form201Response.md @@ -5,39 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**employee_first_name** | **str** | The first name of the employee. | [optional] -**employee_middle_name** | **str** | The middle name of the employee. | [optional] -**employee_last_name** | **str** | The last name of the employee. | [optional] -**employee_name_suffix** | **str** | The name suffix of the employee. | [optional] -**tin_type** | **str** | The type of TIN provided. | [optional] -**tin** | **str** | The taxpayer identification number (TIN). | [optional] -**address** | **str** | The address of the individual or entity. | [optional] -**city** | **str** | The city of the address. | [optional] -**state** | **str** | The state of the address. | [optional] -**zip** | **str** | The ZIP code of the address. | [optional] -**marital_status** | **str** | The marital status of the employee. | [optional] -**last_name_differs** | **bool** | Indicates whether the last name differs from prior records. | [optional] -**num_allowances** | **int** | The number of allowances claimed by the employee. | [optional] -**other_dependents** | **int** | The number of dependents other than allowances. | [optional] -**non_job_income** | **float** | The amount of non-job income. | [optional] -**deductions** | **float** | The amount of deductions claimed. | [optional] -**additional_withheld** | **float** | The additional amount withheld. | [optional] -**exempt_from_withholding** | **bool** | Indicates whether the employee is exempt from withholding. | [optional] -**office_code** | **str** | The office code associated with the form. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] **name** | **str** | The name of the individual or entity associated with the form. | [optional] **citizenship_country** | **str** | The country of citizenship. | [optional] **disregarded_entity** | **str** | The name of the disregarded entity receiving the payment (if applicable). | [optional] @@ -55,6 +22,8 @@ Name | Type | Description | Notes **mailing_state** | **str** | The state of the mailing address. | [optional] **mailing_zip** | **str** | The ZIP code of the mailing address. | [optional] **mailing_country** | **str** | The country of the mailing address. | [optional] +**tin_type** | **str** | The type of TIN provided. | [optional] +**tin** | **str** | The taxpayer identification number (TIN). | [optional] **giin** | **str** | The global intermediary identification number (GIIN). | [optional] **foreign_tin_not_required** | **bool** | Indicates whether a foreign TIN is not required. | [optional] **foreign_tin** | **str** | The foreign taxpayer identification number (TIN). | [optional] @@ -132,6 +101,20 @@ Name | Type | Description | Notes **substantial_us_owners** | [**List[SubstantialUsOwnerResponse]**](SubstantialUsOwnerResponse.md) | The list of substantial U.S. owners of passive NFFE. | [optional] **signer_name** | **str** | The name of the signer. | [optional] **capacity_to_sign_certification** | **bool** | Certifies signer has the capacity to sign for the beneficial owner. | [optional] +**id** | **str** | The unique identifier for the form. | [optional] +**entry_status** | **str** | The form status. | [optional] +**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] +**reference_id** | **str** | A reference identifier for the form. | [optional] +**company_id** | **str** | The ID of the associated company. | [optional] +**display_name** | **str** | The display name associated with the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] +**archived** | **bool** | Indicates whether the form is archived. | [optional] +**signature** | **str** | The signature of the form. | [optional] +**signed_date** | **datetime** | The date the form was signed. | [optional] +**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] +**created_at** | **datetime** | The creation date of the form. | [optional] +**updated_at** | **datetime** | The last updated date of the form. | [optional] +**type** | **str** | The type of the response object. | [optional] **birthday** | **date** | The birthday of the individual associated with the form. | [optional] **signer_capacity** | **str** | The capacity in which the signer is signing the form. | [optional] **qualified_intermediary_certification** | **bool** | Certifies that the entity is a Qualified Intermediary (QI) acting in accordance with its QI Agreement, providing required withholding statements and documentation for relevant tax withholding purposes. | [optional] @@ -180,7 +163,11 @@ Name | Type | Description | Notes **exempt_payee_code** | **str** | The exempt payee code. | [optional] **exempt_fatca_code** | **str** | The exemption from FATCA reporting code. | [optional] **foreign_country_indicator** | **bool** | Indicates whether the individual or entity is in a foreign country. | [optional] +**address** | **str** | The address of the individual or entity. | [optional] **foreign_address** | **str** | The foreign address of the individual or entity. | [optional] +**city** | **str** | The city of the address. | [optional] +**state** | **str** | The state of the address. | [optional] +**zip** | **str** | The ZIP code of the address. | [optional] **account_number** | **str** | The account number associated with the form. | [optional] **backup_withholding** | **bool** | Indicates whether backup withholding applies. | [optional] **is1099able** | **bool** | Indicates whether the individual or entity should be issued a 1099 form. | [optional] diff --git a/docs/A1099/V2/ErrorResponse.md b/docs/A1099/V2/ErrorResponse.md index ac71013..9b35fc3 100644 --- a/docs/A1099/V2/ErrorResponse.md +++ b/docs/A1099/V2/ErrorResponse.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **title** | **str** | | [optional] -**errors** | [**List[ErrorResponseErrorsInner]**](ErrorResponseErrorsInner.md) | | [optional] +**errors** | [**List[ErrorResponseItem]**](ErrorResponseItem.md) | | [optional] ## Example diff --git a/docs/A1099/V2/ErrorResponseItem.md b/docs/A1099/V2/ErrorResponseItem.md new file mode 100644 index 0000000..e67796b --- /dev/null +++ b/docs/A1099/V2/ErrorResponseItem.md @@ -0,0 +1,30 @@ +# ErrorResponseItem + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | | [optional] +**detail** | **str** | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.error_response_item import ErrorResponseItem + +# TODO update the JSON string below +json = "{}" +# create an instance of ErrorResponseItem from a JSON string +error_response_item_instance = ErrorResponseItem.from_json(json) +# print the JSON string representation of the object +print(ErrorResponseItem.to_json()) + +# convert the object into a dict +error_response_item_dict = error_response_item_instance.to_dict() +# create an instance of ErrorResponseItem from a dict +error_response_item_from_dict = ErrorResponseItem.from_dict(error_response_item_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1042S.md b/docs/A1099/V2/Form1042S.md new file mode 100644 index 0000000..96356b8 --- /dev/null +++ b/docs/A1099/V2/Form1042S.md @@ -0,0 +1,90 @@ +# Form1042S + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**unique_form_id** | **str** | | [optional] +**recipient_date_of_birth** | **datetime** | | [optional] +**recipient_giin** | **str** | | [optional] +**recipient_foreign_tin** | **str** | | [optional] +**lob_code** | **str** | | [optional] +**income_code** | **str** | | [optional] +**gross_income** | **float** | | [optional] +**withholding_indicator** | **str** | | [optional] +**tax_country_code** | **str** | | [optional] +**exemption_code_chap3** | **str** | | [optional] +**exemption_code_chap4** | **str** | | [optional] +**tax_rate_chap3** | **str** | | [optional] +**withholding_allowance** | **float** | | [optional] +**federal_tax_withheld** | **float** | | [optional] +**tax_not_deposited_indicator** | **bool** | | [optional] +**academic_indicator** | **bool** | | [optional] +**tax_withheld_other_agents** | **float** | | [optional] +**amount_repaid** | **float** | | [optional] +**tax_paid_agent** | **float** | | [optional] +**chap3_status_code** | **str** | | [optional] +**chap4_status_code** | **str** | | [optional] +**primary_withholding_agent** | [**PrimaryWithholdingAgent**](PrimaryWithholdingAgent.md) | | [optional] +**intermediary_or_flow_through** | [**IntermediaryOrFlowThrough**](IntermediaryOrFlowThrough.md) | | [optional] +**id** | **str** | | [optional] +**type** | **str** | | [optional] +**issuer_id** | **int** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**federal_efile** | **bool** | | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**state_efile** | **bool** | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | | [optional] +**postal_mail** | **bool** | | [optional] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**tin_match** | **bool** | | [optional] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**address_verification** | **bool** | | [optional] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**reference_id** | **str** | | [optional] +**email** | **str** | | [optional] +**tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] +**tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1042_s import Form1042S + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1042S from a JSON string +form1042_s_instance = Form1042S.from_json(json) +# print the JSON string representation of the object +print(Form1042S.to_json()) + +# convert the object into a dict +form1042_s_dict = form1042_s_instance.to_dict() +# create an instance of Form1042S from a dict +form1042_s_from_dict = Form1042S.from_dict(form1042_s_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1042SListItem.md b/docs/A1099/V2/Form1042SListItem.md index 9e05e69..b4a3fa5 100644 --- a/docs/A1099/V2/Form1042SListItem.md +++ b/docs/A1099/V2/Form1042SListItem.md @@ -35,21 +35,22 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1042SRequest.md b/docs/A1099/V2/Form1042SRequest.md index 9ea49a2..9e4b9fe 100644 --- a/docs/A1099/V2/Form1042SRequest.md +++ b/docs/A1099/V2/Form1042SRequest.md @@ -36,22 +36,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] ## Example diff --git a/docs/A1099/V2/Form1095B.md b/docs/A1099/V2/Form1095B.md index 2f6d32d..3b9da5d 100644 --- a/docs/A1099/V2/Form1095B.md +++ b/docs/A1099/V2/Form1095B.md @@ -23,10 +23,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -34,8 +38,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1095BListItem.md b/docs/A1099/V2/Form1095BListItem.md index 35371fa..8b8d6bf 100644 --- a/docs/A1099/V2/Form1095BListItem.md +++ b/docs/A1099/V2/Form1095BListItem.md @@ -18,22 +18,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1095BRequest.md b/docs/A1099/V2/Form1095BRequest.md index 7d9694e..f6c4717 100644 --- a/docs/A1099/V2/Form1095BRequest.md +++ b/docs/A1099/V2/Form1095BRequest.md @@ -19,22 +19,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1095BResponse.md b/docs/A1099/V2/Form1095BResponse.md new file mode 100644 index 0000000..63151a1 --- /dev/null +++ b/docs/A1099/V2/Form1095BResponse.md @@ -0,0 +1,73 @@ +# Form1095BResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**employee_first_name** | **str** | | [optional] +**employee_middle_name** | **str** | | [optional] +**employee_last_name** | **str** | | [optional] +**employee_name_suffix** | **str** | | [optional] +**employee_date_of_birth** | **datetime** | | [optional] +**origin_of_health_coverage_code** | **str** | | [optional] +**covered_individuals** | [**List[CoveredIndividualRequest]**](CoveredIndividualRequest.md) | | [optional] +**type** | **str** | | [optional] [readonly] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholdingResponse**](StateAndLocalWithholdingResponse.md) | | [optional] +**tin_type** | **str** | | [optional] +**id** | **str** | | [optional] +**issuer_id** | **str** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**reference_id** | **str** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_tin** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**email** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**federal_e_file** | **bool** | | [optional] +**postal_mail** | **bool** | | [optional] +**state_e_file** | **bool** | | [optional] +**tin_match** | **bool** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**address_verification** | **bool** | | [optional] +**federal_efile_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**e_delivery_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetailResponse]**](StateEfileStatusDetailResponse.md) | | [optional] +**postal_mail_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**tin_match_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**address_verification_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**validation_errors** | [**List[ValidationErrorResponse]**](ValidationErrorResponse.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1095_b_response import Form1095BResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1095BResponse from a JSON string +form1095_b_response_instance = Form1095BResponse.from_json(json) +# print the JSON string representation of the object +print(Form1095BResponse.to_json()) + +# convert the object into a dict +form1095_b_response_dict = form1095_b_response_instance.to_dict() +# create an instance of Form1095BResponse from a dict +form1095_b_response_from_dict = Form1095BResponse.from_dict(form1095_b_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1095CListItem.md b/docs/A1099/V2/Form1095CListItem.md index 3a9a8c5..f23b5b5 100644 --- a/docs/A1099/V2/Form1095CListItem.md +++ b/docs/A1099/V2/Form1095CListItem.md @@ -23,22 +23,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1099Base.md b/docs/A1099/V2/Form1099Base.md index fbbb288..63276d2 100644 --- a/docs/A1099/V2/Form1099Base.md +++ b/docs/A1099/V2/Form1099Base.md @@ -21,10 +21,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -32,8 +36,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099Div.md b/docs/A1099/V2/Form1099Div.md new file mode 100644 index 0000000..f4a1137 --- /dev/null +++ b/docs/A1099/V2/Form1099Div.md @@ -0,0 +1,85 @@ +# Form1099Div + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**total_ordinary_dividends** | **float** | | [optional] +**qualified_dividends** | **float** | | [optional] +**total_capital_gain_distributions** | **float** | | [optional] +**unrecaptured_section1250_gain** | **float** | | [optional] +**section1202_gain** | **float** | | [optional] +**collectibles_gain** | **float** | | [optional] +**section897_ordinary_dividends** | **float** | | [optional] +**section897_capital_gain** | **float** | | [optional] +**nondividend_distributions** | **float** | | [optional] +**federal_income_tax_withheld** | **float** | | [optional] +**section199_a_dividends** | **float** | | [optional] +**investment_expenses** | **float** | | [optional] +**foreign_tax_paid** | **float** | | [optional] +**foreign_country_or_us_possession** | **str** | | [optional] +**cash_liquidation_distributions** | **float** | | [optional] +**noncash_liquidation_distributions** | **float** | | [optional] +**exempt_interest_dividends** | **float** | | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] +**id** | **str** | | [optional] +**type** | **str** | | [optional] +**issuer_id** | **int** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**federal_efile** | **bool** | | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**state_efile** | **bool** | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | | [optional] +**postal_mail** | **bool** | | [optional] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**tin_match** | **bool** | | [optional] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**address_verification** | **bool** | | [optional] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**reference_id** | **str** | | [optional] +**email** | **str** | | [optional] +**tin_type** | **str** | | [optional] +**tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_div import Form1099Div + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099Div from a JSON string +form1099_div_instance = Form1099Div.from_json(json) +# print the JSON string representation of the object +print(Form1099Div.to_json()) + +# convert the object into a dict +form1099_div_dict = form1099_div_instance.to_dict() +# create an instance of Form1099Div from a dict +form1099_div_from_dict = Form1099Div.from_dict(form1099_div_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099DivListItem.md b/docs/A1099/V2/Form1099DivListItem.md index 3df9953..e2050de 100644 --- a/docs/A1099/V2/Form1099DivListItem.md +++ b/docs/A1099/V2/Form1099DivListItem.md @@ -5,24 +5,24 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] -**federal_income_tax_withheld** | **str** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] **fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] **issuer_reference_id** | **str** | Issuer Reference ID. One of `issuerReferenceId` or `issuerTin` is required. | [optional] **issuer_tin** | **str** | Issuer TIN. One of `issuerReferenceId` or `issuerTin` is required. | [optional] @@ -33,16 +33,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099DivListItemResponse.md b/docs/A1099/V2/Form1099DivListItemResponse.md index 8db86a0..9d71900 100644 --- a/docs/A1099/V2/Form1099DivListItemResponse.md +++ b/docs/A1099/V2/Form1099DivListItemResponse.md @@ -5,24 +5,24 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] -**federal_income_tax_withheld** | **str** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] **fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] **id** | **str** | ID of the form | [readonly] **type** | **str** | Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC | diff --git a/docs/A1099/V2/Form1099DivRequest.md b/docs/A1099/V2/Form1099DivRequest.md index f5d51ee..31babd4 100644 --- a/docs/A1099/V2/Form1099DivRequest.md +++ b/docs/A1099/V2/Form1099DivRequest.md @@ -5,24 +5,24 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] -**federal_income_tax_withheld** | **str** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] **fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] **type** | **str** | | [optional] **issuer_id** | **str** | Issuer ID | [optional] @@ -31,16 +31,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099DivResponse.md b/docs/A1099/V2/Form1099DivResponse.md index 13a3b6e..6fd81a8 100644 --- a/docs/A1099/V2/Form1099DivResponse.md +++ b/docs/A1099/V2/Form1099DivResponse.md @@ -5,6 +5,25 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**total_ordinary_dividends** | **float** | | [optional] +**qualified_dividends** | **float** | | [optional] +**total_capital_gain_distributions** | **float** | | [optional] +**unrecaptured_section1250_gain** | **float** | | [optional] +**section1202_gain** | **float** | | [optional] +**collectibles_gain** | **float** | | [optional] +**section897_ordinary_dividends** | **float** | | [optional] +**section897_capital_gain** | **float** | | [optional] +**nondividend_distributions** | **float** | | [optional] +**federal_income_tax_withheld** | **float** | | [optional] +**section199_a_dividends** | **float** | | [optional] +**investment_expenses** | **float** | | [optional] +**foreign_tax_paid** | **float** | | [optional] +**foreign_country_or_us_possession** | **str** | | [optional] +**cash_liquidation_distributions** | **float** | | [optional] +**noncash_liquidation_distributions** | **float** | | [optional] +**exempt_interest_dividends** | **float** | | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **type** | **str** | | [optional] [readonly] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099Int.md b/docs/A1099/V2/Form1099Int.md new file mode 100644 index 0000000..2227c84 --- /dev/null +++ b/docs/A1099/V2/Form1099Int.md @@ -0,0 +1,81 @@ +# Form1099Int + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**interest_income** | **float** | | [optional] +**early_withdrawal_penalty** | **float** | | [optional] +**us_savings_bonds_interest** | **float** | | [optional] +**federal_income_tax_withheld** | **float** | | [optional] +**investment_expenses** | **float** | | [optional] +**foreign_tax_paid** | **float** | | [optional] +**foreign_country** | **str** | | [optional] +**tax_exempt_interest** | **float** | | [optional] +**specified_private_activity_bond_interest** | **float** | | [optional] +**market_discount** | **float** | | [optional] +**bond_premium** | **float** | | [optional] +**bond_premium_on_treasury_obligations** | **float** | | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | | [optional] +**tax_exempt_bond_cusip_number** | **str** | | [optional] +**id** | **str** | | [optional] +**type** | **str** | | [optional] +**issuer_id** | **int** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**federal_efile** | **bool** | | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**state_efile** | **bool** | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | | [optional] +**postal_mail** | **bool** | | [optional] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**tin_match** | **bool** | | [optional] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**address_verification** | **bool** | | [optional] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**reference_id** | **str** | | [optional] +**email** | **str** | | [optional] +**tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] +**tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int import Form1099Int + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099Int from a JSON string +form1099_int_instance = Form1099Int.from_json(json) +# print the JSON string representation of the object +print(Form1099Int.to_json()) + +# convert the object into a dict +form1099_int_dict = form1099_int_instance.to_dict() +# create an instance of Form1099Int from a dict +form1099_int_from_dict = Form1099Int.from_dict(form1099_int_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099IntList.md b/docs/A1099/V2/Form1099IntList.md new file mode 100644 index 0000000..bd2de09 --- /dev/null +++ b/docs/A1099/V2/Form1099IntList.md @@ -0,0 +1,30 @@ +# Form1099IntList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**forms** | [**List[Form1099IntListItem]**](Form1099IntListItem.md) | | [optional] +**form_type** | **str** | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int_list import Form1099IntList + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099IntList from a JSON string +form1099_int_list_instance = Form1099IntList.from_json(json) +# print the JSON string representation of the object +print(Form1099IntList.to_json()) + +# convert the object into a dict +form1099_int_list_dict = form1099_int_list_instance.to_dict() +# create an instance of Form1099IntList from a dict +form1099_int_list_from_dict = Form1099IntList.from_dict(form1099_int_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099IntListItem.md b/docs/A1099/V2/Form1099IntListItem.md new file mode 100644 index 0000000..0e9c0a7 --- /dev/null +++ b/docs/A1099/V2/Form1099IntListItem.md @@ -0,0 +1,70 @@ +# Form1099IntListItem + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early Withdrawal Penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**investment_expenses** | **float** | Investment Expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-Exempt Interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified Private activity | [optional] +**market_discount** | **float** | Market Discount | [optional] +**bond_premium** | **float** | Bond Premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond Premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond Premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP no. | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID. One of `issuerReferenceId` or `issuerTin` is required. | [optional] +**issuer_tin** | **str** | Issuer TIN. One of `issuerReferenceId` or `issuerTin` is required. | [optional] +**tax_year** | **int** | Tax year | +**issuer_id** | **str** | Issuer ID | [optional] +**reference_id** | **str** | Reference ID | [optional] +**recipient_tin** | **str** | Recipient Tax ID Number | [optional] +**recipient_name** | **str** | Recipient name | [optional] +**tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address | [optional] +**address2** | **str** | Address line 2 | [optional] +**city** | **str** | City | [optional] +**state** | **str** | US state. Required if CountryCode is \"US\". | [optional] +**zip** | **str** | Zip/postal code | [optional] +**email** | **str** | Recipient email address | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Foreign province | [optional] +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] +**federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] +**postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] +**state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] +**tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] +**no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] +**second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int_list_item import Form1099IntListItem + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099IntListItem from a JSON string +form1099_int_list_item_instance = Form1099IntListItem.from_json(json) +# print the JSON string representation of the object +print(Form1099IntListItem.to_json()) + +# convert the object into a dict +form1099_int_list_item_dict = form1099_int_list_item_instance.to_dict() +# create an instance of Form1099IntListItem from a dict +form1099_int_list_item_from_dict = Form1099IntListItem.from_dict(form1099_int_list_item_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099IntListItemResponse.md b/docs/A1099/V2/Form1099IntListItemResponse.md new file mode 100644 index 0000000..c1367e3 --- /dev/null +++ b/docs/A1099/V2/Form1099IntListItemResponse.md @@ -0,0 +1,81 @@ +# Form1099IntListItemResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early withdrawal penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-exempt interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified private activity bond interest | [optional] +**market_discount** | **float** | Market discount | [optional] +**bond_premium** | **float** | Bond premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP number | [optional] +**id** | **str** | ID of the form | [readonly] +**type** | **str** | Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC | +**issuer_id** | **int** | Issuer ID | +**issuer_reference_id** | **str** | Issuer Reference ID | [optional] +**issuer_tin** | **str** | Issuer TIN | [optional] +**tax_year** | **int** | Tax year | [optional] +**federal_efile** | **bool** | Boolean indicating that federal e-filing has been scheduled for this form | +**federal_efile_status** | [**StatusDetail**](StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile** | **bool** | Boolean indicating that state e-filing has been scheduled for this form | +**state_efile_status** | [**List[StateEfileStatusDetailResponse]**](StateEfileStatusDetailResponse.md) | State e-file status | [optional] [readonly] +**postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient has been scheduled for this form | +**postal_mail_status** | [**StatusDetail**](StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match** | **bool** | Boolean indicating that TIN Matching has been scheduled for this form | +**tin_match_status** | [**StatusDetail**](StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification** | **bool** | Boolean indicating that address verification has been scheduled for this form | +**address_verification_status** | [**StatusDetail**](StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**StatusDetail**](StatusDetail.md) | EDelivery status | [optional] [readonly] +**reference_id** | **str** | Reference ID | [optional] +**email** | **str** | Recipient email address | [optional] +**tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] +**tin** | **str** | Recipient Tax ID Number | [optional] +**no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] +**second_tin_notice** | **bool** | Second Tin Notice | [optional] +**recipient_name** | **str** | Recipient name | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address | [optional] +**address2** | **str** | Address line 2 | [optional] +**city** | **str** | City | [optional] +**state** | **str** | US state | [optional] +**zip** | **str** | Zip/postal code | [optional] +**non_us_province** | **str** | Foreign province | [optional] +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] +**account_number** | **str** | Account Number | [optional] +**office_code** | **str** | Office Code | [optional] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**validation_errors** | [**List[ValidationErrorResponse]**](ValidationErrorResponse.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Creation time | [optional] [readonly] +**updated_at** | **datetime** | Update time | [optional] [readonly] +**state_and_local_withholding** | [**StateAndLocalWithholdingResponse**](StateAndLocalWithholdingResponse.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099IntListItemResponse from a JSON string +form1099_int_list_item_response_instance = Form1099IntListItemResponse.from_json(json) +# print the JSON string representation of the object +print(Form1099IntListItemResponse.to_json()) + +# convert the object into a dict +form1099_int_list_item_response_dict = form1099_int_list_item_response_instance.to_dict() +# create an instance of Form1099IntListItemResponse from a dict +form1099_int_list_item_response_from_dict = Form1099IntListItemResponse.from_dict(form1099_int_list_item_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099IntRequest.md b/docs/A1099/V2/Form1099IntRequest.md new file mode 100644 index 0000000..5e51133 --- /dev/null +++ b/docs/A1099/V2/Form1099IntRequest.md @@ -0,0 +1,68 @@ +# Form1099IntRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early Withdrawl Penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**investment_expenses** | **float** | Investment Expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-Exempt Interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified Private activity | [optional] +**market_discount** | **float** | Market Discount | [optional] +**bond_premium** | **float** | Bond Premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond Premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond Premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP no. | [optional] +**type** | **str** | | [optional] +**issuer_id** | **str** | Issuer ID | [optional] +**reference_id** | **str** | Reference ID | [optional] +**recipient_tin** | **str** | Recipient Tax ID Number | [optional] +**recipient_name** | **str** | Recipient name | [optional] +**tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address | [optional] +**address2** | **str** | Address line 2 | [optional] +**city** | **str** | City | [optional] +**state** | **str** | US state. Required if CountryCode is \"US\". | [optional] +**zip** | **str** | Zip/postal code | [optional] +**email** | **str** | Recipient email address | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Foreign province | [optional] +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] +**federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] +**postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] +**state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] +**tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] +**no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] +**second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int_request import Form1099IntRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099IntRequest from a JSON string +form1099_int_request_instance = Form1099IntRequest.from_json(json) +# print the JSON string representation of the object +print(Form1099IntRequest.to_json()) + +# convert the object into a dict +form1099_int_request_dict = form1099_int_request_instance.to_dict() +# create an instance of Form1099IntRequest from a dict +form1099_int_request_from_dict = Form1099IntRequest.from_dict(form1099_int_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099IntResponse.md b/docs/A1099/V2/Form1099IntResponse.md new file mode 100644 index 0000000..c7253e4 --- /dev/null +++ b/docs/A1099/V2/Form1099IntResponse.md @@ -0,0 +1,80 @@ +# Form1099IntResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early Withdrawal Penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**investment_expenses** | **float** | Investment Expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-Exempt Interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified Private activity | [optional] +**market_discount** | **float** | Market Discount | [optional] +**bond_premium** | **float** | Bond Premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond Premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond Premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP no. | [optional] +**type** | **str** | | [optional] [readonly] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholdingResponse**](StateAndLocalWithholdingResponse.md) | | [optional] +**tin_type** | **str** | | [optional] +**id** | **str** | | [optional] +**issuer_id** | **str** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**reference_id** | **str** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_tin** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**email** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**federal_e_file** | **bool** | | [optional] +**postal_mail** | **bool** | | [optional] +**state_e_file** | **bool** | | [optional] +**tin_match** | **bool** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**address_verification** | **bool** | | [optional] +**federal_efile_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**e_delivery_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetailResponse]**](StateEfileStatusDetailResponse.md) | | [optional] +**postal_mail_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**tin_match_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**address_verification_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**validation_errors** | [**List[ValidationErrorResponse]**](ValidationErrorResponse.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_int_response import Form1099IntResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099IntResponse from a JSON string +form1099_int_response_instance = Form1099IntResponse.from_json(json) +# print the JSON string representation of the object +print(Form1099IntResponse.to_json()) + +# convert the object into a dict +form1099_int_response_dict = form1099_int_response_instance.to_dict() +# create an instance of Form1099IntResponse from a dict +form1099_int_response_from_dict = Form1099IntResponse.from_dict(form1099_int_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099K.md b/docs/A1099/V2/Form1099K.md index f3b03c2..743a691 100644 --- a/docs/A1099/V2/Form1099K.md +++ b/docs/A1099/V2/Form1099K.md @@ -41,10 +41,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -52,8 +56,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099KListItem.md b/docs/A1099/V2/Form1099KListItem.md index 50a1246..a206e9d 100644 --- a/docs/A1099/V2/Form1099KListItem.md +++ b/docs/A1099/V2/Form1099KListItem.md @@ -34,22 +34,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1099KRequest.md b/docs/A1099/V2/Form1099KRequest.md index 03a93c2..d0f631d 100644 --- a/docs/A1099/V2/Form1099KRequest.md +++ b/docs/A1099/V2/Form1099KRequest.md @@ -32,22 +32,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1099ListResponseValueInner.md b/docs/A1099/V2/Form1099ListResponseValueInner.md index 2c11830..4545e5e 100644 --- a/docs/A1099/V2/Form1099ListResponseValueInner.md +++ b/docs/A1099/V2/Form1099ListResponseValueInner.md @@ -69,24 +69,35 @@ Name | Type | Description | Notes **intermediary_or_flow_through** | [**IntermediaryOrFlowThroughResponse**](IntermediaryOrFlowThroughResponse.md) | Intermediary or flow-through entity information | [optional] **origin_of_health_coverage_code** | **str** | Origin of health coverage code | [optional] **covered_individuals** | [**List[CoveredIndividualReferenceResponse]**](CoveredIndividualReferenceResponse.md) | Covered individuals information | [optional] -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] **federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early withdrawal penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-exempt interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified private activity bond interest | [optional] +**market_discount** | **float** | Market discount | [optional] +**bond_premium** | **float** | Bond premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP number | [optional] **filer_type** | **str** | Filer type (PSE or EPF) | [optional] **payment_type** | **str** | Payment type (payment card or third party network) | [optional] **payment_settlement_entity_name_phone_number** | **str** | Payment settlement entity name and phone number | [optional] @@ -138,7 +149,6 @@ Name | Type | Description | Notes **total_employee_contributions** | **float** | Total employee contributions | [optional] **amount_allocable_to_irr** | **float** | Amount allocable to IRR within 5 years | [optional] **first_year_designated_roth_contrib** | **str** | First year of designated Roth contribution | [optional] -**fatca_requirement_indicator** | **bool** | FATCA filing requirement | [optional] **date_of_payment** | **str** | Date of payment | [optional] ## Example diff --git a/docs/A1099/V2/Form1099Misc.md b/docs/A1099/V2/Form1099Misc.md index bf8c76b..6094b58 100644 --- a/docs/A1099/V2/Form1099Misc.md +++ b/docs/A1099/V2/Form1099Misc.md @@ -10,15 +10,15 @@ Name | Type | Description | Notes **other_income** | **float** | | [optional] **fed_income_tax_withheld** | **float** | | [optional] **fishing_boat_proceeds** | **float** | | [optional] -**medical_and_health_care** | **float** | | [optional] -**nonemployee_compensation** | **float** | | [optional] +**medical_and_health_care_payments** | **float** | | [optional] **substitute_payments** | **float** | | [optional] **direct_sales_indicator** | **bool** | | [optional] **crop_insurance_proceeds** | **float** | | [optional] -**excess_golden_parachute** | **float** | | [optional] -**gross_amount_paid_attorney** | **float** | | [optional] +**excess_golden_parachute_payments** | **float** | | [optional] +**gross_proceeds_paid_to_attorney** | **float** | | [optional] +**fish_purchased_for_resale** | **float** | | [optional] **section409_a_deferrals** | **float** | | [optional] -**section409_a_income** | **float** | | [optional] +**nonqualified_deferred_compensation** | **float** | | [optional] **id** | **str** | | [optional] **type** | **str** | | [optional] **issuer_id** | **int** | | [optional] @@ -35,10 +35,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -46,8 +50,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099MiscListItem.md b/docs/A1099/V2/Form1099MiscListItem.md index 8fd1894..bc76a11 100644 --- a/docs/A1099/V2/Form1099MiscListItem.md +++ b/docs/A1099/V2/Form1099MiscListItem.md @@ -29,16 +29,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099MiscRequest.md b/docs/A1099/V2/Form1099MiscRequest.md index ef06880..2260fbe 100644 --- a/docs/A1099/V2/Form1099MiscRequest.md +++ b/docs/A1099/V2/Form1099MiscRequest.md @@ -27,16 +27,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099Nec.md b/docs/A1099/V2/Form1099Nec.md index c427321..80d5893 100644 --- a/docs/A1099/V2/Form1099Nec.md +++ b/docs/A1099/V2/Form1099Nec.md @@ -24,10 +24,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -35,8 +39,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099NecListItem.md b/docs/A1099/V2/Form1099NecListItem.md index f7c3eb9..b6d42dd 100644 --- a/docs/A1099/V2/Form1099NecListItem.md +++ b/docs/A1099/V2/Form1099NecListItem.md @@ -18,22 +18,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1099NecRequest.md b/docs/A1099/V2/Form1099NecRequest.md index 05552bb..f099370 100644 --- a/docs/A1099/V2/Form1099NecRequest.md +++ b/docs/A1099/V2/Form1099NecRequest.md @@ -15,22 +15,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Form1099ProccessResult.md b/docs/A1099/V2/Form1099ProccessResult.md index d969a22..3e2840a 100644 --- a/docs/A1099/V2/Form1099ProccessResult.md +++ b/docs/A1099/V2/Form1099ProccessResult.md @@ -6,6 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **job_data** | [**Data**](Data.md) | | [optional] +**processed_forms** | [**List[Form1099ProccessResultProcessedFormsInner]**](Form1099ProccessResultProcessedFormsInner.md) | | [optional] ## Example diff --git a/docs/A1099/V2/Form1099ProccessResultProcessedFormsInner.md b/docs/A1099/V2/Form1099ProccessResultProcessedFormsInner.md new file mode 100644 index 0000000..2e98f56 --- /dev/null +++ b/docs/A1099/V2/Form1099ProccessResultProcessedFormsInner.md @@ -0,0 +1,173 @@ +# Form1099ProccessResultProcessedFormsInner + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**unique_form_id** | **str** | | [optional] +**recipient_date_of_birth** | **datetime** | | [optional] +**recipient_giin** | **str** | | [optional] +**recipient_foreign_tin** | **str** | | [optional] +**lob_code** | **str** | | [optional] +**income_code** | **str** | | [optional] +**gross_income** | **float** | | [optional] +**withholding_indicator** | **str** | | [optional] +**tax_country_code** | **str** | | [optional] +**exemption_code_chap3** | **str** | | [optional] +**exemption_code_chap4** | **str** | | [optional] +**tax_rate_chap3** | **str** | | [optional] +**withholding_allowance** | **float** | | [optional] +**federal_tax_withheld** | **float** | | [optional] +**tax_not_deposited_indicator** | **bool** | | [optional] +**academic_indicator** | **bool** | | [optional] +**tax_withheld_other_agents** | **float** | | [optional] +**amount_repaid** | **float** | | [optional] +**tax_paid_agent** | **float** | | [optional] +**chap3_status_code** | **str** | | [optional] +**chap4_status_code** | **str** | | [optional] +**primary_withholding_agent** | [**PrimaryWithholdingAgent**](PrimaryWithholdingAgent.md) | | [optional] +**intermediary_or_flow_through** | [**IntermediaryOrFlowThrough**](IntermediaryOrFlowThrough.md) | | [optional] +**id** | **str** | | [optional] +**type** | **str** | | [optional] +**issuer_id** | **int** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**federal_efile** | **bool** | | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**state_efile** | **bool** | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | | [optional] +**postal_mail** | **bool** | | [optional] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**tin_match** | **bool** | | [optional] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**address_verification** | **bool** | | [optional] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**reference_id** | **str** | | [optional] +**email** | **str** | | [optional] +**tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] +**tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | | [optional] +**origin_of_health_coverage_code** | **str** | | [optional] +**covered_individuals** | [**List[CoveredIndividualReference]**](CoveredIndividualReference.md) | | [optional] +**total_ordinary_dividends** | **float** | | [optional] +**qualified_dividends** | **float** | | [optional] +**total_capital_gain_distributions** | **float** | | [optional] +**unrecaptured_section1250_gain** | **float** | | [optional] +**section1202_gain** | **float** | | [optional] +**collectibles_gain** | **float** | | [optional] +**section897_ordinary_dividends** | **float** | | [optional] +**section897_capital_gain** | **float** | | [optional] +**nondividend_distributions** | **float** | | [optional] +**federal_income_tax_withheld** | **float** | | [optional] +**section199_a_dividends** | **float** | | [optional] +**investment_expenses** | **float** | | [optional] +**foreign_tax_paid** | **float** | | [optional] +**foreign_country_or_us_possession** | **str** | | [optional] +**cash_liquidation_distributions** | **float** | | [optional] +**noncash_liquidation_distributions** | **float** | | [optional] +**exempt_interest_dividends** | **float** | | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | | [optional] +**interest_income** | **float** | | [optional] +**early_withdrawal_penalty** | **float** | | [optional] +**us_savings_bonds_interest** | **float** | | [optional] +**foreign_country** | **str** | | [optional] +**tax_exempt_interest** | **float** | | [optional] +**specified_private_activity_bond_interest** | **float** | | [optional] +**market_discount** | **float** | | [optional] +**bond_premium** | **float** | | [optional] +**bond_premium_on_treasury_obligations** | **float** | | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | | [optional] +**tax_exempt_bond_cusip_number** | **str** | | [optional] +**filer_type** | **str** | | [optional] +**payment_type** | **str** | | [optional] +**payment_settlement_entity_name_phone_number** | **str** | | [optional] +**gross_amount_payment_card** | **float** | | [optional] +**card_not_present_transactions** | **float** | | [optional] +**merchant_category_code** | **str** | | [optional] +**payment_transaction_number** | **float** | | [optional] +**january** | **float** | | [optional] +**february** | **float** | | [optional] +**march** | **float** | | [optional] +**april** | **float** | | [optional] +**may** | **float** | | [optional] +**june** | **float** | | [optional] +**july** | **float** | | [optional] +**august** | **float** | | [optional] +**sept** | **float** | | [optional] +**october** | **float** | | [optional] +**november** | **float** | | [optional] +**december** | **float** | | [optional] +**rents** | **float** | | [optional] +**royalties** | **float** | | [optional] +**other_income** | **float** | | [optional] +**fed_income_tax_withheld** | **float** | | [optional] +**fishing_boat_proceeds** | **float** | | [optional] +**medical_and_health_care_payments** | **float** | | [optional] +**substitute_payments** | **float** | | [optional] +**direct_sales_indicator** | **bool** | | [optional] +**crop_insurance_proceeds** | **float** | | [optional] +**excess_golden_parachute_payments** | **float** | | [optional] +**gross_proceeds_paid_to_attorney** | **float** | | [optional] +**fish_purchased_for_resale** | **float** | | [optional] +**section409_a_deferrals** | **float** | | [optional] +**nonqualified_deferred_compensation** | **float** | | [optional] +**nonemployee_compensation** | **float** | | [optional] +**gross_distributions** | **float** | | [optional] +**taxable_amount** | **float** | | [optional] +**taxable_amount_not_determined** | **bool** | | [optional] +**total_distribution_indicator** | **bool** | | [optional] +**capital_gain** | **float** | | [optional] +**employee_contributions** | **float** | | [optional] +**net_unrealized_appreciation** | **float** | | [optional] +**distribution_code_required** | **str** | | [optional] +**distribution_code_optional** | **str** | | [optional] +**ira_sep_simple_indicator** | **bool** | | [optional] +**total_ira_sep_simple_distribution** | **float** | | [optional] +**other** | **float** | | [optional] +**other_percent** | **str** | | [optional] +**percentage_total_distribution** | **str** | | [optional] +**total_employee_contributions** | **float** | | [optional] +**amount_allocable_to_irr** | **float** | | [optional] +**first_year_designated_roth_contrib** | **str** | | [optional] +**date_of_payment** | **str** | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_proccess_result_processed_forms_inner import Form1099ProccessResultProcessedFormsInner + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099ProccessResultProcessedFormsInner from a JSON string +form1099_proccess_result_processed_forms_inner_instance = Form1099ProccessResultProcessedFormsInner.from_json(json) +# print the JSON string representation of the object +print(Form1099ProccessResultProcessedFormsInner.to_json()) + +# convert the object into a dict +form1099_proccess_result_processed_forms_inner_dict = form1099_proccess_result_processed_forms_inner_instance.to_dict() +# create an instance of Form1099ProccessResultProcessedFormsInner from a dict +form1099_proccess_result_processed_forms_inner_from_dict = Form1099ProccessResultProcessedFormsInner.from_dict(form1099_proccess_result_processed_forms_inner_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Form1099R.md b/docs/A1099/V2/Form1099R.md index 8273226..33cd9f8 100644 --- a/docs/A1099/V2/Form1099R.md +++ b/docs/A1099/V2/Form1099R.md @@ -23,7 +23,6 @@ Name | Type | Description | Notes **total_employee_contributions** | **float** | | [optional] **amount_allocable_to_irr** | **float** | | [optional] **first_year_designated_roth_contrib** | **str** | | [optional] -**fatca_requirement_indicator** | **bool** | | [optional] **date_of_payment** | **str** | | [optional] **id** | **str** | | [optional] **type** | **str** | | [optional] @@ -41,10 +40,14 @@ Name | Type | Description | Notes **tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **address_verification** | **bool** | | [optional] **address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | | [optional] **reference_id** | **str** | | [optional] **email** | **str** | | [optional] **tin_type** | **str** | | [optional] +**fatca_filing_requirement** | **bool** | | [optional] **tin** | **str** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] **recipient_name** | **str** | | [optional] **recipient_second_name** | **str** | | [optional] **address** | **str** | | [optional] @@ -52,8 +55,10 @@ Name | Type | Description | Notes **city** | **str** | | [optional] **state** | **str** | | [optional] **zip** | **str** | | [optional] -**foreign_province** | **str** | | [optional] +**non_us_province** | **str** | | [optional] **country_code** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] **validation_errors** | [**List[ValidationError]**](ValidationError.md) | | [optional] **created_at** | **datetime** | | [optional] **updated_at** | **datetime** | | [optional] diff --git a/docs/A1099/V2/Form1099RListItem.md b/docs/A1099/V2/Form1099RListItem.md index fbba1e5..4f5f194 100644 --- a/docs/A1099/V2/Form1099RListItem.md +++ b/docs/A1099/V2/Form1099RListItem.md @@ -34,16 +34,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099RListItemResponse.md b/docs/A1099/V2/Form1099RListItemResponse.md index e99d722..e647aea 100644 --- a/docs/A1099/V2/Form1099RListItemResponse.md +++ b/docs/A1099/V2/Form1099RListItemResponse.md @@ -23,7 +23,6 @@ Name | Type | Description | Notes **total_employee_contributions** | **float** | Total employee contributions | [optional] **amount_allocable_to_irr** | **float** | Amount allocable to IRR within 5 years | [optional] **first_year_designated_roth_contrib** | **str** | First year of designated Roth contribution | [optional] -**fatca_requirement_indicator** | **bool** | FATCA filing requirement | [optional] **date_of_payment** | **str** | Date of payment | [optional] **id** | **str** | ID of the form | [readonly] **type** | **str** | Type of the form. Will be one of: * 940 * 941 * 943 * 944 * 945 * 1042 * 1042-S * 1095-B * 1095-C * 1097-BTC * 1098 * 1098-C * 1098-E * 1098-Q * 1098-T * 3921 * 3922 * 5498 * 5498-ESA * 5498-SA * 1099-MISC * 1099-A * 1099-B * 1099-C * 1099-CAP * 1099-DIV * 1099-G * 1099-INT * 1099-K * 1099-LS * 1099-LTC * 1099-NEC * 1099-OID * 1099-PATR * 1099-Q * 1099-R * 1099-S * 1099-SA * T4A * W-2 * W-2G * 1099-HC | diff --git a/docs/A1099/V2/Form1099RRequest.md b/docs/A1099/V2/Form1099RRequest.md index de2cb90..7d9b9e5 100644 --- a/docs/A1099/V2/Form1099RRequest.md +++ b/docs/A1099/V2/Form1099RRequest.md @@ -32,16 +32,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Form1099RResponse.md b/docs/A1099/V2/Form1099RResponse.md new file mode 100644 index 0000000..ddceb5a --- /dev/null +++ b/docs/A1099/V2/Form1099RResponse.md @@ -0,0 +1,86 @@ +# Form1099RResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**gross_distribution** | **float** | Gross distribution | [optional] +**taxable_amount** | **float** | Taxable amount | [optional] +**taxable_amount_not_determined** | **bool** | Taxable amount not determined | [optional] +**total_distribution_determined** | **bool** | Total distribution | [optional] +**capital_gain** | **float** | Capital gain (included in Box 2a) | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**employee_contributions_or_designated_roth_or_insurance_premiums** | **float** | Employee contributions/Designated Roth contributions or insurance premiums | [optional] +**net_unrealized_appreciation_in_employer_securities** | **float** | Net unrealized appreciation in employer's securities | [optional] +**distribution_code** | **str** | Distribution code | [optional] +**second_distribution_code** | **str** | Second distribution code | [optional] +**ira_sep_simple** | **bool** | IRA/SEP/SIMPLE | [optional] +**traditional_ira_sep_simple_or_roth_conversion_amount** | **float** | Traditional IRA/SEP/SIMPLE or Roth conversion amount | [optional] +**other_amount** | **float** | Other amount | [optional] +**other_percentage** | **str** | Other percentage | [optional] +**total_distribution_percentage** | **str** | Total distribution percentage | [optional] +**total_employee_contributions** | **float** | Total employee contributions | [optional] +**amount_allocable_to_irr_within5_years** | **float** | Amount allocable to IRR within 5 years | [optional] +**first_year_of_designated_roth_contribution** | **str** | First year of designated Roth contribution | [optional] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**date_of_payment** | **datetime** | Date of payment | [optional] +**type** | **str** | | [optional] [readonly] +**created_at** | **datetime** | | [optional] +**updated_at** | **datetime** | | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholdingResponse**](StateAndLocalWithholdingResponse.md) | | [optional] +**tin_type** | **str** | | [optional] +**id** | **str** | | [optional] +**issuer_id** | **str** | | [optional] +**issuer_reference_id** | **str** | | [optional] +**issuer_tin** | **str** | | [optional] +**tax_year** | **int** | | [optional] +**reference_id** | **str** | | [optional] +**recipient_name** | **str** | | [optional] +**recipient_tin** | **str** | | [optional] +**recipient_second_name** | **str** | | [optional] +**address** | **str** | | [optional] +**address2** | **str** | | [optional] +**city** | **str** | | [optional] +**state** | **str** | | [optional] +**zip** | **str** | | [optional] +**email** | **str** | | [optional] +**account_number** | **str** | | [optional] +**office_code** | **str** | | [optional] +**non_us_province** | **str** | | [optional] +**country_code** | **str** | | [optional] +**federal_e_file** | **bool** | | [optional] +**postal_mail** | **bool** | | [optional] +**state_e_file** | **bool** | | [optional] +**tin_match** | **bool** | | [optional] +**no_tin** | **bool** | | [optional] +**second_tin_notice** | **bool** | | [optional] +**address_verification** | **bool** | | [optional] +**federal_efile_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**e_delivery_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**state_efile_status** | [**List[StateEfileStatusDetailResponse]**](StateEfileStatusDetailResponse.md) | | [optional] +**postal_mail_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**tin_match_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**address_verification_status** | [**StatusDetail**](StatusDetail.md) | | [optional] +**validation_errors** | [**List[ValidationErrorResponse]**](ValidationErrorResponse.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_r_response import Form1099RResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099RResponse from a JSON string +form1099_r_response_instance = Form1099RResponse.from_json(json) +# print the JSON string representation of the object +print(Form1099RResponse.to_json()) + +# convert the object into a dict +form1099_r_response_dict = form1099_r_response_instance.to_dict() +# create an instance of Form1099RResponse from a dict +form1099_r_response_from_dict = Form1099RResponse.from_dict(form1099_r_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/FormRequestBase.md b/docs/A1099/V2/FormRequestBase.md index fec7c09..65cf5aa 100644 --- a/docs/A1099/V2/FormRequestBase.md +++ b/docs/A1099/V2/FormRequestBase.md @@ -11,22 +11,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/FormRequestListItemBase.md b/docs/A1099/V2/FormRequestListItemBase.md index c3054ba..3fdbebd 100644 --- a/docs/A1099/V2/FormRequestListItemBase.md +++ b/docs/A1099/V2/FormRequestListItemBase.md @@ -14,22 +14,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/FormSingleRequestBase.md b/docs/A1099/V2/FormSingleRequestBase.md index fc9762d..f6fbafc 100644 --- a/docs/A1099/V2/FormSingleRequestBase.md +++ b/docs/A1099/V2/FormSingleRequestBase.md @@ -12,22 +12,23 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] **tin_match** | **bool** | Boolean indicating that TIN Matching should be scheduled for this form | [optional] **no_tin** | **bool** | Indicates whether the recipient has no TIN | [optional] **second_tin_notice** | **bool** | Second TIN notice in three years | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] **state_and_local_withholding** | [**StateAndLocalWithholdingRequest**](StateAndLocalWithholdingRequest.md) | State and local withholding information | [optional] diff --git a/docs/A1099/V2/Forms1099Api.md b/docs/A1099/V2/Forms1099Api.md index a5f6dc2..1c9fdce 100644 --- a/docs/A1099/V2/Forms1099Api.md +++ b/docs/A1099/V2/Forms1099Api.md @@ -48,7 +48,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms1099_api.Forms1099Api(api_client) avalara_version = '2.0.0' # str | API version dry_run = False # bool | (optional) if omitted the server will use the default value of False - x_correlation_id = '85d89e46-adbc-4a36-a615-347bd0ad3549' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'fc005c04-52f7-44d6-bf16-6551603a8324' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) bulk_upsert1099_forms_request = Avalara.SDK.BulkUpsert1099FormsRequest() # BulkUpsert1099FormsRequest | (optional) # example passing only required values which don't have defaults set @@ -139,7 +139,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = forms1099_api.Forms1099Api(api_client) avalara_version = '2.0.0' # str | API version - x_correlation_id = 'ac2b2725-9848-49c3-9255-1d638490cc87' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '13eb4eb0-0e7d-41e3-adf3-61b131c1a92c' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) i_create_form1099_request = Avalara.SDK.ICreateForm1099Request() # ICreateForm1099Request | (optional) # example passing only required values which don't have defaults set @@ -227,7 +227,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms1099_api.Forms1099Api(api_client) id = 'id_example' # str | The unique identifier of the desired form to delete. avalara_version = '2.0.0' # str | API version - x_correlation_id = '0839267c-9208-438e-9fcd-3c193fd0216a' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '2bcc9cf0-9638-46d5-a792-be61566e0651' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -315,7 +315,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms1099_api.Forms1099Api(api_client) id = 'id_example' # str | avalara_version = '2.0.0' # str | API version - x_correlation_id = '4c3931c8-2cd4-42f3-9042-7c23336b9f32' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '6e842a03-8b64-4b02-8c5e-7073bf4e8a8c' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -404,7 +404,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: id = 'id_example' # str | The ID of the form avalara_version = '2.0.0' # str | API version mark_edelivered = True # bool | Optional boolean that if set indicates that the form should be marked as having been successfully edelivered (optional) - x_correlation_id = '9133bfa6-8661-46dc-bbf2-4d45d0439e76' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '7b4aa70b-3a10-4fa0-bf19-7592170409b7' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -497,7 +497,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: top = 10 # 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. (optional) if omitted the server will use the default value of 10 skip = 0 # int | If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets. (optional) if omitted the server will use the default value of 0 order_by = 'order_by_example' # str | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example issuerReferenceId ASC. Supported sorting fields are: issuerReferenceId taxYear createdAt recipientName updatedAt (optional) - x_correlation_id = '1d1f9e87-4684-46a4-9439-85058f82f858' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '7766bce5-4834-4907-81e9-dd0fd6c13079' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -590,7 +590,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms1099_api.Forms1099Api(api_client) id = 'id_example' # str | avalara_version = '2.0.0' # str | API version - x_correlation_id = 'e59dff29-007e-4aa7-8b11-5ba83766a56a' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '9f622e4f-7992-4e4f-8e24-e628c5339402' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) i_update_form1099_request = Avalara.SDK.IUpdateForm1099Request() # IUpdateForm1099Request | (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/FormsW9Api.md b/docs/A1099/V2/FormsW9Api.md index e8e81e3..5a31d89 100644 --- a/docs/A1099/V2/FormsW9Api.md +++ b/docs/A1099/V2/FormsW9Api.md @@ -47,7 +47,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = forms_w9_api.FormsW9Api(api_client) avalara_version = '2.0.0' # str | API version - x_correlation_id = '479b3bdd-2b5c-48b3-b24c-b0ecbe0d07c5' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'd8cc3501-afdd-4b9e-af90-85db9793cbbc' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) create_w9_form_request = {"type":"W9","name":"John Doe","businessName":"Acme Inc.","businessClassification":"Individual","businessOther":null,"foreignPartnerOwnerOrBeneficiary":false,"exemptPayeeCode":null,"exemptFatcaCode":null,"foreignCountryIndicator":false,"address":"123 Main St.","foreignAddress":null,"city":"Anytown","state":"CA","zip":"12345","accountNumber":null,"tinType":"SSN","tin":"543456789","backupWithholding":false,"is1099able":true,"companyId":"32553266","referenceId":null,"email":null,"eDeliveryConsentedAt":null,"signature":null} # CreateW9FormRequest | Form to be created (optional) # example passing only required values which don't have defaults set @@ -134,7 +134,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms_w9_api.FormsW9Api(api_client) id = 'id_example' # str | ID of the form to delete avalara_version = '2.0.0' # str | API version - x_correlation_id = '7d79301a-ebfd-40a1-a1af-a9a1e44f8936' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '0013f0dd-e304-45c6-9f17-bd023626ba48' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -219,7 +219,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms_w9_api.FormsW9Api(api_client) id = 'id_example' # str | ID of the form avalara_version = '2.0.0' # str | API version - x_correlation_id = 'b4cc81aa-1d2e-4cef-aa68-705ea2aaf594' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'e76a4eb2-f5f0-4586-888a-c25443f75fc4' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -273,11 +273,11 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../../README.md#documentation-for-models) [[Back to README]](../../../README.md) # **list_w9_forms** -> PaginatedW9FormsModel list_w9_forms(avalara_version) +> PaginatedQueryResultModelW9FormBaseResponse list_w9_forms(avalara_version) List W9/W4/W8 forms -List W9/W4/W8 forms. +List W9/W4/W8 forms. Filterable/Sortable fields are: \"companyId\", \"type\", \"displayName\", \"entryStatus\", \"email\", \"archived\" and \"referenceId\". ### Example @@ -287,8 +287,8 @@ List W9/W4/W8 forms. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms_w9_api +PaginatedQueryResultModelW9FormBaseResponse ErrorModel -PaginatedW9FormsModel from pprint import pprint # Define configuration object with parameters specified to your application. @@ -305,12 +305,13 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = forms_w9_api.FormsW9Api(api_client) avalara_version = '2.0.0' # str | API version - filter = 'filter_example' # str | A filter statement to identify specific records to retrieve. For more information on filtering, see Filtering in REST. (optional) - top = 10 # 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. (optional) if omitted the server will use the default value of 10 - skip = 0 # int | If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets. (optional) if omitted the server will use the default value of 0 + filter = 'filter_example' # str | A filter statement to identify specific records to retrieve. For more information on filtering, see Filtering in REST. (optional) + top = 56 # int | If zero or greater than 1000, return at most 1000 results. Otherwise, return this number of results. Used with skip to provide pagination for large datasets. (optional) + skip = 56 # int | If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets. (optional) order_by = 'order_by_example' # str | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. (optional) - count = True # bool | When true, returns a @recordSetCount in the result set (optional) - x_correlation_id = '8afdb9ff-bb10-414e-bd81-5cb5175aad0c' # str | Unique correlation Id in a GUID format (optional) + count = True # bool | If true, return the global count of elements in the collection. (optional) + count_only = True # bool | If true, return ONLY the global count of elements in the collection. It only applies when count=true. (optional) + x_correlation_id = '8092ac9c-17d0-4ee8-a00e-804088e5ab81' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -324,7 +325,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # List W9/W4/W8 forms - api_response = api_instance.list_w9_forms(avalara_version, filter=filter, top=top, skip=skip, order_by=order_by, count=count, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client) + api_response = api_instance.list_w9_forms(avalara_version, filter=filter, top=top, skip=skip, order_by=order_by, count=count, count_only=count_only, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling FormsW9Api->list_w9_forms: %s\n" % e) @@ -335,17 +336,18 @@ with Avalara.SDK.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **avalara_version** | **str**| API version | - **filter** | **str**| A filter statement to identify specific records to retrieve. For more information on filtering, see <a href=\"https://developer.avalara.com/avatax/filtering-in-rest/\">Filtering in REST</a>. | [optional] - **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. | [optional] if omitted the server will use the default value of 10 - **skip** | **int**| If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets. | [optional] if omitted the server will use the default value of 0 + **filter** | **str**| A filter statement to identify specific records to retrieve. For more information on filtering, see <a href=\"https://developer.avalara.com/avatax/filtering-in-rest/\">Filtering in REST</a>. | [optional] + **top** | **int**| If zero or greater than 1000, return at most 1000 results. Otherwise, return this number of results. Used with skip to provide pagination for large datasets. | [optional] + **skip** | **int**| If nonzero, skip this number of results before returning data. Used with top to provide pagination for large datasets. | [optional] **order_by** | **str**| A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. | [optional] - **count** | **bool**| When true, returns a @recordSetCount in the result set | [optional] + **count** | **bool**| If true, return the global count of elements in the collection. | [optional] + **count_only** | **bool**| If true, return ONLY the global count of elements in the collection. It only applies when count=true. | [optional] **x_correlation_id** | **str**| Unique correlation Id in a GUID format | [optional] **x_avalara_client** | **str**| Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . | [optional] ### Return type -[**PaginatedW9FormsModel**](PaginatedW9FormsModel.md) +[**PaginatedQueryResultModelW9FormBaseResponse**](PaginatedQueryResultModelW9FormBaseResponse.md) ### Authorization @@ -361,9 +363,9 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| -**200** | List of forms | - | **400** | Bad request (e.g., invalid sort key) | - | **401** | Authentication failed | - | +**200** | List of forms | - | [[Back to top]](#) [[Back to API list]](../../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../../README.md#documentation-for-models) [[Back to README]](../../../README.md) @@ -401,7 +403,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms_w9_api.FormsW9Api(api_client) id = 'id_example' # str | The ID of the W9/W4/W8 form. avalara_version = '2.0.0' # str | API version - x_correlation_id = '37d1fca1-1efa-454b-a3ff-94ec972b74b4' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '05ca3285-5ab1-43c0-88d7-f23c30428d54' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -488,7 +490,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms_w9_api.FormsW9Api(api_client) id = 'id_example' # str | ID of the form to update avalara_version = '2.0.0' # str | API version - x_correlation_id = '8c37ab84-020e-452c-ad69-df89a9ac9cfa' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '87498441-c774-4e3a-864e-dd604bff0d41' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) iw9_form_data_models_one_of = Avalara.SDK.IW9FormDataModelsOneOf() # IW9FormDataModelsOneOf | Form to be updated (optional) # example passing only required values which don't have defaults set @@ -576,7 +578,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = forms_w9_api.FormsW9Api(api_client) id = 'id_example' # str | Id of the form avalara_version = '2.0.0' # str | API version - x_correlation_id = '2ce587b6-7523-41b2-8033-347329740bcb' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '453b7d64-1fd0-4ed3-ba3c-a1d9ca1d69e6' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) file = None # bytearray | (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/Get1099Form200Response.md b/docs/A1099/V2/Get1099Form200Response.md index 9df8402..333ce74 100644 --- a/docs/A1099/V2/Get1099Form200Response.md +++ b/docs/A1099/V2/Get1099Form200Response.md @@ -69,24 +69,35 @@ Name | Type | Description | Notes **intermediary_or_flow_through** | [**IntermediaryOrFlowThroughResponse**](IntermediaryOrFlowThroughResponse.md) | Intermediary or flow-through entity information | [optional] **origin_of_health_coverage_code** | **str** | Origin of health coverage code | [optional] **covered_individuals** | [**List[CoveredIndividualReferenceResponse]**](CoveredIndividualReferenceResponse.md) | Covered individuals information | [optional] -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] **federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early withdrawal penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-exempt interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified private activity bond interest | [optional] +**market_discount** | **float** | Market discount | [optional] +**bond_premium** | **float** | Bond premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP number | [optional] **filer_type** | **str** | Filer type (PSE or EPF) | [optional] **payment_type** | **str** | Payment type (payment card or third party network) | [optional] **payment_settlement_entity_name_phone_number** | **str** | Payment settlement entity name and phone number | [optional] @@ -138,7 +149,6 @@ Name | Type | Description | Notes **total_employee_contributions** | **float** | Total employee contributions | [optional] **amount_allocable_to_irr** | **float** | Amount allocable to IRR within 5 years | [optional] **first_year_designated_roth_contrib** | **str** | First year of designated Roth contribution | [optional] -**fatca_requirement_indicator** | **bool** | FATCA filing requirement | [optional] **date_of_payment** | **str** | Date of payment | [optional] ## Example diff --git a/docs/A1099/V2/ICreateForm1099Request.md b/docs/A1099/V2/ICreateForm1099Request.md index a96db55..4b4be86 100644 --- a/docs/A1099/V2/ICreateForm1099Request.md +++ b/docs/A1099/V2/ICreateForm1099Request.md @@ -5,25 +5,25 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] **federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] -**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **type** | **str** | | [optional] **issuer_id** | **str** | Issuer ID | [optional] **reference_id** | **str** | Reference ID | [optional] @@ -31,16 +31,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/IUpdateForm1099Request.md b/docs/A1099/V2/IUpdateForm1099Request.md index f80d5d3..22a442b 100644 --- a/docs/A1099/V2/IUpdateForm1099Request.md +++ b/docs/A1099/V2/IUpdateForm1099Request.md @@ -5,25 +5,25 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**total_ordinary_dividends** | **str** | Total ordinary dividends | [optional] -**qualified_dividends** | **str** | Qualified dividends | [optional] -**total_capital_gain_distributions** | **str** | Total capital gain distributions | [optional] -**unrecaptured_section1250_gain** | **str** | Unrecaptured Section 1250 gain | [optional] -**section1202_gain** | **str** | Section 1202 gain | [optional] -**collectibles_gain** | **str** | Collectibles (28%) gain | [optional] -**section897_ordinary_dividends** | **str** | Section 897 ordinary dividends | [optional] -**section897_capital_gain** | **str** | Section 897 capital gain | [optional] -**nondividend_distributions** | **str** | Nondividend distributions | [optional] +**total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] +**qualified_dividends** | **float** | Qualified dividends | [optional] +**total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] +**unrecaptured_section1250_gain** | **float** | Unrecaptured Section 1250 gain | [optional] +**section1202_gain** | **float** | Section 1202 gain | [optional] +**collectibles_gain** | **float** | Collectibles (28%) gain | [optional] +**section897_ordinary_dividends** | **float** | Section 897 ordinary dividends | [optional] +**section897_capital_gain** | **float** | Section 897 capital gain | [optional] +**nondividend_distributions** | **float** | Nondividend distributions | [optional] **federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] -**section199_a_dividends** | **str** | Section 199A dividends | [optional] -**investment_expenses** | **str** | Investment expenses | [optional] -**foreign_tax_paid** | **str** | Foreign tax paid | [optional] +**section199_a_dividends** | **float** | Section 199A dividends | [optional] +**investment_expenses** | **float** | Investment expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] **foreign_country_or_us_possession** | **str** | Foreign country or U.S. possession | [optional] -**cash_liquidation_distributions** | **str** | Cash liquidation distributions | [optional] -**noncash_liquidation_distributions** | **str** | Noncash liquidation distributions | [optional] -**exempt_interest_dividends** | **str** | Exempt-interest dividends | [optional] -**specified_private_activity_bond_interest_dividends** | **str** | Specified private activity bond interest dividends | [optional] -**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**cash_liquidation_distributions** | **float** | Cash liquidation distributions | [optional] +**noncash_liquidation_distributions** | **float** | Noncash liquidation distributions | [optional] +**exempt_interest_dividends** | **float** | Exempt-interest dividends | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | Specified private activity bond interest dividends | [optional] +**fatca_filing_requirement** | **bool** | Fatca filing requirement | [optional] **type** | **str** | | [optional] **issuer_id** | **str** | Issuer ID | [optional] **reference_id** | **str** | Reference ID | [optional] @@ -31,16 +31,16 @@ Name | Type | Description | Notes **recipient_name** | **str** | Recipient name | [optional] **tin_type** | **str** | Type of TIN (Tax ID Number). Will be one of: * SSN * EIN * ITIN * ATIN | [optional] **recipient_second_name** | **str** | Recipient second name | [optional] -**address** | **str** | Address | +**address** | **str** | Address | [optional] **address2** | **str** | Address line 2 | [optional] -**city** | **str** | City | +**city** | **str** | City | [optional] **state** | **str** | US state. Required if CountryCode is \"US\". | [optional] **zip** | **str** | Zip/postal code | [optional] **email** | **str** | Recipient email address | [optional] **account_number** | **str** | Account number | [optional] **office_code** | **str** | Office code | [optional] **non_us_province** | **str** | Foreign province | [optional] -**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | +**country_code** | **str** | Country code, as defined at https://www.irs.gov/e-file-providers/country-codes | [optional] **federal_e_file** | **bool** | Boolean indicating that federal e-filing should be scheduled for this form | [optional] **postal_mail** | **bool** | Boolean indicating that postal mailing to the recipient should be scheduled for this form | [optional] **state_e_file** | **bool** | Boolean indicating that state e-filing should be scheduled for this form | [optional] diff --git a/docs/A1099/V2/Issuers1099Api.md b/docs/A1099/V2/Issuers1099Api.md index 63aa265..e66748d 100644 --- a/docs/A1099/V2/Issuers1099Api.md +++ b/docs/A1099/V2/Issuers1099Api.md @@ -45,7 +45,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = issuers1099_api.Issuers1099Api(api_client) avalara_version = '2.0.0' # str | API version - x_correlation_id = 'cd08f20c-e93f-4ed9-9fcc-1c43161a5ab1' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'd2b38090-a4c9-4170-bc1d-6cc2778b0bd0' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) issuer_command = Avalara.SDK.IssuerCommand() # IssuerCommand | The issuer to create (optional) # example passing only required values which don't have defaults set @@ -132,7 +132,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = issuers1099_api.Issuers1099Api(api_client) id = 'id_example' # str | Id of the issuer to delete avalara_version = '2.0.0' # str | API version - x_correlation_id = 'b31ed293-452b-4f1a-9781-92bf4cc732b2' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '22e9dc96-0041-4e27-ab37-038dc9d6c215' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -217,7 +217,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = issuers1099_api.Issuers1099Api(api_client) id = 'id_example' # str | Id of the issuer to retrieve avalara_version = '2.0.0' # str | API version - x_correlation_id = '6f7412dc-b5d2-4657-9ae0-9eb72e1cbaac' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '86c9eff5-1ed3-49b1-be09-a117b235f3e2' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -309,7 +309,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: order_by = 'order_by_example' # str | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. (optional) count = True # bool | If true, return the global count of elements in the collection. (optional) count_only = True # bool | If true, return ONLY the global count of elements in the collection. It only applies when count=true. (optional) - x_correlation_id = '6ab59fe8-83fc-4fa3-9617-abb9b8d1bdb7' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '0983f292-e1e0-4415-9cdc-b70482da76b0' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: @@ -403,7 +403,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = issuers1099_api.Issuers1099Api(api_client) id = 'id_example' # str | Id of the issuer to update avalara_version = '2.0.0' # str | API version - x_correlation_id = '2f427cf4-fa55-4abb-85da-d79a4a846191' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'f43f2c52-c35e-4e50-b1ad-2923b624e5a0' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) issuer_command = Avalara.SDK.IssuerCommand() # IssuerCommand | The issuer to update (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/Jobs1099Api.md b/docs/A1099/V2/Jobs1099Api.md index 8a292f0..c7889e1 100644 --- a/docs/A1099/V2/Jobs1099Api.md +++ b/docs/A1099/V2/Jobs1099Api.md @@ -41,7 +41,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = jobs1099_api.Jobs1099Api(api_client) id = 'id_example' # str | Job id obtained from other API responses, like `/1099/bulk-upsert`. avalara_version = '2.0.0' # str | API version - x_correlation_id = '85be69fe-08d7-40f4-8ce2-dd043ea36143' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '25f0c6ce-1d1a-45f6-b828-15789bccc55b' # str | Unique correlation Id in a GUID format (optional) x_avalara_client = 'Swagger UI; 22.1.0' # str | Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/) . (optional) # example passing only required values which don't have defaults set try: diff --git a/docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md b/docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md new file mode 100644 index 0000000..23af83e --- /dev/null +++ b/docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md @@ -0,0 +1,32 @@ +# PaginatedQueryResultModelW9FormBaseResponse + +Generic paginated model to wrap query response data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**recordset_count** | **int** | | [optional] +**value** | [**List[CreateW9Form201Response]**](CreateW9Form201Response.md) | | [optional] +**next_link** | **str** | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.paginated_query_result_model_w9_form_base_response import PaginatedQueryResultModelW9FormBaseResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedQueryResultModelW9FormBaseResponse from a JSON string +paginated_query_result_model_w9_form_base_response_instance = PaginatedQueryResultModelW9FormBaseResponse.from_json(json) +# print the JSON string representation of the object +print(PaginatedQueryResultModelW9FormBaseResponse.to_json()) + +# convert the object into a dict +paginated_query_result_model_w9_form_base_response_dict = paginated_query_result_model_w9_form_base_response_instance.to_dict() +# create an instance of PaginatedQueryResultModelW9FormBaseResponse from a dict +paginated_query_result_model_w9_form_base_response_from_dict = PaginatedQueryResultModelW9FormBaseResponse.from_dict(paginated_query_result_model_w9_form_base_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/A1099/V2/Update1099Form200Response.md b/docs/A1099/V2/Update1099Form200Response.md index 8499087..69f7fea 100644 --- a/docs/A1099/V2/Update1099Form200Response.md +++ b/docs/A1099/V2/Update1099Form200Response.md @@ -43,6 +43,43 @@ Name | Type | Description | Notes **tin_match_status** | [**StatusDetail**](StatusDetail.md) | | [optional] **address_verification_status** | [**StatusDetail**](StatusDetail.md) | | [optional] **validation_errors** | [**List[ValidationErrorResponse]**](ValidationErrorResponse.md) | | [optional] +**employee_first_name** | **str** | | [optional] +**employee_middle_name** | **str** | | [optional] +**employee_last_name** | **str** | | [optional] +**employee_name_suffix** | **str** | | [optional] +**employee_date_of_birth** | **datetime** | | [optional] +**origin_of_health_coverage_code** | **str** | | [optional] +**covered_individuals** | [**List[CoveredIndividualRequest]**](CoveredIndividualRequest.md) | | [optional] +**total_ordinary_dividends** | **float** | | [optional] +**qualified_dividends** | **float** | | [optional] +**total_capital_gain_distributions** | **float** | | [optional] +**unrecaptured_section1250_gain** | **float** | | [optional] +**section1202_gain** | **float** | | [optional] +**collectibles_gain** | **float** | | [optional] +**section897_ordinary_dividends** | **float** | | [optional] +**section897_capital_gain** | **float** | | [optional] +**nondividend_distributions** | **float** | | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**section199_a_dividends** | **float** | | [optional] +**investment_expenses** | **float** | Investment Expenses | [optional] +**foreign_tax_paid** | **float** | Foreign tax paid | [optional] +**foreign_country_or_us_possession** | **str** | | [optional] +**cash_liquidation_distributions** | **float** | | [optional] +**noncash_liquidation_distributions** | **float** | | [optional] +**exempt_interest_dividends** | **float** | | [optional] +**specified_private_activity_bond_interest_dividends** | **float** | | [optional] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**interest_income** | **float** | Interest Income | [optional] +**early_withdrawal_penalty** | **float** | Early Withdrawal Penalty | [optional] +**us_savings_bonds_interest** | **float** | Interest on U.S. Savings Bonds and Treasury obligations | [optional] +**foreign_country** | **str** | Foreign country or U.S. possession | [optional] +**tax_exempt_interest** | **float** | Tax-Exempt Interest | [optional] +**specified_private_activity_bond_interest** | **float** | Specified Private activity | [optional] +**market_discount** | **float** | Market Discount | [optional] +**bond_premium** | **float** | Bond Premium | [optional] +**bond_premium_on_treasury_obligations** | **float** | Bond Premium on Treasury obligations | [optional] +**bond_premium_on_tax_exempt_bond** | **float** | Bond Premium on tax exempt bond | [optional] +**tax_exempt_bond_cusip_number** | **str** | Tax exempt bond CUSIP no. | [optional] **filer_type** | **str** | | [optional] **payment_type** | **str** | | [optional] **payment_settlement_entity_name_phone_number** | **str** | | [optional] @@ -50,7 +87,6 @@ Name | Type | Description | Notes **card_not_present_transactions** | **float** | | [optional] **merchant_category_code** | **str** | | [optional] **payment_transaction_number** | **float** | | [optional] -**federal_income_tax_withheld** | **float** | | [optional] **january** | **float** | | [optional] **february** | **float** | | [optional] **march** | **float** | | [optional] @@ -75,10 +111,27 @@ Name | Type | Description | Notes **gross_proceeds_paid_to_attorney** | **float** | | [optional] **fish_purchased_for_resale** | **float** | | [optional] **section409_a_deferrals** | **float** | | [optional] -**fatca_filing_requirement** | **bool** | | [optional] **excess_golden_parachute_payments** | **float** | | [optional] **nonqualified_deferred_compensation** | **float** | | [optional] **nonemployee_compensation** | **float** | | [optional] +**gross_distribution** | **float** | Gross distribution | [optional] +**taxable_amount** | **float** | Taxable amount | [optional] +**taxable_amount_not_determined** | **bool** | Taxable amount not determined | [optional] +**total_distribution_determined** | **bool** | Total distribution | [optional] +**capital_gain** | **float** | Capital gain (included in Box 2a) | [optional] +**employee_contributions_or_designated_roth_or_insurance_premiums** | **float** | Employee contributions/Designated Roth contributions or insurance premiums | [optional] +**net_unrealized_appreciation_in_employer_securities** | **float** | Net unrealized appreciation in employer's securities | [optional] +**distribution_code** | **str** | Distribution code | [optional] +**second_distribution_code** | **str** | Second distribution code | [optional] +**ira_sep_simple** | **bool** | IRA/SEP/SIMPLE | [optional] +**traditional_ira_sep_simple_or_roth_conversion_amount** | **float** | Traditional IRA/SEP/SIMPLE or Roth conversion amount | [optional] +**other_amount** | **float** | Other amount | [optional] +**other_percentage** | **str** | Other percentage | [optional] +**total_distribution_percentage** | **str** | Total distribution percentage | [optional] +**total_employee_contributions** | **float** | Total employee contributions | [optional] +**amount_allocable_to_irr_within5_years** | **float** | Amount allocable to IRR within 5 years | [optional] +**first_year_of_designated_roth_contribution** | **str** | First year of designated Roth contribution | [optional] +**date_of_payment** | **datetime** | Date of payment | [optional] ## Example diff --git a/docs/A1099/V2/W4FormResponse.md b/docs/A1099/V2/W4FormResponse.md index 24bf675..488e06d 100644 --- a/docs/A1099/V2/W4FormResponse.md +++ b/docs/A1099/V2/W4FormResponse.md @@ -24,20 +24,6 @@ Name | Type | Description | Notes **additional_withheld** | **float** | The additional amount withheld. | [optional] **exempt_from_withholding** | **bool** | Indicates whether the employee is exempt from withholding. | [optional] **office_code** | **str** | The office code associated with the form. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8BenEFormResponse.md b/docs/A1099/V2/W8BenEFormResponse.md index c91a505..84b8502 100644 --- a/docs/A1099/V2/W8BenEFormResponse.md +++ b/docs/A1099/V2/W8BenEFormResponse.md @@ -101,20 +101,6 @@ Name | Type | Description | Notes **substantial_us_owners** | [**List[SubstantialUsOwnerResponse]**](SubstantialUsOwnerResponse.md) | The list of substantial U.S. owners of passive NFFE. | [optional] **signer_name** | **str** | The name of the signer. | [optional] **capacity_to_sign_certification** | **bool** | Certifies signer has the capacity to sign for the beneficial owner. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8BenFormResponse.md b/docs/A1099/V2/W8BenFormResponse.md index 92c6697..bc9ad55 100644 --- a/docs/A1099/V2/W8BenFormResponse.md +++ b/docs/A1099/V2/W8BenFormResponse.md @@ -31,20 +31,6 @@ Name | Type | Description | Notes **income_type** | **str** | The type of income covered by the treaty. | [optional] **signer_name** | **str** | The name of the signer of the form. | [optional] **signer_capacity** | **str** | The capacity in which the signer is signing the form. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8ImyFormResponse.md b/docs/A1099/V2/W8ImyFormResponse.md index feffe09..bd3fecb 100644 --- a/docs/A1099/V2/W8ImyFormResponse.md +++ b/docs/A1099/V2/W8ImyFormResponse.md @@ -116,20 +116,6 @@ Name | Type | Description | Notes **sponsored_direct_reporting_nffe_certification** | **bool** | Certifies that the entity is a sponsored direct reporting NFFE. | [optional] **direct_reporting_nffe_sponsoring_entity** | **str** | The name of the entity that sponsors the direct reporting NFFE. | [optional] **signer_name** | **str** | The name of the signer. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] ## Example diff --git a/docs/A1099/V2/W9FormBaseResponse.md b/docs/A1099/V2/W9FormBaseResponse.md index 0ef82a1..a905615 100644 --- a/docs/A1099/V2/W9FormBaseResponse.md +++ b/docs/A1099/V2/W9FormBaseResponse.md @@ -6,7 +6,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] **entry_status** | **str** | The form status. | [optional] **entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] **reference_id** | **str** | A reference identifier for the form. | [optional] @@ -19,6 +18,7 @@ Name | Type | Description | Notes **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **created_at** | **datetime** | The creation date of the form. | [optional] **updated_at** | **datetime** | The last updated date of the form. | [optional] +**type** | **str** | The type of the response object. | [optional] ## Example diff --git a/docs/A1099/V2/W9FormResponse.md b/docs/A1099/V2/W9FormResponse.md index ce2787c..0a0fb46 100644 --- a/docs/A1099/V2/W9FormResponse.md +++ b/docs/A1099/V2/W9FormResponse.md @@ -24,20 +24,6 @@ Name | Type | Description | Notes **backup_withholding** | **bool** | Indicates whether backup withholding applies. | [optional] **is1099able** | **bool** | Indicates whether the individual or entity should be issued a 1099 form. | [optional] **tin_match_status** | [**TinMatchStatusResponse**](TinMatchStatusResponse.md) | The TIN Match status from IRS. | [optional] -**id** | **str** | The unique identifier for the form. | [optional] -**type** | **str** | The form type. | [optional] -**entry_status** | **str** | The form status. | [optional] -**entry_status_date** | **datetime** | The timestamp for the latest status update. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**display_name** | **str** | The display name associated with the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] -**archived** | **bool** | Indicates whether the form is archived. | [optional] -**signature** | **str** | The signature of the form. | [optional] -**signed_date** | **datetime** | The date the form was signed. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**created_at** | **datetime** | The creation date of the form. | [optional] -**updated_at** | **datetime** | The last updated date of the form. | [optional] ## Example diff --git a/setup.py b/setup.py index 209a851..7991f12 100644 --- a/setup.py +++ b/setup.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.1 +@version 25.8.2 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -40,7 +40,7 @@ from setuptools import setup, find_namespace_packages NAME = "Avalara.SDK" -VERSION = "25.8.1" +VERSION = "25.8.2" PYTHON_REQUIRES = ">=3.7" REQUIRES = [ "urllib3 >= 1.25.3, < 2.1.0",