mikf / gallery-dl

Command-line program to download image galleries and collections from several image hosting sites
GNU General Public License v2.0
10.66k stars 880 forks source link

Twitter DM direct link cookie issue #5732

Closed AdamSaketume26 closed 6 days ago

AdamSaketume26 commented 1 week ago

command gallery-dl -o extractor.twitter.cookies="twitter cookies.txt" "https://ton.x.com/i/ton/data/dm/secreturl.jpg"

cmd prompt output [downloader.http][warning] '401 Unauthorized' for 'https://ton.x.com/i/ton/data/dm/secreturl.jpg"

i found the problem is because twitter changed to x so there is a problem with the extractor cookies. when i change the option to extractor.cookies it works and downloads the twitter dm direct link

mikf commented 1 week ago

https://ton.x.com/i/ton/data/dm/secreturl.jpg uses the directlink extractor and not any twitter ones, so any Twitter settings like extractor.twitter.cookies will get ignored.

Just use -C/--cookies or -o cookies=... if possible.