> ## Documentation Index
> Fetch the complete documentation index at: https://aivision.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Read the relevant procedure and prerequisites before suggesting commands. Cite the section and give an observable check. Treat sample data as illustrative. Report product actions and results only when verified in the user's environment.

# Preview HTML, Markdown, and code in a Trace

> Open recorded documents and explicit HTML links from Trace input and output, and copy code as recorded.

Use **Enhanced** view to inspect documents and code already recorded in a native Trace. You need read access to the Trace and an AI Vision version that offers the preview controls.

## Find the recorded content

1. Open [Agent traces](https://aivision.mintlify.site/en/guides/traces.md) and select your Trace.
2. In **Preview**, find the input or output. Use **View full message** for input and **View output source** or **View full output** for output.
3. For an individual call, select its Span and expand **Input** or **Output** in **Enhanced** view. Use **Original / JSON** to verify the recorded fields or message boundaries. See [Read call content](https://aivision.mintlify.site/en/guides/span-content.md).

## Open a document

Choose **Preview HTML** or **Preview Markdown** when it appears. If the content is recorded as a file, use **Load media** or **Load** on its card first. See [View recorded media](https://aivision.mintlify.site/en/guides/multimedia.md) for attachment permissions and loading controls.

Select **Preview** to read the document or **Source** to inspect the text. The copy icon copies the source. Identifiable fragments can be previewed even when the recording ends before a closing tag. Adjacent text parts in one message may form a single document. Separate calls and messages retain their own content.

An explicit HTTPS URL ending in `.html` or `.htm` in its path can offer **Preview HTML**. AI Vision requests the URL when you select the action. It sends no credentials or referrer, follows no redirects, and accepts a UTF-8 `text/html` response up to 512 KiB. The serving site needs to allow the browser's cross-origin request. If the preview is unavailable, check the recorded URL and server response, then select **Retry**.

HTML is rendered in a static sandbox. Scripts, navigation inside the document, and external resources are blocked. Markdown document previews show link text without opening destinations or loading remote images.

[![Static HTML preview showing a sample report table, with Preview, Source, Copy and Close in the top bar](https://mintcdn.com/aivision/ZziJIIF-59LYjMtn/assets/figures/trace-document-preview/html-link.en.light.png?fit=max\&auto=format\&n=ZziJIIF-59LYjMtn\&q=85\&s=1ef1044347d20c725febdeacdf5c6335)](https://aivision.mintlify.site/assets/figures/trace-document-preview/html-link.en.light.png)

[![Static HTML preview showing a sample report table, with Preview, Source, Copy and Close in the top bar](https://mintcdn.com/aivision/ZziJIIF-59LYjMtn/assets/figures/trace-document-preview/html-link.en.dark.png?fit=max\&auto=format\&n=ZziJIIF-59LYjMtn\&q=85\&s=1b50b24219b3cd2e499fc2372f6287b4)](https://aivision.mintlify.site/assets/figures/trace-document-preview/html-link.en.dark.png)

HTML link opened in the static preview · Synthetic data · Select to enlarge

## Read and copy code

Recognized code blocks and code fields display in a separate block, with syntax highlighting when the language is supported. Select **Expand full text** when it appears. Use **Copy original content** on the code block to preserve its indentation, spaces and line breaks. Adjacent recorded text parts that split one code fence can be rejoined within the same message.

Code stays as text. AI Vision does not execute it or request URLs inside it. Very long or unrecognized code can appear as plain text. Use **Original / JSON** to check the containing message when a code block is missing.

[![Trace input showing the Preview HTML action above an expanded JavaScript block with a copy icon and a URL rendered as a string](https://mintcdn.com/aivision/ZziJIIF-59LYjMtn/assets/figures/trace-document-preview/code.en.light.png?fit=max\&auto=format\&n=ZziJIIF-59LYjMtn\&q=85\&s=03629e38a41656260087e6ff74f0d3c9)](https://aivision.mintlify.site/assets/figures/trace-document-preview/code.en.light.png)

[![Trace input showing the Preview HTML action above an expanded JavaScript block with a copy icon and a URL rendered as a string](https://mintcdn.com/aivision/ZziJIIF-59LYjMtn/assets/figures/trace-document-preview/code.en.dark.png?fit=max\&auto=format\&n=ZziJIIF-59LYjMtn\&q=85\&s=faacfbfa00221ffdd55ee8998cefc18c)](https://aivision.mintlify.site/assets/figures/trace-document-preview/code.en.dark.png)

Expanded JavaScript in a Trace input · Synthetic data · Select to enlarge


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.