PREMIUM FEATURE ✨This feature is only available to users with a premium license. Please
contact us to get access to Lago Cloud and Lago
Self-Hosted Premium.
draft status, allowing you to review them and make changes before they are
finalized and sent for payment collection.
In the example below, the timeline includes a billing period of one month and a
grace period of three days.

Define a grace period at organization level
The organization’s grace period applies to all customers by default.- Dashboard
- API
To define a grace period at organization level through the user interface:
- Access the “Settings” section via the side menu;
- Open the “Invoice” tab;
- Click “Edit” in the “Grace period” section;
- Enter the number of days associated with the grace period; and
- Click “Edit grace period” to confirm.

Define a grace period at customer level
- Dashboard
- API
To define a grace period at customer level through the user interface:
- Access the “Customers” section via the side menu;
- Select a customer from the list;
- Open the “Settings” tab of the customer view;
- Click “Add grace period” in the “Grace period” section;
- Enter the number of days associated with the grace period; and
- Click “Add grace period” to confirm.

Application scope and possible actions
The grace period applies to subscription invoices. It does not apply to invoices related to add-ons or credit purchases. The creation of adraft invoice triggers the invoice.drafted
webhook.
When a subscription invoice is in draft status, you can:
- Add usage records by sending events with a
timestampwithin the relevant billing period; - Edit a specific fee by adjusting the total amount or the total units;
- Apply coupons to the customer’s account; and
- Add credits to the customer’s wallet and credit note wallet.
Edit a specific fee
To edit a specific fee, follow these steps in the Dashboard:- Open a draft invoice’s details page;
- Click the ‘three dots’ icon next to the desired fee;
- Change the invoice’s display name if needed; and/or
- Select either
Total amountorTotal unitfor adjustment; - For
Total amount, enter units and unit amount. Note: This will overwrite existing fee details. - For
Total unit, input new units. Lago will then automatically recalculate the fee based on the charge model.
Add usage records
In order to add usage to an invoice that is indraft status, the timestamp
of the events must be
within the billing period. Consider the following example:
The billing period started on January 1st and ended on January 31st. We have defined a 3-day grace period and today is February 2nd. On February 1st, Lago automatically generated aAfter sending events, you can go to the invoice list and refresh the correspondingdraftinvoice for the period January 1st to January 31st. We want to send additional usage records for this invoice. To do so, the timestamp of our events must be included in the period January 1st to January 31st.1673457300(i.e. January 11th, 2023) is a valid timestamp, therefore the event will be included in thedraftinvoice. However,1675354500(i.e. February 2nd, 2023) is outside the billing period under consideration, therefore the event will not be included in thedraftinvoice, it will be included in the next invoice.
draft invoice to ensure your new events have been taken into
account.
When all changes have been made, you can either wait for the grace period to
expire (the invoice status will automatically switch to finalized) or you can
finalize the invoice manually through the user interface or the API.
When an invoice is finalized, it can no longer be edited. Finalizing an
invoice triggers the invoice.created webhook.

Coupons and credits that are applied/added during the grace period will not
appear on
draft invoices but will be automatically deducted from the
customer’s next finalized invoice.