ServiceNow Integration for Runbooks
Harness Incident Response integrates with ServiceNow through a Connector-based approach, enabling automated incident management and tracking.
Overview
ServiceNow integration enables your runbooks to:
- Create and update incidents
- Track incident progress
- Manage CMDB records
- Automate workflow transitions
- Sync incident updates bidirectionally
Connector-Based Integration
Prerequisites
- ServiceNow admin access
- Instance URL
- Service account credentials
- Harness Project Admin role
Setup Steps
- Navigate to Settings → Connectors
- Click + New Connector
- Select ServiceNow
- Configure authentication:
- Instance URL
- Username
- Password/OAuth credentials
- Test connection
Required Permissions
- incident_manager role
- itil role
- rest_service role
- web_service_admin role
Using ServiceNow in Runbooks
Incident Creation
- Action Type: ServiceNow
Operation: Create Incident
Category: "Infrastructure"
Impact: "[incident.severity]"
ShortDescription: "[incident.service] Incident"
Description: |
Impact: [incident.description]
Service: [incident.service]
Environment: [incident.environment]
Update Incident
- Action Type: ServiceNow
Operation: Update Incident
Number: "[servicenow.number]"
Fields:
Priority: "[incident.severity]"
Assignment_group: "SRE Team"
Comments: "Automated response initiated"
State Management
- Action Type: ServiceNow
Operation: Update State
Number: "[servicenow.number]"
State: "In Progress"
WorkNotes: "Incident response team engaged"
Directional Synchronization with IR
Harness IR uses runbook triggers to update ServiceNow when incident fields change. When a field in IR changes, a runbook can automatically update the corresponding ServiceNow incident.
Field Change Triggers
Configure runbooks to trigger on field changes:
- State changes
- Priority updates
- Severity modifications
- Assignment changes
Example: State Change Sync
Trigger:
Type: Field Change
Field: state
Actions:
- Action Type: ServiceNow
Operation: Update State
Number: "[servicenow.number]"
State: "[incident.state]"
WorkNotes: "State updated from IR"
Example: Priority Sync
Trigger:
Type: Field Change
Field: priority
Actions:
- Action Type: ServiceNow
Operation: Update Incident
Number: "[servicenow.number]"
Fields:
Priority: "[incident.priority]"
WorkNotes: "Priority updated from IR"
Advanced Features
Bidirectional Sync (Coming Soon)
Future Capability
The following features are planned for future releases:
- Real-time incident synchronization
- Work notes mirroring
- CMDB integration
- Workflow state mapping
Planned Capabilities
-
Incident Sync
- ServiceNow → Harness IR status mapping
- Automatic state transitions
- Priority synchronization
-
Work Notes Sync
- Bidirectional updates flow
- Attachment synchronization
- User mapping
-
CMDB Integration
- CI relationship mapping
- Impact analysis
- Service dependency tracking
Best Practices
Incident Management
- Use standard categorization
- Include business impact
- Link configuration items
- Maintain SLA tracking
Workflow Integration
- Define clear state mappings
- Document transition rules
- Set up appropriate triggers
- Monitor sync status
Field Configuration
- Map essential fields
- Use custom fields appropriately
- Document field purposes
- Validate field values
Common Use Cases
Major Incident Management
- Create ServiceNow incident
- Assign response teams
- Track resolution progress
- Update stakeholders
Change Management
- Create change requests
- Track approvals
- Document implementations
- Update CMDB
SLA Compliance
- Monitor response times
- Track resolution progress
- Generate reports
- Escalate as needed
Troubleshooting
Common Issues
-
Authentication Failures
- Verify credentials
- Check roles/permissions
- Confirm instance access
-
Field Update Errors
- Validate field names
- Check required fields
- Verify field formats
-
State Transition Issues
- Check workflow rules
- Verify state mappings
- Confirm permissions