From c72ab8650ce64754d22aa224681303035dc674b0 Mon Sep 17 00:00:00 2001 From: "svc.developer" Date: Thu, 16 Apr 2026 11:35:23 -0700 Subject: [PATCH 1/2] 26.4.0 --- README.md | 117 +-- docs/EInvoicing/V1/CodeListListResponse.md | 16 + docs/EInvoicing/V1/CodeListResponse.md | 19 + docs/EInvoicing/V1/CodeListSummary.md | 19 + docs/EInvoicing/V1/CodeListValue.md | 16 + docs/EInvoicing/V1/CodeListVersion.md | 18 + docs/EInvoicing/V1/CodeListsApi.md | 199 +++++ docs/EInvoicing/V1/DataInputFieldsApi.md | 30 +- docs/EInvoicing/V1/DocumentStatusResponse.md | 3 +- docs/EInvoicing/V1/DocumentSummary.md | 4 + docs/EInvoicing/V1/DocumentsApi.md | 128 +-- docs/EInvoicing/V1/Identifier.md | 1 + docs/EInvoicing/V1/InteropApi.md | 24 +- docs/EInvoicing/V1/Mandate.md | 1 + docs/EInvoicing/V1/MandatesApi.md | 40 +- docs/EInvoicing/V1/ReportDownloadResponse.md | 15 + docs/EInvoicing/V1/ReportItem.md | 32 + docs/EInvoicing/V1/ReportListResponse.md | 16 + docs/EInvoicing/V1/ReportsApi.md | 283 +++++++ docs/EInvoicing/V1/StatusEvent.md | 3 +- docs/EInvoicing/V1/SubscriptionsApi.md | 66 +- .../V1/SupportedDocumentStatuses.md | 15 + ...TaxIdentifierSchemaByCountry200Response.md | 1 + docs/EInvoicing/V1/TaxIdentifiersApi.md | 60 +- docs/EInvoicing/V1/TradingPartnersApi.md | 248 +++--- pom.xml | 4 +- src/main/java/Avalara/SDK/JSON.java | 4 +- .../SDK/api/EInvoicing/V1/CodeListsApi.java | 543 +++++++++++++ .../api/EInvoicing/V1/DataInputFieldsApi.java | 52 +- .../SDK/api/EInvoicing/V1/DocumentsApi.java | 234 +++--- .../SDK/api/EInvoicing/V1/InteropApi.java | 56 +- .../SDK/api/EInvoicing/V1/MandatesApi.java | 82 +- .../SDK/api/EInvoicing/V1/ReportsApi.java | 711 +++++++++++++++++ .../api/EInvoicing/V1/SubscriptionsApi.java | 176 ++--- .../api/EInvoicing/V1/TaxIdentifiersApi.java | 122 +-- .../api/EInvoicing/V1/TradingPartnersApi.java | 492 ++++++------ .../EInvoicing/V1/CodeListListResponse.java | 308 ++++++++ .../model/EInvoicing/V1/CodeListResponse.java | 379 +++++++++ .../model/EInvoicing/V1/CodeListSummary.java | 379 +++++++++ .../model/EInvoicing/V1/CodeListValue.java | 270 +++++++ .../model/EInvoicing/V1/CodeListVersion.java | 354 +++++++++ .../EInvoicing/V1/DocumentStatusResponse.java | 33 +- .../model/EInvoicing/V1/DocumentSummary.java | 154 +++- .../SDK/model/EInvoicing/V1/Identifier.java | 55 +- .../SDK/model/EInvoicing/V1/Mandate.java | 53 +- .../EInvoicing/V1/ReportDownloadResponse.java | 242 ++++++ .../SDK/model/EInvoicing/V1/ReportItem.java | 742 ++++++++++++++++++ .../EInvoicing/V1/ReportListResponse.java | 308 ++++++++ .../SDK/model/EInvoicing/V1/StatusEvent.java | 35 +- .../V1/SupportedDocumentStatuses.java | 241 ++++++ ...xIdentifierSchemaByCountry200Response.java | 32 +- 51 files changed, 6417 insertions(+), 1018 deletions(-) create mode 100644 docs/EInvoicing/V1/CodeListListResponse.md create mode 100644 docs/EInvoicing/V1/CodeListResponse.md create mode 100644 docs/EInvoicing/V1/CodeListSummary.md create mode 100644 docs/EInvoicing/V1/CodeListValue.md create mode 100644 docs/EInvoicing/V1/CodeListVersion.md create mode 100644 docs/EInvoicing/V1/CodeListsApi.md create mode 100644 docs/EInvoicing/V1/ReportDownloadResponse.md create mode 100644 docs/EInvoicing/V1/ReportItem.md create mode 100644 docs/EInvoicing/V1/ReportListResponse.md create mode 100644 docs/EInvoicing/V1/ReportsApi.md create mode 100644 docs/EInvoicing/V1/SupportedDocumentStatuses.md create mode 100644 src/main/java/Avalara/SDK/api/EInvoicing/V1/CodeListsApi.java create mode 100644 src/main/java/Avalara/SDK/api/EInvoicing/V1/ReportsApi.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListListResponse.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListResponse.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListSummary.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListValue.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListVersion.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportDownloadResponse.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportItem.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportListResponse.java create mode 100644 src/main/java/Avalara/SDK/model/EInvoicing/V1/SupportedDocumentStatuses.java diff --git a/README.md b/README.md index 73e8dd4..7672401 100644 --- a/README.md +++ b/README.md @@ -109,6 +109,8 @@ It's recommended to create an instance of `ApiClient` per thread in a multithrea Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- +*CodeListsApi* | [**getCodeList**](docs/EInvoicing/V1/CodeListsApi.md#getcodelist) | **GET** /codelists/{codelistId} | Retrieves a code list by ID for a specific country +*CodeListsApi* | [**getCodeListList**](docs/EInvoicing/V1/CodeListsApi.md#getcodelistlist) | **GET** /codelists | Returns a list of code lists for a specific country *DataInputFieldsApi* | [**getDataInputFields**](docs/EInvoicing/V1/DataInputFieldsApi.md#getdatainputfields) | **GET** /data-input-fields | Returns the optionality of document fields for different country mandates *DocumentsApi* | [**downloadDocument**](docs/EInvoicing/V1/DocumentsApi.md#downloaddocument) | **GET** /documents/{documentId}/$download | Returns a copy of the document *DocumentsApi* | [**fetchDocuments**](docs/EInvoicing/V1/DocumentsApi.md#fetchdocuments) | **POST** /documents/$fetch | Fetch the inbound document from a tax authority @@ -118,11 +120,14 @@ Class | Method | HTTP request | Description *InteropApi* | [**submitInteropDocument**](docs/EInvoicing/V1/InteropApi.md#submitinteropdocument) | **POST** /interop/documents | Submit a document *MandatesApi* | [**getMandateDataInputFields**](docs/EInvoicing/V1/MandatesApi.md#getmandatedatainputfields) | **GET** /mandates/{mandateId}/data-input-fields | Returns document field information for a country mandate, a selected document type, and its version *MandatesApi* | [**getMandates**](docs/EInvoicing/V1/MandatesApi.md#getmandates) | **GET** /mandates | List country mandates that are supported by the Avalara E-Invoicing platform +*ReportsApi* | [**downloadReport**](docs/EInvoicing/V1/ReportsApi.md#downloadreport) | **GET** /reports/{reportId}/$download | Returns a pre-signed download URL for a report +*ReportsApi* | [**getReportById**](docs/EInvoicing/V1/ReportsApi.md#getreportbyid) | **GET** /reports/{reportId}/status | Retrieves a report by its unique ID +*ReportsApi* | [**getReports**](docs/EInvoicing/V1/ReportsApi.md#getreports) | **GET** /reports | Returns a list of reports *SubscriptionsApi* | [**createWebhookSubscription**](docs/EInvoicing/V1/SubscriptionsApi.md#createwebhooksubscription) | **POST** /webhooks/subscriptions | Create a subscription to events -*SubscriptionsApi* | [**deleteWebhookSubscription**](docs/EInvoicing/V1/SubscriptionsApi.md#deletewebhooksubscription) | **DELETE** /webhooks/subscriptions/{subscription-id} | Unsubscribe from events -*SubscriptionsApi* | [**getWebhookSubscription**](docs/EInvoicing/V1/SubscriptionsApi.md#getwebhooksubscription) | **GET** /webhooks/subscriptions/{subscription-id} | Get details of a subscription +*SubscriptionsApi* | [**deleteWebhookSubscription**](docs/EInvoicing/V1/SubscriptionsApi.md#deletewebhooksubscription) | **DELETE** /webhooks/subscriptions/{subscriptionId} | Unsubscribe from events +*SubscriptionsApi* | [**getWebhookSubscription**](docs/EInvoicing/V1/SubscriptionsApi.md#getwebhooksubscription) | **GET** /webhooks/subscriptions/{subscriptionId} | Get details of a subscription *SubscriptionsApi* | [**listWebhookSubscriptions**](docs/EInvoicing/V1/SubscriptionsApi.md#listwebhooksubscriptions) | **GET** /webhooks/subscriptions | List all subscriptions -*TaxIdentifiersApi* | [**taxIdentifierSchemaByCountry**](docs/EInvoicing/V1/TaxIdentifiersApi.md#taxidentifierschemabycountry) | **GET** /tax-identifiers/schema | Returns the tax identifier request & response schema for a specific country. +*TaxIdentifiersApi* | [**taxIdentifierSchemaByCountry**](docs/EInvoicing/V1/TaxIdentifiersApi.md#taxidentifierschemabycountry) | **GET** /tax-identifiers/schema | Returns the tax identifier request and response schema for a specific country. *TaxIdentifiersApi* | [**validateTaxIdentifier**](docs/EInvoicing/V1/TaxIdentifiersApi.md#validatetaxidentifier) | **POST** /tax-identifiers/validate | Validates a tax identifier. *TradingPartnersApi* | [**batchSearchParticipants**](docs/EInvoicing/V1/TradingPartnersApi.md#batchsearchparticipants) | **POST** /trading-partners/batch-searches | Handles batch search requests by uploading a file containing search parameters. *TradingPartnersApi* | [**createTradingPartner**](docs/EInvoicing/V1/TradingPartnersApi.md#createtradingpartner) | **POST** /trading-partners | Creates a new trading partner. @@ -134,39 +139,6 @@ Class | Method | HTTP request | Description *TradingPartnersApi* | [**searchParticipants**](docs/EInvoicing/V1/TradingPartnersApi.md#searchparticipants) | **GET** /trading-partners | Returns a list of participants matching the input query. *TradingPartnersApi* | [**updateTradingPartner**](docs/EInvoicing/V1/TradingPartnersApi.md#updatetradingpartner) | **PUT** /trading-partners/{id} | Updates a trading partner using ID. - -### A1099 V2 API Documentation - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -*CompaniesW9Api* | [**createCompany**](docs/A1099/V2/CompaniesW9Api.md#createcompany) | **POST** /w9/companies | Create a company -*CompaniesW9Api* | [**deleteCompany**](docs/A1099/V2/CompaniesW9Api.md#deletecompany) | **DELETE** /w9/companies/{id} | Delete a company -*CompaniesW9Api* | [**getCompanies**](docs/A1099/V2/CompaniesW9Api.md#getcompanies) | **GET** /w9/companies | List companies -*CompaniesW9Api* | [**getCompany**](docs/A1099/V2/CompaniesW9Api.md#getcompany) | **GET** /w9/companies/{id} | Retrieve a company -*CompaniesW9Api* | [**updateCompany**](docs/A1099/V2/CompaniesW9Api.md#updatecompany) | **PUT** /w9/companies/{id} | Update a company -*Forms1099Api* | [**bulkUpsert1099Forms**](docs/A1099/V2/Forms1099Api.md#bulkupsert1099forms) | **POST** /1099/forms/$bulk-upsert | Create or update multiple 1099/1095/W2/1042S forms -*Forms1099Api* | [**create1099Form**](docs/A1099/V2/Forms1099Api.md#create1099form) | **POST** /1099/forms | Create a 1099/1095/W2/1042S form -*Forms1099Api* | [**delete1099Form**](docs/A1099/V2/Forms1099Api.md#delete1099form) | **DELETE** /1099/forms/{id} | Delete a 1099/1095/W2/1042S form -*Forms1099Api* | [**get1099Form**](docs/A1099/V2/Forms1099Api.md#get1099form) | **GET** /1099/forms/{id} | Retrieve a 1099/1095/W2/1042S form -*Forms1099Api* | [**get1099FormPdf**](docs/A1099/V2/Forms1099Api.md#get1099formpdf) | **GET** /1099/forms/{id}/pdf | Retrieve the PDF file for a 1099/1095/W2/1042S form -*Forms1099Api* | [**list1099Forms**](docs/A1099/V2/Forms1099Api.md#list1099forms) | **GET** /1099/forms | List 1099/1095/W2/1042S forms -*Forms1099Api* | [**update1099Form**](docs/A1099/V2/Forms1099Api.md#update1099form) | **PUT** /1099/forms/{id} | Update a 1099/1095/W2/1042S form -*FormsW9Api* | [**createAndSendW9FormEmail**](docs/A1099/V2/FormsW9Api.md#createandsendw9formemail) | **POST** /w9/forms/$create-and-send-email | Create a minimal W9/W4/W8 form and sends the e-mail request -*FormsW9Api* | [**createW9Form**](docs/A1099/V2/FormsW9Api.md#createw9form) | **POST** /w9/forms | Create a W9/W4/W8 form -*FormsW9Api* | [**deleteW9Form**](docs/A1099/V2/FormsW9Api.md#deletew9form) | **DELETE** /w9/forms/{id} | Delete a W9/W4/W8 form -*FormsW9Api* | [**getW9Form**](docs/A1099/V2/FormsW9Api.md#getw9form) | **GET** /w9/forms/{id} | Retrieve a W9/W4/W8 form -*FormsW9Api* | [**getW9FormPdf**](docs/A1099/V2/FormsW9Api.md#getw9formpdf) | **GET** /w9/forms/{id}/pdf | Download the PDF for a W9/W4/W8 form. -*FormsW9Api* | [**listW9Forms**](docs/A1099/V2/FormsW9Api.md#listw9forms) | **GET** /w9/forms | List W9/W4/W8 forms -*FormsW9Api* | [**sendW9FormEmail**](docs/A1099/V2/FormsW9Api.md#sendw9formemail) | **POST** /w9/forms/{id}/$send-email | Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form -*FormsW9Api* | [**updateW9Form**](docs/A1099/V2/FormsW9Api.md#updatew9form) | **PUT** /w9/forms/{id} | Update a W9/W4/W8 form -*FormsW9Api* | [**uploadW9Files**](docs/A1099/V2/FormsW9Api.md#uploadw9files) | **POST** /w9/forms/{id}/attachment | Replace the PDF file for a W9/W4/W8 form -*Issuers1099Api* | [**createIssuer**](docs/A1099/V2/Issuers1099Api.md#createissuer) | **POST** /1099/issuers | Create an issuer -*Issuers1099Api* | [**deleteIssuer**](docs/A1099/V2/Issuers1099Api.md#deleteissuer) | **DELETE** /1099/issuers/{id} | Delete an issuer -*Issuers1099Api* | [**getIssuer**](docs/A1099/V2/Issuers1099Api.md#getissuer) | **GET** /1099/issuers/{id} | Retrieve an issuer -*Issuers1099Api* | [**getIssuers**](docs/A1099/V2/Issuers1099Api.md#getissuers) | **GET** /1099/issuers | List issuers -*Issuers1099Api* | [**updateIssuer**](docs/A1099/V2/Issuers1099Api.md#updateissuer) | **PUT** /1099/issuers/{id} | Update an issuer -*JobsApi* | [**getJob**](docs/A1099/V2/JobsApi.md#getjob) | **GET** /jobs/{id} | Retrieves information about the job - ## Documentation for Models @@ -180,6 +152,11 @@ Class | Method | HTTP request | Description - [Avalara.SDK.model.EInvoicing.V1.BatchSearch](docs/EInvoicing/V1/BatchSearch.md) - [Avalara.SDK.model.EInvoicing.V1.BatchSearchListResponse](docs/EInvoicing/V1/BatchSearchListResponse.md) - [Avalara.SDK.model.EInvoicing.V1.BatchSearchParticipants202Response](docs/EInvoicing/V1/BatchSearchParticipants202Response.md) + - [Avalara.SDK.model.EInvoicing.V1.CodeListListResponse](docs/EInvoicing/V1/CodeListListResponse.md) + - [Avalara.SDK.model.EInvoicing.V1.CodeListResponse](docs/EInvoicing/V1/CodeListResponse.md) + - [Avalara.SDK.model.EInvoicing.V1.CodeListSummary](docs/EInvoicing/V1/CodeListSummary.md) + - [Avalara.SDK.model.EInvoicing.V1.CodeListValue](docs/EInvoicing/V1/CodeListValue.md) + - [Avalara.SDK.model.EInvoicing.V1.CodeListVersion](docs/EInvoicing/V1/CodeListVersion.md) - [Avalara.SDK.model.EInvoicing.V1.ConditionalForField](docs/EInvoicing/V1/ConditionalForField.md) - [Avalara.SDK.model.EInvoicing.V1.Consents](docs/EInvoicing/V1/Consents.md) - [Avalara.SDK.model.EInvoicing.V1.CreateTradingPartner201Response](docs/EInvoicing/V1/CreateTradingPartner201Response.md) @@ -221,6 +198,9 @@ Class | Method | HTTP request | Description - [Avalara.SDK.model.EInvoicing.V1.NotUsedForField](docs/EInvoicing/V1/NotUsedForField.md) - [Avalara.SDK.model.EInvoicing.V1.OutputDataFormats](docs/EInvoicing/V1/OutputDataFormats.md) - [Avalara.SDK.model.EInvoicing.V1.Pagination](docs/EInvoicing/V1/Pagination.md) + - [Avalara.SDK.model.EInvoicing.V1.ReportDownloadResponse](docs/EInvoicing/V1/ReportDownloadResponse.md) + - [Avalara.SDK.model.EInvoicing.V1.ReportItem](docs/EInvoicing/V1/ReportItem.md) + - [Avalara.SDK.model.EInvoicing.V1.ReportListResponse](docs/EInvoicing/V1/ReportListResponse.md) - [Avalara.SDK.model.EInvoicing.V1.RequiredWhenField](docs/EInvoicing/V1/RequiredWhenField.md) - [Avalara.SDK.model.EInvoicing.V1.SearchParticipants200Response](docs/EInvoicing/V1/SearchParticipants200Response.md) - [Avalara.SDK.model.EInvoicing.V1.Signature](docs/EInvoicing/V1/Signature.md) @@ -235,6 +215,7 @@ Class | Method | HTTP request | Description - [Avalara.SDK.model.EInvoicing.V1.SubscriptionListResponse](docs/EInvoicing/V1/SubscriptionListResponse.md) - [Avalara.SDK.model.EInvoicing.V1.SubscriptionRegistration](docs/EInvoicing/V1/SubscriptionRegistration.md) - [Avalara.SDK.model.EInvoicing.V1.SuccessResponse](docs/EInvoicing/V1/SuccessResponse.md) + - [Avalara.SDK.model.EInvoicing.V1.SupportedDocumentStatuses](docs/EInvoicing/V1/SupportedDocumentStatuses.md) - [Avalara.SDK.model.EInvoicing.V1.SupportedDocumentTypes](docs/EInvoicing/V1/SupportedDocumentTypes.md) - [Avalara.SDK.model.EInvoicing.V1.TaxIdentifierRequest](docs/EInvoicing/V1/TaxIdentifierRequest.md) - [Avalara.SDK.model.EInvoicing.V1.TaxIdentifierResponse](docs/EInvoicing/V1/TaxIdentifierResponse.md) @@ -247,67 +228,3 @@ Class | Method | HTTP request | Description - [Avalara.SDK.model.EInvoicing.V1.WebhooksErrorInfo](docs/EInvoicing/V1/WebhooksErrorInfo.md) - [Avalara.SDK.model.EInvoicing.V1.WebhooksErrorResponse](docs/EInvoicing/V1/WebhooksErrorResponse.md) - [Avalara.SDK.model.EInvoicing.V1.WorkflowIds](docs/EInvoicing/V1/WorkflowIds.md) - - - -### A1099 V2 Model Documentation - - - [Avalara.SDK.model.A1099.V2.CompanyBase](docs/A1099/V2/CompanyBase.md) - - [Avalara.SDK.model.A1099.V2.CompanyRequest](docs/A1099/V2/CompanyRequest.md) - - [Avalara.SDK.model.A1099.V2.CompanyResponse](docs/A1099/V2/CompanyResponse.md) - - [Avalara.SDK.model.A1099.V2.CoveredIndividual](docs/A1099/V2/CoveredIndividual.md) - - [Avalara.SDK.model.A1099.V2.CreateAndSendW9FormEmailRequest](docs/A1099/V2/CreateAndSendW9FormEmailRequest.md) - - [Avalara.SDK.model.A1099.V2.CreateW9Form201Response](docs/A1099/V2/CreateW9Form201Response.md) - - [Avalara.SDK.model.A1099.V2.CreateW9FormRequest](docs/A1099/V2/CreateW9FormRequest.md) - - [Avalara.SDK.model.A1099.V2.EntryStatusResponse](docs/A1099/V2/EntryStatusResponse.md) - - [Avalara.SDK.model.A1099.V2.ErrorResponse](docs/A1099/V2/ErrorResponse.md) - - [Avalara.SDK.model.A1099.V2.ErrorResponseItem](docs/A1099/V2/ErrorResponseItem.md) - - [Avalara.SDK.model.A1099.V2.Form1042S](docs/A1099/V2/Form1042S.md) - - [Avalara.SDK.model.A1099.V2.Form1095B](docs/A1099/V2/Form1095B.md) - - [Avalara.SDK.model.A1099.V2.Form1095C](docs/A1099/V2/Form1095C.md) - - [Avalara.SDK.model.A1099.V2.Form1099Base](docs/A1099/V2/Form1099Base.md) - - [Avalara.SDK.model.A1099.V2.Form1099Div](docs/A1099/V2/Form1099Div.md) - - [Avalara.SDK.model.A1099.V2.Form1099Int](docs/A1099/V2/Form1099Int.md) - - [Avalara.SDK.model.A1099.V2.Form1099K](docs/A1099/V2/Form1099K.md) - - [Avalara.SDK.model.A1099.V2.Form1099ListRequest](docs/A1099/V2/Form1099ListRequest.md) - - [Avalara.SDK.model.A1099.V2.Form1099Misc](docs/A1099/V2/Form1099Misc.md) - - [Avalara.SDK.model.A1099.V2.Form1099Nec](docs/A1099/V2/Form1099Nec.md) - - [Avalara.SDK.model.A1099.V2.Form1099R](docs/A1099/V2/Form1099R.md) - - [Avalara.SDK.model.A1099.V2.Form1099StatusDetail](docs/A1099/V2/Form1099StatusDetail.md) - - [Avalara.SDK.model.A1099.V2.Get1099Form200Response](docs/A1099/V2/Get1099Form200Response.md) - - [Avalara.SDK.model.A1099.V2.IntermediaryOrFlowThrough](docs/A1099/V2/IntermediaryOrFlowThrough.md) - - [Avalara.SDK.model.A1099.V2.IrsResponse](docs/A1099/V2/IrsResponse.md) - - [Avalara.SDK.model.A1099.V2.IssuerBase](docs/A1099/V2/IssuerBase.md) - - [Avalara.SDK.model.A1099.V2.IssuerRequest](docs/A1099/V2/IssuerRequest.md) - - [Avalara.SDK.model.A1099.V2.IssuerResponse](docs/A1099/V2/IssuerResponse.md) - - [Avalara.SDK.model.A1099.V2.JobResponse](docs/A1099/V2/JobResponse.md) - - [Avalara.SDK.model.A1099.V2.OfferAndCoverage](docs/A1099/V2/OfferAndCoverage.md) - - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelCompanyResponse](docs/A1099/V2/PaginatedQueryResultModelCompanyResponse.md) - - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelForm1099Base](docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md) - - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelIssuerResponse](docs/A1099/V2/PaginatedQueryResultModelIssuerResponse.md) - - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelW9FormBaseResponse](docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md) - - [Avalara.SDK.model.A1099.V2.PrimaryWithholdingAgent](docs/A1099/V2/PrimaryWithholdingAgent.md) - - [Avalara.SDK.model.A1099.V2.StateAndLocalWithholding](docs/A1099/V2/StateAndLocalWithholding.md) - - [Avalara.SDK.model.A1099.V2.StateEfileStatusDetail](docs/A1099/V2/StateEfileStatusDetail.md) - - [Avalara.SDK.model.A1099.V2.SubstantialUsOwnerRequest](docs/A1099/V2/SubstantialUsOwnerRequest.md) - - [Avalara.SDK.model.A1099.V2.SubstantialUsOwnerResponse](docs/A1099/V2/SubstantialUsOwnerResponse.md) - - [Avalara.SDK.model.A1099.V2.TinMatchStatusResponse](docs/A1099/V2/TinMatchStatusResponse.md) - - [Avalara.SDK.model.A1099.V2.ValidationError](docs/A1099/V2/ValidationError.md) - - [Avalara.SDK.model.A1099.V2.W4FormMinimalRequest](docs/A1099/V2/W4FormMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W4FormRequest](docs/A1099/V2/W4FormRequest.md) - - [Avalara.SDK.model.A1099.V2.W4FormResponse](docs/A1099/V2/W4FormResponse.md) - - [Avalara.SDK.model.A1099.V2.W8BenEFormMinimalRequest](docs/A1099/V2/W8BenEFormMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W8BenEFormRequest](docs/A1099/V2/W8BenEFormRequest.md) - - [Avalara.SDK.model.A1099.V2.W8BenEFormResponse](docs/A1099/V2/W8BenEFormResponse.md) - - [Avalara.SDK.model.A1099.V2.W8BenFormMinimalRequest](docs/A1099/V2/W8BenFormMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W8BenFormRequest](docs/A1099/V2/W8BenFormRequest.md) - - [Avalara.SDK.model.A1099.V2.W8BenFormResponse](docs/A1099/V2/W8BenFormResponse.md) - - [Avalara.SDK.model.A1099.V2.W8ImyFormMinimalRequest](docs/A1099/V2/W8ImyFormMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W8ImyFormRequest](docs/A1099/V2/W8ImyFormRequest.md) - - [Avalara.SDK.model.A1099.V2.W8ImyFormResponse](docs/A1099/V2/W8ImyFormResponse.md) - - [Avalara.SDK.model.A1099.V2.W9FormBaseMinimalRequest](docs/A1099/V2/W9FormBaseMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W9FormBaseRequest](docs/A1099/V2/W9FormBaseRequest.md) - - [Avalara.SDK.model.A1099.V2.W9FormBaseResponse](docs/A1099/V2/W9FormBaseResponse.md) - - [Avalara.SDK.model.A1099.V2.W9FormMinimalRequest](docs/A1099/V2/W9FormMinimalRequest.md) - - [Avalara.SDK.model.A1099.V2.W9FormRequest](docs/A1099/V2/W9FormRequest.md) - - [Avalara.SDK.model.A1099.V2.W9FormResponse](docs/A1099/V2/W9FormResponse.md) diff --git a/docs/EInvoicing/V1/CodeListListResponse.md b/docs/EInvoicing/V1/CodeListListResponse.md new file mode 100644 index 0000000..73f11f3 --- /dev/null +++ b/docs/EInvoicing/V1/CodeListListResponse.md @@ -0,0 +1,16 @@ + + +# CodeListListResponse + +Returns the requested list of code lists + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**atRecordsetCount** | **String** | Count of code lists for the given query parameters | [optional] | +|**atNextLink** | **String** | | [optional] | +|**value** | [**List<CodeListSummary>**](CodeListSummary.md) | Array of code lists matching query parameters | | + + + diff --git a/docs/EInvoicing/V1/CodeListResponse.md b/docs/EInvoicing/V1/CodeListResponse.md new file mode 100644 index 0000000..040b063 --- /dev/null +++ b/docs/EInvoicing/V1/CodeListResponse.md @@ -0,0 +1,19 @@ + + +# CodeListResponse + +Returns a code list definition for a specific country + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**countryCode** | **String** | Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. | [optional] | +|**codeListId** | **String** | System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. | [optional] | +|**codeListName** | **String** | Human-readable name of the code list, usually describing what the codes represent (for example, document types, tax categories, currencies). | [optional] | +|**description** | **String** | Textual description of the code list, including what it is used for and whether it represents a global standard (e.g., UN/CEFACT, ISO, EN16931) or a jurisdiction-specific/local extension of that standard. | [optional] | +|**standard** | **String** | Identifier of the underlying standard or authoritative source for this code list. This may be a formal code list name (e.g., UNCL1001), a standard reference (e.g., EN16931), or an internal standard identifier. | [optional] | +|**versions** | [**List<CodeListVersion>**](CodeListVersion.md) | Array of versioned definitions of this code list for the given jurisdiction. Each entry represents a version that is valid for a specific effective/sunset date range, optionally per locale. | [optional] | + + + diff --git a/docs/EInvoicing/V1/CodeListSummary.md b/docs/EInvoicing/V1/CodeListSummary.md new file mode 100644 index 0000000..edeb680 --- /dev/null +++ b/docs/EInvoicing/V1/CodeListSummary.md @@ -0,0 +1,19 @@ + + +# CodeListSummary + +Displays a summary of information about a code list + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**countryCode** | **String** | Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. | [optional] | +|**codeListId** | **String** | System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. | [optional] | +|**codeListName** | **String** | Human-readable name of the code list, usually describing what the codes represent (for example, document types, tax categories, currencies). | [optional] | +|**description** | **String** | Textual description of the code list, including what it is used for and whether it represents a global standard (e.g., UN/CEFACT, ISO, EN16931) or a jurisdiction-specific/local extension of that standard. | [optional] | +|**standard** | **String** | Identifier of the underlying standard or authoritative source for this code list. This may be a formal code list name (e.g., UNCL1001), a standard reference (e.g., EN16931), or an internal standard identifier. | [optional] | +|**versions** | [**List<CodeListVersion>**](CodeListVersion.md) | Array of versioned definitions of this code list for the given jurisdiction. Each entry represents a version that is valid for a specific effective/sunset date range, optionally per locale. | [optional] | + + + diff --git a/docs/EInvoicing/V1/CodeListValue.md b/docs/EInvoicing/V1/CodeListValue.md new file mode 100644 index 0000000..f55c1f8 --- /dev/null +++ b/docs/EInvoicing/V1/CodeListValue.md @@ -0,0 +1,16 @@ + + +# CodeListValue + +Represents a single code entry in a code list version + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**code** | **String** | The actual code value used in documents or systems. This is typically what appears in the e-invoice payload, such as a numeric or alphanumeric code from the official code list. | [optional] | +|**value** | **String** | Human-readable label or name for the code, localized according to the locale field of the version. | [optional] | +|**description** | **String** | Detailed explanation of what the code represents, localized according to the locale field of the version. | [optional] | + + + diff --git a/docs/EInvoicing/V1/CodeListVersion.md b/docs/EInvoicing/V1/CodeListVersion.md new file mode 100644 index 0000000..d46ba36 --- /dev/null +++ b/docs/EInvoicing/V1/CodeListVersion.md @@ -0,0 +1,18 @@ + + +# CodeListVersion + +Represents a versioned definition of a code list for a specific jurisdiction and date range + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**versionReasons** | **List<String>** | List of free-text reasons explaining why this version of the code list exists (for example, initial introduction, regulatory update, addition/deprecation of codes). Useful for audit and change tracking. | [optional] | +|**jurisEffectiveDate** | **LocalDate** | Date from which this version of the code list becomes legally or operationally effective in the jurisdiction. Typically corresponds to a go-live, mandate, or release date. | [optional] | +|**jurisSunsetDate** | **LocalDate** | Date after which this version of the code list must no longer be used in the jurisdiction. Use a far-future date (e.g., 9999-12-31) when the sunset is not yet known. | [optional] | +|**locale** | **String** | Language–region locale identifier indicating the language and regional variant for descriptions in this version of the code list. Follows BCP-47 format such as en-US, fr-FR, de-DE. | [optional] | +|**values** | [**List<CodeListValue>**](CodeListValue.md) | Array of code entries defined in this version of the code list. Each entry contains the machine-readable code value and its human-readable description in the given locale. | [optional] | + + + diff --git a/docs/EInvoicing/V1/CodeListsApi.md b/docs/EInvoicing/V1/CodeListsApi.md new file mode 100644 index 0000000..7b32f1c --- /dev/null +++ b/docs/EInvoicing/V1/CodeListsApi.md @@ -0,0 +1,199 @@ +# CodeListsApi + +All URIs are relative to *https://api.sbx.avalara.com/einvoicing* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getCodeList**](CodeListsApi.md#getCodeList) | **GET** /codelists/{codelistId} | Retrieves a code list by ID for a specific country +[**getCodeListList**](CodeListsApi.md#getCodeListList) | **GET** /codelists | Returns a list of code lists for a specific country + + + +## getCodeList + +> CodeListResponse getCodeList(avalaraVersion, codelistId, countryCode, xAvalaraClient, effectiveDate, sunsetDate) + +Retrieves a code list by ID for a specific country + +A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions.<br><br>Code Lists are versioned, and each version may have defined effective and sunset dates to ensure that the correct set of allowable values is applied according to regulatory or jurisdictional requirements.<br><br>By default, the API returns only non-expired code list versions (versions where the sunset date has not passed). To retrieve expired versions or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters. + +### Example + +```java +// Import classes: +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.Configuration; +import Avalara.SDK.auth.*; +import Avalara.SDK.models.*; +import Avalara.SDK.api.EInvoicing.V1.CodeListsApi; + +public class Example { + public static void main(String[] args) { + Configuration configuration = new Configuration(); + configuration.setAppName("Test"); + configuration.setAppVersion("1.0"); + configuration.setMachineName("LocalBox"); + configuration.setTimeout(5000); + configuration.setEnvironment(AvaTaxEnvironment.Sandbox); + // Configure HTTP basic authorization + configuration.setUsername("YOUR USERNAME"); + configuration.setPassword("YOUR PASSWORD"); + // Configure OAuth2 access token for authorization + configuration.setBearerToken("YOUR ACCESS TOKEN"); + + ApiClient apiClient = new ApiClient(configuration); + + CodeListsApi apiInstance = new CodeListsApi(apiClient); + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String codelistId = "ab123343-3432-423c-ac3f-53453scs9999"; // String | System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. + String countryCode = "FR"; // String | Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + LocalDate effectiveDate = LocalDate.parse("Tue Dec 31 16:00:00 PST 2024"); // LocalDate | Filter code list versions by effective date. Returns versions that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. + LocalDate sunsetDate = LocalDate.parse("Wed Dec 30 16:00:00 PST 2026"); // LocalDate | Filter code list versions by sunset date. Returns versions that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired versions are returned. + try { + CodeListResponse result = apiInstance.getCodeList(avalaraVersion, codelistId, countryCode, xAvalaraClient, effectiveDate, sunsetDate); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CodeListsApi#getCodeList"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **codelistId** | **String**| System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. | + **countryCode** | **String**| Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **effectiveDate** | **LocalDate**| Filter code list versions by effective date. Returns versions that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. | [optional] + **sunsetDate** | **LocalDate**| Filter code list versions by sunset date. Returns versions that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired versions are returned. | [optional] + +### Return type + +[**CodeListResponse**](CodeListResponse.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** | OK | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | +| **404** | Code list not found. | - | + + +## getCodeListList + +> CodeListListResponse getCodeListList(avalaraVersion, countryCode, xAvalaraClient, effectiveDate, sunsetDate, $count, $countOnly, $top, $skip) + +Returns a list of code lists for a specific country + +Get a list of code lists on the Avalara E-Invoicing platform for the specified country. By default, the API returns only non-expired code lists (code lists where the sunset date has not passed). To retrieve expired code lists or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters.<br><br>A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions. + +### Example + +```java +// Import classes: +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.Configuration; +import Avalara.SDK.auth.*; +import Avalara.SDK.models.*; +import Avalara.SDK.api.EInvoicing.V1.CodeListsApi; + +public class Example { + public static void main(String[] args) { + Configuration configuration = new Configuration(); + configuration.setAppName("Test"); + configuration.setAppVersion("1.0"); + configuration.setMachineName("LocalBox"); + configuration.setTimeout(5000); + configuration.setEnvironment(AvaTaxEnvironment.Sandbox); + // Configure HTTP basic authorization + configuration.setUsername("YOUR USERNAME"); + configuration.setPassword("YOUR PASSWORD"); + // Configure OAuth2 access token for authorization + configuration.setBearerToken("YOUR ACCESS TOKEN"); + + ApiClient apiClient = new ApiClient(configuration); + + CodeListsApi apiInstance = new CodeListsApi(apiClient); + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String countryCode = "FR"; // String | Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction for which code lists should be returned. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + LocalDate effectiveDate = LocalDate.parse("Tue Dec 31 16:00:00 PST 2024"); // LocalDate | Filter code lists by effective date. Returns code lists that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. + LocalDate sunsetDate = LocalDate.parse("Wed Dec 30 16:00:00 PST 2026"); // LocalDate | Filter code lists by sunset date. Returns code lists that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired code lists are returned. + String $count = "true"; // String | When set to true, the response body also includes the count of items in the collection. + String $countOnly = "false"; // String | When set to true, the response returns only the count of items in the collection. + Integer $top = 56; // Integer | The number of items to include in the result. + Integer $skip = 56; // Integer | The number of items to skip in the result. + try { + CodeListListResponse result = apiInstance.getCodeListList(avalaraVersion, countryCode, xAvalaraClient, effectiveDate, sunsetDate, $count, $countOnly, $top, $skip); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling CodeListsApi#getCodeListList"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **countryCode** | **String**| Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction for which code lists should be returned. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **effectiveDate** | **LocalDate**| Filter code lists by effective date. Returns code lists that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. | [optional] + **sunsetDate** | **LocalDate**| Filter code lists by sunset date. Returns code lists that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired code lists are returned. | [optional] + **$count** | **String**| When set to true, the response body also includes the count of items in the collection. | [optional] + **$countOnly** | **String**| When set to true, the response returns only the count of items in the collection. | [optional] + **$top** | **Integer**| The number of items to include in the result. | [optional] + **$skip** | **Integer**| The number of items to skip in the result. | [optional] + +### Return type + +[**CodeListListResponse**](CodeListListResponse.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** | OK | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | + diff --git a/docs/EInvoicing/V1/DataInputFieldsApi.md b/docs/EInvoicing/V1/DataInputFieldsApi.md index 13fc050..3fefa6c 100644 --- a/docs/EInvoicing/V1/DataInputFieldsApi.md +++ b/docs/EInvoicing/V1/DataInputFieldsApi.md @@ -14,7 +14,7 @@ Method | HTTP request | Description Returns the optionality of document fields for different country mandates -This endpoint provides a list of required, conditional, and optional fields for each country mandate. You can use the <code>mandates</code> endpoint to retrieve all available country mandates. You can use the $filter query parameter to retrieve fields for a particular mandate +This endpoint returns a list of required, conditional, and optional fields for each country mandate. Use the mandates endpoint to retrieve all available country mandates. Use the $filter query parameter to retrieve fields for a specific mandate. ### Example @@ -44,13 +44,13 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DataInputFieldsApi apiInstance = new DataInputFieldsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. - String $filter = "requiredFor/countryMandate eq AU-B2G-PEPPOL"; // String | Filter by field name and value. This filter only supports eq and contains. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String $filter = "requiredFor/countryMandate eq AU-B2G-PEPPOL"; // String | Filter by field name and value. This filter supports only eq and contains. For more information, refer to the Avalara filtering guide. Integer $top = 56; // Integer | The number of items to include in the result. Integer $skip = 56; // Integer | The number of items to skip in the result. - Boolean $count = true; // Boolean | When set to true, the count of the collection is also returned in the response body - Boolean $countOnly = true; // Boolean | When set to true, only the count of the collection is returned + Boolean $count = true; // Boolean | When set to true, the response body also includes the count of items in the collection. + Boolean $countOnly = true; // Boolean | When set to true, the response returns only the count of items in the collection. try { DataInputFieldsResponse result = apiInstance.getDataInputFields(avalaraVersion, xAvalaraClient, $filter, $top, $skip, $count, $countOnly); System.out.println(result); @@ -70,13 +70,13 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] - **$filter** | **String**| Filter by field name and value. This filter only supports <code>eq</code> and <code>contains</code>. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **$filter** | **String**| Filter by field name and value. This filter supports only eq and contains. For more information, refer to the Avalara filtering guide. | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] **$skip** | **Integer**| The number of items to skip in the result. | [optional] - **$count** | **Boolean**| When set to true, the count of the collection is also returned in the response body | [optional] - **$countOnly** | **Boolean**| When set to true, only the count of the collection is returned | [optional] + **$count** | **Boolean**| When set to true, the response body also includes the count of items in the collection. | [optional] + **$countOnly** | **Boolean**| When set to true, the response returns only the count of items in the collection. | [optional] ### Return type @@ -95,8 +95,8 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | -| **500** | Internal Server Error | - | +| **200** | Returns a DataInputFieldsResponse object containing the data input fields and their optionality for the requested mandate. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | +| **500** | Internal server error. | - | diff --git a/docs/EInvoicing/V1/DocumentStatusResponse.md b/docs/EInvoicing/V1/DocumentStatusResponse.md index 5988af3..b6b36ae 100644 --- a/docs/EInvoicing/V1/DocumentStatusResponse.md +++ b/docs/EInvoicing/V1/DocumentStatusResponse.md @@ -9,7 +9,8 @@ Returns the current document ID and status | Name | Type | Description | Notes | |------------ | ------------- | ------------- | -------------| |**id** | **String** | The unique ID for this document | [optional] | -|**status** | **String** | Status of the document | [optional] | +|**status** | **String** | Document status. See the `supportedDocumentStatuses` field in the GET /mandates response for full status definitions. | [optional] | +|**businessStatus** | **String** | Represents the document's business lifecycle state based on responses from external actors (Tax Authority, PDP, or ERP), such as acceptance, rejection, or validation. | [optional] | |**events** | [**List<StatusEvent>**](StatusEvent.md) | | [optional] | diff --git a/docs/EInvoicing/V1/DocumentSummary.md b/docs/EInvoicing/V1/DocumentSummary.md index 3f244a9..cd4ffe5 100644 --- a/docs/EInvoicing/V1/DocumentSummary.md +++ b/docs/EInvoicing/V1/DocumentSummary.md @@ -12,6 +12,7 @@ Displays a summary of information about the document |**companyId** | **String** | Unique identifier that represents the company within the system. | [optional] | |**processDateTime** | **String** | The date and time when the document was processed, displayed in the format YYYY-MM-DDThh:mm:ss | [optional] | |**status** | **String** | The Document status | [optional] | +|**businessStatus** | **String** | Represents the document's business lifecycle state based on responses from external actors (Tax Authority, PDP, or ERP), such as acceptance, rejection, or validation. | [optional] | |**supplierName** | **String** | The name of the supplier in the transaction | [optional] | |**customerName** | **String** | The name of the customer in the transaction | [optional] | |**documentType** | **String** | The document type | [optional] | @@ -23,6 +24,9 @@ Displays a summary of information about the document |**countryMandate** | **String** | The e-invoicing mandate for the specified country | [optional] | |**_interface** | **String** | The interface where the document is sent | [optional] | |**receiver** | **String** | The document recipient based on the interface | [optional] | +|**events** | [**List<StatusEvent>**](StatusEvent.md) | Array of status events associated with this document. Events are included in each document in the response only when the query parameter $include=events is passed; otherwise the events array is not populated. | [optional] | +|**createdAt** | **String** | The date and time when the document was created in the system, displayed in ISO 8601 format with timezone | [optional] | +|**lastUpdatedAt** | **String** | The date and time when the document was last updated in the system, displayed in ISO 8601 format with timezone | [optional] | diff --git a/docs/EInvoicing/V1/DocumentsApi.md b/docs/EInvoicing/V1/DocumentsApi.md index e2592b3..40e85d8 100644 --- a/docs/EInvoicing/V1/DocumentsApi.md +++ b/docs/EInvoicing/V1/DocumentsApi.md @@ -18,7 +18,7 @@ Method | HTTP request | Description Returns a copy of the document -When the document is available, use this endpoint to download it as text, XML, or PDF. The output format needs to be specified in the Accept header, and it will vary depending on the mandate. If the file has not yet been created, then status code 404 (not found) is returned. +Downloads the document when it is available. Specify the output format in the Accept header. Returns 404 if the file has not been created. ### Example @@ -48,10 +48,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DocumentsApi apiInstance = new DocumentsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String accept = "application/pdf"; // String | This header indicates the MIME type of the document - String documentId = "documentId_example"; // String | The unique ID for this document that was returned in the POST /einvoicing/document response body - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String accept = "application/pdf"; // String | Header that specifies the MIME type of the returned document. + String documentId = "documentId_example"; // String | The unique documentId returned in the POST /documents response body. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). try { File result = apiInstance.downloadDocument(avalaraVersion, accept, documentId, xAvalaraClient); System.out.println(result); @@ -71,10 +71,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **accept** | **String**| This header indicates the MIME type of the document | - **documentId** | **String**| The unique ID for this document that was returned in the POST /einvoicing/document response body | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **accept** | **String**| Header that specifies the MIME type of the returned document. | + **documentId** | **String**| The unique documentId returned in the POST /documents response body. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] ### Return type @@ -93,11 +93,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | * Content-type -
| -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **200** | Returns the document content in the format specified by the Accept header. | * Content-type -
| +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | | **404** | A document for the specified ID was not found. | - | -| **406** | Unsupported document format was requested in the Accept header | - | +| **406** | Unsupported document format was requested in the Accept header. | - | ## fetchDocuments @@ -106,7 +106,7 @@ Name | Type | Description | Notes Fetch the inbound document from a tax authority -This API allows you to retrieve an inbound document. Pass key-value pairs as parameters in the request, such as the confirmation number, supplier number, and buyer VAT number. +Retrieves an inbound document. Provide key-value pairs as request parameters. Supported parameters vary by tax authority and country. ### Example @@ -136,9 +136,9 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DocumentsApi apiInstance = new DocumentsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). FetchDocumentsRequest fetchDocumentsRequest = new FetchDocumentsRequest(); // FetchDocumentsRequest | - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). try { DocumentFetch result = apiInstance.fetchDocuments(avalaraVersion, fetchDocumentsRequest, xAvalaraClient); System.out.println(result); @@ -158,9 +158,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | **fetchDocumentsRequest** | [**FetchDocumentsRequest**](FetchDocumentsRequest.md)| | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] ### Return type @@ -179,19 +179,19 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | Accepted DocumentFetch Request | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | -| **500** | Internal Server Error | - | +| **200** | Response from the inbound document fetch endpoint. Contains the platform documentId for status checks and downloads, the returned status (e.g. Accepted), and eventDateTime when the document was accepted. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | +| **500** | Internal server error. | - | ## getDocumentList -> DocumentListResponse getDocumentList(avalaraVersion, xAvalaraClient, startDate, endDate, flow, $count, $countOnly, $filter, $top, $skip) +> DocumentListResponse getDocumentList(avalaraVersion, xAvalaraClient, startDate, endDate, flow, $count, $countOnly, $filter, $include, $top, $skip) Returns a summary of documents for a date range -Get a list of documents on the Avalara E-Invoicing platform that have a processing date within the specified date range. +Returns a list of document summaries with a processing date within the specified date range. ### Example @@ -221,18 +221,19 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DocumentsApi apiInstance = new DocumentsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. - OffsetDateTime startDate = OffsetDateTime.now(); // OffsetDateTime | Start date of documents to return. This defaults to the previous month. - OffsetDateTime endDate = OffsetDateTime.now(); // OffsetDateTime | End date of documents to return. This defaults to the current date. - String flow = "out"; // String | Optionally filter by document direction, where issued = `out` and received = `in` - String $count = "true"; // String | When set to true, the count of the collection is also returned in the response body - String $countOnly = "false"; // String | When set to true, only the count of the collection is returned - String $filter = "id eq 52f60401-44d0-4667-ad47-4afe519abb53"; // String | Filter by field name and value. This filter only supports eq . Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. Filtering will be done over the provided startDate and endDate. If no startDate or endDate is provided, defaults will be assumed. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + OffsetDateTime startDate = OffsetDateTime.now(); // OffsetDateTime | Start date for documents to return. Defaults to the previous month. Format: \"YYYY-MM-DDThh:mm:ss\". + OffsetDateTime endDate = OffsetDateTime.now(); // OffsetDateTime | End date for documents to return. Defaults to the current date. Format: \"YYYY-MM-DDThh:mm:ss\". + String flow = "out"; // String | Optional filter for document direction: issued uses \"out\" and received uses \"in\". + String $count = "true"; // String | When set to true, the response body also includes the count of items in the collection. + String $countOnly = "false"; // String | When set to true, the response returns only the count of items in the collection. + String $filter = "id eq 52f60401-44d0-4667-ad47-4afe519abb53"; // String | Filter by field name and value. This filter supports only eq. For more information, refer to the Avalara filtering guide. + String $include = "events"; // String | When set to `events`, each document in the response includes its events array. Omit this parameter or use any other value to exclude events from the response. Integer $top = 56; // Integer | The number of items to include in the result. Integer $skip = 56; // Integer | The number of items to skip in the result. try { - DocumentListResponse result = apiInstance.getDocumentList(avalaraVersion, xAvalaraClient, startDate, endDate, flow, $count, $countOnly, $filter, $top, $skip); + DocumentListResponse result = apiInstance.getDocumentList(avalaraVersion, xAvalaraClient, startDate, endDate, flow, $count, $countOnly, $filter, $include, $top, $skip); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling DocumentsApi#getDocumentList"); @@ -250,14 +251,15 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] - **startDate** | **OffsetDateTime**| Start date of documents to return. This defaults to the previous month. | [optional] - **endDate** | **OffsetDateTime**| End date of documents to return. This defaults to the current date. | [optional] - **flow** | **String**| Optionally filter by document direction, where issued = `out` and received = `in` | [optional] - **$count** | **String**| When set to true, the count of the collection is also returned in the response body | [optional] - **$countOnly** | **String**| When set to true, only the count of the collection is returned | [optional] - **$filter** | **String**| Filter by field name and value. This filter only supports <code>eq</code> . Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. Filtering will be done over the provided startDate and endDate. If no startDate or endDate is provided, defaults will be assumed. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **startDate** | **OffsetDateTime**| Start date for documents to return. Defaults to the previous month. Format: \"YYYY-MM-DDThh:mm:ss\". | [optional] + **endDate** | **OffsetDateTime**| End date for documents to return. Defaults to the current date. Format: \"YYYY-MM-DDThh:mm:ss\". | [optional] + **flow** | **String**| Optional filter for document direction: issued uses \"out\" and received uses \"in\". | [optional] + **$count** | **String**| When set to true, the response body also includes the count of items in the collection. | [optional] + **$countOnly** | **String**| When set to true, the response returns only the count of items in the collection. | [optional] + **$filter** | **String**| Filter by field name and value. This filter supports only eq. For more information, refer to the Avalara filtering guide. | [optional] + **$include** | **String**| When set to `events`, each document in the response includes its events array. Omit this parameter or use any other value to exclude events from the response. | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] **$skip** | **Integer**| The number of items to skip in the result. | [optional] @@ -278,10 +280,10 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | - | -| **400** | Bad request | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **200** | Returns a collection of document summaries for the specified date range. | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | ## getDocumentStatus @@ -290,7 +292,7 @@ Name | Type | Description | Notes Checks the status of a document -Using the unique ID from POST /einvoicing/documents response body, request the current status of a document. +Uses the documentId from the POST /documents response body to return the current status of a document. ### Example @@ -320,9 +322,9 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DocumentsApi apiInstance = new DocumentsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String documentId = "documentId_example"; // String | The unique ID for this document that was returned in the POST /einvoicing/documents response body - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String documentId = "documentId_example"; // String | The unique documentId returned in the POST /documents response body. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). try { DocumentStatusResponse result = apiInstance.getDocumentStatus(avalaraVersion, documentId, xAvalaraClient); System.out.println(result); @@ -342,9 +344,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **documentId** | **String**| The unique ID for this document that was returned in the POST /einvoicing/documents response body | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **documentId** | **String**| The unique documentId returned in the POST /documents response body. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] ### Return type @@ -363,9 +365,9 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **200** | Returns the current status for the specified documentId. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | | **404** | A document for the specified ID was not found. | - | @@ -405,10 +407,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); DocumentsApi apiInstance = new DocumentsApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). SubmitDocumentMetadata metadata = new SubmitDocumentMetadata(); // SubmitDocumentMetadata | Object data = null; // Object | The document to be submitted, as indicated by the metadata fields 'dataFormat' and 'dataFormatVersion' - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). try { DocumentSubmitResponse result = apiInstance.submitDocument(avalaraVersion, metadata, data, xAvalaraClient); System.out.println(result); @@ -428,10 +430,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | **metadata** | [**SubmitDocumentMetadata**](SubmitDocumentMetadata.md)| | **data** | [**Object**](Object.md)| The document to be submitted, as indicated by the metadata fields 'dataFormat' and 'dataFormatVersion' | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] ### Return type @@ -450,8 +452,8 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **201** | Created | - | -| **400** | Bad request | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **201** | Returns a unique documentId for the submitted document. | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | diff --git a/docs/EInvoicing/V1/Identifier.md b/docs/EInvoicing/V1/Identifier.md index 0c4cfdc..a273552 100644 --- a/docs/EInvoicing/V1/Identifier.md +++ b/docs/EInvoicing/V1/Identifier.md @@ -10,6 +10,7 @@ |**name** | **String** | Identifier name (e.g., Peppol Participant ID). | | |**displayName** | **String** | Display name of the identifier. | [optional] | |**value** | **String** | Value of the identifier. | | +|**extensions** | [**List<Extension>**](Extension.md) | Optional array used to carry additional metadata or configuration values for the identifier. | [optional] | diff --git a/docs/EInvoicing/V1/InteropApi.md b/docs/EInvoicing/V1/InteropApi.md index 7a01b68..a3be0a9 100644 --- a/docs/EInvoicing/V1/InteropApi.md +++ b/docs/EInvoicing/V1/InteropApi.md @@ -14,7 +14,7 @@ Method | HTTP request | Description Submit a document -This API used by the interoperability partners to submit a document to their trading partners in Avalara on behalf of their customers. +Upload documents on behalf of interoperability partners and submit them to trading partners through the Avalara platform. ### Example @@ -46,9 +46,9 @@ public class Example { InteropApi apiInstance = new InteropApi(apiClient); String documentType = "ubl-invoice-2.1"; // String | Type of the document being uploaded. Partners will be configured in Avalara system to send only certain types of documents. String interchangeType = "FI-B2B-TIEKE"; // String | Type of interchange (codes in Avalara system that uniquely identifies a type of interchange). Partners will be configured in Avalara system to send documents belonging to certain types of interchanges. - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\" - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). File fileName = new File("/path/to/file"); // File | The file to be uploaded (e.g., UBL XML, CII XML). try { SubmitInteropDocument202Response result = apiInstance.submitInteropDocument(documentType, interchangeType, avalaraVersion, xAvalaraClient, xCorrelationID, fileName); @@ -71,9 +71,9 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **documentType** | **String**| Type of the document being uploaded. Partners will be configured in Avalara system to send only certain types of documents. | [enum: ubl-invoice-2.1, ubl-creditnote-2.1, ubl-applicationresponse-2.1] **interchangeType** | **String**| Type of interchange (codes in Avalara system that uniquely identifies a type of interchange). Partners will be configured in Avalara system to send documents belonging to certain types of interchanges. | [enum: FI-B2B-TIEKE, FI-B2G-TIEKE] - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\" | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] **fileName** | **File**| The file to be uploaded (e.g., UBL XML, CII XML). | [optional] ### Return type @@ -93,9 +93,9 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **202** | Document Accepted. This doesn't mean it is processed. This is just a transport ack. | * X-Correlation-ID -
| -| **400** | Bad/Invalid Request. | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **202** | Document accepted for processing. Returns the interchange ID and acceptance message. This is a transport acknowledgment; processing occurs asynchronously. | * X-Correlation-ID -
| +| **400** | Bad request. The request is invalid or contains missing or incorrect parameters. | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| diff --git a/docs/EInvoicing/V1/Mandate.md b/docs/EInvoicing/V1/Mandate.md index 3a64f89..e9a0a2e 100644 --- a/docs/EInvoicing/V1/Mandate.md +++ b/docs/EInvoicing/V1/Mandate.md @@ -20,6 +20,7 @@ |**inputDataFormats** | [**List<InputDataFormats>**](InputDataFormats.md) | Format and version used when inputting the data | [optional] | |**outputDataFormats** | [**List<OutputDataFormats>**](OutputDataFormats.md) | Lists the supported output document formats for the country mandate. For countries where specifying an output document format is required (e.g., France), this array will contain the applicable formats. For other countries where output format selection is not necessary, the array will be empty. | [optional] | |**workflowIds** | [**List<WorkflowIds>**](WorkflowIds.md) | Workflow ID list | [optional] | +|**supportedDocumentStatuses** | [**List<SupportedDocumentStatuses>**](SupportedDocumentStatuses.md) | List of document statuses defined by the mandate. | [optional] | diff --git a/docs/EInvoicing/V1/MandatesApi.md b/docs/EInvoicing/V1/MandatesApi.md index 221c1c8..f34ed51 100644 --- a/docs/EInvoicing/V1/MandatesApi.md +++ b/docs/EInvoicing/V1/MandatesApi.md @@ -45,11 +45,11 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); MandatesApi apiInstance = new MandatesApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String mandateId = "AD-B2G-PEPPOL"; // String | The unique ID for the mandate that was returned in the GET /einvoicing/mandates response body + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String mandateId = "AD-B2G-PEPPOL"; // String | Unique identifier of the mandate returned by the GET /mandates endpoint. String documentType = "ubl-invoice"; // String | Select the documentType for which you wish to view the data-input-fields (You may obtain the supported documentTypes from the GET /mandates endpoint) String documentVersion = "2.1"; // String | Select the document version of the documentType (You may obtain the supported documentVersion from the GET /mandates endpoint) - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). try { List result = apiInstance.getMandateDataInputFields(avalaraVersion, mandateId, documentType, documentVersion, xAvalaraClient); System.out.println(result); @@ -69,11 +69,11 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **mandateId** | **String**| The unique ID for the mandate that was returned in the GET /einvoicing/mandates response body | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **mandateId** | **String**| Unique identifier of the mandate returned by the GET /mandates endpoint. | **documentType** | **String**| Select the documentType for which you wish to view the data-input-fields (You may obtain the supported documentTypes from the GET /mandates endpoint) | **documentVersion** | **String**| Select the document version of the documentType (You may obtain the supported documentVersion from the GET /mandates endpoint) | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] ### Return type @@ -92,10 +92,10 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | - | -| **400** | Bad Request | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **200** | Returns a MandateDataInputFieldsResponse object containing the input fields and their optionality for the specified mandate, document type, and document version. | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | | **404** | Resource not found | - | | **500** | Internal Server Error | - | @@ -136,13 +136,13 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); MandatesApi apiInstance = new MandatesApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). String $filter = "countryMandate eq DE-B2G-PEPPOL"; // String | Filter by field name and value. This filter only supports eq and contains. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. Integer $top = 56; // Integer | The number of items to include in the result. Integer $skip = 56; // Integer | The number of items to skip in the result. Boolean $count = true; // Boolean | When set to true, the count of the collection is also returned in the response body. - Boolean $countOnly = true; // Boolean | When set to true, only the count of the collection is returned + Boolean $countOnly = true; // Boolean | When set to true, only the count of the collection is returned. try { MandatesResponse result = apiInstance.getMandates(avalaraVersion, xAvalaraClient, $filter, $top, $skip, $count, $countOnly); System.out.println(result); @@ -162,13 +162,13 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] **$filter** | **String**| Filter by field name and value. This filter only supports <code>eq</code> and <code>contains</code>. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] **$skip** | **Integer**| The number of items to skip in the result. | [optional] **$count** | **Boolean**| When set to true, the count of the collection is also returned in the response body. | [optional] - **$countOnly** | **Boolean**| When set to true, only the count of the collection is returned | [optional] + **$countOnly** | **Boolean**| When set to true, only the count of the collection is returned. | [optional] ### Return type @@ -187,9 +187,9 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | - | -| **401** | Unauthorized | - | -| **403** | Forbidden | - | +| **200** | Returns a MandatesResponse object containing the supported country mandates. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | | **404** | Resource not found | - | -| **500** | Internal Server Error | - | +| **500** | Internal server error. | - | diff --git a/docs/EInvoicing/V1/ReportDownloadResponse.md b/docs/EInvoicing/V1/ReportDownloadResponse.md new file mode 100644 index 0000000..933d977 --- /dev/null +++ b/docs/EInvoicing/V1/ReportDownloadResponse.md @@ -0,0 +1,15 @@ + + +# ReportDownloadResponse + +Returns a pre-signed URL to download the report file. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**reportId** | **String** | The unique identifier of the report. | [optional] | +|**downloadUrl** | **URI** | A pre-signed URL to download the report file. This URL is time-limited. | [optional] | + + + diff --git a/docs/EInvoicing/V1/ReportItem.md b/docs/EInvoicing/V1/ReportItem.md new file mode 100644 index 0000000..5de0c1b --- /dev/null +++ b/docs/EInvoicing/V1/ReportItem.md @@ -0,0 +1,32 @@ + + +# ReportItem + +Represents a single report with full details including metadata and associated transaction IDs. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**reportId** | **String** | The unique ID for this report. | [optional] | +|**jobId** | **String** | The unique ID of the job that generated this report. | [optional] | +|**reportGenerateDate** | **OffsetDateTime** | The date and time when the report was generated. | [optional] | +|**reportFrom** | **LocalDate** | The start date of the reporting period. | [optional] | +|**reportTo** | **LocalDate** | The end date of the reporting period. | [optional] | +|**countryCode** | **String** | The two-letter ISO-3166 country code for which this report was generated. | [optional] | +|**countryMandate** | **String** | The e-invoicing mandate for the specified country. | [optional] | +|**documentType** | **String** | The type of document covered by this report. | [optional] | +|**documentSubType** | **String** | The sub-type of the document. | [optional] | +|**reportReference** | **String** | An internal reference path for the report. | [optional] | +|**reportName** | **String** | The name of the report file. | [optional] | +|**status** | **String** | The current status of the report. Possible values include: PENDING, PROCESSING, COMPLETED, FAILED, SENT_TO_PPF, ERROR. | [optional] | +|**reportFormatMimetypes** | **String** | The MIME type of the report file. | [optional] | +|**tenantId** | **String** | The tenant identifier associated with this report. | [optional] | +|**taName** | **String** | The name of the tax authority for this report. | [optional] | +|**taxInvoiceAmount** | **BigDecimal** | The total invoice amount covered by this report. | [optional] | +|**totalTaxAmount** | **BigDecimal** | The total tax amount covered by this report. | [optional] | +|**metadata** | **Object** | Additional report metadata (free-form JSON). Contents vary by country mandate. | [optional] | +|**transactionIds** | **List<String>** | List of transaction IDs associated with this report. | [optional] | + + + diff --git a/docs/EInvoicing/V1/ReportListResponse.md b/docs/EInvoicing/V1/ReportListResponse.md new file mode 100644 index 0000000..34b78f0 --- /dev/null +++ b/docs/EInvoicing/V1/ReportListResponse.md @@ -0,0 +1,16 @@ + + +# ReportListResponse + +Returns the requested list of reports matching the query parameters. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**atRecordsetCount** | **String** | Count of reports matching the filter for the given query. Present when the request includes $count=true. | [optional] | +|**atNextLink** | **String** | URL to retrieve the next page of results when more items match the query. Omitted or null when there is no next page. | [optional] | +|**value** | [**List<ReportItem>**](ReportItem.md) | Array of reports matching the query parameters. | | + + + diff --git a/docs/EInvoicing/V1/ReportsApi.md b/docs/EInvoicing/V1/ReportsApi.md new file mode 100644 index 0000000..3a795be --- /dev/null +++ b/docs/EInvoicing/V1/ReportsApi.md @@ -0,0 +1,283 @@ +# ReportsApi + +All URIs are relative to *https://api.sbx.avalara.com/einvoicing* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**downloadReport**](ReportsApi.md#downloadReport) | **GET** /reports/{reportId}/$download | Returns a pre-signed download URL for a report +[**getReportById**](ReportsApi.md#getReportById) | **GET** /reports/{reportId}/status | Retrieves a report by its unique ID +[**getReports**](ReportsApi.md#getReports) | **GET** /reports | Returns a list of reports + + + +## downloadReport + +> ReportDownloadResponse downloadReport(avalaraVersion, reportId, xAvalaraClient, xCorrelationID) + +Returns a pre-signed download URL for a report + +Returns a pre-signed URL to download the report file when it is available. If the report has not yet been generated, a 404 (not found) is returned. + +### Example + +```java +// Import classes: +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.Configuration; +import Avalara.SDK.auth.*; +import Avalara.SDK.models.*; +import Avalara.SDK.api.EInvoicing.V1.ReportsApi; + +public class Example { + public static void main(String[] args) { + Configuration configuration = new Configuration(); + configuration.setAppName("Test"); + configuration.setAppVersion("1.0"); + configuration.setMachineName("LocalBox"); + configuration.setTimeout(5000); + configuration.setEnvironment(AvaTaxEnvironment.Sandbox); + // Configure HTTP basic authorization + configuration.setUsername("YOUR USERNAME"); + configuration.setPassword("YOUR PASSWORD"); + // Configure OAuth2 access token for authorization + configuration.setBearerToken("YOUR ACCESS TOKEN"); + + ApiClient apiClient = new ApiClient(configuration); + + ReportsApi apiInstance = new ReportsApi(apiClient); + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String reportId = "reportId_example"; // String | The unique ID for this report as returned in a GET /reports response. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). + try { + ReportDownloadResponse result = apiInstance.downloadReport(avalaraVersion, reportId, xAvalaraClient, xCorrelationID); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ReportsApi#downloadReport"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **reportId** | **String**| The unique ID for this report as returned in a GET /reports response. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] + +### Return type + +[**ReportDownloadResponse**](ReportDownloadResponse.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** | Returns a pre-signed URL to download the report. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | +| **404** | Report not found or not yet available for download. | - | + + +## getReportById + +> ReportItem getReportById(avalaraVersion, reportId, xAvalaraClient, xCorrelationID) + +Retrieves a report by its unique ID + +Retrieves a specific report by its unique identifier. Returns complete report details including metadata, status, and associated information. + +### Example + +```java +// Import classes: +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.Configuration; +import Avalara.SDK.auth.*; +import Avalara.SDK.models.*; +import Avalara.SDK.api.EInvoicing.V1.ReportsApi; + +public class Example { + public static void main(String[] args) { + Configuration configuration = new Configuration(); + configuration.setAppName("Test"); + configuration.setAppVersion("1.0"); + configuration.setMachineName("LocalBox"); + configuration.setTimeout(5000); + configuration.setEnvironment(AvaTaxEnvironment.Sandbox); + // Configure HTTP basic authorization + configuration.setUsername("YOUR USERNAME"); + configuration.setPassword("YOUR PASSWORD"); + // Configure OAuth2 access token for authorization + configuration.setBearerToken("YOUR ACCESS TOKEN"); + + ApiClient apiClient = new ApiClient(configuration); + + ReportsApi apiInstance = new ReportsApi(apiClient); + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String reportId = "reportId_example"; // String | The unique ID for this report as returned in a GET /reports response. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). + try { + ReportItem result = apiInstance.getReportById(avalaraVersion, reportId, xAvalaraClient, xCorrelationID); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ReportsApi#getReportById"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **reportId** | **String**| The unique ID for this report as returned in a GET /reports response. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] + +### Return type + +[**ReportItem**](ReportItem.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** | Report found and returned successfully. | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | +| **404** | Report not found. | - | + + +## getReports + +> ReportListResponse getReports(avalaraVersion, xAvalaraClient, xCorrelationID, $filter, $top, $skip, $count, $countOnly, $orderby) + +Returns a list of reports + +Retrieves all reports with optional filtering, paging, and sorting. Results are filtered by tenant. Supports OData-style filtering using the $filter parameter. Use $top and $skip for paging; when more results exist, the response includes @nextLink to fetch the next page. Default sort order is by report generation date (descending). + +### Example + +```java +// Import classes: +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.Configuration; +import Avalara.SDK.auth.*; +import Avalara.SDK.models.*; +import Avalara.SDK.api.EInvoicing.V1.ReportsApi; + +public class Example { + public static void main(String[] args) { + Configuration configuration = new Configuration(); + configuration.setAppName("Test"); + configuration.setAppVersion("1.0"); + configuration.setMachineName("LocalBox"); + configuration.setTimeout(5000); + configuration.setEnvironment(AvaTaxEnvironment.Sandbox); + // Configure HTTP basic authorization + configuration.setUsername("YOUR USERNAME"); + configuration.setPassword("YOUR PASSWORD"); + // Configure OAuth2 access token for authorization + configuration.setBearerToken("YOUR ACCESS TOKEN"); + + ApiClient apiClient = new ApiClient(configuration); + + ReportsApi apiInstance = new ReportsApi(apiClient); + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). + String $filter = "status eq 'COMPLETED'"; // String | OData-style filter expression. Supports operators: eq, ne, gt, ge, lt, le, like, ilike, contains. Examples: status eq 'COMPLETED', reportGenerateDate gt '2025-11-01', transactionIds contains 'TXN-2025-001' + Integer $top = 56; // Integer | The number of items to include in the result. + Integer $skip = 56; // Integer | The number of items to skip in the result. + String $count = "true"; // String | When set to true, the response body also includes the count of items in the collection. + String $countOnly = "false"; // String | When set to true, the response returns only the count of items in the collection. + String $orderby = "reportGenerateDate desc"; // String | OData-style orderby expression. Format: 'field asc' or 'field desc'. Default: reportGenerateDate desc + try { + ReportListResponse result = apiInstance.getReports(avalaraVersion, xAvalaraClient, xCorrelationID, $filter, $top, $skip, $count, $countOnly, $orderby); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling ReportsApi#getReports"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] + **$filter** | **String**| OData-style filter expression. Supports operators: eq, ne, gt, ge, lt, le, like, ilike, contains. Examples: status eq 'COMPLETED', reportGenerateDate gt '2025-11-01', transactionIds contains 'TXN-2025-001' | [optional] + **$top** | **Integer**| The number of items to include in the result. | [optional] + **$skip** | **Integer**| The number of items to skip in the result. | [optional] + **$count** | **String**| When set to true, the response body also includes the count of items in the collection. | [optional] + **$countOnly** | **String**| When set to true, the response returns only the count of items in the collection. | [optional] + **$orderby** | **String**| OData-style orderby expression. Format: 'field asc' or 'field desc'. Default: reportGenerateDate desc | [optional] [default to reportGenerateDate desc] + +### Return type + +[**ReportListResponse**](ReportListResponse.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** | Reports retrieved successfully. | - | +| **400** | Bad request. | - | +| **401** | Unauthorized. | - | +| **403** | Forbidden. | - | + diff --git a/docs/EInvoicing/V1/StatusEvent.md b/docs/EInvoicing/V1/StatusEvent.md index c22217e..261e4f0 100644 --- a/docs/EInvoicing/V1/StatusEvent.md +++ b/docs/EInvoicing/V1/StatusEvent.md @@ -8,10 +8,11 @@ Displays when a status event occurred | Name | Type | Description | Notes | |------------ | ------------- | ------------- | -------------| -|**eventDateTime** | **String** | The date and time when the status event occured, displayed in the format YYYY-MM-DDThh:mm:ss | [optional] | +|**eventDateTime** | **String** | The date and time when the status event occurred, displayed in the format YYYY-MM-DDThh:mm:ss | [optional] | |**message** | **String** | A message describing the status event | [optional] | |**responseKey** | **String** | The type of number or acknowledgement returned by the tax authority (if applicable). For example, it could be an identification key, acknowledgement code, or any other relevant identifier. | [optional] | |**responseValue** | **String** | The corresponding value associated with the response key. This value is provided by the tax authority in response to the event. | [optional] | +|**category** | **String** | Represents the functional area or process stage where the status event occurred. Useful for grouping related events such as document processing, transmission, or validation. | [optional] | diff --git a/docs/EInvoicing/V1/SubscriptionsApi.md b/docs/EInvoicing/V1/SubscriptionsApi.md index c3994b1..384ec14 100644 --- a/docs/EInvoicing/V1/SubscriptionsApi.md +++ b/docs/EInvoicing/V1/SubscriptionsApi.md @@ -5,8 +5,8 @@ All URIs are relative to *https://api.sbx.avalara.com/einvoicing* Method | HTTP request | Description ------------- | ------------- | ------------- [**createWebhookSubscription**](SubscriptionsApi.md#createWebhookSubscription) | **POST** /webhooks/subscriptions | Create a subscription to events -[**deleteWebhookSubscription**](SubscriptionsApi.md#deleteWebhookSubscription) | **DELETE** /webhooks/subscriptions/{subscription-id} | Unsubscribe from events -[**getWebhookSubscription**](SubscriptionsApi.md#getWebhookSubscription) | **GET** /webhooks/subscriptions/{subscription-id} | Get details of a subscription +[**deleteWebhookSubscription**](SubscriptionsApi.md#deleteWebhookSubscription) | **DELETE** /webhooks/subscriptions/{subscriptionId} | Unsubscribe from events +[**getWebhookSubscription**](SubscriptionsApi.md#getWebhookSubscription) | **GET** /webhooks/subscriptions/{subscriptionId} | Get details of a subscription [**listWebhookSubscriptions**](SubscriptionsApi.md#listWebhookSubscriptions) | **GET** /webhooks/subscriptions | List all subscriptions @@ -17,7 +17,7 @@ Method | HTTP request | Description Create a subscription to events -Create a subscription to events exposed by registered systems. +Create a new webhook subscription and return the created subscription details. ### Example @@ -47,7 +47,7 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); SubscriptionsApi apiInstance = new SubscriptionsApi(apiClient); - String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.4\". + String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.6\". SubscriptionRegistration subscriptionRegistration = new SubscriptionRegistration(); // SubscriptionRegistration | String xCorrelationID = "xCorrelationID_example"; // String | A unique identifier for tracking the request and its response String xAvalaraClient = "xAvalaraClient_example"; // String | Client application identification @@ -70,7 +70,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.4\". | + **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.6\". | **subscriptionRegistration** | [**SubscriptionRegistration**](SubscriptionRegistration.md)| | **xCorrelationID** | **String**| A unique identifier for tracking the request and its response | [optional] **xAvalaraClient** | **String**| Client application identification | [optional] @@ -92,10 +92,10 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **201** | Subscribed successfully | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **400** | Invalid input | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **401** | Not authenticated | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **403** | Access token does not have the required scope | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **201** | Subscription created successfully. Returns the created SubscriptionDetail object. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **400** | Bad request. The request payload is invalid or contains missing required fields. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **401** | Unauthorized. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **403** | Forbidden. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| ## deleteWebhookSubscription @@ -104,7 +104,7 @@ Name | Type | Description | Notes Unsubscribe from events -Remove a subscription from the webhooks dispatch service. All events and subscriptions are also deleted. +Delete the specified webhook subscription. ### Example @@ -134,8 +134,8 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); SubscriptionsApi apiInstance = new SubscriptionsApi(apiClient); - String subscriptionId = "subscriptionId_example"; // String | - String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.4\". + String subscriptionId = "subscriptionId_example"; // String | Unique identifier of the subscription. + String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.6\". String xCorrelationID = "xCorrelationID_example"; // String | A unique identifier for tracking the request and its response String xAvalaraClient = "xAvalaraClient_example"; // String | Client application identification try { @@ -156,8 +156,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **subscriptionId** | **String**| | - **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.4\". | + **subscriptionId** | **String**| Unique identifier of the subscription. | + **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.6\". | **xCorrelationID** | **String**| A unique identifier for tracking the request and its response | [optional] **xAvalaraClient** | **String**| Client application identification | [optional] @@ -178,10 +178,10 @@ null (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **204** | Unsubscribed successfully | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **401** | Not authenticated | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **403** | Access token does not have the required scope | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **404** | Subscription not found | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **204** | Subscription deleted successfully. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **401** | Unauthorized. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **403** | Forbidden. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **404** | Subscription not found for the specified subscriptionId. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| ## getWebhookSubscription @@ -220,8 +220,8 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); SubscriptionsApi apiInstance = new SubscriptionsApi(apiClient); - String subscriptionId = "subscriptionId_example"; // String | - String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.4\". + String subscriptionId = "subscriptionId_example"; // String | Unique identifier of the subscription. + String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.6\". String xCorrelationID = "xCorrelationID_example"; // String | A unique identifier for tracking the request and its response String xAvalaraClient = "xAvalaraClient_example"; // String | Client application identification try { @@ -243,8 +243,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **subscriptionId** | **String**| | - **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.4\". | + **subscriptionId** | **String**| Unique identifier of the subscription. | + **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.6\". | **xCorrelationID** | **String**| A unique identifier for tracking the request and its response | [optional] **xAvalaraClient** | **String**| Client application identification | [optional] @@ -265,10 +265,10 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | Subscription details retrieved successfully | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **401** | Not authenticated | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **403** | Access token does not have the required scope | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **404** | Subscription not found | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **200** | Returns the SubscriptionDetail object for the specified subscriptionId. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **401** | Unauthorized. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **403** | Forbidden. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **404** | Subscription not found for the specified subscriptionId. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| ## listWebhookSubscriptions @@ -277,7 +277,7 @@ Name | Type | Description | Notes List all subscriptions -Retrieve a list of all subscriptions. +Retrieve a list of webhook subscriptions. ### Example @@ -307,7 +307,7 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); SubscriptionsApi apiInstance = new SubscriptionsApi(apiClient); - String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.4\". + String avalaraVersion = "avalaraVersion_example"; // String | The version of the API to use, e.g., \"1.6\". String xCorrelationID = "xCorrelationID_example"; // String | A unique identifier for tracking the request and its response String xAvalaraClient = "xAvalaraClient_example"; // String | Client application identification Integer $top = 56; // Integer | The number of items to include in the result. @@ -333,7 +333,7 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.4\". | + **avalaraVersion** | **String**| The version of the API to use, e.g., \"1.6\". | **xCorrelationID** | **String**| A unique identifier for tracking the request and its response | [optional] **xAvalaraClient** | **String**| Client application identification | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] @@ -358,8 +358,8 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | A list of subscriptions | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **401** | Not authenticated | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **403** | Access token does not have the required scope | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| -| **500** | Internal server error | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **200** | Returns a list of webhook subscriptions in a SubscriptionListResponse object. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **401** | Unauthorized. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **403** | Forbidden. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| +| **500** | Internal server error. | * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
| diff --git a/docs/EInvoicing/V1/SupportedDocumentStatuses.md b/docs/EInvoicing/V1/SupportedDocumentStatuses.md new file mode 100644 index 0000000..84c0886 --- /dev/null +++ b/docs/EInvoicing/V1/SupportedDocumentStatuses.md @@ -0,0 +1,15 @@ + + +# SupportedDocumentStatuses + +Represents a document status defined by the mandate. + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +|**status** | **String** | The name of the status (e.g., Approved, Fully Paid). | [optional] | +|**description** | **String** | Explanation of what the status means. | [optional] | + + + diff --git a/docs/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.md b/docs/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.md index 4eb793b..e4242ab 100644 --- a/docs/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.md +++ b/docs/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.md @@ -8,6 +8,7 @@ | Name | Type | Description | Notes | |------------ | ------------- | ------------- | -------------| |**countryCode** | **String** | The two-letter ISO-3166 country code of the tax identifier. | | +|**schemaType** | **String** | The type of schema returned: \"request\" or \"response\". | | |**schema** | **Object** | The JSON Schema definition, following Draft-07 specification, used to validate tax identifier data. | | diff --git a/docs/EInvoicing/V1/TaxIdentifiersApi.md b/docs/EInvoicing/V1/TaxIdentifiersApi.md index 2047db3..edb8a59 100644 --- a/docs/EInvoicing/V1/TaxIdentifiersApi.md +++ b/docs/EInvoicing/V1/TaxIdentifiersApi.md @@ -4,7 +4,7 @@ All URIs are relative to *https://api.sbx.avalara.com/einvoicing* Method | HTTP request | Description ------------- | ------------- | ------------- -[**taxIdentifierSchemaByCountry**](TaxIdentifiersApi.md#taxIdentifierSchemaByCountry) | **GET** /tax-identifiers/schema | Returns the tax identifier request & response schema for a specific country. +[**taxIdentifierSchemaByCountry**](TaxIdentifiersApi.md#taxIdentifierSchemaByCountry) | **GET** /tax-identifiers/schema | Returns the tax identifier request and response schema for a specific country. [**validateTaxIdentifier**](TaxIdentifiersApi.md#validateTaxIdentifier) | **POST** /tax-identifiers/validate | Validates a tax identifier. @@ -13,9 +13,9 @@ Method | HTTP request | Description > TaxIdentifierSchemaByCountry200Response taxIdentifierSchemaByCountry(avalaraVersion, countryCode, xAvalaraClient, xCorrelationID, type) -Returns the tax identifier request & response schema for a specific country. +Returns the tax identifier request and response schema for a specific country. -This endpoint retrieves the request and response schema required to validate tax identifiers based on a specific country's requirements. This can include both standard fields and any additional parameters required by the respective country's tax authority. +Returns the tax identifier request and response schema for a specific country. ### Example @@ -45,11 +45,11 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TaxIdentifiersApi apiInstance = new TaxIdentifiersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String countryCode = "DE"; // String | The two-letter ISO-3166 country code for which the schema should be retrieved. - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. - String type = "request"; // String | Specifies whether to return the request or response schema. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String countryCode = "DE"; // String | Two-letter ISO 3166 country code for which to retrieve the schema (for example \"DE\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). + String type = "request"; // String | Specifies which schema to return: \"request\" to receive the request validation schema or \"response\" to receive the response validation schema. try { TaxIdentifierSchemaByCountry200Response result = apiInstance.taxIdentifierSchemaByCountry(avalaraVersion, countryCode, xAvalaraClient, xCorrelationID, type); System.out.println(result); @@ -69,11 +69,11 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **countryCode** | **String**| The two-letter ISO-3166 country code for which the schema should be retrieved. | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] - **type** | **String**| Specifies whether to return the request or response schema. | [optional] [enum: request, response] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **countryCode** | **String**| Two-letter ISO 3166 country code for which to retrieve the schema (for example \"DE\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] + **type** | **String**| Specifies which schema to return: \"request\" to receive the request validation schema or \"response\" to receive the response validation schema. | [optional] [enum: request, response] ### Return type @@ -92,11 +92,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | * X-Correlation-Id -
| -| **400** | Invalid request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Returns an object containing countryCode, schemaType, and schema. The schema property contains a JSON Schema (Draft-07) used to validate tax identifier requests or responses for the specified country. | * X-Correlation-ID -
| +| **400** | Invalid request | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## validateTaxIdentifier @@ -135,10 +135,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TaxIdentifiersApi apiInstance = new TaxIdentifiersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). TaxIdentifierRequest taxIdentifierRequest = new TaxIdentifierRequest(); // TaxIdentifierRequest | - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { TaxIdentifierResponse result = apiInstance.validateTaxIdentifier(avalaraVersion, taxIdentifierRequest, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -158,10 +158,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | **taxIdentifierRequest** | [**TaxIdentifierRequest**](TaxIdentifierRequest.md)| | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -180,10 +180,10 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | Success response. | * X-Correlation-Id -
| -| **400** | Invalid request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **429** | Rate limit exceeded | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Validation completed. Returns a TaxIdentifierResponse object that includes countryCode and a value object with identifierType, identifier, and optional extensions when available. | * X-Correlation-ID -
| +| **400** | Bad request. The request is invalid or contains missing or incorrect parameters. | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **429** | Rate limit exceeded. | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| diff --git a/docs/EInvoicing/V1/TradingPartnersApi.md b/docs/EInvoicing/V1/TradingPartnersApi.md index be68e20..6e18f5c 100644 --- a/docs/EInvoicing/V1/TradingPartnersApi.md +++ b/docs/EInvoicing/V1/TradingPartnersApi.md @@ -52,12 +52,12 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String name = "Automotive Companies in London Search"; // String | A human-readable name for the batch search. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String name = "Automotive Companies in London Search"; // String | A human-readable name for the batch search. String notificationEmail = "user@example.com"; // String | The email address to which a notification will be sent once the batch search is complete. File _file = new File("/path/to/file"); // File | CSV file containing search parameters. Input Constraints: - Maximum file size: 1 MB - File Header: Must be less than 500 KB - Total number of lines (including header): Must be 101 or fewer - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { BatchSearchParticipants202Response result = apiInstance.batchSearchParticipants(avalaraVersion, name, notificationEmail, _file, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -77,12 +77,12 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **name** | **String**| A <b>human-readable</b> name for the batch search. | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **name** | **String**| A human-readable name for the batch search. | **notificationEmail** | **String**| The email address to which a notification will be sent once the batch search is complete. | **_file** | **File**| CSV file containing search parameters. Input Constraints: - Maximum file size: 1 MB - File Header: Must be less than 500 KB - Total number of lines (including header): Must be 101 or fewer | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -101,11 +101,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **202** | Batch search file accepted for processing the search. | * X-Correlation-Id -
| -| **400** | Invalid request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **202** | Batch search file accepted for processing the search. | * X-Correlation-ID -
| +| **400** | Invalid request | * X-Correlation-ID -
| +| **401** | Unauthorized | * X-Correlation-ID -
| +| **403** | Forbidden | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## createTradingPartner @@ -144,10 +144,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). TradingPartner tradingPartner = new TradingPartner(); // TradingPartner | - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { CreateTradingPartner201Response result = apiInstance.createTradingPartner(avalaraVersion, tradingPartner, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -167,10 +167,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | **tradingPartner** | [**TradingPartner**](TradingPartner.md)| | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -189,12 +189,12 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **201** | The trading partner has been successfully created. | * X-Correlation-Id -
| -| **400** | Bad request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **409** | Conflict | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **201** | The trading partner has been successfully created. | * X-Correlation-ID -
| +| **400** | Bad request | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **409** | Conflict | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## createTradingPartnersBatch @@ -203,7 +203,7 @@ Name | Type | Description | Notes Creates a batch of multiple trading partners. -This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or 1 MB request payload. The batch is processed atomically and partial success is not allowed. +This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or a 1 MB request payload. ### Example @@ -233,10 +233,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). CreateTradingPartnersBatchRequest createTradingPartnersBatchRequest = new CreateTradingPartnersBatchRequest(); // CreateTradingPartnersBatchRequest | - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { CreateTradingPartnersBatch200Response result = apiInstance.createTradingPartnersBatch(avalaraVersion, createTradingPartnersBatchRequest, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -256,10 +256,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | **createTradingPartnersBatchRequest** | [**CreateTradingPartnersBatchRequest**](CreateTradingPartnersBatchRequest.md)| | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -278,13 +278,13 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | Batch processing completed | * X-Correlation-Id -
| -| **400** | Bad request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **409** | Conflict | * X-Correlation-Id -
| -| **413** | ContentTooLarge | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Batch processing completed. Returns a list of created trading partners. | * X-Correlation-ID -
| +| **400** | Bad request | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **409** | Conflict | * X-Correlation-ID -
| +| **413** | ContentTooLarge | * X-Correlation-ID -
| +| **500** | Internal server error | * X-Correlation-ID -
| ## deleteTradingPartner @@ -323,10 +323,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String id = "id_example"; // String | The ID of the trading partner which is being deleted. - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String id = "id_example"; // String | Unique identifier of the trading partner. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { apiInstance.deleteTradingPartner(avalaraVersion, id, xAvalaraClient, xCorrelationID); } catch (ApiException e) { @@ -345,10 +345,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **id** | **String**| The ID of the trading partner which is being deleted. | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **id** | **String**| Unique identifier of the trading partner. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -367,11 +367,11 @@ null (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **204** | Trading partner deleted successfully. | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **404** | NotFound | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **204** | Trading partner deleted successfully. | * X-Correlation-ID -
| +| **401** | Unauthorized | * X-Correlation-ID -
| +| **403** | Forbidden | * X-Correlation-ID -
| +| **404** | NotFound | * X-Correlation-ID -
| +| **500** | Internal server error | * X-Correlation-ID -
| ## downloadBatchSearchReport @@ -410,10 +410,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String id = "2f5ea4b5-4dae-445a-b3e4-9f65a61eaa99"; // String | The ID of the batch search for which the report should be downloaded. - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String id = "2f5ea4b5-4dae-445a-b3e4-9f65a61eaa99"; // String | Unique identifier of the batch search for which to download the report. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { File result = apiInstance.downloadBatchSearchReport(avalaraVersion, id, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -433,10 +433,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **id** | **String**| The ID of the batch search for which the report should be downloaded. | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **id** | **String**| Unique identifier of the batch search for which to download the report. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -455,11 +455,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | Successful report download Output Constraints: - Maximum of 1000 query results returned in the CSV | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **404** | Report not found | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Successful report download. Returns a CSV file containing up to 1,000 query results. | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **404** | Report not found | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## getBatchSearchDetail @@ -498,10 +498,10 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String id = "2f5ea4b5-4dae-445a-b3e4-9f65a61eaa99"; // String | The ID of the batch search that was submitted earlier. - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String id = "2f5ea4b5-4dae-445a-b3e4-9f65a61eaa99"; // String | Unique identifier of the batch search. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { BatchSearch result = apiInstance.getBatchSearchDetail(avalaraVersion, id, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -521,10 +521,10 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **id** | **String**| The ID of the batch search that was submitted earlier. | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **id** | **String**| Unique identifier of the batch search. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -543,11 +543,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | The batch search details for a given ID. | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **404** | Report not found | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Returns the batch search details for the specified ID. | * X-Correlation-ID -
| +| **401** | Unauthorized | * X-Correlation-ID -
| +| **403** | Forbidden | * X-Correlation-ID -
| +| **404** | Report not found | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## listBatchSearches @@ -586,14 +586,14 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String $filter = "name eq 'Batch_Search_Import_V4'"; // String | Filters the results by field name. Only the eq operator and the name field is supported. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String $filter = "name eq 'Batch_Search_Import_V4'"; // String | Filters the results by field name. Only the eq operator and the name field are supported. For more information, refer to the Avalara filtering guide. Boolean count = true; // Boolean | When set to true, returns the total count of matching records included as @recordSetCount in the response body. Integer $top = 56; // Integer | The number of items to include in the result. Integer $skip = 56; // Integer | The number of items to skip in the result. String $orderBy = "name desc"; // String | The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { BatchSearchListResponse result = apiInstance.listBatchSearches(avalaraVersion, xAvalaraClient, $filter, count, $top, $skip, $orderBy, xCorrelationID); System.out.println(result); @@ -613,14 +613,14 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **$filter** | **String**| Filters the results by field name. Only the <code>eq</code> operator and the name field is supported. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **$filter** | **String**| Filters the results by field name. Only the eq operator and the name field are supported. For more information, refer to the Avalara filtering guide. | [optional] **count** | **Boolean**| When set to <code>true</code>, returns the total count of matching records included as <code>@recordSetCount</code> in the response body. | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] **$skip** | **Integer**| The number of items to skip in the result. | [optional] **$orderBy** | **String**| The <code>$orderBy</code> query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -639,11 +639,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | List of batch searches | * X-Correlation-Id -
| -| **400** | Bad request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Returns a collection of batch searches. | * X-Correlation-ID -
| +| **400** | Bad request | * X-Correlation-ID -
| +| **401** | Unauthorized | * X-Correlation-ID -
| +| **403** | Forbidden | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## searchParticipants @@ -682,15 +682,15 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String $search = "Acme and 7726627177 or BMW"; // String | Search by value supports logical AND / OR operators. Search is performed only over the name and identifier value fields. For more information, refer to [Query options overview - OData.](https://learn.microsoft.com/en-us/odata/concepts/queryoptions-overview#search). - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - Boolean count = true; // Boolean | When set to true, returns the total count of matching records included as @recordSetCount in the response body. - String $filter = "network eq 'Peppol' and country eq 'Australia'"; // String | Filters the results using the eq operator. Supported fields: network, country, documentType, idType. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String $search = "Acme AND 7726627177 OR BMW"; // String | Search by value supports logical AND and OR operators (case-sensitive). Search is performed only over the name and identifier value fields. For more information, refer to the OData query options overview documentation. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + Boolean count = true; // Boolean | When set to true, returns the total count of matching records included as @recordSetCount in the response body. + String $filter = "network eq 'Peppol' and country eq 'Australia'"; // String | Filters the results using the eq operator. Supported fields include network, country, documentType, and idType. For more information, refer to the Avalara filtering guide. Integer $top = 56; // Integer | The number of items to include in the result. Integer $skip = 56; // Integer | The number of items to skip in the result. - String $orderBy = "name desc"; // String | The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String $orderBy = "name desc"; // String | The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { SearchParticipants200Response result = apiInstance.searchParticipants(avalaraVersion, $search, xAvalaraClient, count, $filter, $top, $skip, $orderBy, xCorrelationID); System.out.println(result); @@ -710,15 +710,15 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **$search** | **String**| Search by value supports logical <code>AND</code> / <code>OR</code> operators. Search is performed only over the name and identifier value fields. For more information, refer to [Query options overview - OData.](https://learn.microsoft.com/en-us/odata/concepts/queryoptions-overview#search). | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **count** | **Boolean**| When set to <code>true</code>, returns the total count of matching records included as <code>@recordSetCount</code> in the response body. | [optional] - **$filter** | **String**| Filters the results using the <code>eq</code> operator. Supported fields: <code>network</code>, <code>country</code>, <code>documentType</code>, <code>idType</code>. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). | [optional] + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **$search** | **String**| Search by value supports logical AND and OR operators (case-sensitive). Search is performed only over the name and identifier value fields. For more information, refer to the OData query options overview documentation. | + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **count** | **Boolean**| When set to true, returns the total count of matching records included as @recordSetCount in the response body. | [optional] + **$filter** | **String**| Filters the results using the eq operator. Supported fields include network, country, documentType, and idType. For more information, refer to the Avalara filtering guide. | [optional] **$top** | **Integer**| The number of items to include in the result. | [optional] **$skip** | **Integer**| The number of items to skip in the result. | [optional] - **$orderBy** | **String**| The <code>$orderBy</code> query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **$orderBy** | **String**| The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -737,11 +737,11 @@ Name | Type | Description | Notes ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | OK | * X-Correlation-Id -
| -| **400** | Bad request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **200** | Returns a collection of trading partners matching the specified search criteria. | * X-Correlation-ID -
| +| **400** | Bad request. | * X-Correlation-ID -
| +| **401** | Unauthorized. | * X-Correlation-ID -
| +| **403** | Forbidden. | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| ## updateTradingPartner @@ -780,11 +780,11 @@ public class Example { ApiClient apiClient = new ApiClient(configuration); TradingPartnersApi apiInstance = new TradingPartnersApi(apiClient); - String avalaraVersion = "1.4"; // String | The HTTP Header meant to specify the version of the API intended to be used. - String id = "id_example"; // String | The ID of the trading partner which is being updated. + String avalaraVersion = "1.6"; // String | Header that specifies the API version to use (for example \"1.6\"). + String id = "id_example"; // String | Unique identifier of the trading partner. TradingPartner tradingPartner = new TradingPartner(); // TradingPartner | - String xAvalaraClient = "John's E-Invoicing-API Client"; // String | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". - String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | The caller can use this as an identifier to use as a correlation id to trace the call. + String xAvalaraClient = "John's E-Invoicing-API Client"; // String | Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). + String xCorrelationID = "f3f0d19a-01a1-4748-8a58-f000d0424f43"; // String | Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). try { UpdateTradingPartner200Response result = apiInstance.updateTradingPartner(avalaraVersion, id, tradingPartner, xAvalaraClient, xCorrelationID); System.out.println(result); @@ -804,11 +804,11 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **avalaraVersion** | **String**| The HTTP Header meant to specify the version of the API intended to be used. | - **id** | **String**| The ID of the trading partner which is being updated. | + **avalaraVersion** | **String**| Header that specifies the API version to use (for example \"1.6\"). | + **id** | **String**| Unique identifier of the trading partner. | **tradingPartner** | [**TradingPartner**](TradingPartner.md)| | - **xAvalaraClient** | **String**| You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". | [optional] - **xCorrelationID** | **String**| The caller can use this as an identifier to use as a correlation id to trace the call. | [optional] + **xAvalaraClient** | **String**| Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). | [optional] + **xCorrelationID** | **String**| Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). | [optional] ### Return type @@ -828,10 +828,10 @@ Name | Type | Description | Notes | Status code | Description | Response headers | |-------------|-------------|------------------| | **200** | The trading partner has been successfully created. | - | -| **400** | Bad request | * X-Correlation-Id -
| -| **401** | Unauthorized | * X-Correlation-Id -
| -| **403** | Forbidden | * X-Correlation-Id -
| -| **404** | NotFound | * X-Correlation-Id -
| -| **409** | Conflict | * X-Correlation-Id -
| -| **500** | Internal server error | * X-Correlation-Id -
| +| **400** | Bad request | * X-Correlation-ID -
| +| **401** | Unauthorized | * X-Correlation-ID -
| +| **403** | Forbidden | * X-Correlation-ID -
| +| **404** | NotFound | * X-Correlation-ID -
| +| **409** | Conflict | * X-Correlation-ID -
| +| **500** | Internal server error. | * X-Correlation-ID -
| diff --git a/pom.xml b/pom.xml index 69c5d7e..24c35bb 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ avalara-sdk jar avalara-sdk - 25.11.2 + 26.4.0 https://github.com/avadev/Avalara-SDK-Java OpenAPI Java @@ -17,7 +17,7 @@ Unlicense - https://www.apache.org/licenses/LICENSE-2.0.html + http://unlicense.org repo diff --git a/src/main/java/Avalara/SDK/JSON.java b/src/main/java/Avalara/SDK/JSON.java index cf7e5bb..5f045e9 100644 --- a/src/main/java/Avalara/SDK/JSON.java +++ b/src/main/java/Avalara/SDK/JSON.java @@ -13,8 +13,8 @@ import java.time.LocalDate; import java.time.OffsetDateTime; import java.time.format.DateTimeFormatter; -import Avalara.SDK.model.A1099.V2.*; -import Avalara.SDK.model.EInvoicing.V1.*; +import Avalara.SDK.model.EInvoicing.V1*; +import Avalara.SDK.model.A1099.V2*; import okio.ByteString; diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/CodeListsApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/CodeListsApi.java new file mode 100644 index 0000000..529b9fe --- /dev/null +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/CodeListsApi.java @@ -0,0 +1,543 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.api.EInvoicing.V1; + +import Avalara.SDK.ApiCallback; +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.ApiResponse; +import Avalara.SDK.Configuration; +import Avalara.SDK.Pair; +import Avalara.SDK.ProgressRequestBody; +import Avalara.SDK.ProgressResponseBody; +import Avalara.SDK.AvalaraMicroservice; + + +import com.google.gson.reflect.TypeToken; + +import java.io.IOException; +import java.util.*; + + +import Avalara.SDK.model.EInvoicing.V1.BadRequest; +import Avalara.SDK.model.EInvoicing.V1.CodeListListResponse; +import Avalara.SDK.model.EInvoicing.V1.CodeListResponse; +import Avalara.SDK.model.EInvoicing.V1.ForbiddenError; +import java.time.LocalDate; +import Avalara.SDK.model.EInvoicing.V1.NotFoundError; + +import java.lang.reflect.Type; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CodeListsApi { + private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; + + public CodeListsApi(ApiClient apiClient) { + this.localVarApiClient = apiClient; + SetConfiguration(apiClient); + } + + public ApiClient getApiClient() { + return localVarApiClient; + } + + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + + /** + * Build call for getCodeList + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Code list not found. -
+ */ + public okhttp3.Call getCodeListCall(GetCodeListRequest requestParameters, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + //OAuth2 Scopes + String requiredScopes = ""; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/einvoicing/codelists/{codelistId}" + .replaceAll("\\{" + "codelistId" + "\\}", localVarApiClient.escapeString(requestParameters.codelistId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (requestParameters.getCountryCode() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("countryCode", requestParameters.getCountryCode())); + } + + if (requestParameters.getEffectiveDate() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("effectiveDate", requestParameters.getEffectiveDate())); + } + + if (requestParameters.getSunsetDate() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sunsetDate", requestParameters.getSunsetDate())); + } + + if (requestParameters.getAvalaraVersion() != null) { + localVarHeaderParams.put("avalara-version", localVarApiClient.parameterToString(requestParameters.getAvalaraVersion())); + } + + if (requestParameters.getXAvalaraClient() != null) { + localVarHeaderParams.put("X-Avalara-Client", localVarApiClient.parameterToString(requestParameters.getXAvalaraClient())); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null && !localVarHeaderParams.containsKey("Accept")) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + String[] localVarAuthNames = new String[] { "OAuth", "Bearer" }; + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, requiredScopes, AvalaraMicroservice.EInvoicing); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getCodeListValidateBeforeCall(GetCodeListRequest requestParameters, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'requestParameters.avalaraVersion' is set + if (requestParameters.getAvalaraVersion() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.avalaraVersion' when calling getCodeList(Async)"); + } + + // verify the required parameter 'requestParameters.codelistId' is set + if (requestParameters.getCodelistId() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.codelistId' when calling getCodeList(Async)"); + } + + // verify the required parameter 'requestParameters.countryCode' is set + if (requestParameters.getCountryCode() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.countryCode' when calling getCodeList(Async)"); + } + + + okhttp3.Call localVarCall = getCodeListCall(requestParameters, _callback); + return localVarCall; + + } + + /** + * Retrieves a code list by ID for a specific country + * A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions.<br><br>Code Lists are versioned, and each version may have defined effective and sunset dates to ensure that the correct set of allowable values is applied according to regulatory or jurisdictional requirements.<br><br>By default, the API returns only non-expired code list versions (versions where the sunset date has not passed). To retrieve expired versions or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters. + * @param requestOptions Object which represents the options available for a given API/request + * @return CodeListResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Code list not found. -
+ */ + public CodeListResponse getCodeList(GetCodeListRequest requestParameters) throws ApiException { + ApiResponse localVarResp = getCodeListWithHttpInfo(requestParameters); + return localVarResp.getData(); + } + + /** + * Retrieves a code list by ID for a specific country + * A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions.<br><br>Code Lists are versioned, and each version may have defined effective and sunset dates to ensure that the correct set of allowable values is applied according to regulatory or jurisdictional requirements.<br><br>By default, the API returns only non-expired code list versions (versions where the sunset date has not passed). To retrieve expired versions or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters. + * @param requestOptions Object which represents the options available for a given API/request + * @return ApiResponse<CodeListResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Code list not found. -
+ */ + public ApiResponse getCodeListWithHttpInfo(GetCodeListRequest requestParameters) throws ApiException { + okhttp3.Call localVarCall = getCodeListValidateBeforeCall(requestParameters, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Retrieves a code list by ID for a specific country (asynchronously) + * A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions.<br><br>Code Lists are versioned, and each version may have defined effective and sunset dates to ensure that the correct set of allowable values is applied according to regulatory or jurisdictional requirements.<br><br>By default, the API returns only non-expired code list versions (versions where the sunset date has not passed). To retrieve expired versions or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters. + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Code list not found. -
+ */ + public okhttp3.Call getCodeListAsync(GetCodeListRequest requestParameters, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getCodeListValidateBeforeCall(requestParameters, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Represents the Request object for the GetCodeList API + * + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param codelistId System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. + * @param countryCode Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param effectiveDate Filter code list versions by effective date. Returns versions that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. (optional) + * @param sunsetDate Filter code list versions by sunset date. Returns versions that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired versions are returned. (optional) + */ + public class GetCodeListRequest { + private String avalaraVersion; + private String codelistId; + private String countryCode; + private String xAvalaraClient; + private LocalDate effectiveDate; + private LocalDate sunsetDate; + + public GetCodeListRequest () { + } + + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } + public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } + public String getCodelistId() { return codelistId; } + public void setCodelistId(String codelistId) { this.codelistId = codelistId; } + public String getCountryCode() { return countryCode; } + public void setCountryCode(String countryCode) { this.countryCode = countryCode; } + public String getXAvalaraClient() { return xAvalaraClient; } + public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } + public LocalDate getEffectiveDate() { return effectiveDate; } + public void setEffectiveDate(LocalDate effectiveDate) { this.effectiveDate = effectiveDate; } + public LocalDate getSunsetDate() { return sunsetDate; } + public void setSunsetDate(LocalDate sunsetDate) { this.sunsetDate = sunsetDate; } + } + + /** + * Getter function to instantiate Request class + * @returns GetCodeListRequest + */ + public GetCodeListRequest getGetCodeListRequest() { + return this.new GetCodeListRequest(); + } + + /** + * Build call for getCodeListList + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public okhttp3.Call getCodeListListCall(GetCodeListListRequest requestParameters, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + //OAuth2 Scopes + String requiredScopes = ""; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/einvoicing/codelists"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (requestParameters.getCountryCode() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("countryCode", requestParameters.getCountryCode())); + } + + if (requestParameters.getEffectiveDate() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("effectiveDate", requestParameters.getEffectiveDate())); + } + + if (requestParameters.getSunsetDate() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("sunsetDate", requestParameters.getSunsetDate())); + } + + if (requestParameters.get$count() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$count", requestParameters.get$count())); + } + + if (requestParameters.get$countOnly() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$countOnly", requestParameters.get$countOnly())); + } + + if (requestParameters.get$top() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$top", requestParameters.get$top())); + } + + if (requestParameters.get$skip() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$skip", requestParameters.get$skip())); + } + + if (requestParameters.getAvalaraVersion() != null) { + localVarHeaderParams.put("avalara-version", localVarApiClient.parameterToString(requestParameters.getAvalaraVersion())); + } + + if (requestParameters.getXAvalaraClient() != null) { + localVarHeaderParams.put("X-Avalara-Client", localVarApiClient.parameterToString(requestParameters.getXAvalaraClient())); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null && !localVarHeaderParams.containsKey("Accept")) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + String[] localVarAuthNames = new String[] { "OAuth", "Bearer" }; + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, requiredScopes, AvalaraMicroservice.EInvoicing); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getCodeListListValidateBeforeCall(GetCodeListListRequest requestParameters, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'requestParameters.avalaraVersion' is set + if (requestParameters.getAvalaraVersion() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.avalaraVersion' when calling getCodeListList(Async)"); + } + + // verify the required parameter 'requestParameters.countryCode' is set + if (requestParameters.getCountryCode() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.countryCode' when calling getCodeListList(Async)"); + } + + + okhttp3.Call localVarCall = getCodeListListCall(requestParameters, _callback); + return localVarCall; + + } + + /** + * Returns a list of code lists for a specific country + * Get a list of code lists on the Avalara E-Invoicing platform for the specified country. By default, the API returns only non-expired code lists (code lists where the sunset date has not passed). To retrieve expired code lists or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters.<br><br>A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions. + * @param requestOptions Object which represents the options available for a given API/request + * @return CodeListListResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public CodeListListResponse getCodeListList(GetCodeListListRequest requestParameters) throws ApiException { + ApiResponse localVarResp = getCodeListListWithHttpInfo(requestParameters); + return localVarResp.getData(); + } + + /** + * Returns a list of code lists for a specific country + * Get a list of code lists on the Avalara E-Invoicing platform for the specified country. By default, the API returns only non-expired code lists (code lists where the sunset date has not passed). To retrieve expired code lists or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters.<br><br>A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions. + * @param requestOptions Object which represents the options available for a given API/request + * @return ApiResponse<CodeListListResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public ApiResponse getCodeListListWithHttpInfo(GetCodeListListRequest requestParameters) throws ApiException { + okhttp3.Call localVarCall = getCodeListListValidateBeforeCall(requestParameters, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Returns a list of code lists for a specific country (asynchronously) + * Get a list of code lists on the Avalara E-Invoicing platform for the specified country. By default, the API returns only non-expired code lists (code lists where the sunset date has not passed). To retrieve expired code lists or filter by specific date ranges, use the <code>effectiveDate</code> and <code>sunsetDate</code> query parameters.<br><br>A Code List is a controlled set of predefined, standardized values used to populate specific fields in electronic documents (such as e-invoices). Each code has a stable, machine-readable identifier and a human-readable description. Code Lists are typically based on global standards (e.g., UN/CEFACT, ISO, EN16931) and may include jurisdiction-specific extensions or restrictions. + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 OK -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public okhttp3.Call getCodeListListAsync(GetCodeListListRequest requestParameters, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getCodeListListValidateBeforeCall(requestParameters, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Represents the Request object for the GetCodeListList API + * + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param countryCode Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction for which code lists should be returned. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param effectiveDate Filter code lists by effective date. Returns code lists that are effective on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, defaults to the current date. sunsetDate is required when effectiveDate is provided. (optional) + * @param sunsetDate Filter code lists by sunset date. Returns code lists that have not yet sunset on or before this date. Format: YYYY-MM-DD (ISO 8601). If not specified, only non-expired code lists are returned. (optional) + * @param $count When set to true, the response body also includes the count of items in the collection. (optional) + * @param $countOnly When set to true, the response returns only the count of items in the collection. (optional) + * @param $top The number of items to include in the result. (optional) + * @param $skip The number of items to skip in the result. (optional) + */ + public class GetCodeListListRequest { + private String avalaraVersion; + private String countryCode; + private String xAvalaraClient; + private LocalDate effectiveDate; + private LocalDate sunsetDate; + private String $count; + private String $countOnly; + private Integer $top; + private Integer $skip; + + public GetCodeListListRequest () { + } + + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } + public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } + public String getCountryCode() { return countryCode; } + public void setCountryCode(String countryCode) { this.countryCode = countryCode; } + public String getXAvalaraClient() { return xAvalaraClient; } + public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } + public LocalDate getEffectiveDate() { return effectiveDate; } + public void setEffectiveDate(LocalDate effectiveDate) { this.effectiveDate = effectiveDate; } + public LocalDate getSunsetDate() { return sunsetDate; } + public void setSunsetDate(LocalDate sunsetDate) { this.sunsetDate = sunsetDate; } + public String get$count() { return $count; } + public void set$count(String $count) { this.$count = $count; } + public String get$countOnly() { return $countOnly; } + public void set$countOnly(String $countOnly) { this.$countOnly = $countOnly; } + public Integer get$top() { return $top; } + public void set$top(Integer $top) { this.$top = $top; } + public Integer get$skip() { return $skip; } + public void set$skip(Integer $skip) { this.$skip = $skip; } + } + + /** + * Getter function to instantiate Request class + * @returns GetCodeListListRequest + */ + public GetCodeListListRequest getGetCodeListListRequest() { + return this.new GetCodeListListRequest(); + } + + private void SetConfiguration(ApiClient client) { + if (client == null) throw new MissingFormatArgumentException("client"); + this.localVarApiClient.setSdkVersion("26.4.0"); + } +} + diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/DataInputFieldsApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/DataInputFieldsApi.java index 71d438d..50695ae 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/DataInputFieldsApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/DataInputFieldsApi.java @@ -85,10 +85,10 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Returns a DataInputFieldsResponse object containing the data input fields and their optionality for the requested mandate. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public okhttp3.Call getDataInputFieldsCall(GetDataInputFieldsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -183,17 +183,17 @@ private okhttp3.Call getDataInputFieldsValidateBeforeCall(GetDataInputFieldsRequ /** * Returns the optionality of document fields for different country mandates - * This endpoint provides a list of required, conditional, and optional fields for each country mandate. You can use the <code>mandates</code> endpoint to retrieve all available country mandates. You can use the $filter query parameter to retrieve fields for a particular mandate + * This endpoint returns a list of required, conditional, and optional fields for each country mandate. Use the mandates endpoint to retrieve all available country mandates. Use the $filter query parameter to retrieve fields for a specific mandate. * @param requestOptions Object which represents the options available for a given API/request * @return DataInputFieldsResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Returns a DataInputFieldsResponse object containing the data input fields and their optionality for the requested mandate. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public DataInputFieldsResponse getDataInputFields(GetDataInputFieldsRequest requestParameters) throws ApiException { @@ -203,17 +203,17 @@ public DataInputFieldsResponse getDataInputFields(GetDataInputFieldsRequest requ /** * Returns the optionality of document fields for different country mandates - * This endpoint provides a list of required, conditional, and optional fields for each country mandate. You can use the <code>mandates</code> endpoint to retrieve all available country mandates. You can use the $filter query parameter to retrieve fields for a particular mandate + * This endpoint returns a list of required, conditional, and optional fields for each country mandate. Use the mandates endpoint to retrieve all available country mandates. Use the $filter query parameter to retrieve fields for a specific mandate. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<DataInputFieldsResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Returns a DataInputFieldsResponse object containing the data input fields and their optionality for the requested mandate. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public ApiResponse getDataInputFieldsWithHttpInfo(GetDataInputFieldsRequest requestParameters) throws ApiException { @@ -224,7 +224,7 @@ public ApiResponse getDataInputFieldsWithHttpInfo(GetDa /** * Returns the optionality of document fields for different country mandates (asynchronously) - * This endpoint provides a list of required, conditional, and optional fields for each country mandate. You can use the <code>mandates</code> endpoint to retrieve all available country mandates. You can use the $filter query parameter to retrieve fields for a particular mandate + * This endpoint returns a list of required, conditional, and optional fields for each country mandate. Use the mandates endpoint to retrieve all available country mandates. Use the $filter query parameter to retrieve fields for a specific mandate. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -232,10 +232,10 @@ public ApiResponse getDataInputFieldsWithHttpInfo(GetDa * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Returns a DataInputFieldsResponse object containing the data input fields and their optionality for the requested mandate. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public okhttp3.Call getDataInputFieldsAsync(GetDataInputFieldsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -248,13 +248,13 @@ public okhttp3.Call getDataInputFieldsAsync(GetDataInputFieldsRequest requestPar /** * Represents the Request object for the GetDataInputFields API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) - * @param $filter Filter by field name and value. This filter only supports eq and contains. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param $filter Filter by field name and value. This filter supports only eq and contains. For more information, refer to the Avalara filtering guide. (optional) * @param $top The number of items to include in the result. (optional) * @param $skip The number of items to skip in the result. (optional) - * @param $count When set to true, the count of the collection is also returned in the response body (optional) - * @param $countOnly When set to true, only the count of the collection is returned (optional) + * @param $count When set to true, the response body also includes the count of items in the collection. (optional) + * @param $countOnly When set to true, the response returns only the count of items in the collection. (optional) */ public class GetDataInputFieldsRequest { private String avalaraVersion; @@ -268,7 +268,7 @@ public class GetDataInputFieldsRequest { public GetDataInputFieldsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXAvalaraClient() { return xAvalaraClient; } public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } @@ -294,7 +294,7 @@ public GetDataInputFieldsRequest getGetDataInputFieldsRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/DocumentsApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/DocumentsApi.java index 6cd3511..084d537 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/DocumentsApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/DocumentsApi.java @@ -96,11 +96,11 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK * Content-type -
401 Unauthorized -
403 Forbidden -
200 Returns the document content in the format specified by the Accept header. * Content-type -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
406 Unsupported document format was requested in the Accept header -
406 Unsupported document format was requested in the Accept header. -
*/ public okhttp3.Call downloadDocumentCall(DownloadDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -190,18 +190,18 @@ private okhttp3.Call downloadDocumentValidateBeforeCall(DownloadDocumentRequest /** * Returns a copy of the document - * When the document is available, use this endpoint to download it as text, XML, or PDF. The output format needs to be specified in the Accept header, and it will vary depending on the mandate. If the file has not yet been created, then status code 404 (not found) is returned. + * Downloads the document when it is available. Specify the output format in the Accept header. Returns 404 if the file has not been created. * @param requestOptions Object which represents the options available for a given API/request * @return File * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK * Content-type -
401 Unauthorized -
403 Forbidden -
200 Returns the document content in the format specified by the Accept header. * Content-type -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
406 Unsupported document format was requested in the Accept header -
406 Unsupported document format was requested in the Accept header. -
*/ public File downloadDocument(DownloadDocumentRequest requestParameters) throws ApiException { @@ -211,18 +211,18 @@ public File downloadDocument(DownloadDocumentRequest requestParameters) throws A /** * Returns a copy of the document - * When the document is available, use this endpoint to download it as text, XML, or PDF. The output format needs to be specified in the Accept header, and it will vary depending on the mandate. If the file has not yet been created, then status code 404 (not found) is returned. + * Downloads the document when it is available. Specify the output format in the Accept header. Returns 404 if the file has not been created. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<File> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK * Content-type -
401 Unauthorized -
403 Forbidden -
200 Returns the document content in the format specified by the Accept header. * Content-type -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
406 Unsupported document format was requested in the Accept header -
406 Unsupported document format was requested in the Accept header. -
*/ public ApiResponse downloadDocumentWithHttpInfo(DownloadDocumentRequest requestParameters) throws ApiException { @@ -233,7 +233,7 @@ public ApiResponse downloadDocumentWithHttpInfo(DownloadDocumentRequest re /** * Returns a copy of the document (asynchronously) - * When the document is available, use this endpoint to download it as text, XML, or PDF. The output format needs to be specified in the Accept header, and it will vary depending on the mandate. If the file has not yet been created, then status code 404 (not found) is returned. + * Downloads the document when it is available. Specify the output format in the Accept header. Returns 404 if the file has not been created. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -241,11 +241,11 @@ public ApiResponse downloadDocumentWithHttpInfo(DownloadDocumentRequest re * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK * Content-type -
401 Unauthorized -
403 Forbidden -
200 Returns the document content in the format specified by the Accept header. * Content-type -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
406 Unsupported document format was requested in the Accept header -
406 Unsupported document format was requested in the Accept header. -
*/ public okhttp3.Call downloadDocumentAsync(DownloadDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -258,10 +258,10 @@ public okhttp3.Call downloadDocumentAsync(DownloadDocumentRequest requestParamet /** * Represents the Request object for the DownloadDocument API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param accept This header indicates the MIME type of the document - * @param documentId The unique ID for this document that was returned in the POST /einvoicing/document response body - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param accept Header that specifies the MIME type of the returned document. + * @param documentId The unique documentId returned in the POST /documents response body. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) */ public class DownloadDocumentRequest { private String avalaraVersion; @@ -272,7 +272,7 @@ public class DownloadDocumentRequest { public DownloadDocumentRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getAccept() { return accept; } public void setAccept(String accept) { this.accept = accept; } @@ -299,10 +299,10 @@ public DownloadDocumentRequest getDownloadDocumentRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Accepted DocumentFetch Request -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Response from the inbound document fetch endpoint. Contains the platform documentId for status checks and downloads, the returned status (e.g. Accepted), and eventDateTime when the document was accepted. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public okhttp3.Call fetchDocumentsCall(FetchDocumentsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -382,17 +382,17 @@ private okhttp3.Call fetchDocumentsValidateBeforeCall(FetchDocumentsRequest requ /** * Fetch the inbound document from a tax authority - * This API allows you to retrieve an inbound document. Pass key-value pairs as parameters in the request, such as the confirmation number, supplier number, and buyer VAT number. + * Retrieves an inbound document. Provide key-value pairs as request parameters. Supported parameters vary by tax authority and country. * @param requestOptions Object which represents the options available for a given API/request * @return DocumentFetch * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Accepted DocumentFetch Request -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Response from the inbound document fetch endpoint. Contains the platform documentId for status checks and downloads, the returned status (e.g. Accepted), and eventDateTime when the document was accepted. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public DocumentFetch fetchDocuments(FetchDocumentsRequest requestParameters) throws ApiException { @@ -402,17 +402,17 @@ public DocumentFetch fetchDocuments(FetchDocumentsRequest requestParameters) thr /** * Fetch the inbound document from a tax authority - * This API allows you to retrieve an inbound document. Pass key-value pairs as parameters in the request, such as the confirmation number, supplier number, and buyer VAT number. + * Retrieves an inbound document. Provide key-value pairs as request parameters. Supported parameters vary by tax authority and country. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<DocumentFetch> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Accepted DocumentFetch Request -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Response from the inbound document fetch endpoint. Contains the platform documentId for status checks and downloads, the returned status (e.g. Accepted), and eventDateTime when the document was accepted. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public ApiResponse fetchDocumentsWithHttpInfo(FetchDocumentsRequest requestParameters) throws ApiException { @@ -423,7 +423,7 @@ public ApiResponse fetchDocumentsWithHttpInfo(FetchDocumentsReque /** * Fetch the inbound document from a tax authority (asynchronously) - * This API allows you to retrieve an inbound document. Pass key-value pairs as parameters in the request, such as the confirmation number, supplier number, and buyer VAT number. + * Retrieves an inbound document. Provide key-value pairs as request parameters. Supported parameters vary by tax authority and country. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -431,10 +431,10 @@ public ApiResponse fetchDocumentsWithHttpInfo(FetchDocumentsReque * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Accepted DocumentFetch Request -
401 Unauthorized -
403 Forbidden -
500 Internal Server Error -
200 Response from the inbound document fetch endpoint. Contains the platform documentId for status checks and downloads, the returned status (e.g. Accepted), and eventDateTime when the document was accepted. -
401 Unauthorized. -
403 Forbidden. -
500 Internal server error. -
*/ public okhttp3.Call fetchDocumentsAsync(FetchDocumentsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -447,9 +447,9 @@ public okhttp3.Call fetchDocumentsAsync(FetchDocumentsRequest requestParameters, /** * Represents the Request object for the FetchDocuments API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). * @param fetchDocumentsRequest - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) */ public class FetchDocumentsRequest { private String avalaraVersion; @@ -459,7 +459,7 @@ public class FetchDocumentsRequest { public FetchDocumentsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public FetchDocumentsRequest getFetchDocumentsRequest() { return fetchDocumentsRequest; } public void setFetchDocumentsRequest(FetchDocumentsRequest fetchDocumentsRequest) { this.fetchDocumentsRequest = fetchDocumentsRequest; } @@ -484,10 +484,10 @@ public FetchDocumentsRequest getFetchDocumentsRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
200 Returns a collection of document summaries for the specified date range. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public okhttp3.Call getDocumentListCall(GetDocumentListRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -543,6 +543,10 @@ public okhttp3.Call getDocumentListCall(GetDocumentListRequest requestParameters localVarQueryParams.addAll(localVarApiClient.parameterToPair("$filter", requestParameters.get$filter())); } + if (requestParameters.get$include() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$include", requestParameters.get$include())); + } + if (requestParameters.get$top() != null) { localVarQueryParams.addAll(localVarApiClient.parameterToPair("$top", requestParameters.get$top())); } @@ -594,17 +598,17 @@ private okhttp3.Call getDocumentListValidateBeforeCall(GetDocumentListRequest re /** * Returns a summary of documents for a date range - * Get a list of documents on the Avalara E-Invoicing platform that have a processing date within the specified date range. + * Returns a list of document summaries with a processing date within the specified date range. * @param requestOptions Object which represents the options available for a given API/request * @return DocumentListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
200 Returns a collection of document summaries for the specified date range. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public DocumentListResponse getDocumentList(GetDocumentListRequest requestParameters) throws ApiException { @@ -614,17 +618,17 @@ public DocumentListResponse getDocumentList(GetDocumentListRequest requestParame /** * Returns a summary of documents for a date range - * Get a list of documents on the Avalara E-Invoicing platform that have a processing date within the specified date range. + * Returns a list of document summaries with a processing date within the specified date range. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<DocumentListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
200 Returns a collection of document summaries for the specified date range. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public ApiResponse getDocumentListWithHttpInfo(GetDocumentListRequest requestParameters) throws ApiException { @@ -635,7 +639,7 @@ public ApiResponse getDocumentListWithHttpInfo(GetDocument /** * Returns a summary of documents for a date range (asynchronously) - * Get a list of documents on the Avalara E-Invoicing platform that have a processing date within the specified date range. + * Returns a list of document summaries with a processing date within the specified date range. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -643,10 +647,10 @@ public ApiResponse getDocumentListWithHttpInfo(GetDocument * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad request -
401 Unauthorized -
403 Forbidden -
200 Returns a collection of document summaries for the specified date range. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public okhttp3.Call getDocumentListAsync(GetDocumentListRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -659,14 +663,15 @@ public okhttp3.Call getDocumentListAsync(GetDocumentListRequest requestParameter /** * Represents the Request object for the GetDocumentList API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) - * @param startDate Start date of documents to return. This defaults to the previous month. (optional) - * @param endDate End date of documents to return. This defaults to the current date. (optional) - * @param flow Optionally filter by document direction, where issued = `out` and received = `in` (optional) - * @param $count When set to true, the count of the collection is also returned in the response body (optional) - * @param $countOnly When set to true, only the count of the collection is returned (optional) - * @param $filter Filter by field name and value. This filter only supports eq . Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. Filtering will be done over the provided startDate and endDate. If no startDate or endDate is provided, defaults will be assumed. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param startDate Start date for documents to return. Defaults to the previous month. Format: \"YYYY-MM-DDThh:mm:ss\". (optional) + * @param endDate End date for documents to return. Defaults to the current date. Format: \"YYYY-MM-DDThh:mm:ss\". (optional) + * @param flow Optional filter for document direction: issued uses \"out\" and received uses \"in\". (optional) + * @param $count When set to true, the response body also includes the count of items in the collection. (optional) + * @param $countOnly When set to true, the response returns only the count of items in the collection. (optional) + * @param $filter Filter by field name and value. This filter supports only eq. For more information, refer to the Avalara filtering guide. (optional) + * @param $include When set to `events`, each document in the response includes its events array. Omit this parameter or use any other value to exclude events from the response. (optional) * @param $top The number of items to include in the result. (optional) * @param $skip The number of items to skip in the result. (optional) */ @@ -679,13 +684,14 @@ public class GetDocumentListRequest { private String $count; private String $countOnly; private String $filter; + private String $include; private Integer $top; private Integer $skip; public GetDocumentListRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXAvalaraClient() { return xAvalaraClient; } public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } @@ -701,6 +707,8 @@ public GetDocumentListRequest () { public void set$countOnly(String $countOnly) { this.$countOnly = $countOnly; } public String get$filter() { return $filter; } public void set$filter(String $filter) { this.$filter = $filter; } + public String get$include() { return $include; } + public void set$include(String $include) { this.$include = $include; } public Integer get$top() { return $top; } public void set$top(Integer $top) { this.$top = $top; } public Integer get$skip() { return $skip; } @@ -724,9 +732,9 @@ public GetDocumentListRequest getGetDocumentListRequest() { * @http.response.details - - - + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns the current status for the specified documentId. -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
*/ @@ -808,16 +816,16 @@ private okhttp3.Call getDocumentStatusValidateBeforeCall(GetDocumentStatusReques /** * Checks the status of a document - * Using the unique ID from POST /einvoicing/documents response body, request the current status of a document. + * Uses the documentId from the POST /documents response body to return the current status of a document. * @param requestOptions Object which represents the options available for a given API/request * @return DocumentStatusResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns the current status for the specified documentId. -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
*/ @@ -828,16 +836,16 @@ public DocumentStatusResponse getDocumentStatus(GetDocumentStatusRequest request /** * Checks the status of a document - * Using the unique ID from POST /einvoicing/documents response body, request the current status of a document. + * Uses the documentId from the POST /documents response body to return the current status of a document. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<DocumentStatusResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns the current status for the specified documentId. -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
*/ @@ -849,7 +857,7 @@ public ApiResponse getDocumentStatusWithHttpInfo(GetDocu /** * Checks the status of a document (asynchronously) - * Using the unique ID from POST /einvoicing/documents response body, request the current status of a document. + * Uses the documentId from the POST /documents response body to return the current status of a document. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -857,9 +865,9 @@ public ApiResponse getDocumentStatusWithHttpInfo(GetDocu * @http.response.details - - - + + +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns the current status for the specified documentId. -
401 Unauthorized. -
403 Forbidden. -
404 A document for the specified ID was not found. -
*/ @@ -873,9 +881,9 @@ public okhttp3.Call getDocumentStatusAsync(GetDocumentStatusRequest requestParam /** * Represents the Request object for the GetDocumentStatus API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param documentId The unique ID for this document that was returned in the POST /einvoicing/documents response body - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param documentId The unique documentId returned in the POST /documents response body. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) */ public class GetDocumentStatusRequest { private String avalaraVersion; @@ -885,7 +893,7 @@ public class GetDocumentStatusRequest { public GetDocumentStatusRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getDocumentId() { return documentId; } public void setDocumentId(String documentId) { this.documentId = documentId; } @@ -910,10 +918,10 @@ public GetDocumentStatusRequest getGetDocumentStatusRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
403 Forbidden -
201 Returns a unique documentId for the submitted document. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public okhttp3.Call submitDocumentCall(SubmitDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1013,10 +1021,10 @@ private okhttp3.Call submitDocumentValidateBeforeCall(SubmitDocumentRequest requ * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
403 Forbidden -
201 Returns a unique documentId for the submitted document. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public DocumentSubmitResponse submitDocument(SubmitDocumentRequest requestParameters) throws ApiException { @@ -1033,10 +1041,10 @@ public DocumentSubmitResponse submitDocument(SubmitDocumentRequest requestParame * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
403 Forbidden -
201 Returns a unique documentId for the submitted document. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public ApiResponse submitDocumentWithHttpInfo(SubmitDocumentRequest requestParameters) throws ApiException { @@ -1055,10 +1063,10 @@ public ApiResponse submitDocumentWithHttpInfo(SubmitDocu * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Created -
400 Bad request -
401 Unauthorized -
403 Forbidden -
201 Returns a unique documentId for the submitted document. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
*/ public okhttp3.Call submitDocumentAsync(SubmitDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1071,10 +1079,10 @@ public okhttp3.Call submitDocumentAsync(SubmitDocumentRequest requestParameters, /** * Represents the Request object for the SubmitDocument API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). * @param metadata * @param data The document to be submitted, as indicated by the metadata fields 'dataFormat' and 'dataFormatVersion' - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) */ public class SubmitDocumentRequest { private String avalaraVersion; @@ -1085,7 +1093,7 @@ public class SubmitDocumentRequest { public SubmitDocumentRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public SubmitDocumentMetadata getMetadata() { return metadata; } public void setMetadata(SubmitDocumentMetadata metadata) { this.metadata = metadata; } @@ -1105,7 +1113,7 @@ public SubmitDocumentRequest getSubmitDocumentRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/InteropApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/InteropApi.java index 10e4a3e..d77a9c6 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/InteropApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/InteropApi.java @@ -85,11 +85,11 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Document Accepted. This doesn't mean it is processed. This is just a transport ack. * X-Correlation-ID -
400 Bad/Invalid Request. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Document accepted for processing. Returns the interchange ID and acceptance message. This is a transport acknowledgment; processing occurs asynchronously. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call submitInteropDocumentCall(SubmitInteropDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -190,18 +190,18 @@ private okhttp3.Call submitInteropDocumentValidateBeforeCall(SubmitInteropDocume /** * Submit a document - * This API used by the interoperability partners to submit a document to their trading partners in Avalara on behalf of their customers. + * Upload documents on behalf of interoperability partners and submit them to trading partners through the Avalara platform. * @param requestOptions Object which represents the options available for a given API/request * @return SubmitInteropDocument202Response * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Document Accepted. This doesn't mean it is processed. This is just a transport ack. * X-Correlation-ID -
400 Bad/Invalid Request. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Document accepted for processing. Returns the interchange ID and acceptance message. This is a transport acknowledgment; processing occurs asynchronously. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public SubmitInteropDocument202Response submitInteropDocument(SubmitInteropDocumentRequest requestParameters) throws ApiException { @@ -211,18 +211,18 @@ public SubmitInteropDocument202Response submitInteropDocument(SubmitInteropDocum /** * Submit a document - * This API used by the interoperability partners to submit a document to their trading partners in Avalara on behalf of their customers. + * Upload documents on behalf of interoperability partners and submit them to trading partners through the Avalara platform. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<SubmitInteropDocument202Response> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Document Accepted. This doesn't mean it is processed. This is just a transport ack. * X-Correlation-ID -
400 Bad/Invalid Request. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Document accepted for processing. Returns the interchange ID and acceptance message. This is a transport acknowledgment; processing occurs asynchronously. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse submitInteropDocumentWithHttpInfo(SubmitInteropDocumentRequest requestParameters) throws ApiException { @@ -233,7 +233,7 @@ public ApiResponse submitInteropDocumentWithHt /** * Submit a document (asynchronously) - * This API used by the interoperability partners to submit a document to their trading partners in Avalara on behalf of their customers. + * Upload documents on behalf of interoperability partners and submit them to trading partners through the Avalara platform. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -241,11 +241,11 @@ public ApiResponse submitInteropDocumentWithHt * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Document Accepted. This doesn't mean it is processed. This is just a transport ack. * X-Correlation-ID -
400 Bad/Invalid Request. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Document accepted for processing. Returns the interchange ID and acceptance message. This is a transport acknowledgment; processing occurs asynchronously. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call submitInteropDocumentAsync(SubmitInteropDocumentRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -260,9 +260,9 @@ public okhttp3.Call submitInteropDocumentAsync(SubmitInteropDocumentRequest requ * * @param documentType Type of the document being uploaded. Partners will be configured in Avalara system to send only certain types of documents. * @param interchangeType Type of interchange (codes in Avalara system that uniquely identifies a type of interchange). Partners will be configured in Avalara system to send documents belonging to certain types of interchanges. - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\" (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) * @param fileName The file to be uploaded (e.g., UBL XML, CII XML). (optional) */ public class SubmitInteropDocumentRequest { @@ -280,7 +280,7 @@ public SubmitInteropDocumentRequest () { public void setDocumentType(String documentType) { this.documentType = documentType; } public String getInterchangeType() { return interchangeType; } public void setInterchangeType(String interchangeType) { this.interchangeType = interchangeType; } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXAvalaraClient() { return xAvalaraClient; } public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } @@ -300,7 +300,7 @@ public SubmitInteropDocumentRequest getSubmitInteropDocumentRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/MandatesApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/MandatesApi.java index a0c5f52..a3be934 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/MandatesApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/MandatesApi.java @@ -88,10 +88,10 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
200 Returns a MandateDataInputFieldsResponse object containing the input fields and their optionality for the specified mandate, document type, and document version. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
@@ -199,10 +199,10 @@ private okhttp3.Call getMandateDataInputFieldsValidateBeforeCall(GetMandateDataI * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
200 Returns a MandateDataInputFieldsResponse object containing the input fields and their optionality for the specified mandate, document type, and document version. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
@@ -221,10 +221,10 @@ public List getMandateDataInputFields(GetMandateDataInput * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
200 Returns a MandateDataInputFieldsResponse object containing the input fields and their optionality for the specified mandate, document type, and document version. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
@@ -245,10 +245,10 @@ public ApiResponse> getMandateDataInputFieldsWithHtt * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
200 Returns a MandateDataInputFieldsResponse object containing the input fields and their optionality for the specified mandate, document type, and document version. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
@@ -263,11 +263,11 @@ public okhttp3.Call getMandateDataInputFieldsAsync(GetMandateDataInputFieldsRequ /** * Represents the Request object for the GetMandateDataInputFields API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param mandateId The unique ID for the mandate that was returned in the GET /einvoicing/mandates response body + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param mandateId Unique identifier of the mandate returned by the GET /mandates endpoint. * @param documentType Select the documentType for which you wish to view the data-input-fields (You may obtain the supported documentTypes from the GET /mandates endpoint) * @param documentVersion Select the document version of the documentType (You may obtain the supported documentVersion from the GET /mandates endpoint) - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) */ public class GetMandateDataInputFieldsRequest { private String avalaraVersion; @@ -279,7 +279,7 @@ public class GetMandateDataInputFieldsRequest { public GetMandateDataInputFieldsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getMandateId() { return mandateId; } public void setMandateId(String mandateId) { this.mandateId = mandateId; } @@ -308,11 +308,11 @@ public GetMandateDataInputFieldsRequest getGetMandateDataInputFieldsRequest() { * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns a MandatesResponse object containing the supported country mandates. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
500 Internal server error. -
*/ public okhttp3.Call getMandatesCall(GetMandatesRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -414,11 +414,11 @@ private okhttp3.Call getMandatesValidateBeforeCall(GetMandatesRequest requestPar * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns a MandatesResponse object containing the supported country mandates. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
500 Internal server error. -
*/ public MandatesResponse getMandates(GetMandatesRequest requestParameters) throws ApiException { @@ -435,11 +435,11 @@ public MandatesResponse getMandates(GetMandatesRequest requestParameters) throws * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns a MandatesResponse object containing the supported country mandates. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
500 Internal server error. -
*/ public ApiResponse getMandatesWithHttpInfo(GetMandatesRequest requestParameters) throws ApiException { @@ -458,11 +458,11 @@ public ApiResponse getMandatesWithHttpInfo(GetMandatesRequest * @http.response.details - - - + + + - +
Status Code Description Response Headers
200 OK -
401 Unauthorized -
403 Forbidden -
200 Returns a MandatesResponse object containing the supported country mandates. -
401 Unauthorized. -
403 Forbidden. -
404 Resource not found -
500 Internal Server Error -
500 Internal server error. -
*/ public okhttp3.Call getMandatesAsync(GetMandatesRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -475,13 +475,13 @@ public okhttp3.Call getMandatesAsync(GetMandatesRequest requestParameters, final /** * Represents the Request object for the GetMandates API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a fingerprint. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) * @param $filter Filter by field name and value. This filter only supports eq and contains. Refer to [https://developer.avalara.com/avatax/filtering-in-rest/](https://developer.avalara.com/avatax/filtering-in-rest/) for more information on filtering. (optional) * @param $top The number of items to include in the result. (optional) * @param $skip The number of items to skip in the result. (optional) * @param $count When set to true, the count of the collection is also returned in the response body. (optional) - * @param $countOnly When set to true, only the count of the collection is returned (optional) + * @param $countOnly When set to true, only the count of the collection is returned. (optional) */ public class GetMandatesRequest { private String avalaraVersion; @@ -495,7 +495,7 @@ public class GetMandatesRequest { public GetMandatesRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXAvalaraClient() { return xAvalaraClient; } public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } @@ -521,7 +521,7 @@ public GetMandatesRequest getGetMandatesRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/ReportsApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/ReportsApi.java new file mode 100644 index 0000000..97a0b32 --- /dev/null +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/ReportsApi.java @@ -0,0 +1,711 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.api.EInvoicing.V1; + +import Avalara.SDK.ApiCallback; +import Avalara.SDK.ApiClient; +import Avalara.SDK.ApiException; +import Avalara.SDK.ApiResponse; +import Avalara.SDK.Configuration; +import Avalara.SDK.Pair; +import Avalara.SDK.ProgressRequestBody; +import Avalara.SDK.ProgressResponseBody; +import Avalara.SDK.AvalaraMicroservice; + + +import com.google.gson.reflect.TypeToken; + +import java.io.IOException; +import java.util.*; + + +import Avalara.SDK.model.EInvoicing.V1.BadRequest; +import Avalara.SDK.model.EInvoicing.V1.ForbiddenError; +import Avalara.SDK.model.EInvoicing.V1.NotFoundError; +import Avalara.SDK.model.EInvoicing.V1.ReportDownloadResponse; +import Avalara.SDK.model.EInvoicing.V1.ReportItem; +import Avalara.SDK.model.EInvoicing.V1.ReportListResponse; + +import java.lang.reflect.Type; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ReportsApi { + private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; + + public ReportsApi(ApiClient apiClient) { + this.localVarApiClient = apiClient; + SetConfiguration(apiClient); + } + + public ApiClient getApiClient() { + return localVarApiClient; + } + + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + + /** + * Build call for downloadReport + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Returns a pre-signed URL to download the report. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found or not yet available for download. -
+ */ + public okhttp3.Call downloadReportCall(DownloadReportRequest requestParameters, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + //OAuth2 Scopes + String requiredScopes = ""; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/einvoicing/reports/{reportId}/$download" + .replaceAll("\\{" + "reportId" + "\\}", localVarApiClient.escapeString(requestParameters.reportId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (requestParameters.getAvalaraVersion() != null) { + localVarHeaderParams.put("avalara-version", localVarApiClient.parameterToString(requestParameters.getAvalaraVersion())); + } + + if (requestParameters.getXAvalaraClient() != null) { + localVarHeaderParams.put("X-Avalara-Client", localVarApiClient.parameterToString(requestParameters.getXAvalaraClient())); + } + + if (requestParameters.getXCorrelationID() != null) { + localVarHeaderParams.put("X-Correlation-ID", localVarApiClient.parameterToString(requestParameters.getXCorrelationID())); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null && !localVarHeaderParams.containsKey("Accept")) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + String[] localVarAuthNames = new String[] { "OAuth", "Bearer" }; + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, requiredScopes, AvalaraMicroservice.EInvoicing); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call downloadReportValidateBeforeCall(DownloadReportRequest requestParameters, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'requestParameters.avalaraVersion' is set + if (requestParameters.getAvalaraVersion() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.avalaraVersion' when calling downloadReport(Async)"); + } + + // verify the required parameter 'requestParameters.reportId' is set + if (requestParameters.getReportId() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.reportId' when calling downloadReport(Async)"); + } + + + okhttp3.Call localVarCall = downloadReportCall(requestParameters, _callback); + return localVarCall; + + } + + /** + * Returns a pre-signed download URL for a report + * Returns a pre-signed URL to download the report file when it is available. If the report has not yet been generated, a 404 (not found) is returned. + * @param requestOptions Object which represents the options available for a given API/request + * @return ReportDownloadResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Returns a pre-signed URL to download the report. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found or not yet available for download. -
+ */ + public ReportDownloadResponse downloadReport(DownloadReportRequest requestParameters) throws ApiException { + ApiResponse localVarResp = downloadReportWithHttpInfo(requestParameters); + return localVarResp.getData(); + } + + /** + * Returns a pre-signed download URL for a report + * Returns a pre-signed URL to download the report file when it is available. If the report has not yet been generated, a 404 (not found) is returned. + * @param requestOptions Object which represents the options available for a given API/request + * @return ApiResponse<ReportDownloadResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Returns a pre-signed URL to download the report. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found or not yet available for download. -
+ */ + public ApiResponse downloadReportWithHttpInfo(DownloadReportRequest requestParameters) throws ApiException { + okhttp3.Call localVarCall = downloadReportValidateBeforeCall(requestParameters, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Returns a pre-signed download URL for a report (asynchronously) + * Returns a pre-signed URL to download the report file when it is available. If the report has not yet been generated, a 404 (not found) is returned. + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Returns a pre-signed URL to download the report. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found or not yet available for download. -
+ */ + public okhttp3.Call downloadReportAsync(DownloadReportRequest requestParameters, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = downloadReportValidateBeforeCall(requestParameters, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Represents the Request object for the DownloadReport API + * + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param reportId The unique ID for this report as returned in a GET /reports response. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) + */ + public class DownloadReportRequest { + private String avalaraVersion; + private String reportId; + private String xAvalaraClient; + private String xCorrelationID; + + public DownloadReportRequest () { + } + + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } + public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } + public String getReportId() { return reportId; } + public void setReportId(String reportId) { this.reportId = reportId; } + public String getXAvalaraClient() { return xAvalaraClient; } + public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } + public String getXCorrelationID() { return xCorrelationID; } + public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } + } + + /** + * Getter function to instantiate Request class + * @returns DownloadReportRequest + */ + public DownloadReportRequest getDownloadReportRequest() { + return this.new DownloadReportRequest(); + } + + /** + * Build call for getReportById + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 Report found and returned successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found. -
+ */ + public okhttp3.Call getReportByIdCall(GetReportByIdRequest requestParameters, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + //OAuth2 Scopes + String requiredScopes = ""; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/einvoicing/reports/{reportId}/status" + .replaceAll("\\{" + "reportId" + "\\}", localVarApiClient.escapeString(requestParameters.reportId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (requestParameters.getAvalaraVersion() != null) { + localVarHeaderParams.put("avalara-version", localVarApiClient.parameterToString(requestParameters.getAvalaraVersion())); + } + + if (requestParameters.getXAvalaraClient() != null) { + localVarHeaderParams.put("X-Avalara-Client", localVarApiClient.parameterToString(requestParameters.getXAvalaraClient())); + } + + if (requestParameters.getXCorrelationID() != null) { + localVarHeaderParams.put("X-Correlation-ID", localVarApiClient.parameterToString(requestParameters.getXCorrelationID())); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null && !localVarHeaderParams.containsKey("Accept")) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + String[] localVarAuthNames = new String[] { "OAuth", "Bearer" }; + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, requiredScopes, AvalaraMicroservice.EInvoicing); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getReportByIdValidateBeforeCall(GetReportByIdRequest requestParameters, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'requestParameters.avalaraVersion' is set + if (requestParameters.getAvalaraVersion() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.avalaraVersion' when calling getReportById(Async)"); + } + + // verify the required parameter 'requestParameters.reportId' is set + if (requestParameters.getReportId() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.reportId' when calling getReportById(Async)"); + } + + + okhttp3.Call localVarCall = getReportByIdCall(requestParameters, _callback); + return localVarCall; + + } + + /** + * Retrieves a report by its unique ID + * Retrieves a specific report by its unique identifier. Returns complete report details including metadata, status, and associated information. + * @param requestOptions Object which represents the options available for a given API/request + * @return ReportItem + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 Report found and returned successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found. -
+ */ + public ReportItem getReportById(GetReportByIdRequest requestParameters) throws ApiException { + ApiResponse localVarResp = getReportByIdWithHttpInfo(requestParameters); + return localVarResp.getData(); + } + + /** + * Retrieves a report by its unique ID + * Retrieves a specific report by its unique identifier. Returns complete report details including metadata, status, and associated information. + * @param requestOptions Object which represents the options available for a given API/request + * @return ApiResponse<ReportItem> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 Report found and returned successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found. -
+ */ + public ApiResponse getReportByIdWithHttpInfo(GetReportByIdRequest requestParameters) throws ApiException { + okhttp3.Call localVarCall = getReportByIdValidateBeforeCall(requestParameters, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Retrieves a report by its unique ID (asynchronously) + * Retrieves a specific report by its unique identifier. Returns complete report details including metadata, status, and associated information. + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + + +
Status Code Description Response Headers
200 Report found and returned successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
404 Report not found. -
+ */ + public okhttp3.Call getReportByIdAsync(GetReportByIdRequest requestParameters, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getReportByIdValidateBeforeCall(requestParameters, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Represents the Request object for the GetReportById API + * + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param reportId The unique ID for this report as returned in a GET /reports response. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) + */ + public class GetReportByIdRequest { + private String avalaraVersion; + private String reportId; + private String xAvalaraClient; + private String xCorrelationID; + + public GetReportByIdRequest () { + } + + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } + public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } + public String getReportId() { return reportId; } + public void setReportId(String reportId) { this.reportId = reportId; } + public String getXAvalaraClient() { return xAvalaraClient; } + public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } + public String getXCorrelationID() { return xCorrelationID; } + public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } + } + + /** + * Getter function to instantiate Request class + * @returns GetReportByIdRequest + */ + public GetReportByIdRequest getGetReportByIdRequest() { + return this.new GetReportByIdRequest(); + } + + /** + * Build call for getReports + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Reports retrieved successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public okhttp3.Call getReportsCall(GetReportsRequest requestParameters, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + //OAuth2 Scopes + String requiredScopes = ""; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/einvoicing/reports"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (requestParameters.get$filter() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$filter", requestParameters.get$filter())); + } + + if (requestParameters.get$top() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$top", requestParameters.get$top())); + } + + if (requestParameters.get$skip() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$skip", requestParameters.get$skip())); + } + + if (requestParameters.get$count() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$count", requestParameters.get$count())); + } + + if (requestParameters.get$countOnly() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$countOnly", requestParameters.get$countOnly())); + } + + if (requestParameters.get$orderby() != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("$orderby", requestParameters.get$orderby())); + } + + if (requestParameters.getAvalaraVersion() != null) { + localVarHeaderParams.put("avalara-version", localVarApiClient.parameterToString(requestParameters.getAvalaraVersion())); + } + + if (requestParameters.getXAvalaraClient() != null) { + localVarHeaderParams.put("X-Avalara-Client", localVarApiClient.parameterToString(requestParameters.getXAvalaraClient())); + } + + if (requestParameters.getXCorrelationID() != null) { + localVarHeaderParams.put("X-Correlation-ID", localVarApiClient.parameterToString(requestParameters.getXCorrelationID())); + } + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null && !localVarHeaderParams.containsKey("Accept")) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + String[] localVarAuthNames = new String[] { "OAuth", "Bearer" }; + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback, requiredScopes, AvalaraMicroservice.EInvoicing); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call getReportsValidateBeforeCall(GetReportsRequest requestParameters, final ApiCallback _callback) throws ApiException { + + // verify the required parameter 'requestParameters.avalaraVersion' is set + if (requestParameters.getAvalaraVersion() == null) { + throw new ApiException("Missing the required parameter 'requestParameters.avalaraVersion' when calling getReports(Async)"); + } + + + okhttp3.Call localVarCall = getReportsCall(requestParameters, _callback); + return localVarCall; + + } + + /** + * Returns a list of reports + * Retrieves all reports with optional filtering, paging, and sorting. Results are filtered by tenant. Supports OData-style filtering using the $filter parameter. Use $top and $skip for paging; when more results exist, the response includes @nextLink to fetch the next page. Default sort order is by report generation date (descending). + * @param requestOptions Object which represents the options available for a given API/request + * @return ReportListResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Reports retrieved successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public ReportListResponse getReports(GetReportsRequest requestParameters) throws ApiException { + ApiResponse localVarResp = getReportsWithHttpInfo(requestParameters); + return localVarResp.getData(); + } + + /** + * Returns a list of reports + * Retrieves all reports with optional filtering, paging, and sorting. Results are filtered by tenant. Supports OData-style filtering using the $filter parameter. Use $top and $skip for paging; when more results exist, the response includes @nextLink to fetch the next page. Default sort order is by report generation date (descending). + * @param requestOptions Object which represents the options available for a given API/request + * @return ApiResponse<ReportListResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Reports retrieved successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public ApiResponse getReportsWithHttpInfo(GetReportsRequest requestParameters) throws ApiException { + okhttp3.Call localVarCall = getReportsValidateBeforeCall(requestParameters, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Returns a list of reports (asynchronously) + * Retrieves all reports with optional filtering, paging, and sorting. Results are filtered by tenant. Supports OData-style filtering using the $filter parameter. Use $top and $skip for paging; when more results exist, the response includes @nextLink to fetch the next page. Default sort order is by report generation date (descending). + * @param requestOptions Object which represents the options available for a given API/request + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + * @http.response.details + + + + + + +
Status Code Description Response Headers
200 Reports retrieved successfully. -
400 Bad request. -
401 Unauthorized. -
403 Forbidden. -
+ */ + public okhttp3.Call getReportsAsync(GetReportsRequest requestParameters, final ApiCallback _callback) throws ApiException { + + okhttp3.Call localVarCall = getReportsValidateBeforeCall(requestParameters, _callback); + Type localVarReturnType = new TypeToken(){}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + /** + * Represents the Request object for the GetReports API + * + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) + * @param $filter OData-style filter expression. Supports operators: eq, ne, gt, ge, lt, le, like, ilike, contains. Examples: status eq 'COMPLETED', reportGenerateDate gt '2025-11-01', transactionIds contains 'TXN-2025-001' (optional) + * @param $top The number of items to include in the result. (optional) + * @param $skip The number of items to skip in the result. (optional) + * @param $count When set to true, the response body also includes the count of items in the collection. (optional) + * @param $countOnly When set to true, the response returns only the count of items in the collection. (optional) + * @param $orderby OData-style orderby expression. Format: 'field asc' or 'field desc'. Default: reportGenerateDate desc (optional, default to reportGenerateDate desc) + */ + public class GetReportsRequest { + private String avalaraVersion; + private String xAvalaraClient; + private String xCorrelationID; + private String $filter; + private Integer $top; + private Integer $skip; + private String $count; + private String $countOnly; + private String $orderby; + + public GetReportsRequest () { + } + + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } + public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } + public String getXAvalaraClient() { return xAvalaraClient; } + public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } + public String getXCorrelationID() { return xCorrelationID; } + public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } + public String get$filter() { return $filter; } + public void set$filter(String $filter) { this.$filter = $filter; } + public Integer get$top() { return $top; } + public void set$top(Integer $top) { this.$top = $top; } + public Integer get$skip() { return $skip; } + public void set$skip(Integer $skip) { this.$skip = $skip; } + public String get$count() { return $count; } + public void set$count(String $count) { this.$count = $count; } + public String get$countOnly() { return $countOnly; } + public void set$countOnly(String $countOnly) { this.$countOnly = $countOnly; } + public String get$orderby() { return $orderby; } + public void set$orderby(String $orderby) { this.$orderby = $orderby; } + } + + /** + * Getter function to instantiate Request class + * @returns GetReportsRequest + */ + public GetReportsRequest getGetReportsRequest() { + return this.new GetReportsRequest(); + } + + private void SetConfiguration(ApiClient client) { + if (client == null) throw new MissingFormatArgumentException("client"); + this.localVarApiClient.setSdkVersion("26.4.0"); + } +} + diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/SubscriptionsApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/SubscriptionsApi.java index afb6e14..1304a0a 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/SubscriptionsApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/SubscriptionsApi.java @@ -87,10 +87,10 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Subscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Invalid input * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
201 Subscription created successfully. Returns the created SubscriptionDetail object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Bad request. The request payload is invalid or contains missing required fields. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call createWebhookSubscriptionCall(CreateWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -174,17 +174,17 @@ private okhttp3.Call createWebhookSubscriptionValidateBeforeCall(CreateWebhookSu /** * Create a subscription to events - * Create a subscription to events exposed by registered systems. + * Create a new webhook subscription and return the created subscription details. * @param requestOptions Object which represents the options available for a given API/request * @return SuccessResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Subscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Invalid input * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
201 Subscription created successfully. Returns the created SubscriptionDetail object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Bad request. The request payload is invalid or contains missing required fields. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public SuccessResponse createWebhookSubscription(CreateWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -194,17 +194,17 @@ public SuccessResponse createWebhookSubscription(CreateWebhookSubscriptionReques /** * Create a subscription to events - * Create a subscription to events exposed by registered systems. + * Create a new webhook subscription and return the created subscription details. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<SuccessResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Subscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Invalid input * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
201 Subscription created successfully. Returns the created SubscriptionDetail object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Bad request. The request payload is invalid or contains missing required fields. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public ApiResponse createWebhookSubscriptionWithHttpInfo(CreateWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -215,7 +215,7 @@ public ApiResponse createWebhookSubscriptionWithHttpInfo(Create /** * Create a subscription to events (asynchronously) - * Create a subscription to events exposed by registered systems. + * Create a new webhook subscription and return the created subscription details. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -223,10 +223,10 @@ public ApiResponse createWebhookSubscriptionWithHttpInfo(Create * @http.response.details - - - - + + + +
Status Code Description Response Headers
201 Subscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Invalid input * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
201 Subscription created successfully. Returns the created SubscriptionDetail object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
400 Bad request. The request payload is invalid or contains missing required fields. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call createWebhookSubscriptionAsync(CreateWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -239,7 +239,7 @@ public okhttp3.Call createWebhookSubscriptionAsync(CreateWebhookSubscriptionRequ /** * Represents the Request object for the CreateWebhookSubscription API * - * @param avalaraVersion The version of the API to use, e.g., \"1.4\". + * @param avalaraVersion The version of the API to use, e.g., \"1.6\". * @param subscriptionRegistration * @param xCorrelationID A unique identifier for tracking the request and its response (optional) * @param xAvalaraClient Client application identification (optional) @@ -253,7 +253,7 @@ public class CreateWebhookSubscriptionRequest { public CreateWebhookSubscriptionRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public SubscriptionRegistration getSubscriptionRegistration() { return subscriptionRegistration; } public void setSubscriptionRegistration(SubscriptionRegistration subscriptionRegistration) { this.subscriptionRegistration = subscriptionRegistration; } @@ -280,10 +280,10 @@ public CreateWebhookSubscriptionRequest getCreateWebhookSubscriptionRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
204 Unsubscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
204 Subscription deleted successfully. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call deleteWebhookSubscriptionCall(DeleteWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -307,8 +307,8 @@ public okhttp3.Call deleteWebhookSubscriptionCall(DeleteWebhookSubscriptionReque Object localVarPostBody = null; // create path and map variables - String localVarPath = "/einvoicing/webhooks/subscriptions/{subscription-id}" - .replaceAll("\\{" + "subscription-id" + "\\}", localVarApiClient.escapeString(requestParameters.subscriptionId.toString())); + String localVarPath = "/einvoicing/webhooks/subscriptions/{subscriptionId}" + .replaceAll("\\{" + "subscriptionId" + "\\}", localVarApiClient.escapeString(requestParameters.subscriptionId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -368,16 +368,16 @@ private okhttp3.Call deleteWebhookSubscriptionValidateBeforeCall(DeleteWebhookSu /** * Unsubscribe from events - * Remove a subscription from the webhooks dispatch service. All events and subscriptions are also deleted. + * Delete the specified webhook subscription. * @param requestOptions Object which represents the options available for a given API/request * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
204 Unsubscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
204 Subscription deleted successfully. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public void deleteWebhookSubscription(DeleteWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -386,17 +386,17 @@ public void deleteWebhookSubscription(DeleteWebhookSubscriptionRequest requestPa /** * Unsubscribe from events - * Remove a subscription from the webhooks dispatch service. All events and subscriptions are also deleted. + * Delete the specified webhook subscription. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
204 Unsubscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
204 Subscription deleted successfully. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public ApiResponse deleteWebhookSubscriptionWithHttpInfo(DeleteWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -406,7 +406,7 @@ public ApiResponse deleteWebhookSubscriptionWithHttpInfo(DeleteWebhookSubs /** * Unsubscribe from events (asynchronously) - * Remove a subscription from the webhooks dispatch service. All events and subscriptions are also deleted. + * Delete the specified webhook subscription. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -414,10 +414,10 @@ public ApiResponse deleteWebhookSubscriptionWithHttpInfo(DeleteWebhookSubs * @http.response.details - - - - + + + +
Status Code Description Response Headers
204 Unsubscribed successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
204 Subscription deleted successfully. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call deleteWebhookSubscriptionAsync(DeleteWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -429,8 +429,8 @@ public okhttp3.Call deleteWebhookSubscriptionAsync(DeleteWebhookSubscriptionRequ /** * Represents the Request object for the DeleteWebhookSubscription API * - * @param subscriptionId - * @param avalaraVersion The version of the API to use, e.g., \"1.4\". + * @param subscriptionId Unique identifier of the subscription. + * @param avalaraVersion The version of the API to use, e.g., \"1.6\". * @param xCorrelationID A unique identifier for tracking the request and its response (optional) * @param xAvalaraClient Client application identification (optional) */ @@ -445,7 +445,7 @@ public DeleteWebhookSubscriptionRequest () { public String getSubscriptionId() { return subscriptionId; } public void setSubscriptionId(String subscriptionId) { this.subscriptionId = subscriptionId; } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXCorrelationID() { return xCorrelationID; } public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } @@ -470,10 +470,10 @@ public DeleteWebhookSubscriptionRequest getDeleteWebhookSubscriptionRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Subscription details retrieved successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns the SubscriptionDetail object for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call getWebhookSubscriptionCall(GetWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -497,8 +497,8 @@ public okhttp3.Call getWebhookSubscriptionCall(GetWebhookSubscriptionRequest req Object localVarPostBody = null; // create path and map variables - String localVarPath = "/einvoicing/webhooks/subscriptions/{subscription-id}" - .replaceAll("\\{" + "subscription-id" + "\\}", localVarApiClient.escapeString(requestParameters.subscriptionId.toString())); + String localVarPath = "/einvoicing/webhooks/subscriptions/{subscriptionId}" + .replaceAll("\\{" + "subscriptionId" + "\\}", localVarApiClient.escapeString(requestParameters.subscriptionId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -565,10 +565,10 @@ private okhttp3.Call getWebhookSubscriptionValidateBeforeCall(GetWebhookSubscrip * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Subscription details retrieved successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns the SubscriptionDetail object for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public SubscriptionDetail getWebhookSubscription(GetWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -585,10 +585,10 @@ public SubscriptionDetail getWebhookSubscription(GetWebhookSubscriptionRequest r * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Subscription details retrieved successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns the SubscriptionDetail object for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public ApiResponse getWebhookSubscriptionWithHttpInfo(GetWebhookSubscriptionRequest requestParameters) throws ApiException { @@ -607,10 +607,10 @@ public ApiResponse getWebhookSubscriptionWithHttpInfo(GetWeb * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 Subscription details retrieved successfully * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns the SubscriptionDetail object for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
404 Subscription not found for the specified subscriptionId. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call getWebhookSubscriptionAsync(GetWebhookSubscriptionRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -623,8 +623,8 @@ public okhttp3.Call getWebhookSubscriptionAsync(GetWebhookSubscriptionRequest re /** * Represents the Request object for the GetWebhookSubscription API * - * @param subscriptionId - * @param avalaraVersion The version of the API to use, e.g., \"1.4\". + * @param subscriptionId Unique identifier of the subscription. + * @param avalaraVersion The version of the API to use, e.g., \"1.6\". * @param xCorrelationID A unique identifier for tracking the request and its response (optional) * @param xAvalaraClient Client application identification (optional) */ @@ -639,7 +639,7 @@ public GetWebhookSubscriptionRequest () { public String getSubscriptionId() { return subscriptionId; } public void setSubscriptionId(String subscriptionId) { this.subscriptionId = subscriptionId; } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXCorrelationID() { return xCorrelationID; } public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } @@ -664,10 +664,10 @@ public GetWebhookSubscriptionRequest getGetWebhookSubscriptionRequest() { * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 A list of subscriptions * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns a list of webhook subscriptions in a SubscriptionListResponse object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call listWebhookSubscriptionsCall(ListWebhookSubscriptionsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -762,17 +762,17 @@ private okhttp3.Call listWebhookSubscriptionsValidateBeforeCall(ListWebhookSubsc /** * List all subscriptions - * Retrieve a list of all subscriptions. + * Retrieve a list of webhook subscriptions. * @param requestOptions Object which represents the options available for a given API/request * @return SubscriptionListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 A list of subscriptions * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns a list of webhook subscriptions in a SubscriptionListResponse object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public SubscriptionListResponse listWebhookSubscriptions(ListWebhookSubscriptionsRequest requestParameters) throws ApiException { @@ -782,17 +782,17 @@ public SubscriptionListResponse listWebhookSubscriptions(ListWebhookSubscription /** * List all subscriptions - * Retrieve a list of all subscriptions. + * Retrieve a list of webhook subscriptions. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<SubscriptionListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 A list of subscriptions * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns a list of webhook subscriptions in a SubscriptionListResponse object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public ApiResponse listWebhookSubscriptionsWithHttpInfo(ListWebhookSubscriptionsRequest requestParameters) throws ApiException { @@ -803,7 +803,7 @@ public ApiResponse listWebhookSubscriptionsWithHttpInf /** * List all subscriptions (asynchronously) - * Retrieve a list of all subscriptions. + * Retrieve a list of webhook subscriptions. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -811,10 +811,10 @@ public ApiResponse listWebhookSubscriptionsWithHttpInf * @http.response.details - - - - + + + +
Status Code Description Response Headers
200 A list of subscriptions * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Not authenticated * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Access token does not have the required scope * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
200 Returns a list of webhook subscriptions in a SubscriptionListResponse object. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
401 Unauthorized. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
403 Forbidden. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
500 Internal server error. * X-Correlation-ID - Correlation ID from the request, or a new one if not provided in request
*/ public okhttp3.Call listWebhookSubscriptionsAsync(ListWebhookSubscriptionsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -827,7 +827,7 @@ public okhttp3.Call listWebhookSubscriptionsAsync(ListWebhookSubscriptionsReques /** * Represents the Request object for the ListWebhookSubscriptions API * - * @param avalaraVersion The version of the API to use, e.g., \"1.4\". + * @param avalaraVersion The version of the API to use, e.g., \"1.6\". * @param xCorrelationID A unique identifier for tracking the request and its response (optional) * @param xAvalaraClient Client application identification (optional) * @param $top The number of items to include in the result. (optional) @@ -847,7 +847,7 @@ public class ListWebhookSubscriptionsRequest { public ListWebhookSubscriptionsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXCorrelationID() { return xCorrelationID; } public void setXCorrelationID(String xCorrelationID) { this.xCorrelationID = xCorrelationID; } @@ -873,7 +873,7 @@ public ListWebhookSubscriptionsRequest getListWebhookSubscriptionsRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/TaxIdentifiersApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/TaxIdentifiersApi.java index fa2c331..6ebb177 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/TaxIdentifiersApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/TaxIdentifiersApi.java @@ -86,11 +86,11 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns an object containing countryCode, schemaType, and schema. The schema property contains a JSON Schema (Draft-07) used to validate tax identifier requests or responses for the specified country. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call taxIdentifierSchemaByCountryCall(TaxIdentifierSchemaByCountryRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -181,19 +181,19 @@ private okhttp3.Call taxIdentifierSchemaByCountryValidateBeforeCall(TaxIdentifie } /** - * Returns the tax identifier request & response schema for a specific country. - * This endpoint retrieves the request and response schema required to validate tax identifiers based on a specific country's requirements. This can include both standard fields and any additional parameters required by the respective country's tax authority. + * Returns the tax identifier request and response schema for a specific country. + * Returns the tax identifier request and response schema for a specific country. * @param requestOptions Object which represents the options available for a given API/request * @return TaxIdentifierSchemaByCountry200Response * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns an object containing countryCode, schemaType, and schema. The schema property contains a JSON Schema (Draft-07) used to validate tax identifier requests or responses for the specified country. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public TaxIdentifierSchemaByCountry200Response taxIdentifierSchemaByCountry(TaxIdentifierSchemaByCountryRequest requestParameters) throws ApiException { @@ -202,19 +202,19 @@ public TaxIdentifierSchemaByCountry200Response taxIdentifierSchemaByCountry(TaxI } /** - * Returns the tax identifier request & response schema for a specific country. - * This endpoint retrieves the request and response schema required to validate tax identifiers based on a specific country's requirements. This can include both standard fields and any additional parameters required by the respective country's tax authority. + * Returns the tax identifier request and response schema for a specific country. + * Returns the tax identifier request and response schema for a specific country. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<TaxIdentifierSchemaByCountry200Response> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns an object containing countryCode, schemaType, and schema. The schema property contains a JSON Schema (Draft-07) used to validate tax identifier requests or responses for the specified country. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse taxIdentifierSchemaByCountryWithHttpInfo(TaxIdentifierSchemaByCountryRequest requestParameters) throws ApiException { @@ -224,8 +224,8 @@ public ApiResponse taxIdentifierSchemaB } /** - * Returns the tax identifier request & response schema for a specific country. (asynchronously) - * This endpoint retrieves the request and response schema required to validate tax identifiers based on a specific country's requirements. This can include both standard fields and any additional parameters required by the respective country's tax authority. + * Returns the tax identifier request and response schema for a specific country. (asynchronously) + * Returns the tax identifier request and response schema for a specific country. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -233,11 +233,11 @@ public ApiResponse taxIdentifierSchemaB * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns an object containing countryCode, schemaType, and schema. The schema property contains a JSON Schema (Draft-07) used to validate tax identifier requests or responses for the specified country. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call taxIdentifierSchemaByCountryAsync(TaxIdentifierSchemaByCountryRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -250,11 +250,11 @@ public okhttp3.Call taxIdentifierSchemaByCountryAsync(TaxIdentifierSchemaByCount /** * Represents the Request object for the TaxIdentifierSchemaByCountry API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param countryCode The two-letter ISO-3166 country code for which the schema should be retrieved. - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) - * @param type Specifies whether to return the request or response schema. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param countryCode Two-letter ISO 3166 country code for which to retrieve the schema (for example \"DE\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) + * @param type Specifies which schema to return: \"request\" to receive the request validation schema or \"response\" to receive the response validation schema. (optional) */ public class TaxIdentifierSchemaByCountryRequest { private String avalaraVersion; @@ -266,7 +266,7 @@ public class TaxIdentifierSchemaByCountryRequest { public TaxIdentifierSchemaByCountryRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getCountryCode() { return countryCode; } public void setCountryCode(String countryCode) { this.countryCode = countryCode; } @@ -295,12 +295,12 @@ public TaxIdentifierSchemaByCountryRequest getTaxIdentifierSchemaByCountryReques * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
200 Success response. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
429 Rate limit exceeded * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Validation completed. Returns a TaxIdentifierResponse object that includes countryCode and a value object with identifierType, identifier, and optional extensions when available. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
429 Rate limit exceeded. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call validateTaxIdentifierCall(ValidateTaxIdentifierRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -391,12 +391,12 @@ private okhttp3.Call validateTaxIdentifierValidateBeforeCall(ValidateTaxIdentifi * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
200 Success response. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
429 Rate limit exceeded * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Validation completed. Returns a TaxIdentifierResponse object that includes countryCode and a value object with identifierType, identifier, and optional extensions when available. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
429 Rate limit exceeded. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public TaxIdentifierResponse validateTaxIdentifier(ValidateTaxIdentifierRequest requestParameters) throws ApiException { @@ -413,12 +413,12 @@ public TaxIdentifierResponse validateTaxIdentifier(ValidateTaxIdentifierRequest * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
200 Success response. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
429 Rate limit exceeded * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Validation completed. Returns a TaxIdentifierResponse object that includes countryCode and a value object with identifierType, identifier, and optional extensions when available. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
429 Rate limit exceeded. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse validateTaxIdentifierWithHttpInfo(ValidateTaxIdentifierRequest requestParameters) throws ApiException { @@ -437,12 +437,12 @@ public ApiResponse validateTaxIdentifierWithHttpInfo(Vali * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
200 Success response. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
429 Rate limit exceeded * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Validation completed. Returns a TaxIdentifierResponse object that includes countryCode and a value object with identifierType, identifier, and optional extensions when available. * X-Correlation-ID -
400 Bad request. The request is invalid or contains missing or incorrect parameters. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
429 Rate limit exceeded. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call validateTaxIdentifierAsync(ValidateTaxIdentifierRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -455,10 +455,10 @@ public okhttp3.Call validateTaxIdentifierAsync(ValidateTaxIdentifierRequest requ /** * Represents the Request object for the ValidateTaxIdentifier API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). * @param taxIdentifierRequest - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class ValidateTaxIdentifierRequest { private String avalaraVersion; @@ -469,7 +469,7 @@ public class ValidateTaxIdentifierRequest { public ValidateTaxIdentifierRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public TaxIdentifierRequest getTaxIdentifierRequest() { return taxIdentifierRequest; } public void setTaxIdentifierRequest(TaxIdentifierRequest taxIdentifierRequest) { this.taxIdentifierRequest = taxIdentifierRequest; } @@ -489,7 +489,7 @@ public ValidateTaxIdentifierRequest getValidateTaxIdentifierRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/EInvoicing/V1/TradingPartnersApi.java b/src/main/java/Avalara/SDK/api/EInvoicing/V1/TradingPartnersApi.java index c7c3f09..336089e 100644 --- a/src/main/java/Avalara/SDK/api/EInvoicing/V1/TradingPartnersApi.java +++ b/src/main/java/Avalara/SDK/api/EInvoicing/V1/TradingPartnersApi.java @@ -93,11 +93,11 @@ public void setCustomBaseUrl(String customBaseUrl) { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Batch search file accepted for processing the search. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Batch search file accepted for processing the search. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call batchSearchParticipantsCall(BatchSearchParticipantsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -210,11 +210,11 @@ private okhttp3.Call batchSearchParticipantsValidateBeforeCall(BatchSearchPartic * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Batch search file accepted for processing the search. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Batch search file accepted for processing the search. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public BatchSearchParticipants202Response batchSearchParticipants(BatchSearchParticipantsRequest requestParameters) throws ApiException { @@ -231,11 +231,11 @@ public BatchSearchParticipants202Response batchSearchParticipants(BatchSearchPar * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Batch search file accepted for processing the search. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Batch search file accepted for processing the search. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse batchSearchParticipantsWithHttpInfo(BatchSearchParticipantsRequest requestParameters) throws ApiException { @@ -254,11 +254,11 @@ public ApiResponse batchSearchParticipantsWi * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
202 Batch search file accepted for processing the search. * X-Correlation-Id -
400 Invalid request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
202 Batch search file accepted for processing the search. * X-Correlation-ID -
400 Invalid request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call batchSearchParticipantsAsync(BatchSearchParticipantsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -271,12 +271,12 @@ public okhttp3.Call batchSearchParticipantsAsync(BatchSearchParticipantsRequest /** * Represents the Request object for the BatchSearchParticipants API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param name A human-readable name for the batch search. + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param name A human-readable name for the batch search. * @param notificationEmail The email address to which a notification will be sent once the batch search is complete. * @param _file CSV file containing search parameters. Input Constraints: - Maximum file size: 1 MB - File Header: Must be less than 500 KB - Total number of lines (including header): Must be 101 or fewer - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class BatchSearchParticipantsRequest { private String avalaraVersion; @@ -289,7 +289,7 @@ public class BatchSearchParticipantsRequest { public BatchSearchParticipantsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getName() { return name; } public void setName(String name) { this.name = name; } @@ -320,12 +320,12 @@ public BatchSearchParticipantsRequest getBatchSearchParticipantsRequest() { * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
201 The trading partner has been successfully created. * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
201 The trading partner has been successfully created. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call createTradingPartnerCall(CreateTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -416,12 +416,12 @@ private okhttp3.Call createTradingPartnerValidateBeforeCall(CreateTradingPartner * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
201 The trading partner has been successfully created. * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
201 The trading partner has been successfully created. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public CreateTradingPartner201Response createTradingPartner(CreateTradingPartnerRequest requestParameters) throws ApiException { @@ -438,12 +438,12 @@ public CreateTradingPartner201Response createTradingPartner(CreateTradingPartner * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
201 The trading partner has been successfully created. * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
201 The trading partner has been successfully created. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse createTradingPartnerWithHttpInfo(CreateTradingPartnerRequest requestParameters) throws ApiException { @@ -462,12 +462,12 @@ public ApiResponse createTradingPartnerWithHttp * @http.response.details - - - - - - + + + + + +
Status Code Description Response Headers
201 The trading partner has been successfully created. * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
201 The trading partner has been successfully created. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call createTradingPartnerAsync(CreateTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -480,10 +480,10 @@ public okhttp3.Call createTradingPartnerAsync(CreateTradingPartnerRequest reques /** * Represents the Request object for the CreateTradingPartner API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). * @param tradingPartner - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class CreateTradingPartnerRequest { private String avalaraVersion; @@ -494,7 +494,7 @@ public class CreateTradingPartnerRequest { public CreateTradingPartnerRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public TradingPartner getTradingPartner() { return tradingPartner; } public void setTradingPartner(TradingPartner tradingPartner) { this.tradingPartner = tradingPartner; } @@ -521,13 +521,13 @@ public CreateTradingPartnerRequest getCreateTradingPartnerRequest() { * @http.response.details - - - - - - - + + + + + + +
Status Code Description Response Headers
200 Batch processing completed * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
413 ContentTooLarge * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Batch processing completed. Returns a list of created trading partners. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
413 ContentTooLarge * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public okhttp3.Call createTradingPartnersBatchCall(CreateTradingPartnersBatchRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -611,20 +611,20 @@ private okhttp3.Call createTradingPartnersBatchValidateBeforeCall(CreateTradingP /** * Creates a batch of multiple trading partners. - * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or 1 MB request payload. The batch is processed atomically and partial success is not allowed. + * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or a 1 MB request payload. * @param requestOptions Object which represents the options available for a given API/request * @return CreateTradingPartnersBatch200Response * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - - - + + + + + + +
Status Code Description Response Headers
200 Batch processing completed * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
413 ContentTooLarge * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Batch processing completed. Returns a list of created trading partners. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
413 ContentTooLarge * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public CreateTradingPartnersBatch200Response createTradingPartnersBatch(CreateTradingPartnersBatchRequest requestParameters) throws ApiException { @@ -634,20 +634,20 @@ public CreateTradingPartnersBatch200Response createTradingPartnersBatch(CreateTr /** * Creates a batch of multiple trading partners. - * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or 1 MB request payload. The batch is processed atomically and partial success is not allowed. + * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or a 1 MB request payload. * @param requestOptions Object which represents the options available for a given API/request * @return ApiResponse<CreateTradingPartnersBatch200Response> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body * @http.response.details - - - - - - - + + + + + + +
Status Code Description Response Headers
200 Batch processing completed * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
413 ContentTooLarge * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Batch processing completed. Returns a list of created trading partners. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
413 ContentTooLarge * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public ApiResponse createTradingPartnersBatchWithHttpInfo(CreateTradingPartnersBatchRequest requestParameters) throws ApiException { @@ -658,7 +658,7 @@ public ApiResponse createTradingPartnersB /** * Creates a batch of multiple trading partners. (asynchronously) - * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or 1 MB request payload. The batch is processed atomically and partial success is not allowed. + * This endpoint creates multiple trading partners in a single batch request. It accepts an array of trading partners and processes them synchronously. Supports a maximum of 100 records or a 1 MB request payload. * @param requestOptions Object which represents the options available for a given API/request * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -666,13 +666,13 @@ public ApiResponse createTradingPartnersB * @http.response.details - - - - - - - + + + + + + +
Status Code Description Response Headers
200 Batch processing completed * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
413 ContentTooLarge * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Batch processing completed. Returns a list of created trading partners. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
413 ContentTooLarge * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public okhttp3.Call createTradingPartnersBatchAsync(CreateTradingPartnersBatchRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -685,10 +685,10 @@ public okhttp3.Call createTradingPartnersBatchAsync(CreateTradingPartnersBatchRe /** * Represents the Request object for the CreateTradingPartnersBatch API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). * @param createTradingPartnersBatchRequest - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class CreateTradingPartnersBatchRequest { private String avalaraVersion; @@ -699,7 +699,7 @@ public class CreateTradingPartnersBatchRequest { public CreateTradingPartnersBatchRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public CreateTradingPartnersBatchRequest getCreateTradingPartnersBatchRequest() { return createTradingPartnersBatchRequest; } public void setCreateTradingPartnersBatchRequest(CreateTradingPartnersBatchRequest createTradingPartnersBatchRequest) { this.createTradingPartnersBatchRequest = createTradingPartnersBatchRequest; } @@ -726,11 +726,11 @@ public CreateTradingPartnersBatchRequest getCreateTradingPartnersBatchRequest() * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
204 Trading partner deleted successfully. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
204 Trading partner deleted successfully. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public okhttp3.Call deleteTradingPartnerCall(DeleteTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -821,11 +821,11 @@ private okhttp3.Call deleteTradingPartnerValidateBeforeCall(DeleteTradingPartner * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
204 Trading partner deleted successfully. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
204 Trading partner deleted successfully. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public void deleteTradingPartner(DeleteTradingPartnerRequest requestParameters) throws ApiException { @@ -841,11 +841,11 @@ public void deleteTradingPartner(DeleteTradingPartnerRequest requestParameters) * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
204 Trading partner deleted successfully. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
204 Trading partner deleted successfully. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public ApiResponse deleteTradingPartnerWithHttpInfo(DeleteTradingPartnerRequest requestParameters) throws ApiException { @@ -863,11 +863,11 @@ public ApiResponse deleteTradingPartnerWithHttpInfo(DeleteTradingPartnerRe * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
204 Trading partner deleted successfully. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
204 Trading partner deleted successfully. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
500 Internal server error * X-Correlation-ID -
*/ public okhttp3.Call deleteTradingPartnerAsync(DeleteTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -879,10 +879,10 @@ public okhttp3.Call deleteTradingPartnerAsync(DeleteTradingPartnerRequest reques /** * Represents the Request object for the DeleteTradingPartner API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param id The ID of the trading partner which is being deleted. - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param id Unique identifier of the trading partner. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class DeleteTradingPartnerRequest { private String avalaraVersion; @@ -893,7 +893,7 @@ public class DeleteTradingPartnerRequest { public DeleteTradingPartnerRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getId() { return id; } public void setId(String id) { this.id = id; } @@ -920,11 +920,11 @@ public DeleteTradingPartnerRequest getDeleteTradingPartnerRequest() { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 Successful report download Output Constraints: - Maximum of 1000 query results returned in the CSV * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Successful report download. Returns a CSV file containing up to 1,000 query results. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call downloadBatchSearchReportCall(DownloadBatchSearchReportRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1016,11 +1016,11 @@ private okhttp3.Call downloadBatchSearchReportValidateBeforeCall(DownloadBatchSe * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 Successful report download Output Constraints: - Maximum of 1000 query results returned in the CSV * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Successful report download. Returns a CSV file containing up to 1,000 query results. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public File downloadBatchSearchReport(DownloadBatchSearchReportRequest requestParameters) throws ApiException { @@ -1037,11 +1037,11 @@ public File downloadBatchSearchReport(DownloadBatchSearchReportRequest requestPa * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 Successful report download Output Constraints: - Maximum of 1000 query results returned in the CSV * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Successful report download. Returns a CSV file containing up to 1,000 query results. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse downloadBatchSearchReportWithHttpInfo(DownloadBatchSearchReportRequest requestParameters) throws ApiException { @@ -1060,11 +1060,11 @@ public ApiResponse downloadBatchSearchReportWithHttpInfo(DownloadBatchSear * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 Successful report download Output Constraints: - Maximum of 1000 query results returned in the CSV * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Successful report download. Returns a CSV file containing up to 1,000 query results. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call downloadBatchSearchReportAsync(DownloadBatchSearchReportRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1077,10 +1077,10 @@ public okhttp3.Call downloadBatchSearchReportAsync(DownloadBatchSearchReportRequ /** * Represents the Request object for the DownloadBatchSearchReport API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param id The ID of the batch search for which the report should be downloaded. - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param id Unique identifier of the batch search for which to download the report. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class DownloadBatchSearchReportRequest { private String avalaraVersion; @@ -1091,7 +1091,7 @@ public class DownloadBatchSearchReportRequest { public DownloadBatchSearchReportRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getId() { return id; } public void setId(String id) { this.id = id; } @@ -1118,11 +1118,11 @@ public DownloadBatchSearchReportRequest getDownloadBatchSearchReportRequest() { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 The batch search details for a given ID. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns the batch search details for the specified ID. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call getBatchSearchDetailCall(GetBatchSearchDetailRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1214,11 +1214,11 @@ private okhttp3.Call getBatchSearchDetailValidateBeforeCall(GetBatchSearchDetail * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 The batch search details for a given ID. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns the batch search details for the specified ID. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public BatchSearch getBatchSearchDetail(GetBatchSearchDetailRequest requestParameters) throws ApiException { @@ -1235,11 +1235,11 @@ public BatchSearch getBatchSearchDetail(GetBatchSearchDetailRequest requestParam * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 The batch search details for a given ID. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns the batch search details for the specified ID. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse getBatchSearchDetailWithHttpInfo(GetBatchSearchDetailRequest requestParameters) throws ApiException { @@ -1258,11 +1258,11 @@ public ApiResponse getBatchSearchDetailWithHttpInfo(GetBatchSearchD * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 The batch search details for a given ID. * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 Report not found * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns the batch search details for the specified ID. * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 Report not found * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call getBatchSearchDetailAsync(GetBatchSearchDetailRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1275,10 +1275,10 @@ public okhttp3.Call getBatchSearchDetailAsync(GetBatchSearchDetailRequest reques /** * Represents the Request object for the GetBatchSearchDetail API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param id The ID of the batch search that was submitted earlier. - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param id Unique identifier of the batch search. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class GetBatchSearchDetailRequest { private String avalaraVersion; @@ -1289,7 +1289,7 @@ public class GetBatchSearchDetailRequest { public GetBatchSearchDetailRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getId() { return id; } public void setId(String id) { this.id = id; } @@ -1316,11 +1316,11 @@ public GetBatchSearchDetailRequest getGetBatchSearchDetailRequest() { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 List of batch searches * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of batch searches. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call listBatchSearchesCall(ListBatchSearchesRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1426,11 +1426,11 @@ private okhttp3.Call listBatchSearchesValidateBeforeCall(ListBatchSearchesReques * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 List of batch searches * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of batch searches. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public BatchSearchListResponse listBatchSearches(ListBatchSearchesRequest requestParameters) throws ApiException { @@ -1447,11 +1447,11 @@ public BatchSearchListResponse listBatchSearches(ListBatchSearchesRequest reques * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 List of batch searches * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of batch searches. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse listBatchSearchesWithHttpInfo(ListBatchSearchesRequest requestParameters) throws ApiException { @@ -1470,11 +1470,11 @@ public ApiResponse listBatchSearchesWithHttpInfo(ListBa * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 List of batch searches * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of batch searches. * X-Correlation-ID -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call listBatchSearchesAsync(ListBatchSearchesRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1487,14 +1487,14 @@ public okhttp3.Call listBatchSearchesAsync(ListBatchSearchesRequest requestParam /** * Represents the Request object for the ListBatchSearches API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param $filter Filters the results by field name. Only the eq operator and the name field is supported. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param $filter Filters the results by field name. Only the eq operator and the name field are supported. For more information, refer to the Avalara filtering guide. (optional) * @param count When set to true, returns the total count of matching records included as @recordSetCount in the response body. (optional) * @param $top The number of items to include in the result. (optional) * @param $skip The number of items to skip in the result. (optional) * @param $orderBy The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class ListBatchSearchesRequest { private String avalaraVersion; @@ -1509,7 +1509,7 @@ public class ListBatchSearchesRequest { public ListBatchSearchesRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getXAvalaraClient() { return xAvalaraClient; } public void setXAvalaraClient(String xAvalaraClient) { this.xAvalaraClient = xAvalaraClient; } @@ -1544,11 +1544,11 @@ public ListBatchSearchesRequest getListBatchSearchesRequest() { * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of trading partners matching the specified search criteria. * X-Correlation-ID -
400 Bad request. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call searchParticipantsCall(SearchParticipantsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1663,11 +1663,11 @@ private okhttp3.Call searchParticipantsValidateBeforeCall(SearchParticipantsRequ * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of trading partners matching the specified search criteria. * X-Correlation-ID -
400 Bad request. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public SearchParticipants200Response searchParticipants(SearchParticipantsRequest requestParameters) throws ApiException { @@ -1684,11 +1684,11 @@ public SearchParticipants200Response searchParticipants(SearchParticipantsReques * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of trading partners matching the specified search criteria. * X-Correlation-ID -
400 Bad request. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse searchParticipantsWithHttpInfo(SearchParticipantsRequest requestParameters) throws ApiException { @@ -1707,11 +1707,11 @@ public ApiResponse searchParticipantsWithHttpInfo * @http.response.details - - - - - + + + + +
Status Code Description Response Headers
200 OK * X-Correlation-Id -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
200 Returns a collection of trading partners matching the specified search criteria. * X-Correlation-ID -
400 Bad request. * X-Correlation-ID -
401 Unauthorized. * X-Correlation-ID -
403 Forbidden. * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call searchParticipantsAsync(SearchParticipantsRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1724,15 +1724,15 @@ public okhttp3.Call searchParticipantsAsync(SearchParticipantsRequest requestPar /** * Represents the Request object for the SearchParticipants API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param $search Search by value supports logical AND / OR operators. Search is performed only over the name and identifier value fields. For more information, refer to [Query options overview - OData.](https://learn.microsoft.com/en-us/odata/concepts/queryoptions-overview#search). - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param count When set to true, returns the total count of matching records included as @recordSetCount in the response body. (optional) - * @param $filter Filters the results using the eq operator. Supported fields: network, country, documentType, idType. For more information, refer to [AvaTax filtering guide](https://developer.avalara.com/avatax/filtering-in-rest/). (optional) + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param $search Search by value supports logical AND and OR operators (case-sensitive). Search is performed only over the name and identifier value fields. For more information, refer to the OData query options overview documentation. + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param count When set to true, returns the total count of matching records included as @recordSetCount in the response body. (optional) + * @param $filter Filters the results using the eq operator. Supported fields include network, country, documentType, and idType. For more information, refer to the Avalara filtering guide. (optional) * @param $top The number of items to include in the result. (optional) * @param $skip The number of items to skip in the result. (optional) - * @param $orderBy The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value is a string that combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param $orderBy The $orderBy query parameter specifies the field and sorting direction for ordering the result set. The value combines a field name and a sorting direction (asc for ascending or desc for descending), separated by a space. (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class SearchParticipantsRequest { private String avalaraVersion; @@ -1748,7 +1748,7 @@ public class SearchParticipantsRequest { public SearchParticipantsRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String get$search() { return $search; } public void set$search(String $search) { this.$search = $search; } @@ -1786,12 +1786,12 @@ public SearchParticipantsRequest getSearchParticipantsRequest() { - - - - - - + + + + + +
Status Code Description Response Headers
200 The trading partner has been successfully created. -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call updateTradingPartnerCall(UpdateTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1889,12 +1889,12 @@ private okhttp3.Call updateTradingPartnerValidateBeforeCall(UpdateTradingPartner - - - - - - + + + + + +
Status Code Description Response Headers
200 The trading partner has been successfully created. -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public UpdateTradingPartner200Response updateTradingPartner(UpdateTradingPartnerRequest requestParameters) throws ApiException { @@ -1912,12 +1912,12 @@ public UpdateTradingPartner200Response updateTradingPartner(UpdateTradingPartner - - - - - - + + + + + +
Status Code Description Response Headers
200 The trading partner has been successfully created. -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public ApiResponse updateTradingPartnerWithHttpInfo(UpdateTradingPartnerRequest requestParameters) throws ApiException { @@ -1937,12 +1937,12 @@ public ApiResponse updateTradingPartnerWithHttp - - - - - - + + + + + +
Status Code Description Response Headers
200 The trading partner has been successfully created. -
400 Bad request * X-Correlation-Id -
401 Unauthorized * X-Correlation-Id -
403 Forbidden * X-Correlation-Id -
404 NotFound * X-Correlation-Id -
409 Conflict * X-Correlation-Id -
500 Internal server error * X-Correlation-Id -
400 Bad request * X-Correlation-ID -
401 Unauthorized * X-Correlation-ID -
403 Forbidden * X-Correlation-ID -
404 NotFound * X-Correlation-ID -
409 Conflict * X-Correlation-ID -
500 Internal server error. * X-Correlation-ID -
*/ public okhttp3.Call updateTradingPartnerAsync(UpdateTradingPartnerRequest requestParameters, final ApiCallback _callback) throws ApiException { @@ -1955,11 +1955,11 @@ public okhttp3.Call updateTradingPartnerAsync(UpdateTradingPartnerRequest reques /** * Represents the Request object for the UpdateTradingPartner API * - * @param avalaraVersion The HTTP Header meant to specify the version of the API intended to be used. - * @param id The ID of the trading partner which is being updated. + * @param avalaraVersion Header that specifies the API version to use (for example \"1.6\"). + * @param id Unique identifier of the trading partner. * @param tradingPartner - * @param xAvalaraClient You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". (optional) - * @param xCorrelationID The caller can use this as an identifier to use as a correlation id to trace the call. (optional) + * @param xAvalaraClient Optional header for a client identifier string used for diagnostics (for example \"Fingerprint\"). (optional) + * @param xCorrelationID Optional correlation identifier provided by the caller to trace the call (for example \"f3f0d19a-01a1-4748-8a58-f000d0424f43\"). (optional) */ public class UpdateTradingPartnerRequest { private String avalaraVersion; @@ -1971,7 +1971,7 @@ public class UpdateTradingPartnerRequest { public UpdateTradingPartnerRequest () { } - public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.4"; } + public String getAvalaraVersion() { return (avalaraVersion != null) ? avalaraVersion : "1.6"; } public void setAvalaraVersion(String avalaraVersion) { this.avalaraVersion = avalaraVersion; } public String getId() { return id; } public void setId(String id) { this.id = id; } @@ -1993,7 +1993,7 @@ public UpdateTradingPartnerRequest getUpdateTradingPartnerRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListListResponse.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListListResponse.java new file mode 100644 index 0000000..6359e02 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListListResponse.java @@ -0,0 +1,308 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.CodeListSummary; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Returns the requested list of code lists + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class CodeListListResponse { + public static final String SERIALIZED_NAME_AT_RECORDSET_COUNT = "@recordsetCount"; + @SerializedName(SERIALIZED_NAME_AT_RECORDSET_COUNT) + private String atRecordsetCount; + + public static final String SERIALIZED_NAME_AT_NEXT_LINK = "@nextLink"; + @SerializedName(SERIALIZED_NAME_AT_NEXT_LINK) + private String atNextLink; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private List value; + + public CodeListListResponse() { + } + + public CodeListListResponse atRecordsetCount(String atRecordsetCount) { + this.atRecordsetCount = atRecordsetCount; + return this; + } + + /** + * Count of code lists for the given query parameters + * @return atRecordsetCount + */ + @javax.annotation.Nullable + public String getAtRecordsetCount() { + return atRecordsetCount; + } + + public void setAtRecordsetCount(String atRecordsetCount) { + this.atRecordsetCount = atRecordsetCount; + } + + + public CodeListListResponse atNextLink(String atNextLink) { + this.atNextLink = atNextLink; + return this; + } + + /** + * Get atNextLink + * @return atNextLink + */ + @javax.annotation.Nullable + public String getAtNextLink() { + return atNextLink; + } + + public void setAtNextLink(String atNextLink) { + this.atNextLink = atNextLink; + } + + + public CodeListListResponse value(List value) { + this.value = value; + return this; + } + + public CodeListListResponse addValueItem(CodeListSummary valueItem) { + if (this.value == null) { + this.value = new ArrayList<>(); + } + this.value.add(valueItem); + return this; + } + + /** + * Array of code lists matching query parameters + * @return value + */ + @javax.annotation.Nonnull + public List getValue() { + return value; + } + + public void setValue(List value) { + this.value = value; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CodeListListResponse codeListListResponse = (CodeListListResponse) o; + return Objects.equals(this.atRecordsetCount, codeListListResponse.atRecordsetCount) && + Objects.equals(this.atNextLink, codeListListResponse.atNextLink) && + Objects.equals(this.value, codeListListResponse.value); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(atRecordsetCount, atNextLink, value); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CodeListListResponse {\n"); + sb.append(" atRecordsetCount: ").append(toIndentedString(atRecordsetCount)).append("\n"); + sb.append(" atNextLink: ").append(toIndentedString(atNextLink)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("@recordsetCount"); + openapiFields.add("@nextLink"); + openapiFields.add("value"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + openapiRequiredFields.add("value"); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CodeListListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CodeListListResponse.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in CodeListListResponse is not found in the empty JSON string", CodeListListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CodeListListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `CodeListListResponse` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CodeListListResponse.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("@recordsetCount") != null && !jsonObj.get("@recordsetCount").isJsonNull()) && !jsonObj.get("@recordsetCount").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `@recordsetCount` to be a primitive type in the JSON string but got `%s`", jsonObj.get("@recordsetCount").toString())); + } + if ((jsonObj.get("@nextLink") != null && !jsonObj.get("@nextLink").isJsonNull()) && !jsonObj.get("@nextLink").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `@nextLink` to be a primitive type in the JSON string but got `%s`", jsonObj.get("@nextLink").toString())); + } + // ensure the json data is an array + if (!jsonObj.get("value").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `value` to be an array in the JSON string but got `%s`", jsonObj.get("value").toString())); + } + + JsonArray jsonArrayvalue = jsonObj.getAsJsonArray("value"); + // validate the required field `value` (array) + for (int i = 0; i < jsonArrayvalue.size(); i++) { + CodeListSummary.validateJsonElement(jsonArrayvalue.get(i)); + }; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CodeListListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CodeListListResponse' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(CodeListListResponse.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, CodeListListResponse value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CodeListListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of CodeListListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of CodeListListResponse + * @throws IOException if the JSON string is invalid with respect to CodeListListResponse + */ + public static CodeListListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CodeListListResponse.class); + } + + /** + * Convert an instance of CodeListListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListResponse.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListResponse.java new file mode 100644 index 0000000..3714ca6 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListResponse.java @@ -0,0 +1,379 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.CodeListVersion; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Returns a code list definition for a specific country + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class CodeListResponse { + public static final String SERIALIZED_NAME_COUNTRY_CODE = "countryCode"; + @SerializedName(SERIALIZED_NAME_COUNTRY_CODE) + private String countryCode; + + public static final String SERIALIZED_NAME_CODE_LIST_ID = "codeListId"; + @SerializedName(SERIALIZED_NAME_CODE_LIST_ID) + private String codeListId; + + public static final String SERIALIZED_NAME_CODE_LIST_NAME = "codeListName"; + @SerializedName(SERIALIZED_NAME_CODE_LIST_NAME) + private String codeListName; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_STANDARD = "standard"; + @SerializedName(SERIALIZED_NAME_STANDARD) + private String standard; + + public static final String SERIALIZED_NAME_VERSIONS = "versions"; + @SerializedName(SERIALIZED_NAME_VERSIONS) + private List versions; + + public CodeListResponse() { + } + + public CodeListResponse countryCode(String countryCode) { + this.countryCode = countryCode; + return this; + } + + /** + * Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. + * @return countryCode + */ + @javax.annotation.Nullable + public String getCountryCode() { + return countryCode; + } + + public void setCountryCode(String countryCode) { + this.countryCode = countryCode; + } + + + public CodeListResponse codeListId(String codeListId) { + this.codeListId = codeListId; + return this; + } + + /** + * System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. + * @return codeListId + */ + @javax.annotation.Nullable + public String getCodeListId() { + return codeListId; + } + + public void setCodeListId(String codeListId) { + this.codeListId = codeListId; + } + + + public CodeListResponse codeListName(String codeListName) { + this.codeListName = codeListName; + return this; + } + + /** + * Human-readable name of the code list, usually describing what the codes represent (for example, document types, tax categories, currencies). + * @return codeListName + */ + @javax.annotation.Nullable + public String getCodeListName() { + return codeListName; + } + + public void setCodeListName(String codeListName) { + this.codeListName = codeListName; + } + + + public CodeListResponse description(String description) { + this.description = description; + return this; + } + + /** + * Textual description of the code list, including what it is used for and whether it represents a global standard (e.g., UN/CEFACT, ISO, EN16931) or a jurisdiction-specific/local extension of that standard. + * @return description + */ + @javax.annotation.Nullable + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + + public CodeListResponse standard(String standard) { + this.standard = standard; + return this; + } + + /** + * Identifier of the underlying standard or authoritative source for this code list. This may be a formal code list name (e.g., UNCL1001), a standard reference (e.g., EN16931), or an internal standard identifier. + * @return standard + */ + @javax.annotation.Nullable + public String getStandard() { + return standard; + } + + public void setStandard(String standard) { + this.standard = standard; + } + + + public CodeListResponse versions(List versions) { + this.versions = versions; + return this; + } + + public CodeListResponse addVersionsItem(CodeListVersion versionsItem) { + if (this.versions == null) { + this.versions = new ArrayList<>(); + } + this.versions.add(versionsItem); + return this; + } + + /** + * Array of versioned definitions of this code list for the given jurisdiction. Each entry represents a version that is valid for a specific effective/sunset date range, optionally per locale. + * @return versions + */ + @javax.annotation.Nullable + public List getVersions() { + return versions; + } + + public void setVersions(List versions) { + this.versions = versions; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CodeListResponse codeListResponse = (CodeListResponse) o; + return Objects.equals(this.countryCode, codeListResponse.countryCode) && + Objects.equals(this.codeListId, codeListResponse.codeListId) && + Objects.equals(this.codeListName, codeListResponse.codeListName) && + Objects.equals(this.description, codeListResponse.description) && + Objects.equals(this.standard, codeListResponse.standard) && + Objects.equals(this.versions, codeListResponse.versions); + } + + @Override + public int hashCode() { + return Objects.hash(countryCode, codeListId, codeListName, description, standard, versions); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CodeListResponse {\n"); + sb.append(" countryCode: ").append(toIndentedString(countryCode)).append("\n"); + sb.append(" codeListId: ").append(toIndentedString(codeListId)).append("\n"); + sb.append(" codeListName: ").append(toIndentedString(codeListName)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" standard: ").append(toIndentedString(standard)).append("\n"); + sb.append(" versions: ").append(toIndentedString(versions)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("countryCode"); + openapiFields.add("codeListId"); + openapiFields.add("codeListName"); + openapiFields.add("description"); + openapiFields.add("standard"); + openapiFields.add("versions"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CodeListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CodeListResponse.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in CodeListResponse is not found in the empty JSON string", CodeListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CodeListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `CodeListResponse` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("countryCode") != null && !jsonObj.get("countryCode").isJsonNull()) && !jsonObj.get("countryCode").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `countryCode` to be a primitive type in the JSON string but got `%s`", jsonObj.get("countryCode").toString())); + } + if ((jsonObj.get("codeListId") != null && !jsonObj.get("codeListId").isJsonNull()) && !jsonObj.get("codeListId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `codeListId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("codeListId").toString())); + } + if ((jsonObj.get("codeListName") != null && !jsonObj.get("codeListName").isJsonNull()) && !jsonObj.get("codeListName").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `codeListName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("codeListName").toString())); + } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); + } + if ((jsonObj.get("standard") != null && !jsonObj.get("standard").isJsonNull()) && !jsonObj.get("standard").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `standard` to be a primitive type in the JSON string but got `%s`", jsonObj.get("standard").toString())); + } + if (jsonObj.get("versions") != null && !jsonObj.get("versions").isJsonNull()) { + JsonArray jsonArrayversions = jsonObj.getAsJsonArray("versions"); + if (jsonArrayversions != null) { + // ensure the json data is an array + if (!jsonObj.get("versions").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `versions` to be an array in the JSON string but got `%s`", jsonObj.get("versions").toString())); + } + + // validate the optional field `versions` (array) + for (int i = 0; i < jsonArrayversions.size(); i++) { + CodeListVersion.validateJsonElement(jsonArrayversions.get(i)); + }; + } + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CodeListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CodeListResponse' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(CodeListResponse.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, CodeListResponse value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CodeListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of CodeListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of CodeListResponse + * @throws IOException if the JSON string is invalid with respect to CodeListResponse + */ + public static CodeListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CodeListResponse.class); + } + + /** + * Convert an instance of CodeListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListSummary.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListSummary.java new file mode 100644 index 0000000..a3c4b79 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListSummary.java @@ -0,0 +1,379 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.CodeListVersion; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Displays a summary of information about a code list + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class CodeListSummary { + public static final String SERIALIZED_NAME_COUNTRY_CODE = "countryCode"; + @SerializedName(SERIALIZED_NAME_COUNTRY_CODE) + private String countryCode; + + public static final String SERIALIZED_NAME_CODE_LIST_ID = "codeListId"; + @SerializedName(SERIALIZED_NAME_CODE_LIST_ID) + private String codeListId; + + public static final String SERIALIZED_NAME_CODE_LIST_NAME = "codeListName"; + @SerializedName(SERIALIZED_NAME_CODE_LIST_NAME) + private String codeListName; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_STANDARD = "standard"; + @SerializedName(SERIALIZED_NAME_STANDARD) + private String standard; + + public static final String SERIALIZED_NAME_VERSIONS = "versions"; + @SerializedName(SERIALIZED_NAME_VERSIONS) + private List versions; + + public CodeListSummary() { + } + + public CodeListSummary countryCode(String countryCode) { + this.countryCode = countryCode; + return this; + } + + /** + * Two-letter ISO 3166-1 alpha-2 country code indicating the jurisdiction this code list applies to. + * @return countryCode + */ + @javax.annotation.Nullable + public String getCountryCode() { + return countryCode; + } + + public void setCountryCode(String countryCode) { + this.countryCode = countryCode; + } + + + public CodeListSummary codeListId(String codeListId) { + this.codeListId = codeListId; + return this; + } + + /** + * System-generated unique identifier of the code list definition. Typically a UUID used to reference this code list internally or via APIs. + * @return codeListId + */ + @javax.annotation.Nullable + public String getCodeListId() { + return codeListId; + } + + public void setCodeListId(String codeListId) { + this.codeListId = codeListId; + } + + + public CodeListSummary codeListName(String codeListName) { + this.codeListName = codeListName; + return this; + } + + /** + * Human-readable name of the code list, usually describing what the codes represent (for example, document types, tax categories, currencies). + * @return codeListName + */ + @javax.annotation.Nullable + public String getCodeListName() { + return codeListName; + } + + public void setCodeListName(String codeListName) { + this.codeListName = codeListName; + } + + + public CodeListSummary description(String description) { + this.description = description; + return this; + } + + /** + * Textual description of the code list, including what it is used for and whether it represents a global standard (e.g., UN/CEFACT, ISO, EN16931) or a jurisdiction-specific/local extension of that standard. + * @return description + */ + @javax.annotation.Nullable + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + + public CodeListSummary standard(String standard) { + this.standard = standard; + return this; + } + + /** + * Identifier of the underlying standard or authoritative source for this code list. This may be a formal code list name (e.g., UNCL1001), a standard reference (e.g., EN16931), or an internal standard identifier. + * @return standard + */ + @javax.annotation.Nullable + public String getStandard() { + return standard; + } + + public void setStandard(String standard) { + this.standard = standard; + } + + + public CodeListSummary versions(List versions) { + this.versions = versions; + return this; + } + + public CodeListSummary addVersionsItem(CodeListVersion versionsItem) { + if (this.versions == null) { + this.versions = new ArrayList<>(); + } + this.versions.add(versionsItem); + return this; + } + + /** + * Array of versioned definitions of this code list for the given jurisdiction. Each entry represents a version that is valid for a specific effective/sunset date range, optionally per locale. + * @return versions + */ + @javax.annotation.Nullable + public List getVersions() { + return versions; + } + + public void setVersions(List versions) { + this.versions = versions; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CodeListSummary codeListSummary = (CodeListSummary) o; + return Objects.equals(this.countryCode, codeListSummary.countryCode) && + Objects.equals(this.codeListId, codeListSummary.codeListId) && + Objects.equals(this.codeListName, codeListSummary.codeListName) && + Objects.equals(this.description, codeListSummary.description) && + Objects.equals(this.standard, codeListSummary.standard) && + Objects.equals(this.versions, codeListSummary.versions); + } + + @Override + public int hashCode() { + return Objects.hash(countryCode, codeListId, codeListName, description, standard, versions); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CodeListSummary {\n"); + sb.append(" countryCode: ").append(toIndentedString(countryCode)).append("\n"); + sb.append(" codeListId: ").append(toIndentedString(codeListId)).append("\n"); + sb.append(" codeListName: ").append(toIndentedString(codeListName)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" standard: ").append(toIndentedString(standard)).append("\n"); + sb.append(" versions: ").append(toIndentedString(versions)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("countryCode"); + openapiFields.add("codeListId"); + openapiFields.add("codeListName"); + openapiFields.add("description"); + openapiFields.add("standard"); + openapiFields.add("versions"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CodeListSummary + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CodeListSummary.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in CodeListSummary is not found in the empty JSON string", CodeListSummary.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CodeListSummary.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `CodeListSummary` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("countryCode") != null && !jsonObj.get("countryCode").isJsonNull()) && !jsonObj.get("countryCode").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `countryCode` to be a primitive type in the JSON string but got `%s`", jsonObj.get("countryCode").toString())); + } + if ((jsonObj.get("codeListId") != null && !jsonObj.get("codeListId").isJsonNull()) && !jsonObj.get("codeListId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `codeListId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("codeListId").toString())); + } + if ((jsonObj.get("codeListName") != null && !jsonObj.get("codeListName").isJsonNull()) && !jsonObj.get("codeListName").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `codeListName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("codeListName").toString())); + } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); + } + if ((jsonObj.get("standard") != null && !jsonObj.get("standard").isJsonNull()) && !jsonObj.get("standard").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `standard` to be a primitive type in the JSON string but got `%s`", jsonObj.get("standard").toString())); + } + if (jsonObj.get("versions") != null && !jsonObj.get("versions").isJsonNull()) { + JsonArray jsonArrayversions = jsonObj.getAsJsonArray("versions"); + if (jsonArrayversions != null) { + // ensure the json data is an array + if (!jsonObj.get("versions").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `versions` to be an array in the JSON string but got `%s`", jsonObj.get("versions").toString())); + } + + // validate the optional field `versions` (array) + for (int i = 0; i < jsonArrayversions.size(); i++) { + CodeListVersion.validateJsonElement(jsonArrayversions.get(i)); + }; + } + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CodeListSummary.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CodeListSummary' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(CodeListSummary.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, CodeListSummary value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CodeListSummary read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of CodeListSummary given an JSON string + * + * @param jsonString JSON string + * @return An instance of CodeListSummary + * @throws IOException if the JSON string is invalid with respect to CodeListSummary + */ + public static CodeListSummary fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CodeListSummary.class); + } + + /** + * Convert an instance of CodeListSummary to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListValue.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListValue.java new file mode 100644 index 0000000..b686cea --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListValue.java @@ -0,0 +1,270 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Represents a single code entry in a code list version + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class CodeListValue { + public static final String SERIALIZED_NAME_CODE = "code"; + @SerializedName(SERIALIZED_NAME_CODE) + private String code; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private String value; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public CodeListValue() { + } + + public CodeListValue code(String code) { + this.code = code; + return this; + } + + /** + * The actual code value used in documents or systems. This is typically what appears in the e-invoice payload, such as a numeric or alphanumeric code from the official code list. + * @return code + */ + @javax.annotation.Nullable + public String getCode() { + return code; + } + + public void setCode(String code) { + this.code = code; + } + + + public CodeListValue value(String value) { + this.value = value; + return this; + } + + /** + * Human-readable label or name for the code, localized according to the locale field of the version. + * @return value + */ + @javax.annotation.Nullable + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + + public CodeListValue description(String description) { + this.description = description; + return this; + } + + /** + * Detailed explanation of what the code represents, localized according to the locale field of the version. + * @return description + */ + @javax.annotation.Nullable + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CodeListValue codeListValue = (CodeListValue) o; + return Objects.equals(this.code, codeListValue.code) && + Objects.equals(this.value, codeListValue.value) && + Objects.equals(this.description, codeListValue.description); + } + + @Override + public int hashCode() { + return Objects.hash(code, value, description); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CodeListValue {\n"); + sb.append(" code: ").append(toIndentedString(code)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("code"); + openapiFields.add("value"); + openapiFields.add("description"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CodeListValue + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CodeListValue.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in CodeListValue is not found in the empty JSON string", CodeListValue.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CodeListValue.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `CodeListValue` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("code") != null && !jsonObj.get("code").isJsonNull()) && !jsonObj.get("code").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `code` to be a primitive type in the JSON string but got `%s`", jsonObj.get("code").toString())); + } + if ((jsonObj.get("value") != null && !jsonObj.get("value").isJsonNull()) && !jsonObj.get("value").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `value` to be a primitive type in the JSON string but got `%s`", jsonObj.get("value").toString())); + } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CodeListValue.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CodeListValue' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(CodeListValue.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, CodeListValue value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CodeListValue read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of CodeListValue given an JSON string + * + * @param jsonString JSON string + * @return An instance of CodeListValue + * @throws IOException if the JSON string is invalid with respect to CodeListValue + */ + public static CodeListValue fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CodeListValue.class); + } + + /** + * Convert an instance of CodeListValue to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListVersion.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListVersion.java new file mode 100644 index 0000000..d14d695 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/CodeListVersion.java @@ -0,0 +1,354 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.CodeListValue; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.LocalDate; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Represents a versioned definition of a code list for a specific jurisdiction and date range + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class CodeListVersion { + public static final String SERIALIZED_NAME_VERSION_REASONS = "versionReasons"; + @SerializedName(SERIALIZED_NAME_VERSION_REASONS) + private List versionReasons; + + public static final String SERIALIZED_NAME_JURIS_EFFECTIVE_DATE = "jurisEffectiveDate"; + @SerializedName(SERIALIZED_NAME_JURIS_EFFECTIVE_DATE) + private LocalDate jurisEffectiveDate; + + public static final String SERIALIZED_NAME_JURIS_SUNSET_DATE = "jurisSunsetDate"; + @SerializedName(SERIALIZED_NAME_JURIS_SUNSET_DATE) + private LocalDate jurisSunsetDate; + + public static final String SERIALIZED_NAME_LOCALE = "locale"; + @SerializedName(SERIALIZED_NAME_LOCALE) + private String locale; + + public static final String SERIALIZED_NAME_VALUES = "values"; + @SerializedName(SERIALIZED_NAME_VALUES) + private List values; + + public CodeListVersion() { + } + + public CodeListVersion versionReasons(List versionReasons) { + this.versionReasons = versionReasons; + return this; + } + + public CodeListVersion addVersionReasonsItem(String versionReasonsItem) { + if (this.versionReasons == null) { + this.versionReasons = new ArrayList<>(); + } + this.versionReasons.add(versionReasonsItem); + return this; + } + + /** + * List of free-text reasons explaining why this version of the code list exists (for example, initial introduction, regulatory update, addition/deprecation of codes). Useful for audit and change tracking. + * @return versionReasons + */ + @javax.annotation.Nullable + public List getVersionReasons() { + return versionReasons; + } + + public void setVersionReasons(List versionReasons) { + this.versionReasons = versionReasons; + } + + + public CodeListVersion jurisEffectiveDate(LocalDate jurisEffectiveDate) { + this.jurisEffectiveDate = jurisEffectiveDate; + return this; + } + + /** + * Date from which this version of the code list becomes legally or operationally effective in the jurisdiction. Typically corresponds to a go-live, mandate, or release date. + * @return jurisEffectiveDate + */ + @javax.annotation.Nullable + public LocalDate getJurisEffectiveDate() { + return jurisEffectiveDate; + } + + public void setJurisEffectiveDate(LocalDate jurisEffectiveDate) { + this.jurisEffectiveDate = jurisEffectiveDate; + } + + + public CodeListVersion jurisSunsetDate(LocalDate jurisSunsetDate) { + this.jurisSunsetDate = jurisSunsetDate; + return this; + } + + /** + * Date after which this version of the code list must no longer be used in the jurisdiction. Use a far-future date (e.g., 9999-12-31) when the sunset is not yet known. + * @return jurisSunsetDate + */ + @javax.annotation.Nullable + public LocalDate getJurisSunsetDate() { + return jurisSunsetDate; + } + + public void setJurisSunsetDate(LocalDate jurisSunsetDate) { + this.jurisSunsetDate = jurisSunsetDate; + } + + + public CodeListVersion locale(String locale) { + this.locale = locale; + return this; + } + + /** + * Language–region locale identifier indicating the language and regional variant for descriptions in this version of the code list. Follows BCP-47 format such as en-US, fr-FR, de-DE. + * @return locale + */ + @javax.annotation.Nullable + public String getLocale() { + return locale; + } + + public void setLocale(String locale) { + this.locale = locale; + } + + + public CodeListVersion values(List values) { + this.values = values; + return this; + } + + public CodeListVersion addValuesItem(CodeListValue valuesItem) { + if (this.values == null) { + this.values = new ArrayList<>(); + } + this.values.add(valuesItem); + return this; + } + + /** + * Array of code entries defined in this version of the code list. Each entry contains the machine-readable code value and its human-readable description in the given locale. + * @return values + */ + @javax.annotation.Nullable + public List getValues() { + return values; + } + + public void setValues(List values) { + this.values = values; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CodeListVersion codeListVersion = (CodeListVersion) o; + return Objects.equals(this.versionReasons, codeListVersion.versionReasons) && + Objects.equals(this.jurisEffectiveDate, codeListVersion.jurisEffectiveDate) && + Objects.equals(this.jurisSunsetDate, codeListVersion.jurisSunsetDate) && + Objects.equals(this.locale, codeListVersion.locale) && + Objects.equals(this.values, codeListVersion.values); + } + + @Override + public int hashCode() { + return Objects.hash(versionReasons, jurisEffectiveDate, jurisSunsetDate, locale, values); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CodeListVersion {\n"); + sb.append(" versionReasons: ").append(toIndentedString(versionReasons)).append("\n"); + sb.append(" jurisEffectiveDate: ").append(toIndentedString(jurisEffectiveDate)).append("\n"); + sb.append(" jurisSunsetDate: ").append(toIndentedString(jurisSunsetDate)).append("\n"); + sb.append(" locale: ").append(toIndentedString(locale)).append("\n"); + sb.append(" values: ").append(toIndentedString(values)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("versionReasons"); + openapiFields.add("jurisEffectiveDate"); + openapiFields.add("jurisSunsetDate"); + openapiFields.add("locale"); + openapiFields.add("values"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CodeListVersion + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CodeListVersion.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in CodeListVersion is not found in the empty JSON string", CodeListVersion.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CodeListVersion.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `CodeListVersion` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the optional json data is an array if present + if (jsonObj.get("versionReasons") != null && !jsonObj.get("versionReasons").isJsonNull() && !jsonObj.get("versionReasons").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `versionReasons` to be an array in the JSON string but got `%s`", jsonObj.get("versionReasons").toString())); + } + if ((jsonObj.get("locale") != null && !jsonObj.get("locale").isJsonNull()) && !jsonObj.get("locale").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `locale` to be a primitive type in the JSON string but got `%s`", jsonObj.get("locale").toString())); + } + if (jsonObj.get("values") != null && !jsonObj.get("values").isJsonNull()) { + JsonArray jsonArrayvalues = jsonObj.getAsJsonArray("values"); + if (jsonArrayvalues != null) { + // ensure the json data is an array + if (!jsonObj.get("values").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `values` to be an array in the JSON string but got `%s`", jsonObj.get("values").toString())); + } + + // validate the optional field `values` (array) + for (int i = 0; i < jsonArrayvalues.size(); i++) { + CodeListValue.validateJsonElement(jsonArrayvalues.get(i)); + }; + } + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CodeListVersion.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CodeListVersion' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(CodeListVersion.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, CodeListVersion value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CodeListVersion read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of CodeListVersion given an JSON string + * + * @param jsonString JSON string + * @return An instance of CodeListVersion + * @throws IOException if the JSON string is invalid with respect to CodeListVersion + */ + public static CodeListVersion fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CodeListVersion.class); + } + + /** + * Convert an instance of CodeListVersion to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentStatusResponse.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentStatusResponse.java index 31f2098..f7317de 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentStatusResponse.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentStatusResponse.java @@ -68,6 +68,10 @@ public class DocumentStatusResponse { @SerializedName(SERIALIZED_NAME_STATUS) private String status; + public static final String SERIALIZED_NAME_BUSINESS_STATUS = "businessStatus"; + @SerializedName(SERIALIZED_NAME_BUSINESS_STATUS) + private String businessStatus; + public static final String SERIALIZED_NAME_EVENTS = "events"; @SerializedName(SERIALIZED_NAME_EVENTS) private List events; @@ -100,7 +104,7 @@ public DocumentStatusResponse status(String status) { } /** - * Status of the document + * Document status. See the `supportedDocumentStatuses` field in the GET /mandates response for full status definitions. * @return status */ @javax.annotation.Nullable @@ -113,6 +117,25 @@ public void setStatus(String status) { } + public DocumentStatusResponse businessStatus(String businessStatus) { + this.businessStatus = businessStatus; + return this; + } + + /** + * Represents the document's business lifecycle state based on responses from external actors (Tax Authority, PDP, or ERP), such as acceptance, rejection, or validation. + * @return businessStatus + */ + @javax.annotation.Nullable + public String getBusinessStatus() { + return businessStatus; + } + + public void setBusinessStatus(String businessStatus) { + this.businessStatus = businessStatus; + } + + public DocumentStatusResponse events(List events) { this.events = events; return this; @@ -152,12 +175,13 @@ public boolean equals(Object o) { DocumentStatusResponse documentStatusResponse = (DocumentStatusResponse) o; return Objects.equals(this.id, documentStatusResponse.id) && Objects.equals(this.status, documentStatusResponse.status) && + Objects.equals(this.businessStatus, documentStatusResponse.businessStatus) && Objects.equals(this.events, documentStatusResponse.events); } @Override public int hashCode() { - return Objects.hash(id, status, events); + return Objects.hash(id, status, businessStatus, events); } @Override @@ -166,6 +190,7 @@ public String toString() { sb.append("class DocumentStatusResponse {\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" businessStatus: ").append(toIndentedString(businessStatus)).append("\n"); sb.append(" events: ").append(toIndentedString(events)).append("\n"); sb.append("}"); return sb.toString(); @@ -191,6 +216,7 @@ private String toIndentedString(Object o) { openapiFields = new HashSet(); openapiFields.add("id"); openapiFields.add("status"); + openapiFields.add("businessStatus"); openapiFields.add("events"); // a set of required properties/fields (JSON key names) @@ -224,6 +250,9 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) && !jsonObj.get("status").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `status` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status").toString())); } + if ((jsonObj.get("businessStatus") != null && !jsonObj.get("businessStatus").isJsonNull()) && !jsonObj.get("businessStatus").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `businessStatus` to be a primitive type in the JSON string but got `%s`", jsonObj.get("businessStatus").toString())); + } if (jsonObj.get("events") != null && !jsonObj.get("events").isJsonNull()) { JsonArray jsonArrayevents = jsonObj.getAsJsonArray("events"); if (jsonArrayevents != null) { diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentSummary.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentSummary.java index 9f19bed..5284ae7 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentSummary.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/DocumentSummary.java @@ -20,13 +20,17 @@ package Avalara.SDK.model.EInvoicing.V1; import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.StatusEvent; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import java.io.IOException; +import java.util.ArrayList; import java.util.Arrays; +import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import com.google.gson.Gson; import com.google.gson.GsonBuilder; @@ -73,6 +77,10 @@ public class DocumentSummary { @SerializedName(SERIALIZED_NAME_STATUS) private String status; + public static final String SERIALIZED_NAME_BUSINESS_STATUS = "businessStatus"; + @SerializedName(SERIALIZED_NAME_BUSINESS_STATUS) + private String businessStatus; + public static final String SERIALIZED_NAME_SUPPLIER_NAME = "supplierName"; @SerializedName(SERIALIZED_NAME_SUPPLIER_NAME) private String supplierName; @@ -117,6 +125,18 @@ public class DocumentSummary { @SerializedName(SERIALIZED_NAME_RECEIVER) private String receiver; + public static final String SERIALIZED_NAME_EVENTS = "events"; + @SerializedName(SERIALIZED_NAME_EVENTS) + private List events; + + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + @SerializedName(SERIALIZED_NAME_CREATED_AT) + private String createdAt; + + public static final String SERIALIZED_NAME_LAST_UPDATED_AT = "lastUpdatedAt"; + @SerializedName(SERIALIZED_NAME_LAST_UPDATED_AT) + private String lastUpdatedAt; + public DocumentSummary() { } @@ -196,6 +216,25 @@ public void setStatus(String status) { } + public DocumentSummary businessStatus(String businessStatus) { + this.businessStatus = businessStatus; + return this; + } + + /** + * Represents the document's business lifecycle state based on responses from external actors (Tax Authority, PDP, or ERP), such as acceptance, rejection, or validation. + * @return businessStatus + */ + @javax.annotation.Nullable + public String getBusinessStatus() { + return businessStatus; + } + + public void setBusinessStatus(String businessStatus) { + this.businessStatus = businessStatus; + } + + public DocumentSummary supplierName(String supplierName) { this.supplierName = supplierName; return this; @@ -405,6 +444,71 @@ public void setReceiver(String receiver) { } + public DocumentSummary events(List events) { + this.events = events; + return this; + } + + public DocumentSummary addEventsItem(StatusEvent eventsItem) { + if (this.events == null) { + this.events = new ArrayList<>(); + } + this.events.add(eventsItem); + return this; + } + + /** + * Array of status events associated with this document. Events are included in each document in the response only when the query parameter $include=events is passed; otherwise the events array is not populated. + * @return events + */ + @javax.annotation.Nullable + public List getEvents() { + return events; + } + + public void setEvents(List events) { + this.events = events; + } + + + public DocumentSummary createdAt(String createdAt) { + this.createdAt = createdAt; + return this; + } + + /** + * The date and time when the document was created in the system, displayed in ISO 8601 format with timezone + * @return createdAt + */ + @javax.annotation.Nullable + public String getCreatedAt() { + return createdAt; + } + + public void setCreatedAt(String createdAt) { + this.createdAt = createdAt; + } + + + public DocumentSummary lastUpdatedAt(String lastUpdatedAt) { + this.lastUpdatedAt = lastUpdatedAt; + return this; + } + + /** + * The date and time when the document was last updated in the system, displayed in ISO 8601 format with timezone + * @return lastUpdatedAt + */ + @javax.annotation.Nullable + public String getLastUpdatedAt() { + return lastUpdatedAt; + } + + public void setLastUpdatedAt(String lastUpdatedAt) { + this.lastUpdatedAt = lastUpdatedAt; + } + + @Override public boolean equals(Object o) { @@ -419,6 +523,7 @@ public boolean equals(Object o) { Objects.equals(this.companyId, documentSummary.companyId) && Objects.equals(this.processDateTime, documentSummary.processDateTime) && Objects.equals(this.status, documentSummary.status) && + Objects.equals(this.businessStatus, documentSummary.businessStatus) && Objects.equals(this.supplierName, documentSummary.supplierName) && Objects.equals(this.customerName, documentSummary.customerName) && Objects.equals(this.documentType, documentSummary.documentType) && @@ -429,12 +534,26 @@ public boolean equals(Object o) { Objects.equals(this.countryCode, documentSummary.countryCode) && Objects.equals(this.countryMandate, documentSummary.countryMandate) && Objects.equals(this._interface, documentSummary._interface) && - Objects.equals(this.receiver, documentSummary.receiver); + Objects.equals(this.receiver, documentSummary.receiver) && + Objects.equals(this.events, documentSummary.events) && + Objects.equals(this.createdAt, documentSummary.createdAt) && + Objects.equals(this.lastUpdatedAt, documentSummary.lastUpdatedAt); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); } @Override public int hashCode() { - return Objects.hash(id, companyId, processDateTime, status, supplierName, customerName, documentType, documentVersion, documentNumber, documentDate, flow, countryCode, countryMandate, _interface, receiver); + return Objects.hash(id, companyId, processDateTime, status, businessStatus, supplierName, customerName, documentType, documentVersion, documentNumber, documentDate, flow, countryCode, countryMandate, _interface, receiver, events, createdAt, lastUpdatedAt); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; } @Override @@ -445,6 +564,7 @@ public String toString() { sb.append(" companyId: ").append(toIndentedString(companyId)).append("\n"); sb.append(" processDateTime: ").append(toIndentedString(processDateTime)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" businessStatus: ").append(toIndentedString(businessStatus)).append("\n"); sb.append(" supplierName: ").append(toIndentedString(supplierName)).append("\n"); sb.append(" customerName: ").append(toIndentedString(customerName)).append("\n"); sb.append(" documentType: ").append(toIndentedString(documentType)).append("\n"); @@ -456,6 +576,9 @@ public String toString() { sb.append(" countryMandate: ").append(toIndentedString(countryMandate)).append("\n"); sb.append(" _interface: ").append(toIndentedString(_interface)).append("\n"); sb.append(" receiver: ").append(toIndentedString(receiver)).append("\n"); + sb.append(" events: ").append(toIndentedString(events)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" lastUpdatedAt: ").append(toIndentedString(lastUpdatedAt)).append("\n"); sb.append("}"); return sb.toString(); } @@ -482,6 +605,7 @@ private String toIndentedString(Object o) { openapiFields.add("companyId"); openapiFields.add("processDateTime"); openapiFields.add("status"); + openapiFields.add("businessStatus"); openapiFields.add("supplierName"); openapiFields.add("customerName"); openapiFields.add("documentType"); @@ -493,6 +617,9 @@ private String toIndentedString(Object o) { openapiFields.add("countryMandate"); openapiFields.add("interface"); openapiFields.add("receiver"); + openapiFields.add("events"); + openapiFields.add("createdAt"); + openapiFields.add("lastUpdatedAt"); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(); @@ -531,6 +658,9 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) && !jsonObj.get("status").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `status` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status").toString())); } + if ((jsonObj.get("businessStatus") != null && !jsonObj.get("businessStatus").isJsonNull()) && !jsonObj.get("businessStatus").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `businessStatus` to be a primitive type in the JSON string but got `%s`", jsonObj.get("businessStatus").toString())); + } if ((jsonObj.get("supplierName") != null && !jsonObj.get("supplierName").isJsonNull()) && !jsonObj.get("supplierName").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `supplierName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("supplierName").toString())); } @@ -564,6 +694,26 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if ((jsonObj.get("receiver") != null && !jsonObj.get("receiver").isJsonNull()) && !jsonObj.get("receiver").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `receiver` to be a primitive type in the JSON string but got `%s`", jsonObj.get("receiver").toString())); } + if (jsonObj.get("events") != null && !jsonObj.get("events").isJsonNull()) { + JsonArray jsonArrayevents = jsonObj.getAsJsonArray("events"); + if (jsonArrayevents != null) { + // ensure the json data is an array + if (!jsonObj.get("events").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `events` to be an array in the JSON string but got `%s`", jsonObj.get("events").toString())); + } + + // validate the optional field `events` (array) + for (int i = 0; i < jsonArrayevents.size(); i++) { + StatusEvent.validateJsonElement(jsonArrayevents.get(i)); + }; + } + } + if ((jsonObj.get("createdAt") != null && !jsonObj.get("createdAt").isJsonNull()) && !jsonObj.get("createdAt").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `createdAt` to be a primitive type in the JSON string but got `%s`", jsonObj.get("createdAt").toString())); + } + if ((jsonObj.get("lastUpdatedAt") != null && !jsonObj.get("lastUpdatedAt").isJsonNull()) && !jsonObj.get("lastUpdatedAt").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `lastUpdatedAt` to be a primitive type in the JSON string but got `%s`", jsonObj.get("lastUpdatedAt").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/Identifier.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/Identifier.java index e09f086..01d85c0 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/Identifier.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/Identifier.java @@ -20,13 +20,16 @@ package Avalara.SDK.model.EInvoicing.V1; import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.Extension; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import java.io.IOException; +import java.util.ArrayList; import java.util.Arrays; +import java.util.List; import com.google.gson.Gson; import com.google.gson.GsonBuilder; @@ -69,6 +72,10 @@ public class Identifier { @SerializedName(SERIALIZED_NAME_VALUE) private String value; + public static final String SERIALIZED_NAME_EXTENSIONS = "extensions"; + @SerializedName(SERIALIZED_NAME_EXTENSIONS) + private List extensions; + public Identifier() { } @@ -129,6 +136,33 @@ public void setValue(String value) { } + public Identifier extensions(List extensions) { + this.extensions = extensions; + return this; + } + + public Identifier addExtensionsItem(Extension extensionsItem) { + if (this.extensions == null) { + this.extensions = new ArrayList<>(); + } + this.extensions.add(extensionsItem); + return this; + } + + /** + * Optional array used to carry additional metadata or configuration values for the identifier. + * @return extensions + */ + @javax.annotation.Nullable + public List getExtensions() { + return extensions; + } + + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override public boolean equals(Object o) { @@ -141,12 +175,13 @@ public boolean equals(Object o) { Identifier identifier = (Identifier) o; return Objects.equals(this.name, identifier.name) && Objects.equals(this.displayName, identifier.displayName) && - Objects.equals(this.value, identifier.value); + Objects.equals(this.value, identifier.value) && + Objects.equals(this.extensions, identifier.extensions); } @Override public int hashCode() { - return Objects.hash(name, displayName, value); + return Objects.hash(name, displayName, value, extensions); } @Override @@ -156,6 +191,7 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" displayName: ").append(toIndentedString(displayName)).append("\n"); sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append(" extensions: ").append(toIndentedString(extensions)).append("\n"); sb.append("}"); return sb.toString(); } @@ -181,6 +217,7 @@ private String toIndentedString(Object o) { openapiFields.add("name"); openapiFields.add("displayName"); openapiFields.add("value"); + openapiFields.add("extensions"); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(); @@ -225,6 +262,20 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if (!jsonObj.get("value").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `value` to be a primitive type in the JSON string but got `%s`", jsonObj.get("value").toString())); } + if (jsonObj.get("extensions") != null && !jsonObj.get("extensions").isJsonNull()) { + JsonArray jsonArrayextensions = jsonObj.getAsJsonArray("extensions"); + if (jsonArrayextensions != null) { + // ensure the json data is an array + if (!jsonObj.get("extensions").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `extensions` to be an array in the JSON string but got `%s`", jsonObj.get("extensions").toString())); + } + + // validate the optional field `extensions` (array) + for (int i = 0; i < jsonArrayextensions.size(); i++) { + Extension.validateJsonElement(jsonArrayextensions.get(i)); + }; + } + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/Mandate.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/Mandate.java index a71404b..1ce0eae 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/Mandate.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/Mandate.java @@ -22,6 +22,7 @@ import java.util.Objects; import Avalara.SDK.model.EInvoicing.V1.InputDataFormats; import Avalara.SDK.model.EInvoicing.V1.OutputDataFormats; +import Avalara.SDK.model.EInvoicing.V1.SupportedDocumentStatuses; import Avalara.SDK.model.EInvoicing.V1.WorkflowIds; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; @@ -114,6 +115,10 @@ public class Mandate { @SerializedName(SERIALIZED_NAME_WORKFLOW_IDS) private List workflowIds; + public static final String SERIALIZED_NAME_SUPPORTED_DOCUMENT_STATUSES = "supportedDocumentStatuses"; + @SerializedName(SERIALIZED_NAME_SUPPORTED_DOCUMENT_STATUSES) + private List supportedDocumentStatuses; + public Mandate() { } @@ -396,6 +401,33 @@ public void setWorkflowIds(List workflowIds) { } + public Mandate supportedDocumentStatuses(List supportedDocumentStatuses) { + this.supportedDocumentStatuses = supportedDocumentStatuses; + return this; + } + + public Mandate addSupportedDocumentStatusesItem(SupportedDocumentStatuses supportedDocumentStatusesItem) { + if (this.supportedDocumentStatuses == null) { + this.supportedDocumentStatuses = new ArrayList<>(); + } + this.supportedDocumentStatuses.add(supportedDocumentStatusesItem); + return this; + } + + /** + * List of document statuses defined by the mandate. + * @return supportedDocumentStatuses + */ + @javax.annotation.Nullable + public List getSupportedDocumentStatuses() { + return supportedDocumentStatuses; + } + + public void setSupportedDocumentStatuses(List supportedDocumentStatuses) { + this.supportedDocumentStatuses = supportedDocumentStatuses; + } + + @Override public boolean equals(Object o) { @@ -418,12 +450,13 @@ public boolean equals(Object o) { Objects.equals(this.supportsInboundDigitalDocument, mandate.supportsInboundDigitalDocument) && Objects.equals(this.inputDataFormats, mandate.inputDataFormats) && Objects.equals(this.outputDataFormats, mandate.outputDataFormats) && - Objects.equals(this.workflowIds, mandate.workflowIds); + Objects.equals(this.workflowIds, mandate.workflowIds) && + Objects.equals(this.supportedDocumentStatuses, mandate.supportedDocumentStatuses); } @Override public int hashCode() { - return Objects.hash(mandateId, countryMandate, countryCode, description, supportedByELRAPI, mandateFormat, eInvoicingFlow, eInvoicingFlowDocumentationLink, getInvoiceAvailableMediaType, supportsInboundDigitalDocument, inputDataFormats, outputDataFormats, workflowIds); + return Objects.hash(mandateId, countryMandate, countryCode, description, supportedByELRAPI, mandateFormat, eInvoicingFlow, eInvoicingFlowDocumentationLink, getInvoiceAvailableMediaType, supportsInboundDigitalDocument, inputDataFormats, outputDataFormats, workflowIds, supportedDocumentStatuses); } @Override @@ -443,6 +476,7 @@ public String toString() { sb.append(" inputDataFormats: ").append(toIndentedString(inputDataFormats)).append("\n"); sb.append(" outputDataFormats: ").append(toIndentedString(outputDataFormats)).append("\n"); sb.append(" workflowIds: ").append(toIndentedString(workflowIds)).append("\n"); + sb.append(" supportedDocumentStatuses: ").append(toIndentedString(supportedDocumentStatuses)).append("\n"); sb.append("}"); return sb.toString(); } @@ -478,6 +512,7 @@ private String toIndentedString(Object o) { openapiFields.add("inputDataFormats"); openapiFields.add("outputDataFormats"); openapiFields.add("workflowIds"); + openapiFields.add("supportedDocumentStatuses"); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(); @@ -574,6 +609,20 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti }; } } + if (jsonObj.get("supportedDocumentStatuses") != null && !jsonObj.get("supportedDocumentStatuses").isJsonNull()) { + JsonArray jsonArraysupportedDocumentStatuses = jsonObj.getAsJsonArray("supportedDocumentStatuses"); + if (jsonArraysupportedDocumentStatuses != null) { + // ensure the json data is an array + if (!jsonObj.get("supportedDocumentStatuses").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `supportedDocumentStatuses` to be an array in the JSON string but got `%s`", jsonObj.get("supportedDocumentStatuses").toString())); + } + + // validate the optional field `supportedDocumentStatuses` (array) + for (int i = 0; i < jsonArraysupportedDocumentStatuses.size(); i++) { + SupportedDocumentStatuses.validateJsonElement(jsonArraysupportedDocumentStatuses.get(i)); + }; + } + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportDownloadResponse.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportDownloadResponse.java new file mode 100644 index 0000000..6b30d33 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportDownloadResponse.java @@ -0,0 +1,242 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.net.URI; +import java.util.Arrays; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Returns a pre-signed URL to download the report file. + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class ReportDownloadResponse { + public static final String SERIALIZED_NAME_REPORT_ID = "reportId"; + @SerializedName(SERIALIZED_NAME_REPORT_ID) + private String reportId; + + public static final String SERIALIZED_NAME_DOWNLOAD_URL = "downloadUrl"; + @SerializedName(SERIALIZED_NAME_DOWNLOAD_URL) + private URI downloadUrl; + + public ReportDownloadResponse() { + } + + public ReportDownloadResponse reportId(String reportId) { + this.reportId = reportId; + return this; + } + + /** + * The unique identifier of the report. + * @return reportId + */ + @javax.annotation.Nullable + public String getReportId() { + return reportId; + } + + public void setReportId(String reportId) { + this.reportId = reportId; + } + + + public ReportDownloadResponse downloadUrl(URI downloadUrl) { + this.downloadUrl = downloadUrl; + return this; + } + + /** + * A pre-signed URL to download the report file. This URL is time-limited. + * @return downloadUrl + */ + @javax.annotation.Nullable + public URI getDownloadUrl() { + return downloadUrl; + } + + public void setDownloadUrl(URI downloadUrl) { + this.downloadUrl = downloadUrl; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReportDownloadResponse reportDownloadResponse = (ReportDownloadResponse) o; + return Objects.equals(this.reportId, reportDownloadResponse.reportId) && + Objects.equals(this.downloadUrl, reportDownloadResponse.downloadUrl); + } + + @Override + public int hashCode() { + return Objects.hash(reportId, downloadUrl); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReportDownloadResponse {\n"); + sb.append(" reportId: ").append(toIndentedString(reportId)).append("\n"); + sb.append(" downloadUrl: ").append(toIndentedString(downloadUrl)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("reportId"); + openapiFields.add("downloadUrl"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ReportDownloadResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ReportDownloadResponse.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in ReportDownloadResponse is not found in the empty JSON string", ReportDownloadResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ReportDownloadResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `ReportDownloadResponse` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("reportId") != null && !jsonObj.get("reportId").isJsonNull()) && !jsonObj.get("reportId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `reportId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("reportId").toString())); + } + if ((jsonObj.get("downloadUrl") != null && !jsonObj.get("downloadUrl").isJsonNull()) && !jsonObj.get("downloadUrl").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `downloadUrl` to be a primitive type in the JSON string but got `%s`", jsonObj.get("downloadUrl").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ReportDownloadResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ReportDownloadResponse' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(ReportDownloadResponse.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, ReportDownloadResponse value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ReportDownloadResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of ReportDownloadResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of ReportDownloadResponse + * @throws IOException if the JSON string is invalid with respect to ReportDownloadResponse + */ + public static ReportDownloadResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ReportDownloadResponse.class); + } + + /** + * Convert an instance of ReportDownloadResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportItem.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportItem.java new file mode 100644 index 0000000..44da00d --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportItem.java @@ -0,0 +1,742 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.math.BigDecimal; +import java.time.LocalDate; +import java.time.OffsetDateTime; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Represents a single report with full details including metadata and associated transaction IDs. + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class ReportItem { + public static final String SERIALIZED_NAME_REPORT_ID = "reportId"; + @SerializedName(SERIALIZED_NAME_REPORT_ID) + private String reportId; + + public static final String SERIALIZED_NAME_JOB_ID = "jobId"; + @SerializedName(SERIALIZED_NAME_JOB_ID) + private String jobId; + + public static final String SERIALIZED_NAME_REPORT_GENERATE_DATE = "reportGenerateDate"; + @SerializedName(SERIALIZED_NAME_REPORT_GENERATE_DATE) + private OffsetDateTime reportGenerateDate; + + public static final String SERIALIZED_NAME_REPORT_FROM = "reportFrom"; + @SerializedName(SERIALIZED_NAME_REPORT_FROM) + private LocalDate reportFrom; + + public static final String SERIALIZED_NAME_REPORT_TO = "reportTo"; + @SerializedName(SERIALIZED_NAME_REPORT_TO) + private LocalDate reportTo; + + public static final String SERIALIZED_NAME_COUNTRY_CODE = "countryCode"; + @SerializedName(SERIALIZED_NAME_COUNTRY_CODE) + private String countryCode; + + public static final String SERIALIZED_NAME_COUNTRY_MANDATE = "countryMandate"; + @SerializedName(SERIALIZED_NAME_COUNTRY_MANDATE) + private String countryMandate; + + public static final String SERIALIZED_NAME_DOCUMENT_TYPE = "documentType"; + @SerializedName(SERIALIZED_NAME_DOCUMENT_TYPE) + private String documentType; + + public static final String SERIALIZED_NAME_DOCUMENT_SUB_TYPE = "documentSubType"; + @SerializedName(SERIALIZED_NAME_DOCUMENT_SUB_TYPE) + private String documentSubType; + + public static final String SERIALIZED_NAME_REPORT_REFERENCE = "reportReference"; + @SerializedName(SERIALIZED_NAME_REPORT_REFERENCE) + private String reportReference; + + public static final String SERIALIZED_NAME_REPORT_NAME = "reportName"; + @SerializedName(SERIALIZED_NAME_REPORT_NAME) + private String reportName; + + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private String status; + + public static final String SERIALIZED_NAME_REPORT_FORMAT_MIMETYPES = "reportFormatMimetypes"; + @SerializedName(SERIALIZED_NAME_REPORT_FORMAT_MIMETYPES) + private String reportFormatMimetypes; + + public static final String SERIALIZED_NAME_TENANT_ID = "tenantId"; + @SerializedName(SERIALIZED_NAME_TENANT_ID) + private String tenantId; + + public static final String SERIALIZED_NAME_TA_NAME = "taName"; + @SerializedName(SERIALIZED_NAME_TA_NAME) + private String taName; + + public static final String SERIALIZED_NAME_TAX_INVOICE_AMOUNT = "taxInvoiceAmount"; + @SerializedName(SERIALIZED_NAME_TAX_INVOICE_AMOUNT) + private BigDecimal taxInvoiceAmount; + + public static final String SERIALIZED_NAME_TOTAL_TAX_AMOUNT = "totalTaxAmount"; + @SerializedName(SERIALIZED_NAME_TOTAL_TAX_AMOUNT) + private BigDecimal totalTaxAmount; + + public static final String SERIALIZED_NAME_METADATA = "metadata"; + @SerializedName(SERIALIZED_NAME_METADATA) + private Object metadata; + + public static final String SERIALIZED_NAME_TRANSACTION_IDS = "transactionIds"; + @SerializedName(SERIALIZED_NAME_TRANSACTION_IDS) + private List transactionIds; + + public ReportItem() { + } + + public ReportItem reportId(String reportId) { + this.reportId = reportId; + return this; + } + + /** + * The unique ID for this report. + * @return reportId + */ + @javax.annotation.Nullable + public String getReportId() { + return reportId; + } + + public void setReportId(String reportId) { + this.reportId = reportId; + } + + + public ReportItem jobId(String jobId) { + this.jobId = jobId; + return this; + } + + /** + * The unique ID of the job that generated this report. + * @return jobId + */ + @javax.annotation.Nullable + public String getJobId() { + return jobId; + } + + public void setJobId(String jobId) { + this.jobId = jobId; + } + + + public ReportItem reportGenerateDate(OffsetDateTime reportGenerateDate) { + this.reportGenerateDate = reportGenerateDate; + return this; + } + + /** + * The date and time when the report was generated. + * @return reportGenerateDate + */ + @javax.annotation.Nullable + public OffsetDateTime getReportGenerateDate() { + return reportGenerateDate; + } + + public void setReportGenerateDate(OffsetDateTime reportGenerateDate) { + this.reportGenerateDate = reportGenerateDate; + } + + + public ReportItem reportFrom(LocalDate reportFrom) { + this.reportFrom = reportFrom; + return this; + } + + /** + * The start date of the reporting period. + * @return reportFrom + */ + @javax.annotation.Nullable + public LocalDate getReportFrom() { + return reportFrom; + } + + public void setReportFrom(LocalDate reportFrom) { + this.reportFrom = reportFrom; + } + + + public ReportItem reportTo(LocalDate reportTo) { + this.reportTo = reportTo; + return this; + } + + /** + * The end date of the reporting period. + * @return reportTo + */ + @javax.annotation.Nullable + public LocalDate getReportTo() { + return reportTo; + } + + public void setReportTo(LocalDate reportTo) { + this.reportTo = reportTo; + } + + + public ReportItem countryCode(String countryCode) { + this.countryCode = countryCode; + return this; + } + + /** + * The two-letter ISO-3166 country code for which this report was generated. + * @return countryCode + */ + @javax.annotation.Nullable + public String getCountryCode() { + return countryCode; + } + + public void setCountryCode(String countryCode) { + this.countryCode = countryCode; + } + + + public ReportItem countryMandate(String countryMandate) { + this.countryMandate = countryMandate; + return this; + } + + /** + * The e-invoicing mandate for the specified country. + * @return countryMandate + */ + @javax.annotation.Nullable + public String getCountryMandate() { + return countryMandate; + } + + public void setCountryMandate(String countryMandate) { + this.countryMandate = countryMandate; + } + + + public ReportItem documentType(String documentType) { + this.documentType = documentType; + return this; + } + + /** + * The type of document covered by this report. + * @return documentType + */ + @javax.annotation.Nullable + public String getDocumentType() { + return documentType; + } + + public void setDocumentType(String documentType) { + this.documentType = documentType; + } + + + public ReportItem documentSubType(String documentSubType) { + this.documentSubType = documentSubType; + return this; + } + + /** + * The sub-type of the document. + * @return documentSubType + */ + @javax.annotation.Nullable + public String getDocumentSubType() { + return documentSubType; + } + + public void setDocumentSubType(String documentSubType) { + this.documentSubType = documentSubType; + } + + + public ReportItem reportReference(String reportReference) { + this.reportReference = reportReference; + return this; + } + + /** + * An internal reference path for the report. + * @return reportReference + */ + @javax.annotation.Nullable + public String getReportReference() { + return reportReference; + } + + public void setReportReference(String reportReference) { + this.reportReference = reportReference; + } + + + public ReportItem reportName(String reportName) { + this.reportName = reportName; + return this; + } + + /** + * The name of the report file. + * @return reportName + */ + @javax.annotation.Nullable + public String getReportName() { + return reportName; + } + + public void setReportName(String reportName) { + this.reportName = reportName; + } + + + public ReportItem status(String status) { + this.status = status; + return this; + } + + /** + * The current status of the report. Possible values include: PENDING, PROCESSING, COMPLETED, FAILED, SENT_TO_PPF, ERROR. + * @return status + */ + @javax.annotation.Nullable + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + + public ReportItem reportFormatMimetypes(String reportFormatMimetypes) { + this.reportFormatMimetypes = reportFormatMimetypes; + return this; + } + + /** + * The MIME type of the report file. + * @return reportFormatMimetypes + */ + @javax.annotation.Nullable + public String getReportFormatMimetypes() { + return reportFormatMimetypes; + } + + public void setReportFormatMimetypes(String reportFormatMimetypes) { + this.reportFormatMimetypes = reportFormatMimetypes; + } + + + public ReportItem tenantId(String tenantId) { + this.tenantId = tenantId; + return this; + } + + /** + * The tenant identifier associated with this report. + * @return tenantId + */ + @javax.annotation.Nullable + public String getTenantId() { + return tenantId; + } + + public void setTenantId(String tenantId) { + this.tenantId = tenantId; + } + + + public ReportItem taName(String taName) { + this.taName = taName; + return this; + } + + /** + * The name of the tax authority for this report. + * @return taName + */ + @javax.annotation.Nullable + public String getTaName() { + return taName; + } + + public void setTaName(String taName) { + this.taName = taName; + } + + + public ReportItem taxInvoiceAmount(BigDecimal taxInvoiceAmount) { + this.taxInvoiceAmount = taxInvoiceAmount; + return this; + } + + /** + * The total invoice amount covered by this report. + * @return taxInvoiceAmount + */ + @javax.annotation.Nullable + public BigDecimal getTaxInvoiceAmount() { + return taxInvoiceAmount; + } + + public void setTaxInvoiceAmount(BigDecimal taxInvoiceAmount) { + this.taxInvoiceAmount = taxInvoiceAmount; + } + + + public ReportItem totalTaxAmount(BigDecimal totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + return this; + } + + /** + * The total tax amount covered by this report. + * @return totalTaxAmount + */ + @javax.annotation.Nullable + public BigDecimal getTotalTaxAmount() { + return totalTaxAmount; + } + + public void setTotalTaxAmount(BigDecimal totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + } + + + public ReportItem metadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Additional report metadata (free-form JSON). Contents vary by country mandate. + * @return metadata + */ + @javax.annotation.Nullable + public Object getMetadata() { + return metadata; + } + + public void setMetadata(Object metadata) { + this.metadata = metadata; + } + + + public ReportItem transactionIds(List transactionIds) { + this.transactionIds = transactionIds; + return this; + } + + public ReportItem addTransactionIdsItem(String transactionIdsItem) { + if (this.transactionIds == null) { + this.transactionIds = new ArrayList<>(); + } + this.transactionIds.add(transactionIdsItem); + return this; + } + + /** + * List of transaction IDs associated with this report. + * @return transactionIds + */ + @javax.annotation.Nullable + public List getTransactionIds() { + return transactionIds; + } + + public void setTransactionIds(List transactionIds) { + this.transactionIds = transactionIds; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReportItem reportItem = (ReportItem) o; + return Objects.equals(this.reportId, reportItem.reportId) && + Objects.equals(this.jobId, reportItem.jobId) && + Objects.equals(this.reportGenerateDate, reportItem.reportGenerateDate) && + Objects.equals(this.reportFrom, reportItem.reportFrom) && + Objects.equals(this.reportTo, reportItem.reportTo) && + Objects.equals(this.countryCode, reportItem.countryCode) && + Objects.equals(this.countryMandate, reportItem.countryMandate) && + Objects.equals(this.documentType, reportItem.documentType) && + Objects.equals(this.documentSubType, reportItem.documentSubType) && + Objects.equals(this.reportReference, reportItem.reportReference) && + Objects.equals(this.reportName, reportItem.reportName) && + Objects.equals(this.status, reportItem.status) && + Objects.equals(this.reportFormatMimetypes, reportItem.reportFormatMimetypes) && + Objects.equals(this.tenantId, reportItem.tenantId) && + Objects.equals(this.taName, reportItem.taName) && + Objects.equals(this.taxInvoiceAmount, reportItem.taxInvoiceAmount) && + Objects.equals(this.totalTaxAmount, reportItem.totalTaxAmount) && + Objects.equals(this.metadata, reportItem.metadata) && + Objects.equals(this.transactionIds, reportItem.transactionIds); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(reportId, jobId, reportGenerateDate, reportFrom, reportTo, countryCode, countryMandate, documentType, documentSubType, reportReference, reportName, status, reportFormatMimetypes, tenantId, taName, taxInvoiceAmount, totalTaxAmount, metadata, transactionIds); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReportItem {\n"); + sb.append(" reportId: ").append(toIndentedString(reportId)).append("\n"); + sb.append(" jobId: ").append(toIndentedString(jobId)).append("\n"); + sb.append(" reportGenerateDate: ").append(toIndentedString(reportGenerateDate)).append("\n"); + sb.append(" reportFrom: ").append(toIndentedString(reportFrom)).append("\n"); + sb.append(" reportTo: ").append(toIndentedString(reportTo)).append("\n"); + sb.append(" countryCode: ").append(toIndentedString(countryCode)).append("\n"); + sb.append(" countryMandate: ").append(toIndentedString(countryMandate)).append("\n"); + sb.append(" documentType: ").append(toIndentedString(documentType)).append("\n"); + sb.append(" documentSubType: ").append(toIndentedString(documentSubType)).append("\n"); + sb.append(" reportReference: ").append(toIndentedString(reportReference)).append("\n"); + sb.append(" reportName: ").append(toIndentedString(reportName)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" reportFormatMimetypes: ").append(toIndentedString(reportFormatMimetypes)).append("\n"); + sb.append(" tenantId: ").append(toIndentedString(tenantId)).append("\n"); + sb.append(" taName: ").append(toIndentedString(taName)).append("\n"); + sb.append(" taxInvoiceAmount: ").append(toIndentedString(taxInvoiceAmount)).append("\n"); + sb.append(" totalTaxAmount: ").append(toIndentedString(totalTaxAmount)).append("\n"); + sb.append(" metadata: ").append(toIndentedString(metadata)).append("\n"); + sb.append(" transactionIds: ").append(toIndentedString(transactionIds)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("reportId"); + openapiFields.add("jobId"); + openapiFields.add("reportGenerateDate"); + openapiFields.add("reportFrom"); + openapiFields.add("reportTo"); + openapiFields.add("countryCode"); + openapiFields.add("countryMandate"); + openapiFields.add("documentType"); + openapiFields.add("documentSubType"); + openapiFields.add("reportReference"); + openapiFields.add("reportName"); + openapiFields.add("status"); + openapiFields.add("reportFormatMimetypes"); + openapiFields.add("tenantId"); + openapiFields.add("taName"); + openapiFields.add("taxInvoiceAmount"); + openapiFields.add("totalTaxAmount"); + openapiFields.add("metadata"); + openapiFields.add("transactionIds"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ReportItem + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ReportItem.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in ReportItem is not found in the empty JSON string", ReportItem.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ReportItem.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `ReportItem` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("reportId") != null && !jsonObj.get("reportId").isJsonNull()) && !jsonObj.get("reportId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `reportId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("reportId").toString())); + } + if ((jsonObj.get("jobId") != null && !jsonObj.get("jobId").isJsonNull()) && !jsonObj.get("jobId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `jobId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("jobId").toString())); + } + if ((jsonObj.get("countryCode") != null && !jsonObj.get("countryCode").isJsonNull()) && !jsonObj.get("countryCode").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `countryCode` to be a primitive type in the JSON string but got `%s`", jsonObj.get("countryCode").toString())); + } + if ((jsonObj.get("countryMandate") != null && !jsonObj.get("countryMandate").isJsonNull()) && !jsonObj.get("countryMandate").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `countryMandate` to be a primitive type in the JSON string but got `%s`", jsonObj.get("countryMandate").toString())); + } + if ((jsonObj.get("documentType") != null && !jsonObj.get("documentType").isJsonNull()) && !jsonObj.get("documentType").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `documentType` to be a primitive type in the JSON string but got `%s`", jsonObj.get("documentType").toString())); + } + if ((jsonObj.get("documentSubType") != null && !jsonObj.get("documentSubType").isJsonNull()) && !jsonObj.get("documentSubType").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `documentSubType` to be a primitive type in the JSON string but got `%s`", jsonObj.get("documentSubType").toString())); + } + if ((jsonObj.get("reportReference") != null && !jsonObj.get("reportReference").isJsonNull()) && !jsonObj.get("reportReference").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `reportReference` to be a primitive type in the JSON string but got `%s`", jsonObj.get("reportReference").toString())); + } + if ((jsonObj.get("reportName") != null && !jsonObj.get("reportName").isJsonNull()) && !jsonObj.get("reportName").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `reportName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("reportName").toString())); + } + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `status` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status").toString())); + } + if ((jsonObj.get("reportFormatMimetypes") != null && !jsonObj.get("reportFormatMimetypes").isJsonNull()) && !jsonObj.get("reportFormatMimetypes").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `reportFormatMimetypes` to be a primitive type in the JSON string but got `%s`", jsonObj.get("reportFormatMimetypes").toString())); + } + if ((jsonObj.get("tenantId") != null && !jsonObj.get("tenantId").isJsonNull()) && !jsonObj.get("tenantId").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `tenantId` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tenantId").toString())); + } + if ((jsonObj.get("taName") != null && !jsonObj.get("taName").isJsonNull()) && !jsonObj.get("taName").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `taName` to be a primitive type in the JSON string but got `%s`", jsonObj.get("taName").toString())); + } + // ensure the optional json data is an array if present + if (jsonObj.get("transactionIds") != null && !jsonObj.get("transactionIds").isJsonNull() && !jsonObj.get("transactionIds").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `transactionIds` to be an array in the JSON string but got `%s`", jsonObj.get("transactionIds").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ReportItem.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ReportItem' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(ReportItem.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, ReportItem value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ReportItem read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of ReportItem given an JSON string + * + * @param jsonString JSON string + * @return An instance of ReportItem + * @throws IOException if the JSON string is invalid with respect to ReportItem + */ + public static ReportItem fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ReportItem.class); + } + + /** + * Convert an instance of ReportItem to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportListResponse.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportListResponse.java new file mode 100644 index 0000000..7e92853 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/ReportListResponse.java @@ -0,0 +1,308 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import Avalara.SDK.model.EInvoicing.V1.ReportItem; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Returns the requested list of reports matching the query parameters. + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class ReportListResponse { + public static final String SERIALIZED_NAME_AT_RECORDSET_COUNT = "@recordsetCount"; + @SerializedName(SERIALIZED_NAME_AT_RECORDSET_COUNT) + private String atRecordsetCount; + + public static final String SERIALIZED_NAME_AT_NEXT_LINK = "@nextLink"; + @SerializedName(SERIALIZED_NAME_AT_NEXT_LINK) + private String atNextLink; + + public static final String SERIALIZED_NAME_VALUE = "value"; + @SerializedName(SERIALIZED_NAME_VALUE) + private List value; + + public ReportListResponse() { + } + + public ReportListResponse atRecordsetCount(String atRecordsetCount) { + this.atRecordsetCount = atRecordsetCount; + return this; + } + + /** + * Count of reports matching the filter for the given query. Present when the request includes $count=true. + * @return atRecordsetCount + */ + @javax.annotation.Nullable + public String getAtRecordsetCount() { + return atRecordsetCount; + } + + public void setAtRecordsetCount(String atRecordsetCount) { + this.atRecordsetCount = atRecordsetCount; + } + + + public ReportListResponse atNextLink(String atNextLink) { + this.atNextLink = atNextLink; + return this; + } + + /** + * URL to retrieve the next page of results when more items match the query. Omitted or null when there is no next page. + * @return atNextLink + */ + @javax.annotation.Nullable + public String getAtNextLink() { + return atNextLink; + } + + public void setAtNextLink(String atNextLink) { + this.atNextLink = atNextLink; + } + + + public ReportListResponse value(List value) { + this.value = value; + return this; + } + + public ReportListResponse addValueItem(ReportItem valueItem) { + if (this.value == null) { + this.value = new ArrayList<>(); + } + this.value.add(valueItem); + return this; + } + + /** + * Array of reports matching the query parameters. + * @return value + */ + @javax.annotation.Nonnull + public List getValue() { + return value; + } + + public void setValue(List value) { + this.value = value; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ReportListResponse reportListResponse = (ReportListResponse) o; + return Objects.equals(this.atRecordsetCount, reportListResponse.atRecordsetCount) && + Objects.equals(this.atNextLink, reportListResponse.atNextLink) && + Objects.equals(this.value, reportListResponse.value); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(atRecordsetCount, atNextLink, value); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ReportListResponse {\n"); + sb.append(" atRecordsetCount: ").append(toIndentedString(atRecordsetCount)).append("\n"); + sb.append(" atNextLink: ").append(toIndentedString(atNextLink)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("@recordsetCount"); + openapiFields.add("@nextLink"); + openapiFields.add("value"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + openapiRequiredFields.add("value"); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ReportListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ReportListResponse.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in ReportListResponse is not found in the empty JSON string", ReportListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ReportListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `ReportListResponse` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : ReportListResponse.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException(String.format("The required field `%s` is not found in the JSON string: %s", requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("@recordsetCount") != null && !jsonObj.get("@recordsetCount").isJsonNull()) && !jsonObj.get("@recordsetCount").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `@recordsetCount` to be a primitive type in the JSON string but got `%s`", jsonObj.get("@recordsetCount").toString())); + } + if ((jsonObj.get("@nextLink") != null && !jsonObj.get("@nextLink").isJsonNull()) && !jsonObj.get("@nextLink").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `@nextLink` to be a primitive type in the JSON string but got `%s`", jsonObj.get("@nextLink").toString())); + } + // ensure the json data is an array + if (!jsonObj.get("value").isJsonArray()) { + throw new IllegalArgumentException(String.format("Expected the field `value` to be an array in the JSON string but got `%s`", jsonObj.get("value").toString())); + } + + JsonArray jsonArrayvalue = jsonObj.getAsJsonArray("value"); + // validate the required field `value` (array) + for (int i = 0; i < jsonArrayvalue.size(); i++) { + ReportItem.validateJsonElement(jsonArrayvalue.get(i)); + }; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ReportListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ReportListResponse' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(ReportListResponse.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, ReportListResponse value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ReportListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of ReportListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of ReportListResponse + * @throws IOException if the JSON string is invalid with respect to ReportListResponse + */ + public static ReportListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ReportListResponse.class); + } + + /** + * Convert an instance of ReportListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/StatusEvent.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/StatusEvent.java index 88c8306..db65d5c 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/StatusEvent.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/StatusEvent.java @@ -74,6 +74,10 @@ public class StatusEvent { @SerializedName(SERIALIZED_NAME_RESPONSE_VALUE) private String responseValue; + public static final String SERIALIZED_NAME_CATEGORY = "category"; + @SerializedName(SERIALIZED_NAME_CATEGORY) + private String category; + public StatusEvent() { } @@ -83,7 +87,7 @@ public StatusEvent eventDateTime(String eventDateTime) { } /** - * The date and time when the status event occured, displayed in the format YYYY-MM-DDThh:mm:ss + * The date and time when the status event occurred, displayed in the format YYYY-MM-DDThh:mm:ss * @return eventDateTime */ @javax.annotation.Nullable @@ -153,6 +157,25 @@ public void setResponseValue(String responseValue) { } + public StatusEvent category(String category) { + this.category = category; + return this; + } + + /** + * Represents the functional area or process stage where the status event occurred. Useful for grouping related events such as document processing, transmission, or validation. + * @return category + */ + @javax.annotation.Nullable + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + @Override public boolean equals(Object o) { @@ -166,7 +189,8 @@ public boolean equals(Object o) { return Objects.equals(this.eventDateTime, statusEvent.eventDateTime) && Objects.equals(this.message, statusEvent.message) && Objects.equals(this.responseKey, statusEvent.responseKey) && - Objects.equals(this.responseValue, statusEvent.responseValue); + Objects.equals(this.responseValue, statusEvent.responseValue) && + Objects.equals(this.category, statusEvent.category); } private static boolean equalsNullable(JsonNullable a, JsonNullable b) { @@ -175,7 +199,7 @@ private static boolean equalsNullable(JsonNullable a, JsonNullable b) @Override public int hashCode() { - return Objects.hash(eventDateTime, message, responseKey, responseValue); + return Objects.hash(eventDateTime, message, responseKey, responseValue, category); } private static int hashCodeNullable(JsonNullable a) { @@ -193,6 +217,7 @@ public String toString() { sb.append(" message: ").append(toIndentedString(message)).append("\n"); sb.append(" responseKey: ").append(toIndentedString(responseKey)).append("\n"); sb.append(" responseValue: ").append(toIndentedString(responseValue)).append("\n"); + sb.append(" category: ").append(toIndentedString(category)).append("\n"); sb.append("}"); return sb.toString(); } @@ -219,6 +244,7 @@ private String toIndentedString(Object o) { openapiFields.add("message"); openapiFields.add("responseKey"); openapiFields.add("responseValue"); + openapiFields.add("category"); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(); @@ -257,6 +283,9 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if ((jsonObj.get("responseValue") != null && !jsonObj.get("responseValue").isJsonNull()) && !jsonObj.get("responseValue").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `responseValue` to be a primitive type in the JSON string but got `%s`", jsonObj.get("responseValue").toString())); } + if ((jsonObj.get("category") != null && !jsonObj.get("category").isJsonNull()) && !jsonObj.get("category").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `category` to be a primitive type in the JSON string but got `%s`", jsonObj.get("category").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/SupportedDocumentStatuses.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/SupportedDocumentStatuses.java new file mode 100644 index 0000000..a14db57 --- /dev/null +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/SupportedDocumentStatuses.java @@ -0,0 +1,241 @@ +/* + * AvaTax Software Development Kit for Java (JRE) + * + * (c) 2004-2025 Avalara, Inc. + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + * + * Avalara E-Invoicing API + * + * An API that supports sending data for an E-Invoicing compliance use-case. + * + * @author Sachin Baijal + * @author Jonathan Wenger + * @copyright 2004-2025 Avalara, Inc. + * @license https://www.apache.org/licenses/LICENSE-2.0 + * @link https://github.com/avadev/Avalara-SDK-Java + */ + +package Avalara.SDK.model.EInvoicing.V1; + +import java.util.Objects; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonArray; +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonDeserializer; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParseException; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.TypeAdapter; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; + +import java.lang.reflect.Type; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import Avalara.SDK.JSON; + +/** + * Represents a document status defined by the mandate. + */ +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.7.0") +public class SupportedDocumentStatuses { + public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) + private String status; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public SupportedDocumentStatuses() { + } + + public SupportedDocumentStatuses status(String status) { + this.status = status; + return this; + } + + /** + * The name of the status (e.g., Approved, Fully Paid). + * @return status + */ + @javax.annotation.Nullable + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + + public SupportedDocumentStatuses description(String description) { + this.description = description; + return this; + } + + /** + * Explanation of what the status means. + * @return description + */ + @javax.annotation.Nullable + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SupportedDocumentStatuses supportedDocumentStatuses = (SupportedDocumentStatuses) o; + return Objects.equals(this.status, supportedDocumentStatuses.status) && + Objects.equals(this.description, supportedDocumentStatuses.description); + } + + @Override + public int hashCode() { + return Objects.hash(status, description); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SupportedDocumentStatuses {\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(); + openapiFields.add("status"); + openapiFields.add("description"); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to SupportedDocumentStatuses + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!SupportedDocumentStatuses.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException(String.format("The required field(s) %s in SupportedDocumentStatuses is not found in the empty JSON string", SupportedDocumentStatuses.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!SupportedDocumentStatuses.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `SupportedDocumentStatuses` properties. JSON: %s", entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `status` to be a primitive type in the JSON string but got `%s`", jsonObj.get("status").toString())); + } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `description` to be a primitive type in the JSON string but got `%s`", jsonObj.get("description").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!SupportedDocumentStatuses.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'SupportedDocumentStatuses' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter + = gson.getDelegateAdapter(this, TypeToken.get(SupportedDocumentStatuses.class)); + + return (TypeAdapter) new TypeAdapter() { + @Override + public void write(JsonWriter out, SupportedDocumentStatuses value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public SupportedDocumentStatuses read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + + }.nullSafe(); + } + } + + /** + * Create an instance of SupportedDocumentStatuses given an JSON string + * + * @param jsonString JSON string + * @return An instance of SupportedDocumentStatuses + * @throws IOException if the JSON string is invalid with respect to SupportedDocumentStatuses + */ + public static SupportedDocumentStatuses fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, SupportedDocumentStatuses.class); + } + + /** + * Convert an instance of SupportedDocumentStatuses to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} + diff --git a/src/main/java/Avalara/SDK/model/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.java b/src/main/java/Avalara/SDK/model/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.java index ed39c60..0c5631b 100644 --- a/src/main/java/Avalara/SDK/model/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.java +++ b/src/main/java/Avalara/SDK/model/EInvoicing/V1/TaxIdentifierSchemaByCountry200Response.java @@ -61,6 +61,10 @@ public class TaxIdentifierSchemaByCountry200Response { @SerializedName(SERIALIZED_NAME_COUNTRY_CODE) private String countryCode; + public static final String SERIALIZED_NAME_SCHEMA_TYPE = "schemaType"; + @SerializedName(SERIALIZED_NAME_SCHEMA_TYPE) + private String schemaType; + public static final String SERIALIZED_NAME_SCHEMA = "schema"; @SerializedName(SERIALIZED_NAME_SCHEMA) private Object schema; @@ -87,6 +91,25 @@ public void setCountryCode(String countryCode) { } + public TaxIdentifierSchemaByCountry200Response schemaType(String schemaType) { + this.schemaType = schemaType; + return this; + } + + /** + * The type of schema returned: \"request\" or \"response\". + * @return schemaType + */ + @javax.annotation.Nonnull + public String getSchemaType() { + return schemaType; + } + + public void setSchemaType(String schemaType) { + this.schemaType = schemaType; + } + + public TaxIdentifierSchemaByCountry200Response schema(Object schema) { this.schema = schema; return this; @@ -117,12 +140,13 @@ public boolean equals(Object o) { } TaxIdentifierSchemaByCountry200Response taxIdentifierSchemaByCountry200Response = (TaxIdentifierSchemaByCountry200Response) o; return Objects.equals(this.countryCode, taxIdentifierSchemaByCountry200Response.countryCode) && + Objects.equals(this.schemaType, taxIdentifierSchemaByCountry200Response.schemaType) && Objects.equals(this.schema, taxIdentifierSchemaByCountry200Response.schema); } @Override public int hashCode() { - return Objects.hash(countryCode, schema); + return Objects.hash(countryCode, schemaType, schema); } @Override @@ -130,6 +154,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class TaxIdentifierSchemaByCountry200Response {\n"); sb.append(" countryCode: ").append(toIndentedString(countryCode)).append("\n"); + sb.append(" schemaType: ").append(toIndentedString(schemaType)).append("\n"); sb.append(" schema: ").append(toIndentedString(schema)).append("\n"); sb.append("}"); return sb.toString(); @@ -154,11 +179,13 @@ private String toIndentedString(Object o) { // a set of all properties/fields (JSON key names) openapiFields = new HashSet(); openapiFields.add("countryCode"); + openapiFields.add("schemaType"); openapiFields.add("schema"); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(); openapiRequiredFields.add("countryCode"); + openapiRequiredFields.add("schemaType"); openapiRequiredFields.add("schema"); } @@ -193,6 +220,9 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti if (!jsonObj.get("countryCode").isJsonPrimitive()) { throw new IllegalArgumentException(String.format("Expected the field `countryCode` to be a primitive type in the JSON string but got `%s`", jsonObj.get("countryCode").toString())); } + if (!jsonObj.get("schemaType").isJsonPrimitive()) { + throw new IllegalArgumentException(String.format("Expected the field `schemaType` to be a primitive type in the JSON string but got `%s`", jsonObj.get("schemaType").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { From 916a73e1ff3074d67059de801f373ab2bc1d12fb Mon Sep 17 00:00:00 2001 From: "svc.developer" Date: Thu, 16 Apr 2026 11:58:32 -0700 Subject: [PATCH 2/2] Regenerate SDK with fixed imports --- README.md | 97 +++++++++++++++++++ docs/A1099/V2/CompaniesW9Api.md | 10 +- docs/A1099/V2/Form1042S.md | 2 +- docs/A1099/V2/Forms1099Api.md | 14 +-- docs/A1099/V2/FormsW9Api.md | 18 ++-- docs/A1099/V2/Get1099Form200Response.md | 2 +- docs/A1099/V2/Issuers1099Api.md | 10 +- docs/A1099/V2/JobResponse.md | 2 +- docs/A1099/V2/JobsApi.md | 2 +- pom.xml | 2 +- src/main/java/Avalara/SDK/JSON.java | 4 +- .../SDK/api/A1099/V2/CompaniesW9Api.java | 2 +- .../SDK/api/A1099/V2/Forms1099Api.java | 2 +- .../Avalara/SDK/api/A1099/V2/FormsW9Api.java | 2 +- .../SDK/api/A1099/V2/Issuers1099Api.java | 2 +- .../Avalara/SDK/api/A1099/V2/JobsApi.java | 2 +- .../Avalara/SDK/model/A1099/V2/Form1042S.java | 4 +- .../SDK/model/A1099/V2/JobResponse.java | 2 +- 18 files changed, 138 insertions(+), 41 deletions(-) diff --git a/README.md b/README.md index 7672401..a301db7 100644 --- a/README.md +++ b/README.md @@ -139,6 +139,39 @@ Class | Method | HTTP request | Description *TradingPartnersApi* | [**searchParticipants**](docs/EInvoicing/V1/TradingPartnersApi.md#searchparticipants) | **GET** /trading-partners | Returns a list of participants matching the input query. *TradingPartnersApi* | [**updateTradingPartner**](docs/EInvoicing/V1/TradingPartnersApi.md#updatetradingpartner) | **PUT** /trading-partners/{id} | Updates a trading partner using ID. + +### A1099 V2 API Documentation + +Class | Method | HTTP request | Description +------------ | ------------- | ------------- | ------------- +*CompaniesW9Api* | [**createCompany**](docs/A1099/V2/CompaniesW9Api.md#createcompany) | **POST** /w9/companies | Create a company +*CompaniesW9Api* | [**deleteCompany**](docs/A1099/V2/CompaniesW9Api.md#deletecompany) | **DELETE** /w9/companies/{id} | Delete a company +*CompaniesW9Api* | [**getCompanies**](docs/A1099/V2/CompaniesW9Api.md#getcompanies) | **GET** /w9/companies | List companies +*CompaniesW9Api* | [**getCompany**](docs/A1099/V2/CompaniesW9Api.md#getcompany) | **GET** /w9/companies/{id} | Retrieve a company +*CompaniesW9Api* | [**updateCompany**](docs/A1099/V2/CompaniesW9Api.md#updatecompany) | **PUT** /w9/companies/{id} | Update a company +*Forms1099Api* | [**bulkUpsert1099Forms**](docs/A1099/V2/Forms1099Api.md#bulkupsert1099forms) | **POST** /1099/forms/$bulk-upsert | Create or update multiple 1099/1095/W2/1042S forms +*Forms1099Api* | [**create1099Form**](docs/A1099/V2/Forms1099Api.md#create1099form) | **POST** /1099/forms | Create a 1099/1095/W2/1042S form +*Forms1099Api* | [**delete1099Form**](docs/A1099/V2/Forms1099Api.md#delete1099form) | **DELETE** /1099/forms/{id} | Delete a 1099/1095/W2/1042S form +*Forms1099Api* | [**get1099Form**](docs/A1099/V2/Forms1099Api.md#get1099form) | **GET** /1099/forms/{id} | Retrieve a 1099/1095/W2/1042S form +*Forms1099Api* | [**get1099FormPdf**](docs/A1099/V2/Forms1099Api.md#get1099formpdf) | **GET** /1099/forms/{id}/pdf | Retrieve the PDF file for a 1099/1095/W2/1042S form +*Forms1099Api* | [**list1099Forms**](docs/A1099/V2/Forms1099Api.md#list1099forms) | **GET** /1099/forms | List 1099/1095/W2/1042S forms +*Forms1099Api* | [**update1099Form**](docs/A1099/V2/Forms1099Api.md#update1099form) | **PUT** /1099/forms/{id} | Update a 1099/1095/W2/1042S form +*FormsW9Api* | [**createAndSendW9FormEmail**](docs/A1099/V2/FormsW9Api.md#createandsendw9formemail) | **POST** /w9/forms/$create-and-send-email | Create a minimal W9/W4/W8 form and sends the e-mail request +*FormsW9Api* | [**createW9Form**](docs/A1099/V2/FormsW9Api.md#createw9form) | **POST** /w9/forms | Create a W9/W4/W8 form +*FormsW9Api* | [**deleteW9Form**](docs/A1099/V2/FormsW9Api.md#deletew9form) | **DELETE** /w9/forms/{id} | Delete a W9/W4/W8 form +*FormsW9Api* | [**getW9Form**](docs/A1099/V2/FormsW9Api.md#getw9form) | **GET** /w9/forms/{id} | Retrieve a W9/W4/W8 form +*FormsW9Api* | [**getW9FormPdf**](docs/A1099/V2/FormsW9Api.md#getw9formpdf) | **GET** /w9/forms/{id}/pdf | Download the PDF for a W9/W4/W8 form. +*FormsW9Api* | [**listW9Forms**](docs/A1099/V2/FormsW9Api.md#listw9forms) | **GET** /w9/forms | List W9/W4/W8 forms +*FormsW9Api* | [**sendW9FormEmail**](docs/A1099/V2/FormsW9Api.md#sendw9formemail) | **POST** /w9/forms/{id}/$send-email | Send an email to the vendor/payee requesting they fill out a W9/W4/W8 form +*FormsW9Api* | [**updateW9Form**](docs/A1099/V2/FormsW9Api.md#updatew9form) | **PUT** /w9/forms/{id} | Update a W9/W4/W8 form +*FormsW9Api* | [**uploadW9Files**](docs/A1099/V2/FormsW9Api.md#uploadw9files) | **POST** /w9/forms/{id}/attachment | Replace the PDF file for a W9/W4/W8 form +*Issuers1099Api* | [**createIssuer**](docs/A1099/V2/Issuers1099Api.md#createissuer) | **POST** /1099/issuers | Create an issuer +*Issuers1099Api* | [**deleteIssuer**](docs/A1099/V2/Issuers1099Api.md#deleteissuer) | **DELETE** /1099/issuers/{id} | Delete an issuer +*Issuers1099Api* | [**getIssuer**](docs/A1099/V2/Issuers1099Api.md#getissuer) | **GET** /1099/issuers/{id} | Retrieve an issuer +*Issuers1099Api* | [**getIssuers**](docs/A1099/V2/Issuers1099Api.md#getissuers) | **GET** /1099/issuers | List issuers +*Issuers1099Api* | [**updateIssuer**](docs/A1099/V2/Issuers1099Api.md#updateissuer) | **PUT** /1099/issuers/{id} | Update an issuer +*JobsApi* | [**getJob**](docs/A1099/V2/JobsApi.md#getjob) | **GET** /jobs/{id} | Retrieves information about the job + ## Documentation for Models @@ -228,3 +261,67 @@ Class | Method | HTTP request | Description - [Avalara.SDK.model.EInvoicing.V1.WebhooksErrorInfo](docs/EInvoicing/V1/WebhooksErrorInfo.md) - [Avalara.SDK.model.EInvoicing.V1.WebhooksErrorResponse](docs/EInvoicing/V1/WebhooksErrorResponse.md) - [Avalara.SDK.model.EInvoicing.V1.WorkflowIds](docs/EInvoicing/V1/WorkflowIds.md) + + + +### A1099 V2 Model Documentation + + - [Avalara.SDK.model.A1099.V2.CompanyBase](docs/A1099/V2/CompanyBase.md) + - [Avalara.SDK.model.A1099.V2.CompanyRequest](docs/A1099/V2/CompanyRequest.md) + - [Avalara.SDK.model.A1099.V2.CompanyResponse](docs/A1099/V2/CompanyResponse.md) + - [Avalara.SDK.model.A1099.V2.CoveredIndividual](docs/A1099/V2/CoveredIndividual.md) + - [Avalara.SDK.model.A1099.V2.CreateAndSendW9FormEmailRequest](docs/A1099/V2/CreateAndSendW9FormEmailRequest.md) + - [Avalara.SDK.model.A1099.V2.CreateW9Form201Response](docs/A1099/V2/CreateW9Form201Response.md) + - [Avalara.SDK.model.A1099.V2.CreateW9FormRequest](docs/A1099/V2/CreateW9FormRequest.md) + - [Avalara.SDK.model.A1099.V2.EntryStatusResponse](docs/A1099/V2/EntryStatusResponse.md) + - [Avalara.SDK.model.A1099.V2.ErrorResponse](docs/A1099/V2/ErrorResponse.md) + - [Avalara.SDK.model.A1099.V2.ErrorResponseItem](docs/A1099/V2/ErrorResponseItem.md) + - [Avalara.SDK.model.A1099.V2.Form1042S](docs/A1099/V2/Form1042S.md) + - [Avalara.SDK.model.A1099.V2.Form1095B](docs/A1099/V2/Form1095B.md) + - [Avalara.SDK.model.A1099.V2.Form1095C](docs/A1099/V2/Form1095C.md) + - [Avalara.SDK.model.A1099.V2.Form1099Base](docs/A1099/V2/Form1099Base.md) + - [Avalara.SDK.model.A1099.V2.Form1099Div](docs/A1099/V2/Form1099Div.md) + - [Avalara.SDK.model.A1099.V2.Form1099Int](docs/A1099/V2/Form1099Int.md) + - [Avalara.SDK.model.A1099.V2.Form1099K](docs/A1099/V2/Form1099K.md) + - [Avalara.SDK.model.A1099.V2.Form1099ListRequest](docs/A1099/V2/Form1099ListRequest.md) + - [Avalara.SDK.model.A1099.V2.Form1099Misc](docs/A1099/V2/Form1099Misc.md) + - [Avalara.SDK.model.A1099.V2.Form1099Nec](docs/A1099/V2/Form1099Nec.md) + - [Avalara.SDK.model.A1099.V2.Form1099R](docs/A1099/V2/Form1099R.md) + - [Avalara.SDK.model.A1099.V2.Form1099StatusDetail](docs/A1099/V2/Form1099StatusDetail.md) + - [Avalara.SDK.model.A1099.V2.Get1099Form200Response](docs/A1099/V2/Get1099Form200Response.md) + - [Avalara.SDK.model.A1099.V2.IntermediaryOrFlowThrough](docs/A1099/V2/IntermediaryOrFlowThrough.md) + - [Avalara.SDK.model.A1099.V2.IrsResponse](docs/A1099/V2/IrsResponse.md) + - [Avalara.SDK.model.A1099.V2.IssuerBase](docs/A1099/V2/IssuerBase.md) + - [Avalara.SDK.model.A1099.V2.IssuerRequest](docs/A1099/V2/IssuerRequest.md) + - [Avalara.SDK.model.A1099.V2.IssuerResponse](docs/A1099/V2/IssuerResponse.md) + - [Avalara.SDK.model.A1099.V2.JobResponse](docs/A1099/V2/JobResponse.md) + - [Avalara.SDK.model.A1099.V2.OfferAndCoverage](docs/A1099/V2/OfferAndCoverage.md) + - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelCompanyResponse](docs/A1099/V2/PaginatedQueryResultModelCompanyResponse.md) + - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelForm1099Base](docs/A1099/V2/PaginatedQueryResultModelForm1099Base.md) + - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelIssuerResponse](docs/A1099/V2/PaginatedQueryResultModelIssuerResponse.md) + - [Avalara.SDK.model.A1099.V2.PaginatedQueryResultModelW9FormBaseResponse](docs/A1099/V2/PaginatedQueryResultModelW9FormBaseResponse.md) + - [Avalara.SDK.model.A1099.V2.PrimaryWithholdingAgent](docs/A1099/V2/PrimaryWithholdingAgent.md) + - [Avalara.SDK.model.A1099.V2.StateAndLocalWithholding](docs/A1099/V2/StateAndLocalWithholding.md) + - [Avalara.SDK.model.A1099.V2.StateEfileStatusDetail](docs/A1099/V2/StateEfileStatusDetail.md) + - [Avalara.SDK.model.A1099.V2.SubstantialUsOwnerRequest](docs/A1099/V2/SubstantialUsOwnerRequest.md) + - [Avalara.SDK.model.A1099.V2.SubstantialUsOwnerResponse](docs/A1099/V2/SubstantialUsOwnerResponse.md) + - [Avalara.SDK.model.A1099.V2.TinMatchStatusResponse](docs/A1099/V2/TinMatchStatusResponse.md) + - [Avalara.SDK.model.A1099.V2.ValidationError](docs/A1099/V2/ValidationError.md) + - [Avalara.SDK.model.A1099.V2.W4FormMinimalRequest](docs/A1099/V2/W4FormMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W4FormRequest](docs/A1099/V2/W4FormRequest.md) + - [Avalara.SDK.model.A1099.V2.W4FormResponse](docs/A1099/V2/W4FormResponse.md) + - [Avalara.SDK.model.A1099.V2.W8BenEFormMinimalRequest](docs/A1099/V2/W8BenEFormMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W8BenEFormRequest](docs/A1099/V2/W8BenEFormRequest.md) + - [Avalara.SDK.model.A1099.V2.W8BenEFormResponse](docs/A1099/V2/W8BenEFormResponse.md) + - [Avalara.SDK.model.A1099.V2.W8BenFormMinimalRequest](docs/A1099/V2/W8BenFormMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W8BenFormRequest](docs/A1099/V2/W8BenFormRequest.md) + - [Avalara.SDK.model.A1099.V2.W8BenFormResponse](docs/A1099/V2/W8BenFormResponse.md) + - [Avalara.SDK.model.A1099.V2.W8ImyFormMinimalRequest](docs/A1099/V2/W8ImyFormMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W8ImyFormRequest](docs/A1099/V2/W8ImyFormRequest.md) + - [Avalara.SDK.model.A1099.V2.W8ImyFormResponse](docs/A1099/V2/W8ImyFormResponse.md) + - [Avalara.SDK.model.A1099.V2.W9FormBaseMinimalRequest](docs/A1099/V2/W9FormBaseMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W9FormBaseRequest](docs/A1099/V2/W9FormBaseRequest.md) + - [Avalara.SDK.model.A1099.V2.W9FormBaseResponse](docs/A1099/V2/W9FormBaseResponse.md) + - [Avalara.SDK.model.A1099.V2.W9FormMinimalRequest](docs/A1099/V2/W9FormMinimalRequest.md) + - [Avalara.SDK.model.A1099.V2.W9FormRequest](docs/A1099/V2/W9FormRequest.md) + - [Avalara.SDK.model.A1099.V2.W9FormResponse](docs/A1099/V2/W9FormResponse.md) diff --git a/docs/A1099/V2/CompaniesW9Api.md b/docs/A1099/V2/CompaniesW9Api.md index 3193559..250bef5 100644 --- a/docs/A1099/V2/CompaniesW9Api.md +++ b/docs/A1099/V2/CompaniesW9Api.md @@ -49,7 +49,7 @@ public class Example { CompaniesW9Api apiInstance = new CompaniesW9Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "045715ac-dfd3-4f63-ba82-2276c5cb9c7b"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "97d2460b-1098-409f-b4cc-04e39b867ac8"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . CompanyRequest companyRequest = new CompanyRequest(); // CompanyRequest | The company to create try { @@ -136,7 +136,7 @@ public class Example { CompaniesW9Api apiInstance = new CompaniesW9Api(apiClient); String id = "id_example"; // String | The company to delete String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "bdfb4c9b-5dd4-45c3-8dad-630ba1d31df1"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "4ec8a3b4-c6be-4e60-94c4-ae8661c47a12"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { apiInstance.deleteCompany(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -228,7 +228,7 @@ public class Example { String $orderBy = "$orderBy_example"; // String | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. Boolean count = true; // Boolean | If true, return the global count of elements in the collection. Boolean countOnly = true; // Boolean | If true, return ONLY the global count of elements in the collection. It only applies when count=true. - String xCorrelationId = "d8c76c7d-ddae-47da-bfde-e696155b0689"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "b1a92345-e5dd-42c7-99ae-01cc5ad078f1"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { PaginatedQueryResultModelCompanyResponse result = apiInstance.getCompanies(avalaraVersion, $filter, $top, $skip, $orderBy, count, countOnly, xCorrelationId, xAvalaraClient); @@ -321,7 +321,7 @@ public class Example { CompaniesW9Api apiInstance = new CompaniesW9Api(apiClient); String id = "id_example"; // String | Id of the company String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "e0312268-c9e8-4db6-95bd-99d216095728"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "c6651d03-30d8-45b7-bf8e-ae3535bca324"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { CompanyResponse result = apiInstance.getCompany(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -409,7 +409,7 @@ public class Example { CompaniesW9Api apiInstance = new CompaniesW9Api(apiClient); String id = "id_example"; // String | The ID of the company to update String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "715aa1d1-d1b9-4d18-adb3-fffb9e26c197"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "126047bb-383f-4315-a3fa-7517c763abd7"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . CompanyRequest companyRequest = new CompanyRequest(); // CompanyRequest | The updated company data try { diff --git a/docs/A1099/V2/Form1042S.md b/docs/A1099/V2/Form1042S.md index 42c71ee..072d1ed 100644 --- a/docs/A1099/V2/Form1042S.md +++ b/docs/A1099/V2/Form1042S.md @@ -18,7 +18,7 @@ Form 1042-S: Foreign Person's U.S. Source Income Subject to Withholding |**grossIncome** | **Double** | Gross income | | |**withholdingIndicator** | [**WithholdingIndicatorEnum**](#WithholdingIndicatorEnum) | Withholding indicator Available values: - 3: Chapter 3 - 4: Chapter 4 | | |**taxCountryCode** | **String** | Country code | | -|**exemptionCodeChap3** | [**ExemptionCodeChap3Enum**](#ExemptionCodeChap3Enum) | 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] | +|**exemptionCodeChap3** | [**ExemptionCodeChap3Enum**](#ExemptionCodeChap3Enum) | Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3) and FederalTaxWithheld is 0. Required when using TaxRateChap3. Can be left empty if FederalTaxWithheld is greater than 0. Available values: - 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] | |**exemptionCodeChap4** | [**ExemptionCodeChap4Enum**](#ExemptionCodeChap4Enum) | 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] | |**taxRateChap3** | [**TaxRateChap3Enum**](#TaxRateChap3Enum) | 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] | |**withholdingAllowance** | **Double** | Withholding allowance | [optional] | diff --git a/docs/A1099/V2/Forms1099Api.md b/docs/A1099/V2/Forms1099Api.md index 3852cfd..13ab3f0 100644 --- a/docs/A1099/V2/Forms1099Api.md +++ b/docs/A1099/V2/Forms1099Api.md @@ -52,7 +52,7 @@ public class Example { Forms1099Api apiInstance = new Forms1099Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version Boolean dryRun = false; // Boolean | 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 - String xCorrelationId = "6e64cd85-8016-4753-83f5-e78c041e8ab1"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "16597cea-e46f-4db1-a91a-758d08c8a6d9"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . Form1099ListRequest form1099ListRequest = new Form1099ListRequest(); // Form1099ListRequest | try { @@ -141,7 +141,7 @@ public class Example { Forms1099Api apiInstance = new Forms1099Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "05146ed0-5ef3-4d21-a139-bceaf30183da"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "8aae2aaf-fdeb-4a36-965c-81ba3d884563"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . Get1099Form200Response get1099Form200Response = new Get1099Form200Response(); // Get1099Form200Response | try { @@ -229,7 +229,7 @@ public class Example { Forms1099Api apiInstance = new Forms1099Api(apiClient); String id = "id_example"; // String | The unique identifier of the desired form to delete. String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "dfa0ca1e-71ad-4ea3-b2a0-e33a88ae9418"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "0e5923f5-6d5b-4e68-947c-e4465872098b"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { apiInstance.delete1099Form(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -317,7 +317,7 @@ public class Example { Forms1099Api apiInstance = new Forms1099Api(apiClient); String id = "id_example"; // String | String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "7cee7d23-fb69-4dd0-bbb5-e2afaf72a72e"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "5c29014d-312a-43e6-8cba-1d7ff8bf4823"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { Get1099Form200Response result = apiInstance.get1099Form(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -406,7 +406,7 @@ public class Example { String id = "id_example"; // String | The ID of the form String avalaraVersion = "2.0.0"; // String | API version Boolean markEdelivered = true; // Boolean | Optional boolean that if set indicates that the form should be marked as having been successfully edelivered - String xCorrelationId = "751b64d2-bcd9-46d8-a671-cb88f65b2eb7"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "a9c3fd5f-7dcc-400b-b490-2575a0676f13"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { File result = apiInstance.get1099FormPdf(id, avalaraVersion, markEdelivered, xCorrelationId, xAvalaraClient); @@ -500,7 +500,7 @@ public class Example { String $orderBy = "$orderBy_example"; // String | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. Boolean count = true; // Boolean | If true, return the global count of elements in the collection. Boolean countOnly = true; // Boolean | If true, return ONLY the global count of elements in the collection. It only applies when count=true. - String xCorrelationId = "a5957b23-68b0-4987-b6d8-6f2246d72c27"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "f7949787-9b74-49ad-8d7a-272b8130955e"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { PaginatedQueryResultModelForm1099Base result = apiInstance.list1099Forms(avalaraVersion, $filter, $top, $skip, $orderBy, count, countOnly, xCorrelationId, xAvalaraClient); @@ -593,7 +593,7 @@ public class Example { Forms1099Api apiInstance = new Forms1099Api(apiClient); String id = "id_example"; // String | String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "f907e539-ce8b-4d8d-846e-793f9d00ba77"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "0a063fc3-fd55-4b2a-8c61-c80274261cf3"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . Get1099Form200Response get1099Form200Response = new Get1099Form200Response(); // Get1099Form200Response | try { diff --git a/docs/A1099/V2/FormsW9Api.md b/docs/A1099/V2/FormsW9Api.md index 23f1301..88046ce 100644 --- a/docs/A1099/V2/FormsW9Api.md +++ b/docs/A1099/V2/FormsW9Api.md @@ -53,7 +53,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "f288b7a0-8ae8-4fa4-a0e1-b294d597b7a3"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "4d29bf91-6be1-4a09-bd76-947e39261873"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . CreateAndSendW9FormEmailRequest createAndSendW9FormEmailRequest = new CreateAndSendW9FormEmailRequest(); // CreateAndSendW9FormEmailRequest | Form to be created try { @@ -139,7 +139,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "0508a682-ec3b-4686-9f1c-800b1c16cb02"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "c9a65bdc-4b34-4939-8390-0745224fc66f"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . CreateW9FormRequest createW9FormRequest = new CreateW9FormRequest(); // CreateW9FormRequest | Form to be created try { @@ -226,7 +226,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | ID of the form to delete String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "b6cde878-ee95-404d-864e-46cd2d3e3e85"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "de36a366-a0c7-4737-b8b3-3e7dc439eeba"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { apiInstance.deleteW9Form(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -311,7 +311,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | ID of the form String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "6923a86c-3ac5-4826-8b32-b6f5c04bd49b"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "41f07c7e-6c04-47f0-8128-2435ddabd6d2"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { CreateW9Form201Response result = apiInstance.getW9Form(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -397,7 +397,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | Id of the form String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "f14992b5-c401-4059-a78e-5e4f4f389334"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "49aef38a-c6e6-4cd3-9ae2-fc4ed665b4da"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { File result = apiInstance.getW9FormPdf(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -489,7 +489,7 @@ public class Example { String $orderBy = "$orderBy_example"; // String | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. Boolean count = true; // Boolean | If true, return the global count of elements in the collection. Boolean countOnly = true; // Boolean | If true, return ONLY the global count of elements in the collection. It only applies when count=true. - String xCorrelationId = "99af27b9-a391-417e-a443-69f93286eb92"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "cff54571-fafe-44b4-99e0-37026ce17a01"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { PaginatedQueryResultModelW9FormBaseResponse result = apiInstance.listW9Forms(avalaraVersion, $filter, $top, $skip, $orderBy, count, countOnly, xCorrelationId, xAvalaraClient); @@ -580,7 +580,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | The ID of the W9/W4/W8 form. String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "af3f06c2-8e69-4ce1-b283-a387ea3e7763"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "72c78ed0-b02b-45a5-a37a-472f6d418e59"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { CreateW9Form201Response result = apiInstance.sendW9FormEmail(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -668,7 +668,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | ID of the form to update String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "605a2261-2ae9-46f7-b597-d2e88867e827"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "bc850418-16cb-4f71-9a01-811ae3893214"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . CreateW9FormRequest createW9FormRequest = new CreateW9FormRequest(); // CreateW9FormRequest | Form to be updated try { @@ -757,7 +757,7 @@ public class Example { FormsW9Api apiInstance = new FormsW9Api(apiClient); String id = "id_example"; // String | Id of the form String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "57662456-54a0-47c9-a5c5-4fe315a77ae7"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "394e168a-5a3b-4544-b400-5c58fef28209"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . File _file = new File("/path/to/file"); // File | try { diff --git a/docs/A1099/V2/Get1099Form200Response.md b/docs/A1099/V2/Get1099Form200Response.md index a79c63e..ece7811 100644 --- a/docs/A1099/V2/Get1099Form200Response.md +++ b/docs/A1099/V2/Get1099Form200Response.md @@ -17,7 +17,7 @@ |**grossIncome** | **Double** | Gross income | | |**withholdingIndicator** | [**WithholdingIndicatorEnum**](#WithholdingIndicatorEnum) | Withholding indicator Available values: - 3: Chapter 3 - 4: Chapter 4 | | |**taxCountryCode** | **String** | Country code | | -|**exemptionCodeChap3** | [**ExemptionCodeChap3Enum**](#ExemptionCodeChap3Enum) | 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] | +|**exemptionCodeChap3** | [**ExemptionCodeChap3Enum**](#ExemptionCodeChap3Enum) | Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3) and FederalTaxWithheld is 0. Required when using TaxRateChap3. Can be left empty if FederalTaxWithheld is greater than 0. Available values: - 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] | |**exemptionCodeChap4** | [**ExemptionCodeChap4Enum**](#ExemptionCodeChap4Enum) | 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] | |**taxRateChap3** | [**TaxRateChap3Enum**](#TaxRateChap3Enum) | 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] | |**withholdingAllowance** | **Double** | Withholding allowance | [optional] | diff --git a/docs/A1099/V2/Issuers1099Api.md b/docs/A1099/V2/Issuers1099Api.md index d904f97..6ca2991 100644 --- a/docs/A1099/V2/Issuers1099Api.md +++ b/docs/A1099/V2/Issuers1099Api.md @@ -49,7 +49,7 @@ public class Example { Issuers1099Api apiInstance = new Issuers1099Api(apiClient); String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "1b668e82-569a-4e33-9b59-496c627c5239"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "5d8fb58b-669f-47b1-910f-cfa0e599946e"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . IssuerRequest issuerRequest = new IssuerRequest(); // IssuerRequest | The issuer to create try { @@ -136,7 +136,7 @@ public class Example { Issuers1099Api apiInstance = new Issuers1099Api(apiClient); String id = "id_example"; // String | Id of the issuer to delete String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "af861a36-f0a6-4e6c-aa8b-c4ca6b715a26"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "0161282d-23f6-4676-8d92-ff2198d6a01b"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { apiInstance.deleteIssuer(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -221,7 +221,7 @@ public class Example { Issuers1099Api apiInstance = new Issuers1099Api(apiClient); String id = "id_example"; // String | Id of the issuer to retrieve String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "d72af416-f173-416a-9eb6-fa3cb5ea2028"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "d8863721-9e3a-4f50-835c-9609b13b0490"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { IssuerResponse result = apiInstance.getIssuer(id, avalaraVersion, xCorrelationId, xAvalaraClient); @@ -312,7 +312,7 @@ public class Example { String $orderBy = "$orderBy_example"; // String | A comma separated list of sort statements in the format (fieldname) [ASC|DESC], for example id ASC. Boolean count = true; // Boolean | If true, return the global count of elements in the collection. Boolean countOnly = true; // Boolean | If true, return ONLY the global count of elements in the collection. It only applies when count=true. - String xCorrelationId = "954f179a-8653-47ca-a40f-d7ee9ff36a61"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "929b65ac-06d8-4e87-9af9-ac70f6d9de15"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { PaginatedQueryResultModelIssuerResponse result = apiInstance.getIssuers(avalaraVersion, $filter, $top, $skip, $orderBy, count, countOnly, xCorrelationId, xAvalaraClient); @@ -405,7 +405,7 @@ public class Example { Issuers1099Api apiInstance = new Issuers1099Api(apiClient); String id = "id_example"; // String | Id of the issuer to update String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "59fe2706-9acd-4fc3-8cd9-a575e82916d6"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "ee922b56-cd3a-402f-9684-491ed934c165"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . IssuerRequest issuerRequest = new IssuerRequest(); // IssuerRequest | The issuer to update try { diff --git a/docs/A1099/V2/JobResponse.md b/docs/A1099/V2/JobResponse.md index 0e9e689..18f01b4 100644 --- a/docs/A1099/V2/JobResponse.md +++ b/docs/A1099/V2/JobResponse.md @@ -18,7 +18,7 @@ Response model for job operations |**updatedNoEmail** | **Integer** | 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] | |**updatedInvalid** | **Integer** | Number of forms updated but invalid for e-filing. Value can be 0 or another value based on what the job has available | [optional] | |**skippedDuplicate** | **Integer** | 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] | -|**skippedInvalid** | **Integer** | 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] | +|**skippedInvalid** | **Integer** | Number of forms skipped because they would have made a form invalid and the form is already e-filed or scheduled for e-filing, or because you do not have permission to update forms that have been scheduled. Value can be 0 or another value based on what the job has available | [optional] | |**skippedMultipleMatches** | **Integer** | Number of forms skipped because they matched multiple forms. Value can be 0 or another value based on what the job has available | [optional] | |**notFound** | **Integer** | 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] | |**createdInvalid** | **Integer** | 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] | diff --git a/docs/A1099/V2/JobsApi.md b/docs/A1099/V2/JobsApi.md index f3a16d3..4272e2e 100644 --- a/docs/A1099/V2/JobsApi.md +++ b/docs/A1099/V2/JobsApi.md @@ -46,7 +46,7 @@ public class Example { JobsApi apiInstance = new JobsApi(apiClient); String id = "id_example"; // String | Job id obtained from other API responses, like `/1099/bulk-upsert`. String avalaraVersion = "2.0.0"; // String | API version - String xCorrelationId = "404add46-17ce-4740-8684-de29503d6500"; // String | Unique correlation Id in a GUID format + String xCorrelationId = "a944f1ad-48d9-4ff0-b23f-69bf4ceffc12"; // String | Unique correlation Id in a GUID format String xAvalaraClient = "Swagger UI; 22.1.0"; // String | 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/) . try { JobResponse result = apiInstance.getJob(id, avalaraVersion, xCorrelationId, xAvalaraClient); diff --git a/pom.xml b/pom.xml index 24c35bb..3674f4e 100644 --- a/pom.xml +++ b/pom.xml @@ -17,7 +17,7 @@ Unlicense - http://unlicense.org + https://www.apache.org/licenses/LICENSE-2.0.html repo diff --git a/src/main/java/Avalara/SDK/JSON.java b/src/main/java/Avalara/SDK/JSON.java index 5f045e9..b7b6bfc 100644 --- a/src/main/java/Avalara/SDK/JSON.java +++ b/src/main/java/Avalara/SDK/JSON.java @@ -13,8 +13,8 @@ import java.time.LocalDate; import java.time.OffsetDateTime; import java.time.format.DateTimeFormatter; -import Avalara.SDK.model.EInvoicing.V1*; -import Avalara.SDK.model.A1099.V2*; +import Avalara.SDK.model.EInvoicing.V1.*; +import Avalara.SDK.model.A1099.V2.*; import okio.ByteString; diff --git a/src/main/java/Avalara/SDK/api/A1099/V2/CompaniesW9Api.java b/src/main/java/Avalara/SDK/api/A1099/V2/CompaniesW9Api.java index 3a0c400..fad099e 100644 --- a/src/main/java/Avalara/SDK/api/A1099/V2/CompaniesW9Api.java +++ b/src/main/java/Avalara/SDK/api/A1099/V2/CompaniesW9Api.java @@ -1089,7 +1089,7 @@ public UpdateCompanyRequest getUpdateCompanyRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/A1099/V2/Forms1099Api.java b/src/main/java/Avalara/SDK/api/A1099/V2/Forms1099Api.java index b3a37e5..5e1fea7 100644 --- a/src/main/java/Avalara/SDK/api/A1099/V2/Forms1099Api.java +++ b/src/main/java/Avalara/SDK/api/A1099/V2/Forms1099Api.java @@ -1509,7 +1509,7 @@ public Update1099FormRequest getUpdate1099FormRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/A1099/V2/FormsW9Api.java b/src/main/java/Avalara/SDK/api/A1099/V2/FormsW9Api.java index 6782e6f..5842051 100644 --- a/src/main/java/Avalara/SDK/api/A1099/V2/FormsW9Api.java +++ b/src/main/java/Avalara/SDK/api/A1099/V2/FormsW9Api.java @@ -1841,7 +1841,7 @@ public UploadW9FilesRequest getUploadW9FilesRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/A1099/V2/Issuers1099Api.java b/src/main/java/Avalara/SDK/api/A1099/V2/Issuers1099Api.java index eeb399f..e012721 100644 --- a/src/main/java/Avalara/SDK/api/A1099/V2/Issuers1099Api.java +++ b/src/main/java/Avalara/SDK/api/A1099/V2/Issuers1099Api.java @@ -1069,7 +1069,7 @@ public UpdateIssuerRequest getUpdateIssuerRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/api/A1099/V2/JobsApi.java b/src/main/java/Avalara/SDK/api/A1099/V2/JobsApi.java index 90d6edb..8abd3b8 100644 --- a/src/main/java/Avalara/SDK/api/A1099/V2/JobsApi.java +++ b/src/main/java/Avalara/SDK/api/A1099/V2/JobsApi.java @@ -275,7 +275,7 @@ public GetJobRequest getGetJobRequest() { private void SetConfiguration(ApiClient client) { if (client == null) throw new MissingFormatArgumentException("client"); - this.localVarApiClient.setSdkVersion("25.11.2"); + this.localVarApiClient.setSdkVersion("26.4.0"); } } diff --git a/src/main/java/Avalara/SDK/model/A1099/V2/Form1042S.java b/src/main/java/Avalara/SDK/model/A1099/V2/Form1042S.java index f726cd7..8a6db84 100644 --- a/src/main/java/Avalara/SDK/model/A1099/V2/Form1042S.java +++ b/src/main/java/Avalara/SDK/model/A1099/V2/Form1042S.java @@ -441,7 +441,7 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti private String taxCountryCode; /** - * 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 + * Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3) and FederalTaxWithheld is 0. Required when using TaxRateChap3. Can be left empty if FederalTaxWithheld is greater than 0. Available values: - 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 */ @JsonAdapter(ExemptionCodeChap3Enum.Adapter.class) public enum ExemptionCodeChap3Enum { @@ -1444,7 +1444,7 @@ public Form1042S exemptionCodeChap3(ExemptionCodeChap3Enum exemptionCodeChap3) { } /** - * 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 + * Exemption code (Chapter 3). Required if WithholdingIndicator is 3 (Chapter 3) and FederalTaxWithheld is 0. Required when using TaxRateChap3. Can be left empty if FederalTaxWithheld is greater than 0. Available values: - 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 * @return exemptionCodeChap3 */ @javax.annotation.Nullable diff --git a/src/main/java/Avalara/SDK/model/A1099/V2/JobResponse.java b/src/main/java/Avalara/SDK/model/A1099/V2/JobResponse.java index 81c0699..475bd91 100644 --- a/src/main/java/Avalara/SDK/model/A1099/V2/JobResponse.java +++ b/src/main/java/Avalara/SDK/model/A1099/V2/JobResponse.java @@ -394,7 +394,7 @@ public JobResponse skippedInvalid(Integer skippedInvalid) { } /** - * 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 + * Number of forms skipped because they would have made a form invalid and the form is already e-filed or scheduled for e-filing, or because you do not have permission to update forms that have been scheduled. Value can be 0 or another value based on what the job has available * @return skippedInvalid */ @javax.annotation.Nullable