Skip to main content

Infrastructure Service

Sync Type: Incremental

Overview

The ServiceNow Infrastructure Service input fetches data from ServiceNow Table API. ServiceNow uses CMDB (Configuration Management Database) application to build logical representation of assets, Services, and the relationships between them that comprise the infrastructure of your organization. This input accesess data from cmdb_ci_infra_service table.

Prerequisites

Portal setup

  1. Login to your ServiceNow Instance.
  2. Navigate to Users
    • Click on All option and type Users. Select Users option from under System Security > Users and Groups.
  3. Create a New User
    • Fill out the details, most importantly First name, Last name and Email. Click Submit to save the info.
    • Click on New button to add a new User record.
  4. Locate the new user
    • Find the newly created user in the users list.
    • Click on the UserID to open the user record details.
  5. Assign Roles
    • In the user record details, a new "Roles" tab will appear at the bottom.
    • Click on "Edit" under the Roles tab, which will open a new page with all available roles.
    • For the Table API, you can either add all admin roles for the tables you want to retrieve data from or add the "general" admin role to give access to all tables.
    • Save the changes.
  6. Set Password
    • Return to the user record.
    • You will see a "Set Password" button next to the update and delete button.
    • Click the Set Password button, which will open a popup.
    • Click the "Generate" button inside the popup to create a password, then click "Save Password".
  7. Instance Name
    • Note the instance name of the ServiceNow instance for use in later steps. For example, if the URL to your ServiceNow instance is https://test-demo.service-now.com, the instance name will be test-demo.

OAuth Setup

⚠️ Important: Before setting up OAuth make sure you have security_admin role.

  1. Navigate to System OAuth > Application Registry.
  2. Click New and then click Create an OAuth API endpoint for external clients.
  3. Enter the name of the client and click the Submit button to generate Client Secret.
  4. Once generated note down Client ID and Client Secret.

Configuration

SettingTypeRequiredDescription
Instance namestringtrueInstance name found in URL of your ServiceNow instance
UsernamestringtrueYour ServiceNow instance username.
PasswordstringtrueYour ServiceNow instance password.
Client IDstringtrueClient ID of the application created in the Application Registry while setting up OAuth.
Client SecretstringtrueClient ID of the application created in the Application Registry while setting up OAuth.
Backfill start timestringNoThe date to start fetching data from. If not specified, no past records will be fetched.

Sample Record

{
"attested_date": "",
"operational_status": "1",
"running_process_command": "",
"sys_updated_on": "2008-10-26 17:16:08",
"running_process_key_parameters": "",
"rp_command_hash": "",
"discovery_source": "",
"first_discovered": "",
"due_in": "",
"used_for": "Production",
"is_clustered": "false",
"gl_account": "",
"invoice_number": "",
"sys_created_by": "admin",
"warranty_expiration": "",
"owned_by": "",
"checked_out": "",
"rp_key_parameters_hash": "",
"sys_domain_path": "",
"business_unit": "",
"version": "1.0",
"maintenance_schedule": "",
"cost_center": "",
"attested_by": "",
"dns_domain": "",
"provided_by": "",
"assigned": "",
"life_cycle_stage": "",
"purchase_date": "",
"short_description": "",
"managed_by": "",
"can_print": "false",
"last_discovered": "",
"sys_class_name": "cmdb_ci_web_server",
"manufacturer": "",
"cl_port": "",
"life_cycle_stage_status": "",
"vendor": "",
"model_number": "",
"config_file": "",
"assigned_to": "",
"start_date": "",
"serial_number": "",
"support_group": {
"link": "https://test-demo.service-now.com/api/now/table/sys_user_group/5f6441efc0a8010e0177fcb589156352",
"value": "5f6441efc0a8010e0177fcb589156352"
},
"correlation_id": "",
"unverified": "false",
"attributes": "",
"asset": {
"link": "https://test-demo.service-now.com/api/now/table/alm_asset/77c13e8837f3100044e0bfc8bcbe5d2e",
"value": "77c13e8837f3100044e0bfc8bcbe5d2e"
},
"config_directory": "",
"tcp_port": "",
"skip_sync": "false",
"product_instance_id": "",
"pid": "",
"attestation_score": "",
"sys_updated_by": "admin",
"install_directory": "",
"sys_created_on": "2008-10-26 17:16:08",
"sys_domain": {
"link": "https://test-demo.service-now.com/api/now/table/sys_user_group/global",
"value": "global"
},
"install_date": "",
"asset_tag": "",
"fqdn": "",
"change_control": "",
"delivery_date": "",
"install_status": "1",
"supported_by": "",
"name": "",
"subcategory": "",
"assignment_group": "",
"edition": "",
"managed_by_group": "",
"sys_id": "3a27d4370a0a0bb4006316812bf45439",
"po_number": "",
"checked_in": "",
"sys_class_path": "",
"mac_address": "",
"company": "",
"justification": "",
"department": "",
"comments": "",
"cost": "",
"attestation_status": "",
"sys_mod_count": "3",
"monitor": "false",
"ip_address": "",
"model_id": "",
"duplicate_of": "",
"sys_tags": "",
"cost_cc": "USD",
"order_date": "",
"schedule": "",
"environment": "",
"due": "",
"attested": "false",
"location": "",
"category": "",
"fault_count": "0",
"lease_id": ""
}