Enable Include file metadata on the File Question node, then consume the Question node’s file variable (ReferenceImage) instead of rereading System.Activity.Attachments after that node.
Correct the topic
- Open the Question node configured with Identify → File.
- Select More (…) → Properties.
- Under Entity recognition, enable Include file metadata.
- Keep Save user response as set to
ReferenceImage.
- In the following Set variable value node, build
ImageInput from that saved variable:
{
contentBytes: Topic.ReferenceImage.Content,
name: Topic.ReferenceImage.Name
}
- Save and publish the agent again, start a new conversation in Microsoft 365 Copilot, and upload a JPG or PNG using the attachment button.
Microsoft’s documented Question-node implementation specifically requires Include file metadata. Once the Question node has captured the file, downstream flows and connectors should use the saved topic variable’s .Content and .Name fields.^1^
Also verify Settings → Generative AI → File processing capabilities → File uploads is enabled. Microsoft Copilot is listed as a supported file-input channel, along with the Copilot Studio test panel, Teams, and web chat.^2^
If the file can arrive before the Question node
Only use System.Activity.Attachments to detect an attachment sent with the triggering message. Guard against an empty table before calling First:
If(
IsEmpty(System.Activity.Attachments),
Blank(),
{
contentBytes: First(System.Activity.Attachments).Content,
name: First(System.Activity.Attachments).Name
}
)
The supported combined pattern is:
- Check
System.Activity.Attachments.
- If an attachment exists, capture it.
- Otherwise, route to the File Question node.
- After the Question node, use
Topic.ReferenceImage, not the activity collection.^1^
This avoids the null dereference that broke the generic-input workaround.
Validate the uploaded image
Test with an image that is:
- JPG, PNG, WebP, or nonanimated GIF
- No larger than 15 MB
- Not encrypted or protected by a sensitivity label
Those are documented file-processing requirements.^2^
The attachment must be uploaded as a file through the composer. An attachment belongs to the turn on which it is sent; if processing fails, the agent can skip the attachment while continuing to process the message.^3^
If it still fails only after publishing
A Copilot Studio agent in the Microsoft Copilot channel is documented to support file input, so a reproducible difference where the test pane succeeds but the published channel returns an empty attachment is not expected behavior. The current Microsoft 365 Copilot extensibility known-issues page does not list this specific Copilot Studio attachment failure or provide a release ETA.^4^
Capture a clean reproduction and open a support request:
- Reproduce it in a new Microsoft 365 Copilot conversation with one small PNG.
- Record the UTC timestamp, environment, agent name, affected user/channel, and conversation ID.
- Include the transcript showing the attachment turn followed by escalation.
- In Power Platform admin center → Support → Support requests → Get support, create a Copilot Studio case.^5^
- State that the same published version works in Test your agent, but
System.Activity.Attachments is empty and the File Question is not satisfied in Microsoft 365 Copilot.
The escalation response itself does not establish the underlying cause; it is the route the agent selected after the attachment turn failed to satisfy the expected topic path.
References
- Pass files to agent flows, connectors, and tools - Microsoft Copilot Studio
- Allow file input from users - Microsoft Copilot Studio
- Attach files to a conversation (GitHub Copilot) - Microsoft Copilot Studio
- Known Issues in Microsoft 365 Copilot Extensibility
- Find support and give feedback for Copilot Studio