# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import warnings
import pulumi
import pulumi.runtime
from typing import Any, Dict, List, Mapping, Optional, Tuple, Union
from .. import _utilities, _tables
from . import outputs
from ._inputs import *

__all__ = ['NatGateway']


class NatGateway(pulumi.CustomResource):
    def __init__(__self__,
                 resource_name: str,
                 opts: Optional[pulumi.ResourceOptions] = None,
                 bandwidth_packages: Optional[pulumi.Input[List[pulumi.Input[pulumi.InputType['NatGatewayBandwidthPackageArgs']]]]] = None,
                 description: Optional[pulumi.Input[str]] = None,
                 instance_charge_type: Optional[pulumi.Input[str]] = None,
                 name: Optional[pulumi.Input[str]] = None,
                 period: Optional[pulumi.Input[float]] = None,
                 spec: Optional[pulumi.Input[str]] = None,
                 specification: Optional[pulumi.Input[str]] = None,
                 vpc_id: Optional[pulumi.Input[str]] = None,
                 __props__=None,
                 __name__=None,
                 __opts__=None):
        """
        Create a NatGateway resource with the given unique name, props, and options.
        :param str resource_name: The name of the resource.
        :param pulumi.ResourceOptions opts: Options for the resource.
        :param pulumi.Input[List[pulumi.Input[pulumi.InputType['NatGatewayBandwidthPackageArgs']]]] bandwidth_packages: A list of bandwidth packages for the nat gatway. Only support nat gateway created before 00:00 on November 4, 2017. Available in v1.13.0+ and v1.7.1-.
        :param pulumi.Input[str] description: Description of the nat gateway, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Defaults to null.
        :param pulumi.Input[str] instance_charge_type: The billing method of the nat gateway. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".
        :param pulumi.Input[str] name: Name of the nat gateway. The value can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://. Defaults to null.
        :param pulumi.Input[float] period: The duration that you will buy the resource, in month. It is valid when `instance_charge_type` is `PrePaid`. Default to 1. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console.
        :param pulumi.Input[str] spec: It has been deprecated from provider version 1.7.1, and new field 'specification' can replace it.
        :param pulumi.Input[str] specification: The specification of the nat gateway. Valid values are `Small`, `Middle` and `Large`. Default to `Small`. Details refer to [Nat Gateway Specification](https://www.alibabacloud.com/help/doc-detail/42757.htm).
        :param pulumi.Input[str] vpc_id: The VPC ID.
        """
        if __name__ is not None:
            warnings.warn("explicit use of __name__ is deprecated", DeprecationWarning)
            resource_name = __name__
        if __opts__ is not None:
            warnings.warn("explicit use of __opts__ is deprecated, use 'opts' instead", DeprecationWarning)
            opts = __opts__
        if opts is None:
            opts = pulumi.ResourceOptions()
        if not isinstance(opts, pulumi.ResourceOptions):
            raise TypeError('Expected resource options to be a ResourceOptions instance')
        if opts.version is None:
            opts.version = _utilities.get_version()
        if opts.id is None:
            if __props__ is not None:
                raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
            __props__ = dict()

            __props__['bandwidth_packages'] = bandwidth_packages
            __props__['description'] = description
            __props__['instance_charge_type'] = instance_charge_type
            __props__['name'] = name
            __props__['period'] = period
            if spec is not None:
                warnings.warn("Field 'spec' has been deprecated from provider version 1.7.1, and new field 'specification' can replace it.", DeprecationWarning)
                pulumi.log.warn("spec is deprecated: Field 'spec' has been deprecated from provider version 1.7.1, and new field 'specification' can replace it.")
            __props__['spec'] = spec
            __props__['specification'] = specification
            if vpc_id is None:
                raise TypeError("Missing required property 'vpc_id'")
            __props__['vpc_id'] = vpc_id
            __props__['bandwidth_package_ids'] = None
            __props__['forward_table_ids'] = None
            __props__['snat_table_ids'] = None
        super(NatGateway, __self__).__init__(
            'alicloud:vpc/natGateway:NatGateway',
            resource_name,
            __props__,
            opts)

    @staticmethod
    def get(resource_name: str,
            id: pulumi.Input[str],
            opts: Optional[pulumi.ResourceOptions] = None,
            bandwidth_package_ids: Optional[pulumi.Input[str]] = None,
            bandwidth_packages: Optional[pulumi.Input[List[pulumi.Input[pulumi.InputType['NatGatewayBandwidthPackageArgs']]]]] = None,
            description: Optional[pulumi.Input[str]] = None,
            forward_table_ids: Optional[pulumi.Input[str]] = None,
            instance_charge_type: Optional[pulumi.Input[str]] = None,
            name: Optional[pulumi.Input[str]] = None,
            period: Optional[pulumi.Input[float]] = None,
            snat_table_ids: Optional[pulumi.Input[str]] = None,
            spec: Optional[pulumi.Input[str]] = None,
            specification: Optional[pulumi.Input[str]] = None,
            vpc_id: Optional[pulumi.Input[str]] = None) -> 'NatGateway':
        """
        Get an existing NatGateway resource's state with the given name, id, and optional extra
        properties used to qualify the lookup.

        :param str resource_name: The unique name of the resulting resource.
        :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
        :param pulumi.ResourceOptions opts: Options for the resource.
        :param pulumi.Input[str] bandwidth_package_ids: A list ID of the bandwidth packages, and split them with commas.
        :param pulumi.Input[List[pulumi.Input[pulumi.InputType['NatGatewayBandwidthPackageArgs']]]] bandwidth_packages: A list of bandwidth packages for the nat gatway. Only support nat gateway created before 00:00 on November 4, 2017. Available in v1.13.0+ and v1.7.1-.
        :param pulumi.Input[str] description: Description of the nat gateway, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Defaults to null.
        :param pulumi.Input[str] forward_table_ids: The nat gateway will auto create a snap and forward item, the `forward_table_ids` is the created one.
        :param pulumi.Input[str] instance_charge_type: The billing method of the nat gateway. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".
        :param pulumi.Input[str] name: Name of the nat gateway. The value can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://. Defaults to null.
        :param pulumi.Input[float] period: The duration that you will buy the resource, in month. It is valid when `instance_charge_type` is `PrePaid`. Default to 1. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console.
        :param pulumi.Input[str] snat_table_ids: The nat gateway will auto create a snap and forward item, the `snat_table_ids` is the created one.
        :param pulumi.Input[str] spec: It has been deprecated from provider version 1.7.1, and new field 'specification' can replace it.
        :param pulumi.Input[str] specification: The specification of the nat gateway. Valid values are `Small`, `Middle` and `Large`. Default to `Small`. Details refer to [Nat Gateway Specification](https://www.alibabacloud.com/help/doc-detail/42757.htm).
        :param pulumi.Input[str] vpc_id: The VPC ID.
        """
        opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))

        __props__ = dict()

        __props__["bandwidth_package_ids"] = bandwidth_package_ids
        __props__["bandwidth_packages"] = bandwidth_packages
        __props__["description"] = description
        __props__["forward_table_ids"] = forward_table_ids
        __props__["instance_charge_type"] = instance_charge_type
        __props__["name"] = name
        __props__["period"] = period
        __props__["snat_table_ids"] = snat_table_ids
        __props__["spec"] = spec
        __props__["specification"] = specification
        __props__["vpc_id"] = vpc_id
        return NatGateway(resource_name, opts=opts, __props__=__props__)

    @property
    @pulumi.getter(name="bandwidthPackageIds")
    def bandwidth_package_ids(self) -> pulumi.Output[str]:
        """
        A list ID of the bandwidth packages, and split them with commas.
        """
        return pulumi.get(self, "bandwidth_package_ids")

    @property
    @pulumi.getter(name="bandwidthPackages")
    def bandwidth_packages(self) -> pulumi.Output[Optional[List['outputs.NatGatewayBandwidthPackage']]]:
        """
        A list of bandwidth packages for the nat gatway. Only support nat gateway created before 00:00 on November 4, 2017. Available in v1.13.0+ and v1.7.1-.
        """
        return pulumi.get(self, "bandwidth_packages")

    @property
    @pulumi.getter
    def description(self) -> pulumi.Output[Optional[str]]:
        """
        Description of the nat gateway, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Defaults to null.
        """
        return pulumi.get(self, "description")

    @property
    @pulumi.getter(name="forwardTableIds")
    def forward_table_ids(self) -> pulumi.Output[str]:
        """
        The nat gateway will auto create a snap and forward item, the `forward_table_ids` is the created one.
        """
        return pulumi.get(self, "forward_table_ids")

    @property
    @pulumi.getter(name="instanceChargeType")
    def instance_charge_type(self) -> pulumi.Output[str]:
        """
        The billing method of the nat gateway. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".
        """
        return pulumi.get(self, "instance_charge_type")

    @property
    @pulumi.getter
    def name(self) -> pulumi.Output[str]:
        """
        Name of the nat gateway. The value can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://. Defaults to null.
        """
        return pulumi.get(self, "name")

    @property
    @pulumi.getter
    def period(self) -> pulumi.Output[Optional[float]]:
        """
        The duration that you will buy the resource, in month. It is valid when `instance_charge_type` is `PrePaid`. Default to 1. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console.
        """
        return pulumi.get(self, "period")

    @property
    @pulumi.getter(name="snatTableIds")
    def snat_table_ids(self) -> pulumi.Output[str]:
        """
        The nat gateway will auto create a snap and forward item, the `snat_table_ids` is the created one.
        """
        return pulumi.get(self, "snat_table_ids")

    @property
    @pulumi.getter
    def spec(self) -> pulumi.Output[Optional[str]]:
        """
        It has been deprecated from provider version 1.7.1, and new field 'specification' can replace it.
        """
        return pulumi.get(self, "spec")

    @property
    @pulumi.getter
    def specification(self) -> pulumi.Output[Optional[str]]:
        """
        The specification of the nat gateway. Valid values are `Small`, `Middle` and `Large`. Default to `Small`. Details refer to [Nat Gateway Specification](https://www.alibabacloud.com/help/doc-detail/42757.htm).
        """
        return pulumi.get(self, "specification")

    @property
    @pulumi.getter(name="vpcId")
    def vpc_id(self) -> pulumi.Output[str]:
        """
        The VPC ID.
        """
        return pulumi.get(self, "vpc_id")

    def translate_output_property(self, prop):
        return _tables.CAMEL_TO_SNAKE_CASE_TABLE.get(prop) or prop

    def translate_input_property(self, prop):
        return _tables.SNAKE_TO_CAMEL_CASE_TABLE.get(prop) or prop

