// *** 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;
using Pulumi;

namespace zscaler.PulumiPackage.Zia.Firewall
{
    /// <summary>
    /// The **zia_firewall_filtering_network_service_groups** resource allows the creation and management of ZIA Cloud Firewall IP network service groups in the Zscaler Internet Access. This resource can then be associated with a ZIA cloud firewall filtering rule.
    /// 
    /// ## Example Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using Pulumi;
    /// using Zia = Pulumi.Zia;
    /// using Zia = zscaler.PulumiPackage.Zia;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     var example1 = Zia.Firewall.GetFirewallFilteringNetworkServices.Invoke(new()
    ///     {
    ///         Name = "FTP",
    ///     });
    /// 
    ///     var example2 = Zia.Firewall.GetFirewallFilteringNetworkServices.Invoke(new()
    ///     {
    ///         Name = "NETBIOS",
    ///     });
    /// 
    ///     var example3 = Zia.Firewall.GetFirewallFilteringNetworkServices.Invoke(new()
    ///     {
    ///         Name = "DNS",
    ///     });
    /// 
    ///     // Add network services to a network services group
    ///     var example = new Zia.Firewall.FirewallFilteringServiceGroups("example", new()
    ///     {
    ///         Description = "example",
    ///         Services = new[]
    ///         {
    ///             new Zia.Firewall.Inputs.FirewallFilteringServiceGroupsServiceArgs
    ///             {
    ///                 Ids = new[]
    ///                 {
    ///                     example1.Apply(getFirewallFilteringNetworkServicesResult =&gt; getFirewallFilteringNetworkServicesResult.Id),
    ///                     example2.Apply(getFirewallFilteringNetworkServicesResult =&gt; getFirewallFilteringNetworkServicesResult.Id),
    ///                     example3.Apply(getFirewallFilteringNetworkServicesResult =&gt; getFirewallFilteringNetworkServicesResult.Id),
    ///                 },
    ///             },
    ///         },
    ///     });
    /// 
    /// });
    /// ```
    /// </summary>
    [ZiaResourceType("zia:Firewall/firewallFilteringServiceGroups:FirewallFilteringServiceGroups")]
    public partial class FirewallFilteringServiceGroups : global::Pulumi.CustomResource
    {
        /// <summary>
        /// Description of the network services group
        /// </summary>
        [Output("description")]
        public Output<string?> Description { get; private set; } = null!;

        /// <summary>
        /// Name of the network service group
        /// </summary>
        [Output("name")]
        public Output<string> Name { get; private set; } = null!;

        [Output("networkServiceGroupId")]
        public Output<int> NetworkServiceGroupId { get; private set; } = null!;

        /// <summary>
        /// Any number of network services ID to be added to the group
        /// </summary>
        [Output("services")]
        public Output<ImmutableArray<Outputs.FirewallFilteringServiceGroupsService>> Services { get; private set; } = null!;


        /// <summary>
        /// Create a FirewallFilteringServiceGroups 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 FirewallFilteringServiceGroups(string name, FirewallFilteringServiceGroupsArgs? args = null, CustomResourceOptions? options = null)
            : base("zia:Firewall/firewallFilteringServiceGroups:FirewallFilteringServiceGroups", name, args ?? new FirewallFilteringServiceGroupsArgs(), MakeResourceOptions(options, ""))
        {
        }

        private FirewallFilteringServiceGroups(string name, Input<string> id, FirewallFilteringServiceGroupsState? state = null, CustomResourceOptions? options = null)
            : base("zia:Firewall/firewallFilteringServiceGroups:FirewallFilteringServiceGroups", 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/zscaler",
            };
            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 FirewallFilteringServiceGroups 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 FirewallFilteringServiceGroups Get(string name, Input<string> id, FirewallFilteringServiceGroupsState? state = null, CustomResourceOptions? options = null)
        {
            return new FirewallFilteringServiceGroups(name, id, state, options);
        }
    }

    public sealed class FirewallFilteringServiceGroupsArgs : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Description of the network services group
        /// </summary>
        [Input("description")]
        public Input<string>? Description { get; set; }

        /// <summary>
        /// Name of the network service group
        /// </summary>
        [Input("name")]
        public Input<string>? Name { get; set; }

        [Input("services")]
        private InputList<Inputs.FirewallFilteringServiceGroupsServiceArgs>? _services;

        /// <summary>
        /// Any number of network services ID to be added to the group
        /// </summary>
        public InputList<Inputs.FirewallFilteringServiceGroupsServiceArgs> Services
        {
            get => _services ?? (_services = new InputList<Inputs.FirewallFilteringServiceGroupsServiceArgs>());
            set => _services = value;
        }

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

    public sealed class FirewallFilteringServiceGroupsState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Description of the network services group
        /// </summary>
        [Input("description")]
        public Input<string>? Description { get; set; }

        /// <summary>
        /// Name of the network service group
        /// </summary>
        [Input("name")]
        public Input<string>? Name { get; set; }

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

        [Input("services")]
        private InputList<Inputs.FirewallFilteringServiceGroupsServiceGetArgs>? _services;

        /// <summary>
        /// Any number of network services ID to be added to the group
        /// </summary>
        public InputList<Inputs.FirewallFilteringServiceGroupsServiceGetArgs> Services
        {
            get => _services ?? (_services = new InputList<Inputs.FirewallFilteringServiceGroupsServiceGetArgs>());
            set => _services = value;
        }

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