2👍
✅
remove ‘url’ from fields it try to add detail view to the user, but you havent:
class UserSerializer(serializers.ModelSerializer):
class Meta:
model = User
fields = ['username', 'email',]
# ^^^^^^^^^^^^^^^^^^^^^
Or try to use readonlymodelviewset
Source:stackexchange.com