Skip to main content

system.kanoa.asset.addAssetType

Requires kanoaOPS license

Description

Adds a new asset type.

Syntax

addAssetType(assetTypeInfo, userId)

Parameters:
  • assetTypeInfo (dict): Dictionary containing asset type information.
  • userId (int): User ID for tracking changes.

  • Returns:
  • assetTypeId (int)
  • Code Examples

    # Example Usage:
    type_info = {
    'assetTypeName': 'Type1',
    'parentId': 1,
    'enabled': True,
    'iconPath': '/path/to/icon'
    }
    user_id = 5
    asset_type_id = system.kanoa.asset.addAssetType(type_info, user_id)