WebLair Async:
Browser Control Functions
start_chromium(url=None, headless=False, **kwargs)
Starts a Chromium browser instance
Returns a Page object
Optional URL to navigate to
Configurable headless mode and additional options
start_firefox(url=None, headless=False, **kwargs)
Starts a Firefox browser instance
Similar to start_chromium but for Firefox
go_to(url, page=None)
Navigates to a specified URL
Automatically adds 'http://' if protocol not specified
kill_browser(page=None)
Closes the browser and cleans up resources
Resets browser manager state
Interaction Functions
write(text, page=None, into=None)
Types text into fields
Can target specific field by label or placeholder
Works with focused element if no target specified
click(element, page=None)
Clicks on elements identified by text, Point, or element reference
Works with buttons, links, and any clickable elements
press(key, page=None)
Simulates keyboard key press
Works with Keys class constants (ENTER, TAB, etc.)
hover(element, page=None)
Moves mouse over specified element
Accepts text, element handle, or locator
scroll_to(element, page=None)
Scrolls element into view
Works with text or element references
Element Classes
Button(text=None, page=None)
Methods:
exists(): Checks if button exists
is_enabled(): Checks if button is enabled
TextField(label=None, page=None)
Methods:
exists(): Checks if field exists
value(): Gets current text value
type(text): Types text into field
Link(text=None, page=None)
Methods:
exists(): Checks if link exists
href(): Gets link URL
Alert(page=None)
Methods:
accept(): Accepts dialog
dismiss(): Dismisses dialog
text(): Gets alert message
Helper Classes
Point(x, y)
Represents screen coordinates
Supports addition/subtraction for offset calculations
Keys
Constants for keyboard keys
Examples: ENTER, TAB, ESCAPE, etc.
Config
Configuration settings
Properties:
implicit_wait_secs
browser_type
default_timeout
screenshot_dir
viewport_size
Utility Functions
find_all(element_type, page=None)
Finds all elements of specified type (Button, TextField, Link)
Returns list of elements
wait_until(condition_fn, timeout=None, page=None)
Waits for condition to be true
Supports both sync and async conditions
Configurable timeout
attach_file(file_path, to=None, page=None)
Handles file uploads
Can target specific file input
get_text(element, page=None)
Gets text content of element
Works with various element types
take_screenshot(path, full_page=False, page=None)
Captures screenshot
Optional full page capture
Raw data
{
"_id": null,
"home_page": "https://github.com/santhosh/",
"name": "weblair",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.10",
"maintainer_email": null,
"keywords": null,
"author": "Kammari Santhosh",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/36/a7/fcfac015d8f7fa190ebe91c394234068d6ee240e2c6291d5e65ffe63af89/weblair-0.0.11.tar.gz",
"platform": null,
"description": "WebLair Async:\n\nBrowser Control Functions\n\nstart_chromium(url=None, headless=False, **kwargs)\n\nStarts a Chromium browser instance\nReturns a Page object\nOptional URL to navigate to\nConfigurable headless mode and additional options\n\n\nstart_firefox(url=None, headless=False, **kwargs)\n\nStarts a Firefox browser instance\nSimilar to start_chromium but for Firefox\n\n\ngo_to(url, page=None)\n\nNavigates to a specified URL\nAutomatically adds 'http://' if protocol not specified\n\n\nkill_browser(page=None)\n\nCloses the browser and cleans up resources\nResets browser manager state\n\n\n\nInteraction Functions\n\nwrite(text, page=None, into=None)\n\nTypes text into fields\nCan target specific field by label or placeholder\nWorks with focused element if no target specified\n\n\nclick(element, page=None)\n\nClicks on elements identified by text, Point, or element reference\nWorks with buttons, links, and any clickable elements\n\n\npress(key, page=None)\n\nSimulates keyboard key press\nWorks with Keys class constants (ENTER, TAB, etc.)\n\n\nhover(element, page=None)\n\nMoves mouse over specified element\nAccepts text, element handle, or locator\n\n\nscroll_to(element, page=None)\n\nScrolls element into view\nWorks with text or element references\n\n\n\nElement Classes\n\nButton(text=None, page=None)\n\nMethods:\n\nexists(): Checks if button exists\nis_enabled(): Checks if button is enabled\n\n\n\n\nTextField(label=None, page=None)\n\nMethods:\n\nexists(): Checks if field exists\nvalue(): Gets current text value\ntype(text): Types text into field\n\n\n\n\nLink(text=None, page=None)\n\nMethods:\n\nexists(): Checks if link exists\nhref(): Gets link URL\n\n\n\n\nAlert(page=None)\n\nMethods:\n\naccept(): Accepts dialog\ndismiss(): Dismisses dialog\ntext(): Gets alert message\n\n\n\n\n\nHelper Classes\n\nPoint(x, y)\n\nRepresents screen coordinates\nSupports addition/subtraction for offset calculations\n\n\nKeys\n\nConstants for keyboard keys\nExamples: ENTER, TAB, ESCAPE, etc.\n\n\nConfig\n\nConfiguration settings\nProperties:\n\nimplicit_wait_secs\nbrowser_type\ndefault_timeout\nscreenshot_dir\nviewport_size\n\n\n\n\n\nUtility Functions\n\nfind_all(element_type, page=None)\n\nFinds all elements of specified type (Button, TextField, Link)\nReturns list of elements\n\n\nwait_until(condition_fn, timeout=None, page=None)\n\nWaits for condition to be true\nSupports both sync and async conditions\nConfigurable timeout\n\n\nattach_file(file_path, to=None, page=None)\n\nHandles file uploads\nCan target specific file input\n\n\nget_text(element, page=None)\n\nGets text content of element\nWorks with various element types\n\n\ntake_screenshot(path, full_page=False, page=None)\n\nCaptures screenshot\nOptional full page capture\n\n\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "agents based on pyautogui",
"version": "0.0.11",
"project_urls": {
"Homepage": "https://github.com/santhosh/",
"Repository": "https://github.com/santhosh/"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "28096b7cfe8b22b0c61d69e2aa2a1570916380843e04d02816fbf76ffbb4e9c0",
"md5": "6806b3a207d2c269eae2bb48be40c1a1",
"sha256": "cd9fcbb5a445cb8b920903e68b02462abf4a651c085a4cfdaa15f133057def8c"
},
"downloads": -1,
"filename": "weblair-0.0.11-py3-none-any.whl",
"has_sig": false,
"md5_digest": "6806b3a207d2c269eae2bb48be40c1a1",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.10",
"size": 17569,
"upload_time": "2025-02-16T03:09:27",
"upload_time_iso_8601": "2025-02-16T03:09:27.707286Z",
"url": "https://files.pythonhosted.org/packages/28/09/6b7cfe8b22b0c61d69e2aa2a1570916380843e04d02816fbf76ffbb4e9c0/weblair-0.0.11-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "36a7fcfac015d8f7fa190ebe91c394234068d6ee240e2c6291d5e65ffe63af89",
"md5": "2f1b45173891848e68d57d6323ee89fc",
"sha256": "de8dcf11439f9e2098404ed245fed2931b1b80e147960e929356ae8b13f6a246"
},
"downloads": -1,
"filename": "weblair-0.0.11.tar.gz",
"has_sig": false,
"md5_digest": "2f1b45173891848e68d57d6323ee89fc",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.10",
"size": 16764,
"upload_time": "2025-02-16T03:09:29",
"upload_time_iso_8601": "2025-02-16T03:09:29.933371Z",
"url": "https://files.pythonhosted.org/packages/36/a7/fcfac015d8f7fa190ebe91c394234068d6ee240e2c6291d5e65ffe63af89/weblair-0.0.11.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-02-16 03:09:29",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "weblair"
}