State roles
Objects from type state need their common.role property set to one of the roles defined in the list below.
The Role information is a very important information and allows Visualization- and Smart-Assistant adapters
to detect the function of the object and also how/if they relate to other objects in the same channel, device or folder.
State role types
The following State Role types exist:
Operative States
Operative states are used to control the normal functionality of a device. An RGB Lamp can have the following three objects (or more) with different roles that belong together:
switch(On/Off)level.color.rgbwith #RRGGBB color code of the lamplevel.brightnesswith the brightness value
Also, the cleaning mode or the room-to-clean of a robotic vacuum cleaner is such an operative state. These states are using the below definition without any adjustments.
Please use the most detailed role name possible that provide the most details (e.g. level.color.temperature should be used over level for the color temperature, or switch.power is better than switch to operate the power of a device).
Additionally, when using detailed role names (more than one level), it is important not to use the same role twice in a channel of a device.
Different Device templates used for the detecting with the required and optional objects and their roles can be found in the Type-detector repository.
Configuration/Setting States
States that are configuring further "Non-operative" settings of the devices can also use the below basic role definitions to give more context of the type and usage of the provided value, but add a ".setting." as second level of the role name. For example:
level.setting.color.temperaturewith a 0..100% number can be used to set the "Startup ColorTemperature" of a light bulbswitch.setting(On/Off) could be used to define setting that can be turned on or off (e.g. child lock functionality)
User Interfaces might use these special roles to determine device settings and show then in a "Settings" dialog for the device, or ignore them.
Please note: These types of roles were defined in June 2025, so many (older) adapters might not use them. In the future this state type can/should be used when relevant.
Generic States
If no detailed matching role can be found or the use case is not specific then you can fall back to us the below defined Common roles.
State role categories
Common
state- very common purpose. If you don't know which role the state has, use this one.textcommon.type = stringtext.urlcommon.type = stringstate val contains an url for usage in an anchor, iframe or imghtmlcommon.type = stringjsoncommon.type = stringlistcommon.type = arraydatecommon.type = string- parsable bynew Date(ddd)stringdatecommon.type = number-epoch seconds * 1000
Sensor (booleans, read-only)
common.type=boolean, common.write=false
sensor- generic sensor state to represent a status: active -trueor inactivefalsesensor.contact- general contact: open -trueor closed -falsesensor.window- window opened-trueor closed-falsesensor.door- door opened-trueor closed-falsesensor.alarm- some common alarmsensor.alarm.flood- water leakagesensor.alarm.fire- fire sensorsensor.alarm.co- carbon monoxide detectedsensor.alarm.secure- door opened, window opened or motion detected during alarm is ON.sensor.alarm.power- No power (voltage = 0)sensor.light- feedback from the lamp, that it is ONsensor.lock- actual position of lock: unlocked -trueor locked -falsesensor.motion- motion sensorsensor.rain- rain detectedsensor.noise- noise detectedsensor.switch- switch status: on -trueor off -false
Buttons (booleans, write-only)
common.type=boolean, common.write=true, common.read=false
Buttons normally do not have a value and are only used to send an event (TRUE) when pressed, therefore the attribute read-flag must be FALSE. User interfaces should not read the value of this state nor expect it to be reset to "FALSE" after the action was executed or such. Button events triggering onChange on an adapter should be confirmed with ACK = TRUE to show the event has been recognized and processed.
buttonbutton.longbutton.stop- e.g. rollo stop,button.stop.blind- stop the motion of a blind (device typesblind,blindButtons)button.stop.tiltbutton.startbutton.resumebutton.open.doorbutton.open.windowbutton.open.blindbutton.open.tiltbutton.close.blindbutton.close.tiltbutton.open- open a blind. The type detector accepts it as an equivalent ofbutton.open.blind, but the more detailed role is preferredbutton.close- close a blind. The type detector accepts it as an equivalent ofbutton.close.blind, but the more detailed role is preferredbutton.mode.*button.mode.autobutton.mode.manualbutton.mode.silent
Buttons as sensor
common.type=boolean, common.write=false, common.read=true
button- the difference, thatcommon.write=false. Please avoid this role and usebutton.pressorbutton.long.button.longbutton.press
Values (numbers, read-only)
common.type=number, common.write=false (common.type=string, common.write=false where specified explicitly)
valuevalue.window(common.states={"0": "CLOSED", "1": "TILTED", "2": "OPEN"}) It is important to have (CLOSED/TILTED/OPEN). Values can differ.value.temperature(common.unit='°C' or '°F' or 'K')value.temperature.dewpoint(`common.unit='°C' or '°F')value.humidityrelative humidity, same asvalue.humidity.relative(unit: %)value.humidity.relative- (unit: %)value.humidity.absolute- (unit: g/m³, mg/m³)value.co- Carbon monoxide (unit: ppm)value.co2- Carbon dioxide (unit: ppm)value.no- Nitrogen monoxide (unit: µg/m³ or ppm)value.no2- Nitrogen dioxide (unit: µg/m³ or ppm)value.o3- Ozone (unit: µg/m³ or ppm)value.ch2o- Formaldehyde (unit: µg/m³)value.pm1- Particulate matter PM1 (unit: µg/m³)value.pm25- Particulate matter PM2.5 (unit: µg/m³)value.pm10- Particulate matter PM10 (unit: µg/m³)value.rn- Radon (unit: Bq/m³)value.tvoc- Total volatile organic compounds (unit: µg/m³ or ppb)value.airquality- Air quality index (AQI)value.so2- Sulphur dioxide (unit: µg/m³ or ppm)value.co.level,value.co2.level,value.no2.level,value.o3.level,value.ch2o.level,value.pm1.level,value.pm25.level,value.pm10.level,value.rn.level,value.tvoc.level,value.so2.level- qualitative level of the concentration of the same name (common.states={"0": "UNKNOWN", "1": "LOW", "2": "MEDIUM", "3": "HIGH", "4": "CRITICAL"})value.brightness- luminance level (unit: lux)value.dimmer- actual dimming level in % (device typedimmer)value.volume- actual sound volume in % (device typesmedia,volume)value.volume.group- actual sound volume of a group of devices in % (device typevolumeGroup)value.minvalue.maxvalue.defaultvalue.battery- battery levelvalue.valve- valve levelvalue.filter- remaining condition of a filter (unit: %)value.filter.carbon- remaining condition of an activated carbon filter (unit: %)value.flow- flow rate of a liquid or a gas (unit: m³/h)value.rssi- received signal strength of a radio device (unit: dBm)value.time- getTime() of Date() objectvalue.timer- duration in s (r/o equivalent tolevel.timer)value.interval(common.unit='sec') - Interval in seconds (can be 0.1 or less)value.date (common.type=string) - Date in form 2015.01.01 (without time)value.datetime (common.type=string) - Date and time in system formatvalue.gps.longitude- gps longitude coordinatesvalue.gps.latitude- gps latitudevalue.gps.elevation- gps elevationvalue.gps- longitude and latitude together like '5.56;43.45' (common.type=string)value.gps.accuracy- accuracy of current gps measurementvalue.gps.radius- radius of current gps measurementvalue.power.consumption- energy consumption (unit=Wh or KWh)value.power.production- energy production (unit=Wh or KWh)value.energy- energy (unit=Wh, kWh or m3 for gasoline)value.energy.active- active energy (unit=Ws, Wh, kWh)value.energy.reactive- reactive energy (unit=vars, kVarh)value.energy.consumed- energy consumed (unit=Ws, Wh, kWh)value.energy.produced- power produced (unit=Ws, Wh or kWh)value.power- energy power (unit=W or kW)value.power.active- active power (unit=W, kW)value.power.reactive- reactive power (unit=var, kVar)value.power.consumed- power consumed (unit=W or kW)value.power.produced- power produced (unit=W or kW)value.direction- (common.type=number, indicates up/down, left/right, 4-way switches, wind-direction, ... 0 - nothig, 1 - up/opening, 2 - down/closing, 3 - undefined)value.curtain- actual position of curtainvalue.blind- actual position of the blind (max = fully open, min = fully closed)value.tilt- actual tilt position (max = fully open, min = fully closed)value.open.tilt- accepted variant ofvalue.tilt. Prefervalue.tiltfor new adaptersvalue.lock- actual position of lockvalue.speed- wind speedvalue.pressure- (unit: mbar,hPais the same value and is accepted too)value.distancevalue.distance.visibilityvalue.severity- some severity (states can be provided), Higher is more importantvalue.warning- some warning (states can be provided), Higher is more importantvalue.sun.elevation- sun elevation in °value.sun.azimuth- sun azimuth in °value.voltage- Voltage in Volt,unit=Vvalue.current- Current in Ampere,unit=Avalue.frequency- Frequency in Hz,unit=Hzvalue.fill- Fill level,unit=l,ml,m3,%value.blood.sugar- Blood sugar value,unit=mmol,mgdl
Indicators (boolean, read-only)
common.type=boolean, common.write=false
The difference of Indicators from Sensors is that indicators will be shown as small icon. Sensors as a real value. So the indicator may not be alone in the channel. It must be some other main state inside a channel.
indicatorindicator.working- indicates that the target system is executing something, like blinds or lock opening.indicator.working.test- a self test of the device is in progressindicator.reachable- If a device is onlineindicator.connected- used only for instances. Useindicator.reachablefor devicesindicator.direction-true- up/open,false- down/close. Use bettervalue.directionindicator.error- true if any error condition existsindicator.maintenance- indicates system warnings/errors, alarms, service messages, battery empty or stuff like thatindicator.maintenance.lowbatindicator.maintenance.unreachindicator.maintenance.filter- the filter of the device has to be changedindicator.maintenance.alarmindicator.lowbat- true if low batteryindicator.alarm- same as indicator.maintenance.alarmindicator.alarm.fire- fire detectedindicator.alarm.flood- flood detectedindicator.alarm.secure- door or window is openedindicator.alarm.health- health problemindicator.alarm.muted- the alarm of the device is currently muted
Levels (numbers, read-write)
common.type=number, common.write=true(common.type=string, common.write=true where specified explicitly)
With levels, you can control or set some number value.
levellevel.humidity- humidity as a setpoint, i.e., for humidifiers / climate controlslevel.battery- battery target voltage / capacity i.e.for loadinglevel.battery.min- battery minimum voltage / capacitylevel.battery.max- battery maximum voltage / capacitylevel.valve- opening value for valveslevel.pressure-level.pressure.min- minimum air or oil pressure value allowedlevel.pressure.max- maximum air or oil pressure value allowedlevel.voltage- target voltage for generatorslevel.voltage.min- minimum voltage for generatorslevel.voltage.max- maximum voltage for generatorslevel.current- target current for i.e., loading battery deviceslevel.current.min- minimum current for i.e., loading battery deviceslevel.current.max- maximum current for i.e., loading battery deviceslevel.frequency- target frequency for generatorslevel.frequency.min- minimum frequency for generators or for power grid alarmslevel.frequency.max- maximum frequency for generators or for power grid alarmslevel.fill- setpoint for any container fill level stateslevel.brightness- luminance level (unit: lux)level.min- minimum level allowedlevel.max- maximum level allowedlevel.default- default levellevel.dimmer- brightness is dimmer toolevel.blind- set blind position (max = fully opened, min = fully closed)level.temperature- set desired temperaturelevel.temperature.heating- desired temperature for heating, for devices that hold a heating and a cooling setpoint at oncelevel.temperature.cooling- desired temperature for cooling, for devices that hold a heating and a cooling setpoint at oncelevel.valve- set point for valve positionlevel.color.redlevel.color.greenlevel.color.bluelevel.color.white- rgbWlevel.color.hue- color in °0-360; 0=red, 120=green, 240=blue, 360=red(cyclic)level.color.saturationlevel.color.rgb- hex color like#rrggbb(common.type=string)level.color.rgbw- hex color like#rrggbbww(common.type=string)level.color.cie- cie color in form[x, y](common.type=string)level.color.luminancelevel.color.temperature- color temperature in K°2200 warm-white, 6500° cold whitelevel.effect- effect, usually for lights. Should have list of possible effects incommon.states. (common.type=string).level.timerlevel.timer.sleep- sleep timer. 0 - off, or in minuteslevel.timer.off- time in seconds after which the device switches itself off again, e.g. the on-time of a lamp or a socket- ...
level.volume- (min=0, max=100) - sound volume, but min, max can differ. min < maxlevel.volume.group- (min=0, max=100) - sound volume, for the group of deviceslevel.curtain- set the curtain positionlevel.tilt- set the tilt position of blinds (max = fully opened, min = fully closed)level.open.tilt- accepted variant oflevel.tilt. Preferlevel.tiltfor new adapterslevel.speed- speed eg. fan, ventilator, .. Also used as the continuous fan speed in % of an air conditioner, fan or air purifier, where the stepped counterpart islevel.mode.fanlevel.pump- speed or flow setpoint of a pump (unit: %)
Switches (booleans, read-write)
Switch controls a boolean device (true = ON, false = OFF)
common.type=boolean, common.write=true
switchswitch.lock- lock (true - open lock, false - close lock)switch.lock.door- door lockswitch.lock.window- window lockswitch.mode.boost- start/stop boost mode of thermostatswitch.boost- start/stop boost mode. Older variant ofswitch.mode.boost, still accepted (device typeairCondition)switch.mode.party- start/stop party mode of thermostatswitch.power- on/off power, thermostat or air conditionerswitch.lightswitch.comfort- comfort modeswitch.enableswitch.mode.*switch.mode.auto- auto mode on/offswitch.mode.manual- manual mode on/offswitch.mode.silent- silent mode on/offswitch.mode.moonlight- moon light mode on/offswitch.mode.color- color mode on/offswitch.gate- closes(false) or opens(true) the gateswitch.pump- on/off of a pump. A dedicated role, because a pump has no other mandatory state and could not be told apart from a socket otherwise
Air condition or thermostat
level.mode.fan-AUTO, HIGH, LOW, MEDIUM, QUIET, TURBOlevel.mode.swing-AUTO, HORIZONTAL, STATIONARY, VERTICALlevel.mode.airconditioner- air conditioner:AUTO, COOL, DRY, ECO, FAN_ONLY, HEAT, OFF, heating thermostat:AUTO, MANUAL, VACATION,level.mode.thermostat- thermostat:AUTO, MANUAL, VACATION,level.mode.airflow- airflow direction:FORWARD, REVERSEswitch.mode.swing- boolean variant oflevel.mode.swingfor devices that can only switch the swing on and offvalue.mode.thermostat- what the device is actually doing, read-only:OFF, HEAT, COOL. The read-only counterpart oflevel.mode.thermostatvalue.mode.airconditioner- current device state:IDLE,HEAT,COOL(0,1,2 in apple home) Additionally to these states normally thelevel.temperatureandswitch.power` required to map the air conditioner.
TODO: Think about ionization` and oscillation.
Vacuum cleaner
level.mode.cleanup- Enumeration ofAUTO, ECO, EXPRESS, NORMAL, QUIET. OnlyAUTOandNORMALare required.level.mode.work- Enumeration ofAUTO, FAST, MEDIUM, SLOW, TURBO. Optional state.value.water- 0-100% water level.value.waste- 0-100% waste bin level. (0% - empty, 100% - full)indicator.maintenance.waste- Waste bin is fool.value.state-HOME, CLEANING, PAUSEand so on.vacuum.map.base64- map of the cleaned area as a base64 encoded image (common.type=string)value.usage.filter- remaining life of the filter in %value.usage.brush- remaining life of the main brush in %value.usage.brush.side- remaining life of the side brush in %value.usage.sensors- remaining time in % until the sensors have to be cleanedindicator.maintenance.water- the water tank has to be filledlevel.mode.vacuum- run mode of a robotic vacuum:IDLE, CLEANING, MAPPINGand vendor modes. The cleaning intensity islevel.mode.cleanupbutton.home- send the device back to its dockvalue.progress- progress of the running job (unit: %)value.vacuum.phase- current phase reported by the device (common.type=string)
Additionally, to these states normally the switch.power required to map the vacuum cleaner. switch.power in this case works as: true - clean, false - back to home.
Optionally value.battery and
Gate
switch.gate- closes(false) or opens(true) the gate (required)value.position- position of the gate in percent (100% opened, 0% - closed)value.gate- same asvalue.positionbutton.stop- stop the motion of the gateindicator.opened- end contact: the gate is fully openedindicator.closed- end contact: the gate is fully closed. Both contacts exist separately, because a gate can also stand between fully opened and fully closed
Media
Special roles for media players
button.stopbutton.playbutton.nextbutton.prevbutton.pauseswitch.pausebutton.forwardbutton.reversebutton.fastforwardbutton.fastreversebutton.volume.upbutton.volume.downmedia.seek- (common.type=number) %media.mode.shuffle- (common.type=number) 0 - none, 1 - all, 2 - onemedia.mode.repeat- (common.type=boolean)media.state-['play','stop','pause']or[0 - pause, 1 - play, 2 - stop]or[true - playing/false - pause]media.artistmedia.albummedia.titlemedia.title.nextmedia.cover- cover urlmedia.cover.big- big cover urlmedia.cover.small- tiny cover urlmedia.duration.text- e.g "2:35"media.duration- (common.type=number) secondsmedia.elapsed.text- e.g "1:30"media.elapsed- (common.type=number) secondsmedia.broadcastDate- (common.type=string) Broadcast datemedia.mute- (common.type=boolean) true is mutedmedia.player.name- name of the player (common.type=string)media.player.type- type of the player, e.g. the model (common.type=string)media.season- (common.type=string) season number (important the type is really "string" to be able to indicate absence of season with "")media.episode- (common.type=string) episode number (important the type is really "string" to be able to indicate absence of episode with "")media.mute.group- (common.type=boolean) mute of a group of devicesmedia.tts- text to speechmedia.bitrate- kbpsmedia.genre- genre songmedia.date- year songmedia.track- (common.type=string) current play track id[0 - ~](important the type is reallystringto be able to indicate absence of track with "")media.playid- media player track idmedia.add- add current playlistmedia.clear- clear current playlist (write-only)media.playlist- json array likemedia.url- url to play or current urlmedia.url.announcement- URL to play an announcementmedia.jump- Number of items to jump in the playlist (it can be negative)media.content- Type of media being played such as audio/mp3media.link- State with the current filemedia.input- number or string of input (AUX, AV, TV, SAT, ...)level.bass- Bass levellevel.treble- Treble levelswitch.power.zone- power zone
[
{
"artist": "",
"album": "",
"bitrate":0,
"title": "",
"file": "",
"genre": "",
"year": 0,
"len": "00:00",
"rating": "",
"cover": ""
}
]
media.browser- json array like "files"
[
{
"fanart": "",
"file": "", // smb://192.168.1.10/music/AtlantidaProject/
"filetype": "", // directory
"label": "",
"mimetype": "",
"size": 0,
"thumbnail": "",
"title": "",
"type": "",
"lastmodified": "2016-02-27 16:05:46",
"time": "88",
"track": "01",
"date": "2005",
"artist": "yonderboy (H)",
"album": "splendid isolation",
"genre": "Trip-Hop"
}
]
Weather
date- actual date or date of last-read informationdate.forecast.1- tomorrow datedate.forecast.0- today datedayofweek.forecast.0- day of week of today as textdate.sunrise- Sunrise for todaydate.sunset- Sunset for todaydate.sunrise.forecast.0- Sunrise of the forecast for today.date.sunrise.forecast.1for tomorrow and so ondate.sunset.forecast.0- Sunset of the forecast for today.date.sunset.forecast.1for tomorrow and so ontime.sunrise,time.sunset- accepted variants ofdate.sunrise/date.sunset, including the.forecast.<n>forms. Prefer thedate.*roles for new adaptersdayofweek- day of week as textlocation- Text description of location (e.g., address)value.clouds- Clouds on the sky. 0% - no clouds, 100% - many clouds.value.direction.max.wind- actual wind direction in degreesvalue.direction.min.wind- actual wind direction in degreesvalue.direction.wind- actual or average wind direction in degreesvalue.direction.wind.forecast.0- wind direction forecast for today in degreesvalue.direction.wind.forecast.1- wind direction forecast for tomorrow in degreesvalue.humidity- actual or average humidityvalue.humidity.max- actual humidityvalue.humidity.forecast.0- humidity forecast for today.value.humidity.forecast.1for tomorrow and so onvalue.humidity.max.forecast.0- maximum humidity forecast for today.value.humidity.max.forecast.1for tomorrow and so onvalue.temperature.forecast.0- temperature forecast for todayvalue.temperature.feelslike.forecast.0- felt temperature forecast for todayvalue.temperature.windchill.forecast.0- wind chill forecast for todayvalue.pressure.tendency- tendency of the air pressure as text, e.g.up,down,stable(common.type=string)value.humidity.min- actual humidityvalue.precipitation- (type: number, unit: mm) precipitation for last 24 hours rain/snow (Niederschlag heute für Schnee oder Regen / осадки сегодня снега или дождя)value.precipitation.chance- Actual precipitation chance for todayvalue.precipitation.day.forecast.0- Forecast for precipitation for daytimevalue.precipitation.forecast.0- (type: number, unit: %) Forecast of precipitation chance for todayvalue.precipitation.forecast.0- (type: number, unit: mm) Forecast of precipitation level for todayvalue.precipitation.forecast.1- (type: number, unit: %) Forecast of precipitation chance for tomorrowvalue.precipitation.forecast.1- (type: number, unit: mm) Forecast of precipitation level for tomorrowvalue.precipitation.hour- Actual precipitation level in last hourvalue.precipitation.night.forecast.0- Forecast for precipitation for nighttimevalue.precipitation.today- Actual precipitation level for today (till 0:00)value.precipitation.type- Actual precipitation type for today. (type: number) States: 0 - NO, 1 - RAIN, 2 - SNOW, 3 - HAILvalue.pressure.forecast.0- forecast for pressure for todayvalue.pressure.forecast.1value.radiation- Actual sun radiation levelvalue.rain- Actual rain level in last 24 hoursvalue.rain.hour- Actual rain level in last hourvalue.rain.today- Actual rain level for today (till 0:00)value.snow- Actual snow level in last 24 hoursvalue.snow.hour- Actual snow level in last hourvalue.snow.today- Actual snow level for today (till 0:00)value.snowline- Actual snow line in metersvalue.speed.max.wind- maximal wind speed in last 24hvalue.speed.min.wind- minimal wind speed in last 24hvalue.speed.wind- actual or average wind speedvalue.speed.wind.forecast.0- wind speed forecast for todayvalue.speed.wind.forecast.1- wind speed forecast for tomorrowvalue.speed.wind.gust- actual wind gust speedvalue.temperature- Actual temperaturevalue.temperature.dewpoint- Actual dew-pointvalue.temperature.feelslike- Actual temperature "feels like"value.temperature.max- Maximal temperature in last 24hvalue.temperature.max.forecast.0- Max temperature forecast for todayvalue.temperature.max.forecast.1- Max temperature forecast for tomorrowvalue.temperature.min- Minimal temperature in last 24hvalue.temperature.min.forecast.0- Min temperature forecast for todayvalue.temperature.min.forecast.1- Min temperature forecast for tomorrowvalue.temperature.windchill- Actual wind chillvalue.uv- Actual UV levelweather.chart.url- URL to chart for weather historyweather.chart.url.forecast- URL to chart for weather forecastweather.direction.wind- actual or average wind direction as text, e.g., NNWweather.direction.wind.forecast.0- wind direction forecast for today as textweather.html- HTML object with weather descriptionweather.icon- Actual state icon URL for nowweather.icon.forecast.0- state icon URL of the forecast for todayweather.icon.wind.forecast.0- wind icon URL of the forecast for todayweather.icon.forecast.1- tomorrow iconweather.icon.name- Actual state icon name for nowweather.icon.wind- Actual wind icon URL for nowweather.json- JSON object with specific dataweather.state- Actual weather descriptionweather.state.forecast.0- Weather description for todayweather.state.forecast.1- tomorrow weather stateweather.title- Very short descriptionweather.title.forecast.0- Very short description for tomorrowweather.title.short- Very, very short description (One word)weather.type- Type of weather information
Info
info.ip- IP of a deviceinfo.mac- MAC address of a deviceinfo.name- name of a deviceinfo.address- some other address (e.g., KNX)info.serial- serial numberinfo.firmware- firmware versioninfo.hardware- hardware versioninfo.port- tcp portinfo.standby- true if device in standby modeinfo.status- status of a deviceinfo.display- information shown on device displayinfo.model- device modeldate.start- string or numberdate.end- string or number
Health
common.type=number, common.read=true, common.write=false
value.health.fat- body fat index in %value.health.weight- body weight in kg, lbsvalue.health.bmi- bmi indexvalue.health.calories- burned caloriesvalue.health.steps- steps donevalue.health.bpm- heart beats per minute
Others
Roles of a camera (device type camera):
link.camera- URL of the camera image (common.type=string)level.camera.position- pan, tilt and zoom position of the cameraswitch.camera.autofocus- autofocus on/offswitch.camera.autowhitebalance- automatic white balance on/offswitch.camera.brightness- brightness correction on/offswitch.camera.nightmode- night mode on/off
Role of an image (device type image):
-
icon- URL of an image or an icon (common.type=string) -
url -
url.icon- icon (additionally every object can havecommon.icon) -
url.cam- web camera url -
url.blank- open URL in a new window -
url.same- open URL in this window -
url.audio- URL for an audio file -
text.phone- phone number -
time.span- time difference in ms (common.type=number), i.e., time since last update, duration of operation, time until next try, ... -
time.interval- intervall value in ms (common.type=number), i.e. some polling interval -
time.timeout- timeout value in ms (common.type=number), i.e. timeouts for communication requests -
chart- JSON array with chart data, like[{ts: 1678575600000, val: 1}, {ts: 1678579200000, val: 2}] -
adapter.messagebox(common.type=object, common.write=true) used to send messages to email, pushover and other adapters -
adapter.wakeup(common.type=boolean, common.write=true) wake up adapter from suspended mode
Deprecated role aliases
The type detector still accepts the roles listed below so that existing adapters keep working, but they are deprecated. Do not use them in new adapters, and migrate them when you touch an old adapter. Every alias has a documented replacement in the tables below.
Buttons: the action.* namespace
The whole action.* namespace is an old spelling of button.*. The detector matches button and action alike.
| Deprecated | Use instead |
|---|---|
action.play, action.pause, action.stop, action.next, action.prev | button.play, button.pause, button.stop, button.next, button.prev |
action.home | button.home |
action.open, action.open.blind | button.open.blind |
action.close, action.close.blind | button.close.blind |
action.open.tilt, action.close.tilt, action.stop.tilt | button.open.tilt, button.close.tilt, button.stop.tilt |
action.stop.blind | button.stop.blind |
Sensors and alarms with a state. prefix or without .alarm
| Deprecated | Use instead |
|---|---|
state.window | sensor.window |
state.door | sensor.door |
state.fire, state.alarm.fire, sensor.fire, indicator.fire | sensor.alarm.fire |
state.flood, state.alarm.flood, sensor.flood, indicator.flood | sensor.alarm.flood |
state.co, state.alarm.co, sensor.co | sensor.alarm.co |
motion, state.motion | sensor.motion |
state.light | sensor.light (read-only) or switch.light (read-write) |
state.active | sensor.switch |
Indicators
| Deprecated | Use instead |
|---|---|
indicator.battery, indicator.maintenance.battery | indicator.maintenance.lowbat |
indicator.unreach | indicator.maintenance.unreach |
Switches
| Deprecated | Use instead |
|---|---|
switch.active | switch |
switch.party | switch.mode.party |
switch.boost | switch.mode.boost |
switch.autofocus | switch.camera.autofocus |
switch.autowhitebalance | switch.camera.autowhitebalance |
switch.brightness | switch.camera.brightness |
switch.nightmode | switch.camera.nightmode |
Levels and values
| Deprecated | Use instead |
|---|---|
level.thermostat | level.mode.thermostat |
value.latitude, value.longitude, value.elevation | value.gps.latitude, value.gps.longitude, value.gps.elevation |
value.radius, value.accuracy | value.gps.radius, value.gps.accuracy |
value.brush, value.brush.side, value.sensors | value.usage.brush, value.usage.brush.side, value.usage.sensors |
Media
| Deprecated | Use instead |
|---|---|
media | media.mute |