bunbot
    TypeScript icon, indicating that this package has built-in type declarations

    0.0.4 • Public • Published

    bunbot

    Desktop automation for the Bun runtime. Currently works on Mac.

    npm (tag) NPM

    Requirements

    Bunbot uses RobotGo via bun:ffi. Please see RobotGo's requirements here.

    Usage

    bun add bunbot

    Mouse

    import Bunbot from 'bunbot'
    
    const bb = new Bunbot()
    
    // Click
    bb.click()
    // Get mouse position coordinates
    const mousePosition = bb.getMousePosition()
    // Move mouse
    bb.moveMouse(200, 400)
    // Move mouse smoothly
    bb.moveMouseSmooth(200, 400)
    // Scroll mouse
    bb.scrollMouse(100, 200)

    Keyboard

    import Bunbot from 'bunbot'
    
    const bb = new Bunbot()
    
    // Type a string
    bb.type('Hello world!')
    // Tap a key
    bb.tap('i', 'alt', 'command')

    Screen

    import Bunbot from 'bunbot'
    
    const bb = new Bunbot()
    
    // Get screen size
    const screenSize = bb.getScreenSize()
    // Get mouse pos's color
    const color = bb.getMousePositionColor()
    // Get scale size
    const scaleSize = bb.getScaleSize()

    License

    MIT

    Install

    npm i bunbot

    DownloadsWeekly Downloads

    6

    Version

    0.0.4

    License

    MIT

    Unpacked Size

    6.93 MB

    Total Files

    10

    Last publish

    Collaborators

    • wobsoriano