Skip to main content
Many CLI commands take content that could be:
  • Sensitive (API keys, tokens, DB URLs).
  • Large (multi-line prompts, markdown notes, JSON payloads).
  • Coming from another process (a previous command’s output).
The CLI supports a consistent input syntax for these across every subcommand.

The three input modes

Wherever the CLI accepts a value that could be a secret, a file, or a pipe, it recognizes:
  • ?prompt interactively. Input is masked for secret fields, unmasked otherwise.
  • -read one line from stdin. Pipe-friendly.
  • @<path>read from a file. Whole-file content becomes the value.
  • Any other value — used literally, with a shell-history warning for secret fields.
Examples:

Which fields accept which mode

Most non-secret fields (names, descriptions, prompts) accept @<path> for file-based input. Secret-sensitive fields (--api-key, --auth-value, header values, DB URLs) also accept ? for masked prompt and - for stdin. When in doubt, <command> --help shows the specific input contract for each flag.

Reading a value from another CLI

Anywhere you can pass a literal, you can pass a subshell:

Passing multi-line content

@file for anything multi-line — prompts, note bodies, JSON payloads:
Or heredoc + stdin:
Note: not every command supports - for this specific flag — --help confirms.

Secrets and shell history

Passing a secret as a literal on the command line writes it to your shell history. Not just risky — often violates security policy. Symptoms:
Fix:
The CLI warns when it detects a secret-shaped literal but doesn’t refuse — you can override if you have your reasons.

Piping between nora commands

Because many commands support --json, they compose:

Reading complex structures via jq

Most --json output is arrays or objects. Common patterns:

Environment variables for CI

The CLI reads env vars for auth and workspace context:
Then commands become:
No credentials in the command line, no state written to disk.

Quoting rules

Bash and zsh handle quoting differently for special chars in shell values. If a value contains spaces, $, !, or #:
Interpolation-heavy JSON payloads: use jq -c to compact a JSON file into a single line:

Exit codes

The CLI follows standard Unix exit codes:
  • 0 — success.
  • 1 — general error.
  • 2 — misuse (bad flags, missing required args).
  • 4 — not authenticated.
  • 8 — permission denied (auth OK but role insufficient).
  • 16 — server error (5xx from platform).
  • 64 — command not found or malformed.
CI can gate on exit code:

When something’s not working

  • Turn on --verbose to see the full request/response.
  • Check nora auth status to confirm workspace and token.
  • Confirm the pinned Flow: nora flows current.
  • For CI, echo the exit code: nora flows publish support; echo "Exit: $?".