8000 GitHub - guimauvedigital/kdriver: A blazing fast, coroutine-first, undetectable web scraping / browser automation library for Kotlin
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

A blazing fast, coroutine-first, undetectable web scraping / browser automation library for Kotlin

License

Notifications You must be signed in to change notification settings

guimauvedigital/kdriver

Repository files navigation

kdriver

This project is a Kotlin port of @stephanlensky's awesome Python library zendriver, built to bring the same simplicity and power of CDP-based automation to the Kotlin and Java/JVM world.

kdriver is a blazing fast, coroutine-first, undetectable web scraping / browser automation library for Kotlin. It uses the Chrome DevTools Protocol (CDP) under the hood to interact with real Chrome instances, offering a sleek alternative to heavy tools like Selenium or Puppeteer — all without relying on WebDriver.

Features

  • Undetectable – Like its Python counterpart, kdriver speaks CDP directly, making it (almost) impossible for sites to detect.
  • Blazing fast – CDP is lightweight and extremely performant. Combined with Kotlin coroutines, you get low-latency scraping and automation.
  • Simple and powerful API – Designed to get you up and running with just a few lines of idiomatic Kotlin.
  • No external dependencies – kdriver interacts directly with the browser using WebSockets and JSON — no need for Chromium wrappers or native libraries.
  • Session and cookie management – Start with a clean profile every time or load/save cookies between runs.
  • Element utilities – Coming soon: intuitive APIs to query, interact with, and wait for DOM elements.

Motivation

We chose Kotlin for this port because:

  • First-class type safety and null safety help catch bugs early and make the code more robust.
  • It's the core language of our entire stack (backends, Android apps, shared libraries).
  • Multiplatform support is on the roadmap, allowing future compatibility with native and JS targets. (Currently JVM-only)

Installation

To use kdriver, add the following to your build.gradle.kts:

dependencies {
    implementation("dev.kdriver:core:0.1.20")
}

Make sure you have Maven Central configured:

repositories {
    mavenCentral()
}

Usage

Visit a website and do something on it:

fun main() = runBlocking {
    val browser <
84D4
span class="pl-k">= Browser.create(this)
    val tab = browser.get("https://www.browserscan.net/bot-detection")
    // Use tab to interact with the page
    browser.stop()
}

More examples coming soon!

Acknowledgments

Huge thanks to @stephanlensky for creating zendriver, a brilliantly designed and maintained library that inspired this port. If you're using Python, we highly recommend checking out the original project!

Goals of the project

The purpose of kdriver is to provide a clean, coroutine-native API for browser automation in Kotlin, while staying true to the goals of zendriver:

  1. Stay undetected in modern anti-bot environments
  2. Offer a developer-friendly experience with minimal setup
  3. Empower developers with a flexible, low-level browser interface

This library is still in early development — feedback and contributions are very welcome!

Contributing

We welcome contributions of all kinds — feel free to open issues, report bugs, or submit pull requests.

About

A blazing fast, coroutine-first, undetectable web scraping / browser automation library for Kotlin

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

  •  
  •  

Packages

No packages published

Contributors 2

  •  
  •  
0