Skip to main content

system.kanoa.item.addItem(itemInfo, userId)

Adds an item. ItemInfo keys are required.


Parameters

itemInfo Dictionary

- enabledBoolean
- itemClassIdIntegerNone if this is an item at the root
- itemColorStringi.e '#00FF00'
- itemDescriptionString
- itemNameString

userId Integer


Returns

itemId Integer


Example

itemInfo = {
'itemName': 'Sausages',
'itemDescription': 'Delicious bangers',
'itemClassId': None,
'itemColor': None,
'enabled': True
}
itemId = system.kanoa.item.addItem(itemInfo, 123)