Get redirected URLs

When I started to use DEVONthink Pro I captured a lot of PDFs without readability. I wasn’t aware of it, but it didn’t make any sense, as I captured adds etc.

So I thought it would be useful to get only the text content, but also wasn’t aware that URLs change… (which means if you try to create new records (e.g. PDFs with readability) from these URLs, DEVONthink creates a new record, but the text content is only the old URL - as DEVONthink seems to not follow redirected URLs)

If you try to get URLs that have meanwhile changed there’s this super helpful curl code:

"curl -Ls -o /dev/null -w %{url_effective} " & theURL (https://stackoverflow.com/questions/3074288/get-final-url-after-curl-is-redirected/3077316#3077316)

1 Like

In case of AppleScript using DEVONthink 3’s download commands the property last downloaded URL might be useful too.