Skip to main content
After completing this guide, your component catalog will be indexed and queryable by AI through the MCP server or the Storybook addon.

Before you begin

  • A running Storybook instance or a deployed Storybook URL
  • Node.js 22 or higher
  • An API key from the Loracle dashboard (Project Settings > API Keys)

Publish your Storybook

1

Install the CLI

The package exposes the loracle binary.Or run it directly with npx:
2

Set your API key

3

Run publish

The CLI connects to your Storybook, extracts every component with its props and documentation, and uploads the catalog to Loracle.

CI/CD

Automate publishing on every release. The CLI uses Playwright internally to scrape your Storybook, so your CI environment needs a Chromium browser available.
Store your LORACLE_API_KEY as a CI secret. Never commit it to your repository.
The core steps are the same on every CI:
  1. Install your dependencies
  2. Install Chromium (npx playwright install --with-deps chromium)
  3. Build and serve your Storybook on a local port
  4. Wait for the server (npx wait-on http://localhost:6006)
  5. Run npx @loracle-js/cli publish <url> --version <version>
Add these steps to your workflow. ubuntu-latest requires an explicit Chromium install.
Store LORACLE_API_KEY as a repository secret.

Next steps

MCP server

Connect your coding agent to the published catalog.

Storybook addon

Use AI to generate stories from inside Storybook.