JsonApi4j

JsonApi4j

JsonApi4j is a Java framework that takes the toil out of building REST APIs by automatically generating fully spec-compliant JSON:API endpoints — including pagination links, error responses, and OpenAPI documentation.

It works across Spring Boot, Quarkus, and the Jakarta Servlet API, and is data-source agnostic: SQL, NoSQL, REST clients, or in-memory stores all plug in equally. A declarative, annotation-driven model handles access control, sparse fieldsets, and compound documents without requiring custom logic.

Key features:

  • Auto-generated JSON:API endpoints — pagination, filtering, sorting, and error handling out of the box
  • Multi-framework support — Spring Boot, Quarkus, Jakarta Servlet API
  • OpenAPI docs — always in sync, generated automatically
  • Pluggable architecture — access control, sparse fieldsets, and compound document plugins
  • Any data source — SQL, NoSQL, REST clients, or in-memory stores
  • Fine-grained authorization — annotation-driven, per-resource and per-operation

I contributed to the project as an open-source collaborator.