October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

How to Run ScreenshotMachine API Calls in Docker (CLI Workflow)

A practical Docker-and-curl wrapper for ScreenshotMachine’s HTTP screenshot API, with key handling, host output, and troubleshooting—not an official CLI.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

There is no documented, vendor-supported ScreenshotMachine CLI or Docker image in the official materials cited here. You can still use Docker to run a small curl command that calls ScreenshotMachine’s HTTP API and saves the image to your host. Treat this as your own Docker wrapper—not an official ScreenshotMachine CLI recipe.

What you need to know first

ScreenshotMachine documents an HTTP GET API: requests use the API endpoint and query parameters, including a customer API key, target URL and screenshot dimensions. Its API reference gives the endpoint as https://api.screenshotmachine.com/?. Official code examples include Bash and Node.js, but the reviewed official materials do not document a maintained CLI or Docker image. See the ScreenshotMachine Website Screenshot API and its GitHub examples for current details.

That distinction matters: the commands below use Docker’s general container and bind-mount features to run curl. They do not invoke a ScreenshotMachine-maintained binary. Docker documents these features in its container run reference.

Run a ScreenshotMachine request with Docker and curl

1. Set your API key and output directory

Replace the example key and target URL with your own values. Create a local directory to receive the screenshot:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Dell PowerEdge R730xd Server 24B SFF 2U, 2X Intel Xeon E5-2690 v4 2.6Ghz (28-cores Total), 128GB DDR4 RAM, 4X 1.2TB 10K SAS 2.5” 12Gb/s HDD, H730P 2GB RAID, NIC 10Gb + I350 1Gb (Renewed)
  • Dell PowerEdge R730xd 24B SFF 2U Server
  • 2x Intel Xeon E5-2690 v4 2.6Ghz 14-Core (28-cores Total)
  • 128GB DDR4 RAM – 4x 1.2TB 10K SAS 2.5” 12Gb/s
  • Dell H730P mini 2GB 12Gb/s RAID
  • 2x 750W PSU - 2x 10Gb SFP+ 2x 1Gb (RJ45) NIC
export SCREENSHOTMACHINE_KEY='YOUR_API_KEY'
mkdir -p "$PWD/screenshots"

Do not put the key in a Dockerfile or commit it to source control. Passing it at runtime keeps it out of the built image, though environment variables can still be visible to users with access to container configuration. For stronger isolation in production, use your platform’s secret mechanism.

2. Make the API call and write the image to the host

Run a minimal curl container, pass the key as an environment variable, and bind-mount the host directory at /output:

Rank #2
Dell Optiplex 7050 SFF Desktop PC Intel i7-7700 4-Cores 3.60GHz 32GB DDR4 1TB SSD WiFi BT HDMI Duel Monitor Support Windows 11 Pro Excellent Condition(Renewed)
  • Model: Dell OptiPlex 7050 Small Form Factor (SFF)
  • Processor: Intel Core i7-7700 3.60 GHz
  • Memory: 32GB DDR4 Ram
  • Storage: 1TB Solid State Drive (SSD) Fast Boot + Storage
  • Operating System: Windows 11 Pro (64-bit)
docker run --rm 
  -e SCREENSHOTMACHINE_KEY 
  -v "$PWD/screenshots:/output" 
  curlimages/curl:latest 
  -fSsgG 'https://api.screenshotmachine.com/' 
  --data-urlencode "key=$SCREENSHOTMACHINE_KEY" 
  --data-urlencode 'url=https://example.com' 
  --data-urlencode 'dimension=1024x768' 
  -o /output/page.png

The image is written to screenshots/page.png on the host. The endpoint and parameter spellings shown reflect the documented API pattern; check ScreenshotMachine’s current reference and your account settings for the accepted parameters and dimensions before relying on a production command. The reference documents the API key, URL and dimensions, but this wrapper is not a vendor-supplied Docker configuration.

The -f option makes curl return a failure status for HTTP error responses; -S keeps an error message visible; -s suppresses progress output; and -gG sends a GET request with query parameters. --data-urlencode safely encodes the target URL rather than requiring you to assemble a query string by hand.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Hewlett Packard Enterprise ProLiant MicroServer Gen11 Tower Server with Intel Xeon 6315P, 16GB DDR5, 4LFF Bays, 180W PSU (P86811-005)
  • 2.80 GHz processor speed ensures efficient operation with consistent reliability
  • Intel Xeon 2.80 GHz processor provides enterprise-grade performance with built-in security and remote management capabilities
  • Quad-core (4 Core) processor core helps server process data quickly and reliably for maximum productivity
  • 1 processors supported for faster processing and improved access to data, optimizing performance under heavy loads
  • With 16 GB memory, you can multitask between applications seamlessly, keeping productivity high and response times quick

Choose curl or a language client

Approach Best for Trade-off
curl in a container A one-off request or a small shell workflow with few dependencies. Simple HTTP handling; you must decide how your script handles output, errors and retries.
ScreenshotMachine sample client in a runtime container Projects already using a supported language sample, or workflows that need language-level URL generation and download handling. Requires the matching runtime and any client dependencies. ScreenshotMachine publishes examples, not a documented official Docker image or CLI.

ScreenshotMachine’s Bash and Node.js examples are available among its GitHub examples. For a language container, mount the working directory, provide the key at runtime, and run your own script that builds the API request and writes the response beneath the mounted output path.

Common problems and fixes

  • Authentication or parameter error: Confirm the API key and parameter names against the current API reference. Ensure the environment variable is set in the shell that launches Docker.
  • The screenshot is missing on the host: Check that the host directory exists, that the bind mount points to the expected absolute path, and that the command writes to a path under /output.
  • The saved file is not a usable image: Inspect the HTTP status and response before assuming the API returned an image. Curl’s -fS flags expose HTTP failures, but you should still verify that the response is an image before downstream processing.
  • The container cannot reach the API: Check the host’s network access, DNS and any proxy or firewall rules. The container must be able to make an HTTPS request to ScreenshotMachine’s API.
  • A command using screenshotone/cli does not work: That Docker Hub image is described as a CLI for ScreenshotOne, a different screenshot service; it is not a ScreenshotMachine client. See the ScreenshotOne CLI image.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

ScreenshotNeo offers an API and MCP server for screenshots, with a single GET request for a capture. Its cleanup steps can accept cookie or consent banners and remove known consent platforms, newsletter popups and chat widgets before capture; each step can be disabled. Bot checks, blank pages, failed loads, timeouts and cache hits are not billed, and responses identify the page verdict and billing status in headers. Its MCP server provides take_screenshot, get_page_info and capture_pdf tools for AI agents.

Here is the documented cURL pattern, adapted to the target URL:

Rank #4
HPE Hewlett Packard Enterprise ProLiant MicroServer Gen11 Tower Server, Intel Pentium Gold G7400 Processor, 16GB Memory, 1TB HDD Storage, External 180W US Power Supply Smart Choice P74439-005
  • MODEL P74439-005: Compact and affordable HPE ProLiant MicroServer Gen11 powered by Intel Pentium Gold G7400 3.7GHz processor, ideal for file sharing, NAS, and basic business workloads
  • READY OUT OF THE BOX: Includes 16GB DDR5 UDIMM memory (expandable to 128GB), one 1TB SATA 6G Business Critical HDD, embedded Intel VROC SATA, dedicated iLO-M.2 port kit, 180w external power adapter and 1/1/1 warranty for dependable plug-and-play server operation
  • WHISPER-QUIET & SPACE-SAVING: Ultra-compact mini tower design fits easily in small office spaces; supports wall, flat, or vertical placement for deployment flexibility
  • INTEGRATED REMOTE MANAGEMENT: Comes with HPE iLO 6 and embedded TPM 2.0 for secure, license-free remote server administration through shared port access
  • EXPANDABLE DESIGN: Two PCIe slots (including PCIe 5.0) and four LFF-NHP drive bays provide robust options for storage and component scalability. Features new MR408i-p controller support for enhanced storage performance
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://example.com -o shot.webp

See the ScreenshotNeo API documentation for request options. The Free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 screenshots. Sign up for ScreenshotNeo’s free plan.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
HP Z4 G4 Workstation, Intel Xeon W-2133 (6-Core) up to 3.9GHz, 64GB DDR4, 512GB NVMe M.2 SSD + 2TB HDD, Nvidia Quadro P400 2GB, USB 3.1, Windows 11 Pro (Renewed)
  • HP Z4 G4 Workstation Tower
  • Intel Xeon W-2133 6-Core 3.6GHz (3.9GHz Turbo)
  • 64GB DDR4 Memory - Nvidia Quadro P400 2GB
  • 512GB NVMe M.2 SSD (boot) + 2TB HDD (storage)
  • Windows 11 Pro 64-bit

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.

Leave a Reply

Your email address will not be published. Required fields are marked *

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

More from the Wire

  1. Shenzhen desk3 min
    HONOR Expands Beyond Smartphones With Humanoid Robot RevealHONOR said it unveiled its first humanoid robot at MWC 2026 and named shopping assistance, workplace inspections, and supportive companionship as intended uses. Later Robotics D1 claims and a reported…
  2. Cupertino desk5 min
    Apple Unveils AirPods Max 2: The Upgrade That Should Have Happened Years AgoAirPods Max 2 adds H2-powered audio features and Apple claims up to 1.5× more effective ANC, but its design, Smart Case, and 20-hour battery rating are unchanged. Wired lossless audio…
  3. Cupertino desk4 min
    Apple’s OLED Touch MacBooks Are Coming—but the Dynamic Island Is the Real GambleApple has not announced an OLED touchscreen MacBook, but reports point to high-end models arriving in late 2026 or early 2027. The reported Mac Dynamic Island could be useful, but…
Recommended PC Tool
Recommended PC Tool
PC Slower Than It Used to Be?Free scan - under a minute
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.