Dominevo
ReferenceDevice capabilities

consumables

Generic device-consumables capability — the ONE place a device reports what it uses up or fills: wear parts (vacuum filters/brushes, cartridges, descaling cycles), supplies it draws from (a vacuum's clean-water tank and detergent, a dishwasher's salt and rinse aid) and waste it collects (a dirty water tank, a dust bin).

Generic device-consumables capability — the ONE place a device reports what it uses up or fills: wear parts (vacuum filters/brushes, cartridges, descaling cycles), supplies it draws from (a vacuum's clean-water tank and detergent, a dishwasher's salt and rinse aid) and waste it collects (a dirty water tank, a dust bin). Each item carries its remaining life or fill and an optional "Replaced" reset action. Device-agnostic: any provider that knows its device tracks consumables registers it; the provider names each item verbatim and says which kind it is.

The admin UI shows it in the device card's consumables chip and popover (kind-aware level, remaining time, "Reset"), for every device bound to this cap. It no longer has a section of its own under the hero card.

Like childLayout, the cap is INERT until a provider sets items: no provider populates it by guessing (no HA inference). The UI renders a "No consumables reported" line when items is empty.

What an item IS, which decides which direction is bad:

  • wear — a part that wears out (a brush, a filter); low life is bad.
  • supply — something the device draws from (clean water, detergent, salt, rinse aid); low or empty is bad.
  • waste — something the device fills (dirty water, a dust bin); full is bad. Absent = wear.

At a glance

Capabilityconsumables
Provided byThe device's own driver provides it: each device registers its own provider.
Active providers per deviceone
Device typescamera, light, siren, switch, sensor, climate, button, event-emitter, update, generic, notifier, script, automation, lock, cover, valve, humidifier, water-heater, fan, media-player, alarm-panel, control, presence, weather, weather-station, vacuum, lawn-mower, container, image, pet-feeder, pet-fountain, dishwasher, washer, dryer, gateway, heat-pump, energy-system, workload
Sourcepackages/types/src/capabilities/consumables.cap.ts

Methods

Every method takes the device id (deviceId) to address the device; the input tables below list the other fields.

MethodKindRequired of a providerAccess
resetmutationyesadmin

reset

mutation

Mark a consumable as replaced — resets its remaining life. Only meaningful when the item's resettable is true.

Input

FieldTypeRequiredDescription
keystringyes

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
consumables.resetMark as replaced

Runtime state

The state Dominevo keeps for each device with this capability, readable without calling the provider.

Per the cap checklist, runtimeState carries the bridge helper's freshness field. The status surface stays the plain schema; only the persistent slice gains lastFetchedAt so future poll-backed providers can use the runtime-state bridge unchanged.

FieldTypeRequiredDescription
items({ key: string; label: string; level: number | null; status: "ok" | "low" | "empty" | "full" | "replace" | null; kind?: "wear" | "supply" | "waste"; form?: "part" | "tank" | "product" | "bin"; lastResetAt: number | null;…yes
lastChangedAtnumberyes
lastFetchedAtnumberyes

Status

FieldTypeRequiredDescription
items({ key: string; label: string; level: number | null; status: "ok" | "low" | "empty" | "full" | "replace" | null; kind?: "wear" | "supply" | "waste"; form?: "part" | "tank" | "product" | "bin"; lastResetAt: number | null;…yes
lastChangedAtnumberyes