<reponame>rhysmdnz/pulumi-alicloud-rhys-hacks// *** 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! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.AliCloud.Cdn
{
    [AliCloudResourceType("alicloud:cdn/domain:Domain")]
    public partial class Domain : global::Pulumi.CustomResource
    {
        [Output("authConfig")]
        public Output<Outputs.DomainAuthConfig?> AuthConfig { get; private set; } = null!;

        [Output("blockIps")]
        public Output<ImmutableArray<string>> BlockIps { get; private set; } = null!;

        [Output("cacheConfigs")]
        public Output<ImmutableArray<Outputs.DomainCacheConfig>> CacheConfigs { get; private set; } = null!;

        [Output("cdnType")]
        public Output<string> CdnType { get; private set; } = null!;

        [Output("certificateConfig")]
        public Output<Outputs.DomainCertificateConfig?> CertificateConfig { get; private set; } = null!;

        [Output("domainName")]
        public Output<string> DomainName { get; private set; } = null!;

        [Output("httpHeaderConfigs")]
        public Output<ImmutableArray<Outputs.DomainHttpHeaderConfig>> HttpHeaderConfigs { get; private set; } = null!;

        [Output("optimizeEnable")]
        public Output<string?> OptimizeEnable { get; private set; } = null!;

        [Output("page404Config")]
        public Output<Outputs.DomainPage404Config?> Page404Config { get; private set; } = null!;

        [Output("pageCompressEnable")]
        public Output<string?> PageCompressEnable { get; private set; } = null!;

        [Output("parameterFilterConfig")]
        public Output<Outputs.DomainParameterFilterConfig?> ParameterFilterConfig { get; private set; } = null!;

        [Output("rangeEnable")]
        public Output<string?> RangeEnable { get; private set; } = null!;

        [Output("referConfig")]
        public Output<Outputs.DomainReferConfig?> ReferConfig { get; private set; } = null!;

        [Output("scope")]
        public Output<string> Scope { get; private set; } = null!;

        [Output("sourcePort")]
        public Output<int?> SourcePort { get; private set; } = null!;

        [Output("sourceType")]
        public Output<string?> SourceType { get; private set; } = null!;

        [Output("sources")]
        public Output<ImmutableArray<string>> Sources { get; private set; } = null!;

        [Output("videoSeekEnable")]
        public Output<string?> VideoSeekEnable { get; private set; } = null!;


        /// <summary>
        /// Create a Domain resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public Domain(string name, DomainArgs args, CustomResourceOptions? options = null)
            : base("alicloud:cdn/domain:Domain", name, args ?? new DomainArgs(), MakeResourceOptions(options, ""))
        {
        }

        private Domain(string name, Input<string> id, DomainState? state = null, CustomResourceOptions? options = null)
            : base("alicloud:cdn/domain:Domain", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
                PluginDownloadURL = "github://api.github.com/rhysmdnz/pulumi-alicloud",
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing Domain resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static Domain Get(string name, Input<string> id, DomainState? state = null, CustomResourceOptions? options = null)
        {
            return new Domain(name, id, state, options);
        }
    }

    public sealed class DomainArgs : global::Pulumi.ResourceArgs
    {
        [Input("authConfig")]
        public Input<Inputs.DomainAuthConfigArgs>? AuthConfig { get; set; }

        [Input("blockIps")]
        private InputList<string>? _blockIps;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<string> BlockIps
        {
            get => _blockIps ?? (_blockIps = new InputList<string>());
            set => _blockIps = value;
        }

        [Input("cacheConfigs")]
        private InputList<Inputs.DomainCacheConfigArgs>? _cacheConfigs;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<Inputs.DomainCacheConfigArgs> CacheConfigs
        {
            get => _cacheConfigs ?? (_cacheConfigs = new InputList<Inputs.DomainCacheConfigArgs>());
            set => _cacheConfigs = value;
        }

        [Input("cdnType", required: true)]
        public Input<string> CdnType { get; set; } = null!;

        [Input("certificateConfig")]
        public Input<Inputs.DomainCertificateConfigArgs>? CertificateConfig { get; set; }

        [Input("domainName", required: true)]
        public Input<string> DomainName { get; set; } = null!;

        [Input("httpHeaderConfigs")]
        private InputList<Inputs.DomainHttpHeaderConfigArgs>? _httpHeaderConfigs;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<Inputs.DomainHttpHeaderConfigArgs> HttpHeaderConfigs
        {
            get => _httpHeaderConfigs ?? (_httpHeaderConfigs = new InputList<Inputs.DomainHttpHeaderConfigArgs>());
            set => _httpHeaderConfigs = value;
        }

        [Input("optimizeEnable")]
        public Input<string>? OptimizeEnable { get; set; }

        [Input("page404Config")]
        public Input<Inputs.DomainPage404ConfigArgs>? Page404Config { get; set; }

        [Input("pageCompressEnable")]
        public Input<string>? PageCompressEnable { get; set; }

        [Input("parameterFilterConfig")]
        public Input<Inputs.DomainParameterFilterConfigArgs>? ParameterFilterConfig { get; set; }

        [Input("rangeEnable")]
        public Input<string>? RangeEnable { get; set; }

        [Input("referConfig")]
        public Input<Inputs.DomainReferConfigArgs>? ReferConfig { get; set; }

        [Input("scope")]
        public Input<string>? Scope { get; set; }

        [Input("sourcePort")]
        public Input<int>? SourcePort { get; set; }

        [Input("sourceType")]
        public Input<string>? SourceType { get; set; }

        [Input("sources")]
        private InputList<string>? _sources;
        [Obsolete(@"Use `alicloud_cdn_domain_new` configuration `sources` argument instead.")]
        public InputList<string> Sources
        {
            get => _sources ?? (_sources = new InputList<string>());
            set => _sources = value;
        }

        [Input("videoSeekEnable")]
        public Input<string>? VideoSeekEnable { get; set; }

        public DomainArgs()
        {
        }
        public static new DomainArgs Empty => new DomainArgs();
    }

    public sealed class DomainState : global::Pulumi.ResourceArgs
    {
        [Input("authConfig")]
        public Input<Inputs.DomainAuthConfigGetArgs>? AuthConfig { get; set; }

        [Input("blockIps")]
        private InputList<string>? _blockIps;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<string> BlockIps
        {
            get => _blockIps ?? (_blockIps = new InputList<string>());
            set => _blockIps = value;
        }

        [Input("cacheConfigs")]
        private InputList<Inputs.DomainCacheConfigGetArgs>? _cacheConfigs;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<Inputs.DomainCacheConfigGetArgs> CacheConfigs
        {
            get => _cacheConfigs ?? (_cacheConfigs = new InputList<Inputs.DomainCacheConfigGetArgs>());
            set => _cacheConfigs = value;
        }

        [Input("cdnType")]
        public Input<string>? CdnType { get; set; }

        [Input("certificateConfig")]
        public Input<Inputs.DomainCertificateConfigGetArgs>? CertificateConfig { get; set; }

        [Input("domainName")]
        public Input<string>? DomainName { get; set; }

        [Input("httpHeaderConfigs")]
        private InputList<Inputs.DomainHttpHeaderConfigGetArgs>? _httpHeaderConfigs;
        [Obsolete(@"Use `alicloud_cdn_domain_config` configuration `function_name` and `function_args` arguments instead.")]
        public InputList<Inputs.DomainHttpHeaderConfigGetArgs> HttpHeaderConfigs
        {
            get => _httpHeaderConfigs ?? (_httpHeaderConfigs = new InputList<Inputs.DomainHttpHeaderConfigGetArgs>());
            set => _httpHeaderConfigs = value;
        }

        [Input("optimizeEnable")]
        public Input<string>? OptimizeEnable { get; set; }

        [Input("page404Config")]
        public Input<Inputs.DomainPage404ConfigGetArgs>? Page404Config { get; set; }

        [Input("pageCompressEnable")]
        public Input<string>? PageCompressEnable { get; set; }

        [Input("parameterFilterConfig")]
        public Input<Inputs.DomainParameterFilterConfigGetArgs>? ParameterFilterConfig { get; set; }

        [Input("rangeEnable")]
        public Input<string>? RangeEnable { get; set; }

        [Input("referConfig")]
        public Input<Inputs.DomainReferConfigGetArgs>? ReferConfig { get; set; }

        [Input("scope")]
        public Input<string>? Scope { get; set; }

        [Input("sourcePort")]
        public Input<int>? SourcePort { get; set; }

        [Input("sourceType")]
        public Input<string>? SourceType { get; set; }

        [Input("sources")]
        private InputList<string>? _sources;
        [Obsolete(@"Use `alicloud_cdn_domain_new` configuration `sources` argument instead.")]
        public InputList<string> Sources
        {
            get => _sources ?? (_sources = new InputList<string>());
            set => _sources = value;
        }

        [Input("videoSeekEnable")]
        public Input<string>? VideoSeekEnable { get; set; }

        public DomainState()
        {
        }
        public static new DomainState Empty => new DomainState();
    }
}
