// *** 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
{
    /// <summary>
    /// Provides a Msc Sub Subscription resource.
    /// 
    /// &gt; **NOTE:** Available in v1.135.0+.
    /// 
    /// ## Example Usage
    /// 
    /// Basic Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using Pulumi;
    /// using AliCloud = Pulumi.AliCloud;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     var example = new AliCloud.MscSubSubscription("example", new()
    ///     {
    ///         EmailStatus = 1,
    ///         ItemName = "Notifications of Product Expiration",
    ///         PmsgStatus = 1,
    ///         SmsStatus = 1,
    ///         TtsStatus = 1,
    ///         WebhookStatus = 0,
    ///     });
    /// 
    /// });
    /// ```
    /// 
    /// ## Import
    /// 
    /// Msc Sub Subscription can be imported using the id, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import alicloud:index/mscSubSubscription:MscSubSubscription example &lt;id&gt;
    /// ```
    /// </summary>
    [AliCloudResourceType("alicloud:index/mscSubSubscription:MscSubSubscription")]
    public partial class MscSubSubscription : global::Pulumi.CustomResource
    {
        /// <summary>
        /// The channel the Subscription.
        /// </summary>
        [Output("channel")]
        public Output<string> Channel { get; private set; } = null!;

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

        /// <summary>
        /// The description of the Subscription.
        /// </summary>
        [Output("description")]
        public Output<string> Description { get; private set; } = null!;

        /// <summary>
        /// The status of email subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Output("emailStatus")]
        public Output<int?> EmailStatus { get; private set; } = null!;

        /// <summary>
        /// The name of the Subscription. **NOTE:**  You should use the `alicloud.getMscSubSubscriptions` to query the available subscription item name.
        /// </summary>
        [Output("itemName")]
        public Output<string> ItemName { get; private set; } = null!;

        /// <summary>
        /// The status of pmsg subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Output("pmsgStatus")]
        public Output<int?> PmsgStatus { get; private set; } = null!;

        /// <summary>
        /// The status of sms subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Output("smsStatus")]
        public Output<int?> SmsStatus { get; private set; } = null!;

        /// <summary>
        /// The status of tts subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Output("ttsStatus")]
        public Output<int?> TtsStatus { get; private set; } = null!;

        /// <summary>
        /// The ids of subscribed webhooks.
        /// </summary>
        [Output("webhookIds")]
        public Output<ImmutableArray<string>> WebhookIds { get; private set; } = null!;

        /// <summary>
        /// The status of webhook subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Output("webhookStatus")]
        public Output<int?> WebhookStatus { get; private set; } = null!;


        /// <summary>
        /// Create a MscSubSubscription 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 MscSubSubscription(string name, MscSubSubscriptionArgs args, CustomResourceOptions? options = null)
            : base("alicloud:index/mscSubSubscription:MscSubSubscription", name, args ?? new MscSubSubscriptionArgs(), MakeResourceOptions(options, ""))
        {
        }

        private MscSubSubscription(string name, Input<string> id, MscSubSubscriptionState? state = null, CustomResourceOptions? options = null)
            : base("alicloud:index/mscSubSubscription:MscSubSubscription", 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 MscSubSubscription 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 MscSubSubscription Get(string name, Input<string> id, MscSubSubscriptionState? state = null, CustomResourceOptions? options = null)
        {
            return new MscSubSubscription(name, id, state, options);
        }
    }

    public sealed class MscSubSubscriptionArgs : global::Pulumi.ResourceArgs
    {
        [Input("contactIds")]
        private InputList<string>? _contactIds;
        public InputList<string> ContactIds
        {
            get => _contactIds ?? (_contactIds = new InputList<string>());
            set => _contactIds = value;
        }

        /// <summary>
        /// The status of email subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("emailStatus")]
        public Input<int>? EmailStatus { get; set; }

        /// <summary>
        /// The name of the Subscription. **NOTE:**  You should use the `alicloud.getMscSubSubscriptions` to query the available subscription item name.
        /// </summary>
        [Input("itemName", required: true)]
        public Input<string> ItemName { get; set; } = null!;

        /// <summary>
        /// The status of pmsg subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("pmsgStatus")]
        public Input<int>? PmsgStatus { get; set; }

        /// <summary>
        /// The status of sms subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("smsStatus")]
        public Input<int>? SmsStatus { get; set; }

        /// <summary>
        /// The status of tts subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("ttsStatus")]
        public Input<int>? TtsStatus { get; set; }

        [Input("webhookIds")]
        private InputList<string>? _webhookIds;

        /// <summary>
        /// The ids of subscribed webhooks.
        /// </summary>
        public InputList<string> WebhookIds
        {
            get => _webhookIds ?? (_webhookIds = new InputList<string>());
            set => _webhookIds = value;
        }

        /// <summary>
        /// The status of webhook subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("webhookStatus")]
        public Input<int>? WebhookStatus { get; set; }

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

    public sealed class MscSubSubscriptionState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// The channel the Subscription.
        /// </summary>
        [Input("channel")]
        public Input<string>? Channel { get; set; }

        [Input("contactIds")]
        private InputList<string>? _contactIds;
        public InputList<string> ContactIds
        {
            get => _contactIds ?? (_contactIds = new InputList<string>());
            set => _contactIds = value;
        }

        /// <summary>
        /// The description of the Subscription.
        /// </summary>
        [Input("description")]
        public Input<string>? Description { get; set; }

        /// <summary>
        /// The status of email subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("emailStatus")]
        public Input<int>? EmailStatus { get; set; }

        /// <summary>
        /// The name of the Subscription. **NOTE:**  You should use the `alicloud.getMscSubSubscriptions` to query the available subscription item name.
        /// </summary>
        [Input("itemName")]
        public Input<string>? ItemName { get; set; }

        /// <summary>
        /// The status of pmsg subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("pmsgStatus")]
        public Input<int>? PmsgStatus { get; set; }

        /// <summary>
        /// The status of sms subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("smsStatus")]
        public Input<int>? SmsStatus { get; set; }

        /// <summary>
        /// The status of tts subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("ttsStatus")]
        public Input<int>? TtsStatus { get; set; }

        [Input("webhookIds")]
        private InputList<string>? _webhookIds;

        /// <summary>
        /// The ids of subscribed webhooks.
        /// </summary>
        public InputList<string> WebhookIds
        {
            get => _webhookIds ?? (_webhookIds = new InputList<string>());
            set => _webhookIds = value;
        }

        /// <summary>
        /// The status of webhook subscription. Valid values: `-1`, `-2`, `0`, `1`. `-1` means required, `-2` means banned; `1` means subscribed; `0` means not subscribed.
        /// </summary>
        [Input("webhookStatus")]
        public Input<int>? WebhookStatus { get; set; }

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