@facet-llc/cli
v0.1.0
Published
Facet CLI — `npx @facet-llc/cli` to register a site, drop the well-known + a starter facet.yaml. Authenticates against app.facet.llc via device-code flow.
Readme
@facet-llc/cli
Interactive setup CLI for Facet.
npx @facet-llc/cliWhat it does
- Asks Facet for a device code, opens your browser to
https://app.facet.llc/onboarding/cli?code=XXXX-XXXX. - You sign in (Google or Microsoft Entra ID) and click Approve.
- The CLI gets a 30-day token tied to your account.
- Prompts for the new site's handle, domain, display name, and vertical, then registers it via the Facet API.
- Writes
./public/.well-known/facet-association.jsonand a starter./facet.yaml. - Prints the next steps — deploy, verify domain, edit catalog.
Requirements
- Node 18+
- A Facet account (sign up free at https://app.facet.llc/login)
Env
FACET_API_HOST— override the API target. Defaults tohttps://app.facet.llc. Use this when pointing at a deploy preview or a self-hosted instance.FACET_DEBUG=1— print full stack traces on unexpected errors.
Troubleshooting
Approval timed out. Codes expire 10 minutes after the CLI prints them. Re-run for a fresh one.
handle_taken / domain_taken. Pick a different handle (3–32 chars, lowercase alphanumeric + dashes) or a different domain.
Reserved handle. Facet reserves a small set of handles
(api, www, admin, etc.) so they can never collide with infra
subdomains.
