UNPKG

@pulumi/pagerduty

Version:

A Pulumi package for creating and managing pagerduty cloud resources.

137 lines (136 loc) 5.49 kB
import * as pulumi from "@pulumi/pulumi"; import * as outputs from "./types/output"; /** * Use this data source to get information about a specific [Cache Variable](https://support.pagerduty.com/docs/event-orchestration-variables) for a Service Event Orchestration. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as pagerduty from "@pulumi/pagerduty"; * * const engineering = new pagerduty.Team("engineering", {name: "Engineering"}); * const example = new pagerduty.User("example", { * name: "Earline Greenholt", * email: "125.greenholt.earline@graham.name", * teams: [engineering.id], * }); * const exampleEscalationPolicy = new pagerduty.EscalationPolicy("example", { * name: "Engineering Escalation Policy", * numLoops: 2, * rules: [{ * escalationDelayInMinutes: 10, * targets: [{ * type: "user", * id: example.id, * }], * }], * }); * const service = new pagerduty.Service("service", { * name: "My Web App", * autoResolveTimeout: "14400", * acknowledgementTimeout: "600", * escalationPolicy: exampleEscalationPolicy.id, * alertCreation: "create_alerts_and_incidents", * }); * const cacheVariable = pagerduty.getEventOrchestrationServiceCacheVariableOutput({ * service: service.id, * name: "example_cache_variable", * }); * ``` */ export declare function getEventOrchestrationServiceCacheVariable(args: GetEventOrchestrationServiceCacheVariableArgs, opts?: pulumi.InvokeOptions): Promise<GetEventOrchestrationServiceCacheVariableResult>; /** * A collection of arguments for invoking getEventOrchestrationServiceCacheVariable. */ export interface GetEventOrchestrationServiceCacheVariableArgs { /** * ID of the Cache Variable associated with the Service Event Orchestration. Specify either `id` or `name`. If both are specified `id` takes precedence. */ id?: string; /** * Name of the Cache Variable associated with the Service Event Orchestration. Specify either `id` or `name`. If both are specified `id` takes precedence. */ name?: string; /** * ID of the Service Event Orchestration to which this Cache Variable belongs. */ service: string; } /** * A collection of values returned by getEventOrchestrationServiceCacheVariable. */ export interface GetEventOrchestrationServiceCacheVariableResult { /** * Conditions to be evaluated in order to determine whether or not to update the Cache Variable's stored value. This attribute can only be used when `configuration.0.type` is `recentValue` or `triggerEventCount`. */ readonly conditions: outputs.GetEventOrchestrationServiceCacheVariableCondition[]; /** * A configuration object to define what and how values will be stored in the Cache Variable. */ readonly configurations: outputs.GetEventOrchestrationServiceCacheVariableConfiguration[]; /** * Indicates whether the Cache Variable is disabled and would therefore not be evaluated. */ readonly disabled: boolean; readonly id?: string; readonly name?: string; readonly service: string; } /** * Use this data source to get information about a specific [Cache Variable](https://support.pagerduty.com/docs/event-orchestration-variables) for a Service Event Orchestration. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as pagerduty from "@pulumi/pagerduty"; * * const engineering = new pagerduty.Team("engineering", {name: "Engineering"}); * const example = new pagerduty.User("example", { * name: "Earline Greenholt", * email: "125.greenholt.earline@graham.name", * teams: [engineering.id], * }); * const exampleEscalationPolicy = new pagerduty.EscalationPolicy("example", { * name: "Engineering Escalation Policy", * numLoops: 2, * rules: [{ * escalationDelayInMinutes: 10, * targets: [{ * type: "user", * id: example.id, * }], * }], * }); * const service = new pagerduty.Service("service", { * name: "My Web App", * autoResolveTimeout: "14400", * acknowledgementTimeout: "600", * escalationPolicy: exampleEscalationPolicy.id, * alertCreation: "create_alerts_and_incidents", * }); * const cacheVariable = pagerduty.getEventOrchestrationServiceCacheVariableOutput({ * service: service.id, * name: "example_cache_variable", * }); * ``` */ export declare function getEventOrchestrationServiceCacheVariableOutput(args: GetEventOrchestrationServiceCacheVariableOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetEventOrchestrationServiceCacheVariableResult>; /** * A collection of arguments for invoking getEventOrchestrationServiceCacheVariable. */ export interface GetEventOrchestrationServiceCacheVariableOutputArgs { /** * ID of the Cache Variable associated with the Service Event Orchestration. Specify either `id` or `name`. If both are specified `id` takes precedence. */ id?: pulumi.Input<string>; /** * Name of the Cache Variable associated with the Service Event Orchestration. Specify either `id` or `name`. If both are specified `id` takes precedence. */ name?: pulumi.Input<string>; /** * ID of the Service Event Orchestration to which this Cache Variable belongs. */ service: pulumi.Input<string>; }