ServiceNow Endpoints
Endpoint Summary
The following REST endpoints are used in the ServiceNow integration.
A POST is used the first time a resource is created. PATCH is used for any updates to that resource. This ensures that opIntegration only edits the attributes it is responsible for.
Endpoint | Purpose |
---|---|
api/now/table/cmdb_ci_linux_server | Represents a Linux server. |
/api/now/table/cmdb_ci_win_server | Represents a Windows server. |
/api/now/table/cmdb_ci_spkg | Represents a software package. |
/api/now/table/cmdb_software_instance | Represents a mapping between a server and a software package. Both the server and the software package need to be have been created in advance. |
/api/now/table/core_company | Represents a company. Once a company name is created, it is used in server.cpu_manufacturer and software.manufacturer. |
Sample JSON Documents
cmdb_ci_linux_server
{ "model_number" : "VMware, Inc. VMware Virtual Platform", "cpu_count" : 2, "manufacturer" : "VMware, Inc.", "first_discovered" : "2018-04-09 13:01:15", "dns_domain" : "us-west-1.compute.internal", "virtual" : true, "mac_address" : "00:0c:29:bf:a5:20", "cpu_core_count" : 2, "default_gateway" : "192.168.88.254", "cpu_manufacturer" : "Intel", "disk_space" : 81920, "cpu_type" : "", "last_discovered" : "2018-04-30 02:40:08", "ip_address" : "192.168.88.15", "cpu_core_thread" : 2, "serial_number" : "VMware-56 4d 4f 4d 53 e4 b8 fb-f8 ce ab 91 e7 bf a5 20", "cpu_speed" : 3600, "os_address_width" : "64", "os_domain" : "us-west-1.compute.internal", "gl_account" : "", "chassis_type" : "Virtual", "host_name" : "odem", "ram" : 3088228, "discovery_source" : "Open-AudIT API v1", "name" : "odem", "cd_rom" : false, "cpu_name" : "Intel Core i7-7700 CPU @ 3.60GHz", "asset_tag" : "", "os_version" : "6.9", "os" : "CentOS release 6.9 (Final)", "sys_domain" : "us-west-1.compute.internal", "fqdn" : "ip-192-168-88-15.us-west-1.compute.internal" }
cmdb_ci_win_server
This contains exactly the same fields as cmbd_ci_linux_server, with the addition of os_service_pack
{ "os_service_pack": "1" }
cmdb_ci_spkg
{ "last_discovered" : "2018-04-19 20:31:11", "discovery_source" : "Open-AudIT API v1", "manufacturer" : "", "name" : "dhclient", "version" : "4.1.1-53.P1.el6.centos.3", "first_discovered" : "2018-04-16 20:31:11" }
cmdb_ci_software_instance
{ "software" : "54176db0dbc11300a584d8c0cf961916", "installed_on" : "d3176db0dbc11300a584d8c0cf9619cb" }
core_company
{ "name" : "Intel" }