# springdoc/springdoc-openapi

Library for OpenAPI 3 with spring-boot

Repository: https://github.com/springdoc/springdoc-openapi
Canonical: https://ross.abutalabs.com/products/springdoc-openapi
Homepage: https://springdoc.org
Language: Java
License: Apache-2.0
License Family: permissive
Topics: openapi3, spring-boot, springdoc-openapi, swagger-ui, swagger-documentation, openapi, openapi-specification, swagger, yaml-format, json-format, spring-data-rest, kotlin, java, oauth2, openapi-spec, rest-api, spring, spring-hateoas, spring-security, spring-webflux
Last push: 2026-08-21T09:56:03+00:00

## Health v2 (maintenance only)
Score: 97/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 98, release rhythm 95, longevity 100
- inputs: {"age_days": 2610, "days_push": 12, "days_rel": 32, "gap_med": 13, "n_releases_24m": 26}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3737, forks 601 (observed 2026-08-28T04:08:15.860978+00:00)

## What it is
springdoc-openapi is a Java library that automatically generates OpenAPI 3 API documentation for Spring Boot applications, with built-in Swagger UI and Scalar integration. It supports Spring WebMvc, WebFlux, Spring Security, Spring Data REST, Hateoas, Kotlin, and now exposes Spring REST endpoints as MCP tools for AI agents.

## Use cases
- generate openapi 3 spec from spring boot controllers
- add swagger ui to a spring boot rest api
- document spring webflux endpoints automatically
- migrate from springfox to openapi 3
- expose spring boot rest api as mcp tools for ai agents
- generate api docs in json and yaml from spring mvc
- secure and document oauth2 apis with spring security

## When to choose
- you have a Spring Boot (MVC or WebFlux) REST API and want auto-generated OpenAPI 3 docs
- you want an embedded Swagger UI or Scalar viewer with minimal configuration
- you need Spring Security, Data REST, Hateoas, or Actuator-aware API documentation
- you want to expose your Spring endpoints as MCP tools with guardrails for AI agents

## When to avoid
- your backend is not Spring-based (use framework-native OpenAPI tools instead)
- you need OpenAPI 2.0/Swagger 2.0 output rather than OpenAPI 3
- you want hand-authored, fully controlled API specs rather than code-first generation

## Facets
- artifact type: library
- maturity: stable
- function: api-documentation, documentation, mcp, middleware
- domain: apis, web-development, backend, documentation, developer-tools
- platform: jvm, self-hosted
- tags: openapi, swagger-ui, spring-boot, rest-api, api-specification, spring-webflux, spring-security, springdoc, ai-agents, spring

## Member repositories
- springdoc/springdoc-openapi (main) score 97

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:15.860978+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:29:09.722067+00:00, confidence not recorded.
  - readme: https://github.com/springdoc/springdoc-openapi (fetched 2026-08-28T04:08:15.860978+00:00, sha f73cc53627a7)
  - homepage: https://springdoc.org (fetched 2026-08-29T09:23:33.158447+00:00, sha 161cb9d7fe7b)
  - site_page: https://springdoc.org/index.html (fetched 2026-08-29T09:23:33.170293+00:00, sha 161cb9d7fe7b)
- Data as of 2026-08-30T08:39:29.467469+00:00.
