POST /estimates/create_invoice
Generates an estimate for the 'create an invoice' operation. This is similar to the Create an invoice API, but the invoice will not be generated. Only an estimate for this operation is created.
Servers
- {protocol}://{site}.{environment}:{port}/api/v1
- {protocol}://{site}-test.{environment}:{port}/api/v1
Request headers
Name | Type | Required | Description |
---|---|---|---|
chargebee-request-origin-device |
String | No |
The device from which the customer has made the request |
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/x-www-form-urlencoded" |
chargebee-event-webhook |
String | No |
skip only webhooks Possible values:
|
chargebee-event-actions |
String | No |
skip all actions to be done on the events Possible values:
|
chargebee-request-origin-user |
String | No |
The email address of your customer/user. Use this when the email address has only ASCII characters. |
chargebee-request-origin-ip |
String | No |
The IP address of the customer where the request originated |
chargebee-request-origin-user-encoded |
String | No |
The Base64-encoded email address of your customer/user. Use this if the email address has UTF-8 characters. When this header is provided, the header |
chargebee-event-email |
String | No |
skip only emails Possible values:
|
Request body fields
Name | Type | Required | Description |
---|---|---|---|
shipping_address |
Object | No |
Parameters for shipping_address |
shipping_address.first_name |
String | No |
The first name of the contact. |
shipping_address.state |
String | No |
The state/province name. Is set by Chargebee automatically for US, Canada and India If |
shipping_address.city |
String | No |
The name of the city. |
shipping_address.line2 |
String | No |
Address line 2 |
shipping_address.line1 |
String | No |
Address line 1 |
shipping_address.email |
String | No |
The email address. |
shipping_address.last_name |
String | No |
The last name of the contact. |
shipping_address.company |
String | No |
The company name. |
shipping_address.line3 |
String | No |
Address line 3 |
shipping_address.state_code |
String | No |
The ISO 3166-2 state/province code without the country prefix. Currently supported for USA, Canada and India. For instance, for Arizona (USA), set |
shipping_address.zip |
String | No |
Zip or postal code. The number of characters is validated according to the rules specified here. |
shipping_address.phone |
String | No |
The phone number. |
shipping_address.country |
String | No |
The billing address country of the customer. Must be one of ISO 3166 alpha-2 country code. Note : If you enter an invalid country code, the system will return an error. Brexit If you have enabled EU VAT in 2021 or later, or have manually enable the Brexit configuration, then |
customer |
Object | No |
Parameters for customer |
customer.taxability |
String | No |
Specifies if the customer is liable for tax * exempt -
* taxable - Computes tax for the customer based on the site configuration. In some cases, depending on the region, shipping_address is needed. If not provided, then billing_address is used to compute tax. If that's not available either, the tax is taken as zero. Possible values:
Default value: "taxable" |
customer.vat_number |
String | No |
VAT number of this customer. If not provided then taxes are not calculated for the estimate. Applicable only when taxes are configured for the EU or UK region. VAT validation is not done for this. |
invoice |
Object | No |
Parameters for invoice |
invoice.customer_id |
String | No |
Identifier of the customer for which this invoice needs to be created. Should be specified if 'subscription_id' is not specified. |
invoice.po_number |
String | No |
Purchase Order Number for this invoice. |
invoice.subscription_id |
String | No |
Identifier of the subscription for which this invoice needs to be created. Should be specified if 'customer_id' is not specified.(not applicable for consolidated invoice) |
coupon |
String | No |
The 'One Time' coupon to be applied. |
charges |
Object | No |
Parameters for charges |
charges.description[] |
Array | No |
Description for this charge |
charges.amount[] |
Array | No |
The amount to be charged. The unit depends on the type of currency. |
addons |
Object | No |
Parameters for addons |
addons.id[] |
Array | No |
Identifier of the addon. Multiple addons can be passed. |
addons.quantity[] |
Array | No |
Quantity of the addon. Applicable for addons with |
billing_address |
Object | No |
Parameters for billing_address |
billing_address.state_code |
String | No |
The ISO 3166-2 state/province code without the country prefix. Currently supported for USA, Canada and India. For instance, for Arizona (USA), set |
billing_address.zip |
String | No |
Zip or postal code. The number of characters is validated according to the rules specified here. |
billing_address.country |
String | No |
The billing address country of the customer. Must be one of ISO 3166 alpha-2 country code. Note : If you enter an invalid country code, the system will return an error. Brexit If you have enabled EU VAT in 2021 or later, or have manually enable the Brexit configuration, then |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.