|  Developer
Updated on March 31, 2023

hub.item.dictionary.value.add

Connection type:

Permissions:

  • Add element to the dictionary (key will be generated on firmware side)
    Only applicable for items with value type dictionary
    ‘addItemDictionaryValue’ script from plugin config will be called in lua
Edit
Field Type Description
_id string Item object id
element.type string Valid value type. MUST be equal to dictionary element type
element.value depends on element.type Element value
source object Optional. Contains information about the operation source.
Edit
Edit
Broadcast Description
hub.item.dictionary.updated Informs about item dictionary changed
Edit
Edit
				
					{
    "method": "hub.item.dictionary.value.add",
    "id": "<request_id>",
    "params": {
        "_id" : "5cf0dc8c7f000068d223e88a",
        "element": {
            "type": "string",
            "value": "some_string_value"
        }
    }
}				
			
Edit
				
					{
    "api": "1.0",
    "error": null,
    "id": "_ID_",
    "result": {}
}				
			
Edit
Situation Error code Description
Bus send message operation timeout -32602 Bus request timeout
Bus incorrect message size (more then 100K) -32602 Bus message is too long
Bus data transfer another error -32602 Bus internal error