ASTCMDBINSERT
This method allows adding a relationship in CMDB through a REST web service. The recorded relationship will be available in CMDB in asset data.
POST /apigateway/se/generic/gn_webservice/gn_webservice_execute.php
Query parameters:
Query parameters | Type | Required | Description |
---|---|---|---|
cdprod | Numeric | Yes | Product codeConstant value: 109 |
classname | String | Yes | Class name used in WADLConstant value: CMDBInsertRelationshipInterface |
classpath | String | Yes | Path to the class used in WADLConstant value: ast_import |
Example request:
Supported attributes:
Request body parameter | Type | Required | Description |
---|---|---|---|
TypeFrom | String | Yes | Source object type: 1 - Asset; 2 - Process; 3 - Process activity. |
IdentifierFrom | String | Yes | Source object ID # |
TypeTo | String | Yes | Destination object type: 1 - Asset; 2 - Process; 3 - Process activity. |
IdentifierTo | String | Yes | Destination object ID # |
RelationshipName | String | Yes | Relationship name |
ReverseRelationship | String | Yes | Reverse relationship: 1 - Yes; 2 - No. |
{
"TypeFrom": "string",
"IdentifierFrom": "string",
"TypeTo": "string",
"IdentifierTo": "string",
"RelationshipName": "string",
"ReverseRelationship": "string"
}
Example response:
200 OK
{
"success": true,
"total": 1,
"results": [
{
"Result": true,
"Code": 1
}
]
}