BrowserSolver

CLI

Install the BrowserSolver CLI SDK and make your first API call.

The official BrowserSolver command-line interface, with one command per endpoint.

Requirements

  • Node.js 20+

Install

npm install --global @browsersolver/cli
browsersolver --help
npx @browsersolver/cli --help

Get your API key

Copy your API key from the BrowserSolver dashboard and set it in the BROWSERSOLVER_API_KEY environment variable, which the SDK reads by default. Keep it out of source control.

export BROWSERSOLVER_API_KEY="YOUR_API_KEY"
$env:BROWSERSOLVER_API_KEY = "YOUR_API_KEY"

Usage

browsersolver website-webunlocker --query https://example.com
browsersolver website-webunlocker --help     # parameters of one command
browsersolver endpoints                # every command and its HTTP path
browsersolver endpoints search         # filter the list
browsersolver website-screenshot --url https://example.com --format png -o screenshot.png
echo '{"query": "https://example.com"}' | browsersolver website-webunlocker --params -
browsersolver website-webunlocker --params params.json --compact
browsersolver request get /v1/usage
browsersolver request post /v1/some/new/endpoint --params body.json
browsersolver website-webunlocker --query https://example.com | jq .

Exit codes

  • 0: success
  • 1: API or network failure
  • 2: invalid usage, such as an unknown command, a missing API key or a missing parameter

On this page