Skip to content

Commit 9b88fbb

Browse files
Merge pull request #10 from DolbyIO/develop
Add perm option to the get_all_recordings and get_recording APIs
2 parents cb4f4d9 + c5ca05a commit 9b88fbb

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

client/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ aiohttp>=3.7.4
22
aiofiles>=0.7.0
33
aiohttp-retry>=2.4.6
44
certifi>=2021.10.8
5+
Deprecated

client/src/dolbyio_rest_apis/communications/monitor/recordings.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
This module contains the functions to work with the monitor API related to recordings.
66
"""
77

8+
from deprecated import deprecated
89
from dolbyio_rest_apis.communications.internal.http_context import CommunicationsHttpContext
910
from dolbyio_rest_apis.communications.internal.urls import get_monitor_url
1011
from dolbyio_rest_apis.communications.monitor.models import GetRecordingsResponse, Recording, DolbyVoiceRecording
@@ -16,6 +17,7 @@ async def get_recordings(
1617
tr_to: int=9999999999999,
1718
maximum: int=100,
1819
start: str=None,
20+
perm: bool=False,
1921
) -> GetRecordingsResponse:
2022
r"""
2123
Get recording details
@@ -35,6 +37,7 @@ async def get_recordings(
3537
start: When the results span multiple pages, use this option to navigate through pages.
3638
By default, only the max number of results is displayed. To see the next results,
3739
set the start parameter to the value of the next key returned in the previous response.
40+
perm: When set to true, the URL is replaced with a monitor API signed URL with unlimited validity.
3841
3942
Returns:
4043
A :class:`GetRecordingsResponse` object.
@@ -49,6 +52,7 @@ async def get_recordings(
4952
'from': tr_from,
5053
'to': tr_to,
5154
'max': maximum,
55+
'perm': str(perm).lower(),
5256
}
5357

5458
if not start is None:
@@ -68,6 +72,7 @@ async def get_all_recordings(
6872
tr_from: int=0,
6973
tr_to: int=9999999999999,
7074
page_size: int=100,
75+
perm: bool=False,
7176
) -> List[Recording]:
7277
r"""
7378
Get all recording details
@@ -83,6 +88,7 @@ async def get_all_recordings(
8388
tr_from: The beginning of the time range (in milliseconds that have elapsed since epoch).
8489
tr_to: The end of the time range (in milliseconds that have elapsed since epoch).
8590
page_size: (Optional) Number of elements to return per page.
91+
perm: When set to true, the URL is replaced with a monitor API signed URL with unlimited validity.
8692
8793
Returns:
8894
A list of :class:`Recording` objects.
@@ -97,6 +103,7 @@ async def get_all_recordings(
97103
'from': tr_from,
98104
'to': tr_to,
99105
'max': page_size,
106+
'perm': str(perm).lower(),
100107
}
101108

102109
recordings = []
@@ -123,6 +130,7 @@ async def get_recording(
123130
tr_from: int=0,
124131
tr_to: int=9999999999999,
125132
page_size: int=100,
133+
perm: bool=False,
126134
) -> GetRecordingsResponse:
127135
r"""
128136
Get the recording of a specific conference
@@ -139,6 +147,7 @@ async def get_recording(
139147
tr_from: The beginning of the time range (in milliseconds that have elapsed since epoch).
140148
tr_to: The end of the time range (in milliseconds that have elapsed since epoch).
141149
page_size: (Optional) Number of elements to return per page.
150+
perm: When set to true, the URL is replaced with a monitor API signed URL with unlimited validity.
142151
143152
Returns:
144153
A :class:`GetRecordingsResponse` object.
@@ -153,6 +162,7 @@ async def get_recording(
153162
'from': tr_from,
154163
'to': tr_to,
155164
'max': page_size,
165+
'perm': str(perm).lower(),
156166
}
157167

158168
recordings = []
@@ -237,6 +247,7 @@ async def get_dolby_voice_recordings(
237247

238248
return DolbyVoiceRecording(json_response)
239249

250+
@deprecated(reason='This API is no longer applicable on the Dolby.io Communications APIs platform.')
240251
async def download_mp4_recording(
241252
access_token: str,
242253
conference_id: str,
@@ -270,6 +281,7 @@ async def download_mp4_recording(
270281
file_path=file_path,
271282
)
272283

284+
@deprecated(reason='This API is no longer applicable on the Dolby.io Communications APIs platform.')
273285
async def download_mp3_recording(
274286
access_token: str,
275287
conference_id: str,

0 commit comments

Comments
 (0)