Session

Contains information about a single WebDriver session.

Constructor

new Session(id, capabilities)

Parameters:
NameTypeDescription
idstring

The session ID.

capabilities

Methods

getCapabilities() → (non-null) {Capabilities}

Returns:

This session's capabilities.

Type: 
Capabilities

getCapability(key) → {*}

Retrieves the value of a specific capability.

Parameters:
NameTypeDescription
keystring

The capability to retrieve.

Returns:

The capability value.

Type: 
*

getId() → {string}

Returns:

This session's ID.

Type: 
string

toJSON() → {string}

Returns the JSON representation of this object, which is just the string session ID.

Returns:

The JSON representation of this Session.

Type: 
string