npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@facet-llc/schema-generator

v0.1.0

Published

Facet schema-generator CLI — `npx @facet-llc/schema-generator shopify` to crawl your Shopify Admin API and upsert a facet.yaml manifest under your account. Authenticates via device-code flow against app.facet.llc — your Shopify admin token is used once in

Readme

@facet-llc/schema-generator

Facet schema-generator CLI — crawls a Shopify Admin REST API and upserts a facet.yaml manifest into the site you own on Facet.

npx @facet-llc/schema-generator shopify \
  --shop-domain=acme.myshopify.com \
  --admin-token=shpat_xxxxxxxxxxxxxxxxxxxxxxxxxxxx

What it does

  1. Asks Facet for a device code, opens your browser to https://app.facet.llc/onboarding/cli?code=XXXX-XXXX.
  2. You sign in (Google or Microsoft Entra ID) and click Approve.
  3. The CLI gets a 30-day token tied to your account.
  4. Sends { shop_domain, admin_token } to app.facet.llc/api/catalog/generate-from-shopify with the token as Authorization: Bearer ….
  5. The server resolves the token → your user → your owned site, then crawls https://<shop>.myshopify.com/admin/api/2024-10/products.json, builds a normalized catalog, emits a facet.yaml manifest, and upserts it into site_manifests.
  6. CLI prints a count of imported products + a sample of titles.

Why server-side?

The Supabase service-role key lives only on the Facet server — it never hits your machine. Your Shopify admin token is forwarded in-flight to the server crawler for one run and discarded. Nothing is logged.

Flags

| flag | required | meaning | | -------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | --shop-domain=<handle>.myshopify.com | yes | Validated client-side AND server-side against ^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\.myshopify\.com$/i. Path/port injection or non-Shopify hosts are rejected before the admin token leaves the CLI. | | --admin-token=shpat_... | yes | Shopify Admin API access token — read_products scope is sufficient. | | --kya-issuer=<url> | no, repeatable | Override the manifest's kya_issuers list. Defaults to whatever the server picks for your site. |

Environment

| var | meaning | | ---------------- | ------------------------------------------------------------------------ | | FACET_API_HOST | Override the default https://app.facet.llc target. Useful for staging. | | FACET_DEBUG=1 | Log full error stack traces. |

Authoring a Shopify admin token

  1. In Shopify admin, go to Settings → Apps and sales channels → Develop apps.
  2. Create a new private app, grant read_products (and optionally read_inventory).
  3. Copy the Admin API access token (shpat_...).
  4. Pass it via --admin-token to this CLI.

The token is consumed once per run by the Facet server; it is not stored. You can rotate or revoke it at any time from the Shopify admin without affecting your Facet account.