Integrate Instana with OAuth authentication
Integrate Instana with Event Management with ServiceNow using OAuth authentication.
Vorbereitungen
Ensure that the Event Management Connectors (sn_em_connector) plugin is installed on the ServiceNow AI Platform instance.
Role required: evt_mgmt_admin
Prozedur
-
Configuration on the ServiceNow instance.
- Create glide.oauth.inbound.client.credential.grant_type.enabled system property to use Client Credentials grant type for OAuth inbound integrations.
- Type: true|false
- Value: true
Hinweis:An administrator must create this system property because the evt_mgmt_admin role lacks permission to do so. - Create an OAuth Entity endpoint for clients to access the instance.
- Navigate to All > System OAuth > Application Registry and then select New.
- On the interceptor page, select Create an OAuth API endpoint for external clients and then fill in the form.
- To create an OAuth client record, select Submit.
- Add the OAuth Application User and the Default Grant Type to the created OAuth client record.
- On the OAuth Entity form, add the OAuth Application User and the Default Grant Type fields to use the Client Credentials grant type for OAuth inbound integrations.
- Open the created OAuth client record.
- From the page header, select the More options icon.
- Select Configure > Form Layout
- On the Form Layout page, add OAuth Application User and Default Grant Type from the list of fields.
- Save or Update the form.
- For the OAuth Application User field, select the user.The user must have the evt_mgmt_integration role that will be used to create the events sent by Grafana.Hinweis:To ensure proper authentication, use the least privileged user with the evt_mgmt_integration role, rather than a high privileged user.
- Set Default Grant Type field value to Client Credentials.
- Create glide.oauth.inbound.client.credential.grant_type.enabled system property to use Client Credentials grant type for OAuth inbound integrations.
- In the Instana console, navigate to Settings > Events & Alerts > Alert Channels.
- Open the Add Alert Channel drop-down list and select the Generic Webhook option.
-
In the Webhook URLs field, create an alert channel by entering the following URL:
https://<instance>.service-now.com/api/sn_em_connector/em/inbound_event?source=instana.
-
Enable the Enable OAuth toggle switch to authenticate the ServiceNow URL.
- In the Client ID field, provide the client id value of the OAuth Entity Client created in ServiceNow instance.
- In the Client Secret field, provide the client secret value of the OAuth Entity Client created in ServiceNow instance.
- In the Token URL field, enter https://<instance_name>.servicenow.com/oauth_token.do
- To test the integration, select Test channel
- Select Save.
-
Configure Instana to create alerts for event types or events.
- Navigate to Settings > Events & Alerts > Alerts.
- Select New Alert.
-
In the Events section, select one of the following:
- Alert on Event Type(s)
- Alert on Event(s)
-
When creating alerts for event types:
- Select the type of events for which you want alerts to be created, such as Critical Issues, All Incidents, Warning issues, and so forth.
- In the Alerting section, select the servicenow alert channel.
-
When creating alerts for events:
- Select the events for which you want alerts to be created.
- In the Alerting section, select the servicenow alert channel.
When Instana creates an alert, the alert is sent to the ServiceNow instance. Alerts created for the host entity are bound to the Server (cmdb_ci_server) table, and alerts created for the website entity are bound to the HTTP(S) (cmdb_ci_endpoint_http) table.Add other entity types in the Instana - ci_type Event Field Mapping table to ensure that the entity binds with the correct CI in the ServiceNow instance.
-
To view the event in the Instana source system, you can access it from a ServiceNow instance:
- Navigate to All > Event Management > Service Operations Workspace.
- Select All Alerts.
- Select the relevant alert.
- On the Details tab, locate the Actions section on the right side of the page and in the Show Event on Instana UI cell, select Launch app.