diff --git a/web/b3desk/models/bbb.py b/web/b3desk/models/bbb.py index eb74f8d..60b0397 100644 --- a/web/b3desk/models/bbb.py +++ b/web/b3desk/models/bbb.py @@ -275,9 +275,26 @@ def get_recordings(self): type = format.find("type").text if type in ("presentation", "video"): data["playbacks"][type] = { - "url": format.find("url").text, + "url": (media_url := format.find("url").text), "images": images, } + if type == "video": + try: + resp = requests.get( + direct_link := media_url + "video-0.m4v" + ) + if resp.status_code == 200: + data["playbacks"][type]["direct_link"] = ( + direct_link + ) + except ( + requests.exceptions.HTTPError, + requests.exceptions.ConnectionError, + ): + current_app.logger.warning( + "No direct recording link for meeting %s", + self.meeting.meetingID, + ) result.append(data) except Exception as exception: current_app.logger.error(exception) diff --git a/web/b3desk/templates/meeting/recordings.html b/web/b3desk/templates/meeting/recordings.html index 9c6a826..5b786d1 100644 --- a/web/b3desk/templates/meeting/recordings.html +++ b/web/b3desk/templates/meeting/recordings.html @@ -58,9 +58,13 @@