$ show Vinyzu/Botright
Botright is a Python library built on Playwright that provides advanced browser automation with stealth features to evade bot detection. It includes proxy management, fingerprint spoofing using real browser profiles (chrome-fingerprints), human-like mouse movements, and CAPTCHA solving for hCaptcha, reCAPTCHA, and Geetest (though Geetest support is currently disabled). The library wraps Playwright's API with a custom layer that intercepts browser events, modifies user agent, platform, and other fingerprinting vectors, and injects anti-detection scripts. It supports both headless and headed modes, proxy rotation, and response caching. The codebase is well-structured but has commented-out modules indicating incomplete transitions (e.g., Geetest).
The LLM identified 3 files worth highlighting for reuse:
ProxyManager handles splitting proxy strings into components (ip, port, auth), validates connectivity by fetching the IP address with a fallback chain of APIs, and retrieves geographic data (country, timezone, etc.) from multiple geo-IP services. It configures Playwright proxy settings and HTTPX clients. This module is self-contained except for the `botright` reference (used for linking) and could be extracted into a standalone async proxy utility with minimal changes.
The Mouse class overrides Playwright's mouse to implement human-like click and drag trajectories using Bezier curves. The `HumanizeMouseTrajectory` class generates a curved path between two points with random internal knots, distortion, and tweening. This pattern is self-contained (only depends on `numpy` and `random`) and can be reused in any Playwright-based automation to avoid robotic cursor detection.
Faker generates a complete browser fingerprint using the `chrome-fingerprints` library (providing realistic navigator properties, screen dimensions, WebGL data) and determines locale based on proxy country via a hardcoded mapping table. It also adjusts the user-agent to match the browser version. The module is tightly coupled to the Botright class for fingerprint generator access but the locale mapping table and adjustment logic could be extracted as a standalone utility for proxy-based locale inference.