# `A2UIAgent.CatalogConfig`
[🔗](https://github.com/a2ui-elixir/a2ui/blob/v0.1.1/umbrella/apps/a2ui_agent/lib/a2ui_agent/catalog_config.ex#L1)

A catalog an agent registers, together with the transformers applied to
it.

    config =
      A2UIAgent.CatalogConfig.new(catalog,
        transformers: [A2UIAgent.CatalogTransformer.component_pruning(["Text", "Button"])]
      )

    config.transformed
    #=> the pruned catalog, which prompts and validation use

The transformed catalog is computed once, when the config is built.

# `t`
*since 0.1.0* 

```elixir
@type t() :: %A2UIAgent.CatalogConfig{
  catalog: A2UICore.Catalog.t(),
  transformed: A2UICore.Catalog.t(),
  transformers: [A2UIAgent.CatalogTransformer.t()]
}
```

# `from_path`
*since 0.1.0* 

```elixir
@spec from_path(String.t(), keyword()) :: {:ok, t()} | {:error, A2UICore.Error.t()}
```

Loads a catalog file with `A2UIAgent.CatalogProvider.load_file/2` and
registers it. Options: `:transformers`, `:catalog_id`,
`:protocol_version`.

# `new`
*since 0.1.0* 

```elixir
@spec new(A2UICore.Catalog.t(), keyword()) :: t()
```

Registers `catalog`. Option: `:transformers`, applied in order.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
