← all adapters
fattureincloud-style
simulates Fatture in Cloud API v2 2.0.29
restadapter v0.1.042 routes
verification
use it
# add to stunt.yaml
services:
fattureincloud:
adapter: embedded:fattureincloud-style
# then
$ stunt upThe embedded: source extracts this adapter from the binary — no git clone, fully offline.
how to mock the Fatture in Cloud API v2 API locally
Install stunt, paste the service block above into stunt.yaml, run stunt up — then point your client at localhost instead of Fatture in Cloud API v2. It works offline, keeps state across requests and restarts, and every response is synthetic: the route shapes, status codes, pagination, and webhook delivery follow the real Fatture in Cloud API v2 2.0.29 surface — the data is fake, the behavior is real.
backing stores
clientsissued_documentsreceived_documentsproducts
api surface (42)
generated from the adapter manifest — exactly what boots, nothing more · covers 25% of the real API's 123 routes (derived from spec openapi-fattureincloud @ 2.1.8)
42 routes
GET/user/companies
GET/c/{company_id}/company/info
PUT/c/{company_id}/company/info
GET/c/{company_id}/received_documents
POST/c/{company_id}/received_documents
GET/c/{company_id}/received_documents/info
GET/c/{company_id}/received_documents/{id}
PUT/c/{company_id}/received_documents/{id}
DELETE/c/{company_id}/received_documents/{id}
GET/c/{company_id}/issued_documents
POST/c/{company_id}/issued_documents
GET/c/{company_id}/issued_documents/info
GET/c/{company_id}/issued_documents/{id}
PUT/c/{company_id}/issued_documents/{id}
DELETE/c/{company_id}/issued_documents/{id}
GET/c/{company_id}/suppliers
POST/c/{company_id}/suppliers
GET/c/{company_id}/suppliers/{id}
PUT/c/{company_id}/suppliers/{id}
DELETE/c/{company_id}/suppliers/{id}
GET/c/{company_id}/clients
POST/c/{company_id}/clients
GET/c/{company_id}/clients/{id}
PUT/c/{company_id}/clients/{id}
DELETE/c/{company_id}/clients/{id}
GET/c/{company_id}/products
POST/c/{company_id}/products
GET/c/{company_id}/products/{id}
PUT/c/{company_id}/products/{id}
DELETE/c/{company_id}/products/{id}
GET/c/{company_id}/taxes
POST/c/{company_id}/taxes
GET/c/{company_id}/taxes/{id}
PUT/c/{company_id}/taxes/{id}
DELETE/c/{company_id}/taxes/{id}
GET/c/{company_id}/cashbook/{year}/{month}
POST/c/{company_id}/archive
GET/c/{company_id}/subscriptions
POST/c/{company_id}/subscriptions
GET/c/{company_id}/subscriptions/{id}
PUT/c/{company_id}/subscriptions/{id}
DELETE/c/{company_id}/subscriptions/{id}
VM-verified behaviors (10)
- ✓auth failures answer the flat OAuth envelope; any non-empty bearer passes
- ✓an unknown company id is the nested NOT_FOUND 404
- ✓document create wraps the v2 defaults, an int id, and decimal-string amounts
- ✓modify merges, delete clears, and the after-states keep the v2 envelope
- ✓the Laravel pagination envelope is exact and clamps page and per_page
- ✓type, date, and q filters narrow received documents inclusively
- ✓the metodata endpoint lists the sorted categories in use
- ✓subscriptions round-trip the real data.sink shape; a missing sink is a validation 400
- ✓deliveries are HMAC-signed, real-typed, and respect the types filter
- ✓F24 taxes stamp the virtual clock and flip status through the lifecycle
Not implemented (3)
- OAuth2 token dance not implemented (no authorize or token endpoints)
- No e-invoice send/retrieve side effects or email dispatch
- No receipts, settings, or document attachment endpoints
Differs from the real API (6)
- Any non-empty bearer accepted; missing/malformed header is a genuine 401
- POST /entities/{c}/archive takes JSON; the real endpoint is multipart
- Webhook HMAC uses fixed secret fic-stunt-webhook-signing-secret
- DELETE returns bare {}; real API wraps delete responses in {data: ...}
- Webhook deliveries use a platform envelope, not CloudEvents (ce-* headers, JWT bearer)
- Update events are generalized <category>.update; real API uses per-document-kind types
want more of the Fatture in Cloud API v2 surface? adapters are YAML + Starlark — the authoring guide covers adding routes, fixtures, and state machines. Open an issue for anything big first, or just file a PR — merged routes ship in the next release.