nginxpm CLI

Agents

Machine-readable output, non-interactive operation, and read-only safety for coding agents.

nginxpm CLI is designed to be driven by coding agents as well as humans. It works with Claude Code, OpenAI Codex, Cursor, or any coding agent or agent harness that can run shell commands.

Machine-readable reads

  • Add -o json to list/get commands and status when output will be parsed.
  • Use -o yaml when YAML is more convenient for configuration workflows.
  • Non-zero exits signal command failure.
nginxpm proxy list -o json | jq '.[] | {id, domains: .domain_names}'

Safety flags

FlagEnvEffect
--read-onlyNGINXPM_READ_ONLY=trueBlocks server-mutating commands such as create, update, delete, enable, disable, and renew
--no-inputNGINXPM_NO_INPUT=1Disables interactive prompts; login and unconfirmed deletes fail instead of waiting
--quietNGINXPM_QUIET=1Suppresses informational output
--verboseNGINXPM_VERBOSE=1Enables verbose HTTP logging
# Safe, non-interactive inventory for an agent
NGINXPM_READ_ONLY=true NGINXPM_NO_INPUT=1 nginxpm proxy list -o json

--no-input does not make a command read-only. Use --read-only as the safety boundary. Outside read-only mode, --confirm allows delete commands to proceed without a prompt.

Configuration via environment

No login step is needed. Set credentials directly:

export NGINXPM_URL=https://npm.example.com
export NGINXPM_EMAIL=admin@example.com
export NGINXPM_PASSWORD=changeme
NGINXPM_NO_INPUT=1 nginxpm user current -o json

Definition files and stdin

Many create and update commands require -f with a JSON or YAML definition. Use -f - to read that definition from standard input:

nginxpm proxy create -f proxy.json
nginxpm setting update default-site -f - < setting.yaml

Agent skill

A ready-to-use skill lives at nginxpm/SKILL.md.

Next, review authentication for profile and credential precedence, or browse the complete command overview.

On this page