The Chargebee.js library includes functions that allow you to carry out activities or fetch information for your customers during the checkout process. For example, functions can be used to:
- Check the validity of an EU-VAT number before you exempt a customer from taxes.
- Calculate the amount a customer must pay on checkout after discounts and taxes.
- Estimate the amount that the customer has to pay on the next renewal.
Described below, are the functions that are currently available in Chargebee JS. Do contact us at [email protected] if you wish to see other features supported here.
# Available Functions
"Estimates", as the name implies, can be used to find out the estimate for performing an operation as against performing the operation itself. Say, if you want to create a new subscription or update an existing one, you can deduce the details such as the amount the customer needs to be charged for this operation, the state the subscription would be in, etc. using the estimate functions.
Currently we support the following Estimate functions
- These APIs when invoked don't perform actual operations. They just generate an estimate.
- If you have configured Avalara, Chargebee will retrieve tax amount from Avalara to be displayed in the estimate invoice, this may increase your Avalara request count.
# EU-VAT Validation
Chargebee validates VAT Number by sending a validation request to VAT Information Exchange System (VIES), a search engine owned by the European Commision.
Refer here for the implementation details.