2
from __future__ import unicode_literals
4
from .common import InfoExtractor
7
class GlideIE(InfoExtractor):
8
IE_DESC = 'Glide mobile video messages (glide.me)'
9
_VALID_URL = r'https?://share\.glide\.me/(?P<id>[A-Za-z0-9\-=_+]+)'
11
'url': 'http://share.glide.me/UZF8zlmuQbe4mr+7dCiQ0w==',
12
'md5': '4466372687352851af2d131cfaa8a4c7',
14
'id': 'UZF8zlmuQbe4mr+7dCiQ0w==',
16
'title': 'Damon Timm\'s Glide message',
17
'thumbnail': 're:^https?://.*?\.cloudfront\.net/.*\.jpg$',
21
def _real_extract(self, url):
22
video_id = self._match_id(url)
23
webpage = self._download_webpage(url, video_id)
24
title = self._html_search_regex(
25
r'<title>(.*?)</title>', webpage, 'title')
26
video_url = self.http_scheme() + self._search_regex(
27
r'<source src="(.*?)" type="video/mp4">', webpage, 'video URL')
28
thumbnail_url = self._search_regex(
29
r'<img id="video-thumbnail" src="(.*?)"',
30
webpage, 'thumbnail url', fatal=False)
32
thumbnail_url if thumbnail_url is None
33
else self.http_scheme() + thumbnail_url)
39
'thumbnail': thumbnail,