How can I use the sys id as an identifier for IRE?

Erick18
Mega Guru

I am wanting to use IRE specifically data source priority for updating the cmdb. I am wanting to create a flow to update the cmdb that uses IRE. If I already know the CI I want to update, how can I use the sys_id of the ci to identify the record I want to update. I tried adding sys_id as a identifier, but it is not available to choose as a field. 

 

Thanks, 

Erick

1 ACCEPTED SOLUTION

Sandeep90
ServiceNow Employee
ServiceNow Employee

You can just call with sys_id as a value to the IRE API and you don't need to configure any identifier rules with sys_id for it.  

Example:

var payload = {
"items": [
{
"className": "cmdb_ci_linux_server",
"values": {
"short_description" : "Demo payload update",
"sys_id": "61f4dec51bee01101f26cbfc0a4bcbc1"
}
}
]
}
var input = new JSON().encode(payload);
var output = SNC.IdentificationEngineScriptableApi.createOrUpdateCIEnhanced('ServiceNow', input,{});
gs.print(JSON.stringify(JSON.parse(output),null,'\t'));

 

In order to learn more about the APU use this doc https://docs.servicenow.com/bundle/utah-api-reference/page/app-store/dev_portal/API_reference/Identi... 

View solution in original post

2 REPLIES 2

Sandeep90
ServiceNow Employee
ServiceNow Employee

You can just call with sys_id as a value to the IRE API and you don't need to configure any identifier rules with sys_id for it.  

Example:

var payload = {
"items": [
{
"className": "cmdb_ci_linux_server",
"values": {
"short_description" : "Demo payload update",
"sys_id": "61f4dec51bee01101f26cbfc0a4bcbc1"
}
}
]
}
var input = new JSON().encode(payload);
var output = SNC.IdentificationEngineScriptableApi.createOrUpdateCIEnhanced('ServiceNow', input,{});
gs.print(JSON.stringify(JSON.parse(output),null,'\t'));

 

In order to learn more about the APU use this doc https://docs.servicenow.com/bundle/utah-api-reference/page/app-store/dev_portal/API_reference/Identi... 

Thanks @Sandeep90 It helped me alot !

 

-Cheers,
Rahul