Since discord introduced params to URL. The only way to circumvent this is to have a bot in the server where files are uploaded.
When sending a file chunks, save message id's and attachment id's in database, and then fetch full message object with the bot to get the updated attachment URL.