officina.it Cestino API
The Cestino API from officina.it — 1 operation(s) for cestino.
The Cestino API from officina.it — 1 operation(s) for cestino.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/officina-it:officina-it-cestino-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: officina.it Cestino API
version: '2026-11-17'
description: 'API REST pubblica di officina.it: consente di leggere e scrivere i dati
della propria officina da altri programmi (gestionali contabili, sistemi
di flotta, strumenti di analisi). L''autenticazione avviene con una chiave API (`Authorization: Bearer
ofk_live_…`) generata da Impostazioni → Accesso API. Ogni chiave porta
permessi per risorsa e appartiene a una singola officina. Ogni richiesta deve indicare la revisione del contratto con l''header
`X-API-Version`. Il percorso `/v1` identifica la versione maggiore, che
cambia solo per modifiche non retrocompatibili; la revisione identifica
la data del contratto. La documentazione completa è su
https://officina.it/api. ## Revisioni
Ogni revisione dentro `/v1` è additiva: dichiarare una revisione più
vecchia continua a funzionare, semplicemente senza i campi più recenti. I campi e gli endpoint introdotti da una revisione riportano
`x-since: ''AAAA-MM-GG''` (schemi) o `x-changes` (operazioni). | Revisione | Novità | Azione |
|---|---|---|
| 2026-11-17 | Targa già presente. Il `409 license_plate_taken` di `POST /v1/vehicles` e `PATCH /v1/vehicles/{id}` porta `reason`: chi ha il veicolo che ha già la targa rispetto al cliente del veicolo che si sta salvando (`same_customer`, `no_customer`, `other_customer`); se più veicoli hanno la targa, `candidates` indica quello dello stesso cliente, poi uno senza cliente, poi il più vecchio, e `message` dice di chi è (entrambe le cose a ogni revisione dal 2026-10-22). Visura targa nell''app (`POST /v1/vehicles/license-plate-lookup`, non esposta nell''API pubblica): da questa revisione, se un veicolo attivo ha già la targa, risponde lo stesso `409` su `/license_plate` senza eseguire la visura; accetta `customer_id` (il cliente per cui si crea il veicolo) e `allow_duplicate_license: true` per eseguire comunque la visura. Le revisioni precedenti eseguono la visura come prima. | Opzionale |
| 2026-11-11 | Righe di schede lavoro, preventivi, fatture e scontrini: `article_code` è il codice della riga (scritto con la riga, non cambia se cambia l''articolo), assente se non ne ha, e `description` non lo contiene più. In `…/line-items/batch` `article_code` si invia sulle righe senza articolo (`""` lo toglie); sulle righe con `article_id` è quello dell''articolo, e in update un valore diverso da quello della riga risponde `422` su `/article_code`. Le revisioni precedenti vedono quello che vedevano: `article_code` è il codice attuale dell''articolo e, se l''officina stampa i codici, il codice salvato torna davanti a `description`; il loro `article_code` in scrittura è ignorato. | Opzionale |
| 2026-11-09 | Potenza motore (`engine_power_kw`) con al massimo due decimali, maggiore di 0 e al massimo 2000 (`422` su `/engine_power_kw` fuori dai limiti, a ogni revisione; le revisioni precedenti possono ancora inviare 0, salvato come vuoto). Le revisioni precedenti la ricevono arrotondata all''intero; un `PATCH` che rimanda il valore arrotondato non cambia quello salvato. | Opzionale |
| 2026-11-02 | Schede lavoro, preventivi, accettazioni e appuntamenti non riportano più `work_category_id` e `work_category_name`, le fatture `work_category_name`: si leggono `work_category_ids` / `work_categories` (`work_category_names` sulle fatture). In scrittura `work_category_id` risponde `422` su `/work_category_id`. Le righe collegate a un articolo riportano `work_category_names`, le categorie dell''articolo, e `article_code`, il suo codice (anche per le revisioni precedenti). Gli elenchi di clienti e veicoli riportano `custom_fields` come il dettaglio. L''etichetta del filtro categorie senza filtro diventa `Tutte` (era `tutte`). | Opzionale |
| 2026-10-31 | Ogni numero in scrittura segue le regole dei moduli web (`422` sul campo, con il messaggio del web). Righe di schede e preventivi: `quantity` e `unit_price` anche negativi, `unit_discount_rate` intero 0–100 (12.5 veniva salvato come 12). Importi arrotondati al centesimo; negativi, zero e decimali rifiutati dove il campo non li ammette.'
contact:
name: officina.it engineering
email: assistenza@officina.it
servers:
- url: https://api.officina.it
description: Production
- url: http://localhost:8084
description: Local development
security:
- PublicAPIKey: []
tags:
- name: Cestino
paths:
/v1/trash:
parameters:
- $ref: '#/components/parameters/APIVersion'
get:
x-changes:
- since: '2026-10-22'
it: 'Nuovo endpoint: i documenti e i record eliminati dell''officina, con chi li ha eliminati e quando.'
en: 'New endpoint: the workshop''s deleted documents and records, with who deleted them and when.'
tags:
- Cestino
summary: List deleted records (the Cestino)
x-summary-it: Elenca i documenti e i record eliminati
x-scope: trash.read
operationId: trashList
x-description-it: 'Il Cestino di Impostazioni: ogni documento o record eliminato
dell''officina (fatture, scontrini, note di credito, schede lavoro,
preventivi, clienti, veicoli, articoli, appuntamenti, accettazioni,
spese, ordini, fornitori, depositi gomme, DDT, vendite e noleggi),
dal più recente, normalizzato alle stesse colonne: tipo, numero o
nome, cliente, importo, data di eliminazione e chi l''ha eliminato
(dal registro attività; `null` per le eliminazioni più vecchie).
Niente viene mai eliminato definitivamente e nessun numero viene
riutilizzato: un documento fiscale numerato eliminato riporta
`number_unused: true`.
`type` sceglie una scheda (`all`, `invoice`, `receipt`, `worksheet`,
`quote`, `customer`, `vehicle`, `article`, `other`), `q` cerca per
numero, nome, targa o codice, `period` sceglie la finestra (`c30`,
`c60`, `c180`, `c365`, `all`). Ogni pagina riporta `counts` per
scheda, il `period` applicato e `periods` con il flag `allowed`.
Lo storico dipende dal piano (`window_days`): 30 giorni con Base,
180 con Pro, tutto con Business e Illimitato. Senza `period` si
applica la finestra più ampia del piano; un `period` oltre il piano
risponde `402 plan_upgrade_required` con `param: /period`. Serve un
abbonamento attivo (`402 subscription_required` altrimenti). Sola
lettura: il ripristino non è disponibile via API e i dettagli di un
record eliminato rispondono `404` su ogni endpoint.
'
description: 'The Impostazioni → Cestino page as data: every soft-deleted
document or record of the workshop (invoices, receipts, credit
notes, worksheets, quotes, customers, vehicles, articles, calendar
entries, check-ins, expenses, orders, suppliers, tyre sets, delivery
notes, vehicle sales and rentals), newest deletion first, normalised
to one row shape: type, number or label, customer, amount, deletion
time and the user who deleted it (from the events log; `null` for
older deletions). Nothing is ever purged and no number is reused:
a numbered fiscal document that was deleted reports
`number_unused: true`.
`type` picks a tab (`all`, `invoice`, `receipt`, `worksheet`,
`quote`, `customer`, `vehicle`, `article`, `other`), `q` searches
number, name, plate or code, `period` picks the window (`c30`,
`c60`, `c180`, `c365`, `all`). Every page carries the per-tab
`counts`, the applied `period` and `periods` with their `allowed`
flag, so a client can render the control without knowing the plan.
The history window depends on the plan (`window_days`): 30 days on
Base, 180 on Pro, everything on Business and Illimitato. Without
`period` the plan''s widest window applies; a `period` beyond the plan
answers `402 plan_upgrade_required` with `param: /period`. An active
subscription is required (`402 subscription_required` otherwise).
Read-only: restore is not on the API, and a deleted record''s detail
answers `404` on every endpoint. Pages are keyset cursors on
`(deleted_at, id)`.'
parameters:
- name: type
in: query
required: false
description: Tab to list. Unknown values are rejected with 422.
schema:
type: string
enum:
- all
- invoice
- receipt
- worksheet
- quote
- customer
- vehicle
- article
- other
default: all
- name: q
in: query
required: false
description: Substring of the number, name, plate, title or code.
schema:
type: string
- name: period
in: query
required: false
description: 'History window. Must be allowed by the plan (`periods[].allowed`),
else `402 plan_upgrade_required`. Omitted: the plan''s widest window.
'
schema:
type: string
enum:
- c30
- c60
- c180
- c365
- all
- name: limit
in: query
required: false
schema:
type: integer
minimum: 1
maximum: 100
default: 20
- name: starting_after
in: query
required: false
description: The `next_starting_after` of the previous page.
schema:
type: string
responses:
'200':
description: One page of deleted records, newest deletion first, plus counts and the period control.
x-description-it: Una pagina di record eliminati, dal più recente, con i conteggi e i periodi.
headers:
X-API-Version:
$ref: '#/components/headers/APIVersion'
Deprecation:
$ref: '#/components/headers/Deprecation'
Sunset:
$ref: '#/components/headers/Sunset'
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/ListEnvelope'
- type: object
required:
- period
- periods
- window_days
- counts
properties:
data:
type: array
items:
$ref: '#/components/schemas/DeletedRecord'
period:
$ref: '#/components/schemas/TrashPeriod'
periods:
type: array
items:
$ref: '#/components/schemas/TrashPeriodOption'
window_days:
type: integer
description: The plan's history window in days, -1 = unlimited.
counts:
$ref: '#/components/schemas/TrashCounts'
example:
object: list
data:
- object: deleted_record
type: invoice
id: 2f6c1a84-93d7-4e1b-b0a2-7c58d9e3f614
seq_number: 816
label: Tagliando 60.000 km
meta: ''
customer_name: Mario Rossi
amount: 285.36
issued: true
number_unused: true
numbered_at: '2026-09-30T10:12:00Z'
deleted_at: '2026-10-03T16:40:12Z'
deleted_by: Luca Bianchi
- object: deleted_record
type: customer
id: 4c911f08-7713-4e83-bdf6-a0692a1b43fd
seq_number: null
label: Rossi Autotrasporti Srl
meta: Azienda
customer_name: ''
amount: null
issued: null
number_unused: false
numbered_at: '2026-02-11T09:00:00Z'
deleted_at: '2026-10-01T08:05:44Z'
deleted_by: null
has_more: false
url: /v1/trash
period:
object: trash_period
key: c30
label: Ultimi 30 giorni
days: 30
from: '2026-09-22'
to: '2026-10-22'
periods:
- object: trash_period_option
key: c30
label: Ultimi 30 giorni
days: 30
allowed: true
- object: trash_period_option
key: c60
label: Ultimi 60 giorni
days: 60
allowed: false
- object: trash_period_option
key: c180
label: Ultimi 180 giorni
days: 180
allowed: false
- object: trash_period_option
key: c365
label: Ultimo anno
days: 365
allowed: false
- object: trash_period_option
key: all
label: Tutto lo storico
days: -1
allowed: false
window_days: 30
counts:
object: trash_counts
all: 2
invoice: 1
receipt: 0
worksheet: 0
quote: 0
customer: 1
vehicle: 0
article: 0
other: 0
'401':
$ref: '#/components/responses/Unauthorized'
'402':
$ref: '#/components/responses/PaymentRequired'
'403':
$ref: '#/components/responses/Forbidden'
'422':
$ref: '#/components/responses/ValidationError'
'500':
$ref: '#/components/responses/InternalError'
components:
responses:
InternalError:
x-description-it: Errore imprevisto del server. Il dettaglio finisce nei log, non nella risposta.
description: Unhandled server error. Detail is logged, not exposed.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
example:
error:
type: https://api.officina.it/errors/internal_error
status: 500
code: internal_error
message: An unexpected error occurred. Please retry or contact support if it persists.
trace_id: abc-123
ValidationError:
x-description-it: 'Un campo della richiesta manca o non è valido: «param» indica quale.'
description: A request field is missing or invalid (fast-fail).
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
example:
error:
type: https://api.officina.it/errors/parameter_invalid
status: 422
code: parameter_invalid
message: Email must be a valid email address.
param: /email
trace_id: abc-123
Forbidden:
x-description-it: La chiave non ha il permesso richiesto per questa operazione.
description: The authenticated user lacks the required permission.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
example:
error:
type: https://api.officina.it/errors/insufficient_scope
status: 403
code: insufficient_scope
message: La chiave non ha il permesso reports.read.
trace_id: abc-123
PaymentRequired:
x-description-it: Il piano non include l'accesso API, oppure non è attivo un abbonamento.
description: 'The company has no active subscription, or its plan does not
include API access. API access is included in the Business and
Illimitato plans.
'
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
example:
error:
type: https://api.officina.it/errors/plan_upgrade_required
status: 402
code: plan_upgrade_required
message: Il piano attivo non include l'accesso API.
trace_id: abc-123
Unauthorized:
x-description-it: Chiave API mancante, non valida, revocata o scaduta.
description: Missing, malformed, expired, or wrong-audience bearer token.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
example:
error:
type: https://api.officina.it/errors/api_key_invalid
status: 401
code: api_key_invalid
message: Chiave API mancante, non valida, revocata o scaduta.
trace_id: abc-123
headers:
Deprecation:
description: 'Present only when the declared `X-API-Version` is older than the current
revision (RFC 9745): the revision still works but is deprecated. The value
is `@` + the Unix time of the current revision''s date. Comes with
`Link: <https://officina.it/api#deprecazione>; rel="deprecation"`.
'
schema:
type: string
example: '@1792022400'
Sunset:
description: 'Present only when the declared revision has a scheduled retirement
(RFC 8594): the HTTP date from which calls with it answer
`400 api_version_retired`. Announced at least 90 days ahead.
'
schema:
type: string
example: Wed, 20 Jan 2027 00:00:00 GMT
APIVersion:
description: Echoes the `X-API-Version` value the server processed.
schema:
type: string
schemas:
ErrorBody:
type: object
required:
- type
- status
- code
- message
description: 'Single error per response (fast-fail). Inspired by RFC 9457
Problem Details, wrapped in an `error` root key so success
and error bodies are visually distinguishable.
'
properties:
type:
type: string
format: uri
description: URI identifying the error class. Stable.
example: https://api.officina.it/errors/invalid_credentials
status:
type: integer
description: HTTP status code, mirrored from the response.
example: 401
code:
type: string
description: 'Stable machine-readable identifier (snake_case). Clients
branch on this, never on `message`.
'
example: invalid_credentials
message:
type: string
description: Human-readable English explanation.
param:
type: string
description: 'JSON Pointer (RFC 6901) to the offending request field.
Omitted when the error isn''t tied to a specific input
field (e.g. auth errors).
'
example: /email
trace_id:
type: string
description: Request trace ID for support correlation.
candidates:
type: array
items:
type: string
description: 'Only on `ambiguous_number`: the ids of every record the
number matched, to retrieve the right one by id.
'
reason:
type: string
enum:
- disabled
- fully_paid
- already_applied
- nothing_to_charge
- same_customer
- no_customer
- other_customer
x-since: '2026-10-06'
description: 'On `waste_disposal_not_applicable`: why the charge can''t be
applied to the document. On `license_plate_taken` (from
2026-11-17): who has the vehicle that already carries the plate,
seen from the customer of the vehicle being saved or looked up
(`same_customer`, `no_customer`, `other_customer`).
'
TrashCounts:
type: object
x-since: '2026-10-22'
description: Per-tab counts for the active search and period.
required:
- object
- all
- invoice
- receipt
- worksheet
- quote
- customer
- vehicle
- article
- other
properties:
object:
type: string
const: trash_counts
all:
type: integer
invoice:
type: integer
receipt:
type: integer
worksheet:
type: integer
quote:
type: integer
customer:
type: integer
vehicle:
type: integer
article:
type: integer
other:
type: integer
ListEnvelope:
type: object
required:
- object
- data
- has_more
- url
properties:
object:
type: string
const: list
description: Polymorphic discriminator.
data:
type: array
description: Page of items. Each item carries its own `object` field.
items: {}
has_more:
type: boolean
description: 'True if more results exist beyond this page. Use this
for the "load more" UI — `data.length` alone is
unreliable because a full page may still be the last
page.
'
next_starting_after:
type: string
description: 'Opaque cursor for the next page. Present (and non-empty)
when `has_more` is `true`; omitted otherwise. Pass the
value verbatim as `?starting_after=` on the follow-up
request. Clients MUST NOT parse it — today it encodes
an offset, tomorrow it may encode a `(created_at, id)`
tuple without a wire-visible change.
'
url:
type: string
description: The request path that produced this list.
TrashPeriod:
type: object
x-since: '2026-10-22'
description: The history window applied to the page.
required:
- object
- key
- label
- days
properties:
object:
type: string
const: trash_period
key:
type: string
enum:
- c30
- c60
- c180
- c365
- all
label:
type: string
days:
type: integer
description: -1 = the whole history.
from:
type: string
format: date
description: Omitted for `all`.
to:
type: string
format: date
description: Omitted for `all`.
TrashPeriodOption:
type: object
x-since: '2026-10-22'
description: One entry of the period control with its plan state.
required:
- object
- key
- label
- days
- allowed
properties:
object:
type: string
const: trash_period_option
key:
type: string
enum:
- c30
- c60
- c180
- c365
- all
label:
type: string
days:
type: integer
allowed:
type: boolean
description: Whether the plan window covers it; a request for a locked one answers 402.
DeletedRecord:
type: object
x-since: '2026-10-22'
description: 'One soft-deleted record of the Cestino, whatever its type,
normalised to the page''s columns. Amounts of invoices and receipts
are derived from the source worksheet, sale or rental, never from
the document''s own snapshot.
'
required:
- object
- type
- id
- seq_number
- label
- meta
- customer_name
- amount
- issued
- number_unused
- numbered_at
- deleted_at
- deleted_by
properties:
object:
type: string
const: deleted_record
type:
type: string
enum:
- invoice
- receipt
- credit_note
- worksheet
- quote
- customer
- vehicle
- article
- calendar_entry
- checkin
- expense
- order
- supplier
- tyre_set
- delivery_note
- vehicle_sale
- rental_schedule
id:
type: string
seq_number:
type:
- integer
- 'null'
description: Progressive number; null for drafts and records without a series.
label:
type: string
description: Main line when there is no number, such as the name, the title or the plate.
meta:
type: string
description: Second line, such as the vehicle, the type, the code or the date. Empty when none.
customer_name:
type: string
amount:
type:
- number
- 'null'
description: Document total net of discount; null for records without one.
issued:
type:
- boolean
- 'null'
description: Fiscal documents only, whether it had a number or an issue date when deleted. Null otherwise.
number_unused:
type: boolean
description: A numbered fiscal document deleted before the finality rule, whose number sits unused in the series.
numbered_at:
type: string
format: date-time
description: The date its number is formatted with (issue date, else creation).
deleted_at:
type: string
format: date-time
deleted_by:
type:
- string
- 'null'
description: Name of the user who deleted it, from the events log; null when unknown.
ErrorEnvelope:
type: object
required:
- error
properties:
error:
$ref: '#/components/schemas/ErrorBody'
parameters:
APIVersion:
name: X-API-Version
in: header
required: true
description: 'The client''s declared revision: the dated `/v1` contract this
client build was developed against. Floor-checked, not an
allowlist — must be a `YYYY-MM-DD` date and at least the minimum
supported revision (`api_version_retired` below it, meaning the
client build is too old); dates newer than the deployed server
are accepted and served with current behaviour. Clients should
also self-identify via the optional headers `X-Client`
(`officina-mobile/1.0.0 (ios)`), `X-App-Version` (`1.0.0`),
`X-Platform` (`ios`) and `X-OS-Version` (`18.5`) — all stamped
on the request logs (`client`, `app_version`, `platform`,
`os_version`) so revision adoption and platform-specific issues
are measurable before the floor is raised.
Current: `2026-07-15`. Minimum: `2026-07-15` (single pre-launch
revision). See the README registry and
`apihttp.CurrentAPIVersion` / `MinSupportedAPIVersion` for the
source of truth.
'
schema:
type: string
pattern: ^\d{4}-\d{2}-\d{2}$
example: '2026-07-15'
securitySchemes:
PublicAPIKey:
type: http
scheme: bearer
bearerFormat: APIKey
description: 'Long-lived API key minted from Impostazioni → Accesso API.
Format `ofk_live_<43 chars>` (`ofk_test_` outside production).
Send it as `Authorization: Bearer ofk_live_…`.
A key authorises a COMPANY and carries per-resource scopes;
a call outside its scopes answers 403 `insufficient_scope`.
Keys are shown once at creation and stored only as a digest.
'
x-doc-groups:
- slug: clienti
name: Clienti
tags:
- Customers
ready: true
description: Anagrafiche, documenti allegati e storico.
- slug: veicoli
name: Veicoli
tags:
- Vehicles
ready: true
description: Veicoli, marche e documenti allegati.
- slug: schede-lavoro
name: Schede lavoro
tags:
- Worksheets
- TimeTracking
ready: true
description: Schede, righe, pagamenti, stati di lavorazione e marcatempo.
- slug: preventivi
name: Preventivi
tags:
- Quotes
ready: true
description: Preventivi, righe e conversione in scheda lavoro.
- slug: fatture
name: Fatture
tags:
- Invoices
- CreditNotes
ready: true
description: Fatture, note di credito, pagamenti ed emissione.
- slug: scontrini
name: Scontrini
tags:
- Receipts
ready: true
description: Scontrini e relativi pagamenti.
- slug: accettazioni
name: Accettazioni
tags:
- Checkins
ready: true
description: Accettazioni, conversioni e documenti.
- slug: agenda
name: Agenda
tags:
- Calendar
ready: true
description: Calendari e appuntamenti.
- slug: magazzino
name: Magazzino
tags:
- Articles
ready: true
description: Articoli, listino manodopera e movimenti.
- slug: deposito-gomme
name: Deposito gomme
tags:
- TyreSets
ready: true
description: Pneumatici in deposito e passaggi di stato.
- slug: fornitori
name: Fornitori
tags:
- Suppliers
ready: true
description: Fornitori, ordini e documenti di trasporto.
- slug: spese
name: Spese
tags:
- Expenses
ready: true
description: Spese, pagamenti e categorie.
- slug: prima-nota
name: Prima nota
tags:
- CashBook
ready: true
description: Movimenti di cassa e conti finanziari.
- slug: impostazioni
name: Impostazioni
tags:
- Settings
- Cestino
ready: true
description: Dati azienda, aliquote IVA, listini, collaboratori, cestino.
- slug: fatturazione-elettronica
name: Fatturazione elettronica
tags:
- ElectronicInvoicing
ready: true
description: Fatture elettroniche emesse e ricevute, in sola lettura.
- slug: concessionaria
name: Concessionaria
tags:
- Dealership
ready: true
description: Stock veicoli, vendite e report.
- slug: report
name: Report
tags:
- Reports
ready: true
description: Statistiche e contatori della tua officina.
- slug: autenticazione
name: Autenticazione
tags:
- Authentication
ready: true
description: Verifica della chiave e dei permessi.