How to download the src of an image when the image is clicked?

I have an image with an external image as its source and I want to download the image when you press on the image.
I genuinely cant think of a way to do this, any help would be greatly appreciated.

$("#image1").src = https://api.qrserver.com/v1/create-qr-code/?size=200x200&data=www.websiteexample.com
// I want to download the image there ^^^

You can’t do it using Corvid.

Are these files stored in database records?

Nope, just an external link

Has anyone found a solution to this topic?

The Pro Gallery has this functionality built in:

Alternatively if you know the fileId of your image in the media manager you can roll your own to download on click with generateFileDownloadUrl()