AppDynamics ServiceNow REST API Alerting Extension

Use Case

ServiceNow ( is a software-as-a-service (SaaS) provider of IT service management (ITSM) software. AppDynamics integrates directly with ServiceNow to create tickets in response to alerts. With the ServiceNow integration you can leverage your existing ticketing infrastructure to notify your operations team to resolve performance degradation issues.

Note: This extension works only with AppDynamics Health Rule Violation events.



To post events to ServiceNow user should have "rest_service" role.


Installation Steps

  1. Find the zip file at ''.

  2. Unzip the file into <CONTROLLER_HOME_DIR>/custom/actions/ . You should have <CONTROLLER_HOME_DIR>/custom/actions/servicenow-api-alert created.

  3. Check if you have custom.xml file in <CONTROLLER_HOME_DIR>/custom/actions/ directory. If yes, add the following xml to the element.

        <!-- For Linux/Unix *.sh -->
        <!-- For windows *.bat -->

    If you don't have custom.xml already, create one with the below xml content

            <!-- For Linux/Unix *.sh -->
            <!-- For windows *.bat -->

    Uncomment the appropriate executable tag based on windows or linux/unix machine.

    1. Update the config.yaml file in <CONTROLLER_HOME_DIR>/custom/actions/servicenow-api-alert/conf/ directory with the domain, username, password and serviceNowVersion. You can also configure the default service now details like assignmentGroup, assignedTo, callerId, category, location.


Make sure that you do not use tab (\t) while editing yaml files. You may want to validate the yaml file using a yaml validator

    #ServiceNow Domain
    domain: ""

    #ServiceNow User
    username: "admin"

    #ServiceNow Password, provide password or passwordEncrypted and encryptionKey.

    passwordEncrypted: "0LKLGb4hc3pAczHmzxQ5ig=="
    encryptionKey: "welcome123"

    #ServiceNow Version
    serviceNowVersion: "Fuji"

    #Proxy server URI
    #Proxy server user name
    #Proxy server password

    #ServiceNow User Specific
    #Please define your ServiceNow specific fields here like assignment_group, assigned_to, caller_id, category and location.
    #The name should be a valid Incident table's column name.
    #Do not add properties short_description, comments, impact and priority here, as they are added by the extenson automatically
       - name: "assignment_group"
         value: "Capacity Mgmt"
       - name: "assigned_to"
         value: "Don Goodliffe"
       - name: "caller_id"
         value: ""
       - name: "category"
         value: "request"
       - name: "location"
         value: "Denver"
       - name: "contact_type"
         value: "email"

Password Encryption

To set passwordEncrypted in config.yaml, follow the steps below:

  1. Download the util jar to encrypt the password from here.
  2. Run command:

    java -cp appd-exts-commons-1.1.2.jar com.appdynamics.extensions.crypto.Encryptor EncryptionKey CredentialToEncrypt
    For example: 
    java -cp "appd-exts-commons-1.1.2.jar" com.appdynamics.extensions.crypto.Encryptor test password
  3. Set the resulting encrypted password in passwordEncrypted field and the encryption key used in encryptionKey field in config.yaml file


The AppDynamics event's parameters are associated with ServiceNow parameters as follows:

AppDynamics ParametersServiceNow ParametersComments
 assigned_toThis is the field used to assign an incident to an individual/department. The email address or full name of the designated user can be written here. This should be entered into the file as an email address that is already configured in the ServiceNow environment.
descriptionThe format is as follows for the following Policy Violation Parameters:
Variable name: Variable value
Application Name: APP_NAME
Policy Violation Alert Time: PVN_ALERT_TIME
Severity: SEVERITY
Name of Violated Policy: POLICY_NAME
Affected Entity Type: AFFECTED_ENTITY_TYPE
Name of Affected Entity: AFFECTED_ENTITY_NAME
Evaluation Entity #x
Evaluation Entity: EVALUATION_TYPE
Evaluation Entity Name: EVALUATION_ENTITY_NAME
Triggered Condition #x
Scope Type: SCOPE_TYPE_x
Scope Name: SCOPE_NAME_x
THRESHOLD_VALUE_x (this is for ABSOLUTE conditions)
Violation Value: OBSERVED_VALUE_x
SEVERITYimpactRepresents the impact of the new Problem. Use the SEVERITY parameter where: ERROR = 1, WARN = 2, and INFO = 3
 knowledgeThis is either "true" or "false" but for policy violations, leave this as "false".
 known_errorThis is either "true" or "false" but for policy violations, leave this as "true".
PRIORITYpriorityThis is a value from 1 to 5 where: 1 = Critical, 2 = High, 3 = Moderate, 4 = Low, 5 = Planning. The PRIORITY parameter will fill this out directly.


Look for the newest created Incident in ServiceNow

When incident is created through AppDynamics it should look similar to the following screenshots. The following is an overview shot of ServiceNow:

The following shows the specifics of the ticket description:

Note: Notice that the "assigned to" field has "ITIL User" current in place here. This is taken from config.yaml.



Comments are only shown in REST API supported versions (Eureka, Fuji). In older versions (Calgary, Dublin) comments are not visible.

From version 1.4, we have added support to display comments in the Calagry and Dublin version too. To achieve this, instead of REST API we are using SOAP API to create incidents.




Always feel free to fork and contribute any changes directly via GitHub.




For any questions or feature request, please contact AppDynamics Center of Excellence.






Service Now Versions:

Calgary, Dublin, Eureka, Fuji

Last Update:

4 July 2016


Note: This extension works only with a dedicated SaaS controller or an on-prem controller. Alerting extensions, currently do not support multi-tenant SaaS controllers. 


Release Notes:

  • Version 1.0.0 (01/19/2015)

    1) Built the new extenson to support latest service now versions.



  • Version 1.1 (08/06/2015)

    1) Made ServiceNow config parameters optional



  • Version 1.2 (10/02/2015)

    1) Added support for password encryption



  • Version 1.3 (01/29/2016)

    1) Code changes to support comments in JSONv2 supported versions of SNOW


  • Version 1.4 (03/15/2016)

    1) Code changes to support comments in older versions of SNOW using SOAP API

  • Version 2.0 (04/06/2016)

    1) Fixed log4j.xml issues


  • Version 2.2 (04/07/2016)

    1) Fixed issue with bat file

    2) Using latest appd commons and http client