set_camera_recording_mode
set_camera_recording_mode
Section titled “set_camera_recording_mode”Set a camera’s recording mode (always, motion, or never).
Side effects:
- PATCHes
recordingSettings.modeon the camera. Takes effect immediately;neverhalts new clip writes. - Mutates controller state. Use dry_run=True to preview the change without applying.
Example
Section titled “Example”set_camera_recording_mode(camera_id="65f...", mode="motion")Parameters
Section titled “Parameters”| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
camera_id | string | yes | — | Protect camera id. |
mode | string | yes | — | One of "always", "motion", "never". |
controller | string | no | ”default” | Name of the UniFi controller to target. Defaults to "default". |
dry_run | boolean | no | false | Preview the change without applying it. Returns the predicted change set. |