Question on Input Binary Field

Describe the problem/error/question

I am trying to upload the video which I downloaded earlier from Google Drive, but I am struggling with that, what is the correct way to do it? all my trials ends with error like:

What is the error message (if any)?

Problem in node ‘Upload a video‘
This operation expects the node’s input data to contain a binary file ‘[object Object]’, but none was found [item 0]

What I tried:

{{ $(‘Download a file’).item.binary.BinaryFile.data}}
{{ $(‘Download a file’).item.binary.BinaryFile}}
{{ $(‘Download a file’).item.binary}}

nothing of them worked.

Please share your workflow

{
  "nodes": [
    {
      "parameters": {
        "pollTimes": {
          "item": [
            {
              "mode": "everyMinute"
            }
          ]
        },
        "triggerOn": "specificFolder",
        "folderToWatch": {
          "__rl": true,
          "value": "1MZyIWJhUBSs79co63-7vNWiV8eJI-v46",
          "mode": "list",
          "cachedResultName": "N8N",
          "cachedResultUrl": "https://drive.google.com/drive/folders/1MZyIWJhUBSs79co63-7vNWiV8eJI-v46"
        },
        "event": "fileCreated",
        "options": {}
      },
      "id": "1abfba72-83a5-4ef5-9efb-d46d9dba7d0d",
      "name": "Google Drive Trigger",
      "type": "n8n-nodes-base.googleDriveTrigger",
      "position": [
        0,
        170
      ],
      "typeVersion": 1,
      "credentials": {
        "googleDriveOAuth2Api": {
          "id": "QLWXMsaCoFht5bbl",
          "name": "Google Drive account"
        }
      }
    },
    {
      "parameters": {
        "authentication": "oAuth2",
        "operation": "download",
        "fileId": {
          "__rl": true,
          "mode": "",
          "value": "={{ $json.id || $json.data[0].id }}"
        },
        "binaryPropertyName": "BinaryFile",
        "options": {}
      },
      "id": "d820ac57-38b4-415b-90c4-56a22bc73224",
      "name": "Download a file",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        220,
        170
      ],
      "retryOnFail": true,
      "typeVersion": 1,
      "waitBetweenTries": 5000,
      "credentials": {
        "googleDriveOAuth2Api": {
          "id": "QLWXMsaCoFht5bbl",
          "name": "Google Drive account"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "// Loop over input items and add a new field called 'myNewField' to the JSON of each one\n\nreturn JSON.parse($input.first().json.candidates[0].content.parts[0].text)"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        1100,
        -80
      ],
      "id": "16bb2536-5449-4b1e-a5ea-3f2e7569ed00",
      "name": "Parse Gemini Results",
      "notesInFlow": true,
      "notes": "parses for every platform"
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.upload-post.com/api/upload",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Apikey eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6Im1hc3NleWFtMTk5OEBnbWFpbC5jb20iLCJleHAiOjQ5MDYwMjk5MTcsImp0aSI6IjUyZjRmN2RmLWZlNDQtNDcyYy1iMWRiLTg0Yzc5NWI1ZTFlMyJ9.nnpnuUU3krb4wVfPejrGKaaA0QRCu1RUsQncodIecNM"
            }
          ]
        },
        "sendBody": true,
        "contentType": "multipart-form-data",
        "bodyParameters": {
          "parameters": [
            {
              "name": "title",
              "value": "={{ $('Parse Gemini Results').item.json.tiktok.caption }}\n"
            },
            {
              "name": "platform[]",
              "value": "youtube"
            },
            {
              "parameterType": "formBinaryData",
              "name": "video",
              "inputDataFieldName": "data"
            },
            {
              "name": "user",
              "value": "masseyam1998"
            }
          ]
        },
        "options": {}
      },
      "id": "6f032190-8b74-48e1-bfe7-ef7c3c2408e0",
      "name": "Upload Video and Description to Tiktok",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1760,
        -180
      ],
      "notesInFlow": true,
      "typeVersion": 4.2,
      "notes": "Generate in upload-post.com the token and add to the credentials in the header-> Authorization: Apikey (token here)"
    },
    {
      "parameters": {
        "resource": "video",
        "operation": "upload",
        "title": "Testing",
        "regionCode": "EG",
        "categoryId": "10",
        "binaryProperty": "={{ $('Download a file').item.binary.BinaryFile}}",
        "options": {
          "description": "={{ $('Parse Gemini Results').item.json.tiktok.caption }}"
        }
      },
      "type": "n8n-nodes-base.youTube",
      "typeVersion": 1,
      "position": [
        2280,
        80
      ],
      "id": "28499614-94e9-44b1-812e-513a0d1b991c",
      "name": "Upload a video",
      "credentials": {
        "youTubeOAuth2Api": {
          "id": "pmH9BeiuuPw1vCEk",
          "name": "YouTube account"
        }
      }
    },
    {
      "parameters": {
        "operation": "sendAndWait",
        "chatId": "1350863880",
        "message": "=Tiktok Generated Caption:\n{{ $('Parse Gemini Results').item.json.tiktok.caption }}\n\n",
        "approvalOptions": {
          "values": {
            "approvalType": "double"
          }
        },
        "options": {}
      },
      "type": "n8n-nodes-base.telegram",
      "typeVersion": 1.2,
      "position": [
        1320,
        -180
      ],
      "id": "8d245a4e-c288-4beb-ac3a-a7784042fdbf",
      "name": "Send a text message",
      "webhookId": "6133e5f3-73f0-425b-914b-57e72ad17a90",
      "credentials": {
        "telegramApi": {
          "id": "jRe73mMSgnzkSaS5",
          "name": "Telegram account"
        }
      }
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "3380d8a8-3941-47ae-9699-229da11e94a0",
              "leftValue": "",
              "rightValue": "",
              "operator": {
                "type": "string",
                "operation": "equals",
                "name": "filter.operator.equals"
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        1540,
        -180
      ],
      "id": "2571fb57-eec3-4a78-9484-2df21ae51464",
      "name": "If1"
    },
    {
      "parameters": {
        "resource": "video",
        "operation": "upload",
        "title": "Testing direct upload",
        "regionCode": "EG",
        "categoryId": "17",
        "options": {}
      },
      "type": "n8n-nodes-base.youTube",
      "typeVersion": 1,
      "position": [
        660,
        -180
      ],
      "id": "03ae3b4b-c78f-4fd4-adff-4bf7acb2ae43",
      "name": "Upload a video1",
      "credentials": {
        "youTubeOAuth2Api": {
          "id": "pmH9BeiuuPw1vCEk",
          "name": "YouTube account"
        }
      }
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash:generateContent",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "x-goog-api-key",
              "value": "AIzaSyBvGPwqRK-k18zEENF1k28ymzxTVTUr1BE"
            },
            {
              "name": "="
            }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={\n  \"contents\": [\n    {\n      \"parts\": [\n        {\n          \"file_data\": {\n            \"file_uri\": \"https://www.youtube.com/watch?v={{ $json.uploadId }}\"\n          }\n        },\n        {\n          \"text\": \"I will post this video on social media tiktok,instagram and facebook. please generate suitable captption for each platform along with some hashtages\"\n        }\n      ]\n    }\n  ],\n  \"generationConfig\": {\n    \"responseMimeType\": \"application/json\",\n    \"responseSchema\": {\n      \"type\": \"ARRAY\",\n      \"items\": {\n        \"type\": \"OBJECT\",\n        \"properties\": {\n          \"tiktok\": {\n            \"type\": \"OBJECT\",\n            \"properties\": {\n              \"caption\": { \"type\": \"STRING\" },\n              \"tags\": {\n                \"type\": \"ARRAY\",\n                \"items\": { \"type\": \"STRING\" }\n              }\n            },\n            \"propertyOrdering\": [\"caption\", \"tags\"]\n          },\n          \"facebook\": {\n            \"type\": \"OBJECT\",\n            \"properties\": {\n              \"caption\": { \"type\": \"STRING\" },\n              \"tags\": {\n                \"type\": \"ARRAY\",\n                \"items\": { \"type\": \"STRING\" }\n              }\n            },\n            \"propertyOrdering\": [\"caption\", \"tags\"]\n          },\n          \"instagram\": {\n            \"type\": \"OBJECT\",\n            \"properties\": {\n              \"caption\": { \"type\": \"STRING\" },\n              \"tags\": {\n                \"type\": \"ARRAY\",\n                \"items\": { \"type\": \"STRING\" }\n              }\n            },\n            \"propertyOrdering\": [\"caption\", \"tags\"]\n          }\n        },\n        \"propertyOrdering\": [\"tiktok\", \"facebook\", \"instagram\"]\n      }\n    }\n  }\n}",
        "options": {}
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [
        880,
        -180
      ],
      "id": "724aa423-e05e-4ffa-8de6-eb005ace51b4",
      "name": "Process the video and generate content1"
    },
    {
      "parameters": {
        "resource": "video",
        "operation": "delete",
        "videoId": "={{ $('Upload a video1').item.json.uploadId }}",
        "options": {}
      },
      "type": "n8n-nodes-base.youTube",
      "typeVersion": 1,
      "position": [
        1100,
        -280
      ],
      "id": "db6e27e1-1ed3-475f-90fe-0f8c88fe213f",
      "name": "Delete a video",
      "credentials": {
        "youTubeOAuth2Api": {
          "id": "pmH9BeiuuPw1vCEk",
          "name": "YouTube account"
        }
      }
    },
    {
      "parameters": {
        "operation": "sendAndWait",
        "chatId": "1350863880",
        "message": "=Tiktok Generated Caption:\n{{ $('Parse Gemini Results').item.json.tiktok.caption }}\n\n",
        "approvalOptions": {
          "values": {
            "approvalType": "double"
          }
        },
        "options": {}
      },
      "type": "n8n-nodes-base.telegram",
      "typeVersion": 1.2,
      "position": [
        1320,
        20
      ],
      "id": "88375bce-c0c5-4433-b446-7a9038d4df96",
      "name": "Send a text message1",
      "webhookId": "6133e5f3-73f0-425b-914b-57e72ad17a90",
      "credentials": {
        "telegramApi": {
          "id": "jRe73mMSgnzkSaS5",
          "name": "Telegram account"
        }
      }
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "3380d8a8-3941-47ae-9699-229da11e94a0",
              "leftValue": "={{ $json.data.approved }}",
              "rightValue": "",
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        1480,
        -40
      ],
      "id": "e84daf9a-4938-4825-9021-6b7a539f77cf",
      "name": "If2"
    }
  ],
  "connections": {
    "Google Drive Trigger": {
      "main": [
        [
          {
            "node": "Download a file",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download a file": {
      "main": [
        [
          {
            "node": "Upload a video1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Gemini Results": {
      "main": [
        [
          {
            "node": "Send a text message",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send a text message1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send a text message": {
      "main": [
        [
          {
            "node": "If1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If1": {
      "main": [
        [
          {
            "node": "Upload Video and Description to Tiktok",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload a video1": {
      "main": [
        [
          {
            "node": "Process the video and generate content1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Process the video and generate content1": {
      "main": [
        [
          {
            "node": "Delete a video",
            "type": "main",
            "index": 0
          },
          {
            "node": "Parse Gemini Results",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Delete a video": {
      "main": [
        []
      ]
    },
    "Send a text message1": {
      "main": [
        [
          {
            "node": "If2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If2": {
      "main": [
        [
          {
            "node": "Upload a video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "pinData": {
    "Google Drive Trigger": [
      {
        "parents": [
          "1MZyIWJhUBSs79co63-7vNWiV8eJI-v46"
        ],
        "lastModifyingUser": {
          "displayName": "Mohamed Abdullah",
          "kind": "drive#user",
          "me": true,
          "permissionId": "15765030077149778855",
          "emailAddress": "[email protected]",
          "photoLink": "https://lh3.googleusercontent.com/a/ACg8ocIeMYUAUeJ3W3qVYWqg3TlG91Rm0_34fsmcQAL2HmQ2rh2bVCFP=s64"
        },
        "owners": [
          {
            "displayName": "Mohamed Abdullah",
            "kind": "drive#user",
            "me": true,
            "permissionId": "15765030077149778855",
            "emailAddress": "[email protected]",
            "photoLink": "https://lh3.googleusercontent.com/a/ACg8ocIeMYUAUeJ3W3qVYWqg3TlG91Rm0_34fsmcQAL2HmQ2rh2bVCFP=s64"
          }
        ],
        "permissions": [
          {
            "kind": "drive#permission",
            "id": "15765030077149778855",
            "type": "user",
            "emailAddress": "[email protected]",
            "role": "owner",
            "displayName": "Mohamed Abdullah",
            "photoLink": "https://lh3.googleusercontent.com/a/ACg8ocIeMYUAUeJ3W3qVYWqg3TlG91Rm0_34fsmcQAL2HmQ2rh2bVCFP=s64",
            "deleted": false,
            "pendingOwner": false
          }
        ],
        "spaces": [
          "drive"
        ],
        "capabilities": {
          "canAcceptOwnership": false,
          "canAddChildren": false,
          "canAddMyDriveParent": false,
          "canChangeCopyRequiresWriterPermission": true,
          "canChangeItemDownloadRestriction": true,
          "canChangeSecurityUpdateEnabled": false,
          "canChangeViewersCanCopyContent": true,
          "canComment": true,
          "canCopy": true,
          "canDelete": true,
          "canDisableInheritedPermissions": false,
          "canDownload": true,
          "canEdit": true,
          "canEnableInheritedPermissions": true,
          "canListChildren": false,
          "canModifyContent": true,
          "canModifyContentRestriction": true,
          "canModifyEditorContentRestriction": true,
          "canModifyOwnerContentRestriction": true,
          "canModifyLabels": false,
          "canMoveChildrenWithinDrive": false,
          "canMoveItemIntoTeamDrive": true,
          "canMoveItemOutOfDrive": true,
          "canMoveItemWithinDrive": true,
          "canReadLabels": false,
          "canReadRevisions": true,
          "canRemoveChildren": false,
          "canRemoveContentRestriction": false,
          "canRemoveMyDriveParent": true,
          "canRename": true,
          "canShare": true,
          "canTrash": true,
          "canUntrash": true
        },
        "permissionIds": [
          "15765030077149778855"
        ],
        "videoMediaMetadata": {
          "width": 1280,
          "height": 686,
          "durationMillis": "192879"
        },
        "linkShareMetadata": {
          "securityUpdateEligible": false,
          "securityUpdateEnabled": true
        },
        "downloadRestrictions": {
          "itemDownloadRestriction": {
            "restrictedForReaders": false,
            "restrictedForWriters": false
          },
          "effectiveDownloadRestrictionWithContext": {
            "restrictedForReaders": false,
            "restrictedForWriters": false
          }
        },
        "kind": "drive#file",
        "id": "16_kNAfGq3f0D1Pe8_BzdbKDaFpMnCCPP",
        "name": "44- Solid Principles | Implement Interface Segregation Principle  | How we implement ISP for animal.mp4",
        "mimeType": "video/mp4",
        "starred": false,
        "trashed": false,
        "explicitlyTrashed": false,
        "version": "8",
        "webContentLink": "https://drive.google.com/uc?id=16_kNAfGq3f0D1Pe8_BzdbKDaFpMnCCPP&export=download",
        "webViewLink": "https://drive.google.com/file/d/16_kNAfGq3f0D1Pe8_BzdbKDaFpMnCCPP/view?usp=drivesdk",
        "iconLink": "https://drive-thirdparty.googleusercontent.com/16/type/video/mp4",
        "hasThumbnail": true,
        "thumbnailLink": "https://lh3.googleusercontent.com/drive-storage/AJQWtBMAojdD89fphJKiBeDw20Qqo5G3VtPzNurNXnPVV2NX1iPTcQkY_T8eDKGgP7npViXyvJ__skliLkVTS1NISHUd4AMmMSwjUDD3p7VrWNXGJz4=s220",
        "thumbnailVersion": "1",
        "viewedByMe": true,
        "viewedByMeTime": "2025-07-13T17:14:16.292Z",
        "createdTime": "2025-07-13T17:14:16.292Z",
        "modifiedTime": "2023-03-27T20:15:01.000Z",
        "modifiedByMeTime": "2023-03-27T20:15:01.000Z",
        "modifiedByMe": true,
        "shared": false,
        "ownedByMe": true,
        "viewersCanCopyContent": true,
        "copyRequiresWriterPermission": false,
        "writersCanShare": true,
        "originalFilename": "44- Solid Principles | Implement Interface Segregation Principle  | How we implement ISP for animal.mp4",
        "fullFileExtension": "mp4",
        "fileExtension": "mp4",
        "md5Checksum": "81cb8f1804efd8571c53f288c45c0bc0",
        "sha1Checksum": "ace9e34c208d9888dd5cb3077ad517cf44aed575",
        "sha256Checksum": "379280d2837d5d559b6f9f4481ca1c38253288774baafb2d6bc12435f479a503",
        "size": "5602116",
        "quotaBytesUsed": "5602116",
        "headRevisionId": "0B0aPraeJjI0idGFSazRKbm9Ba2grM1NjdWFtWnR6ekxHNFRBPQ",
        "isAppAuthorized": false,
        "inheritedPermissionsDisabled": false
      }
    ],
    "Parse Gemini Results": [
      {
        "tiktok": {
          "caption": "Master the Interface Segregation Principle! 👨‍💻 Learn how to apply this key concept in software design with a clear and simple example. #coding #softwareengineering #interfacesegregation #solidprinciples #typescript",
          "tags": [
            "#coding",
            "#softwareengineering",
            "#interfacesegregation",
            "#solidprinciples",
            "#typescript"
          ]
        },
        "facebook": {
          "caption": "Unlock the power of the Interface Segregation Principle! This video breaks down how to implement ISP in your software designs. Learn the key to creating flexible, maintainable code. #softwaredesign #codingtips #interfaces #programming #goodcode",
          "tags": [
            "#softwaredesign",
            "#codingtips",
            "#interfaces",
            "#programming",
            "#goodcode"
          ]
        },
        "instagram": {
          "caption": "Level up your coding skills! 🚀 Discover the Interface Segregation Principle and build better software. #codinglife #softwaredeveloper #programmingconcepts #interfacesegregationprinciple #cleancode",
          "tags": [
            "#codinglife",
            "#softwaredeveloper",
            "#programmingconcepts",
            "#interfacesegregationprinciple",
            "#cleancode"
          ]
        }
      }
    ],
    "Upload a video1": [
      {
        "uploadId": "_zoZkqXe4Uc"
      }
    ],
    "Process the video and generate content1": [
      {
        "candidates": [
          {
            "content": {
              "parts": [
                {
                  "text": "[\n  {\n    \"tiktok\": {\n      \"caption\": \"Interface Segregation Principle explained with simple example\",\n      \"tags\": [\n        \"#isp\",\n        \"#solid\",\n        \"#principle\"\n      ]\n    },\n    \"facebook\": {\n      \"caption\": \"Interface Segregation Principle explained with simple example\",\n      \"tags\": [\n        \"#isp\",\n        \"#solid\",\n        \"#principle\"\n      ]\n    },\n    \"instagram\": {\n      \"caption\": \"Interface Segregation Principle explained with simple example\",\n      \"tags\": [\n        \"#isp\",\n        \"#solid\",\n        \"#principle\"\n      ]\n    }\n  }\n]"
                }
              ],
              "role": "model"
            },
            "finishReason": "STOP",
            "avgLogprobs": -0.14486335305606618
          }
        ],
        "usageMetadata": {
          "promptTokenCount": 56315,
          "candidatesTokenCount": 153,
          "totalTokenCount": 56468,
          "promptTokensDetails": [
            {
              "modality": "TEXT",
              "tokenCount": 59
            },
            {
              "modality": "AUDIO",
              "tokenCount": 5760
            },
            {
              "modality": "VIDEO",
              "tokenCount": 50496
            }
          ],
          "candidatesTokensDetails": [
            {
              "modality": "TEXT",
              "tokenCount": 153
            }
          ]
        },
        "modelVersion": "gemini-2.0-flash",
        "responseId": "vCl0aM_WHqGThMIPgeLqmQU"
      }
    ],
    "Send a text message1": [
      {
        "data": {
          "approved": true
        }
      }
    ]
  },
  "meta": {
    "templateCredsSetupCompleted": true,
    "instanceId": "7de3c4d412e7b907d57466e5b89eba34047904247ae1b2abcd31142c1752015a"
  }
}```

## Share the output returned by the last node

## Information on your n8n setup
- **n8n version:** 1.102.2
- **Database (default: SQLite):** Postgres
- **n8n EXECUTIONS_PROCESS setting (default: own, main):** default
- **Running n8n via (Docker, npm, n8n cloud, desktop app):** Docker
- **Operating system:** Linux

Hey @Mohamed_Abdullah hope all is well.

When a binary is expected, what you usually need to type into that field is the binary output name of the previous node. From what I see, in your previous node you tagged the binary with BinaryFile, so this is what you also need to type into the Input Binary Field in the next node (Upload a video1)

Download a file

Upload a video:

Please try that and see if that helps.

1 Like

hey @Mohamed_Abdullah
try this one:

unpin data and give it a try.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.