Can not download the file

Describe the problem/error/question

When I get file link from trigger it gives error and not downloads.

Any help will be appreciated.

What is the error message (if any)?

Forbidden perhaps check parameters.

Please share your workflow

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

{
  "nodes": [
    {
      "parameters": {
        "url": "={{ $json.webUrl }}",
        "options": {}
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [
        32,
        -80
      ],
      "id": "676cc3be-c3f9-475e-b3c5-a76d7c7e4e86",
      "name": "download file"
    },
    {
      "parameters": {
        "pollTimes": {
          "item": [
            {
              "mode": "everyMinute"
            }
          ]
        },
        "watchFolder": true,
        "folderId": {
          "__rl": true,
          "value": "3C476F87258962A5!s25ab7d713fd841a0bc8dcbb3544ba1eb",
          "mode": "id"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.microsoftOneDriveTrigger",
      "typeVersion": 1,
      "position": [
        -176,
        -80
      ],
      "id": "fc0ff103-b5f4-4817-a80c-b4e021630dce",
      "name": "fetch file",
      "credentials": {
        "microsoftOneDriveOAuth2Api": {
          "id": "9xJoOw9tJetQy12S",
          "name": "Microsoft Drive account"
        }
      }
    }
  ],
  "connections": {
    "fetch file": {
      "main": [
        [
          {
            "node": "download file",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "pinData": {},
  "meta": {
    "templateCredsSetupCompleted": true,
    "instanceId": "004a8f4f776326f6308ea533268fac22ea60e1995204a49569b21eb0ebbf949b"
  }
}

Share the output returned by the last node

Information on your n8n setup

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

hey @ali_ali94872847 welcome to community!

I see you are using weburl to download file but it is not right way to download.
you need to add another node get a file.
I have attached workflow please try it and let me know.

Thanks moosa for quick response I am going to try your solution

It work thanks

If it was helpful please do mark my response as solution :slight_smile: