Skip to content

feat(multi entities): Apply Billing Entity invoice grace period changes #3548

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

ancorcruz
Copy link
Contributor

@ancorcruz ancorcruz commented Apr 28, 2025

Roadmap Task

👉 https://getlago.canny.io/feature-requests/p/support-billing-from-multiple-entities

Context

Users who invoice the same products across multiple entities face the challenge of managing separate Lago organizations.

This requires duplicating all billable metrics, plans, and setup, while also implementing additional logic to handle two different API keys and ensure the correct one is used for each affiliated entity. This process adds complexity and overhead to their billing operations.

Description

Migrate invoice grace period handling from organization update to billing entities update.

When organization's invoice grace period changes it updates the organization data but does not handle invoices update. However, default billing entity is updated and its draft invoices dates are also updated accordingly.

Also, when updating a billing entity invoice grace period its invoices are updated.

Soon the organization invoice_grace_period attribute will be dropped and no need to update it anymore, just delegate to the default billing entity attribute.

 ## Roadmap Task

👉 https://getlago.canny.io/feature-requests/p/support-billing-from-multiple-entities

 ## Context

Users who invoice the same products across multiple entities face the
challenge of managing separate Lago organizations.

This requires duplicating all billable metrics, plans, and setup, while
also implementing additional logic to handle two different API keys and
ensure the correct one is used for each affiliated entity. This process
adds complexity and overhead to their billing operations.

 ## Description

Migrate invoice grace period handling from organzation update to billing
entity update.

When organization's invoice grace period changes it updates the
organzation data but does not handle invoices... this is done when
default billing entity is updated. Soon the organization field will be
dropped and no need to update it, just delegate to the default billing
entity update.
@ancorcruz ancorcruz requested a review from annvelents April 28, 2025 11:00
@ancorcruz ancorcruz self-assigned this Apr 28, 2025
@ancorcruz ancorcruz merged commit 0de1bf9 into main May 14, 2025
14 checks passed
@ancorcruz ancorcruz deleted the feat/multientities/finalize_invoice_on_grace_period_changes branch May 14, 2025 11:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants