Command reference
Run the DocuWriter CLI with npx. No global installation is required.
Start documentation
npx docuwriter
Starts the guided workflow: confirm a project folder, authorize your account, choose generation or import, complete setup, and upload a snapshot.
Options
| Option | Behavior |
|---|---|
--cwd <directory> |
Select exactly this project directory instead of the current working directory. |
--no-open |
Print browser links without opening them automatically. |
--json |
Write the final result as JSON. Prompts and interactive confirmation still apply. |
--help, -h |
Show available commands and options. |
--version, -V |
Show the CLI implementation version. |
Examples:
npx docuwriter --cwd ./packages/api
npx docuwriter --no-open
npx docuwriter --cwd ./my-project --no-open --json
npx docuwriter --help
npx docuwriter --version
--no-open does not bypass browser authorization. If authorization is needed, manually open the printed link.
--json is intended for structured final output during an interactive session. It does not make setup unattended or suitable for a noninteractive CI job.
Sign in
npx docuwriter login
Starts a fresh browser authorization and saves the resulting CLI session. Use this to sign in again or change the connected account.
Sign out
npx docuwriter logout
Revokes the saved CLI session and removes the locally saved session. Signing out does not delete documentation already accepted by DocuWriter.
Control analytics
npx docuwriter analytics status
npx docuwriter analytics off
npx docuwriter analytics on
Running npx docuwriter analytics without a setting also shows the status. The saved preference applies to later CLI runs on that installation.
You can disable analytics for a process by setting the environment variable DOCUWRITER_TELEMETRY_DISABLED=1. This overrides the saved analytics preference for that process.
Final result and exit codes
With --json, the final result includes a status and message. An accepted upload also includes the Space receipt and continuation_url. An accepted result means DocuWriter has accepted the snapshot for processing, not that processing is complete.
| Exit code | Meaning |
|---|---|
0 |
The command completed successfully. |
1 |
An error prevented completion. |
2 |
An interactive terminal is required. |
130 |
The operation was cancelled. |
There are no separate generate, import, search, export, or status subcommands in the current CLI. Choose generation or import inside the guided workflow; follow processing progress in your Space.
Related: Get started and Troubleshooting.