mcp

v1.13.3
@astralkit/mcp Checked 12 hours ago Published 23 hours ago

AstralKit MCP Server — search, browse, and install UI components from any AI coding tool

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

search_components Search Components

START HERE when building any UI with AstralKit. Search components by name, description, or category to find the real component to INSTALL & REUSE (never freestyle one the library already has). Read the descriptions: the library ranges from minimal to BOLD showcase designs (watermarks, oversized display type, complex/asymmetric layouts) — prefer the most striking option that fits the brand, not just the most literal keyword match. LANDING PAGE OR WHOLE WEBSITE: search what the business is ("juice brand landing page", "restaurant website"). A matching website template comes back under `website…

ParameterTypeDescription
query *stringSearch query (component name, description, or keyword)
categorystringFilter by category, by slug or name ("heroes", "Heroes")
limitnumberMax results (default 20, max 100)

list_components List Components

List all available AstralKit components. Optionally filter by category. Use this to browse the full component catalog.

ParameterTypeDescription
categorystringFilter by category slug (e.g. "buttons", "forms", "navigation")
limitnumberMax results (default 50, max 100)
offsetnumberPagination offset

list_categories List Categories

List all available component categories. Use the returned category slugs to filter list_components or search_components.

get_component Get Component

Get a real, build-ready AstralKit component to INSTALL and REUSE — keep its structure/layout/polish and re-content it (swap copy, nav, logo, data) to fit the app; do not freestyle a replacement. Call search_components/list_components first to find the slug. Default mode "recipe" returns a lean, self-describing payload: source (comments stripped) plus the exact ak-* tokens, Phosphor icons, intended font, setup, and dependencies it uses — so you never guess. Use mode "full" only when you need the raw source with comments intact.

ParameterTypeDescription
slug *stringComponent slug (e.g. "button-sizes", "data-table", "sidebar-analytics")
frameworkstringFramework variant (default: react)
modestring"recipe" (default): lean, self-describing, build-ready. "full": raw source with comments.

get_design_tokens Get Design Tokens

Get the complete AstralKit design token reference — surfaces, text colors, borders, spacing scale, typography scale, radii, control heights, fonts, and common patterns — PLUS a raw-Tailwind→ak crosswalk for TOKENIZING existing (non-AstralKit) UI. Use this when styling components or converting raw Tailwind to ak-* tokens.

polish_ui Polish UI

REVAMP an existing UI to AstralKit quality — improve visual hierarchy, spacing rhythm, font sizes/weights, and surface treatment so it looks like part of the library, while KEEPING its layout, content, and app behavior. Use this (not just tokenizing) when the source design is mediocre and needs design-quality elevation, not only ak-* token translation. Returns a 7-phase procedure, a design-smell rubric, allowed/forbidden structural changes, a self-check, and per-region reference targets. Pass the UI regions you see (e.g. ["kanban-card","sidebar","form"]).

ParameterTypeDescription
archetypesarrayThe UI regions you identify, for per-region reference targets. Known archetypes: form, form-field, footer, sidebar, sidebar-nav, card, kanban-card, stat-tile, list-row, table, top-bar, badge, button,…

get_coding_standards Get Coding Standards

Get AstralKit coding standards — the mandatory rules for building with AstralKit. Covers token usage, semantic colors, typography floor, spacing, icons, touch targets, error handling, and empty states. Read this before writing any AstralKit code.

get_build_standards Get Build Standards

Get AstralKit STRUCTURAL standards — how to build an app well, not just how to style it. Covers architecture (atomic design, separation of concerns, layers, file-size limits), the safe incremental refactoring process for cleaning up a messy app, the loading/empty/error/populated state contract, error handling, responsive/mobile-menu patterns, and Radix correctness. This complements get_coding_standards (visual rules). Pass a topic to get one section; omit for the index. Use it before building app structure, or when asked to clean up / refactor vibe-coded code.

ParameterTypeDescription
topicstringWhich section to return. One of: architecture, refactoring, state-lifecycle, empty-states, error-handling, responsive, radix. Omit to get the index of all topics.

get_screen_blueprint Get Screen Blueprint

Get a UX blueprint for a specific screen type — structure, must-haves, anti-patterns, the four-state (loading/empty/error/populated) requirement, responsive/mobile notes, and exactly which AstralKit components to INSTALL for this screen (categories + ready search_components queries + polish_ui archetypes) — reuse and re-content them, do not freestyle. Call this FIRST when building a dashboard, navigation, pricing page, marketing/landing page, auth screen, onboarding flow, or settings page, so the screen is built right and on-library.

ParameterTypeDescription
screen_type *stringThe kind of screen to build. One of: dashboard, nav, pricing, marketing, auth, onboarding, settings (everyday names such as "landing page", "login" or "sidebar" are understood).

get_art_direction Get Art Direction

Get art direction guidance for a screen or component — what assets to generate, style/mood hints, which tools to use (e.g. generate_image, generate_video, search_logos), quality gates, and anti-patterns. Call this BEFORE building screens that need imagery (heroes, landing pages, dashboards with empty states, marketing sections, auth pages). The MCP cannot generate assets itself, but it tells you exactly what to generate with your other connected tools and how to verify the result.

ParameterTypeDescription
context *stringWhat you are building — e.g. "hero section for SaaS landing page", "pricing page", "dashboard", "auth login", "marketing landing page"

get_theming Get Theming (palette catalog)

Get the 17 designed AstralKit palettes with mood descriptors and the 2-step application (import astralkit/palettes + data-ak-theme="<id>"). Call this for EVERY new screen/app build and pick a palette that fits the brand mood — shipping the bare default black-and-white theme reads as an unfinished template. One palette per app; preserve an existing app's light/dark mode; 60-30-10 still applies within a palette.

get_setup Get Setup

Get the exact project setup AstralKit needs to RENDER correctly: the CSS imports (theme + utilities), the Inter font-load step (declaring a font is not loading it), Tailwind v3/v4 config, and the layout-primitive import. Call this before writing a screen in a fresh project, or if styles/fonts look wrong.

get_icons Get Icons

Get the COMPLETE list of valid Phosphor icon names (AstralKit uses Phosphor exclusively). Call this before importing any icon so you never guess a name that does not exist (a wrong name fails the build). Optionally filter by a keyword to narrow the list.

ParameterTypeDescription
filterstringOptional keyword to filter icon names (e.g. "arrow", "user", "chart")

search_logos Search Logos

Find real brand/company logos as ready-to-paste inline SVG (powered by svgl). Use for trust strips, social sign-in buttons, integration grids — instead of guessing or hand-drawing an SVG. Returns the SVG markup for each match. (Brand logos are the one place inline SVG is correct; UI icons must use Phosphor.)

ParameterTypeDescription
query *stringCompany/brand name(s), e.g. "github", "stripe", "google"
limitnumberMax logos to return (default 4, max 12)

get_preview Get Preview Image

Get a rendered PREVIEW IMAGE of a component so you can SEE its design before building. Use it to compare candidates from search_components and pick the best fit — then call get_component (recipe) to install and reuse the chosen one. Returns the image. (After you build, close the loop with verify_visual: it screenshots YOUR render and compares it against this reference.)

ParameterTypeDescription
slug *stringComponent slug to preview

verify_visual Verify Visual (screenshot vs reference)

The FINAL quality gate for any UI work — ALWAYS call this after validate_code + build succeed, before declaring done. Screenshots YOUR rendered page (needs the dev server running) and returns it NEXT TO the AstralKit reference preview plus a region-by-region comparison rubric you must answer item by item. This catches what code checks cannot: a banner with no image, a shrunken logo, an unintended dark background, an unloaded font, broken spacing. Pass the route URL and the slug of the reference component you built from; omit slug for a reference-free self-review. Fix every FAIL it surfaces a…

ParameterTypeDescription
url *stringThe page to capture — your running app route, e.g. http://localhost:3000/dashboard
clickSelectorstringClick this element BEFORE capturing — use to open dropdowns, popovers, or modals for interactive state verification (e.g. "[data-testid='account-menu']", "button:has-text('Menu')").
fullPagebooleanCapture the full scrollable page (default true) or just the viewport.
selectorstringOptional CSS selector to capture just the rebuilt region (e.g. "main", "#hero") when it sits inside a larger app shell.
slugstringSlug of the reference component you built from (adds its preview image to compare against). Omit if there is no single reference.
viewportstringViewport to render at: "desktop" (1440x900, default), "tablet" (768x1024), or "mobile" (390x844). Run desktop first, then tablet, then mobile — the tablet pass is where late-breakpoint bugs hide (co…

screenshot_ui Screenshot UI (see your own render)

Screenshot a page of YOUR running app (dev server must be up) and get the image back with a visual self-review rubric — so you can SEE what you actually rendered instead of assuming. Use during polish/revamp work or any time you changed UI without a single reference component. When you built from a specific library component, prefer verify_visual (it adds the reference preview to compare against). INTERACTIVE STATES: pass clickSelector to click a trigger element BEFORE the screenshot — use this to open dropdowns, popovers, and modals so you can verify their styling (bg-ak-elevated + border…

ParameterTypeDescription
url *stringThe page to capture, e.g. http://localhost:3000/settings
clickSelectorstringClick this element BEFORE capturing — use to open dropdowns, popovers, or modals for interactive state verification (e.g. "[data-testid='account-menu']", "button:has-text('Menu')").
fullPagebooleanCapture the full scrollable page (default true) or just the viewport.
selectorstringOptional CSS selector to capture one region (e.g. "main", "#pricing").
viewportstringViewport to render at: "desktop" (1440x900, default), "tablet" (768x1024), or "mobile" (390x844). Run desktop first, then tablet, then mobile — the tablet pass is where late-breakpoint bugs hide (co…

audit_page Audit Page (numerical quality gate)

Run a shipyard-grade numerical audit on your rendered page (dev server must be running). Tests 8 checks at multiple breakpoints: horizontal reflow, tap targets (WCAG 2.5.8), prose line measure, document structure (h1, landmarks, heading levels), focus visibility (:focus-visible), motion/prefers-reduced-motion, CLS risk (unsized media), and WCAG color contrast (with alpha compositing through the DOM tree — not a naive check). Returns structured findings with error/warning/note counts. This is the numerical companion to verify_visual/screenshot_ui — it measures, they show. FREE TIER — alwa…

ParameterTypeDescription
url *stringThe page to audit, e.g. http://localhost:3000/dashboard
breakpointsarrayViewport widths to test (default: [390, 768, 1440]). Reflow + tap targets run at each; page-level checks run at the widest.

install_component Install Component

INSTALL AstralKit components into the user's project. Pass `projectDir` (the ABSOLUTE path of the project root) and this tool RUNS the install itself, signed in with the AstralKit key this server was given: this is the reliable way, because that key is usually not in your own shell. Pass `slugs` to install several at once (a whole website template: the `sections` a search answered, in order). Without `projectDir` it only returns the CLI command for you to run.

ParameterTypeDescription
packageManagerstringPackage manager (default: npm)
projectDirstringABSOLUTE path of the project root (the folder with package.json). Given, the install runs now and its result comes back.
slugstringComponent slug to install
slugsarraySeveral component slugs to install in one go, in order (for example every section of a website template)

validate_code Validate Code

Check if code follows AstralKit conventions. Validates token usage, semantic colors, spacing, typography, icons, inline styles, and touch targets. Use this to audit component code before shipping. A component you INSTALLED from the library is recognised (by its install line, or by its class lists), and its own code is the library's: never yours to rewrite. Only what a change added is reported as an issue. Pass its `slug` too when you know it: that names it for certain.

ParameterTypeDescription
code *stringThe TSX/JSX/HTML code to validate
slugstringWhen the code is a component INSTALLED from the library (even one you then edited), its slug. What the library original already contains is then reported apart and never as something for you to fix.

review_app Review App (structural audit)

Audit code for STRUCTURAL "messy app" smells — the architectural counterpart to validate_code (which checks visual/token issues). Flags a missing loading/empty/error state contract, the "Ghost" and "Naked Empty" anti-patterns, swallowed errors (empty catch, alert(), raw errors shown to users), atomic-design / separation-of-concerns violations, navigation with no mobile menu, and Radix a11y gaps. Pass a single `code` snippet, or a `files` map (path -> contents) for cross-file checks (file-size limits, atoms that fetch, fat page.tsx, routes missing error.tsx/loading.tsx). Heuristic, not a comp…

ParameterTypeDescription
codestringA single TSX/JSX file or snippet to audit.
filesobjectA map of { "path/to/file.tsx": "contents" } for multi-file checks (file size, layering, route boundaries).
screen_typestringOptional screen type for screen-specific guidance. One of: dashboard, nav, pricing, marketing, auth, onboarding, settings.