Invoice Preview (POST)

Generate preview invoices, which includes the estimated tax amounts, for a billing transaction for the next two billing periods.

Invoice preview provides details of the upcoming invoices for orders or quotes within the system.

Special Access Rules 

You need the Billing Operations User or Billing Customer Service permission set to use this API.

See these requirements to learn more about the configuration prerequisites.

Resource 

1/commerce/invoicing/invoices/collection/actions/preview

Resource Example 

1https://{yourInstance}.salesforce.com/services/data/v68.0/commerce/invoicing/invoices/collection/actions/preview

Available Version 

63.0

HTTP Methods 

POST

Request Body for POST 

JSON Example

1{
2    "billingTransactionId": "801Z600000004LoIAI",
3    "numberOfBillingPeriods": 2,
4    "previewDate": "2024-12-04"
5}

Properties

NameTypeDescriptionRequired or OptionalAvailable Version
billing​TransactionIdStringID of the record to generate the preview invoices for.Required63.0
numberOf​BillingPeriodsIntegerNumber of billing periods that the invoice preview is generated for. If unspecified, the default value is 2.Optional64.0
preview​DateStringThe date on which the preview invoice is generated. For the first invoice, the preview date is the target date for generating the invoice. For the second invoice, the target date is calculated based on the preview date and the minimum billing frequency of the transactions. The default value is the current date.Optional63.0

Response Body for POST 

Invoice Preview