Every successful payment made through Borga produces a legally compliant Icelandic invoice in PayDay.is automatically. You do not need to generate invoices manually, integrate with a separate invoicing system, or handle Icelandic accounting regulations yourself — Borga takes care of it. Invoices are immediately available via the API and downloadable as PDFs.Documentation Index
Fetch the complete documentation index at: https://docs.borga.is/llms.txt
Use this file to discover all available pages before exploring further.
Invoice generation
Borga creates an invoice the moment a payment succeeds. The invoice is associated with the payment and, if provided, the customer record. You can retrieve all invoices withGET /v1/invoices, or fetch a specific invoice with GET /v1/invoices/{id}.
Invoices generated from subscriptions are created at the start of each billing cycle and finalized once payment is collected.
Invoice generation happens asynchronously after payment succeeds. If you query
GET /v1/invoices immediately after a payment, allow a brief moment for the invoice to appear. Use webhooks to receive a notification when an invoice is finalized.Invoice statuses
An invoice moves through the following statuses during its lifecycle:| Status | Meaning |
|---|---|
draft | The invoice is being assembled. Line items can still be added. Not yet sent to the customer. |
open | The invoice has been finalized and sent. Payment is outstanding. |
paid | Payment has been collected. |
void | The invoice has been canceled. A voided invoice is replaced by a new one if rebilling is needed. |
uncollectible | Payment attempts have been exhausted and the invoice is marked as a bad debt. |
Invoice items
For subscription invoices indraft status, you can add ad-hoc line items before the invoice is finalized using POST /v1/invoice_items. This is useful for one-off charges — setup fees, overages, or adjustments — that should appear on the customer’s next invoice.
curl
Invoice item fields
| Field | Required | Description |
|---|---|---|
customer | Yes | The customer the item is billed to. |
amount | Yes | Amount in ISK (integer). |
description | Yes | Line item description that appears on the invoice. |
subscription | No | Attach this item to a specific subscription’s upcoming invoice. |
currency | No | Defaults to ISK. |
quantity | No | Multiplied by amount to produce the line total. Defaults to 1. |
metadata | No | Key-value pairs for your own data. |
Credit notes
When you issue a refund against a paid invoice, Borga automatically generates a credit note. A credit note is the legally required document that offsets the original invoice amount — it does not modify or void the invoice itself. Retrieve credit notes withGET /v1/credit_notes. To filter by invoice, pass the invoice ID as a query parameter:
curl
GET /v1/credit_notes/{id}.
Credit notes are generated automatically when a refund is processed. You do not need to create them manually.
PDF access
Every finalized invoice has a PDF available for download. Invoice PDFs are accessible directly from the Borga dashboard under Invoices. From the API, the invoice object includes apdf_url field you can use to open or serve the PDF directly to your customers.