import * as pulumi from "@pulumi/pulumi"; import * as inputs from "./types/input"; import * as outputs from "./types/output"; /** * An [Incident Workflow Trigger](https://support.pagerduty.com/docs/incident-workflows#triggers) defines when and if an [Incident Workflow](https://support.pagerduty.com/docs/incident-workflows) will be triggered. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as pagerduty from "@pulumi/pagerduty"; * * const myFirstWorkflow = new pagerduty.IncidentWorkflow("my_first_workflow", { * name: "Example Incident Workflow", * description: "This Incident Workflow is an example", * steps: [{ * name: "Send Status Update", * action: "pagerduty.com:incident-workflows:send-status-update:1", * inputs: [{ * name: "Message", * value: "Example status message sent on {{current_date}}", * }], * }], * }); * const firstService = pagerduty.getService({ * name: "My First Service", * }); * const automaticTrigger = new pagerduty.IncidentWorkflowTrigger("automatic_trigger", { * type: "conditional", * workflow: myFirstWorkflow.id, * services: [firstServicePagerdutyService.id], * condition: "incident.priority matches 'P1'", * subscribedToAllServices: false, * }); * const devops = pagerduty.getTeam({ * name: "devops", * }); * const manualTrigger = new pagerduty.IncidentWorkflowTrigger("manual_trigger", { * type: "manual", * workflow: myFirstWorkflow.id, * services: [firstServicePagerdutyService.id], * }); * ``` * * ## Import * * Incident workflows can be imported using the `id`, e.g. * * ```sh * $ pulumi import pagerduty:index/incidentWorkflowTrigger:IncidentWorkflowTrigger pagerduty_incident_workflow_trigger PLBP09X * ``` */ export declare class IncidentWorkflowTrigger extends pulumi.CustomResource { /** * Get an existing IncidentWorkflowTrigger resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: IncidentWorkflowTriggerState, opts?: pulumi.CustomResourceOptions): IncidentWorkflowTrigger; /** * Returns true if the given object is an instance of IncidentWorkflowTrigger. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is IncidentWorkflowTrigger; /** * A [PCL](https://developer.pagerduty.com/docs/ZG9jOjM1NTE0MDc0-pcl-overview) condition string which must be satisfied for the trigger to fire. */ readonly condition: pulumi.Output; /** * Indicates who can start this Trigger. Applicable only to `manual`-type triggers. */ readonly permissions: pulumi.Output; /** * A list of service IDs. Incidents in any of the listed services are eligible to fire this trigger. */ readonly services: pulumi.Output; /** * Set to `true` if the trigger should be eligible for firing on all services. Only allowed to be `true` if the services list is not defined or empty. */ readonly subscribedToAllServices: pulumi.Output; /** * [Updating causes resource replacement] May be either `manual` or `conditional`. */ readonly type: pulumi.Output; /** * The workflow ID for the workflow to trigger. */ readonly workflow: pulumi.Output; /** * Create a IncidentWorkflowTrigger resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: IncidentWorkflowTriggerArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering IncidentWorkflowTrigger resources. */ export interface IncidentWorkflowTriggerState { /** * A [PCL](https://developer.pagerduty.com/docs/ZG9jOjM1NTE0MDc0-pcl-overview) condition string which must be satisfied for the trigger to fire. */ condition?: pulumi.Input; /** * Indicates who can start this Trigger. Applicable only to `manual`-type triggers. */ permissions?: pulumi.Input; /** * A list of service IDs. Incidents in any of the listed services are eligible to fire this trigger. */ services?: pulumi.Input[]>; /** * Set to `true` if the trigger should be eligible for firing on all services. Only allowed to be `true` if the services list is not defined or empty. */ subscribedToAllServices?: pulumi.Input; /** * [Updating causes resource replacement] May be either `manual` or `conditional`. */ type?: pulumi.Input; /** * The workflow ID for the workflow to trigger. */ workflow?: pulumi.Input; } /** * The set of arguments for constructing a IncidentWorkflowTrigger resource. */ export interface IncidentWorkflowTriggerArgs { /** * A [PCL](https://developer.pagerduty.com/docs/ZG9jOjM1NTE0MDc0-pcl-overview) condition string which must be satisfied for the trigger to fire. */ condition?: pulumi.Input; /** * Indicates who can start this Trigger. Applicable only to `manual`-type triggers. */ permissions?: pulumi.Input; /** * A list of service IDs. Incidents in any of the listed services are eligible to fire this trigger. */ services?: pulumi.Input[]>; /** * Set to `true` if the trigger should be eligible for firing on all services. Only allowed to be `true` if the services list is not defined or empty. */ subscribedToAllServices: pulumi.Input; /** * [Updating causes resource replacement] May be either `manual` or `conditional`. */ type: pulumi.Input; /** * The workflow ID for the workflow to trigger. */ workflow: pulumi.Input; }