Introducing the Nulvless CLI

An open-source CLI to integrate Nulvless into your app, built for AI agents and people. Environments, Edge Functions, secrets and the docs, in your terminal.

Gleisson MatosFounder & CEO3 min read
On this page

Today we are releasing the Nulvless CLI, an open-source command line for Nulvless projects. It manages environments, Edge Functions and their secrets from the terminal, and it was designed from the first command to be used by AI coding agents as well as by you.

npm install --global nulvless
nulvless login

The package installs two equivalent commands, nulvless and the shorter nulv. The code is on GitHub under the MIT license.

Build this with your agent

A ready prompt for Claude Code, Cursor, ChatGPT or any coding agent. It points the agent at this guide and the docs, so it follows the real API instead of guessing.

Set up the Nulvless CLI for this project.

Read https://www.nulvless.com/llms.mdx/docs/cli/content.md first. It documents
the real commands, so do not guess them.

- Check that `npx nulvless whoami --json` works. If it exits with code 2, ask me
  to run `npx nulvless login` in my own terminal and wait.
- Ask me for the organization and project slugs, and pass them as `--org` and
  `--project` on every command.
- Always pass `--json` and read errors from the JSON line on stderr.
- Never print secret values. Set secrets with KEY=VALUE only when I give you the
  value.
or open in

Why a CLI now

More and more of the code that talks to Nulvless is written with an agent in the loop. Agents are good at reading docs and running commands, and bad at clicking through a console. Until now, every change outside your code, such as a new environment or a rotated secret, meant leaving the editor for the browser. The CLI brings those actions to the one interface both you and your agent already share: the terminal.

What it does today

The first release covers the day-to-day work around a project:

nulvless whoami                                   # account and organizations
nulvless environments list --project shop         # environments of a project
nulvless environments create staging              # a new environment
nulvless functions list                           # Edge Functions
nulvless functions deployments checkout           # deployment history
nulvless secrets set STRIPE_SECRET_KEY --function checkout
nulvless docs sdk/auth                            # a docs page as Markdown

Secrets get special care. secrets list shows names and never values. secrets set KEY without a value asks for it without echoing it, so the value never lands in your shell history, and saving a secret redeploys the function with it. Names Nulvless reserves for injected values, such as anything starting with NULVLESS_, are refused before a request is sent.

Built for agents

Designing for agents turned out to be the same as designing for scripts and for people in a hurry. A few rules shaped every command:

  • The docs are a command away. nulvless docs prints the index of every page and nulvless docs <path> prints one page as Markdown. An agent can read the real API before it writes a line, instead of guessing method names.

  • Output an agent can parse. Every command takes --json. Results go to stdout and everything else to stderr, so the JSON is never mixed with progress messages. Failures are JSON too:

    {"error":{"message":"You are not signed in.","hint":"Run `nulvless login` to sign in.","exitCode":2}}
  • Never stuck on a prompt. Outside a terminal the CLI never waits for input. If it needs an organization or project, it fails and names the flag to pass. Destructive commands require --yes.

  • Errors with a next step. Every error carries a hint. Exit codes are stable: 0 for success, 1 for a failure, 2 when you need to sign in or lack permission.

Sign-in without copying tokens

nulvless login uses the same OAuth Server you can turn on for your own projects. The CLI opens the consent screen in your browser, you approve, and the browser hands the session back to the CLI on your machine. It uses authorization code with PKCE and a one-time loopback address, the flow OAuth 2.1 recommends for native apps.

The session is stored in your system keychain, with a file readable only by your user as a fallback, and is renewed automatically. In CI, set NULVLESS_TOKEN and no browser is involved.

What comes next

This release is the foundation. Next we are working on creating and deploying Edge Functions from your repository, so the whole loop from writing a function to shipping it can run from the terminal, by you or by your agent.

The CLI is open source, and issues and pull requests are welcome on GitHub. To get started, read the CLI docs or run:

npx nulvless --help

Keep reading

Engineering5 min read

Introducing Edge Functions on the Nulvless Network

What edge functions are, how they run your TypeScript in the region closest to each user, and when to use them instead of single-region serverless.

Gleisson Matos