Skip to main content

nagent CLI

nagent is the command-line client for SimpleAgent deployments.

Install

uv tool install nagent-cli
nagent --help

If uv has stale package metadata immediately after a release, refresh the package cache:

uv tool install --force --refresh-package nagent-cli nagent-cli

To install a specific version:

uv tool install 'nagent-cli==0.4.5'

Log in

Use the API base URL and management key provided by your workspace administrator. For a human terminal, omit the key option and use the hidden prompt:

nagent login --api-base-url https://<api-hostname>

For non-interactive use, send the key as one bounded line through a non-terminal pipe so it never appears in argv or an environment variable. For example, read an existing key from macOS Keychain:

security find-generic-password -w -s nagent-staging-management \
  | nagent login --api-base-url https://<api-hostname> --api-key-stdin

--api-key-stdin is mutually exclusive with --api-key and with prompting. It rejects terminal, EOF/empty, multi-line, invalid UTF-8, and oversized input. Agent and JSON modes never prompt; they require --api-key-stdin (preferred) or the less-safe explicit --api-key argument.

This input changes only the local 0600 CLI credential file. It does not change a management API request/response or server schema, so Nagent Console, ui/manifest.yaml, and generated OpenAPI/UI types intentionally have no corresponding field or flow.

Common commands

nagent models list
nagent tools list
nagent secrets list
nagent deploy ./agent --deployment prod
nagent versions list <agent-name>
nagent run prod 'Hello'

nagent run submits with wait=false and polls the returned /runs/{run_id} resource by default. --stream is human-only: it follows /runs/{run_id}/events over SSE after submission, then confirms final status by polling. --wait instead uses one blocking request and is more susceptible to intermediary timeouts. The start request contains only message and wait; streaming is a separate run-resource transport.

nagent versions list <agent-name> reports each immutable version's public manifest summary, including all configured limits (max_runtime_seconds, max_tool_calls, max_concurrent_runs, max_total_tokens, and max_cost_usd). Human, --agent, and --json modes expose the same public-safe values; internal runtime and package metadata is never included.

With a stored management key, nagent run-log <run_id> fetches the public-safe workspace diagnostic from /api/runs/{run_id}/log. It has no raw mode and cannot return package refs, exact secret/version IDs, raw Pi events, worker/runtime internals, or private paths.

Agent bundles contain:

  • AGENTS.md — agent instructions
  • agent.yaml — public model/tool manifest

Validate a bundle locally before deploying:

nagent inspect-bundle ./agent

Machine-readable output

Use deterministic plain text for agents and scripts:

nagent deployments list --agent

Use JSON for structured automation:

nagent deployments list --json

Export deployed source

Fetch the current deployed bundle for inspection or local editing:

nagent deployments get-bundle prod --out ./prod-bundle

This writes AGENTS.md, agent.yaml, and deployment-bundle.json with logical secret binding names only. Existing files are not overwritten unless --force is supplied.

AGENT_SESSION=1 selects agent mode by default unless --json is supplied.

Upgrade

uv tool upgrade nagent-cli

Metadata

Release files for nagent-cli 0.4.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nagent-cli 0.4.5
File Size Uploaded
nagent_cli-0.4.5.tar.gz 52.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nagent-cli 0.4.5
File Interpreter ABI Platform
nagent_cli-0.4.5-py3-none-any.whl Python 3 none any Details

Total release size: 111.5 kB

Release files / nagent_cli-0.4.5.tar.gz

Download URL nagent_cli-0.4.5.tar.gz
Size 52.2 kB
Tags Source
SHA-256 checksum
How to use checksums
2ca41d90bae3d69a9a38828e53f6b29ae4a08b2ac38acc7731fdf00eacc7b939
BLAKE2b-256 checksum
How to use checksums
6a9a9aeeb825eee12ef2093bb497b75f053344932cd3d8fafe27090f1c1899c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / nagent_cli-0.4.5-py3-none-any.whl

Download URL nagent_cli-0.4.5-py3-none-any.whl
Size 59.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6eea4120172a9374203ea932cb8dc421892adae42c66293dbda59a991111f2e3
BLAKE2b-256 checksum
How to use checksums
c69d3f3ca496a45bea79c7c9e6b873e2ebc5f37c9993d7114d5f55086958db6c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

This release

0.4.5 This release

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page