-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Define on a shared user facing API for BiDi and CDP #8168
Comments
A use-csae of CDP used API I have is to add JS snippet to be executed on every new page load. In current Ruby this is done in the following way: driver.devtools.page.enable
driver.devtools.page.add_script_to_evaluate_on_new_document('my javascript code string') I'm not sure how Selenium API for it might look like. |
After discussion in the #selenium-tlc slack channel, the current suggestion is for me to put together some strawman APIs to feed the design process. |
After discussion in the #selenium-tlc slack channel, the API will essentially be a user-facing API for WebDriver BiDi so we can draft based on its scenarios from https://github.com/w3c/webdriver/blob/master/webdriver-bidi/webdriver.md#goals:
I'll turn this list into a checklist and pin to the issue so that we can track the work. |
Listen out for js errors: d6c10c6 |
The following work remains on the Java bindings:
|
One more use case (which is actually as subset of "intercept network requests," but current implementations do not do this): Get response information before page is displayed in the browser. This is to solve for the "get the HTTP status code" use case. I will refrain from editorializing on the usefulness of this use case. |
Can I propose adding the use case of setting cookies on a domain you aren't on? I'd like to be able to authenticate a user with an API, and set the resulting token value in a cookie so I can navigate to a specific page. Right now I have to navigate to the domain first (which isn't always possible with domain redirects). |
I think we now have these in all the language bindings. Closing. We can always add more use-cases if we need to. |
🚀 Feature Proposal
We'd like to define a shared user-facing API that users can interact with when using bi-directional WebDriver API. Until the standard is delivered, this API is likely to be backed by CDP.
Motivation
See https://github.com/w3c/webdriver-bidi/blob/master/proposals/core.md for more details. The API should focus on satisfying the following use cases:
Event-based use cases:
Other use cases:
Example
Read the issue comments for examples.
The text was updated successfully, but these errors were encountered: