LedgerBee Developer
  • Getting started
  • Conventions
  • Products
  • Configuration
  • API Reference
Subscriptions
Payment flowCard paymentsProducts & PricingProduct Entitlements
Billing documents
    OverviewInvoicesCredit notesQuotesOrder confirmationsDocument templates
Accounting
WebhooksPartner-Hosted Checkout
Customer Portal
Billing documents

Document Templates

Read the PDF design templates a document renders with over the LedgerBee public API (base URL https://api.ledgerbee.com/api/v1). A template's id can be passed as documentTemplateId when sending an invoice or credit note to pick a specific design. Authenticate with the x-api-key header.

Templates are configured in the LedgerBee app; the public API exposes them read-only so a partner can discover an id to reference. There is one scope:

  • document-templates-read — list templates.

The public API exposes templates for the four partner document types only: invoice-template, credit-note-template, quote-template, and order-confirmation-template. Choosing a template is optional; a document with no documentTemplateId renders with the customer's or company's default design.

Operations

OperationEndpointScope
ListGET /v1/document-templatesdocument-templates-read

The list is paginated (page, limit), filterable by documentType and search, and sortable by name, documentType, or createdAt. A type's default template is the one flagged isDefault: true, not the first item in the list; list position follows the requested sort, so rely on the isDefault flag. See the list operation.

TerminalCode
curl 'https://api.ledgerbee.com/api/v1/document-templates?documentType=invoice-template' \ -H 'x-api-key: <your-key>'

Pass a returned id as documentTemplateId when you send an invoice or a credit note, to render that one document with that template:

TerminalCode
curl -X POST 'https://api.ledgerbee.com/api/v1/invoices/0197a943-2325-7829-b835-b6c71a293066/send' \ -H 'x-api-key: <your-key>' \ -H 'Content-Type: application/json' \ -d '{ "deliveryType": "Email", "documentTemplateId": "0197a943-2325-7829-b835-b6c71a293040" }'

The field is accepted on the invoice and credit-note send bodies. Everywhere else — create calls, and quote / order-confirmation sends — the document renders with the customer's or company's default design. The public API validates with forbidNonWhitelisted, so passing the field where it isn't accepted returns a 400 rather than being ignored.

Errors

ConditionError codeFix
documentType filter outside the four partner typesA 400 validation errorFilter by invoice-template, credit-note-template, quote-template, or order-confirmation-template.
Last modified on September 13, 2026
Order confirmationsJournal entries
On this page
  • Operations
  • Errors