@blueharford/scrypted-privacy-manager
v0.0.30-beta
Published
Scrypted plugin for granular camera privacy controls with scheduling, profiles, and Home Assistant integration
Maintainers
Readme
Scrypted Privacy Manager
A Scrypted plugin that provides granular privacy controls for cameras, allowing you to disable recording, events, streaming, and detection on a per-camera basis with time-based scheduling.
Features
Per-Camera Privacy Controls
- Block Recording: Prevent video from being recorded
- Block Events: Suppress motion and detection events
- Block Streaming: Block live video streaming and snapshots
- Block Detection: Disable object detection processing
- Block Motion Alerts: Suppress motion detection notifications
Privacy Profiles
Create named profiles that apply settings to groups of cameras:
- Night Mode: Indoor cameras OFF, outdoor cameras ON
- Away Mode: All cameras ON
- Home Mode: Indoor cameras OFF during the day
- Custom profiles: Create your own
Time-Based Scheduling
Configure automatic privacy based on time:
- Daily: Apply privacy settings every day
- Weekdays: Monday through Friday only
- Weekends: Saturday and Sunday only
- Custom: Select specific days
Example: Disable indoor camera recording from 8 AM to 10 PM on weekdays.
Panic Mode (Quick Toggle)
One-click button to immediately block ALL cameras:
- Overrides all settings, schedules, and profiles
- Exposed as a Home Assistant switch for automation
Home Assistant Integration
All profiles and panic mode are exposed as switches:
switch.privacy_panic_modeswitch.privacy_night_modeswitch.privacy_away_mode- etc.
Webhook Notifications
HTTP POST notifications when privacy settings change:
{
"event": "privacy_changed",
"timestamp": "2024-01-08T10:30:00Z",
"camera": "Living Room Camera",
"cameraId": "abc123",
"settings": {
"blockRecording": true,
"blockEvents": true,
"blockStreaming": false,
"blockDetection": true,
"blockMotionAlerts": true
},
"trigger": "schedule"
}Audit Logging
Track all privacy setting changes:
- Timestamp
- Camera affected
- Previous and new settings
- Trigger (manual, schedule, profile, panic)
Installation
From NPM
npm install @blueharford/scrypted-privacy-managerIn Scrypted
- Go to Plugins in the Scrypted web interface
- Click Install Plugin
- Search for "Privacy Manager" or paste the NPM package name
- Click Install
Configuration
Global Settings
Access via Plugins > Privacy Manager > Settings:
| Setting | Description | |---------|-------------| | Panic Mode | Emergency: Block ALL cameras immediately | | Default Settings | Default privacy settings for new cameras | | Webhook URL | HTTP endpoint for notifications | | Webhook Events | Which events trigger webhooks | | Audit Log Retention | Days to keep audit entries |
Per-Camera Settings
Each camera will have a Privacy Controls section in its settings:
| Setting | Description | |---------|-------------| | Enable Privacy Controls | Master switch for this camera | | Block Recording | Prevent recording | | Block Events | Suppress events | | Block Streaming | Block live video | | Block Detection | Disable object detection | | Block Motion Alerts | Suppress motion alerts | | Enable Schedule | Use time-based automation | | Schedule Type | Daily/Weekdays/Weekends/Custom | | Privacy Start Time | When privacy mode activates | | Privacy End Time | When privacy mode deactivates |
Creating Profiles
- Go to Plugins > Privacy Manager
- Click Add New Device
- Enter a profile name (e.g., "Night Mode")
- Configure the profile:
- Select cameras to include
- Set which privacy options to apply
- Toggle the profile on/off as needed
HTTP API
The plugin exposes HTTP endpoints:
GET /status
Returns current status:
{
"panicMode": false,
"profiles": [
{ "id": "profile-123", "name": "Night Mode", "active": true, "cameraCount": 3 }
],
"schedules": {
"totalSchedules": 5,
"activeSchedules": 2
}
}GET /audit
Returns audit log as JSON.
POST /panic
Enable/disable panic mode:
{ "enabled": true }Use Cases
Indoor Cameras During Day
Disable recording on indoor cameras while you're home:
- Create a profile "Home Mode"
- Add all indoor cameras
- Enable: Block Recording, Block Events, Block Detection
- Set schedule: Daily, 8:00 AM - 10:00 PM
Privacy When Working From Home
Disable office camera during work hours:
- Go to office camera settings
- Enable schedule
- Type: Weekdays
- Start: 09:00, End: 17:00
Instant Privacy
Need immediate privacy?
- Open Scrypted or Home Assistant
- Turn on "Privacy: Panic Mode"
- All cameras immediately stop recording/streaming
Development
Building
npm install
npm run buildLocal Development
npm run scrypted-deploy-debugLicense
Apache-2.0
Author
blueharford
