PinchTab is available as an npm package that provides both a CLI tool and a Node.js SDK for browser automation.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/pinchtab/pinchtab/llms.txt
Use this file to discover all available pages before exploring further.
Installation
- Global (CLI)
- Local (SDK)
Install globally to use the Verify installation:
pinchtab command anywhere:How It Works
The npm package automatically:- Detects your OS and CPU architecture (macOS/Linux/Windows, amd64/arm64)
- Downloads the precompiled PinchTab binary from GitHub Releases
- Verifies integrity using SHA256 checksums from
checksums.txt - Stores in
~/.pinchtab/bin/{version}/(version-specific to avoid conflicts) - Makes the binary executable
The postinstall script runs automatically on
npm install. It requires an internet connection on first install.Requirements
- Node.js: 16+ (18+ recommended)
- npm: Any recent version
- OS: macOS, Linux, or Windows
- Internet: Required during installation to download binary
- Chrome/Chromium: Must be installed on your system
Using the CLI
After global installation, use thepinchtab command:
Start the Server
Check Version
Get Help
Using the Node.js SDK
The npm package includes a TypeScript SDK for programmatic use.Basic Example
SDK API
Constructor Options
Methods
start(binaryPath?)
Start the PinchTab server process.
stop()
Stop the PinchTab server process.
snapshot(params?)
Take a snapshot of the current tab.
click(params)
Click on an element.
lock(params) / unlock(params)
Lock or unlock a tab.
createTab(params)
Create a new tab.
Configuration
Using Custom Binary Path
For Docker, development, or custom setups:Proxy Support
The npm package works with corporate proxies using standard environment variables:Troubleshooting
”command not found: pinchtab”
Problem: Global installation succeeded but command not found. Solution: Add npm’s global bin directory to your PATH:~/.bashrc or ~/.zshrc to persist:
Binary Not Found After Install
Problem: Postinstall script failed to download binary. Check if release has binaries:pinchtab-darwin-arm64, pinchtab-linux-x64, etc.
Rebuild:
Permission Errors (EACCES)
Problem: Permission denied during global install. Solution 1: Use nvm (recommended)Behind Corporate Proxy
Problem: Cannot download binary due to proxy. Solution: Set proxy environment variable:Node Version Too Old
Problem: “npm ERR! engine Unsupported engine” Solution: Upgrade Node.js to version 16 or higher:Using Pre-built Binary
Problem: Need to use a specific binary (development, custom build). Solution: SetPINCHTAB_BINARY_PATH environment variable:
Package Details
Frompackage.json:
Future: Optional Dependencies Pattern
In a future major version (v1.0), PinchTab will migrate to the modern
optionalDependencies pattern used by tools like esbuild, Biome, and Turbo.- Split platform-specific binaries into separate packages (
@pinchtab/cli-darwin-arm64, etc.) - Provide zero postinstall network overhead
- Enable perfect offline support
Next Steps
Quick Start
Start automating with PinchTab
API Reference
Explore HTTP endpoints
Node.js Examples
See more SDK examples
Configuration
Configure environment variables