Add Configuration Item (CI) Attributes
To add CI Attributes to a CI Type, use the following URL format:
http://<hostname>:<port>/api/cmdb/ci/citypeattributes
Assuming you want to add CI Attributes to a CI Type in the local server with port number 8080, the URL should be given as:
http://localhost:8080/api/cmdb/ci/citypeattributes
Keypoints:
-
Input is an XML string sent as "POST attribute" with key "INPUT_DATA".
-
The operation name "add" should be sent as a "POST attribute" with key "OPERATION_NAME".
-
The technician key should be sent as a "POST attribute" with key "TECHNICIAN_KEY".
|
Note:
If no result format specified then API will return output in JSON format. |
Sample Input XML for adding CI Type Attributes to CI Type Access Point
<?xml version="1.0" encoding="UTF-8"?>
<API version="1.0" locale="en">
<addattribute>
<tocitype>Access Point</tocitype>
<attributes>
<attribute>
<parameter><name>Attribute Name</name><value>Cost Center</value></parameter>
<parameter><name>Description</name><value>Access Point coverage area in meters</value></parameter>
<parameter><name>Type</name><value>single-line</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Account Number</value></parameter>
<parameter><name>Description</name><value>Issues in business service for mulit line</value></parameter>
<parameter><name>Type</name><value>single-line</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Resolution</value></parameter>
<parameter><name>Description</name><value>Issues in business service for mulit line</value></parameter>
<parameter><name>Type</name><value>multi-line</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Bank Account</value></parameter>
<parameter><name>Description</name><value>number of issues while creating business service</value></parameter>
<parameter><name>Type</name><value>number</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Depreciation Amount</value></parameter>
<parameter><name>Description</name><value>number of issues while creating business service</value></parameter>
<parameter><name>Type</name><value>number</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Renewal Date</value></parameter>
<parameter><name>Description</name><value>Dated issues while creating business service</value></parameter>
<parameter><name>Type</name><value>datetime</value></parameter>
</attribute>
<attribute>
<parameter><name>Attribute Name</name><value>Pick Service Type</value></parameter>
<parameter><name>Description</name><value>Types of services while creating business service</value></parameter>
<parameter><name>Type</name><value>pick-list</value></parameter>
<parameter><name>List Item</name><value>Switch-1,Switch-2,Switch3</value></parameter>
</attribute>
</attributes>
</addattribute>
</API>
<?xml version="1.0" encoding="UTF-8"?>
<API locale="en" version="1.0">
<response>
<result>
<statuscode>200</statuscode>
<status>Success</status>
<message>Relationship added successfully.</message>
<created-date>Mon Jul 05 18:18:39 GMT+05:30 2010</created-date>
</result>
</response>
</API>