Riferimento API
Base URL https://api.cutoptim.com · versione del contratto v1
Crea una chiave nella tua dashboard, poi inviala come Authorization: Bearer <key>.
▶ Prova l'API dal vivo — senza registrazioneUsa una chiave demo pubblica — limitata, solo lavori piccoli, mai fatturata.
Integrazioni
GuideEN
ConcettiEN
Endpoint
| Metodo | Percorso | Descrizione |
|---|---|---|
| POST | /v1/optimize/2d | ottimizzazione 2D per pannelli |
| POST | /v1/optimize/1d | ottimizzazione 1D / lineare (barre, profili, tubi) |
| POST | /v1/optimize/wood | ottimizzazione del legno — 1D con abbinamento della sezione |
| POST | /v1/optimize/nest | nesting true-shape — poligoni irregolari su pannelli fissi, con zone di esclusione (laser / plasma / getto d’acqua) |
| POST | /v1/validate/2d | valida una richiesta senza risolverla — gratis, nessuna chiave, nessuna quota (2d / 1d / wood / nest) |
| POST | /v1/validate/1d | valida una richiesta senza risolverla — gratis, nessuna chiave, nessuna quota (2d / 1d / wood / nest) |
| POST | /v1/validate/wood | valida una richiesta senza risolverla — gratis, nessuna chiave, nessuna quota (2d / 1d / wood / nest) |
| POST | /v1/validate/nest | valida una richiesta senza risolverla — gratis, nessuna chiave, nessuna quota (2d / 1d / wood / nest) |
| GET | /v1/jobs/{id} | interroga un lavoro asincrono del motore max — restituisce il suo status e, una volta terminato, il piano (nessuna quota; solo i tuoi lavori) |
| POST | /v1/import/nest | legge i contorni dei pezzi da un file SVG o DXF — richiede una chiave, non consuma quota |
| GET | /v1/usage | consumo e quota dell’ACCOUNT nel mese corrente |
| GET | /v1/health | liveness — nessuna chiave, nessun rate limit, nessun database |
POST /v1/validate/{2d,1d,wood,nest} — response
The request is well-formed. No solve ran and no quota was spent.
| Campo | Tipo | Descrizione |
|---|---|---|
| valid | boolean | Always true on a 200 — a malformed request is a 400 with the exact bad field path (details.path) instead. The body is the SAME one the matching optimize endpoint takes. |
| mode | "2d" | "1d" | "wood" | "nest" | The endpoint you called. |
| contractVersion | string | Shape version. Currently "1". |
| engineEnabled | boolean | Nest only — whether the nesting engine is built into this deployment. Absent for the rectangular modes. |
| parts | { rows, total } | Part rows sent, and the total quantity after qty expansion. Check it against the part cap before you spend a call. |
| parts.rows | integer | Number of part rows sent. |
| parts.total | integer | Total quantity across all part rows (Σ qty). |
| stock | { rows, total } | The same for stock. |
| stock.rows | integer | Number of stock rows sent. |
| stock.total | integer | Total quantity across all stock rows (Σ qty). |
| warnings | string[] | Approximate, solve-free feasibility notes — e.g. a part that fits no stock (2D and nest: by bounding box; wood: no matching section long enough). Empty ⇒ every part fits some stock. Ignores trim/kerf/material (a shape check, not a solve). |
Specifica OpenAPI
Un documento OpenAPI 3.1 leggibile dalle macchine descrive tutti e dodici gli endpoint, ogni corpo di richiesta, ogni struttura di risposta e ogni errore. Fai puntare lì il generatore del tuo client, invece di trascrivere questa pagina. Il documento in sé è solo in inglese: è composto da token del contratto, e OpenAPI non prevede alcun meccanismo di localizzazione.
curl -s https://cutoptim.com/engine/openapi.json > cutoptim-engine.jsonApri il documento OpenAPI 3.1 →
- TypeScript
npm install @cutoptim/engine
GitHub · npm - Python
pip install cutoptim
GitHub · PyPI - PHP
composer require cutoptim/engine
GitHub · Packagist
A two-page summary of the Engine API — the four modes (2D, 1D, wood and true-shape nest), a request and response, determinism and pricing. Print-ready, with a QR back to the docs.