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 / Copilot Studio / Copilot Studio Agent F...
Copilot Studio
Suggested Answer

Copilot Studio Agent Flow Tool Does Not Accept File Input and Requests Record Type Instead

(1) ShareShare
ReportReport
Posted on by 2

I have created an agent in Microsoft Copilot Studio and built an agent flow that is designed to take a file input from the user.

 

When I test the flow directly, the file input works as expected and I am able to upload and process the file successfully.

 

However, after adding the same flow as a tool to the agent and testing it through the agent conversation, the behavior changes:

 

  • When the flow is triggered by the agent, it no longer accepts file input

  • Instead, it prompts for a record type input


  •  
 

Because of this:

 

  • The user is unable to upload a file during agent execution

  • The flow fails unless a record reference is manually provided


  •  
 

This inconsistency between flow testing and agent tool execution is causing confusion, as the flow works correctly in isolation but not when invoked by the agent.

 

Expected behavior:

The agent should be able to accept a user file input or provide a supported way to pass the uploaded file to the flow during execution.

 

Actual behavior:

When invoked as an agent tool, the flow requires a record-type input instead of a file and does not allow file upload.

 

Please advise whether this is:

 

  • Expected behavior by design for Copilot Studio agents, or

  • A supported configuration is missing to allow file input when a flow is used as an agent tool
f.png
Categories:
I have the same question (0)
  • frago Profile Picture
    226 on at

    Copilot Studio tools cannot accept file uploads.When a flow is used as a tool, it expects a Record, not a File. So the flow fails because no file record is passed.This is e

    Fastest fix

    Collect the file in the agent topic
    Question node → Identify: File
    Enable Include file metadata
    Save to variable (e.g. userFile)
    Change flow input
    Input type: Record (not File)
    Pass the file to the tool (Power Fx)

    {
      name: Topic.userFile.Name,
      contentBytes: Topic.userFile.Content
    }
     
  • Suggested answer
    deepakmehta13a Profile Picture
    369 on at

    Hi,

    This behavior is expected by design when using Power Automate flows as tools in Copilot Studio agents, and it often causes confusion because the same flow behaves differently when tested independently versus when invoked from an agent.

    When you test the flow directly in Power Automate, the trigger supports file-type inputs (such as file upload controls). However, once the flow is added as a tool in Copilot Studio, the platform converts the flow inputs into a structured schema (record/object-based input). Because of this transformation, file upload inputs are not supported in the same way, and the agent cannot directly prompt the user to upload a file during tool execution.

    This is why:


    • The flow input appears as a record instead of a file

    • The agent cannot accept file uploads

    • The flow fails unless a structured input is passed

    •  

    To resolve this, the flow needs to be slightly redesigned to align with how Copilot Studio handles inputs:


    • Instead of using a file input type, define inputs such as:

      • fileName (string)

      • contentBytes (string/base64 

    • In the agent, ensure that:

      • The file is either captured and converted into contentBytes, or

      • The file is first stored (e.g., SharePoint/Dataverse) and only a file reference (URL or ID) is passed to the flo 

    • Inside the flow:

      • Use the passed contentBytes or file reference to reconstruct or process the fil  

    •  

    This pattern is currently the recommended and supported approach when working with files in Copilot Studio tool scenarios.


    ---------------------------------------------------------------------------------------------------------------------------------------------

    If this helps resolve your issue, please consider marking the response as Verified so it can help others facing a similar scenario

    If you found this helpful, you can also click “Yes” on “Was this reply helpful?” or give it a Like.

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Copilot Studio

#1
Valantis Profile Picture

Valantis 277

#2
11manish Profile Picture

11manish 206

#3
sannavajjala87 Profile Picture

sannavajjala87 156 Super User 2026 Season 1

Last 30 days Overall leaderboard