Get CI Informations during TopDown Discovery

TeeKaypA
Tera Expert

Hi all,

 

Can I access information of specific CI in a discovery pattern? I have to create a connection to a CI, but I don't know on which server this CI is running. However, horizontal discovery has already stored this information in the CMDB and therefore it would be great to get this information. Is there a way to get this informations? Host, Ports etc.

 

Thanks

Thomas

2 ACCEPTED SOLUTIONS

Prabu Velayutha
Mega Sage
Mega Sage

If you know in CMDB table data is located, then try to use the HTTP Get Call operation step to extract data on CI types with using the CMDB instance APIs, hope you can retrieve the data you expect.

Reference Product Document:

https://docs.servicenow.com/bundle/utah-it-operations-management/page/product/service-mapping/task/h...

 

View solution in original post

TeeKaypA
Tera Expert

Hi Guys,

This is the way to go if you need cmdb/ci information during topdown discovery.

Using GlideRecord scripting in Service Mapping Pat... - ServiceNow Community

View solution in original post

15 REPLIES 15

Hi @Prabu Velayutha 

 

I built a get ci-query  inside rest api explorer which worked well. Now, if I make the get call inside the pattern, I get an authentication error.

Just checked the docs but could not find help.

 

Thanks Thomas

 

I would also like to know how I can add further attributes to the result of the query.

 

You can add the fields under sysparm fields. Refer blow screenshot for sample. Let me know if you need more details.

 

PrabuVelayutha_0-1690383845976.png


If my response helped please mark it helpful

@TeeKaypA  Can you try creating a Basic auth credential for discovery, make sure the servicenow user account has the Rest API read access which you use for Basic Auth. You can test It.

If my response helped please mark it helpful.

@Prabu Velayutha 

 

- created a user with needed role

- created basic auth cred with before created user/pw

 

but i dont get the point how the mid-server should know this credential?

mid server is already running with a user which has the needed role but it does not work like this ...

TeeKaypA_0-1690385028565.png