Skip to main content
Paygentic issues an invoice at the end of each billing period for every active subscription. The invoice lists the charges for the period, including usage and tax. Paygentic then collects payment from the customer. You don’t create subscription invoices yourself. You track their status, and act when a payment fails. Invoice 0, the first invoice of a subscription, works differently. Paygentic issues it when you create the subscription. See The first invoice.

Invoice statuses

After a billing period ends, Paygentic calculates the final amount before it issues the invoice. During this short time, the API can return CLOSING, CLOSED, CALCULATING, or DRAFT. You don’t need to do anything with these statuses. If Paygentic can’t prepare an invoice, its status is FAILED. Contact support@paygentic.io if you see this status. If an invoice total is zero, Paygentic marks it PAID when it’s issued.

Pay an invoice

How the customer pays depends on the subscription’s autoCharge setting. See How invoices are paid. While an invoice is unpaid, its paymentUrl field links to the invoice payment page. You can use this link in your own app or emails.

Track invoices

To list invoices, use GET /v2/invoices. You can filter by subscriptionId, customerId, or status. To get a single invoice, use GET /v2/invoices/{id}, and to download its PDF, use GET /v2/invoices/{id}/pdf.
Paygentic sends the invoice.issued.v0 webhook when an invoice is issued, and invoice.paid.v0 when it’s paid. It doesn’t send a webhook when an invoice changes to PAYMENT_FAILED, CANCELLED, or WRITTEN_OFF. To find those invoices, filter by status. For event payloads and delivery details, see Webhooks.
API Reference: See the List Invoices and Get Invoice endpoints for all fields and filters.

Next steps