Download OpenAPI specification:
Logistics operations API for the 4klyft platform.
This API provides comprehensive endpoints for managing:
All API endpoints (except /api/docs and /api/v1/iam/auth/*) require JWT Bearer token authentication.
Include the token in the Authorization header:
Authorization: Bearer <your-jwt-token>
API requests are rate-limited to ensure fair usage. Standard limits are:
Retrieve a paginated list of credit notes with optional filters.
| status | string Enum: "draft" "issued" "applied" "cancelled" Example: status=issued Filter by credit note status |
| partnerId | string Filter by partner ULID |
| invoiceId | string Filter by invoice ULID |
| page | integer >= 1 Default: 1 Page number |
| itemsPerPage | integer [ 1 .. 100 ] Default: 30 Items per page |
{- "totalItems": 0,
- "search": {
- "@type": "string",
- "template": "string",
- "variableRepresentation": "string",
- "mapping": [
- {
- "@type": "string",
- "variable": "string",
- "property": "string",
- "required": true
}
]
}, - "view": {
- "@id": "string",
- "@type": "string",
- "first": "string",
- "last": "string",
- "previous": "string",
- "next": "string"
}, - "member": [
- {
- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "invoiceId": "string",
- "invoiceNumber": "string",
- "partnerId": "string",
- "partnerName": "string",
- "currencyCode": "string",
- "status": "string",
- "reason": "string",
- "creditNoteNumber": "string",
- "totalAmountCents": 0,
- "totalAmountFormatted": "0.00",
- "subtotalCents": 0,
- "totalTaxCents": 0,
- "grandTotalCents": 0,
- "lineItemCount": 0,
- "lineItems": [
- {
- "id": "string",
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "unitPriceFormatted": "string",
- "amountCents": 0,
- "amountFormatted": "string",
- "originalLineItemId": "string",
- "taxCategoryId": "string",
- "taxAmountCents": 0,
- "taxRatePercent": 0
}
], - "issuedAt": "string",
- "appliedAt": "string",
- "createdAt": "string",
- "updatedAt": "string"
}
]
}Create a new credit note for an invoice.
Credit note data
| invoiceId required | string Invoice ULID to credit |
| reason required | string Reason for the credit note |
Array of objects Line items to credit | |
| issueImmediately | boolean Default: false |
{- "invoiceId": "string",
- "reason": "string",
- "lineItems": [
- {
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "originalLineItemId": "string"
}
], - "issueImmediately": false
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "invoiceId": "string",
- "invoiceNumber": "string",
- "partnerId": "string",
- "partnerName": "string",
- "currencyCode": "string",
- "status": "string",
- "reason": "string",
- "creditNoteNumber": "string",
- "totalAmountCents": 0,
- "totalAmountFormatted": "0.00",
- "subtotalCents": 0,
- "totalTaxCents": 0,
- "grandTotalCents": 0,
- "lineItemCount": 0,
- "lineItems": [
- {
- "id": "string",
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "unitPriceFormatted": "string",
- "amountCents": 0,
- "amountFormatted": "string",
- "originalLineItemId": "string",
- "taxCategoryId": "string",
- "taxAmountCents": 0,
- "taxRatePercent": 0
}
], - "issuedAt": "string",
- "appliedAt": "string",
- "createdAt": "string",
- "updatedAt": "string"
}Retrieve a single credit note by its ULID.
| id required | string CreditNote identifier |
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "invoiceId": "string",
- "invoiceNumber": "string",
- "partnerId": "string",
- "partnerName": "string",
- "currencyCode": "string",
- "status": "string",
- "reason": "string",
- "creditNoteNumber": "string",
- "totalAmountCents": 0,
- "totalAmountFormatted": "0.00",
- "subtotalCents": 0,
- "totalTaxCents": 0,
- "grandTotalCents": 0,
- "lineItemCount": 0,
- "lineItems": [
- {
- "id": "string",
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "unitPriceFormatted": "string",
- "amountCents": 0,
- "amountFormatted": "string",
- "originalLineItemId": "string",
- "taxCategoryId": "string",
- "taxAmountCents": 0,
- "taxRatePercent": 0
}
], - "issuedAt": "string",
- "appliedAt": "string",
- "createdAt": "string",
- "updatedAt": "string"
}Apply an issued credit note to the invoice.
| id required | string CreditNote identifier |
The new CreditNote resource
Represents a credit note in the billing system.
{ }{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "invoiceId": "string",
- "invoiceNumber": "string",
- "partnerId": "string",
- "partnerName": "string",
- "currencyCode": "string",
- "status": "string",
- "reason": "string",
- "creditNoteNumber": "string",
- "totalAmountCents": 0,
- "totalAmountFormatted": "0.00",
- "subtotalCents": 0,
- "totalTaxCents": 0,
- "grandTotalCents": 0,
- "lineItemCount": 0,
- "lineItems": [
- {
- "id": "string",
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "unitPriceFormatted": "string",
- "amountCents": 0,
- "amountFormatted": "string",
- "originalLineItemId": "string",
- "taxCategoryId": "string",
- "taxAmountCents": 0,
- "taxRatePercent": 0
}
], - "issuedAt": "string",
- "appliedAt": "string",
- "createdAt": "string",
- "updatedAt": "string"
}Issue a draft credit note.
| id required | string CreditNote identifier |
The new CreditNote resource
| creditNoteNumber | string or null <= 50 characters |
{- "creditNoteNumber": "string"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "invoiceId": "string",
- "invoiceNumber": "string",
- "partnerId": "string",
- "partnerName": "string",
- "currencyCode": "string",
- "status": "string",
- "reason": "string",
- "creditNoteNumber": "string",
- "totalAmountCents": 0,
- "totalAmountFormatted": "0.00",
- "subtotalCents": 0,
- "totalTaxCents": 0,
- "grandTotalCents": 0,
- "lineItemCount": 0,
- "lineItems": [
- {
- "id": "string",
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "unitPriceFormatted": "string",
- "amountCents": 0,
- "amountFormatted": "string",
- "originalLineItemId": "string",
- "taxCategoryId": "string",
- "taxAmountCents": 0,
- "taxRatePercent": 0
}
], - "issuedAt": "string",
- "appliedAt": "string",
- "createdAt": "string",
- "updatedAt": "string"
}Represents an invoice in the billing system.
Invoices track billing for partners with support for line items, issuing, payment tracking, and cancellation.
Generate a new draft invoice. Optionally include line items and issue immediately.
Invoice generation data
| partnerId required | string Partner ULID |
| currencyCode | string or null ISO 4217 currency code. Optional — resolved from channel, tenant default, or country when omitted. |
| channelId | string or null Originating sales channel ULID (consulted for per-channel default currency). |
| dueDate required | string <date> Due date for payment |
| notes | string or null Additional notes |
| issueImmediately | boolean Default: false Whether to issue the invoice immediately |
Array of objects or null Line items to include |
{- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "currencyCode": "EUR",
- "channelId": "01HQWXYZ1234567890ABCDEF",
- "dueDate": "2024-07-15",
- "notes": "string",
- "issueImmediately": false,
- "lineItems": [
- {
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "reference": "string"
}
]
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Retrieve a single invoice by its invoice number.
| invoiceNumber required | string Example: INV-2024-001 Invoice number |
| id required | string Invoice identifier |
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Cancel an invoice. Only draft, issued, or overdue invoices can be cancelled.
| id required | string Example: 01HQWXYZ1234567890ABCDEF Invoice ULID |
Cancellation data
| reason required | string Reason for cancellation |
{- "reason": "Duplicate invoice"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Render the invoice as a PDF via the Document module. Returns the generated Document resource; download it via GET /api/document/documents/{id}/download.
| id required | string Example: 01HQWXYZ1234567890ABCDEF Invoice ULID |
Document generation options
| includeDetails | boolean Default: true Whether to include line-item details in the document. |
{- "includeDetails": true
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "type": "string",
- "subject": "string",
- "status": "string",
- "generatedBy": "string",
- "createdAt": "string",
- "number": "string",
- "primaryFormat": "string",
- "source": "string",
- "sourceRef": "string",
- "templateId": "string",
- "templateVersion": 0,
- "expiresAt": "string",
- "finalizedAt": "string",
- "voidedAt": "string",
- "voidReason": "string",
- "supersedes": "string",
- "supersededBy": "string",
- "storagePath": "string",
- "fileSize": 0,
- "failureReason": "string",
- "updatedAt": "string",
- "metadata": {
- "property1": "string",
- "property2": "string"
}, - "renditions": [
- {
- "id": "string",
- "format": "string",
- "status": "string",
- "locale": "string",
- "storagePath": "string",
- "sizeBytes": 0,
- "generatedAt": "string",
- "failureReason": "string",
- "url": "string"
}
], - "attachments": [
- {
- "id": "string",
- "originalFilename": "string",
- "storagePath": "string",
- "mimeType": "string",
- "sizeBytes": 0,
- "purpose": "string",
- "uploadedAt": "string",
- "slot": "string",
- "uploadedBy": "string",
- "url": "string",
- "downloadUrl": "string"
}
], - "references": [
- {
- "id": "string",
- "targetDocumentId": "string",
- "type": "string",
- "addedAt": "string",
- "description": "string"
}
]
}Issue a draft invoice. Assigns an invoice number and makes it payable.
| id required | string Example: 01HQWXYZ1234567890ABCDEF Invoice ULID |
Issue invoice data
| invoiceNumber | string or null Custom invoice number. If not provided, one will be auto-generated. |
{- "invoiceNumber": "string"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Mark an issued or overdue invoice as paid.
| id required | string Example: 01HQWXYZ1234567890ABCDEF Invoice ULID |
Payment data
| paymentReference | string or null Payment reference or transaction ID |
| paidAt | string or null <date-time> Payment date/time. Defaults to now if not provided. |
{- "paymentReference": "TXN-12345",
- "paidAt": "2019-08-24T14:15:22Z"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Deliver the issued invoice to the chosen recipients (To/CC/BCC) over the selected channel and format, optionally attaching documents. All fields are optional: an empty To list falls back to the partner billing contact, channel defaults to email, format to pdf, and attachments to the invoice's own document. The invoice must already be issued. Returns the invoice resource.
| id required | string Example: 01HQWXYZ1234567890ABCDEF Invoice ULID |
The new Invoice resource
| to | Array of strings Primary (To) recipients. Empty = fall back to the partner billing contact. |
| cc | Array of strings |
| bcc | Array of strings |
| channel | string Default: "email" Enum: "email" "portal" |
| format | string Default: "pdf" Enum: "pdf" "html" |
| attachmentDocumentIds | Array of strings Document IDs to attach. Empty = attach the invoice's own generated document. |
{- "to": [
- "string"
], - "cc": [
- "string"
], - "bcc": [
- "string"
], - "channel": "email",
- "format": "pdf",
- "attachmentDocumentIds": [
- "string"
]
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "status": "draft",
- "invoiceNumber": "INV-2024-001",
- "dueDate": "2024-07-15",
- "totalAmountCents": 15000,
- "totalAmountFormatted": "150.00 EUR",
- "subtotalCents": 10000,
- "totalTaxCents": 2000,
- "grandTotalCents": 12000,
- "notes": "Payment terms: Net 30",
- "lineItemCount": 5,
- "lineItems": [
- {
- "id": "01HQWXYZ1234567890ABCDEF",
- "description": "Delivery service - Amsterdam to Rotterdam",
- "quantity": 1,
- "unitPriceCents": 5000,
- "amountCents": 5000,
- "reference": "SHP-2024-001",
- "taxCategoryId": "01HQWXYZ1234567890ABCDEF",
- "taxAmountCents": 2000,
- "taxRatePercent": 20
}
], - "issuedAt": "2024-06-15T09:00:00+00:00",
- "paidAt": "2024-07-10T14:30:00+00:00",
- "paymentReference": "TXN-12345",
- "documentSubject": "billing/invoice/01HQWXYZ1234567890ABCDEF",
- "createdAt": "2024-06-14T10:30:00+00:00",
- "updatedAt": "2024-06-14T14:45:00+00:00"
}Represents a recurring invoice profile — a billing cadence that automatically generates invoices for a partner.
Retrieve a paginated list of recurring invoice profiles with optional filters.
| status | string Enum: "active" "paused" "ended" Example: status=active Filter by profile status |
| partnerId | string Example: partnerId=01HQWXYZ1234567890ABCDEF Filter by partner ULID |
| page | integer >= 1 Default: 1 Example: page=1 Page number for pagination |
| itemsPerPage | integer [ 1 .. 100 ] Default: 20 Example: itemsPerPage=20 Number of items per page |
{- "totalItems": 0,
- "search": {
- "@type": "string",
- "template": "string",
- "variableRepresentation": "string",
- "mapping": [
- {
- "@type": "string",
- "variable": "string",
- "property": "string",
- "required": true
}
]
}, - "view": {
- "@id": "string",
- "@type": "string",
- "first": "string",
- "last": "string",
- "previous": "string",
- "next": "string"
}, - "member": [
- {
- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}
]
}Create a recurring invoice profile that auto-generates invoices on the given billing cadence.
Recurring invoice profile data
| partnerId required | string Partner ULID |
| currencyCode required | string ISO 4217 currency code (required) |
| cadence required | string Enum: "weekly" "monthly" "quarterly" "yearly" Billing cadence |
| anchorDay required | integer Anchor day: ISO weekday (1..7) for weekly, day-of-month (1..31, clamped) otherwise |
| startAt required | string <date> First billing period start (UTC date) |
| endAt | string or null <date> Optional end of the active window (exclusive) |
| dueDays | integer Payment terms in days after each period start |
| autoIssue | boolean Default: true Whether generated invoices are issued immediately |
| notes | string or null Notes copied onto every generated invoice |
required | Array of objects Line template copied verbatim onto every generated invoice |
{- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "currencyCode": "EUR",
- "cadence": "monthly",
- "anchorDay": 1,
- "startAt": "2026-01-01",
- "endAt": "2019-08-24",
- "dueDays": 14,
- "autoIssue": true,
- "notes": "string",
- "lines": [
- {
- "description": "string",
- "quantity": 0,
- "unitPriceCents": 0,
- "reference": "string"
}
]
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}Retrieve a single recurring invoice profile by its ULID.
| id required | string RecurringInvoiceProfile identifier |
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}End a profile permanently. Terminal — it never generates invoices again.
| id required | string RecurringInvoiceProfile identifier |
The new RecurringInvoiceProfile resource
| id | string Unique identifier (ULID) |
| partnerId | string Partner ULID |
| partnerName | string or null Partner name |
| currencyCode | string ISO 4217 currency code |
| cadence | string Enum: "weekly" "monthly" "quarterly" "yearly" |
| anchorDay | integer Default: 1 Anchor day (weekday 1..7 for weekly, day-of-month 1..31 otherwise) |
| status | string Enum: "active" "paused" "ended" |
| dueDays | integer Default: 0 Payment terms in days after each period start |
| startAt | string First billing period start (ISO 8601) |
| endAt | string or null End of the active window (ISO 8601), if any |
| nextInvoiceAt | string Next billing date (ISO 8601) |
| lastInvoicedAt | string or null Last invoiced period start (ISO 8601), if any |
| createdAt | string Timestamp when the profile was created (ISO 8601) |
| updatedAt | string Timestamp when the profile was last updated (ISO 8601) |
{- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}Pause an active profile. It stops generating invoices until resumed.
| id required | string RecurringInvoiceProfile identifier |
The new RecurringInvoiceProfile resource
| id | string Unique identifier (ULID) |
| partnerId | string Partner ULID |
| partnerName | string or null Partner name |
| currencyCode | string ISO 4217 currency code |
| cadence | string Enum: "weekly" "monthly" "quarterly" "yearly" |
| anchorDay | integer Default: 1 Anchor day (weekday 1..7 for weekly, day-of-month 1..31 otherwise) |
| status | string Enum: "active" "paused" "ended" |
| dueDays | integer Default: 0 Payment terms in days after each period start |
| startAt | string First billing period start (ISO 8601) |
| endAt | string or null End of the active window (ISO 8601), if any |
| nextInvoiceAt | string Next billing date (ISO 8601) |
| lastInvoicedAt | string or null Last invoiced period start (ISO 8601), if any |
| createdAt | string Timestamp when the profile was created (ISO 8601) |
| updatedAt | string Timestamp when the profile was last updated (ISO 8601) |
{- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}Resume a paused profile. The next billing date is advanced past any periods that elapsed while paused.
| id required | string RecurringInvoiceProfile identifier |
The new RecurringInvoiceProfile resource
| id | string Unique identifier (ULID) |
| partnerId | string Partner ULID |
| partnerName | string or null Partner name |
| currencyCode | string ISO 4217 currency code |
| cadence | string Enum: "weekly" "monthly" "quarterly" "yearly" |
| anchorDay | integer Default: 1 Anchor day (weekday 1..7 for weekly, day-of-month 1..31 otherwise) |
| status | string Enum: "active" "paused" "ended" |
| dueDays | integer Default: 0 Payment terms in days after each period start |
| startAt | string First billing period start (ISO 8601) |
| endAt | string or null End of the active window (ISO 8601), if any |
| nextInvoiceAt | string Next billing date (ISO 8601) |
| lastInvoicedAt | string or null Last invoiced period start (ISO 8601), if any |
| createdAt | string Timestamp when the profile was created (ISO 8601) |
| updatedAt | string Timestamp when the profile was last updated (ISO 8601) |
{- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "01HQWXYZ1234567890ABCDEF",
- "partnerId": "01HQWXYZ1234567890ABCDEF",
- "partnerName": "Acme Corporation",
- "currencyCode": "EUR",
- "cadence": "weekly",
- "anchorDay": 1,
- "status": "active",
- "dueDays": 14,
- "startAt": "2026-01-01T00:00:00+00:00",
- "endAt": "2026-12-31T00:00:00+00:00",
- "nextInvoiceAt": "2026-02-01T00:00:00+00:00",
- "lastInvoicedAt": "2026-01-01T00:00:00+00:00",
- "createdAt": "2026-01-01T10:30:00+00:00",
- "updatedAt": "2026-01-01T14:45:00+00:00"
}Retrieves the collection of BillingInvoice resources.
| page | integer Default: 1 The collection page number |
{- "totalItems": 0,
- "search": {
- "@type": "string",
- "template": "string",
- "variableRepresentation": "string",
- "mapping": [
- {
- "@type": "string",
- "variable": "string",
- "property": "string",
- "required": true
}
]
}, - "view": {
- "@id": "string",
- "@type": "string",
- "first": "string",
- "last": "string",
- "previous": "string",
- "next": "string"
}, - "member": [
- {
- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "number": "string",
- "tenantId": "string",
- "subscriptionId": "string",
- "periodStartedAt": "string",
- "periodEndsAt": "string",
- "lineItems": [
- {
- "property1": 0,
- "property2": 0
}
], - "subtotalCents": 0,
- "taxCents": 0,
- "totalCents": 0,
- "currency": "string",
- "status": "string",
- "issuedAt": "string",
- "dueAt": "string",
- "paidAt": "string",
- "paymentMethod": "string",
- "externalReference": "string",
- "createdAt": "string"
}
]
}Retrieves a BillingInvoice resource.
| id required | string BillingInvoice identifier |
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "number": "string",
- "tenantId": "string",
- "subscriptionId": "string",
- "periodStartedAt": "string",
- "periodEndsAt": "string",
- "lineItems": [
- {
- "property1": 0,
- "property2": 0
}
], - "subtotalCents": 0,
- "taxCents": 0,
- "totalCents": 0,
- "currency": "string",
- "status": "string",
- "issuedAt": "string",
- "dueAt": "string",
- "paidAt": "string",
- "paymentMethod": "string",
- "externalReference": "string",
- "createdAt": "string"
}Retrieves a BillingSubscription resource.
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "tenantId": "string",
- "planId": "string",
- "status": "string",
- "trialEndsAt": "string",
- "currentPeriodStartedAt": "string",
- "currentPeriodEndsAt": "string",
- "cancellationRequestedAt": "string",
- "cancellationEffectiveAt": "string",
- "paymentMethodRef": "string",
- "createdAt": "string"
}Creates a BillingSubscription resource.
The new BillingSubscription resource
| reason | string or null Optional cancellation reason for audit purposes. |
{- "reason": "string"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "tenantId": "string",
- "planId": "string",
- "status": "string",
- "trialEndsAt": "string",
- "currentPeriodStartedAt": "string",
- "currentPeriodEndsAt": "string",
- "cancellationRequestedAt": "string",
- "cancellationEffectiveAt": "string",
- "paymentMethodRef": "string",
- "createdAt": "string"
}Creates a BillingSubscription resource.
The new BillingSubscription resource
| planId required | string |
{- "planId": "string"
}{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "id": "string",
- "tenantId": "string",
- "planId": "string",
- "status": "string",
- "trialEndsAt": "string",
- "currentPeriodStartedAt": "string",
- "currentPeriodEndsAt": "string",
- "cancellationRequestedAt": "string",
- "cancellationEffectiveAt": "string",
- "paymentMethodRef": "string",
- "createdAt": "string"
}Retrieves a BillingUsageReport resource.
{- "@context": "string",
- "@id": "string",
- "@type": "string",
- "tenantId": "string",
- "from": "string",
- "to": "string",
- "totals": [
- {
- "property1": 0,
- "property2": 0
}
]
}