logo
search
Copilot Data & Privacy Issues

How to Store a Complete Copilot Studio Chat Transcript in a Variable

Maira MehtabMaira Mehtab Oct 1, 2026 868 views

Question details

The user wants to capture the entire conversation history from Microsoft Copilot Studio and send it to an email using Power Automate.

How to Store a Complete Copilot Studio Chat Transcript in a Variable
Product
Microsoft Copilot Studio
Device & OS
not provided
Scenario
Capturing and automating the retrieval of a full chat transcript to send via email.
Observed behavior
Standard variables often only capture or return the latest user message, leaving out the complete historical chat context.
Before you start

Ensure you have adequate permissions to edit topics in Microsoft Copilot Studio and create flows in Power Automate.

Solution 1Recommended

Compile the Transcript Using a Custom Variable

Use Copilot Studio's variable management to append user and bot messages throughout the conversation manually.

Since standard connectors might not have a direct 'Get Chat History' action, building the transcript during the session is a reliable workaround.

1
Initialize a String Variable

In your Copilot Studio topic, create a new Global string variable (e.g., Global.ChatTranscript) at the start of the conversation.

2
Append Messages to the Variable

After every user response and bot reply, use the 'Set variable value' node to append the latest message to your existing Global.ChatTranscript variable using the Concatenate formula.

3
Pass the Variable to Power Automate

Add an action to 'Call an action' and select your Power Automate flow. Pass the Global.ChatTranscript variable as the input parameter.

4
Send the Email via Power Automate

In the Power Automate flow, use the 'Send an email (V2)' action and insert the transcript input variable into the email body.

Compile the Transcript Using a Custom Variable
Variable Limitations: Keep in mind that there may be character limits on string variables depending on your environment, so this is best suited for standard-length conversations.
Free Microsoft Office alternative

Manage Your Exported Chat Transcripts Easily with WPS Office

If you regularly export Microsoft Copilot or Power Automate chat transcripts into documents or spreadsheets, WPS Office offers a free, lightweight, and highly compatible alternative to Microsoft Office. It's perfect for formatting, analyzing, and sharing your conversation logs.

  1. 1. Download WPS Office: Visit the official WPS website to download and install the free software suite.
  2. 2. Open Your Transcript: Launch WPS Writer or Spreadsheet and open your exported text, DOCX, or CSV chat logs.
  3. 3. Format and Save: Use familiar formatting tools to organize the conversation data, apply highlights, and save your document.
Highly compatible with Microsoft Word, Excel, and CSV formats.Free, lightweight, and incredibly fast to open large transcript files.Familiar user interface ensures seamless migration and ease of use.Built-in PDF editing tools for standardizing your chat reports.
microsoft office alternative - wps office

Frequently Asked Questions

Why does my flow only capture the last message sent in Copilot Studio?

By default, standard system variables often store only the most recent user input. To capture the full session, you must explicitly configure a global variable or array to continuously append the chat history as the conversation progresses.

Is there a built-in 'Get Chat History' action in standard Power Automate connectors?

Currently, there is no direct, out-of-the-box action labeled 'Get Chat History' specifically for Copilot Studio in the standard connectors. Users typically rely on manual variable tracking or advanced custom API calls.

Can I send the compiled transcript directly to an email from Copilot Studio?

Copilot Studio cannot send emails directly on its own. You must pass your compiled transcript variable to a Power Automate flow, which then uses a connector like 'Send an email (V2)' via Outlook or another email provider.

Where is the best place to ask for advanced Microsoft Power Automate support?

For advanced custom connector or specialized workflow inquiries, it is recommended to visit the official Microsoft Power Automate Community (powerusers.microsoft.com), as specialized community members actively share updated workarounds there.