list_componentsLABSCO SUMMARY
The assistant reaches for pc_* components instead of inventing Tailwind.
Without the schemas, an agent writing HEEx guesses at markup. With them it gets attrs, slots, allowed values and an example on demand — and because the schemas are generated by introspecting the library, they do not drift away from it.
What it is
A hosted MCP server serving schemas for petal_components, the Shadcn-style component library for Phoenix LiveView. The schemas are extracted from the library itself by a Mix task that introspects Phoenix.Component.__components__/0, so they track the real library rather than a hand-written copy.
What you get
- Every component in the library listed with a one-line summary
- The full schema for one component — attrs, slots, defaults, allowed values and docs
- A HEEx usage example alongside the schema
Requirements
Nothing to install — add https://mcp.petal.build/mcp to your client as an HTTP server, then work inside a Phoenix project. No account, no key.
Setup effort
One command — claude mcp add petal --transport http https://mcp.petal.build/mcp
USE CASES
Getting AI-written HEEx that uses the library
The component list and schemas ground the output in real petal_components markup.
Finding out which component fits
Read the whole library with a one-line summary for each.
Using a component correctly the first time
Read its attrs, slots, defaults and allowed values, with a usage example.
Keeping up as the library moves
Schemas are generated from petal_components itself, so they follow the version on Hex.
2 tools
Listed in project docs. Your client may show a different list.
get_componentBEFORE YOU INSTALL
What to know first
Tools you get
2 tools named in the project's documentation.
INSTALLATION
Connect your client
The command adds the entry to Claude Code for you; any other client needs an entry you write yourself.
Server setup
claude mcp add
claude mcp add petal --transport http https://mcp.petal.build/mcpHosted endpoint
https://mcp.petal.build/mcpAdd this hosted endpoint to your MCP client.