Skip to content

armgit / meet

Public Imported from GitHub
0

Open source video conferencing app powered by LiveKit. Built with Django and React.

πŸ›(backend) allow any string as sub in the API serializer

lebaudantoinedd3f23b1bf93
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 5bd6f3ec..a04e8662 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -30,6 +30,7 @@ and this project adheres to
- πŸ›(summary) extend tasks auto retry logic
- πŸ›(summary) properly detect when failure webhook should be sent
- πŸ›(backend) preserve recording metadata when updating room access
+- πŸ›(backend) allow any string as sub in the API serializer
## [1.24.0] - 2026-07-21
diff --git a/src/backend/core/api/serializers.py b/src/backend/core/api/serializers.py
index fff4c337..315f8900 100644
--- a/src/backend/core/api/serializers.py
+++ b/src/backend/core/api/serializers.py
@@ -297,8 +297,8 @@ class RoomInviteSerializer(serializers.Serializer):
class BaseParticipantsManagementSerializer(BaseValidationOnlySerializer):
"""Base serializer for participant management operations."""
- participant_identity = serializers.UUIDField(
- help_text="LiveKit participant identity (UUID format)"
+ participant_identity = serializers.CharField(
+ help_text="LiveKit participant identity (matching the user's sub format)"
)
diff --git a/src/backend/core/tests/rooms/test_api_rooms_participants_management.py b/src/backend/core/tests/rooms/test_api_rooms_participants_management.py
index 1aa0a74f..5c00bd00 100644
--- a/src/backend/core/tests/rooms/test_api_rooms_participants_management.py
+++ b/src/backend/core/tests/rooms/test_api_rooms_participants_management.py
@@ -719,13 +719,13 @@ def test_update_participant_invalid_payload():
)
client.force_authenticate(user=user)
- payload = {"participant_identity": "invalid-uuid"}
+ payload = {"participant_identity": ["test"]}
url = reverse("rooms-update-participant", kwargs={"pk": room.id})
response = client.post(url, payload, format="json")
assert response.status_code == status.HTTP_400_BAD_REQUEST
- assert "Must be a valid UUID." in str(response.data)
+ assert "Not a valid string." in str(response.data)
def test_update_participant_no_update_fields():
@@ -918,7 +918,7 @@ def test_remove_participant_invalid_payload():
)
client.force_authenticate(user=user)
- payload = {"participant_identity": "invalid-uuid"}
+ payload = {"participant_identity": ["invalid-uuid"]}
url = reverse("rooms-remove-participant", kwargs={"pk": room.id})
response = client.post(url, payload, format="json")