No binary data exists on item!

I’m setting up a invoice check service that filters out emails from my inbox and send them to my accounting software if it contains an email. Filtering works and now I want to attach the attachments to a new email that will be send via Outlook, but I’m getting an error: No binary data exists on item!

It happens on this step:

Here is the flow:

I’m running on version 1.89.2 on my own Ubuntu server.

Using Merge with append gives you multiple items, some from each input. So only some of the items that would output from the merge, the ones from input 2, would have a binary item.

You might want to use the combine option on the merge instead.

Tried the combine, but then I don’t have a binary anymore form the previous nodes

try to use combine by postion

The inputs to the merge need to be correlated in some way.

  • By position probably doesn’t work because you probably have a different number of items coming in from each input.
  • Matching Fields is a challenge because the 2nd input is only a binary and there’s no way (at least afaik) to reference the attributes of a binary by name (only by expression with something like $binary.data.fileName)

There is a way to do it, but it’s a little awkward. The extra step you are probably missing is to use another merge node, by position, to create an item that has both JSON and binary parts.

I have isolated it here so you can adapt your workflow to do the same things.

Hi @hubschrauber when I look at the data of the get message and attachment from Outlook I get this json back:

[
  {
    "@odata.etag": "W/\"CQAAABYAAADb4zqmFU5OS4XSbkhgbyNSAABorxCW\"",
    "id": "AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQBGAAAAAADYz-n5fPp-RL-WOCqPdOgiBwDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAADb4zqmFU5OS4XSbkhgbyNSAABoy3-5AAA=",
    "createdDateTime": "2025-05-04T02:41:44Z",
    "lastModifiedDateTime": "2025-05-13T18:47:21Z",
    "changeKey": "CQAAABYAAADb4zqmFU5OS4XSbkhgbyNSAABorxCW",
    "categories": [],
    "receivedDateTime": "2025-05-04T02:41:46Z",
    "sentDateTime": "2025-05-04T02:41:36Z",
    "hasAttachments": true,
    "internetMessageId": "<[email protected]>",
    "subject": "View your Microsoft 365 Business Standard invoice",
    "bodyPreview": "Sign in to the Microsoft 365 admin center to view your invoice.\r\n\r\nSign in to view your Microsoft 365 Business Standard invoice\r\n\r\nYour Microsoft 365 Business Standard invoice is now available in the Microsoft 365 admin center. Sign in to view it.\r\n\r\nView",
    "importance": "normal",
    "parentFolderId": "AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQAuAAAAAADYz-n5fPp-RL-WOCqPdOgiAQDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAAA=",
    "conversationId": "AAQkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQAQADZDJE_fNxBMmTtfi41VVVM=",
    "conversationIndex": "AQHbvJ4SNkMkT583EEyZO1+LjVVVUw==",
    "isDeliveryReceiptRequested": null,
    "isReadReceiptRequested": false,
    "isRead": true,
    "isDraft": false,
    "webLink": "https://outlook.office365.com/owa/?ItemID=AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQBGAAAAAADYz%2Fn5fPp%2FRL%2FWOCqPdOgiBwDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAADb4zqmFU5OS4XSbkhgbyNSAABoy3%2F5AAA%3D&exvsurl=1&viewmodel=ReadMessageItem",
    "inferenceClassification": "focused",
    "body": {
      "contentType": "html",
      "content": "-"
    },
    "sender": {
      "emailAddress": {
        "name": "Microsoft",
        "address": "[email protected]"
      }
    },
    "from": {
      "emailAddress": {
        "name": "Microsoft",
        "address": "[email protected]"
      }
    },
    "toRecipients": [
      {
        "emailAddress": {
          "name": "Pieter Baecke",
          "address": "[email protected]"
        }
      }
    ],
    "ccRecipients": [],
    "bccRecipients": [],
    "replyTo": [],
    "flag": {
      "flagStatus": "notFlagged"
    }
  },
  {
    "@odata.etag": "W/\"CQAAABYAAADb4zqmFU5OS4XSbkhgbyNSAAAxObPV\"",
    "id": "AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQBGAAAAAADYz-n5fPp-RL-WOCqPdOgiBwDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAADb4zqmFU5OS4XSbkhgbyNSAAAxOOhVAAA=",
    "createdDateTime": "2025-02-15T21:03:18Z",
    "lastModifiedDateTime": "2025-02-16T07:29:45Z",
    "changeKey": "CQAAABYAAADb4zqmFU5OS4XSbkhgbyNSAAAxObPV",
    "categories": [],
    "receivedDateTime": "2025-02-15T21:03:24Z",
    "sentDateTime": "2025-02-15T21:03:13Z",
    "hasAttachments": false,
    "internetMessageId": "<[email protected]>",
    "subject": "removed",
    "importance": "normal",
    "parentFolderId": "AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQAuAAAAAADYz-n5fPp-RL-WOCqPdOgiAQDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAAA=",
    "conversationId": "AAQkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQAQAKfvrkYiGfJAsgjc-TioRfo=",
    "conversationIndex": "AQHbf+0Jp++uRiIZ8kCyCNz9OKhF+g==",
    "isDeliveryReceiptRequested": null,
    "isReadReceiptRequested": false,
    "isRead": true,
    "isDraft": false,
    "webLink": "https://outlook.office365.com/owa/?ItemID=AAMkAGI4YmZkZTlhLWUwM2ItNDI4ZC05YmRhLTVmZDhmMWFkM2NhOQBGAAAAAADYz%2Fn5fPp%2FRL%2FWOCqPdOgiBwDb4zqmFU5OS4XSbkhgbyNSAAAAAAEMAADb4zqmFU5OS4XSbkhgbyNSAAAxOOhVAAA%3D&exvsurl=1&viewmodel=ReadMessageItem",
    "inferenceClassification": "other",
    "body": {
      "contentType": "html",
      "content": "Removed"
    },
    "sender": {
      "emailAddress": {
        "name": "Cloudbeds Integrations",
        "address": "[email protected]"
      }
    },
    "from": {
      "emailAddress": {
        "name": "Cloudbeds Integrations",
        "address": "[email protected]"
      }
    },
    "toRecipients": [
      {
        "emailAddress": {
          "name": "Pieter Baecke",
          "address": "[email protected]"
        }
      }
    ],
    "ccRecipients": [],
    "bccRecipients": [],
    "replyTo": [
      {
        "emailAddress": {
          "name": "Cloudbeds Integrations",
          "address": "[email protected]"
        }
      }
    ],
    "flag": {
      "flagStatus": "notFlagged"
    }
  }
]

The binary is there as well:

But the strange thing is that I don’t see the filename in the json so how would I replicate your solution?