The complete reference of OpenAPI extensions supported by GitBook.
Last updated
Was this helpful?
You can enhance your OpenAPI specification using extensions—custom fields that start with the x- prefix. These extensions let you add extra information and tailor your API documentation to suit different needs.
GitBook allows you to adjust how your API looks and works on your published site through a range of different extensions you can add to your OpenAPI spec.
Head to our to learn more about using OpenAPI extensions to configure your documentation.
x-page-title | x-displayName
Change the display name of a tag used in the navigation and page title.
Add an individual description for each of the enum values in your schema.
openapi.yaml
openapi: '3.0'
info: ...
components:
schemas:
project_status:
type: string
enum:
- LIVE
- PENDING
- REJECTED
x-enumDescriptions:
LIVE: The project is live.
PENDING: The project is pending approval.
REJECTED: The project was rejected.
We’re currently improving how you build API documentation in GitBook. This page covers features that are being gradually rolled out. If you don’t see them yet, hang tight—they’re on the way!