CMDB (INC-CMDB)

Query Total CI Count by Privilege and CI Name

Query the total CI count based on the provided CI type name, operator name, and operator group name.

Interface URI

/cmdb/ci/readbyType/ciNums/{typeName}/userName/{userName}/groupName/{groupName}

Access Method

HTTP
GET
Parameters
Path parameters
typeName CI type name.
String type. Required. No default value.
userName Operator name.
String type. Required. No default value.
groupName Operator group name.
String type. Required. No default value.

Return Values

Status codes
  • 200 (OK): Success.
  • 404 (Not Found): Failure. The type name does not exist.
Message header
HTTP/1.1 200 OK
Message body
<result>
<commonStr>26</commonStr>
</result>
Query results and elements
ciInfo subelements
commonStr Total number of CIs.
String type.

Example

Query the total number of CIs with the CI type name as Device administrator, the operator name as admin, and the operator group name as Administrator group.

Request
GET http://host:8080/imcrs/cmdb/ci/readbyType/ciNums/Device administrator/userName/admin/groupName/Administrator group accept: application/xml ...
Response
HTTP/1.1 200 OK Content-Type: application/xml ... <result>
<commonStr>1</commonStr>
</result>