Skip to main content
POST
Create a number series

Autorizaciones

Authorization
string
header
requerido

API key sent as a bearer token in the Authorization header.

Encabezados

Idempotency-Key
string

Optional key that makes the request safe to retry: 1 to 255 printable ASCII characters. Sending the same key with the same body within 24 hours returns the stored response instead of executing again; such a replay carries an Idempotent-Replayed: true header. Reusing a key with a different body is rejected.

Cuerpo

application/json

The number series to create.

The number series to create.

prefix
string
requerido

Prefix stamped on every invoice number of the series. Normalized server-side: whitespace is removed and letters are uppercased. After normalization it must be 1-20 characters using only A-Z letters (no accents or "Ñ"), digits, "_", "/", "." or "-", and must be unique in the environment.

Ejemplo:

"F"

first_value
integer

The number the first invoice on this series takes. Defaults to 1.

Rango requerido: x >= 1
Ejemplo:

1

number_digits
integer

Zero-padding width of the numeric part of the invoice number (0-12). Defaults to 0, meaning no padding.

Rango requerido: 0 <= x <= 12
Ejemplo:

5

type
enum<string>

What the series numbers: regular invoices (standard) or rectifying invoices (rectifying). Defaults to standard.

Opciones disponibles:
standard,
rectifying
Ejemplo:

"standard"

Respuesta

The created number series.

An invoice numbering series as exposed by the public API. Invoice numbers are always assigned by the server: prefix plus a gapless, zero-padded counter, and on a yearly series the calendar year in between. A series is immutable once created.

id
string
requerido

Opaque, prefixed number series identifier.

Ejemplo:

"ns_clx123abc456"

prefix
string
requerido

Prefix stamped on every invoice number of this series, stored normalized: whitespace removed and letters uppercased.

Ejemplo:

"F"

type
string
requerido

What the series numbers: regular invoices (standard) or rectifying invoices (rectifying). This is an extensible enum: new values may be added in the future, so clients must tolerate values not listed here. Known values: standard, rectifying.

Ejemplo:

"standard"

first_value
integer
requerido

The number this series starts counting from. On a yearly series it applies only to the calendar year the series was created in; from the next year onward the count restarts at 1. So on a yearly series the first invoice carries this number only if it is issued in that creation year.

Ejemplo:

1

next_value
integer
requerido

The number the next invoice on this series will take. A yearly series counts within one calendar year at a time; once the current year in Europe/Madrid has moved past the year the series is counting in, this reads 1, because the next invoice restarts the count.

Ejemplo:

42

number_digits
integer
requerido

Zero-padding width of the numeric part of the invoice number. 0 means no padding.

Ejemplo:

5

is_yearly
boolean
requerido

Whether invoice numbers on this series carry the calendar year of their issue date, as PREFIX-YYYY-NUMBER, and the counter restarts at 1 on the first invoice issued in a new year. The year is derived from the issue date in Europe/Madrid time. Read-only: yearly series are created in the Finseed app, not through this API.

Ejemplo:

false

is_default
boolean
requerido

Whether this is the default series of the environment. Read-only: only the series seeded with the environment can be the default.

Ejemplo:

false

created_at
string
requerido

Creation timestamp, RFC 3339 in UTC.

Ejemplo:

"2026-06-01T09:30:00Z"