KSC Open API
Kaspersky Security Center API description
array ListTags::GetAllTags ( params  pParams = NULL)

Get all existing tag values.

Retrieves all known tag values that can be set for a list item

Parameters:
pParams(params) object with attributes:
  • "KLTAGS_INCLUDE_VS" (boolean) optional flag. true(default) - to include tags information from virtual servers, false - to exclude tags information from virtual servers
Returns:
(array) of paramString - tags.

See also Python code with use of KlAkOAPI Python package below:

        server = KlAkOAPI.AdmServer.KlAkAdmServer.Create("https://ksc.example.com:13299", "username", "password", verify = False)
        oTagsControl = KlAkOAPI.ListTags.KlAkListTags(server, 'HostsTags')
        oTags = oTagsControl.GetAllTags(None).RetVal()
        if oTags != None and len(oTags) > 0:
            for oObj in oTags:
               print("Tag: ", oObj)