@midlyr/cli
v0.1.2
Published
MidLyr CLI package scaffold.
Readme
@midlyr/cli
CLI for the MidLyr regulation/compliance REST API.
Install
Requires Node.js >= 22. Install globally so the midlyr binary lands on your PATH (the -g flag is required):
npm install -g @midlyr/cli
pnpm add -g @midlyr/cli
bun add -g @midlyr/cli
yarn global add @midlyr/cliOr run without installing:
npx @midlyr/cli <command>
bunx @midlyr/cli <command>
pnpm dlx @midlyr/cli <command>If midlyr: command not found after -g install, your package manager's global bin dir isn't on PATH (check npm prefix -g//bin, or run bun setup / pnpm setup). npx @midlyr/cli works as a fallback.
Uninstall: npm uninstall -g @midlyr/cli (or drop -g for a local install).
Usage
midlyr login # one-time browser auth
midlyr <command> [options]For CI/containers, set MIDLYR_API_KEY=mlyr_... instead (takes precedence over the stored credentials).
Output is JSON on stdout; errors are JSON on stderr with a non-zero exit code. Global options: --help, --version, and --request-timeout-ms <ms>.
Commands
Run midlyr --help to see all commands, midlyr --version to print the installed CLI version, or midlyr <command> --help for per-command options.
browse-document— search regulationsdescribe-document— fetch regulation metadataread-document-content— fetch regulation content bodyscreen-analysis— submit text for compliance screening and poll until done
Example:
midlyr browse-document --query "fair lending" --authority CFPB --limit 25