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

@naturali/cli

v0.83.5

Published

Command-line interface for the naturali.ai API, generated from its OpenAPI specs

Readme

@naturali/cli

The naturali command — one command per naturali.ai API operation, generated from the OpenAPI specs.

pnpm add -g @naturali/cli
export NATURALI_TOKEN=nat_sk_...

Configuration

The CLI always talks to https://api.naturali.ai — the only naturali.ai API origin, and not configurable. Credentials and the default project come from the environment:

| Variable | Purpose | | --- | --- | | NATURALI_TOKEN | Bearer credential (nat_sk_… or a session JWT). Required. | | NATURALI_PROJECT | Default --project-id for commands that take one. An explicit --project-id still wins. |

Commands

Every operation is a command named by kebab-casing its operationId: createAgentcreate-agent, rotateApiKeyrotate-api-key.

naturali list-commands              # every command, with its description
naturali create-agent --help        # one command's flags, and its docs link

Flags are the spec's parameter names. Kebab-case is the documented convention, but snake_case and camelCase are accepted too — --project-id, --project_id and --projectId are the same flag.

naturali list-agents --project-id proj_V1StGXR8Z5jdHi6B --limit 10

naturali create-agent \
  --project-id proj_V1StGXR8Z5jdHi6B \
  --provider-id aip_V1StGXR8Z5jdHi6B \
  --name support-triage \
  --tool-bindings '[{"tool_id":"tool_V1StGXR8Z5jdHi6B"}]'

Where a flag's value goes — URL path, query string or request body — comes from the spec, so you never have to know.

Values

| Kind | How to pass it | | --- | --- | | String | --name support-triage | | Number / boolean | --temperature 0.7, --force (a bare flag is true) | | Object | --tool-choice '{"type":"tool","name":"get_weather"}' | | Array | repeat the flag (--capabilities a --capabilities b) or pass a JSON array (--tool-bindings '[{"tool_id":"tool_a"}]') |

An array-typed field is always sent as a list, even with one value.

Every path parameter a command needs must be passed explicitly; a command that leaves one out fails and names it rather than guessing.

Output

The response body is printed to stdout as formatted JSON, so it pipes into jq:

naturali list-agents --project-id proj_V1StGXR8Z5jdHi6B | jq -r '.data[].id'

A non-2xx response prints the platform's error envelope to stderr and exits 1:

{
  "status": 403,
  "error": { "code": "access_denied", "message": "Not your project" }
}

Generation

src/generated/routes.ts is build output — never edit it, and never commit it. It is rebuilt from api/openapi/v1/*.yaml by pnpm generate, which typecheck, test and build all run first. See ../README.md for the pipeline.

Hand-written source is limited to dispatch, flag parsing, credentials and help; there is no per-endpoint code.

Testing

pnpm test runs the unit suite against a mocked fetch — flag parsing, dispatch, and help output, on every pull request.

pnpm e2e (tests/e2e/smoke.ts) is different: it drives the built CLI binary (bin/naturali) as real subprocesses against the real, deployed API, using a NATURALI_E2E_API_KEY account-scoped key. It proves the one thing the mocked suite can't — that the CLI, the @naturali/sdk it bundles, and the live API actually agree — and it provisions and archives its own throwaway project. It costs real model-provider money, so it only runs as part of the e2e job in main.yml, never on pull requests.

Versioning

Releases are automatic, and the version is shared with the API and with @naturali/sdk — one number, one git tag, three packages. @naturali/[email protected] speaks to API 0.28.0, and naturali --help is generated from the specs that release was built from, so it is always the authority on what your version can do.

Any change to api/openapi/v1/*.yaml regenerates this package and publishes it — new endpoints become new commands without anyone editing the CLI — and so does a change to @naturali/sdk, which is bundled in at build time rather than resolved from npm.

fix:/chore: changes release a patch and feat: a minor, inferred from the squashed commit subject. Every case publishes on merge, breaking changes included. See the repository's PIPELINE.md and CHANGELOG.md.