@pulumi/pagerduty
Version:
A Pulumi package for creating and managing pagerduty cloud resources.
60 lines • 2.71 kB
JavaScript
;
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.ServiceDependency = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* A [service dependency](https://developer.pagerduty.com/api-reference/b3A6Mjc0ODE5Mg-associate-service-dependencies) is a relationship between two services that this service uses, or that are used by this service, and are critical for successful operation.
*
* ## Import
*
* Service dependencies can be imported using the related supporting service id, supporting service type (`business_service` or `service`) and the dependency id separated by a dot, e.g.
*
* ```sh
* $ pulumi import pagerduty:index/serviceDependency:ServiceDependency main P4B2Z7G.business_service.D5RTHKRNGU4PYE90PJ
* ```
*/
class ServiceDependency extends pulumi.CustomResource {
/**
* Get an existing ServiceDependency 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, id, state, opts) {
return new ServiceDependency(name, state, { ...opts, id: id });
}
/**
* Returns true if the given object is an instance of ServiceDependency. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === ServiceDependency.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["dependency"] = state?.dependency;
}
else {
const args = argsOrState;
resourceInputs["dependency"] = args?.dependency;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(ServiceDependency.__pulumiType, name, resourceInputs, opts);
}
}
exports.ServiceDependency = ServiceDependency;
/** @internal */
ServiceDependency.__pulumiType = 'pagerduty:index/serviceDependency:ServiceDependency';
//# sourceMappingURL=serviceDependency.js.map