Add new attribute to an Item


Is there a way to add a new attribute to an item?
I need to store the blind last direction (if it was going down or up) and don’t want to use global vars for that because I have tens of blinds around the house.

Why don’t you use the state that tells you if the Item is ON(Open) or OFF(Closed)
this automatically implies the last direction.

  "link": "",
  "state": "ON",
  "editable": false,
  "type": "Switch",
  "name": "Shutter",
  "label": "Shutter Living",
  "category": "blinds",
  "tags": [],
  "groupNames": []

Through the rest API you could check all attributes on the item

Thank Charley for prompt response.
The blind is controlled by a dimmer and the state is never on or off, it’s just a number.
Today I check if the previousState > currentState to identify the direction.


In that case you use this item

Rollershutter ShutterControl "Shutter living [%d %%]"   (gBlinds) ["Blinds"]      {channel="zwave:device:xxxxxxxxx:node32:blinds_control" }

Here are all attributes you can check the state again

  "link": "",
  "state": "0",
  "stateDescription": {
    "pattern": "%d %%",
    "readOnly": false,
    "options": []
  "editable": false,
  "type": "Rollershutter",
  "name": "ShutterControl",
  "label": "Shutter living",
  "tags": [
  "groupNames": [

Not sure how I identify the blind last direction in this case, can you please let me know what am I missing?

If you are using persistence you could after the position change write a rule that finds the previous state.


Find more info on persistence extensions here

This might be easier than you think, you can use a global “array” (actually a Map object) to store values keyed by Item name.
Usage shown here

You could also use metadata of the item.

Here is a tutorial for Item Metadata.