50 return self.
_raw_data[
'videos'][
'large'][
'url']
55 return self.
_raw_data[
'videos'][
'small'][
'url']
60 return self.
_raw_data[
'videos'][
'medium'][
'url']
65 return self.
_raw_data[
'videos'][
'tiny'][
'url']
110 if (imtype ==
'large'):
112 elif (imtype ==
'medium'):
114 elif (imtype ==
'small'):
116 elif (imtype ==
'tiny'):
119 raise ValueError(
'supported types is large, medium, small and tiny.', imtype,
'unsupported')
121 r = requests.get(uri, allow_redirects=
True)
123 if (r.status_code != 200):
124 raise ValueError(
'Pixabay return status code != 200 for uri', uri,
'Invalid parameters?')
132 with open(dst,
'wb')
as handler:
def getVideoMedium(self)
Get Height of Preview.
def getVideoLarge(self)
Get Height of Preview.
def getLikes(self)
Get likes of video.
def getUserId(self)
Get author id of video.
def getPageURL(self)
Get page url of video.
def getComments(self)
Get comments of video.
def __init__(self, data)
Init video object.
def getDownloads(self)
Get downloads of video.
def getUser(self)
Get name of author of video.
def getVideoTiny(self)
Get Height of Preview.
def getVideoSmall(self)
Get Height of Preview.
def downloadRaw(self, imtype='medium')
Download video to varaible.
def getPictureId(self)
Get width of Preview.
def getType(self)
Get type of video.
def getViews(self)
Get views of video.
def download(self, dst, imtype='medium')
Download video to file.
def getDuration(self)
Get url of Preview.
def getUservideoURL(self)
Get url of video of author of video.
def getId(self)
Get ID of video.
def getTags(self)
Get tags of video.