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

@fhiron/cli

v0.1.1

Published

Fhiron CLI — automatiza validación FHIR® contra CL Core v1.9.4 desde la terminal, CI/CD y pre-commit hooks. Mismo motor que @fhiron/mcp-connector. Bilingüe es/en, zero dependencies.

Downloads

276

Readme

@fhiron/cli

Fhiron CLI — automatiza validación FHIR® contra CL Core v1.9.4 desde la terminal, CI/CD y pre-commit hooks.

Es el tercer canal de Fhiron junto a @fhiron/mcp-connector (agentes IA) y el futuro @fhiron/sdk (integración en código):

Conversa con tu agente vía MCP. Automatiza con CLI. Embebe con SDK. Misma API, misma cuota, mismo CL Core.

Zero dependencies de runtime (excepto @fhiron/linter).

Instalación

npm i -g @fhiron/cli
fhiron --version

También puedes usarlo sin instalar globalmente:

npx @fhiron/cli validate path/to/patient.json

Comandos

| Comando | Qué hace | Requiere login | Descuenta cuota | |---|---|---|---| | fhiron init | Crea fhiron.config.json en el proyecto | no | no | | fhiron login | Autentica vía device-code (browser) | — | no | | fhiron logout | Borra credenciales locales | no | no | | fhiron lint [glob] | Lintea archivos FHIR localmente | no | no | | fhiron validate [glob] | Valida contra api.fhiron.cl | sí | sí | | fhiron status | Plan, cuota, FHIR Score | sí | no |

Quick start

# 1. En tu proyecto
fhiron init
fhiron login

# 2. Lintea localmente (gratis)
fhiron lint "src/**/*.fhir.json"

# 3. Valida contra CL Core (descuenta cuota)
fhiron validate examples/patient.json

Uso en CI (GitHub Actions)

name: FHIR validation
on: [pull_request]
jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4
        with: { node-version: 20 }
      - run: npx @fhiron/cli lint "fhir/**/*.json"
      - run: npx @fhiron/cli validate "fhir/**/*.json"
        env:
          FHIRON_API_KEY: ${{ secrets.FHIRON_API_KEY }}

Para CI usa fhiron login --token $FHIRON_API_KEY o exporta FHIRON_API_KEY y los comandos lo recogen automáticamente.

Configuración

Por proyecto (fhiron.config.json)

{
  "tenant": "mi-tenant",
  "profile": "[email protected]",
  "validate": {
    "include": ["**/*.fhir.json", "**/fhir/**/*.json"],
    "exclude": ["**/node_modules/**"]
  },
  "lint": {
    "include": ["**/*.fhir.json"]
  }
}

Por usuario (~/.fhiron/config.json)

Generado por fhiron login. Permisos 0600. Contiene API key — no la subas al repositorio.

Variables de entorno

| Variable | Uso | |---|---| | FHIRON_API_KEY | Override de la API key (útil en CI) | | FHIRON_API_URL | Override del endpoint (default https://api.fhiron.cl) | | FHIRON_NO_BROWSER | No intenta abrir el browser en fhiron login | | NO_COLOR / FHIRON_NO_COLOR | Desactiva colores ANSI | | FHIRON_DEBUG | Imprime stack traces completos en errores inesperados |

Flags comunes

  • --json — output programático (donde aplica)
  • --quiet — solo errores, oculta warnings
  • --help, -h — ayuda del comando
  • --version, -v — versión instalada

Diferencia con @fhiron/mcp-connector

| Surface | Cuándo usar | |---|---| | MCP | Conversación y razonamiento dentro de Claude Code, Cursor, Continue, etc. El agente lee/escribe FHIR usando tools fhiron_* | | CLI | Automatización, CI/CD, pre-commit hooks, sanity checks rápidos en terminal, headless servers donde no hay agente |

Ambos consumen la misma API (api.fhiron.cl), descuentan la misma cuota del tenant y usan el mismo motor de validación (CL Core 1.9.4 + perfiles chilenos).

Exit codes

| Code | Significado | |---|---| | 0 | Todo OK | | 1 | Error funcional (validación falló, sin login, etc.) | | 2 | Error operacional (no se pudo conectar, dep faltante) |

Soporte

Licencia

MIT