Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Annotations for OpenAPI #1478

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion advanced/publishing-apis/openapi.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ See [Frequently Asked Questions](#faq) for examples on how to use these annotati
| `Computed` | Property | omit from Create and Update structures |
| `DefaultNamespace` | Schema | path templates for actions and functions without namespace prefix |
| `Description` | Action, ActionImport, Function, FunctionImport | `summary` of Operation Object |
| `Description` | EntitySet, Singleton | `title` of Tag Object |
| `Description` | EntitySet, Singleton | `description` of Tag Object |
| `Description` | EntityType | `title` of Request Body Object |
| `Description` | ComplexType, EntityType, EnumerationType, Parameter, Property, TypeDefinition | `title` of Schema Object |
| `Description` | Schema, EntityContainer | `info.title` |
Expand Down Expand Up @@ -183,6 +183,13 @@ annotate MyService with @(
[See it in context.](https://github.com/chgeo/cds-swagger-ui-express/blob/e5794c55b53dd3e43ebe8ffcfff69341b6eac9c7/tests/app/services.cds#L23-L34){.learn-more}


## [Common](https://github.com/SAP/odata-vocabularies/blob/main/vocabularies/Common.md)

| Term | Annotation Target | OpenAPI field |
|--------------------|------------------------------|--------------------------------------------------------------------|
| `Label` | EntitySet, Singleton | `name` of Tag Object and entry in `tags` array of Operation Object |


## OpenAPI

| Term | Annotation Target | OpenAPI field |
Expand Down