diff --git a/tubearchivist/api/views.py b/tubearchivist/api/views.py index 7ae37340..5d231da5 100644 --- a/tubearchivist/api/views.py +++ b/tubearchivist/api/views.py @@ -740,7 +740,15 @@ class LoginApiView(ObtainAuthToken): print(f"returning token for user with id {user.pk}") - return Response({"token": token.key, "user_id": user.pk}) + return Response( + { + "token": token.key, + "user_id": user.pk, + "is_superuser": user.is_superuser, + "is_staff": user.is_staff, + "user_groups": [group.name for group in user.groups.all()], + } + ) class SnapshotApiListView(ApiBaseView):