Skip to main content

Overview

New Relic is a full-stack observability platform. EasyContact supports both New Relic Workflows (recommended) and Classic Alerts formats for receiving incident notifications.
New Relic Workflows is the recommended method for new integrations. Classic Alerts is deprecated but still supported.

Setup Instructions (Workflows)

1

Create Integration in EasyContact

  1. Go to ConfigurationIntegrations
  2. Click Add Integration
  3. Select New Relic as the type
  4. Enter a name (e.g., “Production New Relic”)
  5. Save and copy the webhook URL
2

Create Destination in New Relic

  1. Go to Alerts & AIDestinations
  2. Click Add destination
  3. Select Webhook
  4. Enter your EasyContact webhook URL
  5. Save the destination
3

Create Workflow

  1. Go to Alerts & AIWorkflows
  2. Click Add workflow
  3. Configure filter (which issues to send)
  4. Add your webhook destination
  5. Configure the payload template
4

Test the Integration

Use the Send test notification feature

Workflow Configuration

Destination Setup

FieldValue
TypeWebhook
Endpoint URLYour EasyContact webhook URL
MethodPOST
{
  "issueId": {{ json issueId }},
  "issueUrl": {{ json issuePageUrl }},
  "title": {{ json annotations.title.[0] }},
  "description": {{ json annotations.description.[0] }},
  "priority": {{ json priority }},
  "state": {{ json state }},
  "triggerEvent": {{ json triggerEvent }},
  "createdAt": {{ json createdAt }},
  "updatedAt": {{ json updatedAt }},
  "closedAt": {{ json closedAt }},
  "totalIncidents": {{ json totalIncidents }},
  "impactedEntities": {{ json entitiesData.names }},
  "policyNames": {{ json accumulations.policyName }},
  "conditionNames": {{ json accumulations.conditionName }},
  "sources": {{ json accumulations.source }},
  "tags": {{ json accumulations.tag }}
}

Handlebars Variables

New Relic Workflows use Handlebars syntax:
VariableDescription
{{ issueId }}Unique issue identifier
{{ issuePageUrl }}Link to issue in New Relic
{{ annotations.title.[0] }}Issue title
{{ annotations.description.[0] }}Issue description
{{ priority }}CRITICAL, HIGH, MEDIUM, LOW
{{ state }}ACTIVATED, ACKNOWLEDGED, CLOSED
{{ triggerEvent }}STATE_CHANGE, INCIDENT_ADDED, etc.
{{ createdAt }}Creation timestamp
{{ updatedAt }}Last update timestamp
{{ totalIncidents }}Number of incidents
{{ entitiesData.names }}Impacted entity names
{{ accumulations.policyName }}Alert policy names
{{ accumulations.conditionName }}Alert condition names
{{ accumulations.source }}Alert sources
{{ accumulations.tag.* }}Custom tags

Field Mapping

Workflows Format

New Relic FieldEasyContact Field
issueIdEvent ID
annotations.title[0]Title
annotations.description[0]Description
prioritySeverity
stateStatus
entitiesData.namesHost/Service
issuePageUrlURL
accumulations.tag.*Tags

Classic Alerts Format

New Relic FieldEasyContact Field
incident_idEvent ID
condition_nameTitle
detailsDescription
severitySeverity
current_stateStatus
targets[0].nameHost
incident_urlURL

Severity Mapping

Workflows Priority Mapping

New Relic PriorityEasyContact Severity
CRITICALCritical
HIGHHigh
MEDIUMWarning
LOWInfo

Classic Severity Mapping

New Relic StateEasyContact Severity
criticalCritical
warningWarning

Status Handling

Workflows States

New Relic StateEasyContact Status
ACTIVATEDProblem
CREATEDProblem
ACKNOWLEDGEDProblem (acknowledged)
CLOSEDOK
DEACTIVATEDOK

Trigger Events

Trigger EventDescription
STATE_CHANGEIssue state changed
INCIDENT_ADDEDNew incident added to issue
INCIDENT_CLOSEDIncident closed
PRIORITY_CHANGEDPriority updated
ACKNOWLEDGEDIssue acknowledged

Example Payloads

Workflows Payload

{
  "issueId": "abc123-456-def",
  "issueUrl": "https://one.newrelic.com/alerts/issues/abc123",
  "title": "High CPU utilization",
  "description": "CPU usage exceeded 90% threshold",
  "priority": "CRITICAL",
  "state": "ACTIVATED",
  "triggerEvent": "STATE_CHANGE",
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:30:00Z",
  "totalIncidents": 1,
  "impactedEntities": ["web-server-01", "web-server-02"],
  "policyNames": ["Production Policy"],
  "conditionNames": ["High CPU Alert"],
  "sources": ["Infrastructure"],
  "tags": {
    "environment": ["production"],
    "team": ["platform"]
  }
}

Classic Alerts Payload

{
  "incident_id": "12345678",
  "account_id": "1234567",
  "account_name": "MyCompany",
  "condition_id": "11111",
  "condition_name": "High CPU Alert",
  "current_state": "open",
  "details": "CPU usage is above 90%",
  "event_type": "INCIDENT",
  "incident_acknowledge_url": "https://alerts.newrelic.com/accounts/1234567/incidents/12345678/acknowledge",
  "incident_url": "https://alerts.newrelic.com/accounts/1234567/incidents/12345678",
  "owner": "",
  "policy_name": "Production Policy",
  "policy_url": "https://alerts.newrelic.com/accounts/1234567/policies/22222",
  "runbook_url": "https://wiki.example.com/runbooks/high-cpu",
  "severity": "CRITICAL",
  "targets": [
    {
      "id": "33333",
      "name": "web-server-01",
      "type": "Host"
    }
  ],
  "timestamp": 1705315800000
}

Classic Alerts Setup

For legacy New Relic alerts:
1

Create Notification Channel

  1. Go to AlertsNotification channels
  2. Click New notification channel
  3. Select Webhook
2

Configure Webhook

  • Channel name: EasyContact
  • Base URL: Your EasyContact webhook URL
3

Add to Policies

  1. Go to your alert policy
  2. Add the webhook channel to notification settings

Enrichment Examples

{
  "enrichment": {
    "tags.source": "newrelic",
    "tags.environment": "production",
    "tags.platform": "apm"
  }
}

Workflow Filter Examples

Critical Issues Only

priority = 'CRITICAL'

Specific Policies

accumulations.policyName LIKE '%Production%'

Specific Entity Types

entitiesData.types = 'HOST'

Troubleshooting

  1. Test destination from New Relic UI
  2. Verify workflow filter matches your issues
  3. Check workflow is enabled
  4. Verify destination URL is correct
  1. Verify Handlebars template syntax
  2. Check field names match New Relic schema
  3. Use {{ json fieldName }} for proper formatting
  4. Test with simplified payload first
  1. Verify CLOSED state triggers workflow
  2. Check issueId matches between states
  3. Ensure workflow sends on all state changes
  1. Check priority field in payload
  2. Configure custom severity mapping
  3. Verify priority is set on alert conditions

Best Practices

Migrate to Workflows for better control and flexibility over Classic Alerts.
Add entitiesData.names to identify affected infrastructure or services.
Configure priority on your alert conditions for accurate severity mapping.
Add runbook links in alert conditions for quick remediation access.
Leverage accumulations.tag.* for routing and filtering in EasyContact.