web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / HTTP reguest POST. Att...
Power Automate
Unanswered

HTTP reguest POST. Attachment not working

(1) ShareShare
ReportReport
Posted on by

I have built a Power Automate flow that retrieves attachments from a SharePoint List and creates an email draft in Outlook via an HTTP request. However, I'm encountering an issue with the Append to array variable function.


Flow Structure:

  1. Initialize Variable:

    • I have an AttachmentsArray variable initialized as an array.
  2. Append to Array Variable:

    • I believe the JSON code for the Append to array variable function should look like this:
       
      json
      {
      "type": "AppendToArrayVariable",
      "description": "",
      "inputs": {
      "name": "AttachmentsArray",
      "value": {
      "@odata.type": "#Microsoft.OutlookServices.FileAttachment",
      "Name": "@items('For_each_2')?['DisplayName']",
      "ContentBytes": "@{outputs('Get_attachment_content')?['body']}"
      }
      },
      "runAfter": {
      "Get_attachment_content": [
      "Succeeded"
      ]
      },
      "metadata": {
      "operationMetadataId": "e3c2e5e3-663e-4598-8c4e-6fd21cc872aa"
      }
      }

The Issue:

  • Power Automate does not allow the @ symbol in the @odata.type property.
  • As a result, I cannot save my flow when attempting to use the Append to array variable function with this JSON structure.

Working Alternative:

If I use the Send an email (V2) function instead of an HTTP request, everything works without requiring the @odata.type property. However, I want to proceed with the HTTP request approach, which requires the @odata.type property for properly attaching files.


Key Question:

  • Is there a way to configure the @odata.type property or an alternative approach to include attachments in the HTTP request without encountering this issue?
 
Categories:
I have the same question (0)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 250 Super User 2026 Season 1

#2
Expiscornovus Profile Picture

Expiscornovus 222 Most Valuable Professional

#3
Haque Profile Picture

Haque 174

Last 30 days Overall leaderboard