Using the Slack API to download a file suddenly resulting in a 404 on redirect
I have a relatively simple python script that uses the slack client API to query the URL for a file attachment. The JSON that the Slack API returns includes an entry along the lines of:
"url_private": "https://files.slack.com/files-pri/XXXXXXXXX-YYYYYYYYY/Name_of_File"
When I try to fetch this URL via the python requests module or even via curl it responds with a 302 redirect to a URL along these lines:
https://files-origin.slack.com/files-pri/XXXXXXXXX-YYYYYYYYY/download/Name_of_File
Trying to fetch this second URL results in a 404 error. Has anybody else encountered this? Any ideas?
Posted Aug 23, 2019, 3:41 PM UTC
51