HTTP Import from data source

There may be times where you want to grab a CSV, Excel, or XML file from a place on the Internet to perform your imports. Maybe your third party integration system publishes XML documents that are accessible on demand on or an scheduled basis. Your goal is to grab the file at the given URL and import it into your ServiceNow instance. The easiest way to do this is via a Data Source set up to grab files via HTTP.

Let’s say I have a third-party tool that publishes a CSV file that contains data that is supposed to generate incidents in ServiceNow. The tool publishes the CSV file at the following URL every day at 3AM. We want to create a data source that grabs the file, imports the data into an import set, and generates incident records in our ServiceNow instance. Let’s say the URL for our file will always be: http://john-james-andersen.com/wp-content/uploads/httpincident.csv

First, we create the data source:

HTTP Data Source in ServiceNow

Here are the settings I used:

Name: Incidents via HTTP
Import Set Table Label: Incident Import (I made this up for the example)
Import Set Table Name: u_incident_import (this was generated for me)
Type: File
Format: CSV
File Retrieval Method: HTTP
File Path: /wp-content/uploads/httpincident.csv
Server: john-james-andersen.com

It is important to note that you don’t prefix your Server name with “HTTP://”. The system will do this for you.

Also, note, that if your URL requires basic authentication to access the resource, you can include the username and password on the data source record.

I then create the following transform map for my CSV file:

Transform map for HTTP Data Source

Once I run a load, and transform, I see the following incidents in my system: