This monorepo contains the complete Eufy Security integration for Scrypted, consisting of multiple packages that work together to provide comprehensive home security automation.
The monorepo includes four specialized packages: the main Scrypted plugin for device integration, a WebSocket client library for communication, a streaming server for video delivery, and a command-line interface for testing and automation.
Eufy Security uses legacy encryption that modern Node.js cannot handle. Eufy cameras and devices were designed years ago with older security protocols that are incompatible with current Node.js versions. This creates a fundamental compatibility barrier for modern home automation platforms.
For a detailed technical explanation of why this architecture was chosen, see WHY_THIS_PACKAGE.
Modern Node.js runtimes (18+) have removed support for the deprecated OpenSSL encryption methods that Eufy's older firmware relies on. This means:
- β Direct integration impossible - Can't connect to Eufy devices from modern Node.js applications
- β Security risks - Using older Node.js versions introduces vulnerabilities
- β Maintenance burden - Would require maintaining outdated, insecure runtimes
This plugin uses a two-tier architecture with a dedicated eufy-security-ws server that handles the legacy protocol communication:
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
β Scrypted β β Eufy Security β β Eufy Devices β
β (Modern) βββββΊβ WS Server βββββΊβ (Legacy) β
β β β (Legacy Node) β β β
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
The eufy-security-ws server:
- Runs on Node.js with legacy OpenSSL support
- Handles all direct communication with Eufy devices
- Provides a modern WebSocket API for secure integration
- Isolated in a container for security and compatibility
This Scrypted plugin:
- Runs on your modern Scrypted server
- Communicates with the WS server via secure WebSocket
- Provides the Scrypted integration layer
- Enables full home automation features
- β Security First - Modern, secure Node.js for the main application
- β Compatibility - Works with all Eufy device generations
- β Performance - Optimized streaming and event handling
- β Maintainable - Clear separation of concerns
- β Future-Proof - Can adapt as Eufy updates their protocols
- π Scrypted Documentation - Learn about Scrypted's automation platform
- π§ Eufy Security WS - The foundation this plugin builds upon
- π Home Assistant Integration - Use with Home Assistant
- π API Reference - Technical API documentation
All notable changes to this project are documented in the CHANGELOG file. This includes:
- Version history for all packages in the monorepo
- Feature additions and bug fixes
- Breaking changes and migration guides
- Release notes and upgrade instructions
# Install via Scrypted's plugin system
# Search for "Eufy Security" in Scrypted plugins- Scrypted Server - Home automation platform (get started)
- Eufy Account - Active Eufy Security subscription
# Clone the monorepo
git clone https://github.com/caplaz/eufy-security-scrypted.git
cd eufy-security-scrypted
# Install all dependencies
npm install
# Build all packages
npm run build# Open the Scrypted package in VS Code
code packages/eufy-security-scrypted
# Configure your Scrypted server IP in .vscode/settings.json
# Press the Launch button (green arrow) in Run and DebugThis monorepo contains four specialized packages that work together to provide complete Eufy Security integration:
Scrypted Plugin - The main integration point
Core Scrypted plugin that discovers and controls your Eufy devices. Handles authentication, device management, and integrates with Scrypted's automation ecosystem.
Key Features:
- π Automatic device discovery
- π₯ Live video streaming
- π Motion and doorbell events
- βοΈ Device control and configuration
- π€ Scrypted automation integration
WebSocket Client Library - Communication foundation
Type-safe TypeScript library for communicating with Eufy Security systems via WebSocket. Provides the low-level API interactions that other packages build upon.
Key Features:
- π WebSocket-based communication
- π Type-safe API calls
- π― Event-driven architecture
- π§ͺ Comprehensive test coverage (184 tests)
- π Schema negotiation and compatibility
Command-Line Interface - Development and testing tool
Terminal-based tool for interacting with your Eufy devices. Perfect for testing, debugging, and automation scripts.
Key Features:
- πΊ Direct video streaming to media players
- π Device status and control
- π§ Configuration management
- π Streaming statistics
- π€ Scriptable automation
TCP Streaming Server - High-performance video delivery
Simplified TCP server optimized for raw H.264 video streaming. Handles the complexities of Eufy's video protocols while providing a clean streaming interface.
Key Features:
- π¬ Raw H.264 video streaming
- π TCP server with concurrent connections
- π¦ NAL unit parsing and keyframe detection
- π Connection statistics and monitoring
- β‘ Event-driven TypeScript implementation
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
β Scrypted UI βββββΊβ Scrypted Plugin βββββΊβ Eufy Devices β
β β β (eufy-security- β β β
β User Interface β β scrypted) β β Cameras, β
βββββββββββββββββββ ββββββββββββββββββββ β Doorbells, etc. β
β βββββββββββββββββββ
βΌ
ββββββββββββββββββββ
β WebSocket Client β
β (eufy-security- β
β client) β
ββββββββββββββββββββ
β
βΌ
ββββββββββββββββββββ βββββββββββββββββββ
β Stream Server βββββΊβ Media Players β
β (eufy-stream- β β β
β server) β β VLC, ffplay, β
ββββββββββββββββββββ β etc. β
β² βββββββββββββββββββ
β
ββββββββββββββββββββ
β CLI Tool β
β (eufy-security- β
β cli) β
ββββββββββββββββββββ
- Scrypted Plugin discovers devices and handles user interactions
- WebSocket Client manages all communication with Eufy servers
- Stream Server provides optimized video delivery to media players
- CLI Tool offers direct terminal access for testing and automation
eufy-security-scryptedβ depends oneufy-security-clienteufy-security-cliβ depends oneufy-security-clientandeufy-stream-servereufy-stream-serverβ standalone streaming componenteufy-security-clientβ foundation library with no dependencies
# Build all packages
npm run build
# Build individual packages
cd packages/eufy-security-client && npm run build
cd packages/eufy-security-scrypted && npm run build
cd packages/eufy-stream-server && npm run build
cd packages/eufy-security-cli && npm run build# Run complete test suite (206 tests)
npm run test
# Test individual packages
cd packages/eufy-security-client && npm run test
cd packages/eufy-stream-server && npm run test
cd packages/eufy-security-cli && npm run test# Lint and format
npm run lint
npm run format
# Type checking
npm run type-check# All packages share versioning
git tag v0.1.1
git push origin v0.1.1
# GitHub Actions automatically publishes to npmWe welcome contributions! This monorepo uses modern development practices:
- Lerna for monorepo management
- TypeScript for type safety
- Jest for comprehensive testing
- ESLint + Prettier for code quality
- GitHub Actions for CI/CD
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Ensure all tests pass
- Submit a pull request
# Run full test suite
npm run test
# Run tests in watch mode during development
npm run test:watch| Command | Description |
|---|---|
npm run build |
Build all packages |
npm run test |
Run all tests |
npm run clean |
Clean build artifacts |
npm run lint |
Lint all code |
npm run format |
Format code with Prettier |
npm run type-check |
Run TypeScript type checking |
eufy-security-scrypted/
βββ packages/
β βββ eufy-security-client/ # π WebSocket communication
β βββ eufy-security-cli/ # π» Command-line interface
β βββ eufy-security-scrypted/ # π€ Scrypted plugin
β βββ eufy-stream-server/ # π¬ Video streaming server
βββ docker/ # π³ Development environment
βββ .github/workflows/ # βοΈ CI/CD pipelines
βββ lerna.json # π¦ Monorepo configuration
βββ tsconfig.json # π§ Shared TypeScript config
- Modular Architecture - Each package has a single responsibility
- Type Safety - Full TypeScript coverage for reliability
- Test-Driven - Comprehensive test suites ensure quality
- Developer Experience - Modern tooling and clear documentation
- Performance - Optimized for real-time video streaming
MIT License - See LICENSE for details
@bropat - Author of eufy-security-ws, the foundation this plugin is built upon. Without their excellent work on reverse-engineering Eufy's protocols, this integration would not be possible.
- Scrypted - Powerful home automation platform that makes this integration possible
- Community contributors - Bug reports, feature requests, and testing help improve the plugin
- Eufy Security - For providing the devices we all love to integrate