mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-10-30 21:20:34 +00:00
dc6193cb22
how to redirect to another extractor
939 B
939 B
- Q: How to redirect to another extractor?
- A:
- Most simple using only
url_result
# get proper url first if needed. return self.url_result(url)
- Using
_request_webpage
andto_screen
in additionurlh = self._request_webpage( url, id, note='Downloading redirect page') url = urlh.geturl() self.to_screen('Following redirect: %s' % url) return self.url_result(url)
- Using
return
constructionreturn { '_type': 'url_transparent', 'url': url, 'ie_key': ExampleIE.ie_key(), 'id': id, } # Alternative if extractor supports internal uri like kaltura return { '_type': 'url_transparent', 'url': 'kaltura:%s:%s' % (partner_id, kaltura_id), 'ie_key': KalturaIE.ie_key(), 'id': id, }
- Most simple using only
- A: