• /
  • EnglishEspañolFrançais日本語한국어Português
  • EntrarComeçar agora

Delete an alert policy

|View as Markdown (English)

The action identifier is newrelic.alerts.deletePolicy.

Deletes an existing alert policy. Deleting a policy also removes its association with any conditions that reference it.

The following table describes all available input fields for this action.

Input

Type

Description

Example

accountId

Int

Required. The New Relic account that owns the policy.

123456

id

String

Required. The ID of the policy to delete.

"2000002"

selectors

List

Optional. JQ selectors to extract values from the response.

selectors:
- name: deletedId
expression: ".data.alertsPolicyDelete.id"

The following table describes all output fields returned by this action.

Output

Type

Description

success

Boolean

true when the step executed without error.

errorMessage

String

Error message on failure. null on success.

data

Map

NerdGraph response containing the deleted policy's ID.

{
"data": {
"alertsPolicyDelete": {
"id": "2000002"
}
}
}

The following example deletes an alert policy.

Workflow example

name: delete_alert_policy
description: Delete an alert policy
steps:
- name: deletePolicy
type: action
action: newrelic.alerts.deletePolicy
version: 1
inputs:
accountId: ${{ .workflowInputs.accountId }}
id: ${{ .workflowInputs.policyId }}
next: end
Copyright © 2026 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.