You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: opentok/opentok.py
+12-16Lines changed: 12 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -1648,20 +1648,17 @@ def mute_all(self,
1648
1648
options: dict= {}) ->requests.Response:
1649
1649
1650
1650
"""
1651
-
Use this method so the moderator can mute all streams for OpenTok.
1651
+
Mutes all streams in an OpenTok session.
1652
1652
1653
-
A moderator can exclude streams Id's from being muted. Please note that a
1654
-
client is able to unmute themselves.
1653
+
You can include an optional list of streams IDs to exclude from being muted.
1655
1654
1656
-
This function stays in the OpenTok class and inherits from the Client class.
1655
+
:param session_id The session ID
1657
1656
1658
-
:param session_id gets the session id
1659
-
1660
-
:param excludedStreamIds is a list of the stream IDs for streams that should not be muted.
1657
+
:param excludedStreamIds A list of stream IDs for streams that should not be muted.
1661
1658
This is an optional property. If you omit this property, all streams in the session will be muted.
1662
1659
1663
-
:param active is a required boolean that determines whether streams published after the
1664
-
call, in addition to the current streams in the session, should be muted (True) or not (False).
1660
+
:param active Whether streams published after the call, in addition to the current streams
1661
+
in the session, should be muted (True) or not (False).
1665
1662
1666
1663
:param options is an empty dictonary representing the payload of the request,
1667
1664
whose contents will get populated inside the function
@@ -1684,9 +1681,9 @@ def mute_all(self,
1684
1681
elifresponse.status_code==400:
1685
1682
raiseGetStreamError("Invalid request. This response may indicate that data in your request data is invalid JSON. Or it may indicate that you do not pass in a session ID or you passed in an invalid stream ID.")
1686
1683
elifresponse.status_code==403:
1687
-
raiseAuthError("Failed to create session, invalid credentials")
1684
+
raiseAuthError("Failed to mute, invalid credentials.")
1688
1685
elifresponse.status_code==404:
1689
-
raiseNotFoundError("Mute not found")
1686
+
raiseNotFoundError("The session or a stream is not found.")
1690
1687
exceptExceptionase:
1691
1688
raiseOpenTokException(
1692
1689
("There was an error thrown by the OpenTok SDK, please check that your session_id {0} and excludedStreamIds (if exists) {1} are valid").format(
raiseGetStreamError("Invalid request. This response may indicate that data in your request data is invalid JSON. Or it may indicate that you do not pass in a session ID or you passed in an invalid stream ID.")
1720
1716
elifresponse.status_code==403:
1721
-
raiseAuthError("Failed to create session, invalid credentials")
1717
+
raiseAuthError("Failed to mute, invalid credentials.")
0 commit comments