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

# MCP App HTML

> Serve built MCP App widgets for iframe hosts

The MCP App HTML endpoint serves the same built single-file widgets that are exposed through MCP `resources/read`, but over authenticated REST for hosts that do not have a live MCP client.

## Endpoint

```http theme={null}
GET /api/v2/mcp-apps/:view/mcp-app.html
```

Use this endpoint when an Interchange-hosted UI needs to render a `ui://agentic-api/.../mcp-app.html` widget in a sandboxed iframe. The response body is HTML text and should be passed to the iframe as `srcdoc`; hosts provide widget data over the MCP Apps bridge after the iframe initializes.

## Path parameters

| Parameter | Type   | Description                                                                   |
| --------- | ------ | ----------------------------------------------------------------------------- |
| `view`    | string | Built widget slug. Must contain only lowercase letters, numbers, and hyphens. |

Supported views:

| View                  | Resource URI                                        |
| --------------------- | --------------------------------------------------- |
| `api-call`            | `ui://agentic-api/api-call/mcp-app.html`            |
| `account-analysis`    | `ui://agentic-api/account-analysis/mcp-app.html`    |
| `sponsored-buyers`    | `ui://agentic-api/sponsored-buyers/mcp-app.html`    |
| `storefront-briefs`   | `ui://agentic-api/storefront-briefs/mcp-app.html`   |
| `test-runs`           | `ui://agentic-api/test-runs/mcp-app.html`           |
| `selling-terms`       | `ui://agentic-api/selling-terms/mcp-app.html`       |
| `acceptance-policy`   | `ui://agentic-api/acceptance-policy/mcp-app.html`   |
| `business-profile`    | `ui://agentic-api/business-profile/mcp-app.html`    |
| `merchandising-rules` | `ui://agentic-api/merchandising-rules/mcp-app.html` |
| `approvals`           | `ui://agentic-api/approvals/mcp-app.html`           |
| `seller-dashboard`    | `ui://agentic-api/seller-dashboard/mcp-app.html`    |
| `seller-setup`        | `ui://agentic-api/seller-setup/mcp-app.html`        |

## Response

Successful responses return the built HTML as text:

```http theme={null}
HTTP/1.1 200 OK
Content-Type: text/html;profile=mcp-app
Cache-Control: private, max-age=300
X-Content-Type-Options: nosniff
Content-Security-Policy: sandbox; default-src 'none'; script-src 'none'; base-uri 'none'; frame-ancestors 'none'

<!DOCTYPE html>
...
```

The response is intentionally cacheable only by the authenticated caller. Hosts should still apply their own iframe sandbox and bridge-level allowlists before sending data or actions into the widget.

## Errors

| Status | Code               | When                                                     |
| ------ | ------------------ | -------------------------------------------------------- |
| `400`  | `VALIDATION_ERROR` | `view` contains unsupported characters.                  |
| `404`  | `NOT_FOUND`        | No built MCP App widget exists for the requested `view`. |

## Example

```bash theme={null}
curl https://api.interchange.io/api/v2/mcp-apps/seller-dashboard/mcp-app.html \
  -H "Authorization: Bearer scope3_your_api_key_here" \
  -H "Accept: text/html"
```
