Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ _A gallery of A2UI rendered cards, showing a variety of UI compositions that A2U

## ⚠️ Status: Early stage public preview

> **Note:** A2UI is currently in **v0.8 (Public Preview)**. The specification and
> **Note:** A2UI is currently in **v0.9 (Public Preview)**. The specification and
> implementations are functional but are still evolving. We are opening the project to
> foster collaboration, gather feedback, and solicit contributions (e.g., on client renderers).
> Expect changes.
Expand Down
19 changes: 14 additions & 5 deletions docs/concepts/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,24 +28,33 @@ How components connect to application state using JSON Pointer paths. Covers rea

## Message Types

=== "v0.8 (Stable)"
=== "v0.9 (Stable)"

Version 0.8 uses the following message types:
Version 0.10 uses the following message types:

- **`surfaceUpdate`**: Define or update UI components
- **`dataModelUpdate`**: Update application state
- **`beginRendering`**: Signal the client to render
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the diff being weird? Otherwise this is wrong, I think that the messages that were under 0.9 earlier should be here now, because these are 0.8 right?

- **`deleteSurface`**: Remove a UI surface

=== "v0.9 (Draft)"
=== "v0.10 (Draft)"

Version 0.9 uses the following message types:
Version 0.10 uses the following message types:

- **`createSurface`**: Create a new surface and specify its catalog
- **`updateComponents`**: Add or update UI components in a surface
- **`updateDataModel`**: Update application state
- **`deleteSurface`**: Remove a UI surface

v0.9 separates surface creation from rendering — `createSurface` replaces both `beginRendering` and the implicit surface creation in `surfaceUpdate`. All messages include a `version` field.
v0.10 introduces the `actionResponse` message type, enabling robust client-to-server synchronous RPC capabilities.

=== "v0.8 (Legacy)"

Version 0.8 uses the following message types:

- **`surfaceUpdate`**: Define or update UI components
- **`dataModelUpdate`**: Update application state
- **`beginRendering`**: Signal the client to render
- **`deleteSurface`**: Remove a UI surface

