preview_url
Quick DEMO render on the public renderer (ephemeral, nothing stored). Limited to 2 runs per client, then deploy your own renderer and use make_surface_url. Onboarding only — not the workflow. DATA-IN-URL: keep payloads SMALL (URL < ~2000 chars); large payloads make long URLs that get truncated (→ render errors). For substantial content GRADUATE with emit_deployment instead — no size limit.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"payload": "<payload>"
},
"name": "preview_url"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| payload | Yes | The A2UI payload to preview: {title, theme, blocks:[...]}. Keep it small (URL under about 2000 chars). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Link on the public Apps Script renderer. | |
| demo | No | Always true: this is a demo render. | |
| note | No | Which link to use. | |
| size | No | Present when the URL is large: url_length, warning and recommendation. | |
| play_url | No | Link to the a2uicatalog.ai playground (recommended to share). | |
| clipboard | No | Optional ready-made copy commands for the URL (linux, macos, windows) plus a note. | |
| limitReached | No | True when the per-client demo limit was hit; no link is returned then. | |
| required_catalogs | No | Catalog URIs the payload needs (base catalog first). |