You’ve called it a viewset, but that doesn’t make it one; you inherit from APIView which is a standalone generic view, not a viewset.
A viewset needs to inherit from viewsets.ViewSet.
More Related Contents:
- How can I enable CORS on Django REST Framework
- DRF: Simple foreign key assignment with nested serializers?
- Django MEDIA_URL and MEDIA_ROOT
- Django – Login with Email
- Django Rest Framework File Upload
- How do I include related model fields using Django Rest Framework?
- Include intermediary (through model) in responses in Django Rest Framework
- Unicodedecodeerror with runserver
- How to redirect with post data (Django)
- Django REST Framework POST nested objects
- ImportError: No module named ‘django.core.urlresolvers’
- NoReverseMatch with keyword argument uidb64 with Django 2.0
- How can I use Django OAuth Toolkit with Python Social Auth?
- Django REST: Uploading and serializing multiple images
- Django values_list vs values
- Django Rest Framework – Authentication credentials were not provided
- Django Admin nested inline
- How to create virtual env with python3
- Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual C++ Build Tools”: http://landinghub.visualstudio.com/visual-cpp-build-tools [duplicate]
- How to get the domain name of my site within a Django template?
- Django Rest Framework – Could not resolve URL for hyperlinked relationship using view name “user-detail”
- Class Based Views VS Function Based Views
- How to set and get session variable in django?
- How to get the previous URL from a POST in Django
- How to use csrf_token in Django RESTful API and React?
- How to redirect from a view to another view In Django
- Override JSONSerializer on django rest framework
- How to add custom field in ModelSerializer?
- Add custom form fields that are not part of the model (Django)
- Multiple lookup_fields for django rest framework