You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We require the ability to make an openapi spec reliably and accurately for all endpoints within the open5e api.
Requirements
A valid OpenAPI Spec can be generated fairly quickly and easily.
It can be in either JSON or Yaml format.
It needs to be reasonably accurate. (/search has some issues, so we can consider those separate).
Assuming we can reliably generate an accurate schema from code, we may NOT want to check it in to version control, because it would quickly become out of date (without discipline that we simply don't have as an open source project).
I also generally don't like adding dependencies into the project, less is always better. If it's possible to complete this using drf-spectacular, but ONLY within dev-dependencies that would be great.
The text was updated successfully, but these errors were encountered:
We require the ability to make an openapi spec reliably and accurately for all endpoints within the open5e api.
Requirements
A valid OpenAPI Spec can be generated fairly quickly and easily.
It can be in either JSON or Yaml format.
It needs to be reasonably accurate. (/search has some issues, so we can consider those separate).
Considerations
I have been using:
python manage.py generateschema
but this appears to be going towards deprecation. Probably not a good long term solution. https://www.django-rest-framework.org/api-guide/schemas/#schemaSome of the v1 endpoints and v2 endpoints have a conflicting operationId when using that command. I have attempted to resolve that by specifying a base with the AutoSchema class. https://github.com/open5e/open5e-api/blob/staging/api/views.py#L143
Assuming we can reliably generate an accurate schema from code, we may NOT want to check it in to version control, because it would quickly become out of date (without discipline that we simply don't have as an open source project).
I also generally don't like adding dependencies into the project, less is always better. If it's possible to complete this using drf-spectacular, but ONLY within dev-dependencies that would be great.
The text was updated successfully, but these errors were encountered: