A2UI.Protocol.Messages.UpdateComponents (A2UI v0.3.0)

Copy Markdown View Source

Represents an updateComponents message from the A2UI protocol.

Summary

Functions

Parses a raw JSON map (the inner updateComponents object) into a struct.

Converts an UpdateComponents struct back to a JSON-compatible map (inner object).

Types

t()

@type t() :: %A2UI.Protocol.Messages.UpdateComponents{
  components: [A2UI.Component.t()],
  surface_id: String.t()
}

Functions

from_map(map)

@spec from_map(map()) :: t()

Parses a raw JSON map (the inner updateComponents object) into a struct.

to_map(msg)

@spec to_map(t()) :: map()

Converts an UpdateComponents struct back to a JSON-compatible map (inner object).