BookNest developer surface
Testing API
REST endpoints for functional, negative, stateful, concurrency and resilience PoCs.
Execution isolation
Send X-Test-Run-Id on every request. State with different run IDs is completely isolated. Send X-Client-Id to preserve and merge an anonymous cart. The default run is shared-demo.
Endpoints
GET
/api/v1/booksCatalogue search, filters, sorting and paginationGET
/api/v1/books/{id}Book details and inventory versionPOST
/api/v1/auth/registerRegistration validation and duplicate handlingPOST
/api/v1/auth/loginBearer session and anonymous-cart mergeGET/POST/PATCH/DELETE
/api/v1/cartPersistent cart and stock limitsPOST
/api/v1/promotions/validateValid, expired and unknown codesGET/POST
/api/v1/ordersOrder history and idempotent checkoutPOST
/api/v1/orders/{id}/cancelCancellation and stock restorationGET/POST
/api/v1/test/scenarioProtected deterministic failure controlsPOST
/api/v1/test/resetProtected test-run resetAuthentication and errors
Customer operations use a synthetic bearer token returned by login. Test-control operations require X-Test-Admin-Key. Errors use a consistent JSON envelope containing status, code, message, details and trace ID.