beel_create_recurring_invoice
Set up monthly recurring invoices by defining lines, recipient, series, and payment once; the template then generates invoices automatically on the chosen day, with optional draft preview and VeriFactu compliance.
Instructions
Creates a recurring invoice template under this company: the invoice data it repeats (lines, recipient, series, payment) plus the recurrence that drives it.
Cadence: generation runs monthly on
day_of_month, fromstart_dateuntilend_dateif one is given.frequencyonly acceptsMONTHLY.start_datein the past: accepted and stored as sent, but it never anchors generation backwards.next_generationmoves to the first upcomingday_of_month, and the missed periods are not generated.preview_days: how many days before the emission date the invoice is created as a draft for review.0, the default, means immediate emission.VeriFactu: omitting
verifactu_enabledapplies the company's declared preference (apply_by_default, resolving tofalsewhen the company has no VeriFactu configuration). The resolved value is frozen into the template at creation time, so changing that preference later does not alter templates that already exist.
Endpoint: POST /v1/companies/{company_id}/recurring-invoices
⚠️ Fiscal guardrails — read before calling:
How BeeL derives the AEAT invoice type, and the rules each type imposes. (resource: beel://guardrails/invoice-types)
What regime_key means, where it lives, and which combinations are rejected. (resource: beel://guardrails/regime-keys)
For the exhaustive rules and worked examples, call beel_docs_search.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | ||
| company_id | Yes | Unique identifier (UUID) of the company the operation acts on — its identifier, not its NIF. It is the only source of context: the account that owns it is derived from it, and the `BeeL-Active-Company` header plays no part. A company you do not reach answers `403`, and so does a company that does not exist, so the existence of a company in another account is never disclosed. | |
| idempotency_key | No | Optional idempotency key for this operation. Omit it and one is derived from the request itself, which makes a blind retry safe but also collapses a SECOND, deliberately identical operation into the first for 24 hours. Set it — to an order id, or anything unique per intended operation — whenever you mean to create something that may look identical to what you just created. |