--- id: requestium version: "0.5.1" license: BSD 3-Clause License Copyright (c) 2017, Tryolabs All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following… (full text in the JSON record) license_treatment: permissive maintenance: active --- # requestium License: permissive · Maintenance: active · Downloads: 93.0K/mo ## What it is and what it does Requestium is a Python library that unifies HTTP requests, browser automation, and HTML parsing into a single session object. It lets you start with fast HTTP requests via Requests, switch to Selenium when you encounter JavaScript-heavy pages, and switch back—all while keeping cookies and session state intact. The library wraps Parsel's xpath, css, and regex methods directly onto responses, eliminating boilerplate parsing code. The core use case is web automation scripts that are mostly HTTP-based but need occasional JavaScript execution. Instead of managing two separate tools and manually syncing cookies, you work with one Session object that handles both. Requestium also adds reliability improvements to Selenium—methods like ensure_element and ensure_click reduce flakiness when selecting and interacting with dynamically loaded elements, and ensure_add_cookie handles Selenium's finicky cookie domain requirements. Use it for: - Scrape a site that loads content via AJAX by switching to Selenium only for the dynamic parts, then back to Requests for the rest. - Test web applications that mix static HTML with JavaScript-rendered content, maintaining authentication cookies across both. - Automate form submission and interaction on sites with client-side validation or dynamic element loading. - Extract data using xpath or css selectors without writing separate parsing logic for Requests vs. Selenium responses. - Develop web automation scripts incrementally by starting with Requests and adding Selenium only to the step you're currently debugging. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Requestium merges Requests, Selenium, and Parsel to automate web interactions with seamless switching between HTTP requests and browser-driven JavaScript execution while maintaining session state. Yes. Requestium is actively maintained, has low install friction, carries no known vulnerabilities, and solves a real problem—mixing HTTP and browser automation without session management headaches. It's useful even if you only use Requests or Selenium alone. The BSD license is permissive. Install it if you're automating web workflows that blend static and dynamic content. ## Install pip install requestium uv add requestium poetry add requestium ## Installing requestium Before you install: Low install friction with a pure-Python wheel. Actively maintained with recent commits and a stable release history since 2017. Requires a separate Selenium webdriver (e.g., Chromedriver) if you plan to use the browser automation features, but the library itself installs cleanly. License in practice: BSD 3-Clause License permits commercial and private use with minimal restrictions—you may use, modify, and distribute the code provided you retain the license notice and disclaimer. Quickstart: from requestium import Session s = Session(webdriver_path='./chromedriver', headless=True) title = s.get('http://example.com').xpath('//title/text()').extract_first() s.transfer_session_cookies_to_driver() s.driver.ensure_element('xpath', '//button').ensure_click() Requires a Selenium webdriver binary (e.g., Chromedriver) downloaded separately and passed via webdriver_path or driver parameter if using browser automation. Verify before relying: - Whether the library's lazy evaluation of Selenium and parsing truly eliminates overhead in practice for HTTP-only workflows. - Current compatibility with modern Selenium versions and whether all ensure_* methods work reliably across browser versions. ## Package facts - License: BSD 3-Clause License Copyright (c) 2017, Tryolabs All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following… (full text in the JSON record) (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 93.0K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags web automation requests selenium, http session with javascript execution, web scraping with dynamic content, selenium requests integration, xpath css parsing web automation, web-automation, session-management, scraping [View on SkillFed](https://skillfed.io/packages/requestium) · [View on PyPI](https://pypi.org/project/requestium/)