TaxTransactionRequest Class
Abstract class for storing customer details used in tax calculation and estimation requests.
Specify the CommerceTax namespace when creating an instance of this class. The constructor of this class takes no arguments. For example, let’s say you create an instance of CalculateTaxRequest class, which extends the TaxTransactionRequest class.
-
TaxTransactionRequest Constructors
Learn more about the available constructors with the
TaxTransactionRequestclass. -
TaxTransactionRequest Properties
Learn more about the available properties with the
TaxTransactionRequestclass.
Learn more about the available constructors with the TaxTransactionRequest class.
The TaxTransactionRequest class includes these constructors.
-
Initializes the request for the tax transaction. This constructor is intended for test usage and throws an exception if used outside of the Apex test context.
Initializes the request for the tax transaction. This constructor is intended for test usage and throws an exception if used outside of the Apex test context.
global TaxTransactionRequest(commercetax.HeaderTaxAddressesRequest addresses, String currencyIsoCode, commercetax.TaxCustomerDetailsRequest customerDetails, String description, String documentCode, String referenceDocumentCode, Datetime transactionDate, Datetime effectiveDate, List<commercetax.TaxLineItemRequest> lineItems, String referenceEntityId, commercetax.TaxSellerDetailsRequest sellerDetails,Map<String,Object> customTaxAttributes)
-
addresses:
Type: HeaderTaxAddressesRequest
Tax addresses, such as Ship To and Bill From.
-
currencyIsoCode:
Type: String
Three-letter ISO 4217 currency code associated with the
TaxTransactionRequest. -
customerDetails:
Type: TaxCustomerDetailsRequest
Customer information used in tax calculation.
-
description:
Type: String
Optional user-defined description for providing more information about the tax transaction request.
-
documentCode:
Type: String
Code
for documents that are used to provide more information in the tax calculation process.
-
referenceDocumentCode:
Type: String
Identifier that combines
the original invoice ID, previous tax transaction type, and tax engine ID, used in tax calculations for negative invoice lines. For example, a referenceDocumentCode parameter value
3ttxx00000004Bh_Debit-4wAxx0000000001EAAindicates3ttxx00000004Bhis the original invoice ID and4wAxx0000000001EAAis the tax engine ID. -
transactionDate:
Type: Datetime
The date that the tax transaction occurred.
-
effectiveDate:
Type: Datetime
The date that the tax transaction takes effect. User-defined and used only for reporting purposes.
-
lineItems:
Type: List<TaxLineItemRequest>
A list of line items on which tax is calculated.
-
referenceEntityId:
Type: String
ID of an object related to the line items sent for tax calculation.
-
sellerDetails:
Type: TaxSellerDetailsRequest
Contains tax code information used in a tax calculation request.
-
customTaxAttributes:
Type: Map<String, Object> Customised tax contract to include additional attributes at the header level.
Learn more about the available properties with the TaxTransactionRequest class.
The TaxTransactionRequest class includes these properties.
-
A list of addresses (such as Ship To and Sold To) used as part of the tax transaction.
-
Three-letter ISO 4217 currency code associated with the
TaxTransactionRequest. -
Customer information used in tax calculation.
-
Customised tax contract to include additional attributes at the header level.
-
Optional user-defined description for providing more information about the tax transaction request.
-
Code for documents used to provide more information in the tax calculation process.
-
The date that the tax transaction takes effect. User-defined and used only for reporting purposes.
-
A list of line items on which tax will be calculated.
-
Identifier that combines the original invoice ID, previous tax transaction type, and tax engine ID, used in tax calculations for negative invoice lines.
-
ID of an object related to the line items sent for tax calculation.
-
Contains tax code information used in a tax calculation request.
-
The date that the tax transaction occurred.
A list of addresses (such as Ship To and Sold To) used as part of the tax transaction.
global commercetax.HeaderTaxAddressesRequest addresses {get; set;}
Type: HeaderTaxAddressesRequest
Three-letter ISO 4217 currency code associated with the TaxTransactionRequest.
global String currencyIsoCode {get; set;}
Type: String
Customer information used in tax calculation.
global CommerceTax.TaxCustomerDetailsRequest customerDetails {get; set;}
Type: TaxCustomerDetailsRequest
Customised tax contract to include additional attributes at the header level.
global commercetax.TaxTransactionRequest customTaxAttributes {get; set;}
Type: Map<String, Object>
Optional user-defined description for providing more information about the tax transaction request.
global String description {get; set;}
Type: String
Code for documents used to provide more information in the tax calculation process.
global String documentCode {get; set;}
Type: String
The date that the tax transaction takes effect. User-defined and used only for reporting purposes.
global Datetime effectiveDate {get; set;}
Type: Datetime
A list of line items on which tax will be calculated.
global List<CommerceTax.TaxLineItemRequest> lineItems {get; set;}
Type: List<TaxLineItemRequest>
Identifier that combines the original invoice ID, previous tax transaction type, and tax engine ID, used in tax calculations for negative invoice lines.
For example, a referenceDocumentCode parameter value 3ttxx00000004Bh_Debit-4wAxx0000000001EAA indicates 3ttxx00000004Bh is the original invoice ID and 4wAxx0000000001EAA is the tax engine ID.
global String referenceDocumentCode {get; set;}
Type: String
ID of an object related to the line items sent for tax calculation.
global String referenceEntityId {get; set;}
Type: String
Contains tax code information used in a tax calculation request.
global commercetax.TaxSellerDetailsRequest sellerDetails {get; set;}
Type: TaxSellerDetailsRequest
The date that the tax transaction occurred.
global Datetime transactionDate {get; set;}
Type: Datetime
The following are methods for TaxTransactionRequest.
-
Maintains the integrity of lists of type
TaxTransactionRequestby determining the equality of external objects in a list. This method is dynamic and based on theequals()method in Java. -
Maintains the integrity of lists of type
TaxTransactionRequestby determining the uniqueness of the external object records in a list. -
Converts a value to a string.
Maintains the integrity of lists of type TaxTransactionRequest by determining the equality of external objects in a list. This method is dynamic and based on the equals() method in Java.
global Boolean equals(Object obj)
-
obj:
Type: Object
Type: Boolean
Maintains the integrity of lists of type TaxTransactionRequest by determining the uniqueness of the external object records in a list.
global Integer hashCode()
Type: Integer
Converts a value to a string.
global String toString()
Type: String