Tag display names

View as Markdown

By default, tag names from your OpenAPI specification become section names in your API Reference. Use the x-displayName extension to control how these section names display in your generated documentation. This is helpful for controlling capitalization and creating user-friendly names.

Define tags with display names at the root level of your OpenAPI specification, then reference them by name in your operations:

openapi.yml
1openapi: 3.0.0
2info:
3 title: Plant Care API
4 version: 1.0.0
5
6tags:
7 - name: plant
8 x-displayName: Plants
9 description: Operations for managing plants
10 - name: watering-schedule
11 x-displayName: Watering Schedules
12 description: Handle watering schedule operations
13
14paths:
15 /plants:
16 get:
17 tags:
18 - plant
19 summary: List all plants
20 /plants/{plantId}:
21 get:
22 tags:
23 - plant
24 summary: Get a plant by ID
25 /watering-schedules:
26 get:
27 tags:
28 - watering-schedule
29 summary: List watering schedules

You can also set display names in an overrides file.

Alternatively, you can rename sections directly in your docs.yml file.