Import Set API

abbasyounas
Mega Contributor

when to use importset API and not?

what special advantages   over using tableAPI or Scripted services?

1 ACCEPTED SOLUTION

antin_s
ServiceNow Employee
ServiceNow Employee

ImportSet API Vs Table API - You will use ImportSet when you need to do more processing than just CRUD.


ImportSet API Vs Scripted API - With ImportSet, you don't have to create the API and/or table, the platform creates for you. You will concentrate on process and transform.



Hope this helps. Mark the answer as correct/helpful based on impact.



Thanks


Antin


View solution in original post

3 REPLIES 3

Harsh Vardhan
Giga Patron

Hi Abbas,



Rest API: To become familiar with ServiceNow REST APIs, review this scenario which assumes that you are an integration consultant who wants to see how easily you can integrate with the Incident [incident] table using the REST Table API. The REST Table API is active by default in all instances, starting with the Eureka release.


The tasks you will perform are:


-View available resources.


-Query existing incident records.


-Create a new incident record.


-Retrieve the record you created.


-Update the record.


-Delete the record.



Scripted Rest API: The Scripted REST APIs feature allows application developers to build web service APIs.You can define service endpoints, query parameters, and headers for a scripted web service API, as well as scripts to manage the request and response.Scripted REST APIs generally follow the REST architecture, but may be customized to use different conventions.The following podcast offers additional information on the use of Scripted REST APIs.




Scripted Rest APIs - Part 1


Scripted REST APIs - Part 2


difference between REST message and scripted RESTAPI?


Testing REST web services through Firefox RESTClient or POSTMAN



Real-time CMDB: Mapping as a Service



Ask the Expert : Geneva - Scripted REST APIs


tony_barratt
ServiceNow Employee
ServiceNow Employee

Hi Abbas,



Yes - use an import set api.


If say you are expecting incidents to be created and updated from a 3rd party, then all the 3rd party has to do is to send data across and the "smart" import set will decide whether to create a new incident or update an existing one.


Any question about did ServiceNow process the data as expected can be answered by inspecting the import set data for what arrived at the instance - which is kept by default for 7 days.


Variation in processing required? No problem, tweak it with transform maps and transform map scripts.



Alternative is to use the table api - if you go that route the 3rd party has to send posts and patch or puts and maybe gets as well.



It could be that some else will drop by and explain that actually table api is preferable in some other situations or even in most situations.


That would lead to quite an interesting discussion I guess.



Here are two links for Istanbul which might be useful


Import Set API


Table API



If the reply was informational, please like, mark as helpful or mark as correct!


antin_s
ServiceNow Employee
ServiceNow Employee

ImportSet API Vs Table API - You will use ImportSet when you need to do more processing than just CRUD.


ImportSet API Vs Scripted API - With ImportSet, you don't have to create the API and/or table, the platform creates for you. You will concentrate on process and transform.



Hope this helps. Mark the answer as correct/helpful based on impact.



Thanks


Antin