Skip to content

Commit 46c135e

Browse files
feat: expose participant kind detail (#645)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 03744fb commit 46c135e

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

livekit-rtc/livekit/rtc/__init__.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,12 @@
2020

2121
from ._proto import stats_pb2 as stats
2222
from ._proto.e2ee_pb2 import EncryptionState, EncryptionType, KeyDerivationFunction
23-
from ._proto.participant_pb2 import ParticipantKind, ParticipantState, DisconnectReason
23+
from ._proto.participant_pb2 import (
24+
ParticipantKind,
25+
ParticipantKindDetail,
26+
ParticipantState,
27+
DisconnectReason,
28+
)
2429
from ._proto.room_pb2 import (
2530
ConnectionQuality,
2631
ConnectionState,
@@ -146,6 +151,7 @@
146151
"LocalParticipant",
147152
"Participant",
148153
"ParticipantKind",
154+
"ParticipantKindDetail",
149155
"ParticipantState",
150156
"DisconnectReason",
151157
"RemoteParticipant",

livekit-rtc/livekit/rtc/participant.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,11 @@ def kind(self) -> proto_participant.ParticipantKind.ValueType:
127127
"""Participant's kind (e.g., regular participant, ingress, egress, sip, agent)."""
128128
return self._info.kind
129129

130+
@property
131+
def kind_details(self) -> list[proto_participant.ParticipantKindDetail.ValueType]:
132+
"""Additional details refining the participant's kind (e.g., cloud agent, forwarded, whatsapp/twilio connector, rtsp bridge)."""
133+
return list(self._info.kind_details)
134+
130135
@property
131136
def state(self) -> proto_participant.ParticipantState.ValueType:
132137
"""Participant's connection state (joining, joined, active, disconnected)."""

0 commit comments

Comments
 (0)