1. Packages
  2. New Relic
  3. API Docs
  4. getAlertChannel
New Relic v5.33.0 published on Thursday, Sep 26, 2024 by Pulumi

newrelic.getAlertChannel

Explore with Pulumi AI

newrelic logo
New Relic v5.33.0 published on Thursday, Sep 26, 2024 by Pulumi

    Use this data source to get information about a specific alert channel in New Relic that already exists.

    WARNING: The newrelic.AlertChannel data source is deprecated and will be removed in the next major release.

    Example Usage

    Coming soon!
    
    Coming soon!
    
    Coming soon!
    
    Coming soon!
    
    Coming soon!
    
    resources:
      # Resource
      fooAlertPolicy:
        type: newrelic:AlertPolicy
        name: foo
        properties:
          name: foo
      # Using the data source and resource together
      fooAlertPolicyChannel:
        type: newrelic:AlertPolicyChannel
        name: foo
        properties:
          policyId: ${fooAlertPolicy.id}
          channelId: ${foo.id}
    variables:
      # Data source
      foo:
        fn::invoke:
          Function: newrelic:getAlertChannel
          Arguments:
            name: foo@example.com
    

    Using getAlertChannel

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getAlertChannel(args: GetAlertChannelArgs, opts?: InvokeOptions): Promise<GetAlertChannelResult>
    function getAlertChannelOutput(args: GetAlertChannelOutputArgs, opts?: InvokeOptions): Output<GetAlertChannelResult>
    def get_alert_channel(account_id: Optional[str] = None,
                          name: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetAlertChannelResult
    def get_alert_channel_output(account_id: Optional[pulumi.Input[str]] = None,
                          name: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetAlertChannelResult]
    func LookupAlertChannel(ctx *Context, args *LookupAlertChannelArgs, opts ...InvokeOption) (*LookupAlertChannelResult, error)
    func LookupAlertChannelOutput(ctx *Context, args *LookupAlertChannelOutputArgs, opts ...InvokeOption) LookupAlertChannelResultOutput

    > Note: This function is named LookupAlertChannel in the Go SDK.

    public static class GetAlertChannel 
    {
        public static Task<GetAlertChannelResult> InvokeAsync(GetAlertChannelArgs args, InvokeOptions? opts = null)
        public static Output<GetAlertChannelResult> Invoke(GetAlertChannelInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetAlertChannelResult> getAlertChannel(GetAlertChannelArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: newrelic:index/getAlertChannel:getAlertChannel
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    The name of the alert channel in New Relic.
    AccountId string
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.
    Name string
    The name of the alert channel in New Relic.
    AccountId string
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.
    name String
    The name of the alert channel in New Relic.
    accountId String
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.
    name string
    The name of the alert channel in New Relic.
    accountId string
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.
    name str
    The name of the alert channel in New Relic.
    account_id str
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.
    name String
    The name of the alert channel in New Relic.
    accountId String
    The New Relic account ID to operate on. This allows you to override the account_id attribute set on the provider. Defaults to the environment variable NEW_RELIC_ACCOUNT_ID.

    getAlertChannel Result

    The following output properties are available:

    AccountId string
    Config Pulumi.NewRelic.Outputs.GetAlertChannelConfig
    Alert channel configuration.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    PolicyIds List<string>
    A list of policy IDs associated with the alert channel.
    Type string
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.
    AccountId string
    Config GetAlertChannelConfig
    Alert channel configuration.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    PolicyIds []string
    A list of policy IDs associated with the alert channel.
    Type string
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.
    accountId String
    config GetAlertChannelConfig
    Alert channel configuration.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    policyIds List<String>
    A list of policy IDs associated with the alert channel.
    type String
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.
    accountId string
    config GetAlertChannelConfig
    Alert channel configuration.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    policyIds string[]
    A list of policy IDs associated with the alert channel.
    type string
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.
    account_id str
    config GetAlertChannelConfig
    Alert channel configuration.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    policy_ids Sequence[str]
    A list of policy IDs associated with the alert channel.
    type str
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.
    accountId String
    config Property Map
    Alert channel configuration.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    policyIds List<String>
    A list of policy IDs associated with the alert channel.
    type String
    Alert channel type, either: email, opsgenie, pagerduty, slack, victorops, or webhook.

    Supporting Types

    GetAlertChannelConfig

    ApiKey string
    AuthPassword string
    AuthType string
    AuthUsername string
    BaseUrl string
    Channel string
    Headers Dictionary<string, string>
    IncludeJsonAttachment string
    Key string
    Payload Dictionary<string, string>
    PayloadString string
    PayloadType string
    Recipients string
    Region string
    RouteKey string
    ServiceKey string
    Tags string
    Teams string
    Url string
    UserId string
    ApiKey string
    AuthPassword string
    AuthType string
    AuthUsername string
    BaseUrl string
    Channel string
    Headers map[string]string
    IncludeJsonAttachment string
    Key string
    Payload map[string]string
    PayloadString string
    PayloadType string
    Recipients string
    Region string
    RouteKey string
    ServiceKey string
    Tags string
    Teams string
    Url string
    UserId string
    apiKey String
    authPassword String
    authType String
    authUsername String
    baseUrl String
    channel String
    headers Map<String,String>
    includeJsonAttachment String
    key String
    payload Map<String,String>
    payloadString String
    payloadType String
    recipients String
    region String
    routeKey String
    serviceKey String
    tags String
    teams String
    url String
    userId String
    apiKey string
    authPassword string
    authType string
    authUsername string
    baseUrl string
    channel string
    headers {[key: string]: string}
    includeJsonAttachment string
    key string
    payload {[key: string]: string}
    payloadString string
    payloadType string
    recipients string
    region string
    routeKey string
    serviceKey string
    tags string
    teams string
    url string
    userId string
    apiKey String
    authPassword String
    authType String
    authUsername String
    baseUrl String
    channel String
    headers Map<String>
    includeJsonAttachment String
    key String
    payload Map<String>
    payloadString String
    payloadType String
    recipients String
    region String
    routeKey String
    serviceKey String
    tags String
    teams String
    url String
    userId String

    Package Details

    Repository
    New Relic pulumi/pulumi-newrelic
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the newrelic Terraform Provider.
    newrelic logo
    New Relic v5.33.0 published on Thursday, Sep 26, 2024 by Pulumi