unifi_console_qos_rule
Preview and apply changes to UniFi console QoS rules: set bandwidth limits or prioritization, toggle rules, and delete them with fingerprint verification and rollback.
Instructions
Preview, then apply, a change to the console's QoS rules (the dashboard's QoS widget; Traffic Management objects use unifi_console_traffic_object instead).
Two steps, always: call with confirm=false to get a read-only preview (before, after, diff, warnings, a
fingerprint); call again with the same fields plus confirm=true and that fingerprint to apply. The rule is
re-read first, so a stale preview is refused. A rule names a WAN or VPN link (wan_network), the clients it covers
(source_clients, MAC addresses), the applications it matches (destination_apps, application ids), and an
objective: LIMIT (download_limit / upload_limit in kbit/s, 10000 = 10 Mbit/s, with download_burst / upload_burst OFF,
SHORT or LONG) or PRIORITIZE (no limits). Other source and destination types and schedules other than ALWAYS have
not been captured and are not edited. A new rule starts switched off unless enabled=true; once enabled it takes
effect at once. Use action enable or disable to switch one. Applying also needs UNIFI_CONSOLE_ENABLE_WRITES=true and
'qos_rule' in UNIFI_CONSOLE_WRITE_ENTITIES. The console only accepts the whole rule, so updates send all of it. After
applying, the rule is read back and the result reports verified true/false, the diff, and the exact rollback call.
Every write is journalled. Delete uses the console's batch-delete call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |