Skip to content

Commit f822af7

Browse files
committed
Add more fields to the tag object, from the proposal
1 parent d88c50e commit f822af7

File tree

1 file changed

+36
-5
lines changed

1 file changed

+36
-5
lines changed

src/oas.md

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2687,24 +2687,55 @@ It is not mandatory to have a Tag Object per tag defined in the Operation Object
26872687

26882688
| Field Name | Type | Description |
26892689
| ---- | :----: | ---- |
2690-
| <a name="tag-name"></a>name | `string` | **REQUIRED**. The name of the tag. |
2690+
| <a name="tag-name"></a>name | `string` | **REQUIRED**. The name of the tag. Use this value in the `tags` array of an Operation. |
2691+
| <a name="tag-summary"></a>summary | `string` | A short summary of the tag, used for display purposes. |
26912692
| <a name="tag-description"></a>description | `string` | A description for the tag. [CommonMark syntax](https://spec.commonmark.org/) MAY be used for rich text representation. |
26922693
| <a name="tag-external-docs"></a>externalDocs | [External Documentation Object](#external-documentation-object) | Additional external documentation for this tag. |
2694+
| <a name="tag-parent"></a>parent | `string` | The `name` of a tag that this tags is nested under. The named tag MUST exist in the API description, and circular references between parent and child tags MUST NOT be used. |
2695+
| <a name="tag-kind"></a>kind | `string` | A machine-readable string to categorize what sort of tag it is. Common uses are `nav` for Navigation, `badge` for badges, `internal` for internal APIs, but any string value can be used. |
26932696

26942697
This object MAY be extended with [Specification Extensions](#specification-extensions).
26952698

26962699
##### Tag Object Example
26972700

26982701
```json
26992702
{
2700-
"name": "pet",
2701-
"description": "Pets operations"
2703+
"name": "account-updates",
2704+
"summary": "Account Updates",
2705+
"description": "Account update operations",
2706+
"kind": "nav"
2707+
},
2708+
{
2709+
"name": "partner",
2710+
"summary": "Partner",
2711+
"description": "Operations available to the partners network",
2712+
"parent": "external",
2713+
"kind": "audience"
2714+
},
2715+
{
2716+
"name": "external",
2717+
"summary": "External",
2718+
"description": "Operations available to external consumers",
2719+
"kind": "audience"
27022720
}
27032721
```
27042722

27052723
```yaml
2706-
name: pet
2707-
description: Pets operations
2724+
- name: account-updates
2725+
summary: Account Updates
2726+
description: Account update operations
2727+
kind: nav
2728+
2729+
- name: partner
2730+
summary: Partner
2731+
description: Operations available to the partners network
2732+
parent: external
2733+
kind: audience
2734+
2735+
- name: external
2736+
summary: External
2737+
description: Operations available to external consumers
2738+
kind: audience
27082739
```
27092740

27102741
#### Reference Object

0 commit comments

Comments
 (0)