TransferNowを使って自動のに大容量ファイルを送信

上級

これはContent Creation, Multimodal AI分野の自動化ワークフローで、19個のノードを含みます。主にIf, Set, Code, Form, Mergeなどのノードを使用。 大ファイルをTransferNowで自動アップロードして送信

前提条件
  • ターゲットAPIの認証情報が必要な場合あり
ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
  "id": "IaP1PFerysorkzbn",
  "meta": {
    "instanceId": "a4bfc93e975ca233ac45ed7c9227d84cf5a2329310525917adaf3312e10d5462"
  },
  "name": "Automated Send a Large File with TransferNow",
  "tags": [],
  "nodes": [
    {
      "id": "ae8b10cf-20ea-4975-beba-736b780d7103",
      "name": "付箋",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1488,
        160
      ],
      "parameters": {
        "color": 5,
        "width": 1104,
        "height": 176,
        "content": "## STEP 1\nCreate a FREE account on [TransferNow](https://developers.transfernow.net/). FREE TRIAL 14 DAYS\n\nSet Header Auth in 'HTTP Nodes':\n- NAME: x-api-key\n- VALUE: YOUR_API_KEY"
      },
      "typeVersion": 1
    },
    {
      "id": "d05475bf-b614-4838-a31f-5f42a6c725b2",
      "name": "フォーム送信時",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        1520,
        720
      ],
      "webhookId": "0e6f7af4-c78c-4ce0-a295-df94427ebc16",
      "parameters": {
        "options": {},
        "formTitle": "Upload Form",
        "formFields": {
          "values": [
            {
              "fieldLabel": "Title",
              "requiredField": true
            },
            {
              "fieldType": "textarea",
              "fieldLabel": "Message",
              "requiredField": true
            },
            {
              "fieldType": "email",
              "fieldLabel": "To",
              "requiredField": true
            },
            {
              "fieldType": "file",
              "fieldLabel": "data",
              "multipleFiles": false,
              "requiredField": true
            }
          ]
        },
        "formDescription": "Upload PDF files to send via TransferNow"
      },
      "typeVersion": 2.3
    },
    {
      "id": "d714bb39-527b-4c24-83c1-e715a984899a",
      "name": "サイズ計算",
      "type": "n8n-nodes-base.code",
      "position": [
        1952,
        544
      ],
      "parameters": {
        "jsCode": "const buffer = await this.helpers.getBinaryDataBuffer(0, 'data');\nconst name = $input.first().binary.data.fileName;\n\nreturn [\n  {\n    json: {\n      name: name,\n      size: buffer.length\n    },\n  },\n];"
      },
      "typeVersion": 2
    },
    {
      "id": "8d391955-47e7-4299-be6a-58e8d1f2bf21",
      "name": "Jsonを設定",
      "type": "n8n-nodes-base.set",
      "position": [
        2384,
        544
      ],
      "parameters": {
        "mode": "raw",
        "options": {},
        "jsonOutput": "={\n  \"name\": \"{{ $json.name }}\",\n  \"size\": {{ $json.size }}\n}\n"
      },
      "typeVersion": 3.4
    },
    {
      "id": "d4bc1a9d-bffd-4b3b-889f-e605fd258e8d",
      "name": "Transferを設定",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        2832,
        544
      ],
      "parameters": {
        "url": "https://api.transfernow.net/v1/transfers",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n        \"langCode\": \"it\",\n        \"toEmails\": [\"{{ $('On form submission').item.json.To }}\"],\n        \"files\": [{{ (JSON.stringify($json)) }}],\n        \"message\": \"{{ $('On form submission').item.json.Message }}\",\n        \"subject\": \"{{ $('On form submission').item.json.Title }}\",\n        \"validityStart\": \"{{ $now }}\",\n        \"validityEnd\": \"{{ $now.plus({week:1}) }}\",\n        \"allowPreview\": true,\n        \"maxDownloads\": 7\n      }\n\n",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "Ds6c0Jvwog49aQNO",
          "name": "Header Auth TransferNow"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "9e60b05f-3fa6-4e10-85ed-bb8e3a4c62bf",
      "name": "アップロードURLを取得",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        3312,
        544
      ],
      "parameters": {
        "url": "=https://api.transfernow.net/v1/transfers/{{ $json.transferId }}/files/{{ $json.files[0].id }}/parts/{{ $json.files[0].multipartUpload.parts[0].partNumber }}?uploadId={{ $json.files[0].multipartUpload.uploadId }}",
        "options": {},
        "sendHeaders": true,
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "Ds6c0Jvwog49aQNO",
          "name": "Header Auth TransferNow"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "647c1e4d-4c33-43d0-aaea-c51daac874a6",
      "name": "アップロード完了",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        3312,
        752
      ],
      "parameters": {
        "url": "=https://api.transfernow.net/v1/transfers/{{ $('Set Transfer').item.json.transferId }}/upload-done",
        "method": "PUT",
        "options": {},
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth"
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "Ds6c0Jvwog49aQNO",
          "name": "Header Auth TransferNow"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "2397b257-bfa1-45c0-b80a-c31548019e54",
      "name": "転送データを取得",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        3312,
        960
      ],
      "parameters": {
        "url": "=https://api.transfernow.net/v1/transfers/{{ $('Set Transfer').item.json.transferId }}",
        "options": {},
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth"
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "Ds6c0Jvwog49aQNO",
          "name": "Header Auth TransferNow"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "6688b620-0365-401f-bb85-5a6a8e4b78b5",
      "name": "パラメータを取得",
      "type": "n8n-nodes-base.set",
      "position": [
        3584,
        960
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "625867c4-2859-4b6f-93aa-89148c685328",
              "name": "url_transfer",
              "type": "string",
              "value": "=https://{{ $json.domain }}/dl/{{ $json.id }}/{{ $json.recipients[0].secret }}"
            },
            {
              "id": "f25130a0-d32b-4f0b-b2f0-11f4af955162",
              "name": "email",
              "type": "string",
              "value": "={{ $json.recipients[0].email }}"
            },
            {
              "id": "39ab045d-41cb-475c-940a-12c99e9ca773",
              "name": "name_transfer",
              "type": "string",
              "value": "={{ $json.name }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "c6ff7fd0-0376-4819-9bcb-cfac83d64a3b",
      "name": "フォーム",
      "type": "n8n-nodes-base.form",
      "position": [
        3808,
        960
      ],
      "webhookId": "1e0bfba1-6859-4767-a65e-600c831d7031",
      "parameters": {
        "options": {},
        "operation": "completion",
        "completionTitle": "Upload complete",
        "completionMessage": "=The files have been sent to the following email address: {{ $json.email }}\nDownload URL: {{ $json.url_transfer }}"
      },
      "typeVersion": 2.3
    },
    {
      "id": "533f9bed-2476-489e-8256-c12ad722d133",
      "name": "完了済み?",
      "type": "n8n-nodes-base.if",
      "position": [
        2848,
        880
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "78609385-4035-4bd1-8e06-36feb4115100",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.message }}",
              "rightValue": "OK"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "0824bec9-fdbd-4fd3-b3e5-5f0cce4aa488",
      "name": "転送を送信",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        2576,
        880
      ],
      "parameters": {
        "url": "=https://api.transfernow.net/v1/transfers/{{ $('Set Transfer').item.json.transferId }}/files/{{ $('Set Transfer').item.json.files[0].id }}/upload-done?uploadId={{ $('Set Transfer').item.json.files[0].multipartUpload.uploadId }}",
        "method": "PUT",
        "options": {},
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth"
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "Ds6c0Jvwog49aQNO",
          "name": "Header Auth TransferNow"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "59f81389-6f5a-4664-97fd-bb9b5131066c",
      "name": "アップロードURLを送信",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        2272,
        880
      ],
      "parameters": {
        "url": "={{ $json.uploadUrl }}",
        "method": "PUT",
        "options": {
          "response": {
            "response": {
              "fullResponse": true
            }
          }
        },
        "sendBody": true,
        "contentType": "binaryData",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/octet-stream"
            }
          ]
        },
        "inputDataFieldName": "data"
      },
      "typeVersion": 4.2
    },
    {
      "id": "6b7de5f4-b215-4b2a-9e1b-95750a72b0cc",
      "name": "結合",
      "type": "n8n-nodes-base.merge",
      "position": [
        1968,
        880
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combineBy": "combineByPosition"
      },
      "typeVersion": 3.1
    },
    {
      "id": "3eeea705-5ce5-459d-b15f-8b60f9169a94",
      "name": "付箋1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1488,
        -32
      ],
      "parameters": {
        "color": 3,
        "width": 1104,
        "height": 144,
        "content": "#  Automated Send a Large File with TransferNow\nThis workflow creates a user-friendly web form to upload a file, which allows users to upload a **single large file** (*up to 5Gb*) through a custom web form and automatically send it via **TransferNow**, handling the complex multi-part upload process required for **large files**."
      },
      "typeVersion": 1
    },
    {
      "id": "2b546114-5765-4596-98cd-728a554f97f0",
      "name": "付箋2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1920,
        448
      ],
      "parameters": {
        "width": 704,
        "height": 240,
        "content": "## Size\nCalculate the exact size of the file and put it into an array that will be sent to Transfernow"
      },
      "typeVersion": 1
    },
    {
      "id": "ba8993da-18f0-4713-9fe0-399051e84246",
      "name": "付箋3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2768,
        448
      ],
      "parameters": {
        "width": 704,
        "height": 240,
        "content": "## Upload\nUpload the file to the TransferNow server and create the transfer"
      },
      "typeVersion": 1
    },
    {
      "id": "5fb3a536-4893-4eaf-abbd-b7ef3758a31f",
      "name": "付箋4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2224,
        800
      ],
      "parameters": {
        "width": 544,
        "height": 240,
        "content": "## Transfer\nCreate file transfer"
      },
      "typeVersion": 1
    },
    {
      "id": "bc3a2893-112f-4dde-ade7-7f82252585e8",
      "name": "付箋5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        3280,
        880
      ],
      "parameters": {
        "width": 448,
        "height": 240,
        "content": "## Download\nProvides the URL for downloading the file"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "45265b23-20ea-4e48-aea0-575853184536",
  "connections": {
    "6b7de5f4-b215-4b2a-9e1b-95750a72b0cc": {
      "main": [
        [
          {
            "node": "59f81389-6f5a-4664-97fd-bb9b5131066c",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8d391955-47e7-4299-be6a-58e8d1f2bf21": {
      "main": [
        [
          {
            "node": "d4bc1a9d-bffd-4b3b-889f-e605fd258e8d",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "533f9bed-2476-489e-8256-c12ad722d133": {
      "main": [
        [
          {
            "node": "647c1e4d-4c33-43d0-aaea-c51daac874a6",
            "type": "main",
            "index": 0
          },
          {
            "node": "2397b257-bfa1-45c0-b80a-c31548019e54",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "d4bc1a9d-bffd-4b3b-889f-e605fd258e8d": {
      "main": [
        [
          {
            "node": "9e60b05f-3fa6-4e10-85ed-bb8e3a4c62bf",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "0824bec9-fdbd-4fd3-b3e5-5f0cce4aa488": {
      "main": [
        [
          {
            "node": "533f9bed-2476-489e-8256-c12ad722d133",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "d714bb39-527b-4c24-83c1-e715a984899a": {
      "main": [
        [
          {
            "node": "8d391955-47e7-4299-be6a-58e8d1f2bf21",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9e60b05f-3fa6-4e10-85ed-bb8e3a4c62bf": {
      "main": [
        [
          {
            "node": "6b7de5f4-b215-4b2a-9e1b-95750a72b0cc",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6688b620-0365-401f-bb85-5a6a8e4b78b5": {
      "main": [
        [
          {
            "node": "c6ff7fd0-0376-4819-9bcb-cfac83d64a3b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "59f81389-6f5a-4664-97fd-bb9b5131066c": {
      "main": [
        [
          {
            "node": "0824bec9-fdbd-4fd3-b3e5-5f0cce4aa488",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2397b257-bfa1-45c0-b80a-c31548019e54": {
      "main": [
        [
          {
            "node": "6688b620-0365-401f-bb85-5a6a8e4b78b5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "d05475bf-b614-4838-a31f-5f42a6c725b2": {
      "main": [
        [
          {
            "node": "6b7de5f4-b215-4b2a-9e1b-95750a72b0cc",
            "type": "main",
            "index": 1
          },
          {
            "node": "d714bb39-527b-4c24-83c1-e715a984899a",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
よくある質問

このワークフローの使い方は?

上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。

このワークフローはどんな場面に適していますか?

上級 - コンテンツ作成, マルチモーダルAI

有料ですか?

このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。

ワークフロー情報
難易度
上級
ノード数19
カテゴリー2
ノードタイプ8
難易度説明

上級者向け、16ノード以上の複雑なワークフロー

作成者

Full-stack Web Developer based in Italy specialising in Marketing & AI-powered automations. For business enquiries, send me an email at info@n3w.it or add me on Linkedin.com/in/davideboizza

外部リンク
n8n.ioで表示

このワークフローを共有

カテゴリー

カテゴリー: 34