NewThe SII in Live, under contract
BeeL
Get startedMulti-NIFVeriFactuSIIRulesStripeAPI referenceChangelog
Invoice Customization

List the invoice PDF templates

Scopeconfiguration:read

Returns the PDF templates a NIF can be rendered with. For each one, the code to send as template_type in PUT /v1/companies/{company_id}/invoice-customization, plus a name and a short description translated into the language of the user the credential belongs to.

The accepted values are already in the template_type enum; what this operation adds are the readable labels, so you do not have to show MODERN_TABLE to a person. The catalogue is identical for every account and every NIF, so it is not nested under one.

Closed catalogue. This collection is fixed and bounded: it carries no pagination, it takes no page/limit, and every response holds the whole set.


GET
/v1/invoice-customization-options
AuthorizationBearer <token>

Keys are prefixed beel_sk_, and each one carries the scopes it was created with: a key short of the scope an operation needs is answered 403. The scope an operation requires is shown next to its title, and the full catalogue lives in the Scopes reference.

Keys are created from the BeeL dashboard. They are secret credentials: do not share them or commit them to source control.

In: header

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://app.beel.es/api/v1/invoice-customization-options"
{
  "success": true,
  "data": {
    "template_types": [
      {
        "code": "MODERN_TABLE",
        "name": "Modern Table",
        "description": "Structured table design, suited to standard products and services with several lines."
      }
    ]
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}
{
  "success": false,
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Authentication is required to access this resource"
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}
{
  "success": false,
  "error": {
    "code": "FORBIDDEN",
    "message": "You do not have permission to access this resource"
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}
{
  "success": false,
  "error": {
    "code": "RATE_LIMIT_EXCEEDED",
    "message": "Too many requests. Please try again in 60 seconds."
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}
{
  "success": false,
  "error": {
    "code": "INTERNAL_ERROR",
    "message": "Internal server error"
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}
{
  "success": false,
  "error": {
    "code": "UNSUPPORTED_MEDIA_TYPE",
    "message": "Unsupported media type: text/plain. Supported: application/json"
  },
  "meta": {
    "timestamp": "2025-01-15T10:30:00Z",
    "request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
  }
}

Make an invoice design the default PUT

The series of the company without a design use this one from now on; the previous default stops being it.

Activate a compliance system for a company POST

Activates `system` for this company from `effective_from` on, in the environment of the request, with the `settings` of that system. It is a fact of the taxpayer: it applies to every invoice issued from that date, never to a single one. - **Today or later:** `effective_from` today applies the system from now on; a later date schedules it. A date in the past answers `422 COMPLIANCE_EFFECTIVE_DATE_IN_PAST`. - **Changing the settings:** activating a system that already applies, with other `settings`, ends its current period on `effective_from` and starts a new one. A later date replaces an activation of the same system that is still scheduled. - **Same body, no change:** a body equal to the activation in force or to the scheduled one answers `200` and changes nothing. - **Systems that exclude each other:** VeriFactu and the SII never apply on the same day. Activating one ends the other on `effective_from`, in the same call, and the response shows how the company is left. When that is not possible, the request answers `422 COMPLIANCE_SYSTEMS_INCOMPATIBLE` and nothing changes. - **VeriFactu:** activating `VERIFACTU` behaves like turning VeriFactu on with `PUT /v1/companies/{company_id}/verifactu-configuration`, with the same errors. That resource stays available and reports the same state. VeriFactu has no `settings`. In Live, the signed and validated AEAT representation is required and the NIF is registered for VeriFactu submission at the time of the call, also when `effective_from` is a later date. - **SII:** `settings.periodicity` and `settings.reason` are required, and `acknowledge_responsibility` must be `true`. Activating it registers the NIF of the company for SII submission, so it needs a NIF, as VeriFactu does. The option for the SII must be in force in the AEAT tax census by `effective_from`: otherwise the AEAT rejects the submissions. - **SII in Live:** the account needs the SII contracted, and every change of the SII takes effect tomorrow at the earliest: entering it, leaving it (also by activating `VERIFACTU` while the SII applies) and changing `settings.reason` or `settings.periodicity`. Leaving the SII never takes effect on a past date. The company enters the SII on 1 January, unless it declares with `settings.already_in_sii` that it is already in the SII: then it can enter on any date. Once in the SII, it can only be left from 1 January when `settings.reason` is `VOLUNTARY` or `MANDATORY_LARGE_COMPANY`, from the first day of a month when it is `REDEME`, and on any date when it is `VAT_GROUP`. Changing `settings.periodicity` of the SII in force takes effect on 1 January, so it is scheduled before that day. Moving from `VOLUNTARY` to another `reason` keeps the company in the SII and is accepted on any date from tomorrow. Any other change of `settings.reason` ends the period in force, so it follows the rule for leaving under the `reason` of that period. - **SII in Sandbox:** no contract is needed, and the company can enter and leave the SII and change its settings on any date from today. ## Order of the rules The rules are checked in this order, and the first one that fails answers; nothing is changed: 1. The request: `VALIDATION_ERROR`, `IDEMPOTENCY_KEY_REQUIRED`. 2. Access to the company: `403`. 3. A body equal to the activation in force or to the scheduled one: `200`, no change. 4. The system in the environment: `COMPLIANCE_SYSTEM_NOT_AVAILABLE`; with `SII` in Live, `SII_NOT_CONTRACTED` and then `402`. 5. The SII settings: `SII_ACKNOWLEDGEMENT_REQUIRED`, `SII_QUARTERLY_REQUIRES_VOLUNTARY`, `SII_TERRITORY_NOT_SUPPORTED`. 6. The dates: `COMPLIANCE_EFFECTIVE_DATE_IN_PAST`, `SII_CHANGE_ONLY_FROM_TOMORROW`, `SII_ENTRY_ONLY_FROM_JANUARY_FIRST`, `SII_EXIT_ONLY_FROM_JANUARY_FIRST`, `SII_EXIT_ONLY_FROM_MONTH_START`, `SII_PERIODICITY_CHANGE_ONLY_FROM_JANUARY_FIRST`, `COMPLIANCE_SYSTEMS_INCOMPATIBLE`. 7. With `VERIFACTU` in Live: `VERIFACTU_REPRESENTATION_REQUIRED`. 8. The registration of the NIF: `COMPANY_NIF_MISSING`, `API_COMMUNICATION_ERROR`. `PUT /v1/companies/{company_id}/verifactu-configuration` with `enabled: true` is this operation with `VERIFACTU` and `effective_from` today, in the same order. The response carries the same body as `GET /v1/companies/{company_id}/compliance`.