API call to get a list of assignment groups

bigbacon
Giga Guru

Is this possible to do using the API?

We have a service that can create tickets for us but I would like to be able to determine if the assignment group being used exists or not before trying to submit the ticket.

we are using C# to make the API calls.

10 REPLIES 10

Abhinay Erra
Giga Sage

You can use scripted rest api to achieve this. Pass in assignment group name/sys_id as a path parameter in the end point. Then make a gliderecord query to sys_user_group table to determine if the group exists


are there example of using the scripted API in asp.net out there?



Where do you find the sys_id?


gcubed_
Tera Contributor

Is your existing C# code using SOAP or REST?



Both the SOAP and REST table API would provide you the ability to query the sys_user_group table to check for given group name which would return to you the sys_id if found.



For a SOAP wsdl, just use the table name with a WSDL parameter: https://instance.service-now.com/sys_user_group.do?WSDL



I tend to use the SOAP interfaces with C# with ASP.NET and REST with C# and WebAPI.



V/r,


Gene


maybe that was the better question to ask



Where do I find all the different SOAP WDSL URLs?