Ionic react file transfer download not working

Hi there,
I am trying to do a download using FileTransfer, but it gives me an error.

body: null
code: 3
exception: null
http_status: 401
source: ""
target: "file:///storage/emulated/0/Download/test.gif"

I have read on the repo that code 3 means: FileTransferError.CONNECTION_ERR
But I am pretty sure the endpoint does not receive any request (I can notice this using another url pointing a local server).

This is my code (inside the main component of react).

const downloadFile = async () => {
    const fileTransfer = FileTransfer.create();
    let link = encodeURI("");
    let path = File.externalRootDirectory + "Download/";
    let file_name = 'test.gif';
    let completePath = path + file_name;, completePath, true).then((entry) => {
      console.log(' download complete: ' + entry.toURL());
    }, (error) => {
      console.log("error ", error)

This is my setup:

React app + Ionic + Capacitor

This is the main part of my package.json:

"@capacitor/android": "^2.4.2",
"@capacitor/core": "2.4.2",
"@ionic-native/android-permissions": "^5.28.0",
"@ionic-native/core": "^5.28.0",
"@ionic-native/document-viewer": "^5.28.0",
"@ionic-native/file": "^5.28.0",
"@ionic-native/file-opener": "^5.28.0",
"@ionic-native/file-transfer": "^5.28.0",
"cordova-plugin-android-permissions": "^1.1.0",
"cordova-plugin-document-viewer": "^1.0.0",
"cordova-plugin-file": "^6.0.2",
"cordova-plugin-file-opener": "^1.0.0",
"cordova-plugin-file-transfer": "^1.7.1",
"react": "^16.13.0",

I suppose I am using Ionic 5 from the list on the package.json.

Any help?

I have realized that this plugin is deprecated and not supported anymore, as it is published here:

“With the new features introduced in XMLHttpRequest, this plugin is not needed any more. Migrating from this plugin to using the new features of XMLHttpRequest, is explained in this Cordova blog post.”