Closed
Description
Checklist
- [X ] I have verified that that issue exists against the
master
branch of Django REST framework. - [X ] I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
- [X ] This is not a usage question. (Those should be directed to the discussion group instead.)
- [X ] This cannot be dealt with as a third party library. (We prefer new functionality to be in the form of third party libraries where possible.)
- [ X] I have reduced the issue to the simplest possible case.
- I have included a failing test as a pull request. (If you are unable to do so we can still accept the issue.)
Steps to reproduce
Swagger 2.0 supports the concept of a definition #/definitions/{ModelName}. This is superseded in OpenAPI 3.0 with #/components/schemas/{ModelName}
Expected behavior
- OpenAPI 3.0 output should contain #/components/schemas/{ModelName}
- Each schemas should minimally contain the same type of information found in Swagger 2.0 definitions.
- Optionally, #/paths/... can reference #/components/schemas/{ModelName} rather than a full definition
- #/components/schemas/{ModelName} should include "title" and format="uri"
Actual behavior
- #/components/schemas is not generated.
- Information has to be scoured from the #/paths/...
- Some Information found in Swagger 2.0 definitions such as string format information is not present in any equivalent form.
- Information in i.e. #/paths.../properties/schemas is often duplicated (bigger schema file)