For complete technical details, see [Message Reference](../reference/messages.md).
44 changes: 21 additions & 23 deletions docs/guides/a2ui-in-mcp-apps.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,29 +104,27 @@ MCP Apps are typically delivered as a single HTML resource from the MCP Server.
2. Use a post-build script (like the [`inline.js`](https://github.com/google/A2UI/blob/main/samples/mcp/a2ui-in-mcpapps/server/apps/src/inline.js) script in the sample) to read the `index.html` and replace external `<script src="...">` and `<link rel="stylesheet" href="...">` tags with inline `<script>` and `<style>` tags containing the actual file contents.
3. This produces a self-contained HTML file that can be safely loaded via `srcdoc` in the restricted iframe.

> [!TIP]
> **Using Vite to inline**
>
> If your project uses Vite (common for React, Vue, or Lit), you can achieve the same single-file output automatically using plugins like `vite-plugin-singlefile`. This eliminates the need for a custom post-build script by handling the inlining during the build process itself.
>
> **How to use it:**
>
> 1. **Install the plugin**:
> ```bash
> npm install -D vite-plugin-singlefile
> ```
> 2. **Configure Vite**: Add the plugin to your `vite.config.ts` (or `.js`):
>
> ```typescript
> import {defineConfig} from 'vite';
> import {viteSingleFile} from 'vite-plugin-singlefile';
>
> export default defineConfig({
> plugins: [viteSingleFile()],
> });
> ```
>
> This will ensure that all JS and CSS assets are inlined into the `index.html` file on build, making it ready to be served by your MCP server as a single resource.
!!! tip "Using Vite to inline"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What caused this reformat? Is this the prettier plugin?

If your project uses Vite (common for React, Vue, or Lit), you can achieve the same single-file output automatically using plugins like `vite-plugin-singlefile`. This eliminates the need for a custom post-build script by handling the inlining during the build process itself.

**How to use it:**

1. **Install the plugin**:
```bash
npm install -D vite-plugin-singlefile
```
2. **Configure Vite**: Add the plugin to your `vite.config.ts` (or `.js`):

```typescript
import {defineConfig} from 'vite';
import {viteSingleFile} from 'vite-plugin-singlefile';

export default defineConfig({
plugins: [viteSingleFile()],
});
```

This will ensure that all JS and CSS assets are inlined into the `index.html` file on build, making it ready to be served by your MCP server as a single resource.

### Step 2: Leveraging A2UI-over-MCP

Expand Down
15 changes: 8 additions & 7 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,11 @@ A2UI enables AI agents to generate rich, interactive user interfaces that render

## Specification Versions

| Version | Status | Description |
| -------------------------------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **[v0.8](specification/v0.8-a2ui.md)** | **Stable** | Current production release. Surfaces, components, data binding, adjacency list model. |
| **[v0.9](specification/v0.9-a2ui.md)** | **Current** | Adds `createSurface`, client-side functions, custom catalogs, and the extension specification. [Evolution guide →](specification/v0.9-evolution-guide.md) |
| Version | Status | Description |
| ---------------------------------------- | ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **[v0.9](specification/v0.9-a2ui.md)** | **Stable** | Current production release. Adds `createSurface`, client-side functions, custom catalogs, and the extension specification. [Evolution guide →](specification/v0.9-evolution-guide.md) |
| **[v0.10](specification/v0.10-a2ui.md)** | **Draft** | Adds Client-to-Server RPC (actionResponse), custom functions, and dynamic schema features. [Evolution guide →](specification/v0.10-evolution-guide.md) |
| **[v0.8](specification/v0.8-a2ui.md)** | **Legacy** | Surfaces, components, data binding, adjacency list model. |

A2UI is Apache 2.0 licensed,
created by Google with contributions from CopilotKit and the open source community,
Expand All @@ -37,7 +38,7 @@ Instead of text-only responses or risky code execution, A2UI lets agents send **

This repository contains:

- **[A2UI specifications](specification/v0.8-a2ui.md)** (v0.8 stable, v0.9 draft).
- **[A2UI specifications](specification/v0.9-a2ui.md)** (v0.9 stable, v0.10 draft).
- **Implementations for [renderers](reference/renderers.md)** (Angular, Flutter, Lit, Markdown, etc.) on the client side.
- **Transports like [A2A](concepts/transports.md)** which communicate A2UI messages between agents and clients.

Expand Down Expand Up @@ -125,9 +126,9 @@ This repository contains:

***

Dive into the complete technical specs: [v0.8 (stable)](specification/v0.8-a2ui.md) · [v0.9 (draft)](specification/v0.9-a2ui.md)
Dive into the complete technical specs: [v0.9 (stable)](specification/v0.9-a2ui.md) · [v0.10 (draft)](specification/v0.10-a2ui.md)

[:octicons-arrow-right-24: Read the v0.8 spec](specification/v0.8-a2ui.md)
[:octicons-arrow-right-24: Read the v0.9 spec](specification/v0.9-a2ui.md)

</div>

Expand Down
10 changes: 5 additions & 5 deletions docs/introduction/what-is-a2ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ A2UI: JSON messages describing UI that:

### Example

=== "v0.8 (Stable)"
=== "v0.9 (Stable)"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, I don't think that updating the version numbers of the headers here is the right thing to do, because now the jsonl underneath doesn't match the version of the protocol on the title.


```jsonl
{
Expand Down Expand Up @@ -110,14 +110,14 @@ A2UI: JSON messages describing UI that:

```jsonl
{
"version": "v0.9",
"version": "v0.10",
"createSurface": {
"surfaceId": "booking",
"catalogId": "https://a2ui.org/specification/v0_9/basic_catalog.json"
}
}
{
"version": "v0.9",
"version": "v0.10",
"updateComponents": {
"surfaceId": "booking",
"components": [
Expand Down Expand Up @@ -151,7 +151,7 @@ A2UI: JSON messages describing UI that:
}
}
{
"version": "v0.9",
"version": "v0.10",
"updateDataModel": {
"surfaceId": "booking",
"path": "/booking",
Expand All @@ -162,7 +162,7 @@ A2UI: JSON messages describing UI that:
}
```

Key differences in v0.9: `createSurface` replaces `beginRendering`, components use a flatter structure with `"component": "Text"` instead of nested objects, and all messages include a `version` field.
In v0.9 (Stable), `createSurface` replaces `beginRendering`, components use a flatter structure with `"component": "Text"` instead of nested objects, and all messages include a `version` field.

Client renders these messages as native components (Angular, Flutter, React, etc.).

Expand Down
33 changes: 31 additions & 2 deletions docs/quickstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ In the web app, try these prompts:

Let's peek at what the agent is sending. Here's a simplified example of the JSON messages:

=== "v0.8 (Stable)"
=== "v0.9 (Stable)"

**Defining the UI:**

Expand Down Expand Up @@ -162,7 +162,7 @@ Let's peek at what the agent is sending. Here's a simplified example of the JSON
{"beginRendering": {"surfaceId": "main", "root": "header"}}
```

=== "v0.9 (Draft)"
=== "v0.10 (Draft)"

**Creating the surface:**

Expand All @@ -189,6 +189,35 @@ Let's peek at what the agent is sending. Here's a simplified example of the JSON

Note: In v0.9, `createSurface` replaces `beginRendering`, components use a flatter format, and the data model uses plain JSON values instead of typed adjacency lists.

=== "v0.10 (Draft)"

**Creating the surface:**

```json
{"version": "v0.10", "createSurface": {"surfaceId": "main", "catalogId": "https://a2ui.org/specification/v0_10/basic_catalog.json"}}
```

**Defining the UI:**

```json
{"version": "v0.10", "updateComponents": {"surfaceId": "main", "components": [
{"id": "header", "component": "Text", "text": "# Book Your Table", "variant": "h1"},
{"id": "date-picker", "component": "DateTimeInput", "label": "Select Date", "value": {"path": "/reservation/date"}, "enableDate": true},
{"id": "submit-text", "component": "Text", "text": "Confirm Reservation"},
{"id": "submit-btn", "component": "Button", "child": "submit-text", "variant": "primary", "action": {"event": {"name": "confirm_booking"}}}
]}}
```

**Populating data:**

```json
{"version": "v0.10", "updateDataModel": {"surfaceId": "main", "path": "/reservation", "value": {"date": "2025-12-15", "time": "19:00", "guests": 2}}}
```

Note: v0.10 continues using the flatter `createSurface` model with support for synchronous client-server `actionResponse` messaging.

=== "v0.8 (Legacy)"

TIP: It's Just JSON

Notice how readable and structured this is? LLMs can generate this easily, and it's safe to transmit and render—no code execution required.
Expand Down
16 changes: 16 additions & 0 deletions docs/specification/v0.10-a2ui.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# A2UI Protocol <span class="version-badge draft">v0.10 — Draft</span>

> Version 0.10 is currently in draft status. For production use, consider [v0.9 (Stable)](v0.9-a2ui.md).

> NOTE: Living Document
>
> This specification is automatically included from `specification/v0_10/docs/a2ui_protocol.md`. Any updates to the specification will automatically appear here.

For more information, see the following related documentation:

- [v0.9 Protocol Specification](v0.9-a2ui.md) (Stable).
- [Evolution Guide: v0.9 → v0.10](v0.10-evolution-guide.md).

---

--8<-- "specification/v0_10/docs/a2ui_protocol.md"
12 changes: 12 additions & 0 deletions docs/specification/v0.10-evolution-guide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Evolution Guide <span class="version-badge info">v0.9 → v0.10</span>

> This guide is automatically included from `specification/v0_10/docs/evolution_guide.md`. Any updates will automatically appear here.

For more information, see the following related documentation:

- [A2UI Protocol v0.9](v0.9-a2ui.md) (Stable - what you're migrating from).
- [A2UI Protocol v0.10](v0.10-a2ui.md) (Draft - what you're migrating to).

---

--8<-- "specification/v0_10/docs/evolution_guide.md"
6 changes: 3 additions & 3 deletions docs/specification/v0.8-a2a-extension.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# A2UI Extension for A2A Protocol <span class="version-badge stable">v0.8 — Stable</span>
# A2UI Extension for A2A Protocol <span class="version-badge legacy">v0.8 — Legacy</span>

> NOTE: Living Document
>
> This specification is automatically included from `specification/v0_8/docs/a2ui_extension_specification.md`. Any updates to the specification will automatically appear here.

> NOTE: Version Compatibility
>
> This extension specification applies to A2UI v0.8 and the A2A Protocol. For the base A2UI protocol, see [v0.8 Protocol Specification](v0.8-a2ui.md).
> This extension specification applies to A2UI v0.8 and the A2A Protocol. For the base A2UI protocol, see [v0.8 Protocol Specification](v0.8-a2ui.md) (Legacy).

For more information, see the following related documentation:

- [A2UI Protocol v0.8](v0.8-a2ui.md) (Stable).
- [A2UI Protocol v0.8](v0.8-a2ui.md) (Legacy).
- [A2A Protocol Documentation](https://a2a-protocol.org).

---
Expand Down
9 changes: 5 additions & 4 deletions docs/specification/v0.8-a2ui.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
# A2UI Protocol <span class="version-badge stable">v0.8 — Stable</span>
# A2UI Protocol <span class="version-badge legacy">v0.8 — Legacy</span>

> Version 0.8 is the current stable release, recommended for production use.
> Version 0.8 is a legacy release, maintained for backward compatibility.

> NOTE: Living Document
>
> This specification is automatically included from `specification/v0_8/docs/a2ui_protocol.md`. Any updates to the specification will automatically appear here.

For more information, see the following related documentation:

- [v0.9 Protocol Specification](v0.9-a2ui.md) (Draft).
- [v0.9 Protocol Specification](v0.9-a2ui.md) (Stable).
- [v0.10 Protocol Specification](v0.10-a2ui.md) (Draft).
- [Evolution Guide: v0.8 → v0.9](v0.9-evolution-guide.md).
- [A2A Extension Specification](v0.8-a2a-extension.md) (for v0.8).
- [A2A Extension Specification](v0.8-a2a-extension.md) (Legacy).

---

Expand Down
7 changes: 4 additions & 3 deletions docs/specification/v0.9-a2ui.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# A2UI Protocol <span class="version-badge draft">v0.9 — Draft</span>
# A2UI Protocol <span class="version-badge stable">v0.9 — Stable</span>

> Version 0.9 is currently in draft status. For production use, consider [v0.8 (Stable)](v0.8-a2ui.md).
> Version 0.9 is the current stable release, recommended for production use.

> NOTE: Living Document
>
> This specification is automatically included from `specification/v0_9/docs/a2ui_protocol.md`. Any updates to the specification will automatically appear here.

For more information, see the following related documentation:

- [v0.8 Protocol Specification](v0.8-a2ui.md) (Stable).
- [v0.8 Protocol Specification](v0.8-a2ui.md) (Legacy).
- [v0.10 Protocol Specification](v0.10-a2ui.md) (Draft).
- [Evolution Guide: v0.8 → v0.9](v0.9-evolution-guide.md).

---
Expand Down
4 changes: 2 additions & 2 deletions docs/specification/v0.9-evolution-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

For more information, see the following related documentation:

- [A2UI Protocol v0.8](v0.8-a2ui.md) (Stable - what you're migrating from).
- [A2UI Protocol v0.9](v0.9-a2ui.md) (Draft - what you're migrating to).
- [A2UI Protocol v0.8](v0.8-a2ui.md) (Legacy - what you're migrating from).
- [A2UI Protocol v0.9](v0.9-a2ui.md) (Stable - what you're migrating to).

---

Expand Down
23 changes: 11 additions & 12 deletions mkdocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,21 +56,25 @@ nav:
- Defining Your Own Catalog: guides/defining-your-own-catalog.md
- Authoring Custom Components: guides/authoring-components.md
- Theming & Styling: guides/theming.md
- A2UI over MCP: guides/a2ui_over_mcp.md
- MCP Apps in A2UI: guides/mcp-apps-in-a2ui.md
- A2UI in MCP Apps: guides/a2ui-in-mcp-apps.md
- A2UI + MCP:
- A2UI over MCP: guides/a2ui_over_mcp.md
- MCP Apps in A2UI: guides/mcp-apps-in-a2ui.md
- A2UI in MCP Apps: guides/a2ui-in-mcp-apps.md
- Reference:
- Component Gallery: reference/components.md
- Message Reference: reference/messages.md
- Renderers (Clients): reference/renderers.md
- Agents (Server-side): reference/agents.md
- Specifications:
- v0.8 (Stable):
- A2UI Protocol: specification/v0.8-a2ui.md
- A2A Extension: specification/v0.8-a2a-extension.md
- v0.9 (Draft):
- v0.9 (Stable):
- A2UI Protocol: specification/v0.9-a2ui.md
- Evolution Guide: specification/v0.9-evolution-guide.md
- v0.10 (Draft):
- A2UI Protocol: specification/v0.10-a2ui.md
- Evolution Guide: specification/v0.10-evolution-guide.md
- v0.8 (Legacy):
- A2UI Protocol: specification/v0.8-a2ui.md
- A2A Extension: specification/v0.8-a2a-extension.md
- Ecosystem:
- A2UI in the World: ecosystem/a2ui-in-the-world.md
- Community Renderers: ecosystem/renderers.md
Expand Down Expand Up @@ -202,8 +206,3 @@ plugins:
"introduction/where-is-it-used.md": "ecosystem/a2ui-in-the-world.md"
"guides/guide_a2ui_dynamic_mcp.md": "guides/a2ui-in-mcp-apps.md"
"guides/mcp-apps-in-a2ui-surface.md": "guides/mcp-apps-in-a2ui.md"
# - llmstxt:
# full_output: llms-full.txt
# sections:
# "Specification":
# - a2ui_protocol.md
Loading