Commands that delete (delete), shut down or change something hard to undo ask for confirmation on a terminal; the help says so («Asks before acting»). In a script, without a terminal, the command refuses (status 6) unless you write --yes: use it only when deleting is really what you meant. Where the page has a richer confirmation of its own (for example changing the Internet name, which first lists what it touches), the command asks that same question.
Read-only commands (list, show, and those the help marks «Read-only») change nothing and can be run anywhere.