---
source: tests/cli_json.rs
expression: stdout
---
Download a file from a public GigaFile page

Usage: rgfile download [OPTIONS] <URL>

Arguments:
  <URL>  Download page URL

Options:
  -o, --output <OUTPUT>          Output directory or explicit output file path
  -k, --key <KEY>                Download key [aliases: --password]
      --select <SPEC>            Select files by 1-based index list/ranges, for example 1,3-5
      --force                    Overwrite the final output file if it already exists
      --no-resume                Ignore an existing .part file and start from zero
      --threads <THREADS>        Number of download connections for each file (1-16)
      --timeout <TIMEOUT>        Per-read stall timeout in seconds
      --retries <RETRIES>        Retry count for retryable network/server failures
      --user-agent <USER_AGENT>  Override the default User-Agent
      --dump-page <DUMP_PAGE>    Save the fetched download page HTML for diagnostics
      --json                     Print one JSON object and disable progress output
  -q, --quiet                    Disable progress and non-error status output
  -h, --help                     Print help

Global Options:
  -v, --verbose...     Increase logging verbosity (-v for info, -vv for debug)
      --config <PATH>  Load configuration from a specific TOML file
      --no-config      Do not load a configuration file
      --history        Enable history for this run
      --no-history     Disable history for this run
