Skip to content

docs: modularize the 3.19 Admin API OpenAPI specification - #14148

Open
kayx23 wants to merge 5 commits into
apache:release/3.19from
kayx23:docs/modularize-admin-api-spec-3.19
Open

kayx23 wants to merge 5 commits into
apache:release/3.19from
kayx23:docs/modularize-admin-api-spec-3.19

Conversation

@kayx23

@kayx23 kayx23 commented Nov 3, 2026 •

Copy link
Copy Markdown
Member

Why

The APISIX 3.19 Admin API OpenAPI contract is stored as one minified line. GitHub therefore renders every contract update as one deleted line and one added line, preventing normal line-level review and making concurrent changes conflict on the same physical line.

This backports the modular source and deterministic generation workflow from #14147 to the 3.19 contract. The branches keep their version-appropriate API content while using the same maintenance model.

What changed

  • add docs/openapi/admin-api/openapi.yaml as the modular OpenAPI entry point
  • split all 47 Path Items into individual files under paths/
  • use YAML for the human-maintained modules while retaining JSON as the generated distribution format
  • split schemas, parameters, request bodies, responses, and security schemes into individual component files
  • add make bundle-admin-api-spec, backed by the pinned @redocly/cli@2.72.1
  • regenerate docs/en/latest/admin-api.json as formatted, self-contained JSON
  • mark the bundle as generated so reviewers can focus on the modular source
  • add contributor guidance for editing references and regenerating the bundle
  • add CI that regenerates the bundle and fails when the committed output is stale

This migration changes source organization and formatting only. It does not intentionally change the APISIX 3.19 Admin API contract.

Validation

  • bundled all 182 OpenAPI source files with no unresolved external references
  • parsed and normalized the pre-migration and generated documents, then compared their complete JSON structures: identical
  • canonicalized JSON SHA-256 before and after: 0c79c50700195889eac9501fabd33c19a635f05bd56793e7bcaf2c902636a67b
  • preserved 47 paths, 93 operations, 17 tags, 85 schemas, 15 parameters, 28 request bodies, 3 responses, and 3 security schemes
  • resolved all 572 references in the generated bundle; no internal reference is missing
  • generated the bundle twice and confirmed byte-identical SHA-256 output
  • validated the workflow YAML
  • checked the bundle script with bash -n
  • passed Markdownlint on the new contributor guide
  • git diff --check

Closes #14145.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant