1. Packages
  2. Zenduty Provider
  3. API Docs
  4. getAlertrules
zenduty 1.0.4 published on Wednesday, Apr 2, 2025 by zenduty

zenduty.getAlertrules

Explore with Pulumi AI

zenduty 1.0.4 published on Wednesday, Apr 2, 2025 by zenduty
import * as pulumi from "@pulumi/pulumi";
import * as zenduty from "@pulumi/zenduty";

const examplealertrules = zenduty.getAlertrules({
    integrationId: "",
    serviceId: "",
    teamId: "",
});
Copy
import pulumi
import pulumi_zenduty as zenduty

examplealertrules = zenduty.get_alertrules(integration_id="",
    service_id="",
    team_id="")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/zenduty/zenduty"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := zenduty.LookupAlertrules(ctx, &zenduty.LookupAlertrulesArgs{
			IntegrationId: "",
			ServiceId:     "",
			TeamId:        "",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Zenduty = Pulumi.Zenduty;

return await Deployment.RunAsync(() => 
{
    var examplealertrules = Zenduty.GetAlertrules.Invoke(new()
    {
        IntegrationId = "",
        ServiceId = "",
        TeamId = "",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.zenduty.ZendutyFunctions;
import com.pulumi.zenduty.inputs.GetAlertrulesArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var examplealertrules = ZendutyFunctions.getAlertrules(GetAlertrulesArgs.builder()
            .integrationId("")
            .serviceId("")
            .teamId("")
            .build());

    }
}
Copy
variables:
  examplealertrules:
    fn::invoke:
      function: zenduty:getAlertrules
      arguments:
        integrationId: ""
        serviceId: ""
        teamId: ""
Copy
import * as pulumi from "@pulumi/pulumi";

export const zendutyAlertrules = data.zenduty_alertrules.examplealertrules.alertrules;
Copy
import pulumi

pulumi.export("zendutyAlertrules", data["zenduty_alertrules"]["examplealertrules"]["alertrules"])
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ctx.Export("zendutyAlertrules", data.Zenduty_alertrules.Examplealertrules.Alertrules)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;

return await Deployment.RunAsync(() => 
{
    return new Dictionary<string, object?>
    {
        ["zendutyAlertrules"] = data.Zenduty_alertrules.Examplealertrules.Alertrules,
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        ctx.export("zendutyAlertrules", data.zenduty_alertrules().examplealertrules().alertrules());
    }
}
Copy
outputs:
  zendutyAlertrules: ${data.zenduty_alertrules.examplealertrules.alertrules}
Copy

Using getAlertrules

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 getAlertrules(args: GetAlertrulesArgs, opts?: InvokeOptions): Promise<GetAlertrulesResult>
function getAlertrulesOutput(args: GetAlertrulesOutputArgs, opts?: InvokeOptions): Output<GetAlertrulesResult>
Copy
def get_alertrules(alert_rule_id: Optional[str] = None,
                   id: Optional[str] = None,
                   integration_id: Optional[str] = None,
                   service_id: Optional[str] = None,
                   team_id: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetAlertrulesResult
def get_alertrules_output(alert_rule_id: Optional[pulumi.Input[str]] = None,
                   id: Optional[pulumi.Input[str]] = None,
                   integration_id: Optional[pulumi.Input[str]] = None,
                   service_id: Optional[pulumi.Input[str]] = None,
                   team_id: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetAlertrulesResult]
Copy
func LookupAlertrules(ctx *Context, args *LookupAlertrulesArgs, opts ...InvokeOption) (*LookupAlertrulesResult, error)
func LookupAlertrulesOutput(ctx *Context, args *LookupAlertrulesOutputArgs, opts ...InvokeOption) LookupAlertrulesResultOutput
Copy

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

public static class GetAlertrules 
{
    public static Task<GetAlertrulesResult> InvokeAsync(GetAlertrulesArgs args, InvokeOptions? opts = null)
    public static Output<GetAlertrulesResult> Invoke(GetAlertrulesInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetAlertrulesResult> getAlertrules(GetAlertrulesArgs args, InvokeOptions options)
public static Output<GetAlertrulesResult> getAlertrules(GetAlertrulesArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: zenduty:index/getAlertrules:getAlertrules
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

IntegrationId This property is required. string
unique_id of the integration
ServiceId This property is required. string
unique_id of the service
TeamId This property is required. string
unique_id of the team
AlertRuleId string
unique_id of the alert rule
Id string
IntegrationId This property is required. string
unique_id of the integration
ServiceId This property is required. string
unique_id of the service
TeamId This property is required. string
unique_id of the team
AlertRuleId string
unique_id of the alert rule
Id string
integrationId This property is required. String
unique_id of the integration
serviceId This property is required. String
unique_id of the service
teamId This property is required. String
unique_id of the team
alertRuleId String
unique_id of the alert rule
id String
integrationId This property is required. string
unique_id of the integration
serviceId This property is required. string
unique_id of the service
teamId This property is required. string
unique_id of the team
alertRuleId string
unique_id of the alert rule
id string
integration_id This property is required. str
unique_id of the integration
service_id This property is required. str
unique_id of the service
team_id This property is required. str
unique_id of the team
alert_rule_id str
unique_id of the alert rule
id str
integrationId This property is required. String
unique_id of the integration
serviceId This property is required. String
unique_id of the service
teamId This property is required. String
unique_id of the team
alertRuleId String
unique_id of the alert rule
id String

getAlertrules Result

The following output properties are available:

Supporting Types

GetAlertrulesAlertrule

Actions This property is required. List<GetAlertrulesAlertruleAction>
The actions of the alert rule as a list of maps:
Description This property is required. string
The description of the alert rule
Position This property is required. double
RuleJson This property is required. string
The JSON representation of the alert rule
RuleType This property is required. double
Stop This property is required. bool
UniqueId This property is required. string
The unique_id of the action
Actions This property is required. []GetAlertrulesAlertruleAction
The actions of the alert rule as a list of maps:
Description This property is required. string
The description of the alert rule
Position This property is required. float64
RuleJson This property is required. string
The JSON representation of the alert rule
RuleType This property is required. float64
Stop This property is required. bool
UniqueId This property is required. string
The unique_id of the action
actions This property is required. List<GetAlertrulesAlertruleAction>
The actions of the alert rule as a list of maps:
description This property is required. String
The description of the alert rule
position This property is required. Double
ruleJson This property is required. String
The JSON representation of the alert rule
ruleType This property is required. Double
stop This property is required. Boolean
uniqueId This property is required. String
The unique_id of the action
actions This property is required. GetAlertrulesAlertruleAction[]
The actions of the alert rule as a list of maps:
description This property is required. string
The description of the alert rule
position This property is required. number
ruleJson This property is required. string
The JSON representation of the alert rule
ruleType This property is required. number
stop This property is required. boolean
uniqueId This property is required. string
The unique_id of the action
actions This property is required. Sequence[GetAlertrulesAlertruleAction]
The actions of the alert rule as a list of maps:
description This property is required. str
The description of the alert rule
position This property is required. float
rule_json This property is required. str
The JSON representation of the alert rule
rule_type This property is required. float
stop This property is required. bool
unique_id This property is required. str
The unique_id of the action
actions This property is required. List<Property Map>
The actions of the alert rule as a list of maps:
description This property is required. String
The description of the alert rule
position This property is required. Number
ruleJson This property is required. String
The JSON representation of the alert rule
ruleType This property is required. Number
stop This property is required. Boolean
uniqueId This property is required. String
The unique_id of the action

GetAlertrulesAlertruleAction

ActionType This property is required. double
The type of the action
AssignTo This property is required. string
The assign_to of the action (only if action_type is 6)
EscalationPolicy This property is required. string
Unique id of the escalation policy (only if action_type 4)
Key This property is required. string
Schedule This property is required. string
Sla This property is required. string
Unique_id of the sla (only if action_type is 14)
TeamPriority This property is required. string
Unique_id of the team priority (only if action_type is 15)
UniqueId This property is required. string
The unique_id of the action
Value This property is required. string
The value of the action (only if action_type not in 3, 4, 6, 14, 15)
ActionType This property is required. float64
The type of the action
AssignTo This property is required. string
The assign_to of the action (only if action_type is 6)
EscalationPolicy This property is required. string
Unique id of the escalation policy (only if action_type 4)
Key This property is required. string
Schedule This property is required. string
Sla This property is required. string
Unique_id of the sla (only if action_type is 14)
TeamPriority This property is required. string
Unique_id of the team priority (only if action_type is 15)
UniqueId This property is required. string
The unique_id of the action
Value This property is required. string
The value of the action (only if action_type not in 3, 4, 6, 14, 15)
actionType This property is required. Double
The type of the action
assignTo This property is required. String
The assign_to of the action (only if action_type is 6)
escalationPolicy This property is required. String
Unique id of the escalation policy (only if action_type 4)
key This property is required. String
schedule This property is required. String
sla This property is required. String
Unique_id of the sla (only if action_type is 14)
teamPriority This property is required. String
Unique_id of the team priority (only if action_type is 15)
uniqueId This property is required. String
The unique_id of the action
value This property is required. String
The value of the action (only if action_type not in 3, 4, 6, 14, 15)
actionType This property is required. number
The type of the action
assignTo This property is required. string
The assign_to of the action (only if action_type is 6)
escalationPolicy This property is required. string
Unique id of the escalation policy (only if action_type 4)
key This property is required. string
schedule This property is required. string
sla This property is required. string
Unique_id of the sla (only if action_type is 14)
teamPriority This property is required. string
Unique_id of the team priority (only if action_type is 15)
uniqueId This property is required. string
The unique_id of the action
value This property is required. string
The value of the action (only if action_type not in 3, 4, 6, 14, 15)
action_type This property is required. float
The type of the action
assign_to This property is required. str
The assign_to of the action (only if action_type is 6)
escalation_policy This property is required. str
Unique id of the escalation policy (only if action_type 4)
key This property is required. str
schedule This property is required. str
sla This property is required. str
Unique_id of the sla (only if action_type is 14)
team_priority This property is required. str
Unique_id of the team priority (only if action_type is 15)
unique_id This property is required. str
The unique_id of the action
value This property is required. str
The value of the action (only if action_type not in 3, 4, 6, 14, 15)
actionType This property is required. Number
The type of the action
assignTo This property is required. String
The assign_to of the action (only if action_type is 6)
escalationPolicy This property is required. String
Unique id of the escalation policy (only if action_type 4)
key This property is required. String
schedule This property is required. String
sla This property is required. String
Unique_id of the sla (only if action_type is 14)
teamPriority This property is required. String
Unique_id of the team priority (only if action_type is 15)
uniqueId This property is required. String
The unique_id of the action
value This property is required. String
The value of the action (only if action_type not in 3, 4, 6, 14, 15)

Package Details

Repository
zenduty zenduty/terraform-provider-zenduty
License
Notes
This Pulumi package is based on the zenduty Terraform Provider.
zenduty 1.0.4 published on Wednesday, Apr 2, 2025 by zenduty