Transactions
Commenda provides a range of endpoints to manage transactions:-
/calculateendpoint:- Used to estimate sales tax for a potential transaction.
- The response includes the calculated tax amount.
-
/transactionsendpoints:- Used to submit completed transactions to our system.
- Commenda uses this data to file sales tax in states where the seller is registered and track the seller’s progress towards nexus.
-
/nexusendpoint:- Used to view the seller’s progress towards sales tax nexus.
-
/registrationsendpoints:- Used to manage sales tax registrations.
- Commenda uses information about registrations on the
/calculateendpoint to determine if tax should be collected on transactions.
-
/filingsendpoints:- View the contents and status of a seller’s periodic sales tax filings.
Typical Usage
While the/calculate and /transactions endpoints can be used independently, a typical workflow is as follows:
- A customer visits your website, adds something to their cart, and clicks ‘check out’.
- You call our
/calculateAPI to determine the correct amount of sales tax to charge the customer. - The customer pays the total amount, including the sales tax. You save the transaction details, including the subtotal and tax amount.
- After the transaction is completed, you call the
/transactionsAPI to submit the transaction details to our system.
Discounts
Typically, discounts are treated as a reduction in the overall sales price. To account for this, simply call our/calculate and /transactions endpoints using the post-discount price as the amount and subtotal.
For accounting purposes, some customers may prefer to recognize the full sale amount and treat the discount as an expense. If you need this setup, please contact the Commenda team.