From 32d8dc2459517b8d26c157d31ec0f4da155a3e9a Mon Sep 17 00:00:00 2001 From: Jonathan Wenger Date: Fri, 29 Aug 2025 07:46:10 -0700 Subject: [PATCH 1/2] 25.8.3 --- Avalara/SDK/api/A1099/V2/companies_w9_api.py | 35 +- Avalara/SDK/api/A1099/V2/forms1099_api.py | 86 ++-- Avalara/SDK/api/A1099/V2/forms_w9_api.py | 153 +++++- Avalara/SDK/api/A1099/V2/issuers1099_api.py | 26 +- Avalara/SDK/api/A1099/V2/jobs1099_api.py | 2 +- Avalara/SDK/api/A1099/V2/jobs_api.py | 206 ++++++++ .../EInvoicing/V1/data_input_fields_api.py | 4 +- .../SDK/api/EInvoicing/V1/documents_api.py | 4 +- Avalara/SDK/api/EInvoicing/V1/interop_api.py | 4 +- Avalara/SDK/api/EInvoicing/V1/mandates_api.py | 4 +- .../api/EInvoicing/V1/subscriptions_api.py | 4 +- .../api/EInvoicing/V1/tax_identifiers_api.py | 4 +- .../api/EInvoicing/V1/trading_partners_api.py | 4 +- .../A1099/V2/authorized_api_request_model.py | 2 +- .../authorized_api_request_v2_data_model.py | 2 +- .../A1099/V2/bulk_upsert1099_forms_request.py | 18 +- .../V2/company_create_update_request_model.py | 115 ++++- .../SDK/models/A1099/V2/company_response.py | 146 +++++- .../SDK/models/A1099/V2/covered_individual.py | 244 ++++++++++ .../A1099/V2/create1099_form201_response.py | 18 +- .../create_and_send_w9_form_email_request.py | 195 ++++++++ .../models/A1099/V2/create_company_request.py | 153 ++++++ .../models/A1099/V2/create_issuer_request.py | 153 ++++++ .../A1099/V2/create_w9_form201_response.py | 2 +- .../models/A1099/V2/create_w9_form_request.py | 2 +- Avalara/SDK/models/A1099/V2/data.py | 4 +- .../models/A1099/V2/entry_status_response.py | 111 +++++ Avalara/SDK/models/A1099/V2/error_model.py | 2 +- Avalara/SDK/models/A1099/V2/error_response.py | 2 +- .../A1099/V2/error_response_errors_inner.py | 4 +- .../models/A1099/V2/error_response_item.py | 2 +- Avalara/SDK/models/A1099/V2/form1042_s.py | 448 +++++++++++------ .../SDK/models/A1099/V2/form1042_s_list.py | 2 +- .../models/A1099/V2/form1042_s_list_item.py | 6 +- .../A1099/V2/form1042_s_list_item_response.py | 12 +- .../SDK/models/A1099/V2/form1042_s_request.py | 6 +- .../models/A1099/V2/form1042_s_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1095_b.py | 343 ++++++++----- .../SDK/models/A1099/V2/form1095_b_list.py | 2 +- .../models/A1099/V2/form1095_b_list_item.py | 4 +- .../A1099/V2/form1095_b_list_item_response.py | 10 +- .../SDK/models/A1099/V2/form1095_b_request.py | 4 +- .../models/A1099/V2/form1095_b_response.py | 10 +- Avalara/SDK/models/A1099/V2/form1095_c.py | 449 ++++++++++++++++++ .../SDK/models/A1099/V2/form1095_c_list.py | 2 +- .../models/A1099/V2/form1095_c_list_item.py | 6 +- Avalara/SDK/models/A1099/V2/form1099_base.py | 320 ++++++++----- .../models/A1099/V2/form1099_base_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1099_div.py | 359 ++++++++------ .../SDK/models/A1099/V2/form1099_div_list.py | 2 +- .../models/A1099/V2/form1099_div_list_item.py | 2 +- .../V2/form1099_div_list_item_response.py | 8 +- .../models/A1099/V2/form1099_div_request.py | 2 +- .../models/A1099/V2/form1099_div_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1099_int.py | 349 ++++++++------ .../SDK/models/A1099/V2/form1099_int_list.py | 2 +- .../models/A1099/V2/form1099_int_list_item.py | 2 +- .../V2/form1099_int_list_item_response.py | 8 +- .../models/A1099/V2/form1099_int_request.py | 2 +- .../models/A1099/V2/form1099_int_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1099_k.py | 360 ++++++++------ .../SDK/models/A1099/V2/form1099_k_list.py | 2 +- .../models/A1099/V2/form1099_k_list_item.py | 2 +- .../A1099/V2/form1099_k_list_item_response.py | 8 +- .../SDK/models/A1099/V2/form1099_k_request.py | 2 +- .../models/A1099/V2/form1099_k_response.py | 8 +- .../models/A1099/V2/form1099_list_request.py | 123 +++++ .../models/A1099/V2/form1099_list_response.py | 2 +- .../V2/form1099_list_response_value_inner.py | 18 +- Avalara/SDK/models/A1099/V2/form1099_misc.py | 351 ++++++++------ .../SDK/models/A1099/V2/form1099_misc_list.py | 2 +- .../A1099/V2/form1099_misc_list_item.py | 2 +- .../V2/form1099_misc_list_item_response.py | 8 +- .../models/A1099/V2/form1099_misc_request.py | 2 +- .../models/A1099/V2/form1099_misc_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1099_nec.py | 326 ++++++++----- .../SDK/models/A1099/V2/form1099_nec_list.py | 2 +- .../models/A1099/V2/form1099_nec_list_item.py | 2 +- .../V2/form1099_nec_list_item_response.py | 8 +- .../models/A1099/V2/form1099_nec_request.py | 2 +- .../models/A1099/V2/form1099_nec_response.py | 8 +- .../A1099/V2/form1099_proccess_result.py | 4 +- ...9_proccess_result_processed_forms_inner.py | 16 +- Avalara/SDK/models/A1099/V2/form1099_r.py | 361 ++++++++------ .../SDK/models/A1099/V2/form1099_r_list.py | 2 +- .../models/A1099/V2/form1099_r_list_item.py | 2 +- .../A1099/V2/form1099_r_list_item_response.py | 8 +- .../SDK/models/A1099/V2/form1099_r_request.py | 2 +- .../models/A1099/V2/form1099_r_response.py | 8 +- .../models/A1099/V2/form1099_status_detail.py | 2 +- .../SDK/models/A1099/V2/form_request_base.py | 2 +- .../A1099/V2/form_request_list_item_base.py | 2 +- .../SDK/models/A1099/V2/form_response_base.py | 8 +- .../A1099/V2/form_single_request_base.py | 2 +- .../A1099/V2/get1099_form200_response.py | 162 +++---- .../A1099/V2/i_create_form1099_request.py | 8 +- .../A1099/V2/i_update_form1099_request.py | 8 +- .../A1099/V2/intermediary_or_flow_through.py | 26 +- Avalara/SDK/models/A1099/V2/irs_response.py | 2 +- Avalara/SDK/models/A1099/V2/issuer_command.py | 47 +- .../SDK/models/A1099/V2/issuer_response.py | 136 +++++- .../A1099/V2/iw9_form_data_models_one_of.py | 2 +- Avalara/SDK/models/A1099/V2/job_response.py | 174 +++++++ .../SDK/models/A1099/V2/offer_and_coverage.py | 175 +++++++ ...ted_query_result_model_company_response.py | 2 +- ...inated_query_result_model_form1099_base.py | 130 +++++ ...ated_query_result_model_issuer_response.py | 2 +- ...uery_result_model_w9_form_base_response.py | 2 +- .../A1099/V2/paginated_w9_forms_model.py | 2 +- .../A1099/V2/primary_withholding_agent.py | 26 +- .../A1099/V2/state_and_local_withholding.py | 18 +- .../A1099/V2/state_efile_status_detail.py | 2 +- .../A1099/V2/substantial_us_owner_request.py | 2 +- .../A1099/V2/substantial_us_owner_response.py | 2 +- .../A1099/V2/tin_match_status_response.py | 2 +- .../A1099/V2/update1099_form200_response.py | 18 +- .../SDK/models/A1099/V2/validation_error.py | 6 +- .../SDK/models/A1099/V2/w4_form_data_model.py | 2 +- .../A1099/V2/w4_form_minimal_request.py | 135 ++++++ .../SDK/models/A1099/V2/w4_form_request.py | 37 +- .../SDK/models/A1099/V2/w4_form_response.py | 22 +- .../A1099/V2/w8_ben_e_form_minimal_request.py | 134 ++++++ .../models/A1099/V2/w8_ben_e_form_request.py | 37 +- .../models/A1099/V2/w8_ben_e_form_response.py | 22 +- ...8_ben_e_substantial_us_owner_data_model.py | 2 +- .../models/A1099/V2/w8_ben_form_data_model.py | 2 +- .../A1099/V2/w8_ben_form_minimal_request.py | 134 ++++++ .../models/A1099/V2/w8_ben_form_request.py | 37 +- .../models/A1099/V2/w8_ben_form_response.py | 22 +- .../A1099/V2/w8_bene_form_data_model.py | 2 +- .../models/A1099/V2/w8_imy_form_data_model.py | 2 +- .../A1099/V2/w8_imy_form_minimal_request.py | 134 ++++++ .../models/A1099/V2/w8_imy_form_request.py | 37 +- .../models/A1099/V2/w8_imy_form_response.py | 22 +- .../A1099/V2/w9_form_base_minimal_request.py | 132 +++++ .../models/A1099/V2/w9_form_base_request.py | 25 +- .../models/A1099/V2/w9_form_base_response.py | 7 +- .../SDK/models/A1099/V2/w9_form_data_model.py | 2 +- .../A1099/V2/w9_form_minimal_request.py | 134 ++++++ .../SDK/models/A1099/V2/w9_form_request.py | 37 +- .../SDK/models/A1099/V2/w9_form_response.py | 22 +- Avalara/SDK/models/EInvoicing/V1/address.py | 2 +- .../EInvoicing/V1/bad_download_request.py | 2 +- .../SDK/models/EInvoicing/V1/bad_request.py | 2 +- .../EInvoicing/V1/batch_error_detail.py | 2 +- .../SDK/models/EInvoicing/V1/batch_search.py | 2 +- .../V1/batch_search_list_response.py | 2 +- .../batch_search_participants202_response.py | 2 +- .../EInvoicing/V1/conditional_for_field.py | 2 +- Avalara/SDK/models/EInvoicing/V1/consents.py | 2 +- .../V1/create_trading_partner201_response.py | 2 +- ...eate_trading_partners_batch200_response.py | 2 +- ..._partners_batch200_response_value_inner.py | 2 +- .../create_trading_partners_batch_request.py | 2 +- .../models/EInvoicing/V1/data_input_field.py | 2 +- .../V1/data_input_field_not_used_for.py | 2 +- .../V1/data_input_field_optional_for.py | 2 +- .../V1/data_input_field_required_for.py | 2 +- .../V1/data_input_fields_response.py | 2 +- .../models/EInvoicing/V1/document_fetch.py | 2 +- .../EInvoicing/V1/document_list_response.py | 2 +- .../EInvoicing/V1/document_status_response.py | 2 +- .../V1/document_submission_error.py | 2 +- .../EInvoicing/V1/document_submit_response.py | 2 +- .../models/EInvoicing/V1/document_summary.py | 2 +- .../models/EInvoicing/V1/error_response.py | 2 +- Avalara/SDK/models/EInvoicing/V1/event_id.py | 2 +- .../SDK/models/EInvoicing/V1/event_message.py | 2 +- .../SDK/models/EInvoicing/V1/event_payload.py | 2 +- .../EInvoicing/V1/event_subscription.py | 2 +- Avalara/SDK/models/EInvoicing/V1/extension.py | 2 +- .../EInvoicing/V1/fetch_documents_request.py | 2 +- .../V1/fetch_documents_request_data_inner.py | 2 +- .../V1/fetch_documents_request_metadata.py | 2 +- .../models/EInvoicing/V1/forbidden_error.py | 2 +- .../models/EInvoicing/V1/hmac_signature.py | 2 +- .../EInvoicing/V1/hmac_signature_value.py | 2 +- Avalara/SDK/models/EInvoicing/V1/id.py | 2 +- .../SDK/models/EInvoicing/V1/identifier.py | 2 +- .../EInvoicing/V1/input_data_formats.py | 2 +- .../EInvoicing/V1/internal_server_error.py | 2 +- Avalara/SDK/models/EInvoicing/V1/mandate.py | 2 +- .../EInvoicing/V1/mandate_data_input_field.py | 2 +- .../V1/mandate_data_input_field_namespace.py | 2 +- .../models/EInvoicing/V1/mandates_response.py | 2 +- .../models/EInvoicing/V1/not_found_error.py | 2 +- .../EInvoicing/V1/not_used_for_field.py | 2 +- .../EInvoicing/V1/output_data_formats.py | 2 +- .../SDK/models/EInvoicing/V1/pagination.py | 2 +- .../EInvoicing/V1/required_when_field.py | 2 +- .../V1/search_participants200_response.py | 2 +- Avalara/SDK/models/EInvoicing/V1/signature.py | 2 +- .../EInvoicing/V1/signature_signature.py | 2 +- .../models/EInvoicing/V1/signature_value.py | 2 +- .../V1/signature_value_signature.py | 2 +- .../SDK/models/EInvoicing/V1/status_event.py | 2 +- .../EInvoicing/V1/submit_document_metadata.py | 2 +- .../V1/submit_interop_document202_response.py | 2 +- .../EInvoicing/V1/subscription_common.py | 2 +- .../EInvoicing/V1/subscription_detail.py | 2 +- .../V1/subscription_list_response.py | 2 +- .../V1/subscription_registration.py | 2 +- .../models/EInvoicing/V1/success_response.py | 2 +- .../EInvoicing/V1/supported_document_types.py | 2 +- .../EInvoicing/V1/tax_identifier_request.py | 2 +- .../EInvoicing/V1/tax_identifier_response.py | 2 +- .../V1/tax_identifier_response_value.py | 2 +- ...dentifier_schema_by_country200_response.py | 2 +- .../models/EInvoicing/V1/trading_partner.py | 2 +- .../V1/update_trading_partner200_response.py | 2 +- .../models/EInvoicing/V1/validation_error.py | 2 +- .../EInvoicing/V1/webhook_invocation.py | 2 +- .../EInvoicing/V1/webhooks_error_info.py | 2 +- .../EInvoicing/V1/webhooks_error_response.py | 2 +- .../SDK/models/EInvoicing/V1/workflow_ids.py | 2 +- README.md | 97 +--- docs/A1099/V2/CompaniesW9Api.md | 40 +- .../V2/CompanyCreateUpdateRequestModel.md | 34 +- docs/A1099/V2/CompanyResponse.md | 40 +- docs/A1099/V2/CoveredIndividual.md | 49 ++ .../V2/CreateAndSendW9FormEmailRequest.md | 38 ++ docs/A1099/V2/CreateCompanyRequest.md | 48 ++ docs/A1099/V2/CreateIssuerRequest.md | 46 ++ docs/A1099/V2/CreateW9Form201Response.md | 4 +- docs/A1099/V2/CreateW9FormRequest.md | 6 +- docs/A1099/V2/EntryStatusResponse.md | 31 ++ docs/A1099/V2/Form1042S.md | 125 ++--- docs/A1099/V2/Form1095B.md | 88 ++-- docs/A1099/V2/Form1095C.md | 77 +++ docs/A1099/V2/Form1099Base.md | 78 +-- docs/A1099/V2/Form1099Div.md | 116 ++--- docs/A1099/V2/Form1099Int.md | 107 ++--- docs/A1099/V2/Form1099K.md | 119 ++--- docs/A1099/V2/Form1099ListRequest.md | 30 ++ docs/A1099/V2/Form1099Misc.md | 108 ++--- docs/A1099/V2/Form1099Nec.md | 84 ++-- docs/A1099/V2/Form1099R.md | 118 ++--- docs/A1099/V2/Forms1099Api.md | 92 ++-- docs/A1099/V2/FormsW9Api.md | 125 ++++- docs/A1099/V2/Get1099Form200Response.md | 178 +++---- docs/A1099/V2/IntermediaryOrFlowThrough.md | 23 +- docs/A1099/V2/IssuerCommand.md | 30 +- docs/A1099/V2/IssuerResponse.md | 36 +- docs/A1099/V2/Issuers1099Api.md | 28 +- docs/A1099/V2/JobResponse.md | 49 ++ docs/A1099/V2/JobsApi.md | 98 ++++ docs/A1099/V2/OfferAndCoverage.md | 35 ++ .../PaginatedQueryResultModelForm1099Base.md | 32 ++ docs/A1099/V2/PrimaryWithholdingAgent.md | 5 +- docs/A1099/V2/StateAndLocalWithholding.md | 16 +- docs/A1099/V2/ValidationError.md | 4 +- docs/A1099/V2/W4FormMinimalRequest.md | 35 ++ docs/A1099/V2/W4FormRequest.md | 6 +- docs/A1099/V2/W8BenEFormMinimalRequest.md | 34 ++ docs/A1099/V2/W8BenEFormRequest.md | 6 +- docs/A1099/V2/W8BenFormMinimalRequest.md | 34 ++ docs/A1099/V2/W8BenFormRequest.md | 6 +- docs/A1099/V2/W8ImyFormMinimalRequest.md | 34 ++ docs/A1099/V2/W8ImyFormRequest.md | 6 +- docs/A1099/V2/W9FormBaseMinimalRequest.md | 32 ++ docs/A1099/V2/W9FormBaseRequest.md | 6 +- docs/A1099/V2/W9FormBaseResponse.md | 4 +- docs/A1099/V2/W9FormMinimalRequest.md | 34 ++ docs/A1099/V2/W9FormRequest.md | 6 +- setup.py | 4 +- 265 files changed, 7736 insertions(+), 2757 deletions(-) create mode 100644 Avalara/SDK/api/A1099/V2/jobs_api.py create mode 100644 Avalara/SDK/models/A1099/V2/covered_individual.py create mode 100644 Avalara/SDK/models/A1099/V2/create_and_send_w9_form_email_request.py create mode 100644 Avalara/SDK/models/A1099/V2/create_company_request.py create mode 100644 Avalara/SDK/models/A1099/V2/create_issuer_request.py create mode 100644 Avalara/SDK/models/A1099/V2/entry_status_response.py create mode 100644 Avalara/SDK/models/A1099/V2/form1095_c.py create mode 100644 Avalara/SDK/models/A1099/V2/form1099_list_request.py create mode 100644 Avalara/SDK/models/A1099/V2/job_response.py create mode 100644 Avalara/SDK/models/A1099/V2/offer_and_coverage.py create mode 100644 Avalara/SDK/models/A1099/V2/paginated_query_result_model_form1099_base.py create mode 100644 Avalara/SDK/models/A1099/V2/w4_form_minimal_request.py create mode 100644 Avalara/SDK/models/A1099/V2/w8_ben_e_form_minimal_request.py create mode 100644 Avalara/SDK/models/A1099/V2/w8_ben_form_minimal_request.py create mode 100644 Avalara/SDK/models/A1099/V2/w8_imy_form_minimal_request.py create mode 100644 Avalara/SDK/models/A1099/V2/w9_form_base_minimal_request.py create mode 100644 Avalara/SDK/models/A1099/V2/w9_form_minimal_request.py create mode 100644 docs/A1099/V2/CoveredIndividual.md create mode 100644 docs/A1099/V2/CreateAndSendW9FormEmailRequest.md create mode 100644 docs/A1099/V2/CreateCompanyRequest.md create mode 100644 docs/A1099/V2/CreateIssuerRequest.md create mode 100644 docs/A1099/V2/EntryStatusResponse.md create mode 100644 docs/A1099/V2/Form1095C.md create mode 100644 docs/A1099/V2/Form1099ListRequest.md create mode 100644 docs/A1099/V2/JobResponse.md create mode 100644 docs/A1099/V2/JobsApi.md create mode 100644 docs/A1099/V2/OfferAndCoverage.md create mode 100644 docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md create mode 100644 docs/A1099/V2/W4FormMinimalRequest.md create mode 100644 docs/A1099/V2/W8BenEFormMinimalRequest.md create mode 100644 docs/A1099/V2/W8BenFormMinimalRequest.md create mode 100644 docs/A1099/V2/W8ImyFormMinimalRequest.md create mode 100644 docs/A1099/V2/W9FormBaseMinimalRequest.md create mode 100644 docs/A1099/V2/W9FormMinimalRequest.md diff --git a/Avalara/SDK/api/A1099/V2/companies_w9_api.py b/Avalara/SDK/api/A1099/V2/companies_w9_api.py index d790503..3f29ebc 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,9 +43,8 @@ from pydantic import Field, StrictBool, StrictInt, StrictStr from typing import Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.company_create_update_request_model import CompanyCreateUpdateRequestModel from Avalara.SDK.models.A1099.V2.company_response import CompanyResponse -from Avalara.SDK.models.A1099.V2.company_response_model import CompanyResponseModel +from Avalara.SDK.models.A1099.V2.create_company_request import CreateCompanyRequest from Avalara.SDK.models.A1099.V2.paginated_query_result_model_company_response import PaginatedQueryResultModelCompanyResponse from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth @@ -61,12 +60,12 @@ 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.2") + api_client.set_sdk_version("25.8.3") self.api_client = api_client self.create_company_endpoint = _Endpoint( settings={ - 'response_type': (CompanyResponseModel,), + 'response_type': (CompanyResponse,), 'auth': [ 'bearer' ], @@ -80,7 +79,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'company_create_update_request_model', + 'create_company_request', ], 'required': [ 'avalara_version', @@ -104,8 +103,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'company_create_update_request_model': - (CompanyCreateUpdateRequestModel,), + 'create_company_request': + (CreateCompanyRequest,), }, 'attribute_map': { 'avalara_version': 'avalara-version', @@ -116,7 +115,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'company_create_update_request_model': 'body', + 'create_company_request': 'body', }, 'collection_format_map': { } @@ -372,7 +371,7 @@ def __set_configuration(self, api_client): ) self.update_company_endpoint = _Endpoint( settings={ - 'response_type': (CompanyResponseModel,), + 'response_type': (CompanyResponse,), 'auth': [ 'bearer' ], @@ -387,7 +386,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'company_create_update_request_model', + 'create_company_request', ], 'required': [ 'id', @@ -414,8 +413,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'company_create_update_request_model': - (CompanyCreateUpdateRequestModel,), + 'create_company_request': + (CreateCompanyRequest,), }, 'attribute_map': { 'id': 'id', @@ -428,7 +427,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'company_create_update_request_model': 'body', + 'create_company_request': 'body', }, 'collection_format_map': { } @@ -470,7 +469,7 @@ def create_company( Keyword Args: 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] - company_create_update_request_model (CompanyCreateUpdateRequestModel): The company to create. [optional] + create_company_request (CreateCompanyRequest): The company to create. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -492,7 +491,7 @@ def create_company( async_req (bool): execute request asynchronously Returns: - CompanyResponseModel + CompanyResponse If the method is called asynchronously, returns the request thread. """ @@ -761,7 +760,7 @@ def update_company( Keyword Args: 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] - company_create_update_request_model (CompanyCreateUpdateRequestModel): The updated company data. [optional] + create_company_request (CreateCompanyRequest): The updated company data. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -783,7 +782,7 @@ def update_company( async_req (bool): execute request asynchronously Returns: - CompanyResponseModel + CompanyResponse If the method is called asynchronously, returns the request thread. """ diff --git a/Avalara/SDK/api/A1099/V2/forms1099_api.py b/Avalara/SDK/api/A1099/V2/forms1099_api.py index a5822a5..e235bbf 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,14 +43,10 @@ from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr from typing import Optional, Union from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.bulk_upsert1099_forms_request import BulkUpsert1099FormsRequest -from Avalara.SDK.models.A1099.V2.create1099_form201_response import Create1099Form201Response -from Avalara.SDK.models.A1099.V2.form1099_list_response import Form1099ListResponse -from Avalara.SDK.models.A1099.V2.form1099_proccess_result import Form1099ProccessResult +from Avalara.SDK.models.A1099.V2.form1099_list_request import Form1099ListRequest from Avalara.SDK.models.A1099.V2.get1099_form200_response import Get1099Form200Response -from Avalara.SDK.models.A1099.V2.i_create_form1099_request import ICreateForm1099Request -from Avalara.SDK.models.A1099.V2.i_update_form1099_request import IUpdateForm1099Request -from Avalara.SDK.models.A1099.V2.update1099_form200_response import Update1099Form200Response +from Avalara.SDK.models.A1099.V2.job_response import JobResponse +from Avalara.SDK.models.A1099.V2.paginated_query_result_model_form1099_base import PaginatedQueryResultModelForm1099Base from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth @@ -65,12 +61,12 @@ 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.2") + api_client.set_sdk_version("25.8.3") self.api_client = api_client self.bulk_upsert1099_forms_endpoint = _Endpoint( settings={ - 'response_type': (Form1099ProccessResult,), + 'response_type': (JobResponse,), 'auth': [ 'bearer' ], @@ -85,7 +81,7 @@ def __set_configuration(self, api_client): 'dry_run', 'x_correlation_id', 'x_avalara_client', - 'bulk_upsert1099_forms_request', + 'form1099_list_request', ], 'required': [ 'avalara_version', @@ -111,8 +107,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'bulk_upsert1099_forms_request': - (BulkUpsert1099FormsRequest,), + 'form1099_list_request': + (Form1099ListRequest,), }, 'attribute_map': { 'avalara_version': 'avalara-version', @@ -125,7 +121,7 @@ def __set_configuration(self, api_client): 'dry_run': 'query', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'bulk_upsert1099_forms_request': 'body', + 'form1099_list_request': 'body', }, 'collection_format_map': { } @@ -147,7 +143,7 @@ def __set_configuration(self, api_client): ) self.create1099_form_endpoint = _Endpoint( settings={ - 'response_type': (Create1099Form201Response,), + 'response_type': (Get1099Form200Response,), 'auth': [ 'bearer' ], @@ -161,7 +157,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'i_create_form1099_request', + 'get1099_form200_response', ], 'required': [ 'avalara_version', @@ -185,8 +181,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'i_create_form1099_request': - (ICreateForm1099Request,), + 'get1099_form200_response': + (Get1099Form200Response,), }, 'attribute_map': { 'avalara_version': 'avalara-version', @@ -197,7 +193,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'i_create_form1099_request': 'body', + 'get1099_form200_response': 'body', }, 'collection_format_map': { } @@ -435,7 +431,7 @@ def __set_configuration(self, api_client): ) self.list1099_forms_endpoint = _Endpoint( settings={ - 'response_type': (Form1099ListResponse,), + 'response_type': (PaginatedQueryResultModelForm1099Base,), 'auth': [ 'bearer' ], @@ -451,6 +447,8 @@ def __set_configuration(self, api_client): 'top', 'skip', 'order_by', + 'count', + 'count_only', 'x_correlation_id', 'x_avalara_client', ], @@ -480,6 +478,10 @@ def __set_configuration(self, api_client): (int,), 'order_by': (str,), + 'count': + (bool,), + 'count_only': + (bool,), 'x_correlation_id': (str,), 'x_avalara_client': @@ -491,6 +493,8 @@ def __set_configuration(self, api_client): 'top': '$top', 'skip': '$skip', 'order_by': '$orderBy', + 'count': 'count', + 'count_only': 'countOnly', 'x_correlation_id': 'X-Correlation-Id', 'x_avalara_client': 'X-Avalara-Client', }, @@ -500,6 +504,8 @@ def __set_configuration(self, api_client): 'top': 'query', 'skip': 'query', 'order_by': 'query', + 'count': 'query', + 'count_only': 'query', 'x_correlation_id': 'header', 'x_avalara_client': 'header', }, @@ -519,7 +525,7 @@ def __set_configuration(self, api_client): ) self.update1099_form_endpoint = _Endpoint( settings={ - 'response_type': (Update1099Form200Response,), + 'response_type': (Get1099Form200Response,), 'auth': [ 'bearer' ], @@ -534,7 +540,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'i_update_form1099_request', + 'get1099_form200_response', ], 'required': [ 'id', @@ -561,8 +567,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'i_update_form1099_request': - (IUpdateForm1099Request,), + 'get1099_form200_response': + (Get1099Form200Response,), }, 'attribute_map': { 'id': 'id', @@ -575,7 +581,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'i_update_form1099_request': 'body', + 'get1099_form200_response': 'body', }, 'collection_format_map': { } @@ -604,7 +610,7 @@ def bulk_upsert1099_forms( ): """Create or update multiple 1099/1095/W2/1042S forms # noqa: E501 - This endpoint allows you to create or update multiple 1099/1095/W2/1042S forms. You can use one of the following payload structures: **Form 1099-MISC:** ```json { \"formType\": \"1099-MISC\", \"forms\": [ { \"IssuerId\": \"123456\", \"IssuerReferenceId\": \"REF123\", \"IssuerTin\": \"12-3456789\", \"TaxYear\": 2023, \"ReferenceId\": \"FORM123456\", \"RecipientName\": \"John Doe\", \"RecipientTin\": \"587-65-4321\", \"TinType\": \"SSN\", \"RecipientSecondName\": \"Jane Doe\", \"Address\": \"123 Main Street\", \"Address2\": \"Apt 4B\", \"City\": \"New York\", \"State\": \"NY\", \"Zip\": \"10001\", \"Email\": \"john.doe@email.com\", \"AccountNumber\": \"ACC123456\", \"OfficeCode\": \"NYC01\", \"SecondTinNotice\": false, \"NonUsProvince\": \"\", \"CountryCode\": \"US\", \"Rents\": 12000.00, \"Royalties\": 5000.00, \"OtherIncome\": 3000.00, \"FishingBoatProceeds\": 0.00, \"MedicalAndHealthCarePayments\": 15000.00, \"SubstitutePayments\": 1000.00, \"CropInsuranceProceeds\": 0.00, \"GrossProceedsPaidToAttorney\": 7500.00, \"FishPurchasedForResale\": 0.00, \"FedIncomeTaxWithheld\": 5000.00, \"Section409ADeferrals\": 0.00, \"ExcessGoldenParachutePayments\": 0.00, \"NonqualifiedDeferredCompensation\": 0.00, \"DirectSalesIndicator\": false, \"FatcaFilingRequirement\": false, \"StateAndLocalWithholding\": { \"StateTaxWithheld\": 2500.00, \"LocalTaxWithheld\": 1000.00, \"State\": \"NY\", \"StateIdNumber\": \"NY123456\", \"Locality\": \"New York City\", \"StateIncome\": 35000.00, \"LocalIncome\": 35000.00 } } ] } ``` **Form 1099-NEC:** ```json { \"formType\": \"1099-NEC\", \"forms\": [ { \"issuerID\": \"180337282\", \"issuerReferenceId\": \"ISS123\", \"issuerTin\": \"12-3000000\", \"taxYear\": 2024, \"referenceID\": \"REF-002\", \"recipientName\": \"Jane Smith\", \"recipientSecondName\": \"\", \"recipientTin\": \"587-65-4321\", \"tinType\": \"SSN\", \"address\": \"123 Center St\", \"address2\": \"\", \"city\": \"Santa Monica\", \"state\": \"CA\", \"zip\": \"90401\", \"countryCode\": \"US\", \"nonUsProvince\": \"\", \"email\": \"\", \"accountNumber\": \"\", \"officeCode\": \"\", \"secondTinNotice\": false, \"nonemployeeCompensation\": 123.45, \"directSalesIndicator\": false, \"federalIncomeTaxWithheld\": 12.34, \"stateAndLocalWithholding\": { \"state\": \"CA\", \"stateIdNumber\": \"123123123\", \"stateIncome\": 123.45, \"stateTaxWithheld\": 12.34, \"locality\": \"Santa Monica\", \"localityIdNumber\": \"456456\", \"localTaxWithheld\": 12.34, \"localIncome\": 50000.00 }, \"federalEFile\": true, \"postalMail\": true, \"stateEFile\": true, \"tinMatch\": true, \"addressVerification\": true } ] } ``` For the full version of the payload and its schema details, refer to the Swagger schemas section. # noqa: E501 + This endpoint allows you to create or update multiple 1099/1095/W2/1042S forms. Maximum of 5000 forms can be processed in a single bulk request. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True @@ -615,10 +621,10 @@ def bulk_upsert1099_forms( avalara_version (str): API version Keyword Args: - dry_run (bool): . [optional] if omitted the server will use the default value of False + dry_run (bool): defaults to false. If true, it will NOT change the DB. It will just return a report of what would've have been changed in the DB. [optional] if omitted the server will use the default value of False 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] - bulk_upsert1099_forms_request (BulkUpsert1099FormsRequest): . [optional] + form1099_list_request (Form1099ListRequest): . [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -640,7 +646,7 @@ def bulk_upsert1099_forms( async_req (bool): execute request asynchronously Returns: - Form1099ProccessResult + JobResponse If the method is called asynchronously, returns the request thread. """ @@ -688,7 +694,7 @@ def create1099_form( Keyword Args: 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] - i_create_form1099_request (ICreateForm1099Request): [optional] + get1099_form200_response (Get1099Form200Response): [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -710,7 +716,7 @@ def create1099_form( async_req (bool): execute request asynchronously Returns: - Create1099Form201Response + Get1099Form200Response If the method is called asynchronously, returns the request thread. """ @@ -962,7 +968,7 @@ def list1099_forms( ): """List 1099/1095/W2/1042S forms # noqa: E501 - List 1099/1095/W2/1042S forms. Filterable fields are name, referenceId and taxYear. # noqa: E501 + List 1099/1095/W2/1042S forms. Collections support filtering only on certain fields. An attempt to filter on an unsupported field will receive a 400 Bad Request response. Supported filtering fields are as follows: - issuerId - issuerReferenceId - taxYear - addressVerificationStatus - possible values are: unknown, pending, failed, incomplete, unchanged, verified - createdAt - edeliveryStatus - possible values are: sent, unscheduled, bad_verify, bad_verify_limit, scheduled, bounced, accepted - email - federalEfileStatus - possible values are: unscheduled, scheduled, sent, corrected_scheduled, accepted, corrected, corrected_accepted, held - recipientName - mailStatus - possible values are: sent, unscheduled, pending, delivered - referenceId - tinMatchStatus - possible values are: none, pending, matched, failed - type - possible values are: 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 - updatedAt - validity - possible values are: true, false For more information on filtering, see Filtering in REST. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True @@ -973,10 +979,12 @@ def list1099_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. Collections support filtering only on certain fields. An attempt to filter on an unsupported field will receive a 400 Bad Request response. Supported filtering fields are as follows: issuerId issuerReferenceId taxYear addressVerificationStatus - possible values are: unknown, pending, failed, incomplete, unchanged, verified createdAt edeliveryStatus - possible values are: sent, unscheduled, bad_verify, bad_verify_limit, scheduled, bounced, accepted email federalEfileStatus - possible values are: unscheduled, scheduled, sent, corrected_scheduled, accepted, corrected, corrected_accepted, held recipientName mailStatus - possible values are: sent, unscheduled, pending, delivered referenceId tinMatchStatus - possible values are: none, pending, matched, failed type - possible values are: 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 updatedAt validity - possible values are: true, false. [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 - order_by (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] + 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): 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 @@ -1000,7 +1008,7 @@ def list1099_forms( async_req (bool): execute request asynchronously Returns: - Form1099ListResponse + PaginatedQueryResultModelForm1099Base If the method is called asynchronously, returns the request thread. """ @@ -1050,7 +1058,7 @@ def update1099_form( Keyword Args: 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] - i_update_form1099_request (IUpdateForm1099Request): [optional] + get1099_form200_response (Get1099Form200Response): [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -1072,7 +1080,7 @@ def update1099_form( async_req (bool): execute request asynchronously Returns: - Update1099Form200Response + Get1099Form200Response If the method is called asynchronously, returns the request thread. """ diff --git a/Avalara/SDK/api/A1099/V2/forms_w9_api.py b/Avalara/SDK/api/A1099/V2/forms_w9_api.py index f2ecf66..a80f5a8 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,6 +43,7 @@ from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr from typing import Optional, Union from typing_extensions import Annotated +from Avalara.SDK.models.A1099.V2.create_and_send_w9_form_email_request import CreateAndSendW9FormEmailRequest 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 @@ -61,9 +62,81 @@ 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.2") + api_client.set_sdk_version("25.8.3") self.api_client = api_client + self.create_and_send_w9_form_email_endpoint = _Endpoint( + settings={ + 'response_type': (CreateW9Form201Response,), + 'auth': [ + 'bearer' + ], + 'endpoint_path': '/w9/forms/$create-and-send-email', + 'operation_id': 'create_and_send_w9_form_email', + 'http_method': 'POST', + 'servers': None, + }, + params_map={ + 'all': [ + 'avalara_version', + 'x_correlation_id', + 'x_avalara_client', + 'create_and_send_w9_form_email_request', + ], + 'required': [ + 'avalara_version', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'avalara_version': + (str,), + 'x_correlation_id': + (str,), + 'x_avalara_client': + (str,), + 'create_and_send_w9_form_email_request': + (CreateAndSendW9FormEmailRequest,), + }, + 'attribute_map': { + 'avalara_version': 'avalara-version', + 'x_correlation_id': 'X-Correlation-Id', + 'x_avalara_client': 'X-Avalara-Client', + }, + 'location_map': { + 'avalara_version': 'header', + 'x_correlation_id': 'header', + 'x_avalara_client': 'header', + 'create_and_send_w9_form_email_request': 'body', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'avalara-version': '2.0', + 'accept': [ + 'application/json' + ], + 'content_type': [ + 'application/json', + 'text/json', + 'application/*+json' + ] + }, + api_client=api_client, + required_scopes='', + microservice='A1099' + ) self.create_w9_form_endpoint = _Endpoint( settings={ 'response_type': (CreateW9Form201Response,), @@ -372,7 +445,7 @@ def __set_configuration(self, api_client): ) self.send_w9_form_email_endpoint = _Endpoint( settings={ - 'response_type': (IW9FormDataModelsOneOf,), + 'response_type': (CreateW9Form201Response,), 'auth': [ 'bearer' ], @@ -596,6 +669,76 @@ def __set_configuration(self, api_client): microservice='A1099' ) + @avalara_retry_oauth(max_retry_attempts=2) + def create_and_send_w9_form_email( + self, + avalara_version, + **kwargs + ): + """Create a minimal W9/W4/W8 form and sends the e-mail request # noqa: E501 + + Create a minimal W9/W4/W8 form and sends the e-mail request. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.create_and_send_w9_form_email(avalara_version, async_req=True) + >>> result = thread.get() + + Args: + avalara_version (str): API version + + Keyword Args: + 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] + create_and_send_w9_form_email_request (CreateAndSendW9FormEmailRequest): Form to be created. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + CreateW9Form201Response + If the method is called asynchronously, returns the request + thread. + """ + self.__verify_api_client(self.api_client) + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['avalara_version'] = avalara_version + return self.create_and_send_w9_form_email_endpoint.call_with_http_info(**kwargs) + @avalara_retry_oauth(max_retry_attempts=2) def create_w9_form( self, @@ -894,7 +1037,7 @@ def send_w9_form_email( ): """Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form # noqa: E501 - Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form. # noqa: E501 + Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form. If the form is not in 'Requested' status, it will either use an existing descendant form in 'Requested' status or create a new minimal form and send the email request. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True @@ -929,7 +1072,7 @@ def send_w9_form_email( async_req (bool): execute request asynchronously Returns: - IW9FormDataModelsOneOf + CreateW9Form201Response 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 e4900fa..0cd4390 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,7 +43,7 @@ from pydantic import Field, StrictBool, StrictInt, StrictStr from typing import Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.issuer_command import IssuerCommand +from Avalara.SDK.models.A1099.V2.create_issuer_request import CreateIssuerRequest from Avalara.SDK.models.A1099.V2.issuer_response import IssuerResponse from Avalara.SDK.models.A1099.V2.paginated_query_result_model_issuer_response import PaginatedQueryResultModelIssuerResponse from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException @@ -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.2") + api_client.set_sdk_version("25.8.3") self.api_client = api_client self.create_issuer_endpoint = _Endpoint( @@ -79,7 +79,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'issuer_command', + 'create_issuer_request', ], 'required': [ 'avalara_version', @@ -103,8 +103,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'issuer_command': - (IssuerCommand,), + 'create_issuer_request': + (CreateIssuerRequest,), }, 'attribute_map': { 'avalara_version': 'avalara-version', @@ -115,7 +115,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'issuer_command': 'body', + 'create_issuer_request': 'body', }, 'collection_format_map': { } @@ -386,7 +386,7 @@ def __set_configuration(self, api_client): 'avalara_version', 'x_correlation_id', 'x_avalara_client', - 'issuer_command', + 'create_issuer_request', ], 'required': [ 'id', @@ -413,8 +413,8 @@ def __set_configuration(self, api_client): (str,), 'x_avalara_client': (str,), - 'issuer_command': - (IssuerCommand,), + 'create_issuer_request': + (CreateIssuerRequest,), }, 'attribute_map': { 'id': 'id', @@ -427,7 +427,7 @@ def __set_configuration(self, api_client): 'avalara_version': 'header', 'x_correlation_id': 'header', 'x_avalara_client': 'header', - 'issuer_command': 'body', + 'create_issuer_request': 'body', }, 'collection_format_map': { } @@ -469,7 +469,7 @@ def create_issuer( Keyword Args: 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] - issuer_command (IssuerCommand): The issuer to create. [optional] + create_issuer_request (CreateIssuerRequest): The issuer to create. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object @@ -760,7 +760,7 @@ def update_issuer( Keyword Args: 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] - issuer_command (IssuerCommand): The issuer to update. [optional] + create_issuer_request (CreateIssuerRequest): The issuer to update. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. _preload_content (bool): if False, the urllib3.HTTPResponse object diff --git a/Avalara/SDK/api/A1099/V2/jobs1099_api.py b/Avalara/SDK/api/A1099/V2/jobs1099_api.py index 53384db..7d6ec9f 100644 --- a/Avalara/SDK/api/A1099/V2/jobs1099_api.py +++ b/Avalara/SDK/api/A1099/V2/jobs1099_api.py @@ -43,7 +43,7 @@ from pydantic import Field, StrictStr from typing import Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.job_result import JobResult +from Avalara.SDK.models.A1099.V2.A1099.V2.job_result import JobResult from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth diff --git a/Avalara/SDK/api/A1099/V2/jobs_api.py b/Avalara/SDK/api/A1099/V2/jobs_api.py new file mode 100644 index 0000000..79a135a --- /dev/null +++ b/Avalara/SDK/api/A1099/V2/jobs_api.py @@ -0,0 +1,206 @@ +""" +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.3 +@link https://github.com/avadev/AvaTax-REST-V3-Python-SDK +""" + +import re # noqa: F401 +import sys # noqa: F401 +import decimal + +from Avalara.SDK.api_client import ApiClient, Endpoint as _Endpoint +from Avalara.SDK.model_utils import ( # noqa: F401 + check_allowed_values, + check_validations, + date, + datetime, + file_type, + none_type, + validate_and_convert_types +) +from pydantic import Field, StrictStr +from typing import Optional +from typing_extensions import Annotated +from Avalara.SDK.models.A1099.V2.job_response import JobResponse +from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException +from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth + +class JobsApi(object): + + def __init__(self, api_client): + self.__set_configuration(api_client) + + def __verify_api_client(self,api_client): + if api_client is None: + raise ApiValueError("APIClient not defined") + + def __set_configuration(self, api_client): + self.__verify_api_client(api_client) + api_client.set_sdk_version("25.8.3") + self.api_client = api_client + + self.get_job_endpoint = _Endpoint( + settings={ + 'response_type': (JobResponse,), + 'auth': [ + 'bearer' + ], + 'endpoint_path': '/jobs/{id}', + 'operation_id': 'get_job', + 'http_method': 'GET', + 'servers': None, + }, + params_map={ + 'all': [ + 'id', + 'avalara_version', + 'x_correlation_id', + 'x_avalara_client', + ], + 'required': [ + 'id', + 'avalara_version', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'id': + (str,), + 'avalara_version': + (str,), + 'x_correlation_id': + (str,), + 'x_avalara_client': + (str,), + }, + 'attribute_map': { + 'id': 'id', + 'avalara_version': 'avalara-version', + 'x_correlation_id': 'X-Correlation-Id', + 'x_avalara_client': 'X-Avalara-Client', + }, + 'location_map': { + 'id': 'path', + 'avalara_version': 'header', + 'x_correlation_id': 'header', + 'x_avalara_client': 'header', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'avalara-version': '2.0', + 'accept': [ + 'application/json' + ], + 'content_type': [], + }, + api_client=api_client, + required_scopes='', + microservice='A1099' + ) + + @avalara_retry_oauth(max_retry_attempts=2) + def get_job( + self, + id, + avalara_version, + **kwargs + ): + """Retrieves information about the job # noqa: E501 + + Retrieves information about the job # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.get_job(id, avalara_version, async_req=True) + >>> result = thread.get() + + Args: + id (str): Job id obtained from other API responses, like `/1099/bulk-upsert`. + avalara_version (str): API version + + Keyword Args: + 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 + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobResponse + If the method is called asynchronously, returns the request + thread. + """ + self.__verify_api_client(self.api_client) + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['id'] = id + kwargs['avalara_version'] = avalara_version + return self.get_job_endpoint.call_with_http_info(**kwargs) + 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 34eeed1..042e743 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 04a2bc7..c0e9dce 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 a59e6ba..c7a3b68 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 4bcd86e..f72dfe4 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 e6030f8..dcf95ed 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 71554c0..1e397be 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") 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 599694d..9e5815b 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.2 +@version 25.8.3 @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.2") + api_client.set_sdk_version("25.8.3") self.api_client = api_client self.batch_search_participants_endpoint = _Endpoint( 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 22b9fc5..98e4653 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.2 +@version 25.8.3 @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 7493274..eea1821 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.2 +@version 25.8.3 @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 bc83e3b..920fec0 100644 --- a/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py +++ b/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py @@ -33,15 +33,15 @@ 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_list import Form1042SList -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 -from Avalara.SDK.models.A1099.V2.form1099_r_list import Form1099RList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list import Form1042SList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list import Form1095BList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_c_list import Form1095CList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list import Form1099DivList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list import Form1099IntList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list import Form1099KList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list import Form1099MiscList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list import Form1099NecList +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list import Form1099RList 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/company_create_update_request_model.py b/Avalara/SDK/models/A1099/V2/company_create_update_request_model.py index 41c22c8..b4d4a80 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -42,24 +42,24 @@ class CompanyCreateUpdateRequestModel(BaseModel): """ CompanyCreateUpdateRequestModel """ # noqa: E501 - name: Optional[StrictStr] = None - email: Optional[StrictStr] = None - address: Optional[StrictStr] = None - city: Optional[StrictStr] = None - state: Optional[StrictStr] = None - zip: Optional[StrictStr] = None - telephone: Optional[StrictStr] = None - tin: Optional[StrictStr] = None - dba_name: Optional[StrictStr] = Field(default=None, alias="dbaName") - reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") - do_tin_match: Optional[StrictBool] = Field(default=None, alias="doTinMatch") - group_name: Optional[StrictStr] = Field(default=None, alias="groupName") - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") - country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") - resend_requests: Optional[StrictBool] = Field(default=None, alias="resendRequests") - resend_interval_days: Optional[StrictInt] = Field(default=None, alias="resendIntervalDays") - max_reminder_attempts: Optional[StrictInt] = Field(default=None, alias="maxReminderAttempts") - __properties: ClassVar[List[str]] = ["name", "email", "address", "city", "state", "zip", "telephone", "tin", "dbaName", "referenceId", "doTinMatch", "groupName", "foreignProvince", "countryCode", "resendRequests", "resendIntervalDays", "maxReminderAttempts"] + name: Optional[StrictStr] = Field(description="Legal name. Not the DBA name.") + dba_name: Optional[StrictStr] = Field(default=None, description="Doing Business As (DBA) name or continuation of a long legal name.", alias="dbaName") + email: Optional[StrictStr] = Field(description="Contact email address. For inquiries by vendors/employees.") + address: Optional[StrictStr] = Field(description="Address.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(description="ZIP/postal code.") + telephone: Optional[StrictStr] = Field(description="Contact phone number (must contain at least 10 digits, max 15 characters).") + tin: Optional[StrictStr] = Field(description="Federal Tax Identification Number (TIN). EIN/Tax ID (required for US companies).") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + do_tin_match: Optional[StrictBool] = Field(default=None, description="Indicates whether the company authorizes IRS TIN matching.", alias="doTinMatch") + group_name: Optional[StrictStr] = Field(default=None, description="Group name for organizing companies (creates or finds group by name).", alias="groupName") + foreign_province: Optional[StrictStr] = Field(default=None, description="Province or region for non-US/CA addresses.", alias="foreignProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + resend_requests: Optional[StrictBool] = Field(default=None, description="Boolean to enable automatic reminder emails (default: false).", alias="resendRequests") + resend_interval_days: Optional[StrictInt] = Field(default=None, description="Days between reminder emails (7-365, required if resendRequests is true).", alias="resendIntervalDays") + max_reminder_attempts: Optional[StrictInt] = Field(default=None, description="Maximum number of reminder attempts (1-52, required if resendRequests is true).", alias="maxReminderAttempts") + __properties: ClassVar[List[str]] = ["name", "dbaName", "email", "address", "city", "state", "zip", "telephone", "tin", "referenceId", "doTinMatch", "groupName", "foreignProvince", "countryCode", "resendRequests", "resendIntervalDays", "maxReminderAttempts"] model_config = ConfigDict( populate_by_name=True, @@ -100,6 +100,81 @@ 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 dba_name (nullable) is None + # and model_fields_set contains the field + if self.dba_name is None and "dba_name" in self.model_fields_set: + _dict['dbaName'] = 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 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 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 telephone (nullable) is None + # and model_fields_set contains the field + if self.telephone is None and "telephone" in self.model_fields_set: + _dict['telephone'] = 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 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 do_tin_match (nullable) is None + # and model_fields_set contains the field + if self.do_tin_match is None and "do_tin_match" in self.model_fields_set: + _dict['doTinMatch'] = None + + # set to None if group_name (nullable) is None + # and model_fields_set contains the field + if self.group_name is None and "group_name" in self.model_fields_set: + _dict['groupName'] = None + + # set to None if foreign_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 + + # 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 resend_requests (nullable) is None + # and model_fields_set contains the field + if self.resend_requests is None and "resend_requests" in self.model_fields_set: + _dict['resendRequests'] = None + # set to None if resend_interval_days (nullable) is None # and model_fields_set contains the field if self.resend_interval_days is None and "resend_interval_days" in self.model_fields_set: @@ -123,6 +198,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "name": obj.get("name"), + "dbaName": obj.get("dbaName"), "email": obj.get("email"), "address": obj.get("address"), "city": obj.get("city"), @@ -130,7 +206,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "zip": obj.get("zip"), "telephone": obj.get("telephone"), "tin": obj.get("tin"), - "dbaName": obj.get("dbaName"), "referenceId": obj.get("referenceId"), "doTinMatch": obj.get("doTinMatch"), "groupName": obj.get("groupName"), diff --git a/Avalara/SDK/models/A1099/V2/company_response.py b/Avalara/SDK/models/A1099/V2/company_response.py index 4cc53f0..95a67d8 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,27 +43,27 @@ class CompanyResponse(BaseModel): """ CompanyResponse """ # noqa: E501 - id: Optional[StrictStr] = None - reference_id: Optional[StrictStr] = Field(default=None, alias="referenceId") - group_name: Optional[StrictStr] = Field(default=None, alias="groupName") - name: Optional[StrictStr] = None - dba_name: Optional[StrictStr] = Field(default=None, alias="dbaName") - address: Optional[StrictStr] = None - city: Optional[StrictStr] = None - state: Optional[StrictStr] = None - foreign_province: Optional[StrictStr] = Field(default=None, alias="foreignProvince") - zip: Optional[StrictStr] = None - country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") - email: Optional[StrictStr] = None - telephone: Optional[StrictStr] = None - tin: Optional[StrictStr] = None - do_tin_match: Optional[StrictBool] = Field(default=None, alias="doTinMatch") - resend_requests: Optional[StrictBool] = Field(default=None, alias="resendRequests") - resend_interval_days: Optional[StrictInt] = Field(default=None, alias="resendIntervalDays") - max_reminder_attempts: Optional[StrictInt] = Field(default=None, alias="maxReminderAttempts") - created_at: Optional[datetime] = Field(default=None, alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, alias="updatedAt") - __properties: ClassVar[List[str]] = [] + id: Optional[StrictStr] = Field(default=None, description="Unique identifier set when the record is created.") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + name: Optional[StrictStr] = Field(description="Legal name. Not the DBA name.") + dba_name: Optional[StrictStr] = Field(default=None, description="Doing Business As (DBA) name or continuation of a long legal name.", alias="dbaName") + email: Optional[StrictStr] = Field(description="Contact email address. For inquiries by vendors/employees.") + address: Optional[StrictStr] = Field(description="Address.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(description="ZIP/postal code.") + telephone: Optional[StrictStr] = Field(description="Contact phone number (must contain at least 10 digits, max 15 characters).") + tin: Optional[StrictStr] = Field(description="Federal Tax Identification Number (TIN). EIN/Tax ID (required for US companies).") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + do_tin_match: Optional[StrictBool] = Field(default=None, description="Indicates whether the company authorizes IRS TIN matching.", alias="doTinMatch") + group_name: Optional[StrictStr] = Field(default=None, description="Group name for organizing companies (creates or finds group by name).", alias="groupName") + foreign_province: Optional[StrictStr] = Field(default=None, description="Province or region for non-US/CA addresses.", alias="foreignProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + resend_requests: Optional[StrictBool] = Field(default=None, description="Boolean to enable automatic reminder emails (default: false).", alias="resendRequests") + resend_interval_days: Optional[StrictInt] = Field(default=None, description="Days between reminder emails (7-365, required if resendRequests is true).", alias="resendIntervalDays") + max_reminder_attempts: Optional[StrictInt] = Field(default=None, description="Maximum number of reminder attempts (1-52, required if resendRequests is true).", alias="maxReminderAttempts") + __properties: ClassVar[List[str]] = ["name", "dbaName", "email", "address", "city", "state", "zip", "telephone", "tin", "referenceId", "doTinMatch", "groupName", "foreignProvince", "countryCode", "resendRequests", "resendIntervalDays", "maxReminderAttempts"] model_config = ConfigDict( populate_by_name=True, @@ -104,6 +104,91 @@ 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 dba_name (nullable) is None + # and model_fields_set contains the field + if self.dba_name is None and "dba_name" in self.model_fields_set: + _dict['dbaName'] = 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 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 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 telephone (nullable) is None + # and model_fields_set contains the field + if self.telephone is None and "telephone" in self.model_fields_set: + _dict['telephone'] = 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 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 do_tin_match (nullable) is None + # and model_fields_set contains the field + if self.do_tin_match is None and "do_tin_match" in self.model_fields_set: + _dict['doTinMatch'] = None + + # set to None if group_name (nullable) is None + # and model_fields_set contains the field + if self.group_name is None and "group_name" in self.model_fields_set: + _dict['groupName'] = None + + # set to None if foreign_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 + + # 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 resend_requests (nullable) is None + # and model_fields_set contains the field + if self.resend_requests is None and "resend_requests" in self.model_fields_set: + _dict['resendRequests'] = None + + # set to None if resend_interval_days (nullable) is None + # and model_fields_set contains the field + if self.resend_interval_days is None and "resend_interval_days" in self.model_fields_set: + _dict['resendIntervalDays'] = None + + # set to None if max_reminder_attempts (nullable) is None + # and model_fields_set contains the field + if self.max_reminder_attempts is None and "max_reminder_attempts" in self.model_fields_set: + _dict['maxReminderAttempts'] = None + return _dict @classmethod @@ -116,6 +201,23 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "name": obj.get("name"), + "dbaName": obj.get("dbaName"), + "email": obj.get("email"), + "address": obj.get("address"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "telephone": obj.get("telephone"), + "tin": obj.get("tin"), + "referenceId": obj.get("referenceId"), + "doTinMatch": obj.get("doTinMatch"), + "groupName": obj.get("groupName"), + "foreignProvince": obj.get("foreignProvince"), + "countryCode": obj.get("countryCode"), + "resendRequests": obj.get("resendRequests"), + "resendIntervalDays": obj.get("resendIntervalDays"), + "maxReminderAttempts": obj.get("maxReminderAttempts") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/covered_individual.py b/Avalara/SDK/models/A1099/V2/covered_individual.py new file mode 100644 index 0000000..d5bfe33 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/covered_individual.py @@ -0,0 +1,244 @@ +# 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.3 +@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 date +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self + +class CoveredIndividual(BaseModel): + """ + Covered individual information for health coverage forms + """ # noqa: E501 + id: Optional[StrictStr] = Field(default=None, description="Covered individual's ID") + first_name: Optional[StrictStr] = Field(description="Covered individual's first name", alias="firstName") + middle_name: Optional[StrictStr] = Field(default=None, description="Covered individual's middle name", alias="middleName") + last_name: Optional[StrictStr] = Field(description="Covered individual's last name", alias="lastName") + name_suffix: Optional[StrictStr] = Field(default=None, description="Covered individual's name suffix", alias="nameSuffix") + tin: Optional[StrictStr] = Field(default=None, description="Covered individual's Federal Tax Identification Number (TIN).. SSN or ITIN. Required unless unavailable.") + birth_date: Optional[date] = Field(default=None, description="Covered individual's date of birth - Required when SSN is missing.", alias="birthDate") + covered_all_months: Optional[StrictBool] = Field(default=None, description="Coverage indicator for all 12 months", alias="coveredAllMonths") + covered_january: Optional[StrictBool] = Field(default=None, description="Coverage indicator for January", alias="coveredJanuary") + covered_february: Optional[StrictBool] = Field(default=None, description="Coverage indicator for February", alias="coveredFebruary") + covered_march: Optional[StrictBool] = Field(default=None, description="Coverage indicator for March", alias="coveredMarch") + covered_april: Optional[StrictBool] = Field(default=None, description="Coverage indicator for April", alias="coveredApril") + covered_may: Optional[StrictBool] = Field(default=None, description="Coverage indicator for May", alias="coveredMay") + covered_june: Optional[StrictBool] = Field(default=None, description="Coverage indicator for June", alias="coveredJune") + covered_july: Optional[StrictBool] = Field(default=None, description="Coverage indicator for July", alias="coveredJuly") + covered_august: Optional[StrictBool] = Field(default=None, description="Coverage indicator for August", alias="coveredAugust") + covered_september: Optional[StrictBool] = Field(default=None, description="Coverage indicator for September", alias="coveredSeptember") + covered_october: Optional[StrictBool] = Field(default=None, description="Coverage indicator for October", alias="coveredOctober") + covered_november: Optional[StrictBool] = Field(default=None, description="Coverage indicator for November", alias="coveredNovember") + covered_december: Optional[StrictBool] = Field(default=None, description="Coverage indicator for December", alias="coveredDecember") + __properties: ClassVar[List[str]] = ["id", "firstName", "middleName", "lastName", "nameSuffix", "tin", "birthDate", "coveredAllMonths", "coveredJanuary", "coveredFebruary", "coveredMarch", "coveredApril", "coveredMay", "coveredJune", "coveredJuly", "coveredAugust", "coveredSeptember", "coveredOctober", "coveredNovember", "coveredDecember"] + + 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 CoveredIndividual 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([ + "id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = None + + # set to None if first_name (nullable) is None + # and model_fields_set contains the field + if self.first_name is None and "first_name" in self.model_fields_set: + _dict['firstName'] = None + + # set to None if middle_name (nullable) is None + # and model_fields_set contains the field + if self.middle_name is None and "middle_name" in self.model_fields_set: + _dict['middleName'] = None + + # set to None if last_name (nullable) is None + # and model_fields_set contains the field + if self.last_name is None and "last_name" in self.model_fields_set: + _dict['lastName'] = None + + # set to None if name_suffix (nullable) is None + # and model_fields_set contains the field + if self.name_suffix is None and "name_suffix" in self.model_fields_set: + _dict['nameSuffix'] = 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 birth_date (nullable) is None + # and model_fields_set contains the field + if self.birth_date is None and "birth_date" in self.model_fields_set: + _dict['birthDate'] = None + + # set to None if covered_all_months (nullable) is None + # and model_fields_set contains the field + if self.covered_all_months is None and "covered_all_months" in self.model_fields_set: + _dict['coveredAllMonths'] = None + + # set to None if covered_january (nullable) is None + # and model_fields_set contains the field + if self.covered_january is None and "covered_january" in self.model_fields_set: + _dict['coveredJanuary'] = None + + # set to None if covered_february (nullable) is None + # and model_fields_set contains the field + if self.covered_february is None and "covered_february" in self.model_fields_set: + _dict['coveredFebruary'] = None + + # set to None if covered_march (nullable) is None + # and model_fields_set contains the field + if self.covered_march is None and "covered_march" in self.model_fields_set: + _dict['coveredMarch'] = None + + # set to None if covered_april (nullable) is None + # and model_fields_set contains the field + if self.covered_april is None and "covered_april" in self.model_fields_set: + _dict['coveredApril'] = None + + # set to None if covered_may (nullable) is None + # and model_fields_set contains the field + if self.covered_may is None and "covered_may" in self.model_fields_set: + _dict['coveredMay'] = None + + # set to None if covered_june (nullable) is None + # and model_fields_set contains the field + if self.covered_june is None and "covered_june" in self.model_fields_set: + _dict['coveredJune'] = None + + # set to None if covered_july (nullable) is None + # and model_fields_set contains the field + if self.covered_july is None and "covered_july" in self.model_fields_set: + _dict['coveredJuly'] = None + + # set to None if covered_august (nullable) is None + # and model_fields_set contains the field + if self.covered_august is None and "covered_august" in self.model_fields_set: + _dict['coveredAugust'] = None + + # set to None if covered_september (nullable) is None + # and model_fields_set contains the field + if self.covered_september is None and "covered_september" in self.model_fields_set: + _dict['coveredSeptember'] = None + + # set to None if covered_october (nullable) is None + # and model_fields_set contains the field + if self.covered_october is None and "covered_october" in self.model_fields_set: + _dict['coveredOctober'] = None + + # set to None if covered_november (nullable) is None + # and model_fields_set contains the field + if self.covered_november is None and "covered_november" in self.model_fields_set: + _dict['coveredNovember'] = None + + # set to None if covered_december (nullable) is None + # and model_fields_set contains the field + if self.covered_december is None and "covered_december" in self.model_fields_set: + _dict['coveredDecember'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CoveredIndividual 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"), + "firstName": obj.get("firstName"), + "middleName": obj.get("middleName"), + "lastName": obj.get("lastName"), + "nameSuffix": obj.get("nameSuffix"), + "tin": obj.get("tin"), + "birthDate": obj.get("birthDate"), + "coveredAllMonths": obj.get("coveredAllMonths"), + "coveredJanuary": obj.get("coveredJanuary"), + "coveredFebruary": obj.get("coveredFebruary"), + "coveredMarch": obj.get("coveredMarch"), + "coveredApril": obj.get("coveredApril"), + "coveredMay": obj.get("coveredMay"), + "coveredJune": obj.get("coveredJune"), + "coveredJuly": obj.get("coveredJuly"), + "coveredAugust": obj.get("coveredAugust"), + "coveredSeptember": obj.get("coveredSeptember"), + "coveredOctober": obj.get("coveredOctober"), + "coveredNovember": obj.get("coveredNovember"), + "coveredDecember": obj.get("coveredDecember") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/create1099_form201_response.py b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py index 1a840b8..b07b2a2 100644 --- a/Avalara/SDK/models/A1099/V2/create1099_form201_response.py +++ b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py @@ -33,15 +33,15 @@ 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_list_item_response import Form1042SListItemResponse -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 -from Avalara.SDK.models.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse 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/create_and_send_w9_form_email_request.py b/Avalara/SDK/models/A1099/V2/create_and_send_w9_form_email_request.py new file mode 100644 index 0000000..f4caa6d --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/create_and_send_w9_form_email_request.py @@ -0,0 +1,195 @@ +# 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.3 +@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.w4_form_minimal_request import W4FormMinimalRequest +from Avalara.SDK.models.A1099.V2.w8_ben_e_form_minimal_request import W8BenEFormMinimalRequest +from Avalara.SDK.models.A1099.V2.w8_ben_form_minimal_request import W8BenFormMinimalRequest +from Avalara.SDK.models.A1099.V2.w8_imy_form_minimal_request import W8ImyFormMinimalRequest +from Avalara.SDK.models.A1099.V2.w9_form_minimal_request import W9FormMinimalRequest +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +CREATEANDSENDW9FORMEMAILREQUEST_ONE_OF_SCHEMAS = ["W4FormMinimalRequest", "W8BenEFormMinimalRequest", "W8BenFormMinimalRequest", "W8ImyFormMinimalRequest", "W9FormMinimalRequest"] + +class CreateAndSendW9FormEmailRequest(BaseModel): + """ + CreateAndSendW9FormEmailRequest + """ + # data type: W4FormMinimalRequest + oneof_schema_1_validator: Optional[W4FormMinimalRequest] = None + # data type: W8BenEFormMinimalRequest + oneof_schema_2_validator: Optional[W8BenEFormMinimalRequest] = None + # data type: W8BenFormMinimalRequest + oneof_schema_3_validator: Optional[W8BenFormMinimalRequest] = None + # data type: W8ImyFormMinimalRequest + oneof_schema_4_validator: Optional[W8ImyFormMinimalRequest] = None + # data type: W9FormMinimalRequest + oneof_schema_5_validator: Optional[W9FormMinimalRequest] = None + actual_instance: Optional[Union[W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest]] = None + one_of_schemas: Set[str] = { "W4FormMinimalRequest", "W8BenEFormMinimalRequest", "W8BenFormMinimalRequest", "W8ImyFormMinimalRequest", "W9FormMinimalRequest" } + + 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 = CreateAndSendW9FormEmailRequest.model_construct() + error_messages = [] + match = 0 + # validate data type: W4FormMinimalRequest + if not isinstance(v, W4FormMinimalRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `W4FormMinimalRequest`") + else: + match += 1 + # validate data type: W8BenEFormMinimalRequest + if not isinstance(v, W8BenEFormMinimalRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `W8BenEFormMinimalRequest`") + else: + match += 1 + # validate data type: W8BenFormMinimalRequest + if not isinstance(v, W8BenFormMinimalRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `W8BenFormMinimalRequest`") + else: + match += 1 + # validate data type: W8ImyFormMinimalRequest + if not isinstance(v, W8ImyFormMinimalRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `W8ImyFormMinimalRequest`") + else: + match += 1 + # validate data type: W9FormMinimalRequest + if not isinstance(v, W9FormMinimalRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `W9FormMinimalRequest`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in CreateAndSendW9FormEmailRequest with oneOf schemas: W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in CreateAndSendW9FormEmailRequest with oneOf schemas: W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest. 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 W4FormMinimalRequest + try: + instance.actual_instance = W4FormMinimalRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into W8BenEFormMinimalRequest + try: + instance.actual_instance = W8BenEFormMinimalRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into W8BenFormMinimalRequest + try: + instance.actual_instance = W8BenFormMinimalRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into W8ImyFormMinimalRequest + try: + instance.actual_instance = W8ImyFormMinimalRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into W9FormMinimalRequest + try: + instance.actual_instance = W9FormMinimalRequest.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 CreateAndSendW9FormEmailRequest with oneOf schemas: W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into CreateAndSendW9FormEmailRequest with oneOf schemas: W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest. 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], W4FormMinimalRequest, W8BenEFormMinimalRequest, W8BenFormMinimalRequest, W8ImyFormMinimalRequest, W9FormMinimalRequest]]: + """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/create_company_request.py b/Avalara/SDK/models/A1099/V2/create_company_request.py new file mode 100644 index 0000000..acbb8f2 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/create_company_request.py @@ -0,0 +1,153 @@ +# 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.3 +@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.company_create_update_request_model import CompanyCreateUpdateRequestModel +from Avalara.SDK.models.A1099.V2.company_response import CompanyResponse +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +CREATECOMPANYREQUEST_ONE_OF_SCHEMAS = ["CompanyCreateUpdateRequestModel", "CompanyResponse"] + +class CreateCompanyRequest(BaseModel): + """ + CreateCompanyRequest + """ + # data type: CompanyCreateUpdateRequestModel + oneof_schema_1_validator: Optional[CompanyCreateUpdateRequestModel] = None + # data type: CompanyResponse + oneof_schema_2_validator: Optional[CompanyResponse] = None + actual_instance: Optional[Union[CompanyCreateUpdateRequestModel, CompanyResponse]] = None + one_of_schemas: Set[str] = { "CompanyCreateUpdateRequestModel", "CompanyResponse" } + + 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 = CreateCompanyRequest.model_construct() + error_messages = [] + match = 0 + # validate data type: CompanyCreateUpdateRequestModel + if not isinstance(v, CompanyCreateUpdateRequestModel): + error_messages.append(f"Error! Input type `{type(v)}` is not `CompanyCreateUpdateRequestModel`") + else: + match += 1 + # validate data type: CompanyResponse + if not isinstance(v, CompanyResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `CompanyResponse`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in CreateCompanyRequest with oneOf schemas: CompanyCreateUpdateRequestModel, CompanyResponse. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in CreateCompanyRequest with oneOf schemas: CompanyCreateUpdateRequestModel, CompanyResponse. 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 CompanyCreateUpdateRequestModel + try: + instance.actual_instance = CompanyCreateUpdateRequestModel.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into CompanyResponse + try: + instance.actual_instance = CompanyResponse.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 CreateCompanyRequest with oneOf schemas: CompanyCreateUpdateRequestModel, CompanyResponse. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into CreateCompanyRequest with oneOf schemas: CompanyCreateUpdateRequestModel, CompanyResponse. 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], CompanyCreateUpdateRequestModel, CompanyResponse]]: + """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/create_issuer_request.py b/Avalara/SDK/models/A1099/V2/create_issuer_request.py new file mode 100644 index 0000000..390901d --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/create_issuer_request.py @@ -0,0 +1,153 @@ +# 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.3 +@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.issuer_command import IssuerCommand +from Avalara.SDK.models.A1099.V2.issuer_response import IssuerResponse +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +CREATEISSUERREQUEST_ONE_OF_SCHEMAS = ["IssuerCommand", "IssuerResponse"] + +class CreateIssuerRequest(BaseModel): + """ + CreateIssuerRequest + """ + # data type: IssuerCommand + oneof_schema_1_validator: Optional[IssuerCommand] = None + # data type: IssuerResponse + oneof_schema_2_validator: Optional[IssuerResponse] = None + actual_instance: Optional[Union[IssuerCommand, IssuerResponse]] = None + one_of_schemas: Set[str] = { "IssuerCommand", "IssuerResponse" } + + 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 = CreateIssuerRequest.model_construct() + error_messages = [] + match = 0 + # validate data type: IssuerCommand + if not isinstance(v, IssuerCommand): + error_messages.append(f"Error! Input type `{type(v)}` is not `IssuerCommand`") + else: + match += 1 + # validate data type: IssuerResponse + if not isinstance(v, IssuerResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `IssuerResponse`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in CreateIssuerRequest with oneOf schemas: IssuerCommand, IssuerResponse. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in CreateIssuerRequest with oneOf schemas: IssuerCommand, IssuerResponse. 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 IssuerCommand + try: + instance.actual_instance = IssuerCommand.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into IssuerResponse + try: + instance.actual_instance = IssuerResponse.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 CreateIssuerRequest with oneOf schemas: IssuerCommand, IssuerResponse. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into CreateIssuerRequest with oneOf schemas: IssuerCommand, IssuerResponse. 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], IssuerCommand, IssuerResponse]]: + """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/create_w9_form201_response.py b/Avalara/SDK/models/A1099/V2/create_w9_form201_response.py index 2196ed6..8c7c606 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ 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 ddd7d47..0d83142 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.2 +@version 25.8.3 @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 477c787..4970503 100644 --- a/Avalara/SDK/models/A1099/V2/data.py +++ b/Avalara/SDK/models/A1099/V2/data.py @@ -35,8 +35,8 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.attribute import Attribute -from Avalara.SDK.models.A1099.V2.link import Link +from Avalara.SDK.models.A1099.V2.A1099.V2.attribute import Attribute +from Avalara.SDK.models.A1099.V2.A1099.V2.link import Link from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/entry_status_response.py b/Avalara/SDK/models/A1099/V2/entry_status_response.py new file mode 100644 index 0000000..466cfc6 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/entry_status_response.py @@ -0,0 +1,111 @@ +# 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.3 +@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, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self + +class EntryStatusResponse(BaseModel): + """ + Represents the entry status information for a W9 form. + """ # noqa: E501 + status: Optional[StrictStr] = Field(default=None, description="The form status.") + time: Optional[datetime] = Field(default=None, description="The timestamp for the latest status update.") + __properties: ClassVar[List[str]] = ["status", "time"] + + 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 EntryStatusResponse 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 time (nullable) is None + # and model_fields_set contains the field + if self.time is None and "time" in self.model_fields_set: + _dict['time'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EntryStatusResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "status": obj.get("status"), + "time": obj.get("time") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/error_model.py b/Avalara/SDK/models/A1099/V2/error_model.py index 8feb43f..2fcaa93 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.2 +@version 25.8.3 @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 f6ef04a..aea6c25 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ 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 36445af..7df3696 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.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails -from Avalara.SDK.models.A1099.V2.A1099.V2.problem_details import ProblemDetails +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails +from Avalara.SDK.models.A1099.V2.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 index ac3af6e..3e56474 100644 --- a/Avalara/SDK/models/A1099/V2/error_response_item.py +++ b/Avalara/SDK/models/A1099/V2/error_response_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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/form1042_s.py b/Avalara/SDK/models/A1099/V2/form1042_s.py index a4ab92c..112a2ce 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough @@ -47,71 +47,168 @@ class Form1042S(BaseModel): """ - Form1042S + Form 1042-S: Foreign Person's U.S. Source Income Subject to Withholding """ # 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"] + unique_form_id: Optional[StrictStr] = Field(description="Unique form identifier", alias="uniqueFormId") + recipient_date_of_birth: Optional[date] = Field(default=None, description="Recipient's date of birth", alias="recipientDateOfBirth") + recipient_giin: Optional[StrictStr] = Field(default=None, description="Recipient's Global Intermediary Identification Number (GIIN). A valid GIIN looks like 'XXXXXX.XXXXX.XX.XXX'.", alias="recipientGiin") + recipient_foreign_tin: Optional[StrictStr] = Field(default=None, description="Recipient's foreign TIN. Required if email is specified, must fill either this or Chap3StatusCode.", alias="recipientForeignTin") + lob_code: Optional[StrictStr] = Field(default=None, description="Limitation on Benefits (LOB) code for tax treaty purposes. Available values: - 01: Individual (Deprecated - valid only for tax years prior to 2019) - 02: Government - contracting state/political subdivision/local authority - 03: Tax exempt pension trust/Pension fund - 04: Tax exempt/Charitable organization - 05: Publicly-traded corporation - 06: Subsidiary of publicly-traded corporation - 07: Company that meets the ownership and base erosion test - 08: Company that meets the derivative benefits test - 09: Company with an item of income that meets the active trade or business test - 10: Discretionary determination - 11: Other - 12: No LOB article in treaty", alias="lobCode") + income_code: Optional[StrictStr] = Field(description="Income code. Available values: Interest: - 01: Interest paid by US obligors - general - 02: Interest paid on real property mortgages - 03: Interest paid to controlling foreign corporations - 04: Interest paid by foreign corporations - 05: Interest on tax-free covenant bonds - 22: Interest paid on deposit with a foreign branch of a domestic corporation or partnership - 29: Deposit interest - 30: Original issue discount (OID) - 31: Short-term OID - 33: Substitute payment - interest - 51: Interest paid on certain actively traded or publicly offered securities(1) - 54: Substitute payments - interest from certain actively traded or publicly offered securities(1) Dividend: - 06: Dividends paid by U.S. corporations - general - 07: Dividends qualifying for direct dividend rate - 08: Dividends paid by foreign corporations - 34: Substitute payment - dividends - 40: Other dividend equivalents under IRC section 871(m) (formerly 871(l)) - 52: Dividends paid on certain actively traded or publicly offered securities(1) - 53: Substitute payments - dividends from certain actively traded or publicly offered securities(1) - 56: Dividend equivalents under IRC section 871(m) as a result of applying the combined transaction rules Other: - 09: Capital gains - 10: Industrial royalties - 11: Motion picture or television copyright royalties - 12: Other royalties (for example, copyright, software, broadcasting, endorsement payments) - 13: Royalties paid on certain publicly offered securities(1) - 14: Real property income and natural resources royalties - 15: Pensions, annuities, alimony, and/or insurance premiums - 16: Scholarship or fellowship grants - 17: Compensation for independent personal services(2) - 18: Compensation for dependent personal services(2) - 19: Compensation for teaching(2) - 20: Compensation during studying and training(2) - 23: Other income - 24: Qualified investment entity (QIE) distributions of capital gains - 25: Trust distributions subject to IRC section 1445 - 26: Unsevered growing crops and timber distributions by a trust subject to IRC section 1445 - 27: Publicly traded partnership distributions subject to IRC section 1446 - 28: Gambling winnings(3) - 32: Notional principal contract income(4) - 35: Substitute payment - other - 36: Capital gains distributions - 37: Return of capital - 38: Eligible deferred compensation items subject to IRC section 877A(d)(1) - 39: Distributions from a nongrantor trust subject to IRC section 877A(f)(1) - 41: Guarantee of indebtedness - 42: Earnings as an artist or athlete - no central withholding agreement(5) - 43: Earnings as an artist or athlete - central withholding agreement(5) - 44: Specified Federal procurement payments - 50: Income previously reported under escrow procedure(6) - 55: Taxable death benefits on life insurance contracts - 57: Amount realized under IRC section 1446(f) - 58: Publicly traded partnership distributions-undetermined", alias="incomeCode") + gross_income: Optional[Union[StrictFloat, StrictInt]] = Field(description="Gross income", alias="grossIncome") + withholding_indicator: Optional[StrictStr] = Field(description="Withholding indicator Available values: - 3: Chapter 3 - 4: Chapter 4", alias="withholdingIndicator") + tax_country_code: Optional[StrictStr] = Field(description="Country code", alias="taxCountryCode") + exemption_code_chap3: Optional[StrictStr] = Field(default=None, description="Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3). Required when using TaxRateChap3. Available values: - Empty: Tax rate is due to backup withholding - 00: Not exempt - 01: Effectively connected income - 02: Exempt under IRC (other than portfolio interest) - 03: Income is not from US sources - 04: Exempt under tax treaty - 05: Portfolio interest exempt under IRC - 06: QI that assumes primary withholding responsibility - 07: WFP or WFT - 08: U.S. branch treated as U.S. Person - 09: Territory FI treated as U.S. Person - 10: QI represents that income is exempt - 11: QSL that assumes primary withholding responsibility - 12: Payee subjected to chapter 4 withholding - 22: QDD that assumes primary withholding responsibility - 23: Exempt under section 897(l) - 24: Exempt under section 892", alias="exemptionCodeChap3") + exemption_code_chap4: Optional[StrictStr] = Field(default=None, description="Exemption code (Chapter 4). Required if WithholdingIndicator is 4 (Chapter 4). Available values: - 00: Not exempt - 13: Grandfathered payment - 14: Effectively connected income - 15: Payee not subject to chapter 4 withholding - 16: Excluded nonfinancial payment - 17: Foreign Entity that assumes primary withholding responsibility - 18: U.S. Payees - of participating FFI or registered deemed - compliant FFI - 19: Exempt from withholding under IGA(6) - 20: Dormant account(7) - 21: Other - payment not subject to chapter 4 withholding", alias="exemptionCodeChap4") + tax_rate_chap3: Optional[StrictStr] = Field(default=None, description="Tax rate (Chapter 3) - Required if WithholdingIndicator is 3 (Chapter 3). Available values: - 00.00: 0.00% - 02.00: 2.00% - 04.00: 4.00% - 04.90: 4.90% - 04.95: 4.95% - 05.00: 5.00% - 07.00: 7.00% - 08.00: 8.00% - 10.00: 10.00% - 12.00: 12.00% - 12.50: 12.50% - 14.00: 14.00% - 15.00: 15.00% - 17.50: 17.50% - 20.00: 20.00% - 21.00: 21.00% - 24.00: 24.00% - 25.00: 25.00% - 27.50: 27.50% - 28.00: 28.00% - 30.00: 30.00% - 37.00: 37.00%", alias="taxRateChap3") + withholding_allowance: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Withholding allowance", alias="withholdingAllowance") + federal_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal tax withheld", alias="federalTaxWithheld") + tax_not_deposited_indicator: Optional[StrictBool] = Field(default=None, description="Tax not deposited indicator", alias="taxNotDepositedIndicator") + academic_indicator: Optional[StrictBool] = Field(default=None, description="Academic indicator", alias="academicIndicator") + tax_withheld_other_agents: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax withheld by other agents", alias="taxWithheldOtherAgents") + amount_repaid: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount repaid to recipient", alias="amountRepaid") + tax_paid_agent: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Tax paid by withholding agent", alias="taxPaidAgent") + chap3_status_code: Optional[StrictStr] = Field(default=None, description="Chapter 3 status code - Required if WithholdingIndicator is 3 (Chapter 3) Available values: - 01: U.S. Withholding Agent - FI (Deprecated - valid only for tax years prior to 2020) - 02: U.S. Withholding Agent - Other (Deprecated - valid only for tax years prior to 2020) - 03: Territory FI - treated as U.S. Person - 04: Territory FI - not treated as U.S. Person - 05: U.S. branch - treated as U.S. Person - 06: U.S. branch - not treated as U.S. Person - 07: U.S. branch - ECI presumption applied - 08: Partnership other than Withholding Foreign Partnership - 09: Withholding Foreign Partnership - 10: Trust other than Withholding Foreign Trust - 11: Withholding Foreign Trust - 12: Qualified Intermediary - 13: Qualified Securities Lender - Qualified Intermediary - 14: Qualified Securities Lender - Other - 15: Corporation - 16: Individual - 17: Estate - 18: Private Foundation - 19: Government or International Organization - 20: Tax Exempt Organization (Section 501(c) entities) - 21: Unknown Recipient - 22: Artist or Athlete - 23: Pension - 24: Foreign Central Bank of Issue - 25: Nonqualified Intermediary - 26: Hybrid entity making Treaty Claim - 27: Withholding Rate Pool - General - 28: Withholding Rate Pool - Exempt Organization - 29: PAI Withholding Rate Pool - General - 30: PAI Withholding Rate Pool - Exempt Organization - 31: Agency Withholding Rate Pool - General - 32: Agency Withholding Rate Pool - Exempt Organization - 34: U.S. Withholding Agent-Foreign branch of FI (Deprecated - valid only for tax years prior to 2020) - 35: Qualified Derivatives Dealer - 36: Foreign Government - Integral Part - 37: Foreign Government - Controlled Entity - 38: Publicly Traded Partnership - 39: Disclosing Qualified Intermediary", alias="chap3StatusCode") + chap4_status_code: Optional[StrictStr] = Field(default=None, description="Chapter 4 status code. Required if WithholdingIndicator is 4 (Chapter 4). Required if email is specified, must fill either this or RecipientForeignTin. Available values: - 01: U.S. Withholding Agent - FI - 02: U.S. Withholding Agent - Other - 03: Territory FI - not treated as U.S. Person - 04: Territory FI - treated as U.S. Person - 05: Participating FFI - Other - 06: Participating FFI - Reporting Model 2 FFI - 07: Registered Deemed - Compliant FFI-Reporting Model 1 FFI - 08: Registered Deemed - Compliant FFI-Sponsored Entity - 09: Registered Deemed - Compliant FFI-Other - 10: Certified Deemed - Compliant FFI-Other - 11: Certified Deemed - Compliant FFI-FFI with Low Value Accounts - 12: Certified Deemed - Compliant FFI-Non-Registering Local Bank - 13: Certified Deemed - Compliant FFI-Sponsored Entity - 14: Certified Deemed - Compliant FFI-Investment Advisor or Investment Manager - 15: Nonparticipating FFI - 16: Owner-Documented FFI - 17: U.S. Branch - treated as U.S. person - 18: U.S. Branch - not treated as U.S. person (reporting under section 1471) - 19: Passive NFFE identifying Substantial U.S. Owners - 20: Passive NFFE with no Substantial U.S. Owners - 21: Publicly Traded NFFE or Affiliate of Publicly Traded NFFE - 22: Active NFFE - 23: Individual - 24: Section 501(c) Entities - 25: Excepted Territory NFFE - 26: Excepted NFFE - Other - 27: Exempt Beneficial Owner - 28: Entity Wholly Owned by Exempt Beneficial Owners - 29: Unknown Recipient - 30: Recalcitrant Account Holder - 31: Nonreporting IGA FFI - 32: Direct reporting NFFE - 33: U.S. reportable account - 34: Non-consenting U.S. account - 35: Sponsored direct reporting NFFE - 36: Excepted Inter-affiliate FFI - 37: Undocumented Preexisting Obligation - 38: U.S. Branch - ECI presumption applied - 39: Account Holder of Excluded Financial Account - 40: Passive NFFE reported by FFI - 41: NFFE subject to 1472 withholding - 42: Recalcitrant Pool - No U.S. Indicia - 43: Recalcitrant Pool - U.S. Indicia - 44: Recalcitrant Pool - Dormant Account - 45: Recalcitrant Pool - U.S. Persons - 46: Recalcitrant Pool - Passive NFFEs - 47: Nonparticipating FFI Pool - 48: U.S. Payees Pool - 49: QI - Recalcitrant Pool-General - 50: U.S. Withholding Agent-Foreign branch of FI", alias="chap4StatusCode") + primary_withholding_agent: Optional[PrimaryWithholdingAgent] = Field(default=None, description="Primary withholding agent information", alias="primaryWithholdingAgent") + intermediary_or_flow_through: Optional[IntermediaryOrFlowThrough] = Field(default=None, description="Intermediary or flow-through entity information", alias="intermediaryOrFlowThrough") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value + + @field_validator('lob_code') + def lob_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12']): + raise ValueError("must be one of enum values ('01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12')") + return value + + @field_validator('income_code') + def income_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['01', '02', '03', '04', '05', '22', '29', '30', '31', '33', '51', '54', '06', '07', '08', '34', '40', '52', '53', '56', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '23', '24', '25', '26', '27', '28', '32', '35', '36', '37', '38', '39', '41', '42', '43', '44', '50', '55', '57', '58']): + raise ValueError("must be one of enum values ('01', '02', '03', '04', '05', '22', '29', '30', '31', '33', '51', '54', '06', '07', '08', '34', '40', '52', '53', '56', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '23', '24', '25', '26', '27', '28', '32', '35', '36', '37', '38', '39', '41', '42', '43', '44', '50', '55', '57', '58')") + return value + + @field_validator('withholding_indicator') + def withholding_indicator_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['3', '4']): + raise ValueError("must be one of enum values ('3', '4')") + return value + + @field_validator('exemption_code_chap3') + def exemption_code_chap3_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '22', '23', '24']): + raise ValueError("must be one of enum values ('00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '22', '23', '24')") + return value + + @field_validator('exemption_code_chap4') + def exemption_code_chap4_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['00', '13', '14', '15', '16', '17', '18', '19', '20', '21']): + raise ValueError("must be one of enum values ('00', '13', '14', '15', '16', '17', '18', '19', '20', '21')") + return value + + @field_validator('tax_rate_chap3') + def tax_rate_chap3_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['00.00', '02.00', '04.00', '04.90', '04.95', '05.00', '07.00', '08.00', '10.00', '12.00', '12.50', '14.00', '15.00', '17.50', '20.00', '21.00', '24.00', '25.00', '27.50', '28.00', '30.00', '37.00']): + raise ValueError("must be one of enum values ('00.00', '02.00', '04.00', '04.90', '04.95', '05.00', '07.00', '08.00', '10.00', '12.00', '12.50', '14.00', '15.00', '17.50', '20.00', '21.00', '24.00', '25.00', '27.50', '28.00', '30.00', '37.00')") + return value + + @field_validator('chap3_status_code') + def chap3_status_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['01', '02', '34', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '35', '36', '37', '38', '39']): + raise ValueError("must be one of enum values ('01', '02', '34', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '35', '36', '37', '38', '39')") + return value + + @field_validator('chap4_status_code') + def chap4_status_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50']): + raise ValueError("must be one of enum values ('01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50')") + return value + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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 model_config = ConfigDict( populate_by_name=True, @@ -143,8 +240,30 @@ def to_dict(self) -> Dict[str, Any]: * `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. + * OpenAPI `readOnly` fields are excluded. """ excluded_fields: Set[str] = set([ + "tin_type", + "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( @@ -152,6 +271,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -181,9 +303,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -194,66 +323,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -284,6 +378,21 @@ 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 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: @@ -294,26 +403,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -326,45 +490,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) 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 585b672..7a60b21 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1042_s_list_item import Form1042SListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item import Form1042SListItem from typing import Optional, Set from typing_extensions import Self 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 9607059..0a54959 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py @@ -36,9 +36,9 @@ 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.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 +from Avalara.SDK.models.A1099.V2.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough +from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent import PrimaryWithholdingAgent +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 2333e3a..8977de5 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 @@ -37,12 +37,12 @@ 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.intermediary_or_flow_through_response import IntermediaryOrFlowThroughResponse -from Avalara.SDK.models.A1099.V2.primary_withholding_agent_response import PrimaryWithholdingAgentResponse -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 Avalara.SDK.models.A1099.V2.A1099.V2.intermediary_or_flow_through_response import IntermediaryOrFlowThroughResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent_response import PrimaryWithholdingAgentResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_request.py b/Avalara/SDK/models/A1099/V2/form1042_s_request.py index ea59b13..e9d7966 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_request.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_request.py @@ -36,9 +36,9 @@ 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.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 +from Avalara.SDK.models.A1099.V2.A1099.V2.intermediary_or_flow_through_request import IntermediaryOrFlowThroughRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent_request import PrimaryWithholdingAgentRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_response.py b/Avalara/SDK/models/A1099/V2/form1042_s_response.py index e54be08..1d5cd50 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_response.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_response.py @@ -36,10 +36,10 @@ 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.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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b.py b/Avalara/SDK/models/A1099/V2/form1095_b.py index 66ce98d..34206a4 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,10 +33,10 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from datetime import date, 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_reference import CoveredIndividualReference +from Avalara.SDK.models.A1099.V2.covered_individual import CoveredIndividual 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 @@ -46,50 +46,82 @@ class Form1095B(BaseModel): """ - Form1095B + Form 1095-B: Health Coverage """ # noqa: E501 - origin_of_health_coverage_code: Optional[StrictStr] = Field(default=None, alias="originOfHealthCoverageCode") - covered_individuals: Optional[List[CoveredIndividualReference]] = Field(default=None, alias="coveredIndividuals") - 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"] + employee_first_name: Optional[StrictStr] = Field(description="Employee's first name", alias="employeeFirstName") + employee_middle_name: Optional[StrictStr] = Field(default=None, description="Employee's middle name", alias="employeeMiddleName") + employee_last_name: Optional[StrictStr] = Field(description="Employee's last name", alias="employeeLastName") + employee_name_suffix: Optional[StrictStr] = Field(default=None, description="Employee's name suffix", alias="employeeNameSuffix") + employee_date_of_birth: Optional[date] = Field(default=None, description="Employee's date of birth", alias="employeeDateOfBirth") + origin_of_health_coverage_code: Optional[StrictStr] = Field(description="Origin of health coverage code Available values: - A: Small Business Health Options Program (SHOP) - B: Employer-sponsored coverage - C: Government-sponsored program - D: Individual market insurance - E: Multiemployer plan - F: Other designated minimum essential coverage - G: Employer-sponsored coverage that is an individual coverage HRA (valid for tax years 2020 and later)", alias="originOfHealthCoverageCode") + covered_individuals: Optional[List[CoveredIndividual]] = Field(default=None, description="Covered individuals information - At least one month of coverage must be entered if it's not a correction.", alias="coveredIndividuals") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @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 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -121,8 +153,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -130,6 +182,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -159,9 +214,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -172,66 +234,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -262,6 +289,21 @@ 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 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: @@ -272,26 +314,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -304,45 +401,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_list.py b/Avalara/SDK/models/A1099/V2/form1095_b_list.py index 8116382..0867dec 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1095_b_list_item import Form1095BListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item import Form1095BListItem from typing import Optional, Set from typing_extensions import Self 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 49a6a7c..0c71e56 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py @@ -36,8 +36,8 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, 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_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 b26b04d..ebd44f6 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 @@ -37,11 +37,11 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.covered_individual_reference_response import CoveredIndividualReferenceResponse -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 Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_reference_response import CoveredIndividualReferenceResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_request.py b/Avalara/SDK/models/A1099/V2/form1095_b_request.py index 389940f..0440183 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_request.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_request.py @@ -36,8 +36,8 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, 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_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_response.py b/Avalara/SDK/models/A1099/V2/form1095_b_response.py index d9c45b1..9344340 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_response.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_response.py @@ -36,11 +36,11 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_c.py b/Avalara/SDK/models/A1099/V2/form1095_c.py new file mode 100644 index 0000000..ec8058f --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1095_c.py @@ -0,0 +1,449 @@ +# 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.3 +@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 date, 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 import CoveredIndividual +from Avalara.SDK.models.A1099.V2.form1099_status_detail import Form1099StatusDetail +from Avalara.SDK.models.A1099.V2.offer_and_coverage import OfferAndCoverage +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 Form1095C(BaseModel): + """ + Form 1095-C: Employer-Provided Health Insurance Offer and Coverage + """ # noqa: E501 + employee_first_name: Optional[StrictStr] = Field(description="Employee's first name", alias="employeeFirstName") + employee_middle_name: Optional[StrictStr] = Field(default=None, description="Employee's middle name", alias="employeeMiddleName") + employee_last_name: Optional[StrictStr] = Field(description="Employee's last name", alias="employeeLastName") + employee_name_suffix: Optional[StrictStr] = Field(default=None, description="Employee's name suffix", alias="employeeNameSuffix") + recipient_date_of_birth: Optional[date] = Field(default=None, description="Recipient's date of birth", alias="recipientDateOfBirth") + plan_start_month: Optional[StrictStr] = Field(description="Plan start month. The calendar month during which the plan year begins of the health plan in which the employee is offered coverage (or would be offered coverage if the employee were eligible to participate in the plan). Available values: - 00: None - 01: January - 02: February - 03: March - 04: April - 05: May - 06: June - 07: July - 08: August - 09: September - 10: October - 11: November - 12: December", alias="planStartMonth") + employer_provided_si_coverage: Optional[StrictBool] = Field(default=None, description="Employer provided self-insured coverage", alias="employerProvidedSiCoverage") + offer_and_coverages: List[OfferAndCoverage] = Field(description="Offer and coverage information", alias="offerAndCoverages") + covered_individuals: Optional[List[CoveredIndividual]] = Field(default=None, description="Covered individuals information", alias="coveredIndividuals") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('plan_start_month') + def plan_start_month_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12']): + raise ValueError("must be one of enum values ('00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12')") + return value + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', '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 Form1095C 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 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 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 + # set to None if id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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 tax_year (nullable) is None + # and model_fields_set contains the field + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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 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 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 federal_efile_date (nullable) is None + # and model_fields_set contains the field + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None + + # set to None if postal_mail (nullable) is None + # and model_fields_set contains the field + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None + + # set to None if state_efile_date (nullable) is None + # and model_fields_set contains the field + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + + # 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 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 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 Form1095C 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"), + "id": obj.get("id"), + "issuerId": obj.get("issuerId"), + "issuerReferenceId": obj.get("issuerReferenceId"), + "issuerTin": obj.get("issuerTin"), + "taxYear": obj.get("taxYear"), + "referenceId": obj.get("referenceId"), + "tin": obj.get("tin"), + "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"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, + "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") + }) + 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 fe92046..9203be5 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1095_c_list_item import Form1095CListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_c_list_item import Form1095CListItem from typing import Optional, Set from typing_extensions import Self 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 bff40cb..c86bced 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py @@ -36,9 +36,9 @@ 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.offer_and_coverage_request import OfferAndCoverageRequest -from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.offer_and_coverage_request import OfferAndCoverageRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_base.py b/Avalara/SDK/models/A1099/V2/form1099_base.py index 72c31a6..d23efa7 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_base.py +++ b/Avalara/SDK/models/A1099/V2/form1099_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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -47,46 +47,63 @@ class Form1099Base(BaseModel): """ Form1099Base """ # noqa: E501 - 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"] + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -118,8 +135,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -127,6 +164,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -156,9 +196,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -169,66 +216,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -259,6 +271,21 @@ 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 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: @@ -269,26 +296,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -301,45 +383,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_base_response.py b/Avalara/SDK/models/A1099/V2/form1099_base_response.py index 1dceb2b..f6537df 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_base_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_base_response.py @@ -37,10 +37,10 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div.py b/Avalara/SDK/models/A1099/V2/form1099_div.py index 161c726..a1970f0 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -45,66 +45,84 @@ class Form1099Div(BaseModel): """ - Form1099Div + Form 1099-DIV: Dividends and Distributions """ # 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"] + 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[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: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -136,8 +154,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -145,6 +183,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -174,9 +215,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -187,66 +235,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -277,6 +290,21 @@ 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 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: @@ -287,26 +315,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -319,45 +402,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) 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 77f39b2..e6bbc2f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_div_list_item import Form1099DivListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item import Form1099DivListItem from typing import Optional, Set from typing_extensions import Self 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 4761236..3d5dbe8 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 5ff6c60..e9b012d 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 @@ -37,10 +37,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_request.py b/Avalara/SDK/models/A1099/V2/form1099_div_request.py index 4e2aa6d..a350038 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_request.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_response.py b/Avalara/SDK/models/A1099/V2/form1099_div_response.py index aefde76..53bd95c 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int.py b/Avalara/SDK/models/A1099/V2/form1099_int.py index dc1b1d2..a08956e 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -47,60 +47,78 @@ 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"] + 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") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -132,8 +150,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -141,6 +179,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -170,9 +211,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -183,66 +231,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -273,6 +286,21 @@ 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 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: @@ -283,26 +311,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -315,45 +398,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list.py b/Avalara/SDK/models/A1099/V2/form1099_int_list.py index 0f83219..030f258 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item import Form1099IntListItem from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py index c40ce48..1bceac9 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 index bd9c732..bb19c58 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py @@ -37,10 +37,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_request.py b/Avalara/SDK/models/A1099/V2/form1099_int_request.py index ce4265b..7acdd39 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_request.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_response.py b/Avalara/SDK/models/A1099/V2/form1099_int_response.py index 9982f3d..a9f0348 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k.py b/Avalara/SDK/models/A1099/V2/form1099_k.py index 6199607..d278efd 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,7 +33,7 @@ import re # noqa: F401 import json -from datetime import datetime +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail @@ -45,68 +45,68 @@ class Form1099K(BaseModel): """ - Form1099K + Form 1099-K: Payment Card and Third Party Network Transactions """ # noqa: E501 - filer_type: Optional[StrictStr] = Field(default=None, alias="filerType") - payment_type: Optional[StrictStr] = Field(default=None, alias="paymentType") - payment_settlement_entity_name_phone_number: Optional[StrictStr] = Field(default=None, alias="paymentSettlementEntityNamePhoneNumber") - gross_amount_payment_card: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="grossAmountPaymentCard") - card_not_present_transactions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="cardNotPresentTransactions") - merchant_category_code: Optional[StrictStr] = Field(default=None, alias="merchantCategoryCode") - payment_transaction_number: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="paymentTransactionNumber") - federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalIncomeTaxWithheld") - january: Optional[Union[StrictFloat, StrictInt]] = None - february: Optional[Union[StrictFloat, StrictInt]] = None - march: Optional[Union[StrictFloat, StrictInt]] = None - april: Optional[Union[StrictFloat, StrictInt]] = None - may: Optional[Union[StrictFloat, StrictInt]] = None - june: Optional[Union[StrictFloat, StrictInt]] = None - july: Optional[Union[StrictFloat, StrictInt]] = None - august: Optional[Union[StrictFloat, StrictInt]] = None - sept: Optional[Union[StrictFloat, StrictInt]] = None - october: Optional[Union[StrictFloat, StrictInt]] = None - november: Optional[Union[StrictFloat, StrictInt]] = None - december: Optional[Union[StrictFloat, StrictInt]] = None - 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"] + filer_type: Optional[StrictStr] = Field(default=None, description="Filer type (PSE or EPF)", alias="filerType") + payment_type: Optional[StrictStr] = Field(default=None, description="Payment type (payment card or third party network)", alias="paymentType") + payment_settlement_entity_name_phone_number: Optional[StrictStr] = Field(default=None, description="Payment settlement entity name and phone number", alias="paymentSettlementEntityNamePhoneNumber") + gross_amount_payment_card: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Gross amount of payment card/third party network transactions", alias="grossAmountPaymentCard") + card_not_present_transactions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Card not present transactions", alias="cardNotPresentTransactions") + merchant_category_code: Optional[StrictStr] = Field(default=None, description="Merchant category code", alias="merchantCategoryCode") + payment_transaction_number: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Number of payment transactions", alias="paymentTransactionNumber") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + january: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="January gross payments") + february: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="February gross payments") + march: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="March gross payments") + april: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="April gross payments") + may: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="May gross payments") + june: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="June gross payments") + july: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="July gross payments") + august: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="August gross payments") + september: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="September gross payments") + october: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="October gross payments") + november: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="November gross payments") + december: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="December gross payments") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] @field_validator('filer_type') def filer_type_validate_enum(cls, value): @@ -128,6 +128,23 @@ def payment_type_validate_enum(cls, value): raise ValueError("must be one of enum values ('MerchantPaymentCard', 'ThirdPartyNetwork')") return value + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value + model_config = ConfigDict( populate_by_name=True, validate_assignment=True, @@ -158,8 +175,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -167,6 +204,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -196,9 +236,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -209,66 +256,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -299,6 +311,21 @@ 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 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: @@ -309,26 +336,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -341,45 +423,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_list.py b/Avalara/SDK/models/A1099/V2/form1099_k_list.py index 0b9b215..0805c29 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_k_list_item import Form1099KListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item import Form1099KListItem from typing import Optional, Set from typing_extensions import Self 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 bd8c455..e51a1eb 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 9660bf9..0e9fe04 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 @@ -37,10 +37,10 @@ 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_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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_request.py b/Avalara/SDK/models/A1099/V2/form1099_k_request.py index cc6aae6..b5239f9 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_request.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_response.py b/Avalara/SDK/models/A1099/V2/form1099_k_response.py index eb48a2b..70e9007 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_list_request.py b/Avalara/SDK/models/A1099/V2/form1099_list_request.py new file mode 100644 index 0000000..cde7732 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/form1099_list_request.py @@ -0,0 +1,123 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.get1099_form200_response import Get1099Form200Response +from typing import Optional, Set +from typing_extensions import Self + +class Form1099ListRequest(BaseModel): + """ + Form1099ListRequest + """ # noqa: E501 + type: Optional[StrictStr] = None + forms: Optional[List[Get1099Form200Response]] = None + __properties: ClassVar[List[str]] = ["type", "forms"] + + @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 + + 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 Form1099ListRequest 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 forms (list) + _items = [] + if self.forms: + for _item in self.forms: + if _item: + _items.append(_item.to_dict()) + _dict['forms'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Form1099ListRequest 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"), + "forms": [Get1099Form200Response.from_dict(_item) for _item in obj["forms"]] if obj.get("forms") is not None else None + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/form1099_list_response.py b/Avalara/SDK/models/A1099/V2/form1099_list_response.py index d988a94..ca0543a 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_list_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_list_response.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_list_response_value_inner import Form1099ListResponseValueInner +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_list_response_value_inner import Form1099ListResponseValueInner from typing import Optional, Set from typing_extensions import Self 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 0cfa497..3812f88 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 @@ -33,15 +33,15 @@ 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_list_item_response import Form1042SListItemResponse -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 -from Avalara.SDK.models.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse 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/form1099_misc.py b/Avalara/SDK/models/A1099/V2/form1099_misc.py index 475f85f..20e880b 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -45,62 +45,80 @@ class Form1099Misc(BaseModel): """ - Form1099Misc + Form 1099-MISC: Miscellaneous Income """ # noqa: E501 - rents: Optional[Union[StrictFloat, StrictInt]] = None - royalties: Optional[Union[StrictFloat, StrictInt]] = None - 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_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_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") - 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") - 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"] + rents: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Rents") + royalties: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Royalties") + other_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Other income", alias="otherIncome") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + fishing_boat_proceeds: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Fishing boat proceeds", alias="fishingBoatProceeds") + medical_and_health_care_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Medical and health care payments", alias="medicalAndHealthCarePayments") + direct_sales_indicator: Optional[StrictBool] = Field(default=None, description="Payer made direct sales totaling $5,000 or more of consumer products to recipient for resale", alias="directSalesIndicator") + substitute_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Substitute payments in lieu of dividends or interest", alias="substitutePayments") + crop_insurance_proceeds: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Crop insurance proceeds", alias="cropInsuranceProceeds") + gross_proceeds_paid_to_attorney: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Gross proceeds paid to an attorney", alias="grossProceedsPaidToAttorney") + fish_purchased_for_resale: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Fish purchased for resale", alias="fishPurchasedForResale") + section409_a_deferrals: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Section 409A deferrals", alias="section409ADeferrals") + excess_golden_parachute_payments: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="(Legacy field) Excess golden parachute payments", alias="excessGoldenParachutePayments") + nonqualified_deferred_compensation: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Nonqualified deferred compensation", alias="nonqualifiedDeferredCompensation") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -132,8 +150,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -141,6 +179,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -170,9 +211,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -183,66 +231,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -273,6 +286,21 @@ 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 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: @@ -283,26 +311,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -315,45 +398,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_list.py b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py index 324ee21..df2256d 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_misc_list_item import Form1099MiscListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item import Form1099MiscListItem from typing import Optional, Set from typing_extensions import Self 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 d1ce0ff..c900ee4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 30db98c..c6a4332 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 @@ -37,10 +37,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py index 7927879..0aee3eb 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py index f72fe5b..523549f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec.py b/Avalara/SDK/models/A1099/V2/form1099_nec.py index b5dc1b4..94b3b52 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -47,49 +47,66 @@ class Form1099Nec(BaseModel): """ Form1099Nec """ # noqa: E501 - nonemployee_compensation: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="nonemployeeCompensation") - federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="federalIncomeTaxWithheld") - direct_sales_indicator: Optional[StrictBool] = Field(default=None, alias="directSalesIndicator") - 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"] + nonemployee_compensation: Optional[Union[StrictFloat, StrictInt]] = Field(description="Nonemployee compensation", alias="nonemployeeCompensation") + direct_sales_indicator: Optional[StrictBool] = Field(default=None, description="Payer made direct sales totaling $5,000 or more of consumer products to recipient for resale", alias="directSalesIndicator") + federal_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Federal income tax withheld", alias="federalIncomeTaxWithheld") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -121,8 +138,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -130,6 +167,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -159,9 +199,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -172,66 +219,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -262,6 +274,21 @@ 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 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: @@ -272,26 +299,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -304,45 +386,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py index 7b5da5d..b679ebf 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_nec_list_item import Form1099NecListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item import Form1099NecListItem from typing import Optional, Set from typing_extensions import Self 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 7684c42..986138a 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 aa66f55..46719da 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 @@ -37,10 +37,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py index f94418f..3c687f3 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py @@ -35,7 +35,7 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py index 800d7e4..8c42ed3 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py index 0be1168..6f69b1f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py +++ b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py @@ -35,8 +35,8 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.data import Data +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_proccess_result_processed_forms_inner import Form1099ProccessResultProcessedFormsInner from typing import Optional, Set from typing_extensions import Self 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 index 8a475f5..fdd6eb9 100644 --- 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 @@ -33,14 +33,14 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s import Form1042S +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b import Form1095B +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div import Form1099Div +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int import Form1099Int +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k import Form1099K +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc import Form1099Misc +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec import Form1099Nec +from Avalara.SDK.models.A1099.V2.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 diff --git a/Avalara/SDK/models/A1099/V2/form1099_r.py b/Avalara/SDK/models/A1099/V2/form1099_r.py index 12a2921..47e5923 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,8 +33,8 @@ import re # noqa: F401 import json -from datetime import datetime -from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from datetime import date, 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.form1099_status_detail import Form1099StatusDetail from Avalara.SDK.models.A1099.V2.state_and_local_withholding import StateAndLocalWithholding @@ -45,67 +45,85 @@ class Form1099R(BaseModel): """ - Form1099R + Form 1099-R: Distributions From Pensions, Annuities, Retirement or Profit-Sharing Plans, IRAs, Insurance Contracts, etc. """ # noqa: E501 - gross_distributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="grossDistributions") - taxable_amount: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="taxableAmount") - taxable_amount_not_determined: Optional[StrictBool] = Field(default=None, alias="taxableAmountNotDetermined") - total_distribution_indicator: Optional[StrictBool] = Field(default=None, alias="totalDistributionIndicator") - capital_gain: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="capitalGain") - fed_income_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="fedIncomeTaxWithheld") - employee_contributions: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="employeeContributions") - net_unrealized_appreciation: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="netUnrealizedAppreciation") - distribution_code_required: Optional[StrictStr] = Field(default=None, alias="distributionCodeRequired") - distribution_code_optional: Optional[StrictStr] = Field(default=None, alias="distributionCodeOptional") - ira_sep_simple_indicator: Optional[StrictBool] = Field(default=None, alias="iraSepSimpleIndicator") - total_ira_sep_simple_distribution: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="totalIraSepSimpleDistribution") - other: Optional[Union[StrictFloat, StrictInt]] = None - other_percent: Optional[StrictStr] = Field(default=None, alias="otherPercent") - percentage_total_distribution: Optional[StrictStr] = Field(default=None, alias="percentageTotalDistribution") - 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") - date_of_payment: Optional[StrictStr] = Field(default=None, alias="dateOfPayment") - 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"] + 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") + date_of_payment: Optional[date] = Field(default=None, description="Date of payment", alias="dateOfPayment") + fatca_filing_requirement: Optional[StrictBool] = Field(default=None, description="FATCA filing requirement", alias="fatcaFilingRequirement") + type: StrictStr = Field(description="Form type") + id: Optional[StrictStr] = Field(default=None, description="Form ID. Unique identifier set when the record is created.") + issuer_id: Optional[StrictStr] = Field(default=None, description="Issuer ID - only required when creating forms", alias="issuerId") + issuer_reference_id: Optional[StrictStr] = Field(default=None, description="Issuer Reference ID - only required when creating forms", alias="issuerReferenceId") + issuer_tin: Optional[StrictStr] = Field(default=None, description="Issuer TIN - readonly", alias="issuerTin") + tax_year: Optional[StrictInt] = Field(default=None, description="Tax Year - only required when creating forms", alias="taxYear") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient.", alias="referenceId") + tin: Optional[StrictStr] = Field(default=None, description="Recipient's Federal Tax Identification Number (TIN).") + recipient_name: Optional[StrictStr] = Field(description="Recipient name", alias="recipientName") + tin_type: Optional[StrictStr] = Field(default=None, description="Type of TIN (Tax ID Number)", alias="tinType") + recipient_second_name: Optional[StrictStr] = Field(default=None, description="Recipient second name", alias="recipientSecondName") + address: Optional[StrictStr] = Field(description="Address.") + address2: Optional[StrictStr] = Field(default=None, description="Address line 2.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(default=None, description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(default=None, description="ZIP/postal code.") + email: Optional[StrictStr] = Field(default=None, description="Recipient's Contact 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="Province or region for non-US/CA addresses.", alias="nonUsProvince") + country_code: Optional[StrictStr] = Field(description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes.", alias="countryCode") + federal_efile_date: Optional[date] = Field(default=None, description="Date when federal e-filing should be scheduled for this form", alias="federalEfileDate") + 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_efile_date: Optional[date] = Field(default=None, description="Date when state e-filing should be scheduled for this form", alias="stateEfileDate") + recipient_edelivery_date: Optional[date] = Field(default=None, description="Date when recipient e-delivery should be scheduled for this form", alias="recipientEdeliveryDate") + 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="No TIN indicator", alias="noTin") + 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[StateAndLocalWithholding] = Field(default=None, description="State and local withholding information", alias="stateAndLocalWithholding") + second_tin_notice: Optional[StrictBool] = Field(default=None, description="Second TIN notice", alias="secondTinNotice") + federal_efile_status: Optional[Form1099StatusDetail] = Field(default=None, description="Federal e-file status", alias="federalEfileStatus") + state_efile_status: Optional[List[StateEfileStatusDetail]] = Field(default=None, description="State e-file status", alias="stateEfileStatus") + postal_mail_status: Optional[Form1099StatusDetail] = Field(default=None, description="Postal mail to recipient status", alias="postalMailStatus") + tin_match_status: Optional[Form1099StatusDetail] = Field(default=None, description="TIN Match status", alias="tinMatchStatus") + address_verification_status: Optional[Form1099StatusDetail] = Field(default=None, description="Address verification status", alias="addressVerificationStatus") + e_delivery_status: Optional[Form1099StatusDetail] = Field(default=None, description="EDelivery status", alias="eDeliveryStatus") + validation_errors: Optional[List[ValidationError]] = Field(default=None, description="Validation errors", alias="validationErrors") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + __properties: ClassVar[List[str]] = ["type", "id", "issuerId", "issuerReferenceId", "issuerTin", "taxYear", "referenceId", "tin", "recipientName", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "email", "accountNumber", "officeCode", "nonUsProvince", "countryCode", "federalEfileDate", "postalMail", "stateEfileDate", "recipientEdeliveryDate", "tinMatch", "noTin", "addressVerification", "stateAndLocalWithholding", "secondTinNotice", "federalEfileStatus", "stateEfileStatus", "postalMailStatus", "tinMatchStatus", "addressVerificationStatus", "eDeliveryStatus", "validationErrors", "createdAt", "updatedAt"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + 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(['Empty', 'EIN', 'SSN', 'ITIN', 'ATIN']): + raise ValueError("must be one of enum values ('Empty', 'EIN', 'SSN', 'ITIN', 'ATIN')") + return value model_config = ConfigDict( populate_by_name=True, @@ -137,8 +155,28 @@ def to_dict(self) -> Dict[str, Any]: * `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( @@ -146,6 +184,9 @@ def to_dict(self) -> Dict[str, Any]: 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() @@ -175,9 +216,16 @@ def to_dict(self) -> Dict[str, Any]: 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 id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = 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 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: @@ -188,66 +236,31 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if tax_year (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 + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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: @@ -278,6 +291,21 @@ 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 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: @@ -288,26 +316,81 @@ def to_dict(self) -> Dict[str, Any]: 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 + # set to None if federal_efile_date (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 + if self.federal_efile_date is None and "federal_efile_date" in self.model_fields_set: + _dict['federalEfileDate'] = None - # set to None if office_code (nullable) is None + # set to None if postal_mail (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 + if self.postal_mail is None and "postal_mail" in self.model_fields_set: + _dict['postalMail'] = None - # set to None if validation_errors (nullable) is None + # set to None if state_efile_date (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 + if self.state_efile_date is None and "state_efile_date" in self.model_fields_set: + _dict['stateEfileDate'] = None + + # set to None if recipient_edelivery_date (nullable) is None + # and model_fields_set contains the field + if self.recipient_edelivery_date is None and "recipient_edelivery_date" in self.model_fields_set: + _dict['recipientEdeliveryDate'] = None + + # set to None if tin_match (nullable) is None + # and model_fields_set contains the field + if self.tin_match is None and "tin_match" in self.model_fields_set: + _dict['tinMatch'] = None + + # set to None if no_tin (nullable) is None + # and model_fields_set contains the field + if self.no_tin is None and "no_tin" in self.model_fields_set: + _dict['noTin'] = None + + # set to None if address_verification (nullable) is None + # and model_fields_set contains the field + if self.address_verification is None and "address_verification" in self.model_fields_set: + _dict['addressVerification'] = 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 + # 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 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 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 @@ -320,45 +403,45 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "id": obj.get("id"), "type": obj.get("type"), + "id": obj.get("id"), "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"), + "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"), - "nonUsProvince": obj.get("nonUsProvince"), - "countryCode": obj.get("countryCode"), + "email": obj.get("email"), "accountNumber": obj.get("accountNumber"), "officeCode": obj.get("officeCode"), + "nonUsProvince": obj.get("nonUsProvince"), + "countryCode": obj.get("countryCode"), + "federalEfileDate": obj.get("federalEfileDate"), + "postalMail": obj.get("postalMail"), + "stateEfileDate": obj.get("stateEfileDate"), + "recipientEdeliveryDate": obj.get("recipientEdeliveryDate"), + "tinMatch": obj.get("tinMatch"), + "noTin": obj.get("noTin"), + "addressVerification": obj.get("addressVerification"), + "stateAndLocalWithholding": StateAndLocalWithholding.from_dict(obj["stateAndLocalWithholding"]) if obj.get("stateAndLocalWithholding") is not None else None, + "secondTinNotice": obj.get("secondTinNotice"), + "federalEfileStatus": Form1099StatusDetail.from_dict(obj["federalEfileStatus"]) if obj.get("federalEfileStatus") is not None else None, + "stateEfileStatus": [StateEfileStatusDetail.from_dict(_item) for _item in obj["stateEfileStatus"]] if obj.get("stateEfileStatus") is not None else None, + "postalMailStatus": Form1099StatusDetail.from_dict(obj["postalMailStatus"]) if obj.get("postalMailStatus") is not None else None, + "tinMatchStatus": Form1099StatusDetail.from_dict(obj["tinMatchStatus"]) if obj.get("tinMatchStatus") is not None else None, + "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, "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 + "updatedAt": obj.get("updatedAt") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_list.py b/Avalara/SDK/models/A1099/V2/form1099_r_list.py index 07fa473..e2bd7d4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_r_list_item import Form1099RListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item import Form1099RListItem from typing import Optional, Set from typing_extensions import Self 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 9bba843..a661f16 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py @@ -36,7 +36,7 @@ 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_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 dff739c..14d0161 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 @@ -37,10 +37,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_request.py b/Avalara/SDK/models/A1099/V2/form1099_r_request.py index 04b2d10..0ee5fdd 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_request.py @@ -36,7 +36,7 @@ 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_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_response.py b/Avalara/SDK/models/A1099/V2/form1099_r_response.py index fbb42f0..474b0ce 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_response.py @@ -36,10 +36,10 @@ 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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_status_detail.py b/Avalara/SDK/models/A1099/V2/form1099_status_detail.py index ffd316e..01b558d 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_status_detail.py +++ b/Avalara/SDK/models/A1099/V2/form1099_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.2 +@version 25.8.3 @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 59d7c21..a60c024 100644 --- a/Avalara/SDK/models/A1099/V2/form_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_request_base.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 d19891d..8f8c315 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 @@ -35,7 +35,7 @@ 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.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form_response_base.py b/Avalara/SDK/models/A1099/V2/form_response_base.py index b8e66b2..a0bbc01 100644 --- a/Avalara/SDK/models/A1099/V2/form_response_base.py +++ b/Avalara/SDK/models/A1099/V2/form_response_base.py @@ -36,10 +36,10 @@ 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.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 Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self 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 9ef6f7f..90ee70d 100644 --- a/Avalara/SDK/models/A1099/V2/form_single_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_single_request_base.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/get1099_form200_response.py b/Avalara/SDK/models/A1099/V2/get1099_form200_response.py index e4ea5b8..a9a7e2c 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -33,45 +33,45 @@ 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_list_item_response import Form1042SListItemResponse -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 -from Avalara.SDK.models.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse +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.form1095_c import Form1095C +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 -GET1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042SListItemResponse", "Form1095BListItemResponse", "Form1099BaseResponse", "Form1099DivListItemResponse", "Form1099IntListItemResponse", "Form1099KListItemResponse", "Form1099MiscListItemResponse", "Form1099NecListItemResponse", "Form1099RListItemResponse"] +GET1099FORM200RESPONSE_ONE_OF_SCHEMAS = ["Form1042S", "Form1095B", "Form1095C", "Form1099Div", "Form1099Int", "Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R"] class Get1099Form200Response(BaseModel): """ Get1099Form200Response """ - # data type: Form1099BaseResponse - oneof_schema_1_validator: Optional[Form1099BaseResponse] = None - # data type: Form1042SListItemResponse - oneof_schema_2_validator: Optional[Form1042SListItemResponse] = None - # data type: Form1095BListItemResponse - 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_6_validator: Optional[Form1099KListItemResponse] = None - # data type: Form1099MiscListItemResponse - oneof_schema_7_validator: Optional[Form1099MiscListItemResponse] = None - # data type: Form1099NecListItemResponse - oneof_schema_8_validator: Optional[Form1099NecListItemResponse] = None - # data type: 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" } + # data type: Form1042S + oneof_schema_1_validator: Optional[Form1042S] = None + # data type: Form1095B + oneof_schema_2_validator: Optional[Form1095B] = None + # data type: Form1095C + oneof_schema_3_validator: Optional[Form1095C] = None + # data type: Form1099Div + oneof_schema_4_validator: Optional[Form1099Div] = None + # data type: Form1099Int + oneof_schema_5_validator: Optional[Form1099Int] = None + # data type: Form1099K + oneof_schema_6_validator: Optional[Form1099K] = None + # data type: Form1099Misc + oneof_schema_7_validator: Optional[Form1099Misc] = None + # data type: Form1099Nec + oneof_schema_8_validator: Optional[Form1099Nec] = None + # data type: Form1099R + oneof_schema_9_validator: Optional[Form1099R] = None + actual_instance: Optional[Union[Form1042S, Form1095B, Form1095C, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R]] = None + one_of_schemas: Set[str] = { "Form1042S", "Form1095B", "Form1095C", "Form1099Div", "Form1099Int", "Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R" } model_config = ConfigDict( validate_assignment=True, @@ -94,57 +94,57 @@ def actual_instance_must_validate_oneof(cls, v): instance = Get1099Form200Response.model_construct() error_messages = [] match = 0 - # validate data type: Form1099BaseResponse - if not isinstance(v, Form1099BaseResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099BaseResponse`") + # 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: Form1042SListItemResponse - if not isinstance(v, Form1042SListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1042SListItemResponse`") + # 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: Form1095BListItemResponse - if not isinstance(v, Form1095BListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1095BListItemResponse`") + # validate data type: Form1095C + if not isinstance(v, Form1095C): + error_messages.append(f"Error! Input type `{type(v)}` is not `Form1095C`") else: match += 1 - # validate data type: Form1099DivListItemResponse - if not isinstance(v, Form1099DivListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099DivListItemResponse`") + # 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: Form1099IntListItemResponse - if not isinstance(v, Form1099IntListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099IntListItemResponse`") + # 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: Form1099KListItemResponse - if not isinstance(v, Form1099KListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099KListItemResponse`") + # 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: Form1099MiscListItemResponse - if not isinstance(v, Form1099MiscListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099MiscListItemResponse`") + # 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: Form1099NecListItemResponse - if not isinstance(v, Form1099NecListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099NecListItemResponse`") + # 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: Form1099RListItemResponse - if not isinstance(v, Form1099RListItemResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `Form1099RListItemResponse`") + # 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 Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042S, Form1095B, Form1095C, 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 Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in Get1099Form200Response with oneOf schemas: Form1042S, Form1095B, Form1095C, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) else: return v @@ -159,67 +159,67 @@ def from_json(cls, json_str: str) -> Self: error_messages = [] match = 0 - # deserialize data into Form1099BaseResponse + # deserialize data into Form1042S try: - instance.actual_instance = Form1099BaseResponse.from_json(json_str) + instance.actual_instance = Form1042S.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1042SListItemResponse + # deserialize data into Form1095B try: - instance.actual_instance = Form1042SListItemResponse.from_json(json_str) + instance.actual_instance = Form1095B.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1095BListItemResponse + # deserialize data into Form1095C try: - instance.actual_instance = Form1095BListItemResponse.from_json(json_str) + instance.actual_instance = Form1095C.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099DivListItemResponse + # deserialize data into Form1099Div try: - instance.actual_instance = Form1099DivListItemResponse.from_json(json_str) + instance.actual_instance = Form1099Div.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099IntListItemResponse + # deserialize data into Form1099Int try: - instance.actual_instance = Form1099IntListItemResponse.from_json(json_str) + instance.actual_instance = Form1099Int.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099KListItemResponse + # deserialize data into Form1099K try: - instance.actual_instance = Form1099KListItemResponse.from_json(json_str) + instance.actual_instance = Form1099K.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099MiscListItemResponse + # deserialize data into Form1099Misc try: - instance.actual_instance = Form1099MiscListItemResponse.from_json(json_str) + instance.actual_instance = Form1099Misc.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099NecListItemResponse + # deserialize data into Form1099Nec try: - instance.actual_instance = Form1099NecListItemResponse.from_json(json_str) + instance.actual_instance = Form1099Nec.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) - # deserialize data into Form1099RListItemResponse + # deserialize data into Form1099R try: - instance.actual_instance = Form1099RListItemResponse.from_json(json_str) + 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 Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042S, Form1095B, Form1095C, 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 Get1099Form200Response with oneOf schemas: Form1042SListItemResponse, Form1095BListItemResponse, Form1099BaseResponse, Form1099DivListItemResponse, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into Get1099Form200Response with oneOf schemas: Form1042S, Form1095B, Form1095C, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) else: return instance @@ -233,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, Form1099IntListItemResponse, Form1099KListItemResponse, Form1099MiscListItemResponse, Form1099NecListItemResponse, Form1099RListItemResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], Form1042S, Form1095B, Form1095C, Form1099Div, Form1099Int, Form1099K, Form1099Misc, Form1099Nec, Form1099R]]: """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 fe3c4ea..15c6625 100644 --- a/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py @@ -33,10 +33,10 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_div_request import Form1099DivRequest -from Avalara.SDK.models.A1099.V2.form1099_k_request import Form1099KRequest -from Avalara.SDK.models.A1099.V2.form1099_misc_request import Form1099MiscRequest -from Avalara.SDK.models.A1099.V2.form1099_nec_request import Form1099NecRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest 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/i_update_form1099_request.py b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py index d278c71..1bd3afc 100644 --- a/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py @@ -33,10 +33,10 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.form1099_div_request import Form1099DivRequest -from Avalara.SDK.models.A1099.V2.form1099_k_request import Form1099KRequest -from Avalara.SDK.models.A1099.V2.form1099_misc_request import Form1099MiscRequest -from Avalara.SDK.models.A1099.V2.form1099_nec_request import Form1099NecRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest 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/intermediary_or_flow_through.py b/Avalara/SDK/models/A1099/V2/intermediary_or_flow_through.py index 81e2bfd..6efd99a 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -40,19 +40,19 @@ class IntermediaryOrFlowThrough(BaseModel): """ - IntermediaryOrFlowThrough + Intermediary or flow-through entity information for tax forms """ # noqa: E501 - ein: Optional[StrictStr] = None - chap3_status_code: Optional[StrictStr] = Field(default=None, alias="chap3StatusCode") - chap4_status_code: Optional[StrictStr] = Field(default=None, alias="chap4StatusCode") - name: Optional[StrictStr] = None - giin: Optional[StrictStr] = None - country_code: Optional[StrictStr] = Field(default=None, alias="countryCode") - foreign_tin: Optional[StrictStr] = Field(default=None, alias="foreignTin") - address: Optional[StrictStr] = None - city: Optional[StrictStr] = None - state: Optional[StrictStr] = None - zip: Optional[StrictStr] = None + ein: Optional[StrictStr] = Field(default=None, description="EIN (Employer Identification Number) of the intermediary or flow-through entity") + chap3_status_code: Optional[StrictStr] = Field(default=None, description="Chapter 3 status code for the intermediary or flow-through entity", alias="chap3StatusCode") + chap4_status_code: Optional[StrictStr] = Field(default=None, description="Chapter 4 status code for the intermediary or flow-through entity", alias="chap4StatusCode") + name: Optional[StrictStr] = Field(default=None, description="Name of the intermediary or flow-through entity") + giin: Optional[StrictStr] = Field(default=None, description="GIIN (Global Intermediary Identification Number) of the intermediary or flow-through entity") + country_code: Optional[StrictStr] = Field(default=None, description="Country code for the intermediary or flow-through entity", alias="countryCode") + foreign_tin: Optional[StrictStr] = Field(default=None, description="Foreign TIN of the intermediary or flow-through entity", alias="foreignTin") + address: Optional[StrictStr] = Field(default=None, description="Address of the intermediary or flow-through entity") + city: Optional[StrictStr] = Field(default=None, description="City of the intermediary or flow-through entity") + state: Optional[StrictStr] = Field(default=None, description="State of the intermediary or flow-through entity") + zip: Optional[StrictStr] = Field(default=None, description="Zip code of the intermediary or flow-through entity") __properties: ClassVar[List[str]] = ["ein", "chap3StatusCode", "chap4StatusCode", "name", "giin", "countryCode", "foreignTin", "address", "city", "state", "zip"] model_config = ConfigDict( diff --git a/Avalara/SDK/models/A1099/V2/irs_response.py b/Avalara/SDK/models/A1099/V2/irs_response.py index d536cfa..c75272f 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.2 +@version 25.8.3 @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 6b63ca9..c61e95e 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -42,22 +42,22 @@ class IssuerCommand(BaseModel): """ IssuerCommand """ # noqa: E501 - name: Optional[StrictStr] = Field(default=None, description="Legal name, not DBA") - name_dba: Optional[StrictStr] = Field(default=None, description="Optional DBA name or continuation of a long legal name", alias="nameDba") - tin: Optional[StrictStr] = Field(default=None, description="Tax identification number") - reference_id: Optional[StrictStr] = Field(default=None, description="Optional identifier for your reference, never shown to any agency or recipient. We will also prefix download filenames with this value, if present. Can only include letters, numbers, dashes, underscores and spaces.", alias="referenceId") - telephone: Optional[StrictStr] = Field(default=None, description="Telephone number") - tax_year: Optional[StrictInt] = Field(default=None, description="Tax year", alias="taxYear") - country_code: Optional[StrictStr] = Field(default=None, description="If there is a transfer agent, use the shipping address of the transfer agent.", alias="countryCode") - email: Optional[StrictStr] = Field(default=None, description="Email address") - address: Optional[StrictStr] = Field(default=None, description="Address") - city: Optional[StrictStr] = Field(default=None, description="City") - state: Optional[StrictStr] = Field(default=None, description="State") - zip: Optional[StrictStr] = Field(default=None, description="Zip code") - foreign_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="foreignProvince") - transfer_agent_name: Optional[StrictStr] = Field(default=None, description="Transfer Agent's Name", alias="transferAgentName") - last_filing: Optional[StrictBool] = Field(default=None, description="Last year of filing for this payer", alias="lastFiling") - __properties: ClassVar[List[str]] = ["name", "nameDba", "tin", "referenceId", "telephone", "taxYear", "countryCode", "email", "address", "city", "state", "zip", "foreignProvince", "transferAgentName", "lastFiling"] + name: Optional[StrictStr] = Field(description="Legal name. Not the DBA name.") + dba_name: Optional[StrictStr] = Field(default=None, description="Doing Business As (DBA) name or continuation of a long legal name. Use either this or 'transferAgentName'.", alias="dbaName") + tin: Optional[StrictStr] = Field(default=None, description="Federal Tax Identification Number (TIN).") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient. If present, it will prefix download filenames. Allowed characters: letters, numbers, dashes, underscores, and spaces.", alias="referenceId") + telephone: Optional[StrictStr] = Field(description="Contact phone number (must contain at least 10 digits, max 15 characters). For recipient inquiries.") + tax_year: Optional[StrictInt] = Field(description="Tax year for which the forms are being filed (e.g., 2024). Must be within current tax year and current tax year - 4.", alias="taxYear") + country_code: Optional[StrictStr] = Field(default=None, description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. If there is a transfer agent, use the transfer agent's shipping address.", alias="countryCode") + email: Optional[StrictStr] = Field(description="Contact email address. For recipient inquiries.") + address: Optional[StrictStr] = Field(description="Address.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(description="ZIP/postal code.") + foreign_province: Optional[StrictStr] = Field(default=None, description="Province or region for non-US/CA addresses.", alias="foreignProvince") + transfer_agent_name: Optional[StrictStr] = Field(default=None, description="Name of the transfer agent, if applicable — optional; use either this or 'dbaName'.", alias="transferAgentName") + last_filing: Optional[StrictBool] = Field(description="Indicates if this is the issuer's final year filing.", alias="lastFiling") + __properties: ClassVar[List[str]] = ["name", "dbaName", "tin", "referenceId", "telephone", "taxYear", "countryCode", "email", "address", "city", "state", "zip", "foreignProvince", "transferAgentName", "lastFiling"] model_config = ConfigDict( populate_by_name=True, @@ -103,10 +103,10 @@ def to_dict(self) -> Dict[str, Any]: if self.name is None and "name" in self.model_fields_set: _dict['name'] = None - # set to None if name_dba (nullable) is None + # set to None if dba_name (nullable) is None # and model_fields_set contains the field - if self.name_dba is None and "name_dba" in self.model_fields_set: - _dict['nameDba'] = None + if self.dba_name is None and "dba_name" in self.model_fields_set: + _dict['dbaName'] = None # set to None if tin (nullable) is None # and model_fields_set contains the field @@ -123,6 +123,11 @@ def to_dict(self) -> Dict[str, Any]: if self.telephone is None and "telephone" in self.model_fields_set: _dict['telephone'] = None + # set to None if tax_year (nullable) is None + # and model_fields_set contains the field + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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: @@ -181,7 +186,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "name": obj.get("name"), - "nameDba": obj.get("nameDba"), + "dbaName": obj.get("dbaName"), "tin": obj.get("tin"), "referenceId": obj.get("referenceId"), "telephone": obj.get("telephone"), diff --git a/Avalara/SDK/models/A1099/V2/issuer_response.py b/Avalara/SDK/models/A1099/V2/issuer_response.py index 447de66..0c230ba 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -43,25 +43,25 @@ class IssuerResponse(BaseModel): """ IssuerResponse """ # noqa: E501 - id: Optional[StrictStr] = Field(default=None, description="Unique identifier set when the record is created") - name: Optional[StrictStr] = Field(default=None, description="Legal name, not DBA") - name_dba: Optional[StrictStr] = Field(default=None, description="Optional DBA name or continuation of a long legal name", alias="nameDba") - tin: Optional[StrictStr] = Field(default=None, description="Tax identification number") - reference_id: Optional[StrictStr] = Field(default=None, description="Optional identifier for your reference, never shown to any agency or recipient. We will also prefix download filenames with this value, if present. Can only include letters, numbers, dashes, underscores and spaces.", alias="referenceId") - telephone: Optional[StrictStr] = Field(default=None, description="Telephone number") - tax_year: Optional[StrictInt] = Field(default=None, description="Tax year", alias="taxYear") - country_code: Optional[StrictStr] = Field(default=None, description="If there is a transfer agent, use the address of the transfer agent.", alias="countryCode") - email: Optional[StrictStr] = Field(default=None, description="Email address") - address: Optional[StrictStr] = Field(default=None, description="Address") - city: Optional[StrictStr] = Field(default=None, description="City") - state: Optional[StrictStr] = Field(default=None, description="State") - zip: Optional[StrictStr] = Field(default=None, description="Zip code") - foreign_province: Optional[StrictStr] = Field(default=None, description="Foreign province", alias="foreignProvince") - transfer_agent_name: Optional[StrictStr] = Field(default=None, description="Transfer Agent's Name", alias="transferAgentName") - last_filing: Optional[StrictBool] = Field(default=None, description="Last year of filing for this payer", alias="lastFiling") - created_at: Optional[datetime] = Field(default=None, description="Date time when the issuer was created", alias="createdAt") - updated_at: Optional[datetime] = Field(default=None, description="Date time when the issuer was updated", alias="updatedAt") - __properties: ClassVar[List[str]] = [] + id: Optional[StrictStr] = Field(default=None, description="Unique identifier set when the record is created.") + created_at: Optional[datetime] = Field(default=None, description="Date time when the record was created.", alias="createdAt") + updated_at: Optional[datetime] = Field(default=None, description="Date time when the record was last updated.", alias="updatedAt") + name: Optional[StrictStr] = Field(description="Legal name. Not the DBA name.") + dba_name: Optional[StrictStr] = Field(default=None, description="Doing Business As (DBA) name or continuation of a long legal name. Use either this or 'transferAgentName'.", alias="dbaName") + tin: Optional[StrictStr] = Field(default=None, description="Federal Tax Identification Number (TIN).") + reference_id: Optional[StrictStr] = Field(default=None, description="Internal reference ID. Never shown to any agency or recipient. If present, it will prefix download filenames. Allowed characters: letters, numbers, dashes, underscores, and spaces.", alias="referenceId") + telephone: Optional[StrictStr] = Field(description="Contact phone number (must contain at least 10 digits, max 15 characters). For recipient inquiries.") + tax_year: Optional[StrictInt] = Field(description="Tax year for which the forms are being filed (e.g., 2024). Must be within current tax year and current tax year - 4.", alias="taxYear") + country_code: Optional[StrictStr] = Field(default=None, description="Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. If there is a transfer agent, use the transfer agent's shipping address.", alias="countryCode") + email: Optional[StrictStr] = Field(description="Contact email address. For recipient inquiries.") + address: Optional[StrictStr] = Field(description="Address.") + city: Optional[StrictStr] = Field(description="City.") + state: Optional[StrictStr] = Field(description="Two-letter US state or Canadian province code (required for US/CA addresses).") + zip: Optional[StrictStr] = Field(description="ZIP/postal code.") + foreign_province: Optional[StrictStr] = Field(default=None, description="Province or region for non-US/CA addresses.", alias="foreignProvince") + transfer_agent_name: Optional[StrictStr] = Field(default=None, description="Name of the transfer agent, if applicable — optional; use either this or 'dbaName'.", alias="transferAgentName") + last_filing: Optional[StrictBool] = Field(description="Indicates if this is the issuer's final year filing.", alias="lastFiling") + __properties: ClassVar[List[str]] = ["name", "dbaName", "tin", "referenceId", "telephone", "taxYear", "countryCode", "email", "address", "city", "state", "zip", "foreignProvince", "transferAgentName", "lastFiling"] model_config = ConfigDict( populate_by_name=True, @@ -93,14 +93,8 @@ def to_dict(self) -> Dict[str, Any]: * `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. """ excluded_fields: Set[str] = set([ - "id", - "created_at", - "updated_at", ]) _dict = self.model_dump( @@ -108,6 +102,81 @@ 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 dba_name (nullable) is None + # and model_fields_set contains the field + if self.dba_name is None and "dba_name" in self.model_fields_set: + _dict['dbaName'] = 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 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 telephone (nullable) is None + # and model_fields_set contains the field + if self.telephone is None and "telephone" in self.model_fields_set: + _dict['telephone'] = None + + # set to None if tax_year (nullable) is None + # and model_fields_set contains the field + if self.tax_year is None and "tax_year" in self.model_fields_set: + _dict['taxYear'] = 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 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 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 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 foreign_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 + + # set to None if transfer_agent_name (nullable) is None + # and model_fields_set contains the field + if self.transfer_agent_name is None and "transfer_agent_name" in self.model_fields_set: + _dict['transferAgentName'] = None + + # set to None if last_filing (nullable) is None + # and model_fields_set contains the field + if self.last_filing is None and "last_filing" in self.model_fields_set: + _dict['lastFiling'] = None + return _dict @classmethod @@ -120,6 +189,21 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "name": obj.get("name"), + "dbaName": obj.get("dbaName"), + "tin": obj.get("tin"), + "referenceId": obj.get("referenceId"), + "telephone": obj.get("telephone"), + "taxYear": obj.get("taxYear"), + "countryCode": obj.get("countryCode"), + "email": obj.get("email"), + "address": obj.get("address"), + "city": obj.get("city"), + "state": obj.get("state"), + "zip": obj.get("zip"), + "foreignProvince": obj.get("foreignProvince"), + "transferAgentName": obj.get("transferAgentName"), + "lastFiling": obj.get("lastFiling") }) return _obj 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 af1b975..a51ad6b 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/job_response.py b/Avalara/SDK/models/A1099/V2/job_response.py new file mode 100644 index 0000000..f2c04c2 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/job_response.py @@ -0,0 +1,174 @@ +# 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.3 +@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, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.get1099_form200_response import Get1099Form200Response +from typing import Optional, Set +from typing_extensions import Self + +class JobResponse(BaseModel): + """ + Response model for job operations + """ # noqa: E501 + id: Optional[StrictStr] = Field(default=None, description="Unique identifier for the job") + type: Optional[StrictStr] = Field(default=None, description="Job type identifier. Will always be \"update_job\" for bulk upsert operations") + status: Optional[StrictStr] = Field(default=None, description="Current status of the job (e.g., Success, Failed, InProgress)") + error_message: Optional[StrictStr] = Field(default=None, description="Error message if the job failed, null otherwise", alias="errorMessage") + total_processed: Optional[StrictInt] = Field(default=None, description="Total number of forms processed. Value can be 0 or another value based on what the job has available", alias="totalProcessed") + total_rows: Optional[StrictInt] = Field(default=None, description="Total number of forms in the request. Value can be 0 or another value based on what the job has available", alias="totalRows") + updated_valid: Optional[StrictInt] = Field(default=None, description="Number of forms updated and valid for e-filing and e-delivery. Value can be 0 or another value based on what the job has available", alias="updatedValid") + updated_no_email: Optional[StrictInt] = Field(default=None, description="Number of forms updated and valid for e-filing but missing email or email is undeliverable. Value can be 0 or another value based on what the job has available", alias="updatedNoEmail") + updated_invalid: Optional[StrictInt] = Field(default=None, description="Number of forms updated but invalid for e-filing. Value can be 0 or another value based on what the job has available", alias="updatedInvalid") + skipped_duplicate: Optional[StrictInt] = Field(default=None, description="Number of forms skipped because they would have updated a record already updated once in the request. Value can be 0 or another value based on what the job has available", alias="skippedDuplicate") + skipped_invalid: Optional[StrictInt] = Field(default=None, description="Number of forms skipped because they would have made a form invalid and the form is already e-filed or scheduled for e-filing. Value can be 0 or another value based on what the job has available", alias="skippedInvalid") + skipped_multiple_matches: Optional[StrictInt] = Field(default=None, description="Number of forms skipped because they matched multiple forms. Value can be 0 or another value based on what the job has available", alias="skippedMultipleMatches") + not_found: Optional[StrictInt] = Field(default=None, description="Number of forms skipped because no matching form or issuer could be found. Value can be 0 or another value based on what the job has available", alias="notFound") + created_invalid: Optional[StrictInt] = Field(default=None, description="Number of new forms created because no matching form could be found (and `upsert` was true) - with errors. Value can be 0 or another value based on what the job has available", alias="createdInvalid") + created_no_email: Optional[StrictInt] = Field(default=None, description="Number of new forms created because no matching form could be found (and `upsert` was true) - valid for e-filing but missing email or email is undeliverable. Value can be 0 or another value based on what the job has available", alias="createdNoEmail") + created_valid: Optional[StrictInt] = Field(default=None, description="Number of new forms created because no matching form could be found (and `upsert` was true) - valid for e-filing and e-delivery. Value can be 0 or another value based on what the job has available", alias="createdValid") + dry_run: Optional[StrictBool] = Field(default=None, description="Dry run. If `true`, this job only simulates the changes but doesn't actually persist them.", alias="dryRun") + upsert: Optional[StrictBool] = Field(default=None, description="Upsert. If `true`, this job will first attempt to update existing records if matches can be found. Matches are done in the following order: Form ID, Form Reference ID and tax year, Form TIN and tax year.") + link: Optional[StrictStr] = Field(default=None, description="Link to access the job details") + processed_forms: Optional[List[Get1099Form200Response]] = Field(default=None, description="List of processed forms returned when bulk-upsert processes ≤1000 records. Same format as GET /1099/forms response. Only available in bulk-upsert endpoint responses.", alias="processedForms") + __properties: ClassVar[List[str]] = ["id", "type", "status", "errorMessage", "totalProcessed", "totalRows", "updatedValid", "updatedNoEmail", "updatedInvalid", "skippedDuplicate", "skippedInvalid", "skippedMultipleMatches", "notFound", "createdInvalid", "createdNoEmail", "createdValid", "dryRun", "upsert", "link", "processedForms"] + + @field_validator('status') + def status_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['InProgress', 'Success', 'Failed']): + raise ValueError("must be one of enum values ('InProgress', 'Success', 'Failed')") + 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 JobResponse 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 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 error_message (nullable) is None + # and model_fields_set contains the field + if self.error_message is None and "error_message" in self.model_fields_set: + _dict['errorMessage'] = None + + # set to None if link (nullable) is None + # and model_fields_set contains the field + if self.link is None and "link" in self.model_fields_set: + _dict['link'] = None + + # 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 + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of JobResponse 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"), + "status": obj.get("status"), + "errorMessage": obj.get("errorMessage"), + "totalProcessed": obj.get("totalProcessed"), + "totalRows": obj.get("totalRows"), + "updatedValid": obj.get("updatedValid"), + "updatedNoEmail": obj.get("updatedNoEmail"), + "updatedInvalid": obj.get("updatedInvalid"), + "skippedDuplicate": obj.get("skippedDuplicate"), + "skippedInvalid": obj.get("skippedInvalid"), + "skippedMultipleMatches": obj.get("skippedMultipleMatches"), + "notFound": obj.get("notFound"), + "createdInvalid": obj.get("createdInvalid"), + "createdNoEmail": obj.get("createdNoEmail"), + "createdValid": obj.get("createdValid"), + "dryRun": obj.get("dryRun"), + "upsert": obj.get("upsert"), + "link": obj.get("link"), + "processedForms": [Get1099Form200Response.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/offer_and_coverage.py b/Avalara/SDK/models/A1099/V2/offer_and_coverage.py new file mode 100644 index 0000000..7e1a39c --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/offer_and_coverage.py @@ -0,0 +1,175 @@ +# 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.3 +@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, StrictFloat, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing import Optional, Set +from typing_extensions import Self + +class OfferAndCoverage(BaseModel): + """ + Offer and coverage information for health coverage forms + """ # noqa: E501 + id: Optional[StrictInt] = Field(default=None, description="Id") + month: Optional[StrictStr] = Field(default=None, description="Month of coverage. Available values: - All: All months - January: January - February: February - March: March - April: April - May: May - June: June - July: July - August: August - September: September - October: October - November: November - December: December") + offer_code: Optional[StrictStr] = Field(default=None, description="Offer of Coverage Code. Required if Share has a value, including zero. Available values: Pre-ICHRA Codes (available before 2020): - 1A: Qualifying offer: minimum essential coverage providing minimum value offered to full-time employee with employee required contribution ≤ 9.5% (as adjusted) of mainland single federal poverty line and at least minimum essential coverage offered to spouse and dependent(s) - 1B: Minimum essential coverage providing minimum value offered to employee only - 1C: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to dependent(s) (not spouse) - 1D: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to spouse (not dependent(s)) - 1E: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to dependent(s) and spouse - 1F: Minimum essential coverage NOT providing minimum value offered to employee; employee and spouse or dependent(s); or employee, spouse, and dependents - 1G: Offer of coverage to an individual who was not an employee or not a full-time employee and who enrolled in self-insured coverage - 1H: No offer of coverage (employee not offered any health coverage or employee offered coverage that is not minimum essential coverage) - 1J: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage conditionally offered to spouse; minimum essential coverage not offered to dependent(s) - 1K: Minimum essential coverage providing minimum value offered to employee; at least minimum essential coverage offered to dependents; and at least minimum essential coverage conditionally offered to spouse ICHRA Codes (introduced 2020, require ZIP code): - 1L: Individual coverage HRA offered to employee only - 1M: Individual coverage HRA offered to employee and dependent(s) (not spouse) - 1N: Individual coverage HRA offered to employee, spouse, and dependent(s) - 1O: Individual coverage HRA offered to employee only using employment site ZIP code affordability safe harbor - 1P: Individual coverage HRA offered to employee and dependent(s) (not spouse) using employment site ZIP code affordability safe harbor - 1Q: Individual coverage HRA offered to employee, spouse, and dependent(s) using employment site ZIP code affordability safe harbor - 1R: Individual coverage HRA that is NOT affordable - 1S: Individual coverage HRA offered to an individual who was not a full-time employee - 1T: Individual coverage HRA offered to employee and spouse (not dependents) - 1U: Individual coverage HRA offered to employee and spouse (not dependents) using employment site ZIP code affordability safe harbor Note: Codes 1B, 1C, 1D, 1E, 1J, 1K, 1L, 1M, 1N, 1O, 1P, 1Q, 1T, 1U require employee share amount (0.00 is a valid value).", alias="offerCode") + share: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Employee required contribution share - Employee Share of Lowest Cost Monthly Premium, for Self-Only Minimum Value Coverage - May not exceed 3499.99") + safe_harbor_code: Optional[StrictStr] = Field(default=None, description="Safe harbor code - Applicable Section 4980H Safe Harbor Code. Available values: - 2A: Form W-2 safe harbor - 2B: Federal poverty line safe harbor - 2C: Rate of pay safe harbor - 2D: Part-time employee safe harbor for employees who were not full-time for any month of the year - 2E: Multiemployer interim rule relief - 2F: Qualifying offer method - 2G: Qualifying offer transition relief - 2H: Other affordability safe harbor", alias="safeHarborCode") + zip_code: Optional[StrictStr] = Field(default=None, description="ZIP/postal code. For coverage area (optional, unless codes 1L to 1U are used).", alias="zipCode") + __properties: ClassVar[List[str]] = ["id", "month", "offerCode", "share", "safeHarborCode", "zipCode"] + + @field_validator('month') + def month_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['All', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12']): + raise ValueError("must be one of enum values ('All', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12')") + return value + + @field_validator('offer_code') + def offer_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['1A', '1B', '1C', '1D', '1E', '1F', '1G', '1H', '1J', '1K', '1L', '1M', '1N', '1O', '1P', '1Q', '1R', '1S', '1T', '1U']): + raise ValueError("must be one of enum values ('1A', '1B', '1C', '1D', '1E', '1F', '1G', '1H', '1J', '1K', '1L', '1M', '1N', '1O', '1P', '1Q', '1R', '1S', '1T', '1U')") + return value + + @field_validator('safe_harbor_code') + def safe_harbor_code_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['2A', '2B', '2C', '2D', '2E', '2F', '2G', '2H']): + raise ValueError("must be one of enum values ('2A', '2B', '2C', '2D', '2E', '2F', '2G', '2H')") + 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 OfferAndCoverage 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([ + "id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = None + + # set to None if month (nullable) is None + # and model_fields_set contains the field + if self.month is None and "month" in self.model_fields_set: + _dict['month'] = None + + # set to None if offer_code (nullable) is None + # and model_fields_set contains the field + if self.offer_code is None and "offer_code" in self.model_fields_set: + _dict['offerCode'] = None + + # set to None if share (nullable) is None + # and model_fields_set contains the field + if self.share is None and "share" in self.model_fields_set: + _dict['share'] = None + + # set to None if safe_harbor_code (nullable) is None + # and model_fields_set contains the field + if self.safe_harbor_code is None and "safe_harbor_code" in self.model_fields_set: + _dict['safeHarborCode'] = None + + # set to None if zip_code (nullable) is None + # and model_fields_set contains the field + if self.zip_code is None and "zip_code" in self.model_fields_set: + _dict['zipCode'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OfferAndCoverage 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"), + "month": obj.get("month"), + "offerCode": obj.get("offerCode"), + "share": obj.get("share"), + "safeHarborCode": obj.get("safeHarborCode"), + "zipCode": obj.get("zipCode") + }) + return _obj + + 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 605b108..0ad3df1 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/paginated_query_result_model_form1099_base.py b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_form1099_base.py new file mode 100644 index 0000000..4238313 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_form1099_base.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.3 +@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.get1099_form200_response import Get1099Form200Response +from typing import Optional, Set +from typing_extensions import Self + +class PaginatedQueryResultModelForm1099Base(BaseModel): + """ + Generic paginated model to wrap query response data + """ # noqa: E501 + recordset_count: Optional[StrictInt] = Field(default=None, alias="@recordsetCount") + value: Optional[List[Get1099Form200Response]] = 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 PaginatedQueryResultModelForm1099Base 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 PaginatedQueryResultModelForm1099Base 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": [Get1099Form200Response.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_query_result_model_issuer_response.py b/Avalara/SDK/models/A1099/V2/paginated_query_result_model_issuer_response.py index b355b70..ca901c2 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.2 +@version 25.8.3 @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 index 9574660..7b0ea4e 100644 --- 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 @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ 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 157794d..a4e9db9 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.A1099.V2.iw9_form_data_models_one_of import IW9FormDataModelsOneOf +from Avalara.SDK.models.A1099.V2.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 34c89ee..dde593a 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -40,11 +40,11 @@ class PrimaryWithholdingAgent(BaseModel): """ - PrimaryWithholdingAgent + Primary withholding agent information for tax forms """ # noqa: E501 - primary_withholding_agent_name: Optional[StrictStr] = Field(default=None, alias="primaryWithholdingAgentName") - primary_withholding_agent_ein: Optional[StrictStr] = Field(default=None, alias="primaryWithholdingAgentEin") - __properties: ClassVar[List[str]] = ["primaryWithholdingAgentName", "primaryWithholdingAgentEin"] + name: Optional[StrictStr] = Field(description="Name of the primary withholding agent") + ein: Optional[StrictStr] = Field(description="EIN (Employer Identification Number) of the primary withholding agent.") + __properties: ClassVar[List[str]] = ["name", "ein"] model_config = ConfigDict( populate_by_name=True, @@ -85,15 +85,15 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if primary_withholding_agent_name (nullable) is None + # set to None if name (nullable) is None # and model_fields_set contains the field - if self.primary_withholding_agent_name is None and "primary_withholding_agent_name" in self.model_fields_set: - _dict['primaryWithholdingAgentName'] = None + if self.name is None and "name" in self.model_fields_set: + _dict['name'] = None - # set to None if primary_withholding_agent_ein (nullable) is None + # set to None if ein (nullable) is None # and model_fields_set contains the field - if self.primary_withholding_agent_ein is None and "primary_withholding_agent_ein" in self.model_fields_set: - _dict['primaryWithholdingAgentEin'] = None + if self.ein is None and "ein" in self.model_fields_set: + _dict['ein'] = None return _dict @@ -107,8 +107,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ - "primaryWithholdingAgentName": obj.get("primaryWithholdingAgentName"), - "primaryWithholdingAgentEin": obj.get("primaryWithholdingAgentEin") + "name": obj.get("name"), + "ein": obj.get("ein") }) return _obj 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 6eb3749..5041899 100644 --- a/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py +++ b/Avalara/SDK/models/A1099/V2/state_and_local_withholding.py @@ -24,7 +24,7 @@ @author Jonathan Wenger @copyright 2022 Avalara, Inc. @license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.8.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -42,14 +42,14 @@ class StateAndLocalWithholding(BaseModel): """ StateAndLocalWithholding """ # noqa: E501 - state_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="stateTaxWithheld") - state: Optional[StrictStr] = None - state_id_number: Optional[StrictStr] = Field(default=None, alias="stateIdNumber") - state_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="stateIncome") - local_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="localTaxWithheld") - locality: Optional[StrictStr] = None - locality_id_number: Optional[StrictStr] = Field(default=None, alias="localityIdNumber") - local_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="localIncome") + state_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount of state tax that was withheld", alias="stateTaxWithheld") + state: Optional[StrictStr] = Field(default=None, description="US state") + state_id_number: Optional[StrictStr] = Field(default=None, description="State ID number of the entity issuing the form", alias="stateIdNumber") + state_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount of state income", alias="stateIncome") + local_tax_withheld: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount of local tax that was withheld", alias="localTaxWithheld") + locality: Optional[StrictStr] = Field(default=None, description="Locality name") + locality_id_number: Optional[StrictStr] = Field(default=None, description="Locality ID number of the entity issuing the form", alias="localityIdNumber") + local_income: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Amount of local income", alias="localIncome") __properties: ClassVar[List[str]] = ["stateTaxWithheld", "state", "stateIdNumber", "stateIncome", "localTaxWithheld", "locality", "localityIdNumber", "localIncome"] model_config = ConfigDict( 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 7081a2e..f16a664 100644 --- a/Avalara/SDK/models/A1099/V2/state_efile_status_detail.py +++ b/Avalara/SDK/models/A1099/V2/state_efile_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.2 +@version 25.8.3 @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 ae79e0c..20326dd 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.2 +@version 25.8.3 @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 6022072..9a9c5ec 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.2 +@version 25.8.3 @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 a6f96a1..d5e098c 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.2 +@version 25.8.3 @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 02b82cf..34ce896 100644 --- a/Avalara/SDK/models/A1099/V2/update1099_form200_response.py +++ b/Avalara/SDK/models/A1099/V2/update1099_form200_response.py @@ -33,15 +33,15 @@ 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_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 Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_response import Form1042SResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_response import Form1095BResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_response import Form1099DivResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_response import Form1099IntResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_response import Form1099KResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_response import Form1099MiscResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_response import Form1099NecResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_response import Form1099RResponse +from Avalara.SDK.models.A1099.V2.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 diff --git a/Avalara/SDK/models/A1099/V2/validation_error.py b/Avalara/SDK/models/A1099/V2/validation_error.py index bdd2f96..64079ea 100644 --- a/Avalara/SDK/models/A1099/V2/validation_error.py +++ b/Avalara/SDK/models/A1099/V2/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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -42,8 +42,8 @@ class ValidationError(BaseModel): """ ValidationError """ # noqa: E501 - var_field: Optional[StrictStr] = Field(default=None, alias="field") - errors: Optional[List[StrictStr]] = None + var_field: Optional[StrictStr] = Field(default=None, description="The field containing the error", alias="field") + errors: Optional[List[StrictStr]] = Field(default=None, description="The list of error messages") __properties: ClassVar[List[str]] = ["field", "errors"] model_config = ConfigDict( 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 9443b0b..a4c10bb 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w4_form_minimal_request.py b/Avalara/SDK/models/A1099/V2/w4_form_minimal_request.py new file mode 100644 index 0000000..4f8e970 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w4_form_minimal_request.py @@ -0,0 +1,135 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W4FormMinimalRequest(BaseModel): + """ + W4FormMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type (always \"w4\" for this model).") + email: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The email address of the individual associated with the form.") + employee_first_name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The first name of the employee.", alias="employeeFirstName") + employee_last_name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The last name of the employee.", alias="employeeLastName") + office_code: Optional[StrictStr] = Field(default=None, description="The office code associated with the form.", alias="officeCode") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W4FormMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W4FormMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/w4_form_request.py b/Avalara/SDK/models/A1099/V2/w4_form_request.py index 0a748f6..1cd2704 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ 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 typing import Optional, Set from typing_extensions import Self @@ -63,12 +64,12 @@ class W4FormRequest(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") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["eDeliveryConsentedAt", "signature", "type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -121,16 +122,6 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # 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 e_delivery_consented_at (nullable) is None # and model_fields_set contains the field if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: @@ -141,6 +132,16 @@ def to_dict(self) -> Dict[str, Any]: if self.signature is None and "signature" in self.model_fields_set: _dict['signature'] = 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 + return _dict @classmethod @@ -153,12 +154,12 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), + "signature": obj.get("signature"), "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w4_form_response.py b/Avalara/SDK/models/A1099/V2/w4_form_response.py index d5d9b13..73277f7 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,6 +35,7 @@ from pydantic import ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.entry_status_response import EntryStatusResponse from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self @@ -62,7 +63,7 @@ class W4FormResponse(W9FormBaseResponse): 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") - __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "referenceId", "companyId", "displayName", "email", "archived", "ancestorId", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -103,11 +104,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if entry_status_date (nullable) is None - # and model_fields_set contains the field - if self.entry_status_date is None and "entry_status_date" in self.model_fields_set: - _dict['entryStatusDate'] = None - + # override the default output from pydantic by calling `to_dict()` of entry_status + if self.entry_status: + _dict['entryStatus'] = self.entry_status.to_dict() # 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: @@ -118,6 +117,11 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None + # set to None if ancestor_id (nullable) is None + # and model_fields_set contains the field + if self.ancestor_id is None and "ancestor_id" in self.model_fields_set: + _dict['ancestorId'] = None + # set to None if signature (nullable) is None # and model_fields_set contains the field if self.signature is None and "signature" in self.model_fields_set: @@ -146,13 +150,13 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "entryStatus": obj.get("entryStatus"), - "entryStatusDate": obj.get("entryStatusDate"), + "entryStatus": EntryStatusResponse.from_dict(obj["entryStatus"]) if obj.get("entryStatus") is not None else None, "referenceId": obj.get("referenceId"), "companyId": obj.get("companyId"), "displayName": obj.get("displayName"), "email": obj.get("email"), "archived": obj.get("archived"), + "ancestorId": obj.get("ancestorId"), "signature": obj.get("signature"), "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_e_form_minimal_request.py b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_minimal_request.py new file mode 100644 index 0000000..3395584 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w8_ben_e_form_minimal_request.py @@ -0,0 +1,134 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W8BenEFormMinimalRequest(BaseModel): + """ + W8BenEFormMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type (always \"w8bene\" for this model).") + email: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The email address of the individual associated with the form.") + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The name of the individual or entity associated with the form.") + reference_number: Optional[StrictStr] = Field(default=None, description="A reference number for the form.", alias="referenceNumber") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W8BenEFormMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W8BenEFormMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + 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 e4ddcde..8c65314 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ from datetime import date, 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.substantial_us_owner_request import SubstantialUsOwnerRequest from typing import Optional, Set from typing_extensions import Self @@ -140,12 +141,12 @@ class W8BenEFormRequest(BaseModel): substantial_us_owners: Optional[List[SubstantialUsOwnerRequest]] = 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") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["eDeliveryConsentedAt", "signature", "type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -198,16 +199,6 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # 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 e_delivery_consented_at (nullable) is None # and model_fields_set contains the field if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: @@ -218,6 +209,16 @@ def to_dict(self) -> Dict[str, Any]: if self.signature is None and "signature" in self.model_fields_set: _dict['signature'] = 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 + return _dict @classmethod @@ -230,12 +231,12 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), + "signature": obj.get("signature"), "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj 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 dc6cb20..ebe1dab 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ 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.entry_status_response import EntryStatusResponse 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 @@ -141,7 +142,7 @@ class W8BenEFormResponse(W9FormBaseResponse): 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") - __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "referenceId", "companyId", "displayName", "email", "archived", "ancestorId", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -182,11 +183,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if entry_status_date (nullable) is None - # and model_fields_set contains the field - if self.entry_status_date is None and "entry_status_date" in self.model_fields_set: - _dict['entryStatusDate'] = None - + # override the default output from pydantic by calling `to_dict()` of entry_status + if self.entry_status: + _dict['entryStatus'] = self.entry_status.to_dict() # 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: @@ -197,6 +196,11 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None + # set to None if ancestor_id (nullable) is None + # and model_fields_set contains the field + if self.ancestor_id is None and "ancestor_id" in self.model_fields_set: + _dict['ancestorId'] = None + # set to None if signature (nullable) is None # and model_fields_set contains the field if self.signature is None and "signature" in self.model_fields_set: @@ -225,13 +229,13 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "entryStatus": obj.get("entryStatus"), - "entryStatusDate": obj.get("entryStatusDate"), + "entryStatus": EntryStatusResponse.from_dict(obj["entryStatus"]) if obj.get("entryStatus") is not None else None, "referenceId": obj.get("referenceId"), "companyId": obj.get("companyId"), "displayName": obj.get("displayName"), "email": obj.get("email"), "archived": obj.get("archived"), + "ancestorId": obj.get("ancestorId"), "signature": obj.get("signature"), "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), 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 9a7f223..250ba51 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.2 +@version 25.8.3 @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 d34af21..84f65dc 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_ben_form_minimal_request.py b/Avalara/SDK/models/A1099/V2/w8_ben_form_minimal_request.py new file mode 100644 index 0000000..9c01d58 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w8_ben_form_minimal_request.py @@ -0,0 +1,134 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W8BenFormMinimalRequest(BaseModel): + """ + W8BenFormMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type (always \"w8ben\" for this model).") + email: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The email address of the individual associated with the form.") + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The name of the individual or entity associated with the form.") + reference_number: Optional[StrictStr] = Field(default=None, description="A reference number for the form.", alias="referenceNumber") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W8BenFormMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W8BenFormMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + return _obj + + 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 1f394b0..240a865 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ from datetime import date, 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 typing import Optional, Set from typing_extensions import Self @@ -68,12 +69,12 @@ class W8BenFormRequest(BaseModel): withholding_rate: Optional[StrictStr] = Field(default=None, description="The withholding rate applied as per the treaty.", alias="withholdingRate") 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") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["eDeliveryConsentedAt", "signature", "type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -126,16 +127,6 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # 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 e_delivery_consented_at (nullable) is None # and model_fields_set contains the field if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: @@ -146,6 +137,16 @@ def to_dict(self) -> Dict[str, Any]: if self.signature is None and "signature" in self.model_fields_set: _dict['signature'] = 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 + return _dict @classmethod @@ -158,12 +159,12 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), + "signature": obj.get("signature"), "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj 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 bbf3074..be5b77d 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ 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.entry_status_response import EntryStatusResponse from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self @@ -70,7 +71,7 @@ class W8BenFormResponse(W9FormBaseResponse): 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") - __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "referenceId", "companyId", "displayName", "email", "archived", "ancestorId", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -111,11 +112,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if entry_status_date (nullable) is None - # and model_fields_set contains the field - if self.entry_status_date is None and "entry_status_date" in self.model_fields_set: - _dict['entryStatusDate'] = None - + # override the default output from pydantic by calling `to_dict()` of entry_status + if self.entry_status: + _dict['entryStatus'] = self.entry_status.to_dict() # 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: @@ -126,6 +125,11 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None + # set to None if ancestor_id (nullable) is None + # and model_fields_set contains the field + if self.ancestor_id is None and "ancestor_id" in self.model_fields_set: + _dict['ancestorId'] = None + # set to None if signature (nullable) is None # and model_fields_set contains the field if self.signature is None and "signature" in self.model_fields_set: @@ -154,13 +158,13 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "entryStatus": obj.get("entryStatus"), - "entryStatusDate": obj.get("entryStatusDate"), + "entryStatus": EntryStatusResponse.from_dict(obj["entryStatus"]) if obj.get("entryStatus") is not None else None, "referenceId": obj.get("referenceId"), "companyId": obj.get("companyId"), "displayName": obj.get("displayName"), "email": obj.get("email"), "archived": obj.get("archived"), + "ancestorId": obj.get("ancestorId"), "signature": obj.get("signature"), "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), 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 f1397fe..583454a 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.2 +@version 25.8.3 @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 c0947f1..b755038 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w8_imy_form_minimal_request.py b/Avalara/SDK/models/A1099/V2/w8_imy_form_minimal_request.py new file mode 100644 index 0000000..e5389dd --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w8_imy_form_minimal_request.py @@ -0,0 +1,134 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W8ImyFormMinimalRequest(BaseModel): + """ + W8ImyFormMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type (always \"w8imy\" for this model).") + email: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The email address of the individual associated with the form.") + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The name of the individual or entity associated with the form.") + reference_number: Optional[StrictStr] = Field(default=None, description="A reference number for the form.", alias="referenceNumber") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W8ImyFormMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W8ImyFormMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + return _obj + + 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 3561222..c934ec8 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ from datetime import date, 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 typing import Optional, Set from typing_extensions import Self @@ -155,12 +156,12 @@ class W8ImyFormRequest(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") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["eDeliveryConsentedAt", "signature", "type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -213,16 +214,6 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # 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 e_delivery_consented_at (nullable) is None # and model_fields_set contains the field if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: @@ -233,6 +224,16 @@ def to_dict(self) -> Dict[str, Any]: if self.signature is None and "signature" in self.model_fields_set: _dict['signature'] = 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 + return _dict @classmethod @@ -245,12 +246,12 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), + "signature": obj.get("signature"), "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj 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 1482837..5b4a6b0 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ 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.entry_status_response import EntryStatusResponse from Avalara.SDK.models.A1099.V2.w9_form_base_response import W9FormBaseResponse from typing import Optional, Set from typing_extensions import Self @@ -155,7 +156,7 @@ class W8ImyFormResponse(W9FormBaseResponse): 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") - __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "referenceId", "companyId", "displayName", "email", "archived", "ancestorId", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -196,11 +197,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if entry_status_date (nullable) is None - # and model_fields_set contains the field - if self.entry_status_date is None and "entry_status_date" in self.model_fields_set: - _dict['entryStatusDate'] = None - + # override the default output from pydantic by calling `to_dict()` of entry_status + if self.entry_status: + _dict['entryStatus'] = self.entry_status.to_dict() # 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: @@ -211,6 +210,11 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None + # set to None if ancestor_id (nullable) is None + # and model_fields_set contains the field + if self.ancestor_id is None and "ancestor_id" in self.model_fields_set: + _dict['ancestorId'] = None + # set to None if signature (nullable) is None # and model_fields_set contains the field if self.signature is None and "signature" in self.model_fields_set: @@ -239,13 +243,13 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "entryStatus": obj.get("entryStatus"), - "entryStatusDate": obj.get("entryStatusDate"), + "entryStatus": EntryStatusResponse.from_dict(obj["entryStatus"]) if obj.get("entryStatus") is not None else None, "referenceId": obj.get("referenceId"), "companyId": obj.get("companyId"), "displayName": obj.get("displayName"), "email": obj.get("email"), "archived": obj.get("archived"), + "ancestorId": obj.get("ancestorId"), "signature": obj.get("signature"), "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), diff --git a/Avalara/SDK/models/A1099/V2/w9_form_base_minimal_request.py b/Avalara/SDK/models/A1099/V2/w9_form_base_minimal_request.py new file mode 100644 index 0000000..8ab0da7 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w9_form_base_minimal_request.py @@ -0,0 +1,132 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W9FormBaseMinimalRequest(BaseModel): + """ + W9FormBaseMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type.") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W9FormBaseMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W9FormBaseMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + 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 514686b..0c24def 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated from typing import Optional, Set from typing_extensions import Self @@ -43,13 +44,13 @@ class W9FormBaseRequest(BaseModel): """ W9FormBaseRequest """ # noqa: E501 + e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") + signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") type: Optional[StrictStr] = Field(default=None, description="The form type.") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") - e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") - signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -112,16 +113,6 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None - # set to None if e_delivery_consented_at (nullable) is None - # and model_fields_set contains the field - if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: - _dict['eDeliveryConsentedAt'] = None - - # set to None if signature (nullable) is None - # and model_fields_set contains the field - if self.signature is None and "signature" in self.model_fields_set: - _dict['signature'] = None - return _dict @classmethod @@ -137,9 +128,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj 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 eef8159..c936dd8 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -37,6 +37,7 @@ from importlib import import_module from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional, Union +from Avalara.SDK.models.A1099.V2.entry_status_response import EntryStatusResponse from typing import Optional, Set from typing_extensions import Self @@ -53,13 +54,13 @@ class W9FormBaseResponse(BaseModel): W9FormBaseResponse """ # noqa: E501 id: Optional[StrictStr] = Field(default=None, description="The unique identifier for the form.") - 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") + entry_status: Optional[EntryStatusResponse] = Field(default=None, description="The entry status information for the form.", alias="entryStatus") 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.") + ancestor_id: Optional[StrictStr] = Field(default=None, description="Form ID of previous version.", alias="ancestorId") 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") 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 2eb0dc8..5b2adf7 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/Avalara/SDK/models/A1099/V2/w9_form_minimal_request.py b/Avalara/SDK/models/A1099/V2/w9_form_minimal_request.py new file mode 100644 index 0000000..d1eb9f4 --- /dev/null +++ b/Avalara/SDK/models/A1099/V2/w9_form_minimal_request.py @@ -0,0 +1,134 @@ +# 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.3 +@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, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class W9FormMinimalRequest(BaseModel): + """ + W9FormMinimalRequest + """ # noqa: E501 + type: Optional[StrictStr] = Field(default=None, description="The form type (always \"w9\" for this model).") + email: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The email address of the individual associated with the form.") + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The name of the individual or entity associated with the form.") + account_number: Optional[StrictStr] = Field(default=None, description="The account number associated with the form.", alias="accountNumber") + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email"] + + @field_validator('type') + def type_validate_enum(cls, value): + """Validates the enum""" + if value is None: + return value + + if value not in set(['W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9']): + raise ValueError("must be one of enum values ('W4', 'W8Ben', 'W8BenE', 'W8Imy', 'W9')") + 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 W9FormMinimalRequest 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, + ) + # 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 + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of W9FormMinimalRequest 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"), + "companyId": obj.get("companyId"), + "referenceId": obj.get("referenceId"), + "email": obj.get("email") + }) + return _obj + + diff --git a/Avalara/SDK/models/A1099/V2/w9_form_request.py b/Avalara/SDK/models/A1099/V2/w9_form_request.py index e5fdb55..7198ec5 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -36,6 +36,7 @@ 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 typing import Optional, Set from typing_extensions import Self @@ -62,12 +63,12 @@ class W9FormRequest(BaseModel): tin: Optional[StrictStr] = Field(default=None, description="The taxpayer identification number (TIN).") 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.") - company_id: Optional[StrictStr] = Field(default=None, description="The ID of the associated company.", alias="companyId") - reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") - email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") e_delivery_consented_at: Optional[datetime] = Field(default=None, description="The date when e-delivery was consented.", alias="eDeliveryConsentedAt") signature: Optional[StrictStr] = Field(default=None, description="The signature of the form.") - __properties: ClassVar[List[str]] = ["type", "companyId", "referenceId", "email", "eDeliveryConsentedAt", "signature"] + company_id: Annotated[str, Field(min_length=1, strict=True)] = Field(description="The ID of the associated company.", alias="companyId") + reference_id: Optional[StrictStr] = Field(default=None, description="A reference identifier for the form.", alias="referenceId") + email: Optional[StrictStr] = Field(default=None, description="The email address of the individual associated with the form.") + __properties: ClassVar[List[str]] = ["eDeliveryConsentedAt", "signature", "type", "companyId", "referenceId", "email"] @field_validator('type') def type_validate_enum(cls, value): @@ -120,16 +121,6 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # 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 e_delivery_consented_at (nullable) is None # and model_fields_set contains the field if self.e_delivery_consented_at is None and "e_delivery_consented_at" in self.model_fields_set: @@ -140,6 +131,16 @@ def to_dict(self) -> Dict[str, Any]: if self.signature is None and "signature" in self.model_fields_set: _dict['signature'] = 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 + return _dict @classmethod @@ -152,12 +153,12 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), + "signature": obj.get("signature"), "type": obj.get("type"), "companyId": obj.get("companyId"), "referenceId": obj.get("referenceId"), - "email": obj.get("email"), - "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), - "signature": obj.get("signature") + "email": obj.get("email") }) return _obj diff --git a/Avalara/SDK/models/A1099/V2/w9_form_response.py b/Avalara/SDK/models/A1099/V2/w9_form_response.py index a08f43d..f668d47 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ @@ -35,6 +35,7 @@ from pydantic import ConfigDict, Field, StrictBool, StrictStr from typing import Any, ClassVar, Dict, List, Optional +from Avalara.SDK.models.A1099.V2.entry_status_response import EntryStatusResponse 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 @@ -63,7 +64,7 @@ class W9FormResponse(W9FormBaseResponse): 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") - __properties: ClassVar[List[str]] = ["id", "entryStatus", "entryStatusDate", "referenceId", "companyId", "displayName", "email", "archived", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] + __properties: ClassVar[List[str]] = ["id", "entryStatus", "referenceId", "companyId", "displayName", "email", "archived", "ancestorId", "signature", "signedDate", "eDeliveryConsentedAt", "createdAt", "updatedAt", "type"] model_config = ConfigDict( populate_by_name=True, @@ -104,11 +105,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) - # set to None if entry_status_date (nullable) is None - # and model_fields_set contains the field - if self.entry_status_date is None and "entry_status_date" in self.model_fields_set: - _dict['entryStatusDate'] = None - + # override the default output from pydantic by calling `to_dict()` of entry_status + if self.entry_status: + _dict['entryStatus'] = self.entry_status.to_dict() # 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: @@ -119,6 +118,11 @@ def to_dict(self) -> Dict[str, Any]: if self.email is None and "email" in self.model_fields_set: _dict['email'] = None + # set to None if ancestor_id (nullable) is None + # and model_fields_set contains the field + if self.ancestor_id is None and "ancestor_id" in self.model_fields_set: + _dict['ancestorId'] = None + # set to None if signature (nullable) is None # and model_fields_set contains the field if self.signature is None and "signature" in self.model_fields_set: @@ -147,13 +151,13 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: _obj = cls.model_validate({ "id": obj.get("id"), - "entryStatus": obj.get("entryStatus"), - "entryStatusDate": obj.get("entryStatusDate"), + "entryStatus": EntryStatusResponse.from_dict(obj["entryStatus"]) if obj.get("entryStatus") is not None else None, "referenceId": obj.get("referenceId"), "companyId": obj.get("companyId"), "displayName": obj.get("displayName"), "email": obj.get("email"), "archived": obj.get("archived"), + "ancestorId": obj.get("ancestorId"), "signature": obj.get("signature"), "signedDate": obj.get("signedDate"), "eDeliveryConsentedAt": obj.get("eDeliveryConsentedAt"), diff --git a/Avalara/SDK/models/EInvoicing/V1/address.py b/Avalara/SDK/models/EInvoicing/V1/address.py index b1e7643..6f943c5 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.2 +@version 25.8.3 @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 fcceab4..69c918c 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.2 +@version 25.8.3 @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 4cb4f7b..1e2dfc3 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.2 +@version 25.8.3 @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 b282386..67dd585 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.2 +@version 25.8.3 @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 04097ed..98a89f4 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.2 +@version 25.8.3 @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 3a342c1..11b9909 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.2 +@version 25.8.3 @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 1d3a8fa..20a2d0a 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.2 +@version 25.8.3 @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 cab1a1d..cf1f89f 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.2 +@version 25.8.3 @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 3f6fa5c..b5c31d0 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.2 +@version 25.8.3 @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 7503ba6..e5bc256 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.2 +@version 25.8.3 @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 12bfbce..c5a56c3 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.2 +@version 25.8.3 @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 cf2038b..ae52f9c 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.2 +@version 25.8.3 @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 8d90f1d..51772c2 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.2 +@version 25.8.3 @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 dba2491..7625564 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.2 +@version 25.8.3 @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 1c250ef..5d97fea 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.2 +@version 25.8.3 @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 c8e6c18..4e6b96a 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.2 +@version 25.8.3 @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 b0814cc..a7d92cc 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.2 +@version 25.8.3 @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 7364a09..af9d268 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.2 +@version 25.8.3 @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 e32d8b9..3fe6bf8 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.2 +@version 25.8.3 @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 ee8faa7..86f52e7 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.2 +@version 25.8.3 @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 f4c07d9..ccb90c5 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.2 +@version 25.8.3 @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 7cc405d..54b9693 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.2 +@version 25.8.3 @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 d7a2f2e..382c0c7 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.2 +@version 25.8.3 @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 c5c0602..6866eb4 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.2 +@version 25.8.3 @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 94700e9..803b35b 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.2 +@version 25.8.3 @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 caa0d76..c9add87 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.2 +@version 25.8.3 @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 dd2aa71..b1c8c24 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.2 +@version 25.8.3 @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 deba433..9e52dc0 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.2 +@version 25.8.3 @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 403a857..54a385f 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.2 +@version 25.8.3 @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 27b84d6..7c74180 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.2 +@version 25.8.3 @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 338db83..37043f8 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.2 +@version 25.8.3 @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 3b4ba69..a66f967 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.2 +@version 25.8.3 @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 f99a9d0..d67c48b 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.2 +@version 25.8.3 @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 4440b6d..f630d06 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.2 +@version 25.8.3 @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 35c0c1a..ed334d1 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.2 +@version 25.8.3 @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 775c586..008a15d 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.2 +@version 25.8.3 @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 f8c95f8..80825d9 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.2 +@version 25.8.3 @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 fe8e895..192d745 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.2 +@version 25.8.3 @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 334a89d..df6d039 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.2 +@version 25.8.3 @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 ddef552..eb09e0d 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.2 +@version 25.8.3 @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 e5a2161..ce4cc75 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.2 +@version 25.8.3 @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 07b5c64..f86d56d 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.2 +@version 25.8.3 @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 79da3a8..947fa32 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.2 +@version 25.8.3 @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 b4dc3bd..39c9da8 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.2 +@version 25.8.3 @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 09d76f2..86771c8 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.2 +@version 25.8.3 @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 2660e43..8f86713 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.2 +@version 25.8.3 @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 003514b..5e283e0 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.2 +@version 25.8.3 @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 47831bc..198943d 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.2 +@version 25.8.3 @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 4e6974c..0550d53 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.2 +@version 25.8.3 @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 1c958a0..69a8952 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.2 +@version 25.8.3 @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 2157621..7a46979 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.2 +@version 25.8.3 @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 0c22be6..81bdd63 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.2 +@version 25.8.3 @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 ed8822d..b5f1cf1 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.2 +@version 25.8.3 @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 3ed8f3b..da55eda 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.2 +@version 25.8.3 @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 a658d82..4e89290 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.2 +@version 25.8.3 @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 ef6193b..d98f1c3 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.2 +@version 25.8.3 @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 7a87aa2..abd1e41 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.2 +@version 25.8.3 @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 909b40d..58015f3 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.2 +@version 25.8.3 @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 cd5ea38..19330d1 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.2 +@version 25.8.3 @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 a1dd14a..2576922 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.2 +@version 25.8.3 @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 b59334e..87197f5 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.2 +@version 25.8.3 @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 5cf3cdc..a117f02 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.2 +@version 25.8.3 @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 287b55d..b93a2b3 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.2 +@version 25.8.3 @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 1787110..407e487 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.2 +@version 25.8.3 @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 cfe89db..3a99c8c 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.2 +@version 25.8.3 @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 02b5c43..fc8b413 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.2 +@version 25.8.3 @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 31cc534..21c8e74 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.2 +@version 25.8.3 @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 9a92d78..28a5ec7 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.2 +@version 25.8.3 @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 ae4365c..0dd2c34 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.2 +@version 25.8.3 @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 e2dc685..b4f8f3f 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.2 +@version 25.8.3 @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 daca410..94090de 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.2 +@version 25.8.3 @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 509201c..44760ba 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.2 +@version 25.8.3 @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 c4be4e2..02fff70 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.2 +@version 25.8.3 @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 9f05a65..2c64ae4 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.2 +@version 25.8.3 @link https://github.com/avadev/AvaTax-REST-V3-Python-SDK """ diff --git a/README.md b/README.md index 34eebf7..cfac16c 100644 --- a/README.md +++ b/README.md @@ -188,6 +188,7 @@ Class | Method | HTTP request | Description *Forms1099Api* | [**get1099_form_pdf**](docs/A1099/V2/Forms1099Api.md#get1099_form_pdf) | **GET** /1099/forms/{id}/pdf | Retrieve the PDF file for a 1099/1095/W2/1042S form *Forms1099Api* | [**list1099_forms**](docs/A1099/V2/Forms1099Api.md#list1099_forms) | **GET** /1099/forms | List 1099/1095/W2/1042S forms *Forms1099Api* | [**update1099_form**](docs/A1099/V2/Forms1099Api.md#update1099_form) | **PUT** /1099/forms/{id} | Update a 1099/1095/W2/1042S form +*FormsW9Api* | [**create_and_send_w9_form_email**](docs/A1099/V2/FormsW9Api.md#create_and_send_w9_form_email) | **POST** /w9/forms/$create-and-send-email | Create a minimal W9/W4/W8 form and sends the e-mail request *FormsW9Api* | [**create_w9_form**](docs/A1099/V2/FormsW9Api.md#create_w9_form) | **POST** /w9/forms | Create a W9/W4/W8 form *FormsW9Api* | [**delete_w9_form**](docs/A1099/V2/FormsW9Api.md#delete_w9_form) | **DELETE** /w9/forms/{id} | Delete a W9/W4/W8 form *FormsW9Api* | [**get_w9_form**](docs/A1099/V2/FormsW9Api.md#get_w9_form) | **GET** /w9/forms/{id} | Retrieve a W9/W4/W8 form @@ -200,7 +201,7 @@ Class | Method | HTTP request | Description *Issuers1099Api* | [**get_issuer**](docs/A1099/V2/Issuers1099Api.md#get_issuer) | **GET** /1099/issuers/{id} | Retrieve an issuer *Issuers1099Api* | [**get_issuers**](docs/A1099/V2/Issuers1099Api.md#get_issuers) | **GET** /1099/issuers | List issuers *Issuers1099Api* | [**update_issuer**](docs/A1099/V2/Issuers1099Api.md#update_issuer) | **PUT** /1099/issuers/{id} | Update an issuer -*Jobs1099Api* | [**get_job**](docs/A1099/V2/Jobs1099Api.md#get_job) | **GET** /1099/jobs/{id} | Retrieves information about the job +*JobsApi* | [**get_job**](docs/A1099/V2/JobsApi.md#get_job) | **GET** /jobs/{id} | Retrieves information about the job ## Documentation for Models @@ -287,134 +288,72 @@ Class | Method | HTTP request | Description ### A1099 V2 Model Documentation - - [Avalara.SDK.models.A1099.V2.Attribute](docs/A1099/V2/Attribute.md) - [Avalara.SDK.models.A1099.V2.AuthorizedApiRequestModel](docs/A1099/V2/AuthorizedApiRequestModel.md) - [Avalara.SDK.models.A1099.V2.AuthorizedApiRequestV2DataModel](docs/A1099/V2/AuthorizedApiRequestV2DataModel.md) - - [Avalara.SDK.models.A1099.V2.BaseCompanyModel](docs/A1099/V2/BaseCompanyModel.md) - - [Avalara.SDK.models.A1099.V2.BaseFormListRequest](docs/A1099/V2/BaseFormListRequest.md) - - [Avalara.SDK.models.A1099.V2.BulkUpsert1099FormsRequest](docs/A1099/V2/BulkUpsert1099FormsRequest.md) - [Avalara.SDK.models.A1099.V2.CompanyCreateUpdateRequestModel](docs/A1099/V2/CompanyCreateUpdateRequestModel.md) - - [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) + - [Avalara.SDK.models.A1099.V2.CoveredIndividual](docs/A1099/V2/CoveredIndividual.md) + - [Avalara.SDK.models.A1099.V2.CreateAndSendW9FormEmailRequest](docs/A1099/V2/CreateAndSendW9FormEmailRequest.md) + - [Avalara.SDK.models.A1099.V2.CreateCompanyRequest](docs/A1099/V2/CreateCompanyRequest.md) + - [Avalara.SDK.models.A1099.V2.CreateIssuerRequest](docs/A1099/V2/CreateIssuerRequest.md) - [Avalara.SDK.models.A1099.V2.CreateW9Form201Response](docs/A1099/V2/CreateW9Form201Response.md) - [Avalara.SDK.models.A1099.V2.CreateW9FormRequest](docs/A1099/V2/CreateW9FormRequest.md) - - [Avalara.SDK.models.A1099.V2.Data](docs/A1099/V2/Data.md) + - [Avalara.SDK.models.A1099.V2.EntryStatusResponse](docs/A1099/V2/EntryStatusResponse.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.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.Form1095C](docs/A1099/V2/Form1095C.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) - - [Avalara.SDK.models.A1099.V2.Form1099KRequest](docs/A1099/V2/Form1099KRequest.md) - - [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.Form1099ListRequest](docs/A1099/V2/Form1099ListRequest.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.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) - [Avalara.SDK.models.A1099.V2.IrsResponse](docs/A1099/V2/IrsResponse.md) - [Avalara.SDK.models.A1099.V2.IssuerCommand](docs/A1099/V2/IssuerCommand.md) - [Avalara.SDK.models.A1099.V2.IssuerResponse](docs/A1099/V2/IssuerResponse.md) - - [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.JobResponse](docs/A1099/V2/JobResponse.md) + - [Avalara.SDK.models.A1099.V2.OfferAndCoverage](docs/A1099/V2/OfferAndCoverage.md) - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelCompanyResponse](docs/A1099/V2/PaginatedQueryResultModelCompanyResponse.md) + - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelForm1099Base](docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md) - [Avalara.SDK.models.A1099.V2.PaginatedQueryResultModelIssuerResponse](docs/A1099/V2/PaginatedQueryResultModelIssuerResponse.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.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.W4FormMinimalRequest](docs/A1099/V2/W4FormMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W4FormRequest](docs/A1099/V2/W4FormRequest.md) - [Avalara.SDK.models.A1099.V2.W4FormResponse](docs/A1099/V2/W4FormResponse.md) + - [Avalara.SDK.models.A1099.V2.W8BenEFormMinimalRequest](docs/A1099/V2/W8BenEFormMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W8BenEFormRequest](docs/A1099/V2/W8BenEFormRequest.md) - [Avalara.SDK.models.A1099.V2.W8BenEFormResponse](docs/A1099/V2/W8BenEFormResponse.md) - [Avalara.SDK.models.A1099.V2.W8BenESubstantialUsOwnerDataModel](docs/A1099/V2/W8BenESubstantialUsOwnerDataModel.md) - [Avalara.SDK.models.A1099.V2.W8BenFormDataModel](docs/A1099/V2/W8BenFormDataModel.md) + - [Avalara.SDK.models.A1099.V2.W8BenFormMinimalRequest](docs/A1099/V2/W8BenFormMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W8BenFormRequest](docs/A1099/V2/W8BenFormRequest.md) - [Avalara.SDK.models.A1099.V2.W8BenFormResponse](docs/A1099/V2/W8BenFormResponse.md) - [Avalara.SDK.models.A1099.V2.W8BeneFormDataModel](docs/A1099/V2/W8BeneFormDataModel.md) - [Avalara.SDK.models.A1099.V2.W8ImyFormDataModel](docs/A1099/V2/W8ImyFormDataModel.md) + - [Avalara.SDK.models.A1099.V2.W8ImyFormMinimalRequest](docs/A1099/V2/W8ImyFormMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W8ImyFormRequest](docs/A1099/V2/W8ImyFormRequest.md) - [Avalara.SDK.models.A1099.V2.W8ImyFormResponse](docs/A1099/V2/W8ImyFormResponse.md) + - [Avalara.SDK.models.A1099.V2.W9FormBaseMinimalRequest](docs/A1099/V2/W9FormBaseMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W9FormBaseRequest](docs/A1099/V2/W9FormBaseRequest.md) - [Avalara.SDK.models.A1099.V2.W9FormBaseResponse](docs/A1099/V2/W9FormBaseResponse.md) - [Avalara.SDK.models.A1099.V2.W9FormDataModel](docs/A1099/V2/W9FormDataModel.md) + - [Avalara.SDK.models.A1099.V2.W9FormMinimalRequest](docs/A1099/V2/W9FormMinimalRequest.md) - [Avalara.SDK.models.A1099.V2.W9FormRequest](docs/A1099/V2/W9FormRequest.md) - [Avalara.SDK.models.A1099.V2.W9FormResponse](docs/A1099/V2/W9FormResponse.md) diff --git a/docs/A1099/V2/CompaniesW9Api.md b/docs/A1099/V2/CompaniesW9Api.md index 184776a..1bc03d6 100644 --- a/docs/A1099/V2/CompaniesW9Api.md +++ b/docs/A1099/V2/CompaniesW9Api.md @@ -1,6 +1,6 @@ # Avalara.SDK.CompaniesW9Api -All URIs are relative to *https://api-ava1099.eta.sbx.us-east-1.aws.avalara.io/avalara1099* +All URIs are relative to *https://api.sbx.avalara.com/avalara1099* Method | HTTP request | Description ------------- | ------------- | ------------- @@ -12,7 +12,7 @@ Method | HTTP request | Description # **create_company** -> CompanyResponseModel create_company(avalara_version) +> CompanyResponse create_company(avalara_version) Create a company @@ -26,8 +26,8 @@ Create a company. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import companies_w9_api -CompanyResponseModel -CompanyCreateUpdateRequestModel +CreateCompanyRequest +CompanyResponse ErrorModel from pprint import pprint @@ -45,9 +45,9 @@ 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 = '5ba3a8b6-bf05-4aaa-b8cb-d06c7cfea0f7' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '8e57d48c-bb4e-4088-9beb-bf2323243c9f' # 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) + create_company_request = {"name":"Acme Corporation","dbaName":"","email":"contact@acmecorp.com","address":"123 Business Ave","city":"Phoenix","state":"AZ","zip":"85001","telephone":"602-555-0123","tin":"12-3456789","referenceId":"","doTinMatch":null,"groupName":"","foreignProvince":"","countryCode":"US","resendRequests":null,"resendIntervalDays":null,"maxReminderAttempts":null} # CreateCompanyRequest | The company to create (optional) # example passing only required values which don't have defaults set try: # Create a company @@ -60,7 +60,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Create a company - api_response = api_instance.create_company(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, company_create_update_request_model=company_create_update_request_model) + api_response = api_instance.create_company(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, create_company_request=create_company_request) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling CompaniesW9Api->create_company: %s\n" % e) @@ -73,11 +73,11 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **company_create_update_request_model** | [**CompanyCreateUpdateRequestModel**](CompanyCreateUpdateRequestModel.md)| The company to create | [optional] + **create_company_request** | [**CreateCompanyRequest**](CreateCompanyRequest.md)| The company to create | [optional] ### Return type -[**CompanyResponseModel**](CompanyResponseModel.md) +[**CompanyResponse**](CompanyResponse.md) ### Authorization @@ -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 = '07a8ecdb-0465-469d-8bff-49fce135d5e4' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '3e231f13-24a7-49dc-a92e-1e04f5d7ca28' # 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 = 'f047fdc5-a6e4-4290-8c5c-d4da96ad0699' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '0b03049b-b1d4-4b5c-83df-dba2d815fce0' # 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 = '3f7b5971-06e7-4459-84af-61db7fdcb027' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b5657869-263a-424d-81ed-4f845a37bf20' # 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: @@ -374,7 +374,7 @@ 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) # **update_company** -> CompanyResponseModel update_company(id, avalara_version) +> CompanyResponse update_company(id, avalara_version) Update a company @@ -388,8 +388,8 @@ Update a company. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import companies_w9_api -CompanyResponseModel -CompanyCreateUpdateRequestModel +CreateCompanyRequest +CompanyResponse ErrorModel from pprint import pprint @@ -408,9 +408,9 @@ 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 = '1cd32062-b0bc-46a0-8311-a973b8fb3d56' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'e0cf793c-bc52-406b-9bdf-15b8e91e2ce8' # 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) + create_company_request = {"name":"Acme Corporation","dbaName":"","email":"contact@acmecorp.com","address":"123 Business Ave","city":"Phoenix","state":"AZ","zip":"85001","telephone":"602-555-0123","tin":"12-3456789","referenceId":"","doTinMatch":null,"groupName":"","foreignProvince":"","countryCode":"US","resendRequests":null,"resendIntervalDays":null,"maxReminderAttempts":null} # CreateCompanyRequest | The updated company data (optional) # example passing only required values which don't have defaults set try: # Update a company @@ -423,7 +423,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Update a company - api_response = api_instance.update_company(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, company_create_update_request_model=company_create_update_request_model) + api_response = api_instance.update_company(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, create_company_request=create_company_request) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling CompaniesW9Api->update_company: %s\n" % e) @@ -437,11 +437,11 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **company_create_update_request_model** | [**CompanyCreateUpdateRequestModel**](CompanyCreateUpdateRequestModel.md)| The updated company data | [optional] + **create_company_request** | [**CreateCompanyRequest**](CreateCompanyRequest.md)| The updated company data | [optional] ### Return type -[**CompanyResponseModel**](CompanyResponseModel.md) +[**CompanyResponse**](CompanyResponse.md) ### Authorization diff --git a/docs/A1099/V2/CompanyCreateUpdateRequestModel.md b/docs/A1099/V2/CompanyCreateUpdateRequestModel.md index 1dcddb2..83eec71 100644 --- a/docs/A1099/V2/CompanyCreateUpdateRequestModel.md +++ b/docs/A1099/V2/CompanyCreateUpdateRequestModel.md @@ -5,23 +5,23 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **str** | | [optional] -**email** | **str** | | [optional] -**address** | **str** | | [optional] -**city** | **str** | | [optional] -**state** | **str** | | [optional] -**zip** | **str** | | [optional] -**telephone** | **str** | | [optional] -**tin** | **str** | | [optional] -**dba_name** | **str** | | [optional] -**reference_id** | **str** | | [optional] -**do_tin_match** | **bool** | | [optional] -**group_name** | **str** | | [optional] -**foreign_province** | **str** | | [optional] -**country_code** | **str** | | [optional] -**resend_requests** | **bool** | | [optional] -**resend_interval_days** | **int** | | [optional] -**max_reminder_attempts** | **int** | | [optional] +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. | [optional] +**email** | **str** | Contact email address. For inquiries by vendors/employees. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). | +**tin** | **str** | Federal Tax Identification Number (TIN). EIN/Tax ID (required for US companies). | +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**do_tin_match** | **bool** | Indicates whether the company authorizes IRS TIN matching. | [optional] +**group_name** | **str** | Group name for organizing companies (creates or finds group by name). | [optional] +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**resend_requests** | **bool** | Boolean to enable automatic reminder emails (default: false). | [optional] +**resend_interval_days** | **int** | Days between reminder emails (7-365, required if resendRequests is true). | [optional] +**max_reminder_attempts** | **int** | Maximum number of reminder attempts (1-52, required if resendRequests is true). | [optional] ## Example diff --git a/docs/A1099/V2/CompanyResponse.md b/docs/A1099/V2/CompanyResponse.md index eca8e7e..df12381 100644 --- a/docs/A1099/V2/CompanyResponse.md +++ b/docs/A1099/V2/CompanyResponse.md @@ -5,26 +5,26 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**id** | **str** | | [optional] -**reference_id** | **str** | | [optional] -**group_name** | **str** | | [optional] -**name** | **str** | | [optional] -**dba_name** | **str** | | [optional] -**address** | **str** | | [optional] -**city** | **str** | | [optional] -**state** | **str** | | [optional] -**foreign_province** | **str** | | [optional] -**zip** | **str** | | [optional] -**country_code** | **str** | | [optional] -**email** | **str** | | [optional] -**telephone** | **str** | | [optional] -**tin** | **str** | | [optional] -**do_tin_match** | **bool** | | [optional] -**resend_requests** | **bool** | | [optional] -**resend_interval_days** | **int** | | [optional] -**max_reminder_attempts** | **int** | | [optional] -**created_at** | **datetime** | | [optional] -**updated_at** | **datetime** | | [optional] +**id** | **str** | Unique identifier set when the record is created. | [optional] +**created_at** | **datetime** | Date time when the record was created. | [optional] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. | [optional] +**email** | **str** | Contact email address. For inquiries by vendors/employees. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). | +**tin** | **str** | Federal Tax Identification Number (TIN). EIN/Tax ID (required for US companies). | +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**do_tin_match** | **bool** | Indicates whether the company authorizes IRS TIN matching. | [optional] +**group_name** | **str** | Group name for organizing companies (creates or finds group by name). | [optional] +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**resend_requests** | **bool** | Boolean to enable automatic reminder emails (default: false). | [optional] +**resend_interval_days** | **int** | Days between reminder emails (7-365, required if resendRequests is true). | [optional] +**max_reminder_attempts** | **int** | Maximum number of reminder attempts (1-52, required if resendRequests is true). | [optional] ## Example diff --git a/docs/A1099/V2/CoveredIndividual.md b/docs/A1099/V2/CoveredIndividual.md new file mode 100644 index 0000000..72654e7 --- /dev/null +++ b/docs/A1099/V2/CoveredIndividual.md @@ -0,0 +1,49 @@ +# CoveredIndividual + +Covered individual information for health coverage forms + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Covered individual's ID | [optional] [readonly] +**first_name** | **str** | Covered individual's first name | +**middle_name** | **str** | Covered individual's middle name | [optional] +**last_name** | **str** | Covered individual's last name | +**name_suffix** | **str** | Covered individual's name suffix | [optional] +**tin** | **str** | Covered individual's Federal Tax Identification Number (TIN).. SSN or ITIN. Required unless unavailable. | [optional] +**birth_date** | **date** | Covered individual's date of birth - Required when SSN is missing. | [optional] +**covered_all_months** | **bool** | Coverage indicator for all 12 months | [optional] +**covered_january** | **bool** | Coverage indicator for January | [optional] +**covered_february** | **bool** | Coverage indicator for February | [optional] +**covered_march** | **bool** | Coverage indicator for March | [optional] +**covered_april** | **bool** | Coverage indicator for April | [optional] +**covered_may** | **bool** | Coverage indicator for May | [optional] +**covered_june** | **bool** | Coverage indicator for June | [optional] +**covered_july** | **bool** | Coverage indicator for July | [optional] +**covered_august** | **bool** | Coverage indicator for August | [optional] +**covered_september** | **bool** | Coverage indicator for September | [optional] +**covered_october** | **bool** | Coverage indicator for October | [optional] +**covered_november** | **bool** | Coverage indicator for November | [optional] +**covered_december** | **bool** | Coverage indicator for December | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.covered_individual import CoveredIndividual + +# TODO update the JSON string below +json = "{}" +# create an instance of CoveredIndividual from a JSON string +covered_individual_instance = CoveredIndividual.from_json(json) +# print the JSON string representation of the object +print(CoveredIndividual.to_json()) + +# convert the object into a dict +covered_individual_dict = covered_individual_instance.to_dict() +# create an instance of CoveredIndividual from a dict +covered_individual_from_dict = CoveredIndividual.from_dict(covered_individual_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/CreateAndSendW9FormEmailRequest.md b/docs/A1099/V2/CreateAndSendW9FormEmailRequest.md new file mode 100644 index 0000000..7b53702 --- /dev/null +++ b/docs/A1099/V2/CreateAndSendW9FormEmailRequest.md @@ -0,0 +1,38 @@ +# CreateAndSendW9FormEmailRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type. | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**employee_first_name** | **str** | The first name of the employee. | +**employee_last_name** | **str** | The last name of the employee. | +**office_code** | **str** | The office code associated with the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**name** | **str** | The name of the individual or entity associated with the form. | +**reference_number** | **str** | A reference number for the form. | [optional] +**account_number** | **str** | The account number associated with the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.create_and_send_w9_form_email_request import CreateAndSendW9FormEmailRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateAndSendW9FormEmailRequest from a JSON string +create_and_send_w9_form_email_request_instance = CreateAndSendW9FormEmailRequest.from_json(json) +# print the JSON string representation of the object +print(CreateAndSendW9FormEmailRequest.to_json()) + +# convert the object into a dict +create_and_send_w9_form_email_request_dict = create_and_send_w9_form_email_request_instance.to_dict() +# create an instance of CreateAndSendW9FormEmailRequest from a dict +create_and_send_w9_form_email_request_from_dict = CreateAndSendW9FormEmailRequest.from_dict(create_and_send_w9_form_email_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/CreateCompanyRequest.md b/docs/A1099/V2/CreateCompanyRequest.md new file mode 100644 index 0000000..cbd9461 --- /dev/null +++ b/docs/A1099/V2/CreateCompanyRequest.md @@ -0,0 +1,48 @@ +# CreateCompanyRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. | [optional] +**email** | **str** | Contact email address. For inquiries by vendors/employees. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). | +**tin** | **str** | Federal Tax Identification Number (TIN). EIN/Tax ID (required for US companies). | +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**do_tin_match** | **bool** | Indicates whether the company authorizes IRS TIN matching. | [optional] +**group_name** | **str** | Group name for organizing companies (creates or finds group by name). | [optional] +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**resend_requests** | **bool** | Boolean to enable automatic reminder emails (default: false). | [optional] +**resend_interval_days** | **int** | Days between reminder emails (7-365, required if resendRequests is true). | [optional] +**max_reminder_attempts** | **int** | Maximum number of reminder attempts (1-52, required if resendRequests is true). | [optional] +**id** | **str** | Unique identifier set when the record is created. | [optional] +**created_at** | **datetime** | Date time when the record was created. | [optional] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.create_company_request import CreateCompanyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateCompanyRequest from a JSON string +create_company_request_instance = CreateCompanyRequest.from_json(json) +# print the JSON string representation of the object +print(CreateCompanyRequest.to_json()) + +# convert the object into a dict +create_company_request_dict = create_company_request_instance.to_dict() +# create an instance of CreateCompanyRequest from a dict +create_company_request_from_dict = CreateCompanyRequest.from_dict(create_company_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/CreateIssuerRequest.md b/docs/A1099/V2/CreateIssuerRequest.md new file mode 100644 index 0000000..de50c17 --- /dev/null +++ b/docs/A1099/V2/CreateIssuerRequest.md @@ -0,0 +1,46 @@ +# CreateIssuerRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. Use either this or 'transferAgentName'. | [optional] +**tin** | **str** | Federal Tax Identification Number (TIN). | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. If present, it will prefix download filenames. Allowed characters: letters, numbers, dashes, underscores, and spaces. | [optional] +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). For recipient inquiries. | +**tax_year** | **int** | Tax year for which the forms are being filed (e.g., 2024). Must be within current tax year and current tax year - 4. | +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. If there is a transfer agent, use the transfer agent's shipping address. | [optional] +**email** | **str** | Contact email address. For recipient inquiries. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | +**zip** | **str** | ZIP/postal code. | +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**transfer_agent_name** | **str** | Name of the transfer agent, if applicable — optional; use either this or 'dbaName'. | [optional] +**last_filing** | **bool** | Indicates if this is the issuer's final year filing. | +**id** | **str** | Unique identifier set when the record is created. | [optional] +**created_at** | **datetime** | Date time when the record was created. | [optional] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.create_issuer_request import CreateIssuerRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateIssuerRequest from a JSON string +create_issuer_request_instance = CreateIssuerRequest.from_json(json) +# print the JSON string representation of the object +print(CreateIssuerRequest.to_json()) + +# convert the object into a dict +create_issuer_request_dict = create_issuer_request_instance.to_dict() +# create an instance of CreateIssuerRequest from a dict +create_issuer_request_from_dict = CreateIssuerRequest.from_dict(create_issuer_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/CreateW9Form201Response.md b/docs/A1099/V2/CreateW9Form201Response.md index aba5827..bc9a1ff 100644 --- a/docs/A1099/V2/CreateW9Form201Response.md +++ b/docs/A1099/V2/CreateW9Form201Response.md @@ -102,13 +102,13 @@ Name | Type | Description | Notes **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] +**entry_status** | [**EntryStatusResponse**](EntryStatusResponse.md) | The entry status information for the form. | [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] +**ancestor_id** | **str** | Form ID of previous version. | [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] diff --git a/docs/A1099/V2/CreateW9FormRequest.md b/docs/A1099/V2/CreateW9FormRequest.md index ba63f79..4771705 100644 --- a/docs/A1099/V2/CreateW9FormRequest.md +++ b/docs/A1099/V2/CreateW9FormRequest.md @@ -24,11 +24,11 @@ Name | Type | Description | Notes **tin** | **str** | The taxpayer identification number (TIN). | [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] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual 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] **entity_type** | **str** | The entity type. | [optional] diff --git a/docs/A1099/V2/EntryStatusResponse.md b/docs/A1099/V2/EntryStatusResponse.md new file mode 100644 index 0000000..e876ee1 --- /dev/null +++ b/docs/A1099/V2/EntryStatusResponse.md @@ -0,0 +1,31 @@ +# EntryStatusResponse + +Represents the entry status information for a W9 form. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**status** | **str** | The form status. | [optional] +**time** | **datetime** | The timestamp for the latest status update. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.entry_status_response import EntryStatusResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of EntryStatusResponse from a JSON string +entry_status_response_instance = EntryStatusResponse.from_json(json) +# print the JSON string representation of the object +print(EntryStatusResponse.to_json()) + +# convert the object into a dict +entry_status_response_dict = entry_status_response_instance.to_dict() +# create an instance of EntryStatusResponse from a dict +entry_status_response_from_dict = EntryStatusResponse.from_dict(entry_status_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/Form1042S.md b/docs/A1099/V2/Form1042S.md index 96356b8..ca8399a 100644 --- a/docs/A1099/V2/Form1042S.md +++ b/docs/A1099/V2/Form1042S.md @@ -1,72 +1,73 @@ # Form1042S +Form 1042-S: Foreign Person's U.S. Source Income Subject to Withholding ## 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] +**tin_type** | **str** | | [optional] [readonly] +**unique_form_id** | **str** | Unique form identifier | +**recipient_date_of_birth** | **date** | Recipient's date of birth | [optional] +**recipient_giin** | **str** | Recipient's Global Intermediary Identification Number (GIIN). A valid GIIN looks like 'XXXXXX.XXXXX.XX.XXX'. | [optional] +**recipient_foreign_tin** | **str** | Recipient's foreign TIN. Required if email is specified, must fill either this or Chap3StatusCode. | [optional] +**lob_code** | **str** | Limitation on Benefits (LOB) code for tax treaty purposes. Available values: - 01: Individual (Deprecated - valid only for tax years prior to 2019) - 02: Government - contracting state/political subdivision/local authority - 03: Tax exempt pension trust/Pension fund - 04: Tax exempt/Charitable organization - 05: Publicly-traded corporation - 06: Subsidiary of publicly-traded corporation - 07: Company that meets the ownership and base erosion test - 08: Company that meets the derivative benefits test - 09: Company with an item of income that meets the active trade or business test - 10: Discretionary determination - 11: Other - 12: No LOB article in treaty | [optional] +**income_code** | **str** | Income code. Available values: Interest: - 01: Interest paid by US obligors - general - 02: Interest paid on real property mortgages - 03: Interest paid to controlling foreign corporations - 04: Interest paid by foreign corporations - 05: Interest on tax-free covenant bonds - 22: Interest paid on deposit with a foreign branch of a domestic corporation or partnership - 29: Deposit interest - 30: Original issue discount (OID) - 31: Short-term OID - 33: Substitute payment - interest - 51: Interest paid on certain actively traded or publicly offered securities(1) - 54: Substitute payments - interest from certain actively traded or publicly offered securities(1) Dividend: - 06: Dividends paid by U.S. corporations - general - 07: Dividends qualifying for direct dividend rate - 08: Dividends paid by foreign corporations - 34: Substitute payment - dividends - 40: Other dividend equivalents under IRC section 871(m) (formerly 871(l)) - 52: Dividends paid on certain actively traded or publicly offered securities(1) - 53: Substitute payments - dividends from certain actively traded or publicly offered securities(1) - 56: Dividend equivalents under IRC section 871(m) as a result of applying the combined transaction rules Other: - 09: Capital gains - 10: Industrial royalties - 11: Motion picture or television copyright royalties - 12: Other royalties (for example, copyright, software, broadcasting, endorsement payments) - 13: Royalties paid on certain publicly offered securities(1) - 14: Real property income and natural resources royalties - 15: Pensions, annuities, alimony, and/or insurance premiums - 16: Scholarship or fellowship grants - 17: Compensation for independent personal services(2) - 18: Compensation for dependent personal services(2) - 19: Compensation for teaching(2) - 20: Compensation during studying and training(2) - 23: Other income - 24: Qualified investment entity (QIE) distributions of capital gains - 25: Trust distributions subject to IRC section 1445 - 26: Unsevered growing crops and timber distributions by a trust subject to IRC section 1445 - 27: Publicly traded partnership distributions subject to IRC section 1446 - 28: Gambling winnings(3) - 32: Notional principal contract income(4) - 35: Substitute payment - other - 36: Capital gains distributions - 37: Return of capital - 38: Eligible deferred compensation items subject to IRC section 877A(d)(1) - 39: Distributions from a nongrantor trust subject to IRC section 877A(f)(1) - 41: Guarantee of indebtedness - 42: Earnings as an artist or athlete - no central withholding agreement(5) - 43: Earnings as an artist or athlete - central withholding agreement(5) - 44: Specified Federal procurement payments - 50: Income previously reported under escrow procedure(6) - 55: Taxable death benefits on life insurance contracts - 57: Amount realized under IRC section 1446(f) - 58: Publicly traded partnership distributions-undetermined | +**gross_income** | **float** | Gross income | +**withholding_indicator** | **str** | Withholding indicator Available values: - 3: Chapter 3 - 4: Chapter 4 | +**tax_country_code** | **str** | Country code | +**exemption_code_chap3** | **str** | Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3). Required when using TaxRateChap3. Available values: - Empty: Tax rate is due to backup withholding - 00: Not exempt - 01: Effectively connected income - 02: Exempt under IRC (other than portfolio interest) - 03: Income is not from US sources - 04: Exempt under tax treaty - 05: Portfolio interest exempt under IRC - 06: QI that assumes primary withholding responsibility - 07: WFP or WFT - 08: U.S. branch treated as U.S. Person - 09: Territory FI treated as U.S. Person - 10: QI represents that income is exempt - 11: QSL that assumes primary withholding responsibility - 12: Payee subjected to chapter 4 withholding - 22: QDD that assumes primary withholding responsibility - 23: Exempt under section 897(l) - 24: Exempt under section 892 | [optional] +**exemption_code_chap4** | **str** | Exemption code (Chapter 4). Required if WithholdingIndicator is 4 (Chapter 4). Available values: - 00: Not exempt - 13: Grandfathered payment - 14: Effectively connected income - 15: Payee not subject to chapter 4 withholding - 16: Excluded nonfinancial payment - 17: Foreign Entity that assumes primary withholding responsibility - 18: U.S. Payees - of participating FFI or registered deemed - compliant FFI - 19: Exempt from withholding under IGA(6) - 20: Dormant account(7) - 21: Other - payment not subject to chapter 4 withholding | [optional] +**tax_rate_chap3** | **str** | Tax rate (Chapter 3) - Required if WithholdingIndicator is 3 (Chapter 3). Available values: - 00.00: 0.00% - 02.00: 2.00% - 04.00: 4.00% - 04.90: 4.90% - 04.95: 4.95% - 05.00: 5.00% - 07.00: 7.00% - 08.00: 8.00% - 10.00: 10.00% - 12.00: 12.00% - 12.50: 12.50% - 14.00: 14.00% - 15.00: 15.00% - 17.50: 17.50% - 20.00: 20.00% - 21.00: 21.00% - 24.00: 24.00% - 25.00: 25.00% - 27.50: 27.50% - 28.00: 28.00% - 30.00: 30.00% - 37.00: 37.00% | [optional] +**withholding_allowance** | **float** | Withholding allowance | [optional] +**federal_tax_withheld** | **float** | Federal tax withheld | [optional] +**tax_not_deposited_indicator** | **bool** | Tax not deposited indicator | [optional] +**academic_indicator** | **bool** | Academic indicator | [optional] +**tax_withheld_other_agents** | **float** | Tax withheld by other agents | [optional] +**amount_repaid** | **float** | Amount repaid to recipient | [optional] +**tax_paid_agent** | **float** | Tax paid by withholding agent | [optional] +**chap3_status_code** | **str** | Chapter 3 status code - Required if WithholdingIndicator is 3 (Chapter 3) Available values: - 01: U.S. Withholding Agent - FI (Deprecated - valid only for tax years prior to 2020) - 02: U.S. Withholding Agent - Other (Deprecated - valid only for tax years prior to 2020) - 03: Territory FI - treated as U.S. Person - 04: Territory FI - not treated as U.S. Person - 05: U.S. branch - treated as U.S. Person - 06: U.S. branch - not treated as U.S. Person - 07: U.S. branch - ECI presumption applied - 08: Partnership other than Withholding Foreign Partnership - 09: Withholding Foreign Partnership - 10: Trust other than Withholding Foreign Trust - 11: Withholding Foreign Trust - 12: Qualified Intermediary - 13: Qualified Securities Lender - Qualified Intermediary - 14: Qualified Securities Lender - Other - 15: Corporation - 16: Individual - 17: Estate - 18: Private Foundation - 19: Government or International Organization - 20: Tax Exempt Organization (Section 501(c) entities) - 21: Unknown Recipient - 22: Artist or Athlete - 23: Pension - 24: Foreign Central Bank of Issue - 25: Nonqualified Intermediary - 26: Hybrid entity making Treaty Claim - 27: Withholding Rate Pool - General - 28: Withholding Rate Pool - Exempt Organization - 29: PAI Withholding Rate Pool - General - 30: PAI Withholding Rate Pool - Exempt Organization - 31: Agency Withholding Rate Pool - General - 32: Agency Withholding Rate Pool - Exempt Organization - 34: U.S. Withholding Agent-Foreign branch of FI (Deprecated - valid only for tax years prior to 2020) - 35: Qualified Derivatives Dealer - 36: Foreign Government - Integral Part - 37: Foreign Government - Controlled Entity - 38: Publicly Traded Partnership - 39: Disclosing Qualified Intermediary | [optional] +**chap4_status_code** | **str** | Chapter 4 status code. Required if WithholdingIndicator is 4 (Chapter 4). Required if email is specified, must fill either this or RecipientForeignTin. Available values: - 01: U.S. Withholding Agent - FI - 02: U.S. Withholding Agent - Other - 03: Territory FI - not treated as U.S. Person - 04: Territory FI - treated as U.S. Person - 05: Participating FFI - Other - 06: Participating FFI - Reporting Model 2 FFI - 07: Registered Deemed - Compliant FFI-Reporting Model 1 FFI - 08: Registered Deemed - Compliant FFI-Sponsored Entity - 09: Registered Deemed - Compliant FFI-Other - 10: Certified Deemed - Compliant FFI-Other - 11: Certified Deemed - Compliant FFI-FFI with Low Value Accounts - 12: Certified Deemed - Compliant FFI-Non-Registering Local Bank - 13: Certified Deemed - Compliant FFI-Sponsored Entity - 14: Certified Deemed - Compliant FFI-Investment Advisor or Investment Manager - 15: Nonparticipating FFI - 16: Owner-Documented FFI - 17: U.S. Branch - treated as U.S. person - 18: U.S. Branch - not treated as U.S. person (reporting under section 1471) - 19: Passive NFFE identifying Substantial U.S. Owners - 20: Passive NFFE with no Substantial U.S. Owners - 21: Publicly Traded NFFE or Affiliate of Publicly Traded NFFE - 22: Active NFFE - 23: Individual - 24: Section 501(c) Entities - 25: Excepted Territory NFFE - 26: Excepted NFFE - Other - 27: Exempt Beneficial Owner - 28: Entity Wholly Owned by Exempt Beneficial Owners - 29: Unknown Recipient - 30: Recalcitrant Account Holder - 31: Nonreporting IGA FFI - 32: Direct reporting NFFE - 33: U.S. reportable account - 34: Non-consenting U.S. account - 35: Sponsored direct reporting NFFE - 36: Excepted Inter-affiliate FFI - 37: Undocumented Preexisting Obligation - 38: U.S. Branch - ECI presumption applied - 39: Account Holder of Excluded Financial Account - 40: Passive NFFE reported by FFI - 41: NFFE subject to 1472 withholding - 42: Recalcitrant Pool - No U.S. Indicia - 43: Recalcitrant Pool - U.S. Indicia - 44: Recalcitrant Pool - Dormant Account - 45: Recalcitrant Pool - U.S. Persons - 46: Recalcitrant Pool - Passive NFFEs - 47: Nonparticipating FFI Pool - 48: U.S. Payees Pool - 49: QI - Recalcitrant Pool-General - 50: U.S. Withholding Agent-Foreign branch of FI | [optional] +**primary_withholding_agent** | [**PrimaryWithholdingAgent**](PrimaryWithholdingAgent.md) | Primary withholding agent information | [optional] +**intermediary_or_flow_through** | [**IntermediaryOrFlowThrough**](IntermediaryOrFlowThrough.md) | Intermediary or flow-through entity information | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1095B.md b/docs/A1099/V2/Form1095B.md index 3b9da5d..d988b25 100644 --- a/docs/A1099/V2/Form1095B.md +++ b/docs/A1099/V2/Form1095B.md @@ -1,51 +1,57 @@ # Form1095B +Form 1095-B: Health Coverage ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**origin_of_health_coverage_code** | **str** | | [optional] -**covered_individuals** | [**List[CoveredIndividualReference]**](CoveredIndividualReference.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] +**employee_first_name** | **str** | Employee's first name | +**employee_middle_name** | **str** | Employee's middle name | [optional] +**employee_last_name** | **str** | Employee's last name | +**employee_name_suffix** | **str** | Employee's name suffix | [optional] +**employee_date_of_birth** | **date** | Employee's date of birth | [optional] +**origin_of_health_coverage_code** | **str** | Origin of health coverage code Available values: - A: Small Business Health Options Program (SHOP) - B: Employer-sponsored coverage - C: Government-sponsored program - D: Individual market insurance - E: Multiemployer plan - F: Other designated minimum essential coverage - G: Employer-sponsored coverage that is an individual coverage HRA (valid for tax years 2020 and later) | +**covered_individuals** | [**List[CoveredIndividual]**](CoveredIndividual.md) | Covered individuals information - At least one month of coverage must be entered if it's not a correction. | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1095C.md b/docs/A1099/V2/Form1095C.md new file mode 100644 index 0000000..56c55f6 --- /dev/null +++ b/docs/A1099/V2/Form1095C.md @@ -0,0 +1,77 @@ +# Form1095C + +Form 1095-C: Employer-Provided Health Insurance Offer and Coverage + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**employee_first_name** | **str** | Employee's first name | +**employee_middle_name** | **str** | Employee's middle name | [optional] +**employee_last_name** | **str** | Employee's last name | +**employee_name_suffix** | **str** | Employee's name suffix | [optional] +**recipient_date_of_birth** | **date** | Recipient's date of birth | [optional] +**plan_start_month** | **str** | Plan start month. The calendar month during which the plan year begins of the health plan in which the employee is offered coverage (or would be offered coverage if the employee were eligible to participate in the plan). Available values: - 00: None - 01: January - 02: February - 03: March - 04: April - 05: May - 06: June - 07: July - 08: August - 09: September - 10: October - 11: November - 12: December | +**employer_provided_si_coverage** | **bool** | Employer provided self-insured coverage | [optional] +**offer_and_coverages** | [**List[OfferAndCoverage]**](OfferAndCoverage.md) | Offer and coverage information | +**covered_individuals** | [**List[CoveredIndividual]**](CoveredIndividual.md) | Covered individuals information | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1095_c import Form1095C + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1095C from a JSON string +form1095_c_instance = Form1095C.from_json(json) +# print the JSON string representation of the object +print(Form1095C.to_json()) + +# convert the object into a dict +form1095_c_dict = form1095_c_instance.to_dict() +# create an instance of Form1095C from a dict +form1095_c_from_dict = Form1095C.from_dict(form1095_c_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/Form1099Base.md b/docs/A1099/V2/Form1099Base.md index 63276d2..7a26d92 100644 --- a/docs/A1099/V2/Form1099Base.md +++ b/docs/A1099/V2/Form1099Base.md @@ -5,45 +5,45 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**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] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099Div.md b/docs/A1099/V2/Form1099Div.md index f4a1137..9aae0ed 100644 --- a/docs/A1099/V2/Form1099Div.md +++ b/docs/A1099/V2/Form1099Div.md @@ -1,67 +1,69 @@ # Form1099Div +Form 1099-DIV: Dividends and Distributions ## 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] +**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** | **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** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099Int.md b/docs/A1099/V2/Form1099Int.md index 2227c84..3b4e4d0 100644 --- a/docs/A1099/V2/Form1099Int.md +++ b/docs/A1099/V2/Form1099Int.md @@ -5,59 +5,60 @@ 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] +**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] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099K.md b/docs/A1099/V2/Form1099K.md index 743a691..1ce3dd5 100644 --- a/docs/A1099/V2/Form1099K.md +++ b/docs/A1099/V2/Form1099K.md @@ -1,69 +1,70 @@ # Form1099K +Form 1099-K: Payment Card and Third Party Network Transactions ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**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] -**federal_income_tax_withheld** | **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] -**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] +**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] +**gross_amount_payment_card** | **float** | Gross amount of payment card/third party network transactions | [optional] +**card_not_present_transactions** | **float** | Card not present transactions | [optional] +**merchant_category_code** | **str** | Merchant category code | [optional] +**payment_transaction_number** | **float** | Number of payment transactions | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**january** | **float** | January gross payments | [optional] +**february** | **float** | February gross payments | [optional] +**march** | **float** | March gross payments | [optional] +**april** | **float** | April gross payments | [optional] +**may** | **float** | May gross payments | [optional] +**june** | **float** | June gross payments | [optional] +**july** | **float** | July gross payments | [optional] +**august** | **float** | August gross payments | [optional] +**september** | **float** | September gross payments | [optional] +**october** | **float** | October gross payments | [optional] +**november** | **float** | November gross payments | [optional] +**december** | **float** | December gross payments | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099ListRequest.md b/docs/A1099/V2/Form1099ListRequest.md new file mode 100644 index 0000000..d8081e8 --- /dev/null +++ b/docs/A1099/V2/Form1099ListRequest.md @@ -0,0 +1,30 @@ +# Form1099ListRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | | [optional] +**forms** | [**List[Get1099Form200Response]**](Get1099Form200Response.md) | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.form1099_list_request import Form1099ListRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of Form1099ListRequest from a JSON string +form1099_list_request_instance = Form1099ListRequest.from_json(json) +# print the JSON string representation of the object +print(Form1099ListRequest.to_json()) + +# convert the object into a dict +form1099_list_request_dict = form1099_list_request_instance.to_dict() +# create an instance of Form1099ListRequest from a dict +form1099_list_request_from_dict = Form1099ListRequest.from_dict(form1099_list_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/Form1099Misc.md b/docs/A1099/V2/Form1099Misc.md index 6094b58..cdf6826 100644 --- a/docs/A1099/V2/Form1099Misc.md +++ b/docs/A1099/V2/Form1099Misc.md @@ -1,63 +1,65 @@ # Form1099Misc +Form 1099-MISC: Miscellaneous Income ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**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] -**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] +**rents** | **float** | Rents | [optional] +**royalties** | **float** | Royalties | [optional] +**other_income** | **float** | Other income | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**fishing_boat_proceeds** | **float** | Fishing boat proceeds | [optional] +**medical_and_health_care_payments** | **float** | Medical and health care payments | [optional] +**direct_sales_indicator** | **bool** | Payer made direct sales totaling $5,000 or more of consumer products to recipient for resale | [optional] +**substitute_payments** | **float** | Substitute payments in lieu of dividends or interest | [optional] +**crop_insurance_proceeds** | **float** | Crop insurance proceeds | [optional] +**gross_proceeds_paid_to_attorney** | **float** | Gross proceeds paid to an attorney | [optional] +**fish_purchased_for_resale** | **float** | Fish purchased for resale | [optional] +**section409_a_deferrals** | **float** | Section 409A deferrals | [optional] +**excess_golden_parachute_payments** | **float** | (Legacy field) Excess golden parachute payments | [optional] +**nonqualified_deferred_compensation** | **float** | Nonqualified deferred compensation | [optional] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099Nec.md b/docs/A1099/V2/Form1099Nec.md index 80d5893..da4632c 100644 --- a/docs/A1099/V2/Form1099Nec.md +++ b/docs/A1099/V2/Form1099Nec.md @@ -5,48 +5,48 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**nonemployee_compensation** | **float** | | [optional] -**federal_income_tax_withheld** | **float** | | [optional] -**direct_sales_indicator** | **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] -**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] +**nonemployee_compensation** | **float** | Nonemployee compensation | +**direct_sales_indicator** | **bool** | Payer made direct sales totaling $5,000 or more of consumer products to recipient for resale | [optional] +**federal_income_tax_withheld** | **float** | Federal income tax withheld | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Form1099R.md b/docs/A1099/V2/Form1099R.md index 33cd9f8..6cc4dc6 100644 --- a/docs/A1099/V2/Form1099R.md +++ b/docs/A1099/V2/Form1099R.md @@ -1,68 +1,70 @@ # Form1099R +Form 1099-R: Distributions From Pensions, Annuities, Retirement or Profit-Sharing Plans, IRAs, Insurance Contracts, etc. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**gross_distributions** | **float** | | [optional] -**taxable_amount** | **float** | | [optional] -**taxable_amount_not_determined** | **bool** | | [optional] -**total_distribution_indicator** | **bool** | | [optional] -**capital_gain** | **float** | | [optional] -**fed_income_tax_withheld** | **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] -**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] +**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] +**date_of_payment** | **date** | Date of payment | [optional] +**fatca_filing_requirement** | **bool** | FATCA filing requirement | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] ## Example diff --git a/docs/A1099/V2/Forms1099Api.md b/docs/A1099/V2/Forms1099Api.md index 1c9fdce..576144b 100644 --- a/docs/A1099/V2/Forms1099Api.md +++ b/docs/A1099/V2/Forms1099Api.md @@ -1,6 +1,6 @@ # Avalara.SDK.Forms1099Api -All URIs are relative to *https://api-ava1099.eta.sbx.us-east-1.aws.avalara.io/avalara1099* +All URIs are relative to *https://api.sbx.avalara.com/avalara1099* Method | HTTP request | Description ------------- | ------------- | ------------- @@ -14,11 +14,11 @@ Method | HTTP request | Description # **bulk_upsert1099_forms** -> Form1099ProccessResult bulk_upsert1099_forms(avalara_version) +> JobResponse bulk_upsert1099_forms(avalara_version) Create or update multiple 1099/1095/W2/1042S forms -This endpoint allows you to create or update multiple 1099/1095/W2/1042S forms. You can use one of the following payload structures: **Form 1099-MISC:** ```json { \"formType\": \"1099-MISC\", \"forms\": [ { \"IssuerId\": \"123456\", \"IssuerReferenceId\": \"REF123\", \"IssuerTin\": \"12-3456789\", \"TaxYear\": 2023, \"ReferenceId\": \"FORM123456\", \"RecipientName\": \"John Doe\", \"RecipientTin\": \"587-65-4321\", \"TinType\": \"SSN\", \"RecipientSecondName\": \"Jane Doe\", \"Address\": \"123 Main Street\", \"Address2\": \"Apt 4B\", \"City\": \"New York\", \"State\": \"NY\", \"Zip\": \"10001\", \"Email\": \"john.doe@email.com\", \"AccountNumber\": \"ACC123456\", \"OfficeCode\": \"NYC01\", \"SecondTinNotice\": false, \"NonUsProvince\": \"\", \"CountryCode\": \"US\", \"Rents\": 12000.00, \"Royalties\": 5000.00, \"OtherIncome\": 3000.00, \"FishingBoatProceeds\": 0.00, \"MedicalAndHealthCarePayments\": 15000.00, \"SubstitutePayments\": 1000.00, \"CropInsuranceProceeds\": 0.00, \"GrossProceedsPaidToAttorney\": 7500.00, \"FishPurchasedForResale\": 0.00, \"FedIncomeTaxWithheld\": 5000.00, \"Section409ADeferrals\": 0.00, \"ExcessGoldenParachutePayments\": 0.00, \"NonqualifiedDeferredCompensation\": 0.00, \"DirectSalesIndicator\": false, \"FatcaFilingRequirement\": false, \"StateAndLocalWithholding\": { \"StateTaxWithheld\": 2500.00, \"LocalTaxWithheld\": 1000.00, \"State\": \"NY\", \"StateIdNumber\": \"NY123456\", \"Locality\": \"New York City\", \"StateIncome\": 35000.00, \"LocalIncome\": 35000.00 } } ] } ``` **Form 1099-NEC:** ```json { \"formType\": \"1099-NEC\", \"forms\": [ { \"issuerID\": \"180337282\", \"issuerReferenceId\": \"ISS123\", \"issuerTin\": \"12-3000000\", \"taxYear\": 2024, \"referenceID\": \"REF-002\", \"recipientName\": \"Jane Smith\", \"recipientSecondName\": \"\", \"recipientTin\": \"587-65-4321\", \"tinType\": \"SSN\", \"address\": \"123 Center St\", \"address2\": \"\", \"city\": \"Santa Monica\", \"state\": \"CA\", \"zip\": \"90401\", \"countryCode\": \"US\", \"nonUsProvince\": \"\", \"email\": \"\", \"accountNumber\": \"\", \"officeCode\": \"\", \"secondTinNotice\": false, \"nonemployeeCompensation\": 123.45, \"directSalesIndicator\": false, \"federalIncomeTaxWithheld\": 12.34, \"stateAndLocalWithholding\": { \"state\": \"CA\", \"stateIdNumber\": \"123123123\", \"stateIncome\": 123.45, \"stateTaxWithheld\": 12.34, \"locality\": \"Santa Monica\", \"localityIdNumber\": \"456456\", \"localTaxWithheld\": 12.34, \"localIncome\": 50000.00 }, \"federalEFile\": true, \"postalMail\": true, \"stateEFile\": true, \"tinMatch\": true, \"addressVerification\": true } ] } ``` For the full version of the payload and its schema details, refer to the Swagger schemas section. +This endpoint allows you to create or update multiple 1099/1095/W2/1042S forms. Maximum of 5000 forms can be processed in a single bulk request. ### Example @@ -28,8 +28,8 @@ This endpoint allows you to create or update multiple 1099/1095/W2/1042S forms. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms1099_api -Form1099ProccessResult -BulkUpsert1099FormsRequest +Form1099ListRequest +JobResponse ErrorResponse from pprint import pprint @@ -47,10 +47,10 @@ 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 - dry_run = False # bool | (optional) if omitted the server will use the default value of False - x_correlation_id = 'fc005c04-52f7-44d6-bf16-6551603a8324' # str | Unique correlation Id in a GUID format (optional) + dry_run = False # bool | defaults to false. If true, it will NOT change the DB. It will just return a report of what would've have been changed in the DB (optional) if omitted the server will use the default value of False + x_correlation_id = '51b17473-1a08-453e-ae8c-41924f260edb' # 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) + form1099_list_request = {"type":"1099-NEC","forms":[{"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}}]} # Form1099ListRequest | (optional) # example passing only required values which don't have defaults set try: # Create or update multiple 1099/1095/W2/1042S forms @@ -63,7 +63,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Create or update multiple 1099/1095/W2/1042S forms - api_response = api_instance.bulk_upsert1099_forms(avalara_version, dry_run=dry_run, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, bulk_upsert1099_forms_request=bulk_upsert1099_forms_request) + api_response = api_instance.bulk_upsert1099_forms(avalara_version, dry_run=dry_run, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, form1099_list_request=form1099_list_request) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling Forms1099Api->bulk_upsert1099_forms: %s\n" % e) @@ -74,14 +74,14 @@ with Avalara.SDK.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **avalara_version** | **str**| API version | - **dry_run** | **bool**| | [optional] if omitted the server will use the default value of False + **dry_run** | **bool**| defaults to false. If true, it will NOT change the DB. It will just return a report of what would've have been changed in the DB | [optional] if omitted the server will use the default value of False **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] - **bulk_upsert1099_forms_request** | [**BulkUpsert1099FormsRequest**](BulkUpsert1099FormsRequest.md)| | [optional] + **form1099_list_request** | [**Form1099ListRequest**](Form1099ListRequest.md)| | [optional] ### Return type -[**Form1099ProccessResult**](Form1099ProccessResult.md) +[**JobResponse**](JobResponse.md) ### Authorization @@ -106,7 +106,7 @@ 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) # **create1099_form** -> Create1099Form201Response create1099_form(avalara_version) +> Get1099Form200Response create1099_form(avalara_version) Create a 1099/1095/W2/1042S form @@ -120,9 +120,8 @@ Create a 1099/1095/W2/1042S form. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms1099_api -Create1099Form201Response +Get1099Form200Response ErrorResponse -ICreateForm1099Request from pprint import pprint # Define configuration object with parameters specified to your application. @@ -139,9 +138,9 @@ 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 = '13eb4eb0-0e7d-41e3-adf3-61b131c1a92c' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '8658b701-7c0e-4a84-91fa-101c7b6865d8' # 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) + get1099_form200_response = {"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}} # Get1099Form200Response | (optional) # example passing only required values which don't have defaults set try: # Create a 1099/1095/W2/1042S form @@ -154,7 +153,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Create a 1099/1095/W2/1042S form - api_response = api_instance.create1099_form(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, i_create_form1099_request=i_create_form1099_request) + api_response = api_instance.create1099_form(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, get1099_form200_response=get1099_form200_response) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling Forms1099Api->create1099_form: %s\n" % e) @@ -167,11 +166,11 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **i_create_form1099_request** | [**ICreateForm1099Request**](ICreateForm1099Request.md)| | [optional] + **get1099_form200_response** | [**Get1099Form200Response**](Get1099Form200Response.md)| | [optional] ### Return type -[**Create1099Form201Response**](Create1099Form201Response.md) +[**Get1099Form200Response**](Get1099Form200Response.md) ### Authorization @@ -227,7 +226,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 = '2bcc9cf0-9638-46d5-a792-be61566e0651' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '828993a0-67f5-46c9-b0be-a45fc4436fea' # 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 +314,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 = '6e842a03-8b64-4b02-8c5e-7073bf4e8a8c' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '60127475-bae6-4285-a7eb-1ad8aec75ae6' # 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 +403,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 = '7b4aa70b-3a10-4fa0-bf19-7592170409b7' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'e7c4583b-0102-46c1-a579-35438519cc67' # 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: @@ -461,11 +460,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) # **list1099_forms** -> Form1099ListResponse list1099_forms(avalara_version) +> PaginatedQueryResultModelForm1099Base list1099_forms(avalara_version) List 1099/1095/W2/1042S forms -List 1099/1095/W2/1042S forms. Filterable fields are name, referenceId and taxYear. +List 1099/1095/W2/1042S forms. Collections support filtering only on certain fields. An attempt to filter on an unsupported field will receive a 400 Bad Request response. Supported filtering fields are as follows: - issuerId - issuerReferenceId - taxYear - addressVerificationStatus - possible values are: unknown, pending, failed, incomplete, unchanged, verified - createdAt - edeliveryStatus - possible values are: sent, unscheduled, bad_verify, bad_verify_limit, scheduled, bounced, accepted - email - federalEfileStatus - possible values are: unscheduled, scheduled, sent, corrected_scheduled, accepted, corrected, corrected_accepted, held - recipientName - mailStatus - possible values are: sent, unscheduled, pending, delivered - referenceId - tinMatchStatus - possible values are: none, pending, matched, failed - type - possible values are: 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 - updatedAt - validity - possible values are: true, false For more information on filtering, see Filtering in REST. ### Example @@ -475,7 +474,7 @@ List 1099/1095/W2/1042S forms. Filterable fields are name, referenceId and taxYe import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms1099_api -Form1099ListResponse +PaginatedQueryResultModelForm1099Base ErrorResponse from pprint import pprint @@ -493,11 +492,13 @@ 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 - filter = 'issuerId eq 884781823' # str | A filter statement to identify specific records to retrieve. For more information on filtering, see Filtering in REST. Collections support filtering only on certain fields. An attempt to filter on an unsupported field will receive a 400 Bad Request response. Supported filtering fields are as follows: issuerId issuerReferenceId taxYear addressVerificationStatus - possible values are: unknown, pending, failed, incomplete, unchanged, verified createdAt edeliveryStatus - possible values are: sent, unscheduled, bad_verify, bad_verify_limit, scheduled, bounced, accepted email federalEfileStatus - possible values are: unscheduled, scheduled, sent, corrected_scheduled, accepted, corrected, corrected_accepted, held recipientName mailStatus - possible values are: sent, unscheduled, pending, delivered referenceId tinMatchStatus - possible values are: none, pending, matched, failed type - possible values are: 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 updatedAt validity - possible values are: true, false (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 - 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 = '7766bce5-4834-4907-81e9-dd0fd6c13079' # str | Unique correlation Id in a GUID format (optional) + filter = 'issuerId eq 884781823' # 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 | 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 = '6740cecb-55e5-44ff-86e7-f47e741249e8' # 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: @@ -511,7 +512,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # List 1099/1095/W2/1042S forms - api_response = api_instance.list1099_forms(avalara_version, filter=filter, top=top, skip=skip, order_by=order_by, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client) + api_response = api_instance.list1099_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 Forms1099Api->list1099_forms: %s\n" % e) @@ -522,16 +523,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>. Collections support filtering only on certain fields. An attempt to filter on an unsupported field will receive a 400 Bad Request response. Supported filtering fields are as follows: issuerId issuerReferenceId taxYear addressVerificationStatus - possible values are: unknown, pending, failed, incomplete, unchanged, verified createdAt edeliveryStatus - possible values are: sent, unscheduled, bad_verify, bad_verify_limit, scheduled, bounced, accepted email federalEfileStatus - possible values are: unscheduled, scheduled, sent, corrected_scheduled, accepted, corrected, corrected_accepted, held recipientName mailStatus - possible values are: sent, unscheduled, pending, delivered referenceId tinMatchStatus - possible values are: none, pending, matched, failed type - possible values are: 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 updatedAt validity - possible values are: true, false | [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 - **order_by** | **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] + **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**| 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 -[**Form1099ListResponse**](Form1099ListResponse.md) +[**PaginatedQueryResultModelForm1099Base**](PaginatedQueryResultModelForm1099Base.md) ### Authorization @@ -556,7 +559,7 @@ 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) # **update1099_form** -> Update1099Form200Response update1099_form(id, avalara_version) +> Get1099Form200Response update1099_form(id, avalara_version) Update a 1099/1095/W2/1042S form @@ -570,8 +573,7 @@ Update a 1099/1095/W2/1042S form. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms1099_api -IUpdateForm1099Request -Update1099Form200Response +Get1099Form200Response ErrorResponse from pprint import pprint @@ -590,9 +592,9 @@ 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 = '9f622e4f-7992-4e4f-8e24-e628c5339402' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '2e10a990-964c-4a25-99c8-fb3e5a1f9315' # 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) + get1099_form200_response = {"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}} # Get1099Form200Response | (optional) # example passing only required values which don't have defaults set try: # Update a 1099/1095/W2/1042S form @@ -605,7 +607,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Update a 1099/1095/W2/1042S form - api_response = api_instance.update1099_form(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, i_update_form1099_request=i_update_form1099_request) + api_response = api_instance.update1099_form(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, get1099_form200_response=get1099_form200_response) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling Forms1099Api->update1099_form: %s\n" % e) @@ -619,11 +621,11 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **i_update_form1099_request** | [**IUpdateForm1099Request**](IUpdateForm1099Request.md)| | [optional] + **get1099_form200_response** | [**Get1099Form200Response**](Get1099Form200Response.md)| | [optional] ### Return type -[**Update1099Form200Response**](Update1099Form200Response.md) +[**Get1099Form200Response**](Get1099Form200Response.md) ### Authorization diff --git a/docs/A1099/V2/FormsW9Api.md b/docs/A1099/V2/FormsW9Api.md index 5a31d89..7856e90 100644 --- a/docs/A1099/V2/FormsW9Api.md +++ b/docs/A1099/V2/FormsW9Api.md @@ -1,9 +1,10 @@ # Avalara.SDK.FormsW9Api -All URIs are relative to *https://api-ava1099.eta.sbx.us-east-1.aws.avalara.io/avalara1099* +All URIs are relative to *https://api.sbx.avalara.com/avalara1099* Method | HTTP request | Description ------------- | ------------- | ------------- +[**create_and_send_w9_form_email**](FormsW9Api.md#create_and_send_w9_form_email) | **POST** /w9/forms/$create-and-send-email | Create a minimal W9/W4/W8 form and sends the e-mail request [**create_w9_form**](FormsW9Api.md#create_w9_form) | **POST** /w9/forms | Create a W9/W4/W8 form [**delete_w9_form**](FormsW9Api.md#delete_w9_form) | **DELETE** /w9/forms/{id} | Delete a W9/W4/W8 form [**get_w9_form**](FormsW9Api.md#get_w9_form) | **GET** /w9/forms/{id} | Retrieve a W9/W4/W8 form @@ -13,6 +14,94 @@ Method | HTTP request | Description [**upload_w9_files**](FormsW9Api.md#upload_w9_files) | **POST** /w9/forms/{id}/attachment | Replace the PDF file for a W9/W4/W8 form +# **create_and_send_w9_form_email** +> CreateW9Form201Response create_and_send_w9_form_email(avalara_version) + +Create a minimal W9/W4/W8 form and sends the e-mail request + +Create a minimal W9/W4/W8 form and sends the e-mail request. + +### Example + +* Bearer Authentication (bearer): + +```python +import time +import Avalara.SDK +from Avalara.SDK.api.A1099.V2 import forms_w9_api +CreateW9Form201Response +CreateAndSendW9FormEmailRequest +ErrorResponse +from pprint import pprint + +# Define configuration object with parameters specified to your application. +configuration = Avalara.SDK.Configuration( + app_name='test app' + app_version='1.0' + machine_name='some machine' + client_id='' + client_secret='' + environment='sandbox' +) +# Enter a context with an instance of the API client +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 = 'daaba72b-ef09-4c15-9a83-344ad63c1533' # 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_and_send_w9_form_email_request = {"type":"W9","email":"john.doe@example.com","name":"John Doe","accountNumber":"ACC01","companyId":"32553266","referenceId":"REF-12345"} # CreateAndSendW9FormEmailRequest | Form to be created (optional) + # example passing only required values which don't have defaults set + try: + # Create a minimal W9/W4/W8 form and sends the e-mail request + api_response = api_instance.create_and_send_w9_form_email(avalara_version) + pprint(api_response) + except Avalara.SDK.ApiException as e: + print("Exception when calling FormsW9Api->create_and_send_w9_form_email: %s\n" % e) + + # example passing only required values which don't have defaults set + # and optional values + try: + # Create a minimal W9/W4/W8 form and sends the e-mail request + api_response = api_instance.create_and_send_w9_form_email(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, create_and_send_w9_form_email_request=create_and_send_w9_form_email_request) + pprint(api_response) + except Avalara.SDK.ApiException as e: + print("Exception when calling FormsW9Api->create_and_send_w9_form_email: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalara_version** | **str**| API version | + **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] + **create_and_send_w9_form_email_request** | [**CreateAndSendW9FormEmailRequest**](CreateAndSendW9FormEmailRequest.md)| Form to be created | [optional] + +### Return type + +[**CreateW9Form201Response**](CreateW9Form201Response.md) + +### Authorization + +[bearer](../README.md#bearer) + +### HTTP request headers + + - **Content-Type**: application/json, text/json, application/*+json + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | The created W9/W4/W8 form | - | +**400** | Bad request (e.g. Unknown form type: W10\") | - | +**401** | Authentication failed | - | + +[[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) + # **create_w9_form** > CreateW9Form201Response create_w9_form(avalara_version) @@ -47,9 +136,9 @@ 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 = 'd8cc3501-afdd-4b9e-af90-85db9793cbbc' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '9ec7cabd-da9b-4ec2-b94f-9d344e3c9e50' # 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) + 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,"eDeliveryConsentedAt":null,"signature":null,"companyId":"32553266","referenceId":null,"email":null} # CreateW9FormRequest | Form to be created (optional) # example passing only required values which don't have defaults set try: # Create a W9/W4/W8 form @@ -134,7 +223,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 = '0013f0dd-e304-45c6-9f17-bd023626ba48' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'a78693a0-ae1c-4c54-9220-72380bead3a7' # 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 +308,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 = 'e76a4eb2-f5f0-4586-888a-c25443f75fc4' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '13cc90eb-cbcd-4425-baf5-8ae7cbe57113' # 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: @@ -311,7 +400,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 = '8092ac9c-17d0-4ee8-a00e-804088e5ab81' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'c3ac4fe7-8e06-49b7-8bdd-36c22d18d734' # 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: @@ -365,16 +454,16 @@ Name | Type | Description | Notes |-------------|-------------|------------------| **400** | Bad request (e.g., invalid sort key) | - | **401** | Authentication failed | - | -**200** | List of forms | - | +**200** | list | - | [[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) # **send_w9_form_email** -> IW9FormDataModelsOneOf send_w9_form_email(id, avalara_version) +> CreateW9Form201Response send_w9_form_email(id, avalara_version) Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form -Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form. +Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form. If the form is not in 'Requested' status, it will either use an existing descendant form in 'Requested' status or create a new minimal form and send the email request. ### Example @@ -384,8 +473,8 @@ Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form. import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms_w9_api -IW9FormDataModelsOneOf -ErrorModel +CreateW9Form201Response +ErrorResponse from pprint import pprint # Define configuration object with parameters specified to your application. @@ -403,7 +492,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 = '05ca3285-5ab1-43c0-88d7-f23c30428d54' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'be1b2054-2262-4833-92e6-875a3533d944' # 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: @@ -434,7 +523,7 @@ Name | Type | Description | Notes ### Return type -[**IW9FormDataModelsOneOf**](IW9FormDataModelsOneOf.md) +[**CreateW9Form201Response**](CreateW9Form201Response.md) ### Authorization @@ -450,7 +539,8 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| -**200** | The updated W9/W4/W8 form | - | +**200** | Email sent using existing form (form was already in 'Requested' status or descendant found) | - | +**201** | Email sent using newly created minimal form | - | **400** | Bad request (e.g., invalid sort key) | - | **401** | Authentication failed | - | @@ -472,7 +562,7 @@ import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import forms_w9_api IW9FormDataModelsOneOf -ErrorModel +ErrorResponse from pprint import pprint # Define configuration object with parameters specified to your application. @@ -490,7 +580,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 = '87498441-c774-4e3a-864e-dd604bff0d41' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b301d45c-08df-404f-954c-e7edeb163532' # 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 @@ -542,6 +632,7 @@ Name | Type | Description | Notes **200** | The updated W9/W4/W8 form | - | **400** | Bad request (e.g., invalid sort key) | - | **401** | Authentication failed | - | +**404** | W9/W4/W8 form not found | - | [[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) @@ -578,7 +669,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 = '453b7d64-1fd0-4ed3-ba3c-a1d9ca1d69e6' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'a945240a-b94f-476a-a436-863e27320f9d' # 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 333ce74..c5edbe1 100644 --- a/docs/A1099/V2/Get1099Form200Response.md +++ b/docs/A1099/V2/Get1099Form200Response.md @@ -5,57 +5,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**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] -**unique_form_id** | **str** | Unique form identifier | [optional] -**recipient_date_of_birth** | **datetime** | Recipient's date of birth | [optional] -**recipient_giin** | **str** | Recipient's GIIN (Global Intermediary Identification Number) | [optional] -**recipient_foreign_tin** | **str** | Recipient's foreign TIN | [optional] -**lob_code** | **str** | Limitation on benefits code | [optional] -**income_code** | **str** | Income code | [optional] -**gross_income** | **float** | Gross income | [optional] -**withholding_indicator** | **str** | Withholding indicator | [optional] -**tax_country_code** | **str** | Country code | [optional] -**exemption_code_chap3** | **str** | Exemption code (Chapter 3) | [optional] -**exemption_code_chap4** | **str** | Exemption code (Chapter 4) | [optional] -**tax_rate_chap3** | **str** | Tax rate (Chapter 3) | [optional] +**tin_type** | **str** | Type of TIN (Tax ID Number) | [optional] +**unique_form_id** | **str** | Unique form identifier | +**recipient_date_of_birth** | **date** | Recipient's date of birth | [optional] +**recipient_giin** | **str** | Recipient's Global Intermediary Identification Number (GIIN). A valid GIIN looks like 'XXXXXX.XXXXX.XX.XXX'. | [optional] +**recipient_foreign_tin** | **str** | Recipient's foreign TIN. Required if email is specified, must fill either this or Chap3StatusCode. | [optional] +**lob_code** | **str** | Limitation on Benefits (LOB) code for tax treaty purposes. Available values: - 01: Individual (Deprecated - valid only for tax years prior to 2019) - 02: Government - contracting state/political subdivision/local authority - 03: Tax exempt pension trust/Pension fund - 04: Tax exempt/Charitable organization - 05: Publicly-traded corporation - 06: Subsidiary of publicly-traded corporation - 07: Company that meets the ownership and base erosion test - 08: Company that meets the derivative benefits test - 09: Company with an item of income that meets the active trade or business test - 10: Discretionary determination - 11: Other - 12: No LOB article in treaty | [optional] +**income_code** | **str** | Income code. Available values: Interest: - 01: Interest paid by US obligors - general - 02: Interest paid on real property mortgages - 03: Interest paid to controlling foreign corporations - 04: Interest paid by foreign corporations - 05: Interest on tax-free covenant bonds - 22: Interest paid on deposit with a foreign branch of a domestic corporation or partnership - 29: Deposit interest - 30: Original issue discount (OID) - 31: Short-term OID - 33: Substitute payment - interest - 51: Interest paid on certain actively traded or publicly offered securities(1) - 54: Substitute payments - interest from certain actively traded or publicly offered securities(1) Dividend: - 06: Dividends paid by U.S. corporations - general - 07: Dividends qualifying for direct dividend rate - 08: Dividends paid by foreign corporations - 34: Substitute payment - dividends - 40: Other dividend equivalents under IRC section 871(m) (formerly 871(l)) - 52: Dividends paid on certain actively traded or publicly offered securities(1) - 53: Substitute payments - dividends from certain actively traded or publicly offered securities(1) - 56: Dividend equivalents under IRC section 871(m) as a result of applying the combined transaction rules Other: - 09: Capital gains - 10: Industrial royalties - 11: Motion picture or television copyright royalties - 12: Other royalties (for example, copyright, software, broadcasting, endorsement payments) - 13: Royalties paid on certain publicly offered securities(1) - 14: Real property income and natural resources royalties - 15: Pensions, annuities, alimony, and/or insurance premiums - 16: Scholarship or fellowship grants - 17: Compensation for independent personal services(2) - 18: Compensation for dependent personal services(2) - 19: Compensation for teaching(2) - 20: Compensation during studying and training(2) - 23: Other income - 24: Qualified investment entity (QIE) distributions of capital gains - 25: Trust distributions subject to IRC section 1445 - 26: Unsevered growing crops and timber distributions by a trust subject to IRC section 1445 - 27: Publicly traded partnership distributions subject to IRC section 1446 - 28: Gambling winnings(3) - 32: Notional principal contract income(4) - 35: Substitute payment - other - 36: Capital gains distributions - 37: Return of capital - 38: Eligible deferred compensation items subject to IRC section 877A(d)(1) - 39: Distributions from a nongrantor trust subject to IRC section 877A(f)(1) - 41: Guarantee of indebtedness - 42: Earnings as an artist or athlete - no central withholding agreement(5) - 43: Earnings as an artist or athlete - central withholding agreement(5) - 44: Specified Federal procurement payments - 50: Income previously reported under escrow procedure(6) - 55: Taxable death benefits on life insurance contracts - 57: Amount realized under IRC section 1446(f) - 58: Publicly traded partnership distributions-undetermined | +**gross_income** | **float** | Gross income | +**withholding_indicator** | **str** | Withholding indicator Available values: - 3: Chapter 3 - 4: Chapter 4 | +**tax_country_code** | **str** | Country code | +**exemption_code_chap3** | **str** | Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3). Required when using TaxRateChap3. Available values: - Empty: Tax rate is due to backup withholding - 00: Not exempt - 01: Effectively connected income - 02: Exempt under IRC (other than portfolio interest) - 03: Income is not from US sources - 04: Exempt under tax treaty - 05: Portfolio interest exempt under IRC - 06: QI that assumes primary withholding responsibility - 07: WFP or WFT - 08: U.S. branch treated as U.S. Person - 09: Territory FI treated as U.S. Person - 10: QI represents that income is exempt - 11: QSL that assumes primary withholding responsibility - 12: Payee subjected to chapter 4 withholding - 22: QDD that assumes primary withholding responsibility - 23: Exempt under section 897(l) - 24: Exempt under section 892 | [optional] +**exemption_code_chap4** | **str** | Exemption code (Chapter 4). Required if WithholdingIndicator is 4 (Chapter 4). Available values: - 00: Not exempt - 13: Grandfathered payment - 14: Effectively connected income - 15: Payee not subject to chapter 4 withholding - 16: Excluded nonfinancial payment - 17: Foreign Entity that assumes primary withholding responsibility - 18: U.S. Payees - of participating FFI or registered deemed - compliant FFI - 19: Exempt from withholding under IGA(6) - 20: Dormant account(7) - 21: Other - payment not subject to chapter 4 withholding | [optional] +**tax_rate_chap3** | **str** | Tax rate (Chapter 3) - Required if WithholdingIndicator is 3 (Chapter 3). Available values: - 00.00: 0.00% - 02.00: 2.00% - 04.00: 4.00% - 04.90: 4.90% - 04.95: 4.95% - 05.00: 5.00% - 07.00: 7.00% - 08.00: 8.00% - 10.00: 10.00% - 12.00: 12.00% - 12.50: 12.50% - 14.00: 14.00% - 15.00: 15.00% - 17.50: 17.50% - 20.00: 20.00% - 21.00: 21.00% - 24.00: 24.00% - 25.00: 25.00% - 27.50: 27.50% - 28.00: 28.00% - 30.00: 30.00% - 37.00: 37.00% | [optional] **withholding_allowance** | **float** | Withholding allowance | [optional] **federal_tax_withheld** | **float** | Federal tax withheld | [optional] **tax_not_deposited_indicator** | **bool** | Tax not deposited indicator | [optional] @@ -63,12 +25,58 @@ Name | Type | Description | Notes **tax_withheld_other_agents** | **float** | Tax withheld by other agents | [optional] **amount_repaid** | **float** | Amount repaid to recipient | [optional] **tax_paid_agent** | **float** | Tax paid by withholding agent | [optional] -**chap3_status_code** | **str** | Chapter 3 status code | [optional] -**chap4_status_code** | **str** | Chapter 4 status code | [optional] -**primary_withholding_agent** | [**PrimaryWithholdingAgentResponse**](PrimaryWithholdingAgentResponse.md) | Primary withholding agent information | [optional] -**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] +**chap3_status_code** | **str** | Chapter 3 status code - Required if WithholdingIndicator is 3 (Chapter 3) Available values: - 01: U.S. Withholding Agent - FI (Deprecated - valid only for tax years prior to 2020) - 02: U.S. Withholding Agent - Other (Deprecated - valid only for tax years prior to 2020) - 03: Territory FI - treated as U.S. Person - 04: Territory FI - not treated as U.S. Person - 05: U.S. branch - treated as U.S. Person - 06: U.S. branch - not treated as U.S. Person - 07: U.S. branch - ECI presumption applied - 08: Partnership other than Withholding Foreign Partnership - 09: Withholding Foreign Partnership - 10: Trust other than Withholding Foreign Trust - 11: Withholding Foreign Trust - 12: Qualified Intermediary - 13: Qualified Securities Lender - Qualified Intermediary - 14: Qualified Securities Lender - Other - 15: Corporation - 16: Individual - 17: Estate - 18: Private Foundation - 19: Government or International Organization - 20: Tax Exempt Organization (Section 501(c) entities) - 21: Unknown Recipient - 22: Artist or Athlete - 23: Pension - 24: Foreign Central Bank of Issue - 25: Nonqualified Intermediary - 26: Hybrid entity making Treaty Claim - 27: Withholding Rate Pool - General - 28: Withholding Rate Pool - Exempt Organization - 29: PAI Withholding Rate Pool - General - 30: PAI Withholding Rate Pool - Exempt Organization - 31: Agency Withholding Rate Pool - General - 32: Agency Withholding Rate Pool - Exempt Organization - 34: U.S. Withholding Agent-Foreign branch of FI (Deprecated - valid only for tax years prior to 2020) - 35: Qualified Derivatives Dealer - 36: Foreign Government - Integral Part - 37: Foreign Government - Controlled Entity - 38: Publicly Traded Partnership - 39: Disclosing Qualified Intermediary | [optional] +**chap4_status_code** | **str** | Chapter 4 status code. Required if WithholdingIndicator is 4 (Chapter 4). Required if email is specified, must fill either this or RecipientForeignTin. Available values: - 01: U.S. Withholding Agent - FI - 02: U.S. Withholding Agent - Other - 03: Territory FI - not treated as U.S. Person - 04: Territory FI - treated as U.S. Person - 05: Participating FFI - Other - 06: Participating FFI - Reporting Model 2 FFI - 07: Registered Deemed - Compliant FFI-Reporting Model 1 FFI - 08: Registered Deemed - Compliant FFI-Sponsored Entity - 09: Registered Deemed - Compliant FFI-Other - 10: Certified Deemed - Compliant FFI-Other - 11: Certified Deemed - Compliant FFI-FFI with Low Value Accounts - 12: Certified Deemed - Compliant FFI-Non-Registering Local Bank - 13: Certified Deemed - Compliant FFI-Sponsored Entity - 14: Certified Deemed - Compliant FFI-Investment Advisor or Investment Manager - 15: Nonparticipating FFI - 16: Owner-Documented FFI - 17: U.S. Branch - treated as U.S. person - 18: U.S. Branch - not treated as U.S. person (reporting under section 1471) - 19: Passive NFFE identifying Substantial U.S. Owners - 20: Passive NFFE with no Substantial U.S. Owners - 21: Publicly Traded NFFE or Affiliate of Publicly Traded NFFE - 22: Active NFFE - 23: Individual - 24: Section 501(c) Entities - 25: Excepted Territory NFFE - 26: Excepted NFFE - Other - 27: Exempt Beneficial Owner - 28: Entity Wholly Owned by Exempt Beneficial Owners - 29: Unknown Recipient - 30: Recalcitrant Account Holder - 31: Nonreporting IGA FFI - 32: Direct reporting NFFE - 33: U.S. reportable account - 34: Non-consenting U.S. account - 35: Sponsored direct reporting NFFE - 36: Excepted Inter-affiliate FFI - 37: Undocumented Preexisting Obligation - 38: U.S. Branch - ECI presumption applied - 39: Account Holder of Excluded Financial Account - 40: Passive NFFE reported by FFI - 41: NFFE subject to 1472 withholding - 42: Recalcitrant Pool - No U.S. Indicia - 43: Recalcitrant Pool - U.S. Indicia - 44: Recalcitrant Pool - Dormant Account - 45: Recalcitrant Pool - U.S. Persons - 46: Recalcitrant Pool - Passive NFFEs - 47: Nonparticipating FFI Pool - 48: U.S. Payees Pool - 49: QI - Recalcitrant Pool-General - 50: U.S. Withholding Agent-Foreign branch of FI | [optional] +**primary_withholding_agent** | [**PrimaryWithholdingAgent**](PrimaryWithholdingAgent.md) | Primary withholding agent information | [optional] +**intermediary_or_flow_through** | [**IntermediaryOrFlowThrough**](IntermediaryOrFlowThrough.md) | Intermediary or flow-through entity information | [optional] +**type** | **str** | Form type | +**id** | **str** | Form ID. Unique identifier set when the record is created. | [optional] [readonly] +**issuer_id** | **str** | Issuer ID - only required when creating forms | [optional] +**issuer_reference_id** | **str** | Issuer Reference ID - only required when creating forms | [optional] +**issuer_tin** | **str** | Issuer TIN - readonly | [optional] +**tax_year** | **int** | Tax Year - only required when creating forms | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. | [optional] +**tin** | **str** | Recipient's Federal Tax Identification Number (TIN). | [optional] +**recipient_name** | **str** | Recipient name | +**recipient_second_name** | **str** | Recipient second name | [optional] +**address** | **str** | Address. | +**address2** | **str** | Address line 2. | [optional] +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | [optional] +**zip** | **str** | ZIP/postal code. | [optional] +**email** | **str** | Recipient's Contact email address. | [optional] +**account_number** | **str** | Account number | [optional] +**office_code** | **str** | Office code | [optional] +**non_us_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. | +**federal_efile_date** | **date** | Date when 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_efile_date** | **date** | Date when state e-filing should be scheduled for this form | [optional] +**recipient_edelivery_date** | **date** | Date when recipient e-delivery 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** | No TIN indicator | [optional] +**address_verification** | **bool** | Boolean indicating that address verification should be scheduled for this form | [optional] +**state_and_local_withholding** | [**StateAndLocalWithholding**](StateAndLocalWithholding.md) | State and local withholding information | [optional] +**second_tin_notice** | **bool** | Second TIN notice | [optional] +**federal_efile_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Federal e-file status | [optional] [readonly] +**state_efile_status** | [**List[StateEfileStatusDetail]**](StateEfileStatusDetail.md) | State e-file status | [optional] [readonly] +**postal_mail_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Postal mail to recipient status | [optional] [readonly] +**tin_match_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | TIN Match status | [optional] [readonly] +**address_verification_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | Address verification status | [optional] [readonly] +**e_delivery_status** | [**Form1099StatusDetail**](Form1099StatusDetail.md) | EDelivery status | [optional] [readonly] +**validation_errors** | [**List[ValidationError]**](ValidationError.md) | Validation errors | [optional] [readonly] +**created_at** | **datetime** | Date time when the record was created. | [optional] [readonly] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] [readonly] +**employee_first_name** | **str** | Employee's first name | +**employee_middle_name** | **str** | Employee's middle name | [optional] +**employee_last_name** | **str** | Employee's last name | +**employee_name_suffix** | **str** | Employee's name suffix | [optional] +**employee_date_of_birth** | **date** | Employee's date of birth | [optional] +**origin_of_health_coverage_code** | **str** | Origin of health coverage code Available values: - A: Small Business Health Options Program (SHOP) - B: Employer-sponsored coverage - C: Government-sponsored program - D: Individual market insurance - E: Multiemployer plan - F: Other designated minimum essential coverage - G: Employer-sponsored coverage that is an individual coverage HRA (valid for tax years 2020 and later) | +**covered_individuals** | [**List[CoveredIndividual]**](CoveredIndividual.md) | Covered individuals information | [optional] +**plan_start_month** | **str** | Plan start month. The calendar month during which the plan year begins of the health plan in which the employee is offered coverage (or would be offered coverage if the employee were eligible to participate in the plan). Available values: - 00: None - 01: January - 02: February - 03: March - 04: April - 05: May - 06: June - 07: July - 08: August - 09: September - 10: October - 11: November - 12: December | +**employer_provided_si_coverage** | **bool** | Employer provided self-insured coverage | [optional] +**offer_and_coverages** | [**List[OfferAndCoverage]**](OfferAndCoverage.md) | Offer and coverage information | **total_ordinary_dividends** | **float** | Total ordinary dividends | [optional] **qualified_dividends** | **float** | Qualified dividends | [optional] **total_capital_gain_distributions** | **float** | Total capital gain distributions | [optional] @@ -80,24 +88,25 @@ Name | Type | Description | Notes **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] +**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** | **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] **interest_income** | **float** | Interest Income | [optional] -**early_withdrawal_penalty** | **float** | Early withdrawal penalty | [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] +**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** | 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] @@ -113,43 +122,42 @@ Name | Type | Description | Notes **june** | **float** | June gross payments | [optional] **july** | **float** | July gross payments | [optional] **august** | **float** | August gross payments | [optional] -**sept** | **float** | September gross payments | [optional] +**september** | **float** | September gross payments | [optional] **october** | **float** | October gross payments | [optional] **november** | **float** | November gross payments | [optional] **december** | **float** | December gross payments | [optional] **rents** | **float** | Rents | [optional] **royalties** | **float** | Royalties | [optional] **other_income** | **float** | Other income | [optional] -**fed_income_tax_withheld** | **float** | Federal income tax withheld | [optional] **fishing_boat_proceeds** | **float** | Fishing boat proceeds | [optional] **medical_and_health_care_payments** | **float** | Medical and health care payments | [optional] -**substitute_payments** | **float** | Substitute payments in lieu of dividends or interest | [optional] **direct_sales_indicator** | **bool** | Payer made direct sales totaling $5,000 or more of consumer products to recipient for resale | [optional] +**substitute_payments** | **float** | Substitute payments in lieu of dividends or interest | [optional] **crop_insurance_proceeds** | **float** | Crop insurance proceeds | [optional] -**excess_golden_parachute_payments** | **float** | (Legacy field) Excess golden parachute payments | [optional] **gross_proceeds_paid_to_attorney** | **float** | Gross proceeds paid to an attorney | [optional] **fish_purchased_for_resale** | **float** | Fish purchased for resale | [optional] **section409_a_deferrals** | **float** | Section 409A deferrals | [optional] +**excess_golden_parachute_payments** | **float** | (Legacy field) Excess golden parachute payments | [optional] **nonqualified_deferred_compensation** | **float** | Nonqualified deferred compensation | [optional] -**nonemployee_compensation** | **float** | Nonemployee compensation | [optional] -**gross_distributions** | **float** | Gross distribution | [optional] +**nonemployee_compensation** | **float** | Nonemployee compensation | +**gross_distribution** | **float** | Gross distribution | [optional] **taxable_amount** | **float** | Taxable amount | [optional] **taxable_amount_not_determined** | **bool** | Taxable amount not determined | [optional] -**total_distribution_indicator** | **bool** | Total distribution | [optional] +**total_distribution_determined** | **bool** | Total distribution | [optional] **capital_gain** | **float** | Capital gain (included in Box 2a) | [optional] -**employee_contributions** | **float** | Employee contributions/Designated Roth contributions or insurance premiums | [optional] -**net_unrealized_appreciation** | **float** | Net unrealized appreciation in employer's securities | [optional] -**distribution_code_required** | **str** | Distribution code | [optional] -**distribution_code_optional** | **str** | Second distribution code | [optional] -**ira_sep_simple_indicator** | **bool** | IRA/SEP/SIMPLE | [optional] -**total_ira_sep_simple_distribution** | **float** | Traditional IRA/SEP/SIMPLE or Roth conversion amount | [optional] -**other** | **float** | Other amount | [optional] -**other_percent** | **str** | Other percentage | [optional] -**percentage_total_distribution** | **str** | Total distribution percentage | [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** | **float** | Amount allocable to IRR within 5 years | [optional] -**first_year_designated_roth_contrib** | **str** | First year of designated Roth contribution | [optional] -**date_of_payment** | **str** | Date of payment | [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** | **date** | Date of payment | [optional] ## Example diff --git a/docs/A1099/V2/IntermediaryOrFlowThrough.md b/docs/A1099/V2/IntermediaryOrFlowThrough.md index 0f6ee3b..2c3db9d 100644 --- a/docs/A1099/V2/IntermediaryOrFlowThrough.md +++ b/docs/A1099/V2/IntermediaryOrFlowThrough.md @@ -1,21 +1,22 @@ # IntermediaryOrFlowThrough +Intermediary or flow-through entity information for tax forms ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ein** | **str** | | [optional] -**chap3_status_code** | **str** | | [optional] -**chap4_status_code** | **str** | | [optional] -**name** | **str** | | [optional] -**giin** | **str** | | [optional] -**country_code** | **str** | | [optional] -**foreign_tin** | **str** | | [optional] -**address** | **str** | | [optional] -**city** | **str** | | [optional] -**state** | **str** | | [optional] -**zip** | **str** | | [optional] +**ein** | **str** | EIN (Employer Identification Number) of the intermediary or flow-through entity | [optional] +**chap3_status_code** | **str** | Chapter 3 status code for the intermediary or flow-through entity | [optional] +**chap4_status_code** | **str** | Chapter 4 status code for the intermediary or flow-through entity | [optional] +**name** | **str** | Name of the intermediary or flow-through entity | [optional] +**giin** | **str** | GIIN (Global Intermediary Identification Number) of the intermediary or flow-through entity | [optional] +**country_code** | **str** | Country code for the intermediary or flow-through entity | [optional] +**foreign_tin** | **str** | Foreign TIN of the intermediary or flow-through entity | [optional] +**address** | **str** | Address of the intermediary or flow-through entity | [optional] +**city** | **str** | City of the intermediary or flow-through entity | [optional] +**state** | **str** | State of the intermediary or flow-through entity | [optional] +**zip** | **str** | Zip code of the intermediary or flow-through entity | [optional] ## Example diff --git a/docs/A1099/V2/IssuerCommand.md b/docs/A1099/V2/IssuerCommand.md index 943519b..0db8bb8 100644 --- a/docs/A1099/V2/IssuerCommand.md +++ b/docs/A1099/V2/IssuerCommand.md @@ -5,21 +5,21 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**name** | **str** | Legal name, not DBA | [optional] -**name_dba** | **str** | Optional DBA name or continuation of a long legal name | [optional] -**tin** | **str** | Tax identification number | [optional] -**reference_id** | **str** | Optional identifier for your reference, never shown to any agency or recipient. We will also prefix download filenames with this value, if present. Can only include letters, numbers, dashes, underscores and spaces. | [optional] -**telephone** | **str** | Telephone number | [optional] -**tax_year** | **int** | Tax year | [optional] -**country_code** | **str** | If there is a transfer agent, use the shipping address of the transfer agent. | [optional] -**email** | **str** | Email address | [optional] -**address** | **str** | Address | [optional] -**city** | **str** | City | [optional] -**state** | **str** | State | [optional] -**zip** | **str** | Zip code | [optional] -**foreign_province** | **str** | Foreign province | [optional] -**transfer_agent_name** | **str** | Transfer Agent's Name | [optional] -**last_filing** | **bool** | Last year of filing for this payer | [optional] +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. Use either this or 'transferAgentName'. | [optional] +**tin** | **str** | Federal Tax Identification Number (TIN). | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. If present, it will prefix download filenames. Allowed characters: letters, numbers, dashes, underscores, and spaces. | [optional] +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). For recipient inquiries. | +**tax_year** | **int** | Tax year for which the forms are being filed (e.g., 2024). Must be within current tax year and current tax year - 4. | +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. If there is a transfer agent, use the transfer agent's shipping address. | [optional] +**email** | **str** | Contact email address. For recipient inquiries. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | +**zip** | **str** | ZIP/postal code. | +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**transfer_agent_name** | **str** | Name of the transfer agent, if applicable — optional; use either this or 'dbaName'. | [optional] +**last_filing** | **bool** | Indicates if this is the issuer's final year filing. | ## Example diff --git a/docs/A1099/V2/IssuerResponse.md b/docs/A1099/V2/IssuerResponse.md index bb2215c..72554c9 100644 --- a/docs/A1099/V2/IssuerResponse.md +++ b/docs/A1099/V2/IssuerResponse.md @@ -5,24 +5,24 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**id** | **str** | Unique identifier set when the record is created | [optional] [readonly] -**name** | **str** | Legal name, not DBA | [optional] -**name_dba** | **str** | Optional DBA name or continuation of a long legal name | [optional] -**tin** | **str** | Tax identification number | [optional] -**reference_id** | **str** | Optional identifier for your reference, never shown to any agency or recipient. We will also prefix download filenames with this value, if present. Can only include letters, numbers, dashes, underscores and spaces. | [optional] -**telephone** | **str** | Telephone number | [optional] -**tax_year** | **int** | Tax year | [optional] -**country_code** | **str** | If there is a transfer agent, use the address of the transfer agent. | [optional] -**email** | **str** | Email address | [optional] -**address** | **str** | Address | [optional] -**city** | **str** | City | [optional] -**state** | **str** | State | [optional] -**zip** | **str** | Zip code | [optional] -**foreign_province** | **str** | Foreign province | [optional] -**transfer_agent_name** | **str** | Transfer Agent's Name | [optional] -**last_filing** | **bool** | Last year of filing for this payer | [optional] -**created_at** | **datetime** | Date time when the issuer was created | [optional] [readonly] -**updated_at** | **datetime** | Date time when the issuer was updated | [optional] [readonly] +**id** | **str** | Unique identifier set when the record is created. | [optional] +**created_at** | **datetime** | Date time when the record was created. | [optional] +**updated_at** | **datetime** | Date time when the record was last updated. | [optional] +**name** | **str** | Legal name. Not the DBA name. | +**dba_name** | **str** | Doing Business As (DBA) name or continuation of a long legal name. Use either this or 'transferAgentName'. | [optional] +**tin** | **str** | Federal Tax Identification Number (TIN). | [optional] +**reference_id** | **str** | Internal reference ID. Never shown to any agency or recipient. If present, it will prefix download filenames. Allowed characters: letters, numbers, dashes, underscores, and spaces. | [optional] +**telephone** | **str** | Contact phone number (must contain at least 10 digits, max 15 characters). For recipient inquiries. | +**tax_year** | **int** | Tax year for which the forms are being filed (e.g., 2024). Must be within current tax year and current tax year - 4. | +**country_code** | **str** | Two-letter IRS country code (e.g., 'US', 'CA'), as defined at https://www.irs.gov/e-file-providers/country-codes. If there is a transfer agent, use the transfer agent's shipping address. | [optional] +**email** | **str** | Contact email address. For recipient inquiries. | +**address** | **str** | Address. | +**city** | **str** | City. | +**state** | **str** | Two-letter US state or Canadian province code (required for US/CA addresses). | +**zip** | **str** | ZIP/postal code. | +**foreign_province** | **str** | Province or region for non-US/CA addresses. | [optional] +**transfer_agent_name** | **str** | Name of the transfer agent, if applicable — optional; use either this or 'dbaName'. | [optional] +**last_filing** | **bool** | Indicates if this is the issuer's final year filing. | ## Example diff --git a/docs/A1099/V2/Issuers1099Api.md b/docs/A1099/V2/Issuers1099Api.md index e66748d..b25c5d1 100644 --- a/docs/A1099/V2/Issuers1099Api.md +++ b/docs/A1099/V2/Issuers1099Api.md @@ -1,6 +1,6 @@ # Avalara.SDK.Issuers1099Api -All URIs are relative to *https://api-ava1099.eta.sbx.us-east-1.aws.avalara.io/avalara1099* +All URIs are relative to *https://api.sbx.avalara.com/avalara1099* Method | HTTP request | Description ------------- | ------------- | ------------- @@ -26,7 +26,7 @@ Create an issuer (also known as a Payer). import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import issuers1099_api -IssuerCommand +CreateIssuerRequest IssuerResponse ErrorResponse from pprint import pprint @@ -45,9 +45,9 @@ 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 = 'd2b38090-a4c9-4170-bc1d-6cc2778b0bd0' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '44b5fa45-dc8f-4939-9259-55c44e371c83' # 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) + create_issuer_request = {"name":"Acme Corporation","dbaName":"Acme Widgets","tin":"94-2765431","referenceId":"issuer-001","telephone":"+1-555-123-4567","taxYear":2024,"countryCode":"US","email":"support@acmecorp.com","address":"123 Main Street","city":"San Francisco","state":"CA","zip":"94105","foreignProvince":"","transferAgentName":"","lastFiling":false} # CreateIssuerRequest | The issuer to create (optional) # example passing only required values which don't have defaults set try: # Create an issuer @@ -60,7 +60,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Create an issuer - api_response = api_instance.create_issuer(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, issuer_command=issuer_command) + api_response = api_instance.create_issuer(avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, create_issuer_request=create_issuer_request) pprint(api_response) except Avalara.SDK.ApiException as e: print("Exception when calling Issuers1099Api->create_issuer: %s\n" % e) @@ -73,7 +73,7 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **issuer_command** | [**IssuerCommand**](IssuerCommand.md)| The issuer to create | [optional] + **create_issuer_request** | [**CreateIssuerRequest**](CreateIssuerRequest.md)| The issuer to create | [optional] ### Return type @@ -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 = '22e9dc96-0041-4e27-ab37-038dc9d6c215' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '18937e11-5cfa-4f80-b4ff-a8fdee349cf1' # 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 = '86c9eff5-1ed3-49b1-be09-a117b235f3e2' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '8e5147e0-a97c-47f5-9791-3ea7d3bf7f16' # 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 = '0983f292-e1e0-4415-9cdc-b70482da76b0' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'da351fbb-2f00-42a7-8c6f-e3864f4bbf0c' # 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: @@ -384,7 +384,7 @@ Update an issuer (also known as a Payer). import time import Avalara.SDK from Avalara.SDK.api.A1099.V2 import issuers1099_api -IssuerCommand +CreateIssuerRequest ErrorResponse from pprint import pprint @@ -403,9 +403,9 @@ 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 = 'f43f2c52-c35e-4e50-b1ad-2923b624e5a0' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '07298ef1-41b1-4610-9275-331b7ae88439' # 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) + create_issuer_request = {"name":"Acme Corporation","dbaName":"Acme Widgets","tin":"94-2765431","referenceId":"issuer-001","telephone":"+1-555-123-4567","taxYear":2024,"countryCode":"US","email":"support@acmecorp.com","address":"123 Main Street","city":"San Francisco","state":"CA","zip":"94105","foreignProvince":"","transferAgentName":"","lastFiling":false} # CreateIssuerRequest | The issuer to update (optional) # example passing only required values which don't have defaults set try: # Update an issuer @@ -417,7 +417,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: # and optional values try: # Update an issuer - api_instance.update_issuer(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, issuer_command=issuer_command) + api_instance.update_issuer(id, avalara_version, x_correlation_id=x_correlation_id, x_avalara_client=x_avalara_client, create_issuer_request=create_issuer_request) except Avalara.SDK.ApiException as e: print("Exception when calling Issuers1099Api->update_issuer: %s\n" % e) ``` @@ -430,7 +430,7 @@ Name | Type | Description | Notes **avalara_version** | **str**| API version | **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] - **issuer_command** | [**IssuerCommand**](IssuerCommand.md)| The issuer to update | [optional] + **create_issuer_request** | [**CreateIssuerRequest**](CreateIssuerRequest.md)| The issuer to update | [optional] ### Return type diff --git a/docs/A1099/V2/JobResponse.md b/docs/A1099/V2/JobResponse.md new file mode 100644 index 0000000..b95f9e8 --- /dev/null +++ b/docs/A1099/V2/JobResponse.md @@ -0,0 +1,49 @@ +# JobResponse + +Response model for job operations + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Unique identifier for the job | [optional] +**type** | **str** | Job type identifier. Will always be \"update_job\" for bulk upsert operations | [optional] +**status** | **str** | Current status of the job (e.g., Success, Failed, InProgress) | [optional] +**error_message** | **str** | Error message if the job failed, null otherwise | [optional] +**total_processed** | **int** | Total number of forms processed. Value can be 0 or another value based on what the job has available | [optional] +**total_rows** | **int** | Total number of forms in the request. Value can be 0 or another value based on what the job has available | [optional] +**updated_valid** | **int** | Number of forms updated and valid for e-filing and e-delivery. Value can be 0 or another value based on what the job has available | [optional] +**updated_no_email** | **int** | Number of forms updated and valid for e-filing but missing email or email is undeliverable. Value can be 0 or another value based on what the job has available | [optional] +**updated_invalid** | **int** | Number of forms updated but invalid for e-filing. Value can be 0 or another value based on what the job has available | [optional] +**skipped_duplicate** | **int** | Number of forms skipped because they would have updated a record already updated once in the request. Value can be 0 or another value based on what the job has available | [optional] +**skipped_invalid** | **int** | Number of forms skipped because they would have made a form invalid and the form is already e-filed or scheduled for e-filing. Value can be 0 or another value based on what the job has available | [optional] +**skipped_multiple_matches** | **int** | Number of forms skipped because they matched multiple forms. Value can be 0 or another value based on what the job has available | [optional] +**not_found** | **int** | Number of forms skipped because no matching form or issuer could be found. Value can be 0 or another value based on what the job has available | [optional] +**created_invalid** | **int** | Number of new forms created because no matching form could be found (and `upsert` was true) - with errors. Value can be 0 or another value based on what the job has available | [optional] +**created_no_email** | **int** | Number of new forms created because no matching form could be found (and `upsert` was true) - valid for e-filing but missing email or email is undeliverable. Value can be 0 or another value based on what the job has available | [optional] +**created_valid** | **int** | Number of new forms created because no matching form could be found (and `upsert` was true) - valid for e-filing and e-delivery. Value can be 0 or another value based on what the job has available | [optional] +**dry_run** | **bool** | Dry run. If `true`, this job only simulates the changes but doesn't actually persist them. | [optional] +**upsert** | **bool** | Upsert. If `true`, this job will first attempt to update existing records if matches can be found. Matches are done in the following order: Form ID, Form Reference ID and tax year, Form TIN and tax year. | [optional] +**link** | **str** | Link to access the job details | [optional] +**processed_forms** | [**List[Get1099Form200Response]**](Get1099Form200Response.md) | List of processed forms returned when bulk-upsert processes ≤1000 records. Same format as GET /1099/forms response. Only available in bulk-upsert endpoint responses. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.job_response import JobResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of JobResponse from a JSON string +job_response_instance = JobResponse.from_json(json) +# print the JSON string representation of the object +print(JobResponse.to_json()) + +# convert the object into a dict +job_response_dict = job_response_instance.to_dict() +# create an instance of JobResponse from a dict +job_response_from_dict = JobResponse.from_dict(job_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/JobsApi.md b/docs/A1099/V2/JobsApi.md new file mode 100644 index 0000000..f500ab4 --- /dev/null +++ b/docs/A1099/V2/JobsApi.md @@ -0,0 +1,98 @@ +# Avalara.SDK.JobsApi + +All URIs are relative to *https://api.sbx.avalara.com/avalara1099* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**get_job**](JobsApi.md#get_job) | **GET** /jobs/{id} | Retrieves information about the job + + +# **get_job** +> JobResponse get_job(id, avalara_version) + +Retrieves information about the job + +Retrieves information about the job + +### Example + +* Bearer Authentication (bearer): + +```python +import time +import Avalara.SDK +from Avalara.SDK.api.A1099.V2 import jobs_api +JobResponse +ErrorResponse +from pprint import pprint + +# Define configuration object with parameters specified to your application. +configuration = Avalara.SDK.Configuration( + app_name='test app' + app_version='1.0' + machine_name='some machine' + client_id='' + client_secret='' + environment='sandbox' +) +# Enter a context with an instance of the API client +with Avalara.SDK.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = jobs_api.JobsApi(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 = '19c729e6-45f1-4b1f-8a4c-a1293f8da8bd' # 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: + # Retrieves information about the job + api_response = api_instance.get_job(id, avalara_version) + pprint(api_response) + except Avalara.SDK.ApiException as e: + print("Exception when calling JobsApi->get_job: %s\n" % e) + + # example passing only required values which don't have defaults set + # and optional values + try: + # Retrieves information about the job + api_response = api_instance.get_job(id, avalara_version, 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 JobsApi->get_job: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| Job id obtained from other API responses, like `/1099/bulk-upsert`. | + **avalara_version** | **str**| API version | + **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 + +[**JobResponse**](JobResponse.md) + +### Authorization + +[bearer](../README.md#bearer) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Success | - | +**400** | Bad Request | - | +**404** | Not Found | - | +**500** | Server Error | - | +**401** | Unauthorized | - | + +[[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) + diff --git a/docs/A1099/V2/OfferAndCoverage.md b/docs/A1099/V2/OfferAndCoverage.md new file mode 100644 index 0000000..846b311 --- /dev/null +++ b/docs/A1099/V2/OfferAndCoverage.md @@ -0,0 +1,35 @@ +# OfferAndCoverage + +Offer and coverage information for health coverage forms + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | Id | [optional] [readonly] +**month** | **str** | Month of coverage. Available values: - All: All months - January: January - February: February - March: March - April: April - May: May - June: June - July: July - August: August - September: September - October: October - November: November - December: December | [optional] +**offer_code** | **str** | Offer of Coverage Code. Required if Share has a value, including zero. Available values: Pre-ICHRA Codes (available before 2020): - 1A: Qualifying offer: minimum essential coverage providing minimum value offered to full-time employee with employee required contribution ≤ 9.5% (as adjusted) of mainland single federal poverty line and at least minimum essential coverage offered to spouse and dependent(s) - 1B: Minimum essential coverage providing minimum value offered to employee only - 1C: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to dependent(s) (not spouse) - 1D: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to spouse (not dependent(s)) - 1E: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage offered to dependent(s) and spouse - 1F: Minimum essential coverage NOT providing minimum value offered to employee; employee and spouse or dependent(s); or employee, spouse, and dependents - 1G: Offer of coverage to an individual who was not an employee or not a full-time employee and who enrolled in self-insured coverage - 1H: No offer of coverage (employee not offered any health coverage or employee offered coverage that is not minimum essential coverage) - 1J: Minimum essential coverage providing minimum value offered to employee and at least minimum essential coverage conditionally offered to spouse; minimum essential coverage not offered to dependent(s) - 1K: Minimum essential coverage providing minimum value offered to employee; at least minimum essential coverage offered to dependents; and at least minimum essential coverage conditionally offered to spouse ICHRA Codes (introduced 2020, require ZIP code): - 1L: Individual coverage HRA offered to employee only - 1M: Individual coverage HRA offered to employee and dependent(s) (not spouse) - 1N: Individual coverage HRA offered to employee, spouse, and dependent(s) - 1O: Individual coverage HRA offered to employee only using employment site ZIP code affordability safe harbor - 1P: Individual coverage HRA offered to employee and dependent(s) (not spouse) using employment site ZIP code affordability safe harbor - 1Q: Individual coverage HRA offered to employee, spouse, and dependent(s) using employment site ZIP code affordability safe harbor - 1R: Individual coverage HRA that is NOT affordable - 1S: Individual coverage HRA offered to an individual who was not a full-time employee - 1T: Individual coverage HRA offered to employee and spouse (not dependents) - 1U: Individual coverage HRA offered to employee and spouse (not dependents) using employment site ZIP code affordability safe harbor Note: Codes 1B, 1C, 1D, 1E, 1J, 1K, 1L, 1M, 1N, 1O, 1P, 1Q, 1T, 1U require employee share amount (0.00 is a valid value). | [optional] +**share** | **float** | Employee required contribution share - Employee Share of Lowest Cost Monthly Premium, for Self-Only Minimum Value Coverage - May not exceed 3499.99 | [optional] +**safe_harbor_code** | **str** | Safe harbor code - Applicable Section 4980H Safe Harbor Code. Available values: - 2A: Form W-2 safe harbor - 2B: Federal poverty line safe harbor - 2C: Rate of pay safe harbor - 2D: Part-time employee safe harbor for employees who were not full-time for any month of the year - 2E: Multiemployer interim rule relief - 2F: Qualifying offer method - 2G: Qualifying offer transition relief - 2H: Other affordability safe harbor | [optional] +**zip_code** | **str** | ZIP/postal code. For coverage area (optional, unless codes 1L to 1U are used). | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.offer_and_coverage import OfferAndCoverage + +# TODO update the JSON string below +json = "{}" +# create an instance of OfferAndCoverage from a JSON string +offer_and_coverage_instance = OfferAndCoverage.from_json(json) +# print the JSON string representation of the object +print(OfferAndCoverage.to_json()) + +# convert the object into a dict +offer_and_coverage_dict = offer_and_coverage_instance.to_dict() +# create an instance of OfferAndCoverage from a dict +offer_and_coverage_from_dict = OfferAndCoverage.from_dict(offer_and_coverage_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/PaginatedQueryResultModelForm1099Base.md b/docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md new file mode 100644 index 0000000..2dfdb32 --- /dev/null +++ b/docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md @@ -0,0 +1,32 @@ +# PaginatedQueryResultModelForm1099Base + +Generic paginated model to wrap query response data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**recordset_count** | **int** | | [optional] +**value** | [**List[Get1099Form200Response]**](Get1099Form200Response.md) | | [optional] +**next_link** | **str** | | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.paginated_query_result_model_form1099_base import PaginatedQueryResultModelForm1099Base + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedQueryResultModelForm1099Base from a JSON string +paginated_query_result_model_form1099_base_instance = PaginatedQueryResultModelForm1099Base.from_json(json) +# print the JSON string representation of the object +print(PaginatedQueryResultModelForm1099Base.to_json()) + +# convert the object into a dict +paginated_query_result_model_form1099_base_dict = paginated_query_result_model_form1099_base_instance.to_dict() +# create an instance of PaginatedQueryResultModelForm1099Base from a dict +paginated_query_result_model_form1099_base_from_dict = PaginatedQueryResultModelForm1099Base.from_dict(paginated_query_result_model_form1099_base_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/PrimaryWithholdingAgent.md b/docs/A1099/V2/PrimaryWithholdingAgent.md index d107519..60b88d4 100644 --- a/docs/A1099/V2/PrimaryWithholdingAgent.md +++ b/docs/A1099/V2/PrimaryWithholdingAgent.md @@ -1,12 +1,13 @@ # PrimaryWithholdingAgent +Primary withholding agent information for tax forms ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**primary_withholding_agent_name** | **str** | | [optional] -**primary_withholding_agent_ein** | **str** | | [optional] +**name** | **str** | Name of the primary withholding agent | +**ein** | **str** | EIN (Employer Identification Number) of the primary withholding agent. | ## Example diff --git a/docs/A1099/V2/StateAndLocalWithholding.md b/docs/A1099/V2/StateAndLocalWithholding.md index 029a210..43f692d 100644 --- a/docs/A1099/V2/StateAndLocalWithholding.md +++ b/docs/A1099/V2/StateAndLocalWithholding.md @@ -5,14 +5,14 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**state_tax_withheld** | **float** | | [optional] -**state** | **str** | | [optional] -**state_id_number** | **str** | | [optional] -**state_income** | **float** | | [optional] -**local_tax_withheld** | **float** | | [optional] -**locality** | **str** | | [optional] -**locality_id_number** | **str** | | [optional] -**local_income** | **float** | | [optional] +**state_tax_withheld** | **float** | Amount of state tax that was withheld | [optional] +**state** | **str** | US state | [optional] +**state_id_number** | **str** | State ID number of the entity issuing the form | [optional] +**state_income** | **float** | Amount of state income | [optional] +**local_tax_withheld** | **float** | Amount of local tax that was withheld | [optional] +**locality** | **str** | Locality name | [optional] +**locality_id_number** | **str** | Locality ID number of the entity issuing the form | [optional] +**local_income** | **float** | Amount of local income | [optional] ## Example diff --git a/docs/A1099/V2/ValidationError.md b/docs/A1099/V2/ValidationError.md index 3788de2..e6abe07 100644 --- a/docs/A1099/V2/ValidationError.md +++ b/docs/A1099/V2/ValidationError.md @@ -5,8 +5,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**var_field** | **str** | | [optional] -**errors** | **List[str]** | | [optional] +**var_field** | **str** | The field containing the error | [optional] +**errors** | **List[str]** | The list of error messages | [optional] ## Example diff --git a/docs/A1099/V2/W4FormMinimalRequest.md b/docs/A1099/V2/W4FormMinimalRequest.md new file mode 100644 index 0000000..da76e8b --- /dev/null +++ b/docs/A1099/V2/W4FormMinimalRequest.md @@ -0,0 +1,35 @@ +# W4FormMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type (always \"w4\" for this model). | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**employee_first_name** | **str** | The first name of the employee. | +**employee_last_name** | **str** | The last name of the employee. | +**office_code** | **str** | The office code associated with the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w4_form_minimal_request import W4FormMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W4FormMinimalRequest from a JSON string +w4_form_minimal_request_instance = W4FormMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W4FormMinimalRequest.to_json()) + +# convert the object into a dict +w4_form_minimal_request_dict = w4_form_minimal_request_instance.to_dict() +# create an instance of W4FormMinimalRequest from a dict +w4_form_minimal_request_from_dict = W4FormMinimalRequest.from_dict(w4_form_minimal_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/W4FormRequest.md b/docs/A1099/V2/W4FormRequest.md index b90a0f2..cc4bb37 100644 --- a/docs/A1099/V2/W4FormRequest.md +++ b/docs/A1099/V2/W4FormRequest.md @@ -25,11 +25,11 @@ 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] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8BenEFormMinimalRequest.md b/docs/A1099/V2/W8BenEFormMinimalRequest.md new file mode 100644 index 0000000..afd469a --- /dev/null +++ b/docs/A1099/V2/W8BenEFormMinimalRequest.md @@ -0,0 +1,34 @@ +# W8BenEFormMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type (always \"w8bene\" for this model). | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**name** | **str** | The name of the individual or entity associated with the form. | +**reference_number** | **str** | A reference number for the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w8_ben_e_form_minimal_request import W8BenEFormMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W8BenEFormMinimalRequest from a JSON string +w8_ben_e_form_minimal_request_instance = W8BenEFormMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W8BenEFormMinimalRequest.to_json()) + +# convert the object into a dict +w8_ben_e_form_minimal_request_dict = w8_ben_e_form_minimal_request_instance.to_dict() +# create an instance of W8BenEFormMinimalRequest from a dict +w8_ben_e_form_minimal_request_from_dict = W8BenEFormMinimalRequest.from_dict(w8_ben_e_form_minimal_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/W8BenEFormRequest.md b/docs/A1099/V2/W8BenEFormRequest.md index 60e686a..8019a26 100644 --- a/docs/A1099/V2/W8BenEFormRequest.md +++ b/docs/A1099/V2/W8BenEFormRequest.md @@ -101,11 +101,11 @@ Name | Type | Description | Notes **substantial_us_owners** | [**List[SubstantialUsOwnerRequest]**](SubstantialUsOwnerRequest.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] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8BenFormMinimalRequest.md b/docs/A1099/V2/W8BenFormMinimalRequest.md new file mode 100644 index 0000000..986d08a --- /dev/null +++ b/docs/A1099/V2/W8BenFormMinimalRequest.md @@ -0,0 +1,34 @@ +# W8BenFormMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type (always \"w8ben\" for this model). | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**name** | **str** | The name of the individual or entity associated with the form. | +**reference_number** | **str** | A reference number for the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w8_ben_form_minimal_request import W8BenFormMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W8BenFormMinimalRequest from a JSON string +w8_ben_form_minimal_request_instance = W8BenFormMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W8BenFormMinimalRequest.to_json()) + +# convert the object into a dict +w8_ben_form_minimal_request_dict = w8_ben_form_minimal_request_instance.to_dict() +# create an instance of W8BenFormMinimalRequest from a dict +w8_ben_form_minimal_request_from_dict = W8BenFormMinimalRequest.from_dict(w8_ben_form_minimal_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/W8BenFormRequest.md b/docs/A1099/V2/W8BenFormRequest.md index e022140..c38d27d 100644 --- a/docs/A1099/V2/W8BenFormRequest.md +++ b/docs/A1099/V2/W8BenFormRequest.md @@ -30,11 +30,11 @@ Name | Type | Description | Notes **withholding_rate** | **str** | The withholding rate applied as per the treaty. | [optional] **income_type** | **str** | The type of income covered by the treaty. | [optional] **signer_name** | **str** | The name of the signer of the form. | [optional] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] ## Example diff --git a/docs/A1099/V2/W8ImyFormMinimalRequest.md b/docs/A1099/V2/W8ImyFormMinimalRequest.md new file mode 100644 index 0000000..92e722f --- /dev/null +++ b/docs/A1099/V2/W8ImyFormMinimalRequest.md @@ -0,0 +1,34 @@ +# W8ImyFormMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type (always \"w8imy\" for this model). | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**name** | **str** | The name of the individual or entity associated with the form. | +**reference_number** | **str** | A reference number for the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w8_imy_form_minimal_request import W8ImyFormMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W8ImyFormMinimalRequest from a JSON string +w8_imy_form_minimal_request_instance = W8ImyFormMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W8ImyFormMinimalRequest.to_json()) + +# convert the object into a dict +w8_imy_form_minimal_request_dict = w8_imy_form_minimal_request_instance.to_dict() +# create an instance of W8ImyFormMinimalRequest from a dict +w8_imy_form_minimal_request_from_dict = W8ImyFormMinimalRequest.from_dict(w8_imy_form_minimal_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/W8ImyFormRequest.md b/docs/A1099/V2/W8ImyFormRequest.md index 6619097..7a30a19 100644 --- a/docs/A1099/V2/W8ImyFormRequest.md +++ b/docs/A1099/V2/W8ImyFormRequest.md @@ -117,11 +117,11 @@ 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] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] ## Example diff --git a/docs/A1099/V2/W9FormBaseMinimalRequest.md b/docs/A1099/V2/W9FormBaseMinimalRequest.md new file mode 100644 index 0000000..aa94b35 --- /dev/null +++ b/docs/A1099/V2/W9FormBaseMinimalRequest.md @@ -0,0 +1,32 @@ +# W9FormBaseMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type. | [optional] [readonly] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w9_form_base_minimal_request import W9FormBaseMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W9FormBaseMinimalRequest from a JSON string +w9_form_base_minimal_request_instance = W9FormBaseMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W9FormBaseMinimalRequest.to_json()) + +# convert the object into a dict +w9_form_base_minimal_request_dict = w9_form_base_minimal_request_instance.to_dict() +# create an instance of W9FormBaseMinimalRequest from a dict +w9_form_base_minimal_request_from_dict = W9FormBaseMinimalRequest.from_dict(w9_form_base_minimal_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/W9FormBaseRequest.md b/docs/A1099/V2/W9FormBaseRequest.md index 4bb0f81..af2e7fa 100644 --- a/docs/A1099/V2/W9FormBaseRequest.md +++ b/docs/A1099/V2/W9FormBaseRequest.md @@ -5,12 +5,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] +**signature** | **str** | The signature of the form. | [optional] **type** | **str** | The form type. | [optional] [readonly] -**company_id** | **str** | The ID of the associated company. | [optional] +**company_id** | **str** | The ID of the associated company. | **reference_id** | **str** | A reference identifier for the form. | [optional] **email** | **str** | The email address of the individual associated with the form. | [optional] -**e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] -**signature** | **str** | The signature of the form. | [optional] ## Example diff --git a/docs/A1099/V2/W9FormBaseResponse.md b/docs/A1099/V2/W9FormBaseResponse.md index a905615..32cd808 100644 --- a/docs/A1099/V2/W9FormBaseResponse.md +++ b/docs/A1099/V2/W9FormBaseResponse.md @@ -6,13 +6,13 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **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] +**entry_status** | [**EntryStatusResponse**](EntryStatusResponse.md) | The entry status information for the form. | [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] +**ancestor_id** | **str** | Form ID of previous version. | [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] diff --git a/docs/A1099/V2/W9FormMinimalRequest.md b/docs/A1099/V2/W9FormMinimalRequest.md new file mode 100644 index 0000000..6f53d38 --- /dev/null +++ b/docs/A1099/V2/W9FormMinimalRequest.md @@ -0,0 +1,34 @@ +# W9FormMinimalRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **str** | The form type (always \"w9\" for this model). | [optional] [readonly] +**email** | **str** | The email address of the individual associated with the form. | +**name** | **str** | The name of the individual or entity associated with the form. | +**account_number** | **str** | The account number associated with the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] + +## Example + +```python +from Avalara.SDK.models.A1099.V2.w9_form_minimal_request import W9FormMinimalRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of W9FormMinimalRequest from a JSON string +w9_form_minimal_request_instance = W9FormMinimalRequest.from_json(json) +# print the JSON string representation of the object +print(W9FormMinimalRequest.to_json()) + +# convert the object into a dict +w9_form_minimal_request_dict = w9_form_minimal_request_instance.to_dict() +# create an instance of W9FormMinimalRequest from a dict +w9_form_minimal_request_from_dict = W9FormMinimalRequest.from_dict(w9_form_minimal_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/W9FormRequest.md b/docs/A1099/V2/W9FormRequest.md index bdb7229..5801993 100644 --- a/docs/A1099/V2/W9FormRequest.md +++ b/docs/A1099/V2/W9FormRequest.md @@ -24,11 +24,11 @@ Name | Type | Description | Notes **tin** | **str** | The taxpayer identification number (TIN). | [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] -**company_id** | **str** | The ID of the associated company. | [optional] -**reference_id** | **str** | A reference identifier for the form. | [optional] -**email** | **str** | The email address of the individual associated with the form. | [optional] **e_delivery_consented_at** | **datetime** | The date when e-delivery was consented. | [optional] **signature** | **str** | The signature of the form. | [optional] +**company_id** | **str** | The ID of the associated company. | +**reference_id** | **str** | A reference identifier for the form. | [optional] +**email** | **str** | The email address of the individual associated with the form. | [optional] ## Example diff --git a/setup.py b/setup.py index 7991f12..4a2505a 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.2 +@version 25.8.3 @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.2" +VERSION = "25.8.3" PYTHON_REQUIRES = ">=3.7" REQUIRES = [ "urllib3 >= 1.25.3, < 2.1.0", From 369132982c935a867c843d4210403fb554db0290 Mon Sep 17 00:00:00 2001 From: Jonathan Wenger Date: Fri, 29 Aug 2025 08:02:20 -0700 Subject: [PATCH 2/2] 25.8.3 --- Avalara/SDK/api/A1099/V2/jobs1099_api.py | 2 +- .../A1099/V2/bulk_upsert1099_forms_request.py | 18 +- .../A1099/V2/create1099_form201_response.py | 18 +- Avalara/SDK/models/A1099/V2/data.py | 4 +- .../A1099/V2/error_response_errors_inner.py | 4 +- .../SDK/models/A1099/V2/form1042_s_list.py | 2 +- .../models/A1099/V2/form1042_s_list_item.py | 6 +- .../A1099/V2/form1042_s_list_item_response.py | 12 +- .../SDK/models/A1099/V2/form1042_s_request.py | 6 +- .../models/A1099/V2/form1042_s_response.py | 8 +- .../SDK/models/A1099/V2/form1095_b_list.py | 2 +- .../models/A1099/V2/form1095_b_list_item.py | 4 +- .../A1099/V2/form1095_b_list_item_response.py | 10 +- .../SDK/models/A1099/V2/form1095_b_request.py | 4 +- .../models/A1099/V2/form1095_b_response.py | 10 +- .../SDK/models/A1099/V2/form1095_c_list.py | 2 +- .../models/A1099/V2/form1095_c_list_item.py | 6 +- .../models/A1099/V2/form1099_base_response.py | 8 +- .../SDK/models/A1099/V2/form1099_div_list.py | 2 +- .../models/A1099/V2/form1099_div_list_item.py | 2 +- .../V2/form1099_div_list_item_response.py | 8 +- .../models/A1099/V2/form1099_div_request.py | 2 +- .../models/A1099/V2/form1099_div_response.py | 8 +- .../SDK/models/A1099/V2/form1099_int_list.py | 2 +- .../models/A1099/V2/form1099_int_list_item.py | 2 +- .../V2/form1099_int_list_item_response.py | 8 +- .../models/A1099/V2/form1099_int_request.py | 2 +- .../models/A1099/V2/form1099_int_response.py | 8 +- .../SDK/models/A1099/V2/form1099_k_list.py | 2 +- .../models/A1099/V2/form1099_k_list_item.py | 2 +- .../A1099/V2/form1099_k_list_item_response.py | 8 +- .../SDK/models/A1099/V2/form1099_k_request.py | 2 +- .../models/A1099/V2/form1099_k_response.py | 8 +- Avalara/SDK/models/A1099/V2/form1099_list.py | 116 ---------- .../A1099/V2/form1099_list_data_inner.py | 184 ---------------- .../models/A1099/V2/form1099_list_response.py | 2 +- .../V2/form1099_list_response_value_inner.py | 18 +- .../SDK/models/A1099/V2/form1099_misc_list.py | 2 +- .../A1099/V2/form1099_misc_list_item.py | 2 +- .../V2/form1099_misc_list_item_response.py | 8 +- .../models/A1099/V2/form1099_misc_request.py | 2 +- .../models/A1099/V2/form1099_misc_response.py | 8 +- .../SDK/models/A1099/V2/form1099_nec_list.py | 2 +- .../models/A1099/V2/form1099_nec_list_item.py | 2 +- .../V2/form1099_nec_list_item_response.py | 8 +- .../models/A1099/V2/form1099_nec_request.py | 2 +- .../models/A1099/V2/form1099_nec_response.py | 8 +- .../A1099/V2/form1099_proccess_result.py | 4 +- ...9_proccess_result_processed_forms_inner.py | 16 +- .../SDK/models/A1099/V2/form1099_r_list.py | 2 +- .../models/A1099/V2/form1099_r_list_item.py | 2 +- .../A1099/V2/form1099_r_list_item_response.py | 8 +- .../SDK/models/A1099/V2/form1099_r_request.py | 2 +- .../models/A1099/V2/form1099_r_response.py | 8 +- .../SDK/models/A1099/V2/form_request_base.py | 2 +- .../models/A1099/V2/form_request_csv_base.py | 202 ------------------ .../A1099/V2/form_request_list_item_base.py | 2 +- .../SDK/models/A1099/V2/form_request_model.py | 143 ------------- .../SDK/models/A1099/V2/form_response_base.py | 8 +- .../A1099/V2/form_single_request_base.py | 2 +- .../A1099/V2/i_create_form1099_request.py | 8 +- .../A1099/V2/i_update_form1099_request.py | 8 +- .../A1099/V2/paginated_w9_forms_model.py | 2 +- .../A1099/V2/state_efile_status_detail_app.py | 122 ----------- .../A1099/V2/update1099_form200_response.py | 18 +- .../models/A1099/V2/validation_error_app.py | 115 ---------- .../V1/directory_search_response.py | 115 ---------- .../directory_search_response_value_inner.py | 140 ------------ ...ch_response_value_inner_addresses_inner.py | 111 ---------- ..._response_value_inner_identifiers_inner.py | 105 --------- ...ue_inner_supported_document_types_inner.py | 109 ---------- .../EInvoicing/V1/document_fetch_request.py | 117 ---------- .../V1/document_fetch_request_data_inner.py | 105 --------- .../V1/document_fetch_request_metadata.py | 111 ---------- docs/A1099/V2/CompaniesW9Api.md | 10 +- docs/A1099/V2/Forms1099Api.md | 14 +- docs/A1099/V2/FormsW9Api.md | 16 +- docs/A1099/V2/Issuers1099Api.md | 10 +- docs/A1099/V2/JobsApi.md | 2 +- 79 files changed, 200 insertions(+), 1995 deletions(-) delete mode 100644 Avalara/SDK/models/A1099/V2/form1099_list.py delete mode 100644 Avalara/SDK/models/A1099/V2/form1099_list_data_inner.py delete mode 100644 Avalara/SDK/models/A1099/V2/form_request_csv_base.py delete mode 100644 Avalara/SDK/models/A1099/V2/form_request_model.py delete mode 100644 Avalara/SDK/models/A1099/V2/state_efile_status_detail_app.py delete mode 100644 Avalara/SDK/models/A1099/V2/validation_error_app.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/directory_search_response.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_addresses_inner.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_identifiers_inner.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_supported_document_types_inner.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/document_fetch_request.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/document_fetch_request_data_inner.py delete mode 100644 Avalara/SDK/models/EInvoicing/V1/document_fetch_request_metadata.py diff --git a/Avalara/SDK/api/A1099/V2/jobs1099_api.py b/Avalara/SDK/api/A1099/V2/jobs1099_api.py index 7d6ec9f..1c2b42a 100644 --- a/Avalara/SDK/api/A1099/V2/jobs1099_api.py +++ b/Avalara/SDK/api/A1099/V2/jobs1099_api.py @@ -43,7 +43,7 @@ from pydantic import Field, StrictStr from typing import Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.A1099.V2.job_result import JobResult +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.job_result import JobResult from Avalara.SDK.exceptions import ApiTypeError, ApiValueError, ApiException from Avalara.SDK.oauth_helper.AvalaraSdkOauthUtils import avalara_retry_oauth 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 920fec0..100714d 100644 --- a/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py +++ b/Avalara/SDK/models/A1099/V2/bulk_upsert1099_forms_request.py @@ -33,15 +33,15 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list import Form1042SList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list import Form1095BList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_c_list import Form1095CList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list import Form1099DivList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list import Form1099IntList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list import Form1099KList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list import Form1099MiscList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list import Form1099NecList -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list import Form1099RList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s_list import Form1042SList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b_list import Form1095BList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_c_list import Form1095CList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_list import Form1099DivList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int_list import Form1099IntList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_list import Form1099KList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_list import Form1099MiscList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_list import Form1099NecList +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_r_list import Form1099RList 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/create1099_form201_response.py b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py index b07b2a2..a89eb74 100644 --- a/Avalara/SDK/models/A1099/V2/create1099_form201_response.py +++ b/Avalara/SDK/models/A1099/V2/create1099_form201_response.py @@ -33,15 +33,15 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse 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/data.py b/Avalara/SDK/models/A1099/V2/data.py index 4970503..5a29062 100644 --- a/Avalara/SDK/models/A1099/V2/data.py +++ b/Avalara/SDK/models/A1099/V2/data.py @@ -35,8 +35,8 @@ from pydantic import BaseModel, ConfigDict, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.attribute import Attribute -from Avalara.SDK.models.A1099.V2.A1099.V2.link import Link +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.attribute import Attribute +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.link import Link from typing import Optional, Set from typing_extensions import Self 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 7df3696..eb514e2 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.A1099.V2.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails -from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.problem_details import ProblemDetails +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.A1099.V2.http_validation_problem_details import HttpValidationProblemDetails +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.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/form1042_s_list.py b/Avalara/SDK/models/A1099/V2/form1042_s_list.py index 7a60b21..887ef14 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item import Form1042SListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s_list_item import Form1042SListItem from typing import Optional, Set from typing_extensions import Self 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 0a54959..4fac641 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_list_item.py @@ -36,9 +36,9 @@ 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.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough -from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent import PrimaryWithholdingAgent -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.intermediary_or_flow_through import IntermediaryOrFlowThrough +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.primary_withholding_agent import PrimaryWithholdingAgent +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 8977de5..38c2ae4 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 @@ -37,12 +37,12 @@ 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.A1099.V2.intermediary_or_flow_through_response import IntermediaryOrFlowThroughResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent_response import PrimaryWithholdingAgentResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.intermediary_or_flow_through_response import IntermediaryOrFlowThroughResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.primary_withholding_agent_response import PrimaryWithholdingAgentResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_request.py b/Avalara/SDK/models/A1099/V2/form1042_s_request.py index e9d7966..3cdc8a4 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_request.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_request.py @@ -36,9 +36,9 @@ 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.A1099.V2.intermediary_or_flow_through_request import IntermediaryOrFlowThroughRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.primary_withholding_agent_request import PrimaryWithholdingAgentRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.intermediary_or_flow_through_request import IntermediaryOrFlowThroughRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.primary_withholding_agent_request import PrimaryWithholdingAgentRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1042_s_response.py b/Avalara/SDK/models/A1099/V2/form1042_s_response.py index 1d5cd50..a21b4ea 100644 --- a/Avalara/SDK/models/A1099/V2/form1042_s_response.py +++ b/Avalara/SDK/models/A1099/V2/form1042_s_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_list.py b/Avalara/SDK/models/A1099/V2/form1095_b_list.py index 0867dec..0efd567 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item import Form1095BListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b_list_item import Form1095BListItem from typing import Optional, Set from typing_extensions import Self 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 0c71e56..09ad1d7 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_list_item.py @@ -36,8 +36,8 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 ebd44f6..d71b430 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 @@ -37,11 +37,11 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_reference_response import CoveredIndividualReferenceResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.covered_individual_reference_response import CoveredIndividualReferenceResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_request.py b/Avalara/SDK/models/A1099/V2/form1095_b_request.py index 0440183..273df3f 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_request.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_request.py @@ -36,8 +36,8 @@ from datetime import datetime from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_b_response.py b/Avalara/SDK/models/A1099/V2/form1095_b_response.py index 9344340..649d13d 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_b_response.py +++ b/Avalara/SDK/models/A1099/V2/form1095_b_response.py @@ -36,11 +36,11 @@ 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.A1099.V2.covered_individual_request import CoveredIndividualRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1095_c_list.py b/Avalara/SDK/models/A1099/V2/form1095_c_list.py index 9203be5..9391d56 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_c_list_item import Form1095CListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_c_list_item import Form1095CListItem from typing import Optional, Set from typing_extensions import Self 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 c86bced..b5ebff0 100644 --- a/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1095_c_list_item.py @@ -36,9 +36,9 @@ 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.A1099.V2.covered_individual_request import CoveredIndividualRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.offer_and_coverage_request import OfferAndCoverageRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.covered_individual_request import CoveredIndividualRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.offer_and_coverage_request import OfferAndCoverageRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_base_response.py b/Avalara/SDK/models/A1099/V2/form1099_base_response.py index f6537df..6177a75 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_base_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_base_response.py @@ -37,10 +37,10 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional from typing_extensions import Annotated -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_list.py b/Avalara/SDK/models/A1099/V2/form1099_div_list.py index e6bbc2f..a50fa77 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item import Form1099DivListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_list_item import Form1099DivListItem from typing import Optional, Set from typing_extensions import Self 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 3d5dbe8..39ca976 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_list_item.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 e9b012d..40d6ab9 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 @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_request.py b/Avalara/SDK/models/A1099/V2/form1099_div_request.py index a350038..ada4691 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_request.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_div_response.py b/Avalara/SDK/models/A1099/V2/form1099_div_response.py index 53bd95c..f227dd2 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_div_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_div_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list.py b/Avalara/SDK/models/A1099/V2/form1099_int_list.py index 030f258..817399f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item import Form1099IntListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int_list_item import Form1099IntListItem from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py index 1bceac9..8a8b953 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 index bb19c58..854d956 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_list_item_response.py @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_request.py b/Avalara/SDK/models/A1099/V2/form1099_int_request.py index 7acdd39..ce022c7 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_request.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_int_response.py b/Avalara/SDK/models/A1099/V2/form1099_int_response.py index a9f0348..a1811fa 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_int_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_int_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_list.py b/Avalara/SDK/models/A1099/V2/form1099_k_list.py index 0805c29..e55fae5 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item import Form1099KListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_list_item import Form1099KListItem from typing import Optional, Set from typing_extensions import Self 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 e51a1eb..90fa539 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_list_item.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 0e9fe04..10228f7 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 @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_request.py b/Avalara/SDK/models/A1099/V2/form1099_k_request.py index b5239f9..b5e68cc 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_request.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_k_response.py b/Avalara/SDK/models/A1099/V2/form1099_k_response.py index 70e9007..3e4f966 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_k_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_k_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_list.py b/Avalara/SDK/models/A1099/V2/form1099_list.py deleted file mode 100644 index ccdd613..0000000 --- a/Avalara/SDK/models/A1099/V2/form1099_list.py +++ /dev/null @@ -1,116 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 -from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.get1099_form200_response import Get1099Form200Response -from typing import Optional, Set -from typing_extensions import Self - -class Form1099List(BaseModel): - """ - Form1099List - """ # noqa: E501 - data: Optional[List[Get1099Form200Response]] = None - __properties: ClassVar[List[str]] = ["data"] - - 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 Form1099List 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 data (list) - _items = [] - if self.data: - for _item in self.data: - if _item: - _items.append(_item.to_dict()) - _dict['data'] = _items - # set to None if data (nullable) is None - # and model_fields_set contains the field - if self.data is None and "data" in self.model_fields_set: - _dict['data'] = None - - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of Form1099List from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "data": [Get1099Form200Response.from_dict(_item) for _item in obj["data"]] if obj.get("data") is not None else None - }) - return _obj - - diff --git a/Avalara/SDK/models/A1099/V2/form1099_list_data_inner.py b/Avalara/SDK/models/A1099/V2/form1099_list_data_inner.py deleted file mode 100644 index 92806b4..0000000 --- a/Avalara/SDK/models/A1099/V2/form1099_list_data_inner.py +++ /dev/null @@ -1,184 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.0 -@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.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 - -FORM1099LISTDATAINNER_ONE_OF_SCHEMAS = ["Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R"] - -class Form1099ListDataInner(BaseModel): - """ - Form1099ListDataInner - """ - # data type: Form1099K - oneof_schema_1_validator: Optional[Form1099K] = None - # data type: Form1099Misc - oneof_schema_2_validator: Optional[Form1099Misc] = None - # data type: Form1099Nec - oneof_schema_3_validator: Optional[Form1099Nec] = None - # data type: Form1099R - oneof_schema_4_validator: Optional[Form1099R] = None - actual_instance: Optional[Union[Form1099K, Form1099Misc, Form1099Nec, Form1099R]] = None - one_of_schemas: Set[str] = { "Form1099K", "Form1099Misc", "Form1099Nec", "Form1099R" } - - model_config = ConfigDict( - validate_assignment=True, - protected_namespaces=(), - ) - - - discriminator_value_class_map: Dict[str, str] = { - } - - 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 = Form1099ListDataInner.model_construct() - error_messages = [] - match = 0 - # 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 Form1099ListDataInner with oneOf schemas: Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) - elif match == 0: - # no match - raise ValueError("No match found when setting `actual_instance` in Form1099ListDataInner with oneOf schemas: 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 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 Form1099ListDataInner with oneOf schemas: Form1099K, Form1099Misc, Form1099Nec, Form1099R. Details: " + ", ".join(error_messages)) - elif match == 0: - # no match - raise ValueError("No match found when deserializing the JSON string into Form1099ListDataInner with oneOf schemas: 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], 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_list_response.py b/Avalara/SDK/models/A1099/V2/form1099_list_response.py index ca0543a..12392d4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_list_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_list_response.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_list_response_value_inner import Form1099ListResponseValueInner +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_list_response_value_inner import Form1099ListResponseValueInner from typing import Optional, Set from typing_extensions import Self 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 3812f88..e9a3125 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 @@ -33,15 +33,15 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s_list_item_response import Form1042SListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b_list_item_response import Form1095BListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_base_response import Form1099BaseResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_list_item_response import Form1099DivListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int_list_item_response import Form1099IntListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_list_item_response import Form1099KListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_list_item_response import Form1099MiscListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_list_item_response import Form1099NecListItemResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_r_list_item_response import Form1099RListItemResponse 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/form1099_misc_list.py b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py index df2256d..bf1d988 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_list_item import Form1099MiscListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_list_item import Form1099MiscListItem from typing import Optional, Set from typing_extensions import Self 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 c900ee4..8763f71 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_list_item.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 c6a4332..4796acb 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 @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py index 0aee3eb..bcd0818 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_request.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py index 523549f..470af28 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_misc_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_misc_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py index b679ebf..d129e91 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_list_item import Form1099NecListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_list_item import Form1099NecListItem from typing import Optional, Set from typing_extensions import Self 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 986138a..22a00ef 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_list_item.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 46719da..fbeaf05 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 @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py index 3c687f3..ede7d9f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_request.py @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py index 8c42ed3..f01d2a4 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_nec_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_nec_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py index 6f69b1f..d11b9d2 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py +++ b/Avalara/SDK/models/A1099/V2/form1099_proccess_result.py @@ -35,8 +35,8 @@ from pydantic import BaseModel, ConfigDict, Field from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.data import Data -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_proccess_result_processed_forms_inner import Form1099ProccessResultProcessedFormsInner +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.data import Data +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_proccess_result_processed_forms_inner import Form1099ProccessResultProcessedFormsInner from typing import Optional, Set from typing_extensions import Self 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 index fdd6eb9..cbde123 100644 --- 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 @@ -33,14 +33,14 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s import Form1042S -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b import Form1095B -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div import Form1099Div -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int import Form1099Int -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k import Form1099K -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc import Form1099Misc -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec import Form1099Nec -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r import Form1099R +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s import Form1042S +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b import Form1095B +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div import Form1099Div +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int import Form1099Int +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k import Form1099K +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc import Form1099Misc +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec import Form1099Nec +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.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 diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_list.py b/Avalara/SDK/models/A1099/V2/form1099_r_list.py index e2bd7d4..40aaadd 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_list_item import Form1099RListItem +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_r_list_item import Form1099RListItem from typing import Optional, Set from typing_extensions import Self 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 a661f16..e40460f 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_list_item.py @@ -36,7 +36,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 14d0161..a5b72bf 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 @@ -37,10 +37,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_request.py b/Avalara/SDK/models/A1099/V2/form1099_r_request.py index 0ee5fdd..9760106 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_request.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_request.py @@ -36,7 +36,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form1099_r_response.py b/Avalara/SDK/models/A1099/V2/form1099_r_response.py index 474b0ce..86e4330 100644 --- a/Avalara/SDK/models/A1099/V2/form1099_r_response.py +++ b/Avalara/SDK/models/A1099/V2/form1099_r_response.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form_request_base.py b/Avalara/SDK/models/A1099/V2/form_request_base.py index a60c024..d922061 100644 --- a/Avalara/SDK/models/A1099/V2/form_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_request_base.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form_request_csv_base.py b/Avalara/SDK/models/A1099/V2/form_request_csv_base.py deleted file mode 100644 index 9777983..0000000 --- a/Avalara/SDK/models/A1099/V2/form_request_csv_base.py +++ /dev/null @@ -1,202 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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, StrictInt, StrictStr, field_validator -from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest -from typing import Optional, Set -from typing_extensions import Self - -class FormRequestCsvBase(BaseModel): - """ - FormRequestCsvBase - """ # noqa: E501 - 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") - issuer_id: Optional[StrictStr] = Field(default=None, alias="issuerId") - 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") - tin_type: Optional[StrictStr] = Field(default=None, alias="tinType") - 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 - recipient_email: Optional[StrictStr] = Field(default=None, alias="recipientEmail") - account_number: Optional[StrictStr] = Field(default=None, alias="accountNumber") - office_code: Optional[StrictStr] = Field(default=None, alias="officeCode") - recipient_non_us_province: Optional[StrictStr] = Field(default=None, alias="recipientNonUsProvince") - 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") - address_verification: Optional[StrictBool] = Field(default=None, alias="addressVerification") - state_and_local_withholding: Optional[StateAndLocalWithholdingRequest] = Field(default=None, alias="stateAndLocalWithholding") - __properties: ClassVar[List[str]] = ["issuerId", "referenceId", "recipientName", "recipientTin", "tinType", "recipientSecondName", "address", "address2", "city", "state", "zip", "recipientEmail", "accountNumber", "officeCode", "recipientNonUsProvince", "countryCode", "federalEFile", "postalMail", "stateEFile", "tinMatch", "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 FormRequestCsvBase 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_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 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 recipient_email (nullable) is None - # and model_fields_set contains the field - if self.recipient_email is None and "recipient_email" in self.model_fields_set: - _dict['recipientEmail'] = 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 recipient_non_us_province (nullable) is None - # and model_fields_set contains the field - if self.recipient_non_us_province is None and "recipient_non_us_province" in self.model_fields_set: - _dict['recipientNonUsProvince'] = None - - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of FormRequestCsvBase from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "issuerId": obj.get("issuerId"), - "referenceId": obj.get("referenceId"), - "recipientName": obj.get("recipientName"), - "recipientTin": obj.get("recipientTin"), - "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"), - "recipientEmail": obj.get("recipientEmail"), - "accountNumber": obj.get("accountNumber"), - "officeCode": obj.get("officeCode"), - "recipientNonUsProvince": obj.get("recipientNonUsProvince"), - "countryCode": obj.get("countryCode"), - "federalEFile": obj.get("federalEFile"), - "postalMail": obj.get("postalMail"), - "stateEFile": obj.get("stateEFile"), - "tinMatch": obj.get("tinMatch"), - "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/form_request_list_item_base.py b/Avalara/SDK/models/A1099/V2/form_request_list_item_base.py index 8f8c315..9e774aa 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 @@ -35,7 +35,7 @@ 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.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self diff --git a/Avalara/SDK/models/A1099/V2/form_request_model.py b/Avalara/SDK/models/A1099/V2/form_request_model.py deleted file mode 100644 index 40cd944..0000000 --- a/Avalara/SDK/models/A1099/V2/form_request_model.py +++ /dev/null @@ -1,143 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.0 -@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, StrictInt, StrictStr, field_validator -from typing import Any, ClassVar, Dict, List, Optional -from typing import Optional, Set -from typing_extensions import Self - -class FormRequestModel(BaseModel): - """ - FormRequestModel - """ # noqa: E501 - id: Optional[StrictStr] = None - type: Optional[StrictStr] = None - form_type: Optional[StrictStr] = Field(default=None, description="\"W9\" is currently the only supported value", alias="formType") - company_id: Optional[StrictInt] = Field(default=None, description="Track1099's ID of your company, found in the W-9 UI", alias="companyId") - company_name: Optional[StrictStr] = Field(default=None, description="Name of your company, set in the W-9 UI", alias="companyName") - company_email: Optional[StrictStr] = Field(default=None, description="Contact email of your company, set in the W-9 UI", alias="companyEmail") - reference_id: Optional[StrictStr] = Field(default=None, description="Your internal identifier for the vendor from whom you are requesting a form", alias="referenceId") - signed_at: Optional[datetime] = Field(default=None, description="The timestamp this vendor (identified by your ReferenceId) last signed a complete W-9, null if you did not include a ReferenceId or the vendor has not yet signed a W-9 in Track1099", alias="signedAt") - tin_match_status: Optional[StrictStr] = Field(default=None, description="Result of IRS TIN match query for name and TIN in the last signed form, null if signed_at is null", alias="tinMatchStatus") - expires_at: Optional[datetime] = Field(default=None, description="Timestamp when this FormRequest will expire, ttl (or 3600) seconds from creation", alias="expiresAt") - signed_pdf: Optional[StrictStr] = Field(default=None, description="URL of PDF representation of just-signed form, otherwise null. Integrations may use this value to offer a \"download for your records\" function after a vendor completes and signs a form. Link expires at the same time as this FormRequest. Treat the format of this URL as opaque and expect it to change in the future.", alias="signedPdf") - __properties: ClassVar[List[str]] = [] - - @field_validator('type') - def type_validate_enum(cls, value): - """Validates the enum""" - if value is None: - return value - - if value not in set(['FormRequest']): - raise ValueError("must be one of enum values ('FormRequest')") - return value - - @field_validator('form_type') - def form_type_validate_enum(cls, value): - """Validates the enum""" - if value is None: - return value - - if value not in set(['W9']): - raise ValueError("must be one of enum values ('W9')") - return value - - @field_validator('tin_match_status') - def tin_match_status_validate_enum(cls, value): - """Validates the enum""" - if value is None: - return value - - if value not in set(['None', 'Matched']): - raise ValueError("must be one of enum values ('None', 'Matched')") - 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 FormRequestModel 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 FormRequestModel 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 - - diff --git a/Avalara/SDK/models/A1099/V2/form_response_base.py b/Avalara/SDK/models/A1099/V2/form_response_base.py index a0bbc01..e3527af 100644 --- a/Avalara/SDK/models/A1099/V2/form_response_base.py +++ b/Avalara/SDK/models/A1099/V2/form_response_base.py @@ -36,10 +36,10 @@ 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.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.status_detail import StatusDetail -from Avalara.SDK.models.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_response import StateAndLocalWithholdingResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_efile_status_detail_response import StateEfileStatusDetailResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.status_detail import StatusDetail +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.validation_error_response import ValidationErrorResponse from typing import Optional, Set from typing_extensions import Self 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 90ee70d..421b8d7 100644 --- a/Avalara/SDK/models/A1099/V2/form_single_request_base.py +++ b/Avalara/SDK/models/A1099/V2/form_single_request_base.py @@ -35,7 +35,7 @@ from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.state_and_local_withholding_request import StateAndLocalWithholdingRequest from typing import Optional, Set from typing_extensions import Self 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 15c6625..2f9176e 100644 --- a/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_create_form1099_request.py @@ -33,10 +33,10 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest 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/i_update_form1099_request.py b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py index 1bd3afc..a1868b3 100644 --- a/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py +++ b/Avalara/SDK/models/A1099/V2/i_update_form1099_request.py @@ -33,10 +33,10 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_request import Form1099DivRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_request import Form1099KRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_request import Form1099MiscRequest +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_request import Form1099NecRequest 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/paginated_w9_forms_model.py b/Avalara/SDK/models/A1099/V2/paginated_w9_forms_model.py index a4e9db9..ce5c7c1 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.A1099.V2.A1099.V2.iw9_form_data_models_one_of import IW9FormDataModelsOneOf +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.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/state_efile_status_detail_app.py b/Avalara/SDK/models/A1099/V2/state_efile_status_detail_app.py deleted file mode 100644 index e572b32..0000000 --- a/Avalara/SDK/models/A1099/V2/state_efile_status_detail_app.py +++ /dev/null @@ -1,122 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 StateEfileStatusDetailApp(BaseModel): - """ - StateEfileStatusDetailApp - """ # noqa: E501 - status: Optional[StrictStr] = None - time: Optional[StrictStr] = None - jurisdiction: Optional[StrictStr] = None - __properties: ClassVar[List[str]] = ["status", "time", "jurisdiction"] - - 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 StateEfileStatusDetailApp 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 status (nullable) is None - # and model_fields_set contains the field - if self.status is None and "status" in self.model_fields_set: - _dict['status'] = None - - # set to None if time (nullable) is None - # and model_fields_set contains the field - if self.time is None and "time" in self.model_fields_set: - _dict['time'] = None - - # set to None if jurisdiction (nullable) is None - # and model_fields_set contains the field - if self.jurisdiction is None and "jurisdiction" in self.model_fields_set: - _dict['jurisdiction'] = None - - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of StateEfileStatusDetailApp from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "status": obj.get("status"), - "time": obj.get("time"), - "jurisdiction": obj.get("jurisdiction") - }) - return _obj - - diff --git a/Avalara/SDK/models/A1099/V2/update1099_form200_response.py b/Avalara/SDK/models/A1099/V2/update1099_form200_response.py index 34ce896..422c094 100644 --- a/Avalara/SDK/models/A1099/V2/update1099_form200_response.py +++ b/Avalara/SDK/models/A1099/V2/update1099_form200_response.py @@ -33,15 +33,15 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from Avalara.SDK.models.A1099.V2.A1099.V2.form1042_s_response import Form1042SResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1095_b_response import Form1095BResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_div_response import Form1099DivResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_int_response import Form1099IntResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_k_response import Form1099KResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_misc_response import Form1099MiscResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_nec_response import Form1099NecResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form1099_r_response import Form1099RResponse -from Avalara.SDK.models.A1099.V2.A1099.V2.form_response_base import FormResponseBase +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1042_s_response import Form1042SResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1095_b_response import Form1095BResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_div_response import Form1099DivResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_int_response import Form1099IntResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_k_response import Form1099KResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_misc_response import Form1099MiscResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_nec_response import Form1099NecResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.A1099.V2.form1099_r_response import Form1099RResponse +from Avalara.SDK.models.A1099.V2.A1099.V2.A1099.V2.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 diff --git a/Avalara/SDK/models/A1099/V2/validation_error_app.py b/Avalara/SDK/models/A1099/V2/validation_error_app.py deleted file mode 100644 index 8a881ef..0000000 --- a/Avalara/SDK/models/A1099/V2/validation_error_app.py +++ /dev/null @@ -1,115 +0,0 @@ -# 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 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) - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 typing import Optional, Set -from typing_extensions import Self - -class ValidationErrorApp(BaseModel): - """ - ValidationErrorApp - """ # noqa: E501 - var_field: Optional[StrictStr] = Field(default=None, alias="field") - errors: Optional[List[StrictStr]] = None - __properties: ClassVar[List[str]] = ["field", "errors"] - - 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 ValidationErrorApp 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 var_field (nullable) is None - # and model_fields_set contains the field - if self.var_field is None and "var_field" in self.model_fields_set: - _dict['field'] = None - - # set to None if errors (nullable) is None - # and model_fields_set contains the field - if self.errors is None and "errors" in self.model_fields_set: - _dict['errors'] = None - - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of ValidationErrorApp from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "field": obj.get("field"), - "errors": obj.get("errors") - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/directory_search_response.py b/Avalara/SDK/models/EInvoicing/V1/directory_search_response.py deleted file mode 100644 index d739771..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/directory_search_response.py +++ /dev/null @@ -1,115 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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.EInvoicing.V1.directory_search_response_value_inner import DirectorySearchResponseValueInner -from typing import Optional, Set -from typing_extensions import Self - -class DirectorySearchResponse(BaseModel): - """ - Response schema for directory search results - """ # noqa: E501 - record_set_count: Optional[StrictInt] = Field(default=None, description="The count of records in the result set", alias="@recordSetCount") - next_link: Optional[StrictStr] = Field(default=None, description="The next page link to get the next set of results.", alias="@nextLink") - value: Optional[List[DirectorySearchResponseValueInner]] = None - __properties: ClassVar[List[str]] = ["@recordSetCount", "@nextLink", "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 DirectorySearchResponse 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 - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of DirectorySearchResponse 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"), - "@nextLink": obj.get("@nextLink"), - "value": [DirectorySearchResponseValueInner.from_dict(_item) for _item in obj["value"]] if obj.get("value") is not None else None - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner.py b/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner.py deleted file mode 100644 index f5f04c9..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner.py +++ /dev/null @@ -1,140 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 date -from pydantic import BaseModel, ConfigDict, Field, StrictStr -from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.EInvoicing.V1.directory_search_response_value_inner_addresses_inner import DirectorySearchResponseValueInnerAddressesInner -from Avalara.SDK.models.EInvoicing.V1.directory_search_response_value_inner_identifiers_inner import DirectorySearchResponseValueInnerIdentifiersInner -from Avalara.SDK.models.EInvoicing.V1.directory_search_response_value_inner_supported_document_types_inner import DirectorySearchResponseValueInnerSupportedDocumentTypesInner -from typing import Optional, Set -from typing_extensions import Self - -class DirectorySearchResponseValueInner(BaseModel): - """ - DirectorySearchResponseValueInner - """ # noqa: E501 - id: Optional[StrictStr] = Field(default=None, description="Avalara unique ID of the participant in the directory.") - name: Optional[StrictStr] = Field(default=None, description="Name of the participant (typically, the name of the business entity).") - network: Optional[StrictStr] = Field(default=None, description="The network where the participant is present.") - registration_date: Optional[date] = Field(default=None, description="Registration date of the participant if available", alias="registrationDate") - identifiers: Optional[List[DirectorySearchResponseValueInnerIdentifiersInner]] = None - addresses: Optional[List[DirectorySearchResponseValueInnerAddressesInner]] = None - supported_document_types: Optional[List[DirectorySearchResponseValueInnerSupportedDocumentTypesInner]] = Field(default=None, alias="supportedDocumentTypes") - __properties: ClassVar[List[str]] = ["id", "name", "network", "registrationDate", "identifiers", "addresses", "supportedDocumentTypes"] - - 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 DirectorySearchResponseValueInner 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 identifiers (list) - _items = [] - if self.identifiers: - for _item in self.identifiers: - if _item: - _items.append(_item.to_dict()) - _dict['identifiers'] = _items - # override the default output from pydantic by calling `to_dict()` of each item in addresses (list) - _items = [] - if self.addresses: - for _item in self.addresses: - if _item: - _items.append(_item.to_dict()) - _dict['addresses'] = _items - # override the default output from pydantic by calling `to_dict()` of each item in supported_document_types (list) - _items = [] - if self.supported_document_types: - for _item in self.supported_document_types: - if _item: - _items.append(_item.to_dict()) - _dict['supportedDocumentTypes'] = _items - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of DirectorySearchResponseValueInner 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"), - "name": obj.get("name"), - "network": obj.get("network"), - "registrationDate": obj.get("registrationDate"), - "identifiers": [DirectorySearchResponseValueInnerIdentifiersInner.from_dict(_item) for _item in obj["identifiers"]] if obj.get("identifiers") is not None else None, - "addresses": [DirectorySearchResponseValueInnerAddressesInner.from_dict(_item) for _item in obj["addresses"]] if obj.get("addresses") is not None else None, - "supportedDocumentTypes": [DirectorySearchResponseValueInnerSupportedDocumentTypesInner.from_dict(_item) for _item in obj["supportedDocumentTypes"]] if obj.get("supportedDocumentTypes") is not None else None - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_addresses_inner.py b/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_addresses_inner.py deleted file mode 100644 index 261345b..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_addresses_inner.py +++ /dev/null @@ -1,111 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 typing import Optional, Set -from typing_extensions import Self - -class DirectorySearchResponseValueInnerAddressesInner(BaseModel): - """ - DirectorySearchResponseValueInnerAddressesInner - """ # noqa: E501 - line1: Optional[StrictStr] = Field(default=None, description="Address line 1") - line2: Optional[StrictStr] = Field(default=None, description="Address line 2") - city: Optional[StrictStr] = Field(default=None, description="City") - state: Optional[StrictStr] = Field(default=None, description="State") - country: Optional[StrictStr] = Field(default=None, description="Country") - __properties: ClassVar[List[str]] = ["line1", "line2", "city", "state", "country"] - - 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 DirectorySearchResponseValueInnerAddressesInner 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 DirectorySearchResponseValueInnerAddressesInner from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "line1": obj.get("line1"), - "line2": obj.get("line2"), - "city": obj.get("city"), - "state": obj.get("state"), - "country": obj.get("country") - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_identifiers_inner.py b/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_identifiers_inner.py deleted file mode 100644 index 7a2bc11..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_identifiers_inner.py +++ /dev/null @@ -1,105 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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 typing import Optional, Set -from typing_extensions import Self - -class DirectorySearchResponseValueInnerIdentifiersInner(BaseModel): - """ - DirectorySearchResponseValueInnerIdentifiersInner - """ # noqa: E501 - name: Optional[StrictStr] = Field(default=None, description="Peppol Participant ID if the participant is in Peppol network") - value: Optional[StrictStr] = Field(default=None, description="Value of the identifier") - __properties: ClassVar[List[str]] = ["name", "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 DirectorySearchResponseValueInnerIdentifiersInner 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 DirectorySearchResponseValueInnerIdentifiersInner from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "name": obj.get("name"), - "value": obj.get("value") - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_supported_document_types_inner.py b/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_supported_document_types_inner.py deleted file mode 100644 index 59d02fd..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/directory_search_response_value_inner_supported_document_types_inner.py +++ /dev/null @@ -1,109 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 25.7.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, StrictStr -from typing import Any, ClassVar, Dict, List, Optional -from typing import Optional, Set -from typing_extensions import Self - -class DirectorySearchResponseValueInnerSupportedDocumentTypesInner(BaseModel): - """ - DirectorySearchResponseValueInnerSupportedDocumentTypesInner - """ # noqa: E501 - name: Optional[StrictStr] = Field(default=None, description="Document type name.") - value: Optional[StrictStr] = Field(default=None, description="Document type identifier.") - supported_by_trading_partner: Optional[StrictBool] = Field(default=None, description="Does trading partner support receiving this document type", alias="supportedByTradingPartner") - supported_by_avalara: Optional[StrictBool] = Field(default=None, description="Does avalara support exchanging this document type", alias="supportedByAvalara") - __properties: ClassVar[List[str]] = ["name", "value", "supportedByTradingPartner", "supportedByAvalara"] - - 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 DirectorySearchResponseValueInnerSupportedDocumentTypesInner 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 DirectorySearchResponseValueInnerSupportedDocumentTypesInner from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "name": obj.get("name"), - "value": obj.get("value"), - "supportedByTradingPartner": obj.get("supportedByTradingPartner"), - "supportedByAvalara": obj.get("supportedByAvalara") - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request.py b/Avalara/SDK/models/EInvoicing/V1/document_fetch_request.py deleted file mode 100644 index 6f5af21..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request.py +++ /dev/null @@ -1,117 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 24.12.1 -@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 -from typing import Any, ClassVar, Dict, List, Optional -from Avalara.SDK.models.EInvoicing.V1.document_fetch_request_data_inner import DocumentFetchRequestDataInner -from Avalara.SDK.models.EInvoicing.V1.document_fetch_request_metadata import DocumentFetchRequestMetadata -from typing import Optional, Set -from typing_extensions import Self - -class DocumentFetchRequest(BaseModel): - """ - DocumentFetchRequest - """ # noqa: E501 - data: Optional[List[DocumentFetchRequestDataInner]] = Field(default=None, description="Array of key-value pairs used to retrieve inbound documents from the Tax Authority") - metadata: Optional[DocumentFetchRequestMetadata] = None - __properties: ClassVar[List[str]] = ["data", "metadata"] - - 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 DocumentFetchRequest 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 data (list) - _items = [] - if self.data: - for _item in self.data: - if _item: - _items.append(_item.to_dict()) - _dict['data'] = _items - # override the default output from pydantic by calling `to_dict()` of metadata - if self.metadata: - _dict['metadata'] = self.metadata.to_dict() - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of DocumentFetchRequest from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "data": [DocumentFetchRequestDataInner.from_dict(_item) for _item in obj["data"]] if obj.get("data") is not None else None, - "metadata": DocumentFetchRequestMetadata.from_dict(obj["metadata"]) if obj.get("metadata") is not None else None - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_data_inner.py b/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_data_inner.py deleted file mode 100644 index dd14f80..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_data_inner.py +++ /dev/null @@ -1,105 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 24.12.1 -@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 -from typing import Optional, Set -from typing_extensions import Self - -class DocumentFetchRequestDataInner(BaseModel): - """ - DocumentFetchRequestDataInner - """ # noqa: E501 - key: StrictStr = Field(description="Descriptor of the identifier") - value: StrictStr = Field(description="Value of the identifier") - __properties: ClassVar[List[str]] = ["key", "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 DocumentFetchRequestDataInner 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 DocumentFetchRequestDataInner from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "key": obj.get("key"), - "value": obj.get("value") - }) - return _obj - - diff --git a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_metadata.py b/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_metadata.py deleted file mode 100644 index 5911c9c..0000000 --- a/Avalara/SDK/models/EInvoicing/V1/document_fetch_request_metadata.py +++ /dev/null @@ -1,111 +0,0 @@ -# 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 E-Invoicing API - An API that supports sending data for an E-Invoicing compliance use-case. - -@author Sachin Baijal -@author Jonathan Wenger -@copyright 2022 Avalara, Inc. -@license https://www.apache.org/licenses/LICENSE-2.0 -@version 24.12.1 -@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, StrictFloat, StrictInt, StrictStr -from typing import Any, ClassVar, Dict, List, Union -from typing import Optional, Set -from typing_extensions import Self - -class DocumentFetchRequestMetadata(BaseModel): - """ - DocumentFetchRequestMetadata - """ # noqa: E501 - workflow_id: StrictStr = Field(description="Specifies a unique ID for this workflow.", alias="workflowId") - data_format: StrictStr = Field(description="Specifies the data format for this workflow", alias="dataFormat") - data_format_version: Union[StrictFloat, StrictInt] = Field(description="Specifies the data format version number", alias="dataFormatVersion") - country_code: StrictStr = Field(description="The two-letter ISO-3166 country code for the country for which document is being retrieved", alias="countryCode") - country_mandate: StrictStr = Field(description="The e-invoicing mandate for the specified country", alias="countryMandate") - __properties: ClassVar[List[str]] = ["workflowId", "dataFormat", "dataFormatVersion", "countryCode", "countryMandate"] - - 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 DocumentFetchRequestMetadata 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 DocumentFetchRequestMetadata from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({ - "workflowId": obj.get("workflowId"), - "dataFormat": obj.get("dataFormat"), - "dataFormatVersion": obj.get("dataFormatVersion"), - "countryCode": obj.get("countryCode"), - "countryMandate": obj.get("countryMandate") - }) - return _obj - - diff --git a/docs/A1099/V2/CompaniesW9Api.md b/docs/A1099/V2/CompaniesW9Api.md index 1bc03d6..037c120 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 = '8e57d48c-bb4e-4088-9beb-bf2323243c9f' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '84a816ef-95df-4fb7-8d8a-95bc8a8d8fe9' # 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_company_request = {"name":"Acme Corporation","dbaName":"","email":"contact@acmecorp.com","address":"123 Business Ave","city":"Phoenix","state":"AZ","zip":"85001","telephone":"602-555-0123","tin":"12-3456789","referenceId":"","doTinMatch":null,"groupName":"","foreignProvince":"","countryCode":"US","resendRequests":null,"resendIntervalDays":null,"maxReminderAttempts":null} # CreateCompanyRequest | 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 = '3e231f13-24a7-49dc-a92e-1e04f5d7ca28' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '22a14d95-22c8-4e2d-a6f9-a60235ff2fb6' # 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 = '0b03049b-b1d4-4b5c-83df-dba2d815fce0' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b20f7fbd-d0ac-4f59-a75d-ca2afa4b1e91' # 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 = 'b5657869-263a-424d-81ed-4f845a37bf20' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '06bf1c2a-d8be-473a-9d6d-a5100b9d7402' # 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 = 'e0cf793c-bc52-406b-9bdf-15b8e91e2ce8' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b3aa843f-04a8-48cf-9a55-08fd136a6e0c' # 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_company_request = {"name":"Acme Corporation","dbaName":"","email":"contact@acmecorp.com","address":"123 Business Ave","city":"Phoenix","state":"AZ","zip":"85001","telephone":"602-555-0123","tin":"12-3456789","referenceId":"","doTinMatch":null,"groupName":"","foreignProvince":"","countryCode":"US","resendRequests":null,"resendIntervalDays":null,"maxReminderAttempts":null} # CreateCompanyRequest | The updated company data (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/Forms1099Api.md b/docs/A1099/V2/Forms1099Api.md index 576144b..c3c25cd 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 | defaults to false. If true, it will NOT change the DB. It will just return a report of what would've have been changed in the DB (optional) if omitted the server will use the default value of False - x_correlation_id = '51b17473-1a08-453e-ae8c-41924f260edb' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '8dc909fe-720e-43fb-b983-58faed44f2fa' # 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) form1099_list_request = {"type":"1099-NEC","forms":[{"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}}]} # Form1099ListRequest | (optional) # example passing only required values which don't have defaults set @@ -138,7 +138,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 = '8658b701-7c0e-4a84-91fa-101c7b6865d8' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'ad4f746f-04e3-4a59-8f2a-71982cba7d13' # 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) get1099_form200_response = {"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}} # Get1099Form200Response | (optional) # example passing only required values which don't have defaults set @@ -226,7 +226,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 = '828993a0-67f5-46c9-b0be-a45fc4436fea' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '275dadca-90a3-446a-b0fa-bc0dbaa2b6ef' # 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: @@ -314,7 +314,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 = '60127475-bae6-4285-a7eb-1ad8aec75ae6' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '90f6f993-5bc8-491a-a091-0a9796c654b6' # 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: 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 = 'e7c4583b-0102-46c1-a579-35438519cc67' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'c159dc0f-6a68-4e21-921f-125572625a71' # 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: @@ -498,7 +498,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 = '6740cecb-55e5-44ff-86e7-f47e741249e8' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '75d30018-83d1-41b9-b7b4-6de919434c8b' # 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: @@ -592,7 +592,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 = '2e10a990-964c-4a25-99c8-fb3e5a1f9315' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '31ca64fc-d116-4f15-b49f-4877baa12e4a' # 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) get1099_form200_response = {"type":"1099-NEC","issuerId":"12345","issuerReferenceId":"ISSUER-REF-2024","taxYear":2024,"referenceId":"NEC-REF-001","tin":"123456789","recipientName":"John Doe","tinType":"SSN","recipientSecondName":"Doe Enterprises","address":"123 Main Street","address2":"Suite 100","city":"New York","state":"NY","zip":"10001","email":"john.doe@example.com","accountNumber":"ACC123456","officeCode":"NYC01","countryCode":"US","nonemployeeCompensation":15000.0,"directSalesIndicator":true,"federalIncomeTaxWithheld":3000.0,"secondTinNotice":false,"federalEfileDate":"2024-03-15","stateEfileDate":"2024-03-20","recipientEdeliveryDate":"2024-03-25","postalMail":false,"tinMatch":true,"addressVerification":true,"stateAndLocalWithholding":{"stateTaxWithheld":500.0,"state":"NY","stateIdNumber":"NY123456","stateIncome":15000.0,"localTaxWithheld":250.0,"locality":"New York City","localityIdNumber":"NYC789","localIncome":15000.0}} # Get1099Form200Response | (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 7856e90..229edf0 100644 --- a/docs/A1099/V2/FormsW9Api.md +++ b/docs/A1099/V2/FormsW9Api.md @@ -48,7 +48,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 = 'daaba72b-ef09-4c15-9a83-344ad63c1533' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '980ae482-1742-4c81-a302-1593d823d304' # 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_and_send_w9_form_email_request = {"type":"W9","email":"john.doe@example.com","name":"John Doe","accountNumber":"ACC01","companyId":"32553266","referenceId":"REF-12345"} # CreateAndSendW9FormEmailRequest | Form to be created (optional) # example passing only required values which don't have defaults set @@ -136,7 +136,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 = '9ec7cabd-da9b-4ec2-b94f-9d344e3c9e50' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b5120bcc-613a-4c1c-828d-6478c1df4d6d' # 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,"eDeliveryConsentedAt":null,"signature":null,"companyId":"32553266","referenceId":null,"email":null} # CreateW9FormRequest | Form to be created (optional) # example passing only required values which don't have defaults set @@ -223,7 +223,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 = 'a78693a0-ae1c-4c54-9220-72380bead3a7' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '70ca9f7a-4f25-471d-8618-41c0838ccb66' # 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: @@ -308,7 +308,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 = '13cc90eb-cbcd-4425-baf5-8ae7cbe57113' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '053c9414-f1a1-42a6-8bb8-e90544cb8473' # 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: @@ -400,7 +400,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 = 'c3ac4fe7-8e06-49b7-8bdd-36c22d18d734' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '5552b14e-19e1-48b3-a921-484638d7982b' # 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: @@ -492,7 +492,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 = 'be1b2054-2262-4833-92e6-875a3533d944' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'fbb41ab0-ac34-47fc-815d-946a0d2c48cb' # 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: @@ -580,7 +580,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 = 'b301d45c-08df-404f-954c-e7edeb163532' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '737bda48-54bc-418f-82d0-aa9ea5dbb6a2' # 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 @@ -669,7 +669,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 = 'a945240a-b94f-476a-a436-863e27320f9d' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b246e2b5-17b2-4229-9f03-86095b6b4b54' # 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/Issuers1099Api.md b/docs/A1099/V2/Issuers1099Api.md index b25c5d1..cdf549a 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 = '44b5fa45-dc8f-4939-9259-55c44e371c83' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'c9fe2806-b469-4728-93f3-f60f31c6e515' # 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_issuer_request = {"name":"Acme Corporation","dbaName":"Acme Widgets","tin":"94-2765431","referenceId":"issuer-001","telephone":"+1-555-123-4567","taxYear":2024,"countryCode":"US","email":"support@acmecorp.com","address":"123 Main Street","city":"San Francisco","state":"CA","zip":"94105","foreignProvince":"","transferAgentName":"","lastFiling":false} # CreateIssuerRequest | 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 = '18937e11-5cfa-4f80-b4ff-a8fdee349cf1' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '081895ce-c445-430c-9769-dfade0e811da' # 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 = '8e5147e0-a97c-47f5-9791-3ea7d3bf7f16' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = '918a7b34-19fa-42ae-be7e-42f1f8717e7f' # 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 = 'da351fbb-2f00-42a7-8c6f-e3864f4bbf0c' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'da800a09-436c-4bca-8e7a-557741840192' # 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 = '07298ef1-41b1-4610-9275-331b7ae88439' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'cb4b1dbc-2041-4d63-878e-b528a67f2ffc' # 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_issuer_request = {"name":"Acme Corporation","dbaName":"Acme Widgets","tin":"94-2765431","referenceId":"issuer-001","telephone":"+1-555-123-4567","taxYear":2024,"countryCode":"US","email":"support@acmecorp.com","address":"123 Main Street","city":"San Francisco","state":"CA","zip":"94105","foreignProvince":"","transferAgentName":"","lastFiling":false} # CreateIssuerRequest | The issuer to update (optional) # example passing only required values which don't have defaults set diff --git a/docs/A1099/V2/JobsApi.md b/docs/A1099/V2/JobsApi.md index f500ab4..6aab65c 100644 --- a/docs/A1099/V2/JobsApi.md +++ b/docs/A1099/V2/JobsApi.md @@ -41,7 +41,7 @@ with Avalara.SDK.ApiClient(configuration) as api_client: api_instance = jobs_api.JobsApi(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 = '19c729e6-45f1-4b1f-8a4c-a1293f8da8bd' # str | Unique correlation Id in a GUID format (optional) + x_correlation_id = 'b17e0df6-816d-45a2-8b6d-a2d79a90a02c' # 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: