From 3dd39c5f9a55b8169cf35bc2b33a08842b3c40fe Mon Sep 17 00:00:00 2001 From: SsSsS <54671367+u-spec-png@users.noreply.github.com> Date: Sat, 14 Aug 2021 19:15:01 +0000 Subject: [PATCH] [instagram] Add referrer to prevent throttling (#676) Code from: https://github.com/ytdl-org/youtube-dl/pull/29751 Fixes: https://github.com/ytdl-org/youtube-dl/issues/29736 Authored by: u-spec-png, kikuyan --- yt_dlp/extractor/instagram.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/yt_dlp/extractor/instagram.py b/yt_dlp/extractor/instagram.py index d8acef5ba..27deb0af0 100644 --- a/yt_dlp/extractor/instagram.py +++ b/yt_dlp/extractor/instagram.py @@ -277,6 +277,9 @@ class InstagramIE(InfoExtractor): 'like_count': like_count, 'comment_count': comment_count, 'comments': comments, + 'http_headers': { + 'Referer': 'https://www.instagram.com/', + } }