The WebDriver API is a platform and language-neutral interface and wire protocol allowing programs or scripts to control the behavior of a web browser. The Microsoft Edge implementation of WebDriver supports commands from both the W3C WebDriver Specification and the JSON Wire Protocol. Here’s how to get started with WebDriver for Microsoft Edge.
WebDriver Server Command Line Flags
List of command line flags for the WebDriver server.
| Name | Description | Available Release |
|---|---|---|
| host | Host IP to use for the WebDriver server (default: localhost) | 14393 |
| port | Port to use for the WebDriver server (default: 17556) | 14393 |
| package | ApplicationUserModelId (AUMID) for the application to be launched by the WebDriver server | 14393 |
| verbose | Outputs requests received and responses sent by the WebDriver server | 14393 |
| silent | Outputs nothing | Insiders |
W3C WebDriver Specification Support
The support on a per command basis for the W3C WebDriver Specification.
| Locator Strategies | Status | Available Release |
|---|---|---|
| CSS selector | Supported | 10240 |
| Link text selector | Supported | 10240 |
| Partial link text selector | Supported | 10240 |
| XPath selector | Supported | 10586 |
| Method | URI Template | Command | Status | Available Release/Priority |
|---|---|---|---|---|
| POST | /session | New Session | Supported | 10240 |
| DELETE | /session/{session id} | Delete Session | Supported | 10240 |
| GET | /status | Status | Supported | 10240 |
| GET | /session/{session id}/timeouts | Get Timeouts | Not Supported | Priority 3 |
| POST | /session/{session id}/timeouts | Set Timeouts | Supported | 10240 |
| POST | /session/{session id}/url | Go | Supported | 10240 |
| GET | /session/{session id}/url | Get Current URL | Supported | 10240 |
| POST | /session/{session id}/back | Back | Supported | 10240 |
| POST | /session/{session id}/forward | Forward | Supported | 10240 |
| POST | /session/{session id}/refresh | Refresh | Supported | 10240 |
| GET | /session/{session id}/title | Get Title | Supported | 10240 |
| GET | /session/{session id}/window | Get Window Handle | Supported | Insiders |
| DELETE | /session/{session id}/window | Close Window | Supported | 10586 |
| POST | /session/{session id}/window | Switch to Window | Supported | 10586 |
| GET | /session/{session id}/window/handles | Get Window Handles | Supported | Insiders |
| POST | /session/{session id}/frame | Switch To Frame | Supported | 10586 |
| POST | /session/{session id}/frame/parent | Switch to Parent Frame | Supported | 10586 |
| GET | /session/{session id}/window/rect | Get Window Rect | Not Supported | Priority 3 |
| POST | /session/{session id}/window/rect | Set Window Rect | Not Supported | Priority 3 |
| POST | /session/{session id}/window/maximize | Maximize Window | Not Supported | Priority 3 |
| POST | /session/{session id}/window/minimize | Minimize Window | Not Supported | Priority 3 |
| POST | /session/{session id}/window/fullscreen | Fullscreen Window | Not Supported | Priority 4 |
| GET | /session/{session id}/element/active | Get Active Element | Supported | 10586 |
| POST | /session/{session id}/element | Find Element | Supported | 10586 |
| POST | /session/{session id}/elements | Find Elements | Supported | 10586 |
| POST | /session/{session id}/element/{element id}/element | Find Element From Element | Supported | 10586 |
| POST | /session/{session id}/element/{element id}/elements | Find Elements From Element | Supported | 10586 |
| GET | /session/{session id}/element/{element id}/selected | Is Element Selected | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/attribute/{name} | Get Element Attribute | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/property/{name} | Get Element Property | Not Supported | Priority 2 |
| GET | /session/{session id}/element/{element id}/css/{property name} | Get Element CSS Value | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/text | Get Element Text | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/name | Get Element Tag Name | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/rect | Get Element Rect | Supported | 10586 |
| GET | /session/{session id}/element/{element id}/enabled | Is Element Enabled | Supported | 10240 |
| POST | /session/{session id}/element/{element id}/click | Element Click | Supported | 10240 |
| POST | /session/{session id}/element/{element id}/clear | Element Clear | Supported | 10240 |
| POST | /session/{session id}/element/{element id}/sendKeys | Element Send Keys | Not Supported | Priority 2 |
| GET | /session/{session id}/source | Get Page Source | Supported | 10586 |
| POST | /session/{session id}/execute/sync | Execute Script | Supported | Insiders |
| POST | /session/{session id}/execute/async | Execute Async Script | Supported | Insiders |
| GET | /session/{session id}/cookie | Get All Cookies | Supported | 10240 |
| GET | /session/{session id}/cookie/{name} | Get Named Cookie | Supported | 10240 |
| POST | /session/{session id}/cookie | Add Cookie | Supported | 10240 |
| DELETE | /session/{session id}/cookie/{name} | Delete Cookie | Supported | 10240 |
| DELETE | /session/{session id}/cookie | Delete All Cookies | Supported | 10586 |
| POST | /session/{session id}/actions | Perform Actions | Not Supported | Priority 3 |
| DELETE | /session/{session id}/actions | Release Actions | Not Supported | Priority 3 |
| POST | /session/{session id}/alert/dismiss | Dismiss Alert | Supported | Insiders |
| POST | /session/{session id}/alert/accept | Accept Alert | Supported | Insiders |
| GET | /session/{session id}/alert/text | Get Alert Text | Supported | Insiders |
| POST | /session/{session id}/alert/text | Send Alert Text | Supported | Insiders |
| GET | /session/{session id}/screenshot | Take Screenshot | Supported | 10240 |
| GET | /session/{session id}/element/{element id}/screenshot | Take Element Screenshot | Supported | 10240 |
JSON Wire Protocol Support
The support on a per command basis for the JSON Wire Protocol.