Skip to content

Reduce api-cli default verbosity #7595

@DavidePrincipi

Description

@DavidePrincipi

The api-cli command is frequently used during system maintenance or customization procedures.

In addition to the expected JSON output, many NS8 actions write supplementary information to standard error, which api-cli relays to its own stderr. These messages are often not actual errors but debug lines, which can be confusing or misleading.

Proposed solution

  1. Reduce the default verbosity of the command by omitting stderr relaying when the action completes successfully. If the action exits with a non-zero status, print the stderr output as currently done.
  2. Remove the "default cluster credentials" warning message. Improve error reporting when the action fails due to missing authorizations.

See also

Metadata

Metadata

Assignees

No one assigned

    Labels

    verifiedAll test cases were verified successfully

    Projects

    Status

    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions