ssserver

command module
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2025 License: MIT Imports: 18 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

Web screenshot server

CircleCI Go Report Card

Install the command with:

$ go install github.com/koron/ssserver@latest

Assure to install Chrome and Chrome driver.

Then start the server, it listen 3000 on localhost.

$ ssserver

Run these command from other terminal or console to obtain screenshots.

$ curl -v http://127.0.0.1:3000/?u=https://www.kaoriya.net/ -o kaoriya.png
$ curl -v http://127.0.0.1:3000/?u=http://tokyo-ame.jwa.or.jp/ -o ame.png

Requirements

These tools are required to make ssserver work correctly.

Install those to anywhere in you PATH environment variable.

Request Parameters

Name Description
u URL to take a screenshot (mandatory)
w Width of screenshot (default: 1024)
h Height of screenshot (default: 768)
wait Wait before take a screenshot (default: 0, see Duration)
sX Scroll offset X (default: 0)
sY Scroll offset Y (default: 0)
full Full page screenshot. Ignore h, sX and sY when set.
save Show save as dialog in browser. Imply Content-Disposition: attachment

Server Options

Name Description
-addr Server listen address (default: ":3000")
-driver WebDriver name (default: "chrome")
-maxpages Max number of browser instances (default: 4)
-v Verbose logging

Examples

Full page screenshot:

$ curl -v 'http://127.0.0.1:3000/?u=https://www.kaoriya.net/&full' -o kaoriya-full.png

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址