### Install Node.js on macOS Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Installs Homebrew if not present, then installs Node.js using Homebrew. Ensures Node.js is available for Vibium. ```bash # Install Homebrew (if you don't have it) /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" # Install Node brew install node ``` -------------------------------- ### Verify Node.js and npm Installation Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Checks the installed versions of Node.js and npm. Verifies that the installation meets the minimum requirements for Vibium. ```bash node --version # Should show v18.0.0 or higher npm --version # Should show 9.0.0 or higher ``` -------------------------------- ### Vibium Python Client Setup Source: https://github.com/vibiumdev/vibium/blob/main/CONTRIBUTING.md Details the setup process for the Vibium Python client, including creating and activating a virtual environment and performing an editable install for local development. It also provides the command to install from PyPI. ```bash # For local development: cd clients/python python -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate pip install -e . # Editable install - code changes take effect immediately # Or install from PyPI: pip install vibium ``` -------------------------------- ### JavaScript Clicker Process Start Example (TypeScript) Source: https://github.com/vibiumdev/vibium/blob/main/docs/reference/v1-roadmap.md An example demonstrating how to use the `ClickerProcess` class to start the `clicker serve` command in the background. It logs the discovered port and then stops the process. This showcases the basic lifecycle management of the server process from JavaScript. ```TypeScript import { ClickerProcess } from './clicker/process'; async function main() { try { const proc = await ClickerProcess.start(); console.log(`Clicker server started on port: ${proc.port}`); // Keep the server running for a bit or until some condition is met await new Promise(resolve => setTimeout(resolve, 5000)); // Keep running for 5 seconds await proc.stop(); console.log('Clicker server stopped.'); } catch (error) { console.error('Failed to start or manage Clicker process:', error); } } main(); ``` -------------------------------- ### Install Vibium Package Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Installs the Vibium library and its dependencies, including Chrome for Testing, into the project's node_modules folder. ```bash npm install vibium ``` -------------------------------- ### Install Go using winget Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-windows.md Installs the Go programming language (Golang) using the winget package manager. After installation, it is recommended to restart the terminal and verify the installation using the `go version` command. ```powershell winget install GoLang.Go ``` -------------------------------- ### Vibium Python Client Quick Start (Sync API) Source: https://github.com/vibiumdev/vibium/blob/main/docs/updates/2025-12-31-python-client.md A basic example demonstrating the synchronous API of the Vibium Python client. It shows how to launch a browser, navigate to a URL, find an element, print its text, click it, and then close the browser. ```python from vibium import browser_sync vibe = browser_sync.launch() vibe.go("https://example.com") link = vibe.find("a") print(link.text()) link.click() vibe.quit() ``` -------------------------------- ### Setup Linux ARM VM for Testing Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-mac.md Installs essential development tools including Git, cURL, Wget, build essentials, Go, and Node.js (via NVM) on a Linux ARM VM. Also installs `ripgrep` and `jq`. ```bash # Update system sudo apt update && sudo apt upgrade -y # Install dev tools sudo apt install -y git curl wget build-essential # Install Go wget https://go.dev/dl/go1.23.4.linux-arm64.tar.gz sudo tar -C /usr/local -xzf go1.23.4.linux-arm64.tar.gz echo 'export PATH=$PATH:/usr/local/go/bin' >> ~/.bashrc source ~/.bashrc # Install Node.js (via nvm) curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash source ~/.bashrc nvm install --lts # Install other tools sudo apt install -y ripgrep jq ``` -------------------------------- ### Vibium Python Client Quick Start (Async API) Source: https://github.com/vibiumdev/vibium/blob/main/docs/updates/2025-12-31-python-client.md An example showcasing the asynchronous API of the Vibium Python client. This code demonstrates launching a browser, navigating to a URL, and closing the browser using async/await syntax. ```python import asyncio from vibium import browser async def main(): vibe = await browser.launch() await vibe.go("https://example.com") await vibe.quit() asyncio.run(main()) ``` -------------------------------- ### Create Vibium Project and Initialize npm Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Creates a new directory for the project and initializes a Node.js project using npm, generating a package.json file. ```bash mkdir my-first-bot cd my-first-bot npm init -y ``` -------------------------------- ### Install Node.js on Linux (Ubuntu/Debian) Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Installs Node.js version 20.x using NodeSource repository and apt-get. This provides the necessary environment for Vibium. ```bash # Ubuntu/Debian curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash - sudo apt-get install -y nodejs ``` -------------------------------- ### Python Client Installation and Basic Usage Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/python-client.md Demonstrates how to install the Vibium Python client using pip and provides a basic example of launching a browser, navigating to a URL, and quitting. It highlights the auto-download feature for Chrome if it's not found. ```bash pip install vibium vibium install # Optional: pre-download Chrome ``` ```python from vibium import browser_sync vibe = browser_sync.launch() # Auto-downloads Chrome if needed vibe.go("https://example.com") vibe.quit() ``` -------------------------------- ### Run Vibium Script Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Executes the 'hello.js' script using Node.js. This will launch a browser, perform the automated actions, and generate a screenshot. ```bash node hello.js ``` -------------------------------- ### Enable and Start SSH Server on Host Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Installs the OpenSSH server, enables it to start on boot, and starts the service. It also provides a command to retrieve the host's IP address, which is useful for remote access to the VM. ```bash sudo apt install -y openssh-server sudo systemctl enable ssh sudo systemctl start ssh # Get IP address ip addr show | grep inet ``` -------------------------------- ### Install Vibium Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Installs the Vibium Python package using pip. This command also downloads the necessary clicker binary for your operating system. Optionally, you can pre-download Chrome. ```bash pip install vibium vibium install ``` -------------------------------- ### Vibium Sync API Quick Start Source: https://github.com/vibiumdev/vibium/blob/main/packages/vibium/README.md Illustrates the synchronous API for browser automation with Vibium. This example shows launching a browser, navigating, element interaction, capturing a screenshot, and closing the browser using synchronous methods. It requires importing 'browserSync' from 'vibium' and 'writeFileSync' from 'fs'. ```javascript import { browserSync } from 'vibium' import { writeFileSync } from 'fs' // In a REPL: const { browserSync } = require('vibium') // In a REPL: const { writeFileSync } = require('fs') const vibe = browserSync.launch() vibe.go('https://example.com') const link = vibe.find('a') console.log(link.text()) link.click() const screenshot = vibe.screenshot() writeFileSync('screenshot.png', screenshot) vibe.quit() ``` -------------------------------- ### Create Vibium Script - macOS/Linux Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Creates an empty file named 'hello.js' in the current directory using the touch command. ```bash # macOS/Linux touch hello.js ``` -------------------------------- ### Install Vibium Dependencies on Linux Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Installs essential libraries required for running Chrome in a Linux environment, often needed to resolve 'permission denied' errors or browser launch issues. ```bash sudo apt-get install -y libgbm1 libnss3 libatk-bridge2.0-0 libdrm2 libxkbcommon0 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libgbm1 libasound2 ``` -------------------------------- ### Install and Configure OpenSSH Server on Windows Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-windows.md These commands install the OpenSSH server feature, start the SSH service, set it to start automatically on boot, and configure PowerShell as the default shell for SSH connections. This enables remote access to the Windows machine via SSH. ```powershell # Run as Administrator Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0 Start-Service sshd Set-Service -Name sshd -StartupType Automatic # Set PowerShell as default SSH shell New-ItemProperty -Path "HKLM:\SOFTWARE\OpenSSH" -Name DefaultShell -Value "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -PropertyType String -Force ``` -------------------------------- ### NPM Install and Verification Script Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/V1-MILESTONE-12.2.md Bash script demonstrating how to install the Vibium NPM package locally from a tarball and verify its functionality by running the 'npx vibium' command, which should start the MCP server. ```bash npm install ./packages/vibium/vibium-0.1.0.tgz npx vibium # Should start MCP server ``` -------------------------------- ### Create Project Folder and Virtual Environment Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Sets up a new project directory, creates a Python virtual environment named '.venv', and activates it. This isolates project dependencies. ```bash mkdir my-first-bot cd my-first-bot python3 -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate ``` -------------------------------- ### Install Utility Tools and GitHub CLI Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Installs command-line utility tools like ripgrep and jq. It also sets up the GitHub CLI by adding its APT repository and then installing the 'gh' package. ```bash sudo apt install -y ripgrep jq # GitHub CLI curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null sudo apt update sudo apt install -y gh ``` -------------------------------- ### Install Development Tools using winget Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-windows.md This snippet demonstrates installing several essential development tools for the Vibium project using the Windows Package Manager (winget). It includes Git, GitHub CLI, ripgrep, and jq. A terminal restart is recommended after installing Git. ```powershell winget install Git.Git winget install GitHub.cli winget install BurntSushi.ripgrep.MSVC winget install jqlang.jq ``` -------------------------------- ### Python Client Testing Setup and Execution Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/python-client.md Details the steps required to set up a testing environment for the Vibium Python client, including creating a virtual environment, installing platform-specific packages, and running a sample test script. ```bash cd clients/python python3 -m venv .venv source .venv/bin/activate pip install -e ../../packages/python/vibium_darwin_arm64 pip install -e . python3 -c " from vibium import browser_sync vibe = browser_sync.launch() vibe.go('https://example.com') print(vibe.find('a').text()) vibe.quit() " ``` -------------------------------- ### Vibium Script with Async/Await Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Demonstrates using async/await syntax with Vibium's browser object for more complex or sequential asynchronous operations. Requires Node.js 8.0.0 or higher. ```javascript const { browser } = require('vibium') async function main() { const vibe = await browser.launch() await vibe.go('https://example.com') // ... await vibe.quit() } main() ``` -------------------------------- ### Install Go Programming Language Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Downloads and installs Go version 1.23.4 for Linux amd64. It extracts the archive to /usr/local, adds the Go binary directory to the PATH in ~/.bashrc, and sources the file to apply changes. Finally, it verifies the installation. ```bash wget https://go.dev/dl/go1.23.4.linux-amd64.tar.gz sudo tar -C /usr/local -xzf go1.23.4.linux-amd64.tar.gz rm go1.23.4.linux-amd64.tar.gz echo 'export PATH=$PATH:/usr/local/go/bin' >> ~/.bashrc source ~/.bashrc go version ``` -------------------------------- ### Create Vibium Script - Windows PowerShell Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Creates an empty file named 'hello.js' in the current directory using the New-Item cmdlet. ```powershell # Windows (PowerShell) New-Item hello.js ``` -------------------------------- ### Setup Publishing Environment (Bash) Source: https://github.com/vibiumdev/vibium/blob/main/docs/how-to-guides/pypi-publishing.md Sets up a virtual environment for publishing and installs the necessary 'twine' package. This ensures a clean and isolated environment for the publishing process. ```bash python3 -m venv .venv-publish source .venv-publish/bin/activate pip install twine ``` -------------------------------- ### Chrome for Testing Installer CLI Source: https://github.com/vibiumdev/vibium/blob/main/docs/reference/v1-roadmap.md Implements the browser installer logic in Go, fetching Chrome for Testing and chromedriver, downloading, extracting, and caching them. The CLI command 'clicker install' handles this process, respecting an environment variable to skip downloads. ```bash ./bin/clicker install # Downloads Chrome for Testing + chromedriver # Check platform cache (Linux example): ls ~/.cache/vibium/chrome-for-testing/ # Should show version folder with chrome and chromedriver binaries ``` -------------------------------- ### Install Node.js LTS using winget Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-windows.md Installs the Long-Term Support (LTS) version of Node.js using the winget package manager. After installation, a terminal restart and verification using `node --version` and `npm --version` are recommended. ```powershell winget install OpenJS.NodeJS.LTS ``` -------------------------------- ### Install Node.js via NVM Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Installs Node Version Manager (nvm) using a curl script, sources the ~/.bashrc file to make nvm available, installs the latest LTS version of Node.js, and displays the installed versions of Node.js and npm. ```bash curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash source ~/.bashrc nvm install --lts node --version npm --version ``` -------------------------------- ### CLI - Start Proxy Server Source: https://context7.com/vibiumdev/vibium/llms.txt Starts the WebSocket BiDi proxy server, enabling direct WebSocket connections for automation. ```APIDOC ## CLI - Start Proxy Server ### Description Start the WebSocket BiDi proxy server for direct WebSocket connections. ### Method CLI command ### Endpoint N/A ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Command Example ```bash clicker serve clicker serve --port 9516 clicker serve --verbose ``` ### Response #### Success Response - **Output**: (string) - Confirmation of the proxy server listening and connection details. #### Response Example ``` Vibium proxy listening on :9515 Connect via WebSocket: ws://localhost:9515 Vibium proxy listening on :9516 [DEBUG] Starting proxy server... [INFO] Vibium proxy listening on :9515 ``` ``` -------------------------------- ### Enable and Start SSH Service Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Enables the SSH service to start automatically on boot and starts the service immediately. Also includes a command to display network interfaces and retrieve the VM's IP address. ```bash sudo systemctl enable ssh sudo systemctl start ssh # Get VM IP ip addr show | grep inet ``` -------------------------------- ### Install Python (macOS) Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Installs Python 3 on macOS using Homebrew. Ensure Homebrew is installed first. This step is necessary if your Python version is below 3.9. ```bash # Install Homebrew (if you don't have it) /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" # Install Python brew install python ``` -------------------------------- ### Install Python (Linux) Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Installs Python 3 and pip on Debian/Ubuntu based Linux distributions. For other distributions, use their respective package managers. Requires Python 3.9+. ```bash # Ubuntu/Debian sudo apt-get install python3 python3-pip python3-venv # Or use your distro's package manager ``` -------------------------------- ### Build and Test Vibium Clicker Application Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Navigates to the Vibium clicker project directory, builds the application using Go, and then executes various commands to check the version, list paths, install, and launch a test. ```bash cd ~/Projects/vibium/clicker go build -o bin/clicker ./cmd/clicker ./bin/clicker --version ./bin/clicker paths ./bin/clicker install ./bin/clicker launch-test ``` -------------------------------- ### Install QEMU/KVM and Virt-Manager on Ubuntu Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Installs the necessary virtualization software (QEMU/KVM) and management tools (virt-manager) on an Ubuntu host system. It also adds the current user to the 'libvirt' and 'kvm' groups for proper permissions. Log out and back in for changes to take effect. ```bash sudo apt update sudo apt install -y qemu-kvm libvirt-daemon-system libvirt-clients bridge-utils virt-manager sudo usermod -aG libvirt $USER sudo usermod -aG kvm $USER # Log out and back in for group changes to take effect ``` -------------------------------- ### Troubleshoot Vibium Installation (Linux) Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Installs necessary Chrome dependencies on Linux systems to resolve potential 'Permission denied' errors when running Vibium. This ensures the browser can launch correctly. ```bash sudo apt-get install -y libgbm1 libnss3 libatk-bridge2.0-0 libdrm2 libxkbcommon0 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libasound2 ``` -------------------------------- ### Command-Line Usage Examples for Vibium Logging Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/V1-MILESTONE-11-2.md Demonstrates how to use the implemented logging features from the command line for both Go and JavaScript components of the Vibium project. It shows examples of quiet and verbose logging. ```bash # Go - quiet by default ./bin/clicker navigate https://example.com # Go - verbose ./bin/clicker navigate https://example.com -v # JS - quiet by default node script.js # JS - verbose VIBIUM_DEBUG=1 node script.js ``` -------------------------------- ### Quick Start Vibium Python Client Source: https://github.com/vibiumdev/vibium/blob/main/clients/python/README.md Demonstrates basic usage of the Vibium Python client for launching a browser, navigating to a URL, taking a screenshot, finding and interacting with elements, and closing the browser. ```python from vibium import browser_sync vibe = browser_sync.launch() vibe.go("https://example.com") # Take a screenshot png = vibe.screenshot() with open("screenshot.png", "wb") as f: f.write(png) # Find and click a link link = vibe.find("a") print(link.text()) link.click() vibe.quit() ``` -------------------------------- ### Install Claude Code package via npm Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-windows.md Installs the Claude Code package globally using npm, the Node Package Manager. This package is part of the setup for AI-assisted coding within the development environment. ```bash npm install -g @anthropic-ai/claude-code ``` -------------------------------- ### Start WebSocket Server and Connect (Bash) Source: https://github.com/vibiumdev/vibium/blob/main/docs/reference/v1-roadmap.md Starts the BiDi proxy WebSocket server in the background and then connects to it using `websocat`. This allows for manual interaction with the server to test its responsiveness. ```Bash #!/bin/bash ./bin/clicker serve & websocat ws://localhost:9515 ``` -------------------------------- ### Launch Vibium Browser with Headless Option Source: https://github.com/vibiumdev/vibium/blob/main/packages/vibium/README.md Demonstrates how to launch a new browser session using Vibium's `browser.launch` method. The example shows how to pass an options object to configure the browser, specifically setting `headless` to `true` to run the browser without a visible window. This is useful for server-side automation. ```javascript const vibe = await browser.launch({ headless: true }) ``` -------------------------------- ### Install Essential Development Tools Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-x86-linux.md Updates the package list and upgrades existing packages, then installs essential development tools such as Git, cURL, Wget, and build utilities. ```bash # Update system sudo apt update && sudo apt upgrade -y # Install essentials sudo apt install -y git curl wget build-essential openssh-server ``` -------------------------------- ### Vibium Script with Headless Mode Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Launches Vibium in headless mode, meaning the browser window will not be visible. Useful for running automation on servers or in the background. ```javascript const vibe = browserSync.launch({ headless: true }) ``` -------------------------------- ### Vibium Async/Await Usage Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Demonstrates how to use Vibium with Python's async/await syntax for more complex and efficient asynchronous operations. Requires Python 3.7+. ```python import asyncio from vibium import browser async def main(): vibe = await browser.launch() await vibe.go("https://example.com") # ... await vibe.quit() asyncio.run(main()) ``` -------------------------------- ### CLI Commands for Browser Automation (Bash) Source: https://github.com/vibiumdev/vibium/blob/main/docs/updates/2025-12-16-week1-progress.md Demonstrates various command-line interface commands for the 'clicker' Go binary to perform browser automation tasks. Includes examples for taking screenshots, finding elements, clicking, and typing into inputs. Also lists debugging flags. ```bash # take a screenshot clicker screenshot https://example.com -o shot.png # find an element clicker find https://example.com "a" → tag=A, text="Learn more", box={x:151, y:151, w:82, h:18} # click a link clicker click https://example.com "a" → navigates to iana.org # type into an input clicker type https://the-internet.herokuapp.com/inputs "input" "12345" ``` -------------------------------- ### Install Core Development Languages Source: https://github.com/vibiumdev/vibium/blob/main/docs/local-dev-setup-mac.md Installs essential programming languages and runtime environments including Node.js (via nvm), Python, and Go using Homebrew. ```bash brew install nvm node python go ``` -------------------------------- ### Vibium Headless Mode Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Launches the browser in headless mode, meaning no graphical interface will be shown. This is useful for running automated tasks on servers or in environments without a display. ```python from vibium import browser vibe = browser.launch(headless=True) ``` -------------------------------- ### Vibium Basic Browser Automation Script Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started.md Launches a browser, navigates to a URL, takes a screenshot, finds and clicks a link, and then closes the browser. Demonstrates core Vibium functionalities. ```javascript const fs = require('fs') const { browserSync } = require('vibium') // Launch a browser (you'll see it open!) const vibe = browserSync.launch() // Go to a website vibe.go('https://example.com') console.log('Loaded example.com') // Take a screenshot const png = vibe.screenshot() fs.writeFileSync('screenshot.png', png) console.log('Saved screenshot.png') // Find and click the link const link = vibe.find('a') console.log('Found link:', link.text()) link.click() console.log('Clicked!') // Close the browser vibe.quit() console.log('Done!') ``` -------------------------------- ### Vibium npx Entry Point Script (bin.js) Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/V1-MILESTONE-12.3.md Provides the command-line entry point for 'npx vibium'. This script locates and executes the 'clicker' binary from the appropriate platform-specific Vibium package to run the MCP server. It handles platform and architecture detection to find the correct binary. ```javascript #!/usr/bin/env node // Find clicker binary from platform package and run `clicker mcp` const { execFileSync } = require('child_process'); const path = require('path'); const os = require('os'); function getClickerPath() { const platform = os.platform(); const arch = os.arch() === 'x64' ? 'x64' : 'arm64'; const packageName = `@vibium/${platform}-${arch}`; const binaryName = platform === 'win32' ? 'clicker.exe' : 'clicker'; try { const packagePath = require.resolve(`${packageName}/package.json`); return path.join(path.dirname(packagePath), 'bin', binaryName); } catch { console.error(`Could not find clicker binary for ${platform}-${arch}`); process.exit(1); } } const clickerPath = getClickerPath(); execFileSync(clickerPath, ['mcp'], { stdio: 'inherit' }); ``` -------------------------------- ### Run Vibium Script Source: https://github.com/vibiumdev/vibium/blob/main/docs/tutorials/getting-started-python.md Executes the Python script 'hello.py' using the python3 interpreter. This will launch a browser, perform the automated actions defined in the script, and print output to the console. ```bash python3 hello.py ``` -------------------------------- ### Python Package Dependency Marker Example Source: https://github.com/vibiumdev/vibium/blob/main/docs/plans/python-client.md Illustrates how PEP 508 markers are used in the Python client's configuration to specify platform-dependent packages, ensuring the correct binary is installed for the target system. ```toml "vibium-darwin-arm64>=0.1.0; sys_platform == 'darwin' and platform_machine == 'arm64'" ``` -------------------------------- ### Local Development: JavaScript Client REPL Source: https://github.com/vibiumdev/vibium/blob/main/docs/updates/2025-12-17-halfway-there.md These commands outline how to build the Vibium project and then start an interactive REPL session for the JavaScript client locally. The subsequent JavaScript code demonstrates using the client within the REPL, including launching the browser in non-headless mode to observe its actions. ```bash make # build everything cd clients/javascript && node --experimental-repl-await ``` ```javascript const { browser } = await import('./dist/index.mjs') const vibe = await browser.launch({ headless: false }) // see the browser! await vibe.go('https://example.com') const shot = await vibe.screenshot() require('fs').writeFileSync('test.png', shot) await vibe.quit() ```