1. Initialize your project
Create a new project directory and initialize it:
mkdir my-camera-app && cd my-camera-app
npm init -y
npm pkg set type=module
camera-remote-web-api is an ESM-only package. Setting "type": "module" in your package.json enables ES module syntax (import/export) which is required to use the SDK.
2. Install the SDK
npm install camera-remote-web-api
During installation, you’ll be prompted to accept the Sony Camera Remote SDK license agreement. The native binary for your current OS is downloaded automatically.
If you need to target platforms other than your current machine (e.g., deploying to Linux from macOS):
npx camera-server platforms # List available platforms
npx camera-server install --platform linux-x64 # Install a specific platform
npx camera-server install --platform linux-arm64
npx camera-server install --platform win32-x64
| Platform | Architecture | Package |
|---|
| macOS | Apple Silicon (ARM64) | @alpha-sdk/darwin-arm64 |
| Linux | x64 | @alpha-sdk/linux-x64 |
| Linux | ARM64 | @alpha-sdk/linux-arm64 |
| Windows | x64 | @alpha-sdk/win32-x64 |
4. Check dependencies
Run the doctor command to verify your environment has all required dependencies:
Requirements
- Node.js 18+
- Camera: Sony camera with Remote SDK support (USB or network)
- Windows: libusbK 3.0 driver required for USB connections
- macOS: macOS 14+ (Sonoma)
- Linux: Ubuntu 20.04+ or equivalent
5. Install MCP servers (optional)
Configure AI-powered SDK documentation search for Claude Code, VS Code, or Cursor:
This walks you through installing the AI SDK Assistant and AI Camera Assistant MCP servers. See the MCP Server quickstart for details.
6. Verify setup
Check that everything is installed correctly:
CLI Reference
All available camera-server commands:
npx camera-server info # Version and binary info
npx camera-server install [--platform <name>] # Install platform binary
npx camera-server uninstall [--platform <name>] # Remove platform binary
npx camera-server doctor # Check system prerequisites
npx camera-server platforms # List available platforms
npx camera-server docs # Open API docs in browser
npx camera-server mcp # Configure MCP servers
Package Exports
The npm package has two entry points:
| Import | Environment | Includes |
|---|
camera-remote-web-api | Browser + Node.js | CameraManager, CameraClient, EventStream, all types |
camera-remote-web-api/server | Node.js only | CameraManager (server), ServerManager, LiveViewStream, CameraServer |
// Browser-safe (no Node.js dependencies)
import { CameraManager, CameraClient, EventStream } from 'camera-remote-web-api';
// Node.js only (spawns binary, uses WebSocket)
import { CameraManager, ServerManager, LiveViewStream } from 'camera-remote-web-api/server';
The CameraManager exported from camera-remote-web-api/server is a different class than the one from camera-remote-web-api. The server variant includes binary management (start() is async, getPort(), getPid(), etc.).