diff --git a/apis_core/generic/api_views.py b/apis_core/generic/api_views.py index 1e70ad1ee..50909efdd 100644 --- a/apis_core/generic/api_views.py +++ b/apis_core/generic/api_views.py @@ -3,6 +3,7 @@ from .filterbackends import GenericFilterBackend from .helpers import first_member_match, makeclassprefix, module_paths from .serializers import GenericHyperlinkedModelSerializer, serializer_factory +from apis_core.generic.schema import GenericAutoSchema class ModelViewSet(viewsets.ModelViewSet): @@ -15,6 +16,7 @@ class ModelViewSet(viewsets.ModelViewSet): """ filter_backends = [GenericFilterBackend] + schema = GenericAutoSchema() def dispatch(self, *args, **kwargs): self.model = kwargs.get("contenttype").model_class()