@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
103 lines • 4.39 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.VoiceConnectorTermination = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Enable Termination settings to control outbound calling from your SIP infrastructure.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const _default = new aws.chime.VoiceConnector("default", {
* name: "vc-name-test",
* requireEncryption: true,
* });
* const defaultVoiceConnectorTermination = new aws.chime.VoiceConnectorTermination("default", {
* disabled: false,
* cpsLimit: 1,
* cidrAllowLists: ["50.35.78.96/31"],
* callingRegions: [
* "US",
* "CA",
* ],
* voiceConnectorId: _default.id,
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import Chime Voice Connector Termination using the `voice_connector_id`. For example:
*
* ```sh
* $ pulumi import aws:chime/voiceConnectorTermination:VoiceConnectorTermination default abcdef1ghij2klmno3pqr4
* ```
*/
class VoiceConnectorTermination extends pulumi.CustomResource {
/**
* Get an existing VoiceConnectorTermination 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 VoiceConnectorTermination(name, state, { ...opts, id: id });
}
/**
* Returns true if the given object is an instance of VoiceConnectorTermination. 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'] === VoiceConnectorTermination.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["callingRegions"] = state?.callingRegions;
resourceInputs["cidrAllowLists"] = state?.cidrAllowLists;
resourceInputs["cpsLimit"] = state?.cpsLimit;
resourceInputs["defaultPhoneNumber"] = state?.defaultPhoneNumber;
resourceInputs["disabled"] = state?.disabled;
resourceInputs["region"] = state?.region;
resourceInputs["voiceConnectorId"] = state?.voiceConnectorId;
}
else {
const args = argsOrState;
if (args?.callingRegions === undefined && !opts.urn) {
throw new Error("Missing required property 'callingRegions'");
}
if (args?.cidrAllowLists === undefined && !opts.urn) {
throw new Error("Missing required property 'cidrAllowLists'");
}
if (args?.voiceConnectorId === undefined && !opts.urn) {
throw new Error("Missing required property 'voiceConnectorId'");
}
resourceInputs["callingRegions"] = args?.callingRegions;
resourceInputs["cidrAllowLists"] = args?.cidrAllowLists;
resourceInputs["cpsLimit"] = args?.cpsLimit;
resourceInputs["defaultPhoneNumber"] = args?.defaultPhoneNumber;
resourceInputs["disabled"] = args?.disabled;
resourceInputs["region"] = args?.region;
resourceInputs["voiceConnectorId"] = args?.voiceConnectorId;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(VoiceConnectorTermination.__pulumiType, name, resourceInputs, opts);
}
}
exports.VoiceConnectorTermination = VoiceConnectorTermination;
/** @internal */
VoiceConnectorTermination.__pulumiType = 'aws:chime/voiceConnectorTermination:VoiceConnectorTermination';
//# sourceMappingURL=voiceConnectorTermination.js.map