Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Some links on this page are affiliate links: if you buy through them we may earn a commission, at no extra cost to you.

For a terminal, shell script, or CI job, use a command-line interface (CLI); an SDK is generally for capture from application code. Screenshot Scout’s documented CLI is an npm package that requires Node.js 22 or newer. This guide uses it as a concrete example—not as a universal command set for web-capture services. Install the CLI, set its access key in your shell, and run screenshotscout capture with a page URL and output path. Screenshot Scout’s CLI documentation describes the commands and options covered here.

CLI or SDK: which should you use?

A CLI accepts commands in a terminal and is a natural fit when a person, shell script, or CI job needs a capture. An SDK is a library your application imports to call the service and handle results in code. The terms are not interchangeable: command names, authentication, options, supported runtimes, and response handling vary by provider.

Screenshot Scout documents both approaches. Its CLI is an npm package, while its Node.js SDK is a separate package. The service also exposes an HTTP API, so using an SDK is optional if your language can make HTTP requests directly. The provider lists SDKs for Node.js/TypeScript, Python, PHP, Java, .NET, Go, and Ruby; installation, minimum language versions, and result APIs differ by ecosystem. Use the relevant SDK overview rather than assuming the Node.js instructions apply to another language.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Install Screenshot Scout’s CLI

The documented package is @screenshotscout/cli, and it requires Node.js 22 or newer. Check your Node.js version before installing:

node --version
npm install -g @screenshotscout/cli
screenshotscout --version

If the command reports that screenshotscout cannot be found after installation, check that npm’s global executable directory is on your PATH. The package can also be invoked without a global install. For a script or CI workflow, pin the package version so a later release does not silently change the command being run:

npx @screenshotscout/[email protected] capture https://example.com

The version-pinned invocation above is the example shown in the CLI documentation; check the package’s currently published version before adopting a version-specific command. See the CLI documentation for installation details.

Set credentials in the shell

Set the access key in the same environment that will run the command. On macOS, Linux, or another shell that accepts this syntax:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
export SCREENSHOTSCOUT_ACCESS_KEY="YOUR_ACCESS_KEY"

In Windows PowerShell, for the current session:

$env:SCREENSHOTSCOUT_ACCESS_KEY = "YOUR_ACCESS_KEY"

A secret key is needed only if the API key has the service’s “Require signed requests” setting enabled. In that case, configure SCREENSHOTSCOUT_SECRET_KEY as well. The CLI documentation says it signs locally and does not send the secret itself. In CI, keep both credentials in the CI platform’s secret storage and map them into the environment for the job; do not put secret values directly in a checked-in script.

Rank #2
Sale
HTML and CSS: Design and Build Websites
  • HTML CSS Design and Build Web Sites
  • Comes with secure packaging
  • It can be a gift option

If authentication fails, first verify that the access key is present in the process environment. If signed requests are required, verify that the secret key is present too. The getting-started documentation covers the service’s authentication and request methods.

Capture a page and choose an output

A basic capture saves the returned image or PDF to a named file:

screenshotscout capture https://example.com --output ./capture.png

If you omit --output, the CLI saves the result in the current directory using a generated name such as screenshot.<extension>. Use an output extension appropriate to the format you requested. To send the raw response bytes to standard output instead of a file, set the output to a hyphen:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
screenshotscout capture https://example.com --output - > ./capture.png

This is useful when the next pipeline step can read standard input, or when shell redirection should create the file. Treat this path as binary data: an image or PDF response is not automatically JSON or base64.

To request JSON output, specify the response type. The CLI writes the JSON as returned; it does not reformat or wrap it. For example, if the JSON response contains a screenshot_url field, jq can extract it:

screenshotscout capture https://example.com --response-type json | jq -r .screenshot_url

Use JSON when a script needs structured response data rather than the image or PDF bytes. The service’s response modes are also described in its getting-started guide.

Set capture options

CLI options use kebab-case. A documented example requests WebP, a full-page capture, and cookie-banner blocking:

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
screenshotscout capture https://example.com 
  --format webp 
  --full-page 
  --block-cookie-banners 
  --output ./homepage.webp

Do not assume these flags or their accepted values exist in another provider’s CLI. For Screenshot Scout, inspect the installed version’s local help for available spellings and values:

screenshotscout capture --help
screenshotscout capture-url --help

The provider’s screenshot-options reference explains option behavior. For reusable settings, put API option names in snake_case in a JSON object and pass the file with --options. For example:

Rank #4
Sale
Web Design with HTML, CSS, JavaScript and jQuery Set
  • Brand: Wiley
  • Set of 2 Volumes
  • A handy two-book set that uniquely combines related technologies Highly visual format and accessible language makes these books highly effective learning tools Perfect for beginning web designers and front-end developers
{
  "full_page": true,
  "format": "webp",
  "hide_selectors": [".newsletter-modal"]
}
screenshotscout capture https://example.com --options ./capture.json --output ./capture.webp

When the same option is set in both places, a command-line flag overrides the value in the options file. An omitted boolean is not necessarily the same as explicitly setting it to false; check the provider’s option reference for the behavior of omitted values. Use local help when an option is misspelled or rejected, because available flags and accepted values belong to the CLI version you installed.

Build a capture URL without taking a capture

capture-url constructs a URL locally; it does not send a capture request, and the CLI documentation says the command itself uses no capture quota. The generated URL includes the access key and options, so treat it as a credential-bearing link. Anyone who obtains it may be able to use the associated quota. If you must expose a capture URL, the provider recommends configuring signed requests and requiring signatures. The CLI can add the signature when the secret key is configured; it does not include the secret itself in the URL. See the CLI guide and authentication guide.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Run captures in CI and scripts

The CLI documentation describes it as suitable for any CI system that can run Node.js 22. A dependable job should install a pinned package version, retrieve credentials from the CI system’s secret storage, and let the command’s exit status determine whether the job succeeds. A successful capture writes the file without a success message, so silence alone does not indicate failure.

The documented exit codes are:

  • 0: the command completed successfully.
  • 1: the capture failed.
  • 2: a command error occurred.

For a downstream command that can read binary input, --output - avoids an intermediate file. For JSON handling, explicitly request --response-type json; do not pipe binary output into a JSON parser.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Use the Node.js SDK from application code

If the capture belongs inside a Node.js application rather than a shell workflow, use Screenshot Scout’s separate @screenshotscout/sdk package. It also requires Node.js 22 or newer. Its documented pattern creates a ScreenshotScoutClient, calls capture(), and writes the returned bytes to disk. It also supports a JSON response option and buildCaptureUrl(). Consult the Node.js SDK documentation for current initialization, authentication, and exact method signatures; CLI flags should not be assumed to be SDK method arguments.

The CLI, SDK, and HTTP API are alternative integration surfaces. Choose based on where capture belongs: a command-line invocation for terminal or CI work, an SDK call when application code needs to handle the result, or a direct HTTP request when your runtime can make one and you prefer not to add the SDK.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Common CLI problems and fixes

  • Access-key error: Set SCREENSHOTSCOUT_ACCESS_KEY in the environment of the process running the capture. A value set in a different terminal session will not automatically carry over.
  • Signed-request failure: If the API key requires signed requests, set SCREENSHOTSCOUT_SECRET_KEY too. Confirm the secret is available to the job without printing it into logs.
  • Command not found after global install: Add npm’s global executable directory to PATH, or use the documented npx approach.
  • Unknown or misspelled option: Run screenshotscout capture --help and check the installed version’s accepted options. Compare the option’s behavior with the option reference.
  • Boolean flag rejected: Use a bare flag such as --full-page, or an inline value such as --full-page=false. Do not pass the boolean as a separate space-delimited value.
  • Unexpected output in a pipe: Choose the format deliberately. Image and PDF output is binary; use --response-type json if a later command expects JSON.
  • Capture failure in CI: Check the process exit code and preserve the command’s error output. The documented code 1 indicates a failed capture; code 2 indicates a command error.

Or skip the browser setup

If you need an API call rather than a local browser setup, ScreenshotNeo returns a screenshot or PDF from one GET request. Its API accepts a URL and can return PNG, JPEG, WebP, or PDF. Here is the cURL form from the ScreenshotNeo documentation:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

ScreenshotNeo’s stated differences are practical for automated capture: cookie and consent banners, newsletter popups, and chat widgets are removed before the shot; bot checks, blank pages, and failed loads are never billed; and its MCP server lets AI agents such as Claude or Cursor take screenshots. The free plan includes 1,000 screenshots a month with no card, and paid plans start at $5 for 3,000. Sign up for ScreenshotNeo’s free plan.

Frequently Asked Questions

Does using a CLI mean I do not need Node.js?

For Screenshot Scout’s documented CLI, no: it requires Node.js 22 or newer, including when invoked through npx.

Does Screenshot Scout’s capture-url command use capture quota?

The provider says the command constructs the URL locally and does not itself send a capture request, so it uses no capture quota. The resulting URL still contains the access key and should be protected.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Can I use Screenshot Scout’s instructions for any web capture provider?

No. This is a provider-specific example. Other CLIs and SDKs may use different commands, authentication, options, runtimes, and response formats.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.