Building and customizing solutions using Microsoft 365 Copilot APIs and tools
Do not design the Agent Builder workflow around guaranteed cross-turn file persistence: the public Agent Builder documentation does not explicitly state that its agents inherit the Microsoft Copilot harness’s 28-day retention, file-size, or runtime limits.
For a reliable multi-pass review, download or save each generated workbook to persistent storage after every pass and attach it again when requesting the next update. Cross-turn reuse might work in the current experience, but the supplied documentation does not establish it as an Agent Builder contract.
What is documented
1. Runtime used by Agent Builder
Agent Builder creates declarative agents for Microsoft 365.^1^ Declarative agents run on Microsoft 365 Copilot’s managed orchestration and language-model infrastructure; they do not supply or host their own runtime.^2^
That documentation does not explicitly identify an Agent Builder agent as a Copilot Studio agent powered by the separately documented Microsoft Copilot harness. Consequently, the safest terminology is:
- Authoring product: Agent Builder in the Microsoft 365 Copilot app.
- Agent type: Declarative agent.
- Runtime: Microsoft 365 Copilot managed orchestration.
- Not established by these documents: that every limit documented for Copilot Studio’s Microsoft Copilot harness automatically applies to Agent Builder.
2. Workbook created in turn 1
Code interpreter is supported in Agent Builder and can accept files for analysis or modification and produce downloadable files.^3^
For agents covered by the Microsoft Copilot created-files documentation, the behavior you want is explicitly supported:
- The user can refer to a created file in a later turn.
- The agent can read it back and produce an updated version.
- Maximum created-file size is 10 MB.
- Retention is 28 days after the conversation’s last activity.^4^
However, that article is preview documentation for the Microsoft Copilot harness and does not explicitly name Agent Builder as an applicable authoring surface. Therefore, it is insufficient to treat those values as a guaranteed Agent Builder service contract.
The fresh-VM statement does not itself prevent conversation-level file carryover. It means the code-interpreter VM is destroyed and its local disk is not retained; a host could still store a surfaced file with the conversation and inject it into a later fresh VM. Microsoft explicitly documents the fresh-VM model for code interpreter in Agent Builder.^5^
3. User attachment from turn 1
For Microsoft Copilot harness agents, attachments are retained with the conversation and can be referenced later. The documented limits are:
- 16 MiB per attached file
- 28 days after the conversation’s last activity
- The later prompt should identify the earlier attachment—for example, “compare this with the file I sent earlier.”^6^
“Per-turn input” means the attachment initially influences the turn in which it is sent; it does not mean the stored attachment is necessarily deleted after that turn. The same article expressly says it can be referenced again later.
Again, the unresolved point is applicability to an Agent Builder-created declarative agent. No supplied Agent Builder page publishes an equivalent retention contract.
Also distinguish chat attachments from files embedded while authoring the agent as knowledge. Agent Builder’s later 512 MB increase concerns files uploaded as grounding data when creating an agent, not generated files or files attached to a user’s chat turn.^7^
Runtime and tool-call limits
Microsoft publishes the following defaults for agents powered by the Microsoft Copilot harness:
| Limit | Published default |
|---|---|
| Turn duration | 90 minutes |
| Steering to finish | About 60 minutes |
| Tool calls per turn | 200 |
| Ordinary tool-call timeout | 120 seconds |
| Messages retained in the working window | 100 |
Microsoft manages these defaults and can change them.^8^
The available Agent Builder documentation does not separately publish a per-turn duration or tool-call count, nor does it explicitly say that the table above governs Agent Builder declarative agents. Code interpreter is documented only as having resource quotas for time, CPU, memory, and disk; that security article does not provide their numeric values.^5^
Practical design for the multi-pass review
- In pass 1, have the agent create the workbook and return its file card.
- Download the workbook immediately or save it to SharePoint/OneDrive.
- For pass 2, first try an explicit same-conversation reference:
- “Open the workbook
Review.xlsxthat you created earlier in this conversation, add a tab namedPass 2, and return the updated workbook.”
- “Open the workbook
- If the agent cannot recover the file, reattach the saved copy. There is no documented Agent Builder setting that can force cross-turn restoration.
- Keep the original source document in SharePoint knowledge when appropriate, rather than relying on a chat attachment for a durable process.
- Treat each returned workbook as a new version and save it externally. Declarative agents are not recommended when the requirement is a durable business process with enforced state, retries, recovery, or transaction boundaries.^2^
A definitive statement that the 28-day, 10 MB, 16 MiB, 90-minute, and 200-call limits apply to Agent Builder would require Microsoft to add Agent Builder to those articles’ applicability statements or publish an Agent Builder-specific limits page. None of the supplied Microsoft staff Q&A responses establishes that mapping.
References
- Agent Builder overview
- Declarative agent architecture
- Add the code interpreter capability to your agent
- Files the agent creates (Microsoft Copilot) (preview)
- Code interpreter security architecture
- Attach files to a conversation (Microsoft Copilot)
- What's new history for Microsoft 365 Copilot extensibility
- Agent runtime limits (Microsoft Copilot)