download wetransfer files via terminal [closed]
Asked Answered
T

8

73

How to I download wetransfer files via linux terminal?

Terni answered 4/2, 2013 at 10:9 Comment(0)
P
148
  1. Obtain the real download link by clicking "Download Link" on WeTransfer's download page.
  2. After the download begins, right-click on the file being downloaded and select "Copy Download Link".
  3. Find out your browser's User Agent. You can use whatsmyuseragent to grab it.
  4. Prepare your wget command and download the file.

Example:

wget --user-agent Mozilla/4.0 '[your big address here]' -O dest_file_name

Don't forget the quotes.

[your big address here] must be the direct link to the file, not the forwarded html page. You can get the big address by starting the download on any machine, then copy the link from your download-manager (eg. firefox, chrome)

Peracid answered 27/4, 2013 at 18:2 Comment(15)
Looks like this method doesn't work any more unfortunately, the file is redirected to an HTML page which contains the message: You are using an outdated browser that WeTransfer no longer supports. Even with a modern UserAgent string it still fails...Tantalize
It works. You just have to obtain real download link. Using Firefox click download link on wetransfer download page. After download begins right click on download and click "copy download link". Go to whatsmyuseragent.com and grab your browsers user agent. Prepare your wget command and download file. CheersMidian
Works for me. 'Your big address' is obviously the download link the browser is sent by wetransfer, after you click on Download there, not the original http://we.tl/XXXXXXXXX address. Maybe some of the commenters who reported this answer not working for them confused the two? One thing I had to add to the wget line was the --no-check-certificate switch because the certificates issued for the resp. server were not trusted by wget, so my final command looke sth. like: wget --user-agent Mozilla/4.0 --no-check-certificate 'https://wetransferbeta-eu.s3.amazonaws.com/...' -O archive.tbz2Cuyler
I couldn't get it to work, I also tried --no-check-certificate and even supply a cookie file and real user agent from my browser (could do something wrong though). The link obtained like @EmreErkan said and the one in the email look identical to me.Strata
Just open the network tab in the browser console before clicking on the download link. Then click on the download button and copy the get request url from the network tab.Integrate
If you're using Chrome you can use chrome://downloads to get the actual download link. It expires fairly quickly though, after which you get a 302 error.Enfeoff
I don't know if this is working anymore-- there is a signature value passed in the link parameters. I was trying to wget --content-disposition --user-agent 'Mozilla/4.0' download.wetransfer.com/wetransfer-eu1/… from wetransfer.com/downloads/… and I get HTTP request sent, awaiting response... 400 Bad RequestParade
Oh, ha ha-- I needed to put the entire link in single-quotes :pParade
The & symbol in the link needs to be escaped or the whole address put in quotes. Do not disable the certificate check as it is a security risk.Deceitful
This worked for me without any tweaks or additions. All I had to do was actually begin downloading the file so that I could grab the URL either in my Downloads window or in my Network tab in Dev Tools. Thank you!Pushed
I can also confirm that this works as per november 2016Mizell
Working perfectly - as of Nov 2017Varese
and it even works with wget -c to resume an interrupted download started in the browser 🎉Tolan
This method works for me if I start the download immediately. But if I schedule the download to begin later (for me at night time when the internet is free) then I get an error link broken. Does anyone know if there is a time limit on the validity of these real download links? I don't have a Plus account.Affianced
it works for me without the user agent on AWS Lightsail VMNeon
S
34

I couldn't get it working with wget so here's an alternative using curl:

curl '{pretty_long_appendix_here}' --location --output {file_name_on_my_disk}

replace

{pretty_long_appendix_here}

with the actual download url [starting with https://download.wetransfer.com/] you get when you actually start the download.

In chrome for example start the download and go to

Window > Downloads

Stop the running download and copy the download-URL by right-clicking on it.

Replace

{file_name_on_my_disk}

with the actual name you want the file to be stored on your disk.

Sue answered 5/5, 2017 at 21:0 Comment(0)
P
15

Alejandro Alonso wrote a Python script py-wetransfer for downloading wetransfer files in command line mode.

With a we transfer address similar to https://www.wetransfer.com/downloads/XXXX/YYYY/ZZZZ you can execute this command to download the file:

python wetransfer.py -u https://www.wetransfer.com/downloads/XXXX/YYYY/ZZZZ

It requires Python and Requests.

Partlow answered 17/4, 2013 at 16:28 Comment(1)
This script is no more working, use the MarcosBL's fork instead: github.com/MarcosBL/py-wetransfer/blob/master/wetransfer.pyMenthol
C
7

Solution working in October 2021. Just wget and a browser are required:

  1. access your wetransfer link in any modern browser (https://wetransfer.com/downloads/<>)

  2. open the developer console / panel and head to the network tab

Network tab

  1. set the network speed to 3G (in chrome, or the lowest one on your browser)*

Lower network speed for this tab

  1. click download

  2. in the network tab, find the request that was created right after clicking download and inspect it

Find the request

  1. On the request preview, copy the direct_link content

enter image description here

  1. Now just do wget -o myfile 'your direct link'

  2. You can be nice enough to cancel the download that's still going on your browser so you don't consume that much bandwidth from wetransfer

*You should lower your tab speed because every direct_link has a token attached to it. This token expires once the download is complete. So you want to make sure the download on your browser will take longer than the one on your terminal.

Coleville answered 14/10, 2021 at 7:50 Comment(2)
still works 2023Slander
Worked fine for me until very recently when it suddenly stopped working. Traced the problem to a change in the query string, where they have added cf=y as the first item before token. Change ?cf=y&token=xxxxxx to ?token=xxxxxx and you are once again good to goTiphany
W
4

WeTransfer does offer an option to upload/download files via terminal

enter image description here [ Source : https://wetransfer.com/products ]

You've to download WTClient from here available for Win, Mac and Linux.

enter image description here

Even though it has useful options like 'debug mode'

enter image description here

downloading is only possible with a Plus account.

enter image description here

bummer!


ReadMe

enter image description here

Willey answered 21/4, 2020 at 4:43 Comment(1)
Downloading from the CLI is only possible with a Plus account.Howse
L
2

This utility written in Go seems very well made and worked right away for me, in 2022:

https://github.com/gnojus/wedl

Uses unofficial wetransfer API used when downloading with a browser.

The Python scripts above and their forks didn't work.

Lepsy answered 30/11, 2022 at 14:54 Comment(0)
I
1

I've forked and updated Marcos' fork of Alejandro Alonso's py-wetransfer script.

It's now able to work on Python 2.x or 3.x, and it can handle the shortened links. You can find it here: https://github.com/GaryWatsonUK/py-wetransfer/blob/master/wetransfer.py

(Thanks for sharing your work, guys! I learned a lot from it.)

Introit answered 15/9, 2020 at 22:31 Comment(0)
M
0

If you don't have terminal access, here's a PHP script that can download WeTransfer links.

I've used it to save time when having to download files to my computer, and then upload them to a server.

Magda answered 20/3, 2015 at 12:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.