Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
TaxEngines Interface
Namespace
blng
TaxEngines Methods
The TaxEngines interface includes these methods.
calculateTax(taxParametersInstance)
Signature
global static Map<Id,TaxResults> calculateTax(TaxParameters taxParametersInstance)
Parameters
- taxParametersInstance
- Type: TaxParameters
-
The taxParametersInstance parameter is populated based on the process that uses tax calculation. These examples show the sample values for each process.
- Order is created
-
1TaxParameters:[ 2 isCommitOnGetTax=false, 3 isStandardFromBatch=false, 4 legalEntityReference=80105000000i1MqAAI, 5 listOfSObjectIds=(), 6 listOfSObjects=(), 7 mapOfSObjectByUniqueId={}, 8 mapOfTaxResultsById={}, 9 mapOfTaxTreatmentById={}, 10 sObjectId=null, 11 sObjectTypeInstance=OrderItem, 12 sobjectInstance=null, 13 taxMethod=null 14] - Bill Now or Invoice is created
-
1TaxParameters:[ 2 isCommitOnGetTax=false, 3 isStandardFromBatch=false, 4 legalEntityReference=a2305000000BKIoAAO, 5 listOfSObjectIds=(), 6 listOfSObjects=(), 7 mapOfSObjectByUniqueId={}, 8 mapOfTaxResultsById={}, 9 mapOfTaxTreatmentById={}, 10 sObjectId=null, 11 sObjectTypeInstance=blng__InvoiceLine__c, 12 sobjectInstance=null, 13 taxMethod=null 14] - Invoice is manually posted
-
1TaxParameters:[ 2isCommitOnGetTax=false, 3 isStandardFromBatch=false, 4 legalEntityReference=null, 5 listOfSObjectIds=(a2305000000BKIoAAO), 6 listOfSObjects=(), 7 mapOfSObjectByUniqueId={}, 8 mapOfTaxResultsById={}, 9 mapOfTaxTreatmentById={}, 10 sObjectId=null, 11 sObjectTypeInstance=blng__Invoice__c, 12 sobjectInstance=null, 13 taxMethod=postTax 14]
Return Value
Type: Map<Id,TaxResults>