Skip to content

Addresses ​

Type
Class
Namespace
craft\mcp\capabilities
Inherits
craft\mcp\capabilities\Addresses
Since
5.12.0

Address-specific MCP capabilities. Addresses are listed and managed through the elements.* tools.

View source

Public Methods ​

MethodDescription
__construct()
getFieldLayout()
resourceByIdAndSite()
updateFieldLayout()

__construct() ​

View source

Arguments ​

  • $addresses
  • $actor
  • $elementSerializer
  • $elements
  • $fieldLayouts

getFieldLayout() ​

View source

Returns ​

array{fieldLayout: array<string,mixed>}

resourceByIdAndSite() ​

View source

Arguments ​

  • $id
  • $siteId

Returns ​

array{address: array<string,mixed>}

updateFieldLayout() ​

View source

Arguments ​

  • $fieldLayout (array<string,mixed>, null) – Native Craft field layout config. Pass null to clear the layout.

Returns ​

array{fieldLayout: array<string,mixed>}