Capabilities
Capabilities are per-session settings passed with your Selenium new-session
request. Any client that can send custom capabilities works; for clients that
only allow W3C-standard capabilities, use the websummoner:options protocol
extension (see below).
Quick reference
Section titled “Quick reference”| Capability | Type | Default | What it does |
|---|---|---|---|
enableVNC | boolean | false | Expose the live browser screen over WebSocket |
screenResolution | string | 1920x1080x24 | Screen resolution, <width>x<height>x<depth> |
enableVideo | boolean | false | Record the session to an H.264 video file |
videoName | string | <session-id>.mp4 | Output video file name (keep the extension; plain file name only, no folders) |
videoScreenSize | string | screen size | Video resolution, e.g. 1024x768 (trims from top-left) |
videoFrameRate | int | 12 | Video frames per second |
videoCodec | string | libx264 | ffmpeg codec name (lower CPU alternatives exist) |
enableAudio | boolean | true | Include the audio track in recordings (set false for video-only) |
| enableLog | boolean | false | Save session log to a file |
| logName | string | <session-id>.log | Log file name (keep the extension; plain file name only, no folders) |
| name | string | — | Human-readable test name, shown in the UI |
| sessionTimeout | duration | -timeout flag | Idle timeout, e.g. 30m or 10s; capped by -max-timeout |
| timeZone | string | host time zone | IANA zone, e.g. Europe/Moscow |
| env | array | — | Extra env vars for the browser container, ["K=V"] |
| applicationContainers | array | — | Containers to link, ["name:alias"] |
| hostsEntries | array | — | Extra /etc/hosts entries, ["host:ip"] |
| dnsServers | array | Docker defaults | Custom DNS servers, ["192.168.0.1"] |
| additionalNetworks | array | -container-network | Extra Docker networks to attach |
| labels | map | — | Container labels, {"env": "testing"} |
| containerHostname | string | container ID | Custom hostname inside the container |
| s3KeyPattern | string | -s3-key-pattern | Override the S3 upload key pattern |
Session features
Section titled “Session features”Live browser screen — enableVNC
Section titled “Live browser screen — enableVNC”{ "enableVNC": true }Works with images that ship a VNC server (the VNC column of
Browser images). The screen is proxied to
http://<host>:4444/vnc/<session-id> as a WebSocket — open it via
WebSummoner UI for a
point-and-click view.
Custom screen resolution — screenResolution
Section titled “Custom screen resolution — screenResolution”{ "screenResolution": "1280x1024x24" }This sets the screen resolution, not the browser window size. Browsers
have a default window size, so screenshots can be smaller than the screen.
Resize the window explicitly in your test. Because containers run headless
browsers in Xvfb without a window manager, maximize does not work — use
setSize instead.
Video recording — enableVideo and friends
Section titled “Video recording — enableVideo and friends”{ "enableVideo": true, "videoName": "my-cool-video.mp4", "videoScreenSize": "1024x768", "videoFrameRate": 24, "videoCodec": "mpeg4", "enableAudio": false}enableAudio is true by default — recordings capture the browser’s sound
(see Recording audio). Set it to
false explicitly when you want video-only recordings (privacy, CPU or file
size reasons).
Requires a video recorder image — WebSummoner defaults to
websummoner/video-recorder:latest-release, so recording works out of the
box with the standard images. See the
Video recording guide for retrieving and deleting
files, codecs and disk planning.
Session logs — enableLog, logName
Section titled “Session logs — enableLog, logName”{ "enableLog": true, "logName": "my-cool-log.log" }To save logs for all sessions without asking per test, start WebSummoner
with -save-all-logs. See Session logs for the
retrieval API — and keep the log extension in logName.
Test name — name
Section titled “Test name — name”{ "name": "myCoolTestName" }Shown per session in the UI; makes debugging parallel runs much easier. Also added as a container label automatically.
Session environment
Section titled “Session environment”Idle timeout — sessionTimeout
Section titled “Idle timeout — sessionTimeout”{ "sessionTimeout": "30m" }Go duration format (30m, 10s, 1h5m); values above the -max-timeout
flag are clamped to it.
Time zone — timeZone
Section titled “Time zone — timeZone”{ "timeZone": "Europe/Moscow" }Any IANA zone. Without it, containers inherit the WebSummoner host time zone.
Environment variables — env
Section titled “Environment variables — env”{ "env": ["LANG=ru_RU.UTF-8", "LANGUAGE=ru:en", "LC_ALL=ru_RU.UTF-8"] }Appended to the variables set in browsers.json — useful for locale tests.
Networking
Section titled “Networking”Linked application containers — applicationContainers
Section titled “Linked application containers — applicationContainers”{ "applicationContainers": ["spring-application-main:my-cool-app", "spring-application-gateway"] }Lets tests use URLs like http://my-cool-app/ against app containers on the
same host.
Hosts entries — hostsEntries
Section titled “Hosts entries — hostsEntries”{ "hostsEntries": ["example.com:192.168.0.1", "test.com:192.168.0.2"] }Inserted before the entries from browsers.json, so capability entries
win on conflicts.
DNS servers — dnsServers
Section titled “DNS servers — dnsServers”{ "dnsServers": ["192.168.0.1", "192.168.0.2"] }Overrides the Docker daemon DNS defaults for this session’s container.
Additional networks — additionalNetworks
Section titled “Additional networks — additionalNetworks”{ "additionalNetworks": ["my-custom-net-1", "my-custom-net-2"] }Containers always join the -container-network network; add more when the
tested application lives elsewhere.
Metadata
Section titled “Metadata”Container labels — labels
Section titled “Container labels — labels”{ "labels": { "environment": "testing", "build-number": "14353" } }Useful in clusters to enrich centralized logs (environment, VCS revision,
build number). Overrides same-named labels from browsers.json.
S3 key pattern — s3KeyPattern
Section titled “S3 key pattern — s3KeyPattern”{ "s3KeyPattern": "$quota/$fileType$fileExtension" }Overrides the -s3-key-pattern flag for this session. Supported placeholders
are listed in Uploading files to S3.
Passing capabilities as protocol extensions
Section titled “Passing capabilities as protocol extensions”Some Selenium clients only accept W3C-standard capabilities. For those,
WebSummoner reads the WebDriver protocol-extensions block under the
websummoner:options key. These two requests are equivalent:
{ "browserName": "firefox", "version": "155.0.0", "screenResolution": "1280x1024x24" }{ "browserName": "firefox", "version": "154.0", "websummoner:options": { "screenResolution": "1280x1024x24" }}