generated/api/Models/CreateUser.cs
// Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.10.2, generator: @autorest/powershell@4.0.708) // Changes may cause incorrect behavior and will be lost if the code is regenerated. namespace Commvault.Powershell.Models { using static Commvault.Powershell.Runtime.Extensions; public partial class CreateUser : Commvault.Powershell.Models.ICreateUser, Commvault.Powershell.Models.ICreateUserInternal { /// <summary>Internal Acessors for Company</summary> Commvault.Powershell.Models.IIdName Commvault.Powershell.Models.ICreateUserInternal.Company { get => (this._company = this._company ?? new Commvault.Powershell.Models.IdName()); set { {_company = value;} } } /// <summary>Internal Acessors for Plan</summary> Commvault.Powershell.Models.IIdName Commvault.Powershell.Models.ICreateUserInternal.Plan { get => (this._plan = this._plan ?? new Commvault.Powershell.Models.IdName()); set { {_plan = value;} } } /// <summary>Backing field for <see cref="Company" /> property.</summary> private Commvault.Powershell.Models.IIdName _company; [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] internal Commvault.Powershell.Models.IIdName Company { get => (this._company = this._company ?? new Commvault.Powershell.Models.IdName()); set => this._company = value; } [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Inlined)] public long? CompanyId { get => ((Commvault.Powershell.Models.IIdNameInternal)Company).Id; set => ((Commvault.Powershell.Models.IIdNameInternal)Company).Id = value ?? default(long); } [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Inlined)] public string CompanyName { get => ((Commvault.Powershell.Models.IIdNameInternal)Company).Name; set => ((Commvault.Powershell.Models.IIdNameInternal)Company).Name = value ?? null; } /// <summary>Backing field for <see cref="Email" /> property.</summary> private string _email; /// <summary> /// Used to provide an email-id to the new user. This email-id is used for logging in the user. Please note that email ids /// are compulsory for company and local users and optional for external users. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public string Email { get => this._email; set => this._email = value; } /// <summary>Backing field for <see cref="ExternalProviderId" /> property.</summary> private long? _externalProviderId; /// <summary> /// Please provide this entity only when creating an AD user. Not needed for local and company users. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public long? ExternalProviderId { get => this._externalProviderId; set => this._externalProviderId = value; } /// <summary>Backing field for <see cref="FullName" /> property.</summary> private string _fullName; /// <summary>Used to provide a name to the new user.</summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public string FullName { get => this._fullName; set => this._fullName = value; } /// <summary>Backing field for <see cref="InviteUser" /> property.</summary> private bool? _inviteUser; /// <summary> /// User will receive an email to install backup software package on their device if this is set to true. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public bool? InviteUser { get => this._inviteUser; set => this._inviteUser = value; } /// <summary>Backing field for <see cref="Name" /> property.</summary> private string _name; /// <summary> /// Used to provide the new user with a username. This username can be used for logging in the user instead of email-id when /// duplicate email-ids are present. For external user, it is necessary to provide the domain name along with the username /// (domainName\\username). To create a company user, the company id or name needs to be provided in the company entity. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public string Name { get => this._name; set => this._name = value; } /// <summary>Backing field for <see cref="Password" /> property.</summary> private string _password; /// <summary> /// Used to provide a password to the user being created. This will be accepted when the useSystemGeneratePassword tag is /// false. The password has to be provided in Base64 format. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public string Password { get => this._password; set => this._password = value; } /// <summary>Backing field for <see cref="Plan" /> property.</summary> private Commvault.Powershell.Models.IIdName _plan; [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] internal Commvault.Powershell.Models.IIdName Plan { get => (this._plan = this._plan ?? new Commvault.Powershell.Models.IdName()); set => this._plan = value; } [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Inlined)] public long? PlanId { get => ((Commvault.Powershell.Models.IIdNameInternal)Plan).Id; set => ((Commvault.Powershell.Models.IIdNameInternal)Plan).Id = value ?? default(long); } [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Inlined)] public string PlanName { get => ((Commvault.Powershell.Models.IIdNameInternal)Plan).Name; set => ((Commvault.Powershell.Models.IIdNameInternal)Plan).Name = value ?? null; } /// <summary>Backing field for <see cref="UseSystemGeneratePassword" /> property.</summary> private bool? _useSystemGeneratePassword; /// <summary> /// Choose to provide a system generated password to the user instead of providing your own password. An email will be sent /// to the user to reset the password. If it is set to true, password tag need not be provided. If it is set to false, password /// needs to be provided in the password tag in Base64 format. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public bool? UseSystemGeneratePassword { get => this._useSystemGeneratePassword; set => this._useSystemGeneratePassword = value; } /// <summary>Backing field for <see cref="UserGroups" /> property.</summary> private System.Collections.Generic.List<Commvault.Powershell.Models.IIdName> _userGroups; /// <summary> /// Provide a list of userGroups that the user should be a part of. Either id or name or both can be provided. /// </summary> [Commvault.Powershell.Origin(Commvault.Powershell.PropertyOrigin.Owned)] public System.Collections.Generic.List<Commvault.Powershell.Models.IIdName> UserGroups { get => this._userGroups; set => this._userGroups = value; } /// <summary>Creates an new <see cref="CreateUser" /> instance.</summary> public CreateUser() { } } public partial interface ICreateUser : Commvault.Powershell.Runtime.IJsonSerializable { [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"", SerializedName = @"id", PossibleTypes = new [] { typeof(long) })] long? CompanyId { get; set; } [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"", SerializedName = @"name", PossibleTypes = new [] { typeof(string) })] string CompanyName { get; set; } /// <summary> /// Used to provide an email-id to the new user. This email-id is used for logging in the user. Please note that email ids /// are compulsory for company and local users and optional for external users. /// </summary> [Commvault.Powershell.Runtime.Info( Required = true, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Used to provide an email-id to the new user. This email-id is used for logging in the user. Please note that email ids are compulsory for company and local users and optional for external users.", SerializedName = @"email", PossibleTypes = new [] { typeof(string) })] string Email { get; set; } /// <summary> /// Please provide this entity only when creating an AD user. Not needed for local and company users. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Please provide this entity only when creating an AD user. Not needed for local and company users.", SerializedName = @"externalProviderId", PossibleTypes = new [] { typeof(long) })] long? ExternalProviderId { get; set; } /// <summary>Used to provide a name to the new user.</summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Used to provide a name to the new user.", SerializedName = @"fullName", PossibleTypes = new [] { typeof(string) })] string FullName { get; set; } /// <summary> /// User will receive an email to install backup software package on their device if this is set to true. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"User will receive an email to install backup software package on their device if this is set to true.", SerializedName = @"inviteUser", PossibleTypes = new [] { typeof(bool) })] bool? InviteUser { get; set; } /// <summary> /// Used to provide the new user with a username. This username can be used for logging in the user instead of email-id when /// duplicate email-ids are present. For external user, it is necessary to provide the domain name along with the username /// (domainName\\username). To create a company user, the company id or name needs to be provided in the company entity. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Used to provide the new user with a username. This username can be used for logging in the user instead of email-id when duplicate email-ids are present. For external user, it is necessary to provide the domain name along with the username (domainName\\username). To create a company user, the company id or name needs to be provided in the company entity.", SerializedName = @"name", PossibleTypes = new [] { typeof(string) })] string Name { get; set; } /// <summary> /// Used to provide a password to the user being created. This will be accepted when the useSystemGeneratePassword tag is /// false. The password has to be provided in Base64 format. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Used to provide a password to the user being created. This will be accepted when the useSystemGeneratePassword tag is false. The password has to be provided in Base64 format.", SerializedName = @"password", PossibleTypes = new [] { typeof(string) })] string Password { get; set; } [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"", SerializedName = @"id", PossibleTypes = new [] { typeof(long) })] long? PlanId { get; set; } [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"", SerializedName = @"name", PossibleTypes = new [] { typeof(string) })] string PlanName { get; set; } /// <summary> /// Choose to provide a system generated password to the user instead of providing your own password. An email will be sent /// to the user to reset the password. If it is set to true, password tag need not be provided. If it is set to false, password /// needs to be provided in the password tag in Base64 format. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Choose to provide a system generated password to the user instead of providing your own password. An email will be sent to the user to reset the password. If it is set to true, password tag need not be provided. If it is set to false, password needs to be provided in the password tag in Base64 format.", SerializedName = @"useSystemGeneratePassword", PossibleTypes = new [] { typeof(bool) })] bool? UseSystemGeneratePassword { get; set; } /// <summary> /// Provide a list of userGroups that the user should be a part of. Either id or name or both can be provided. /// </summary> [Commvault.Powershell.Runtime.Info( Required = false, ReadOnly = false, Read = true, Create = true, Update = true, Description = @"Provide a list of userGroups that the user should be a part of. Either id or name or both can be provided.", SerializedName = @"userGroups", PossibleTypes = new [] { typeof(Commvault.Powershell.Models.IIdName) })] System.Collections.Generic.List<Commvault.Powershell.Models.IIdName> UserGroups { get; set; } } internal partial interface ICreateUserInternal { Commvault.Powershell.Models.IIdName Company { get; set; } long? CompanyId { get; set; } string CompanyName { get; set; } /// <summary> /// Used to provide an email-id to the new user. This email-id is used for logging in the user. Please note that email ids /// are compulsory for company and local users and optional for external users. /// </summary> string Email { get; set; } /// <summary> /// Please provide this entity only when creating an AD user. Not needed for local and company users. /// </summary> long? ExternalProviderId { get; set; } /// <summary>Used to provide a name to the new user.</summary> string FullName { get; set; } /// <summary> /// User will receive an email to install backup software package on their device if this is set to true. /// </summary> bool? InviteUser { get; set; } /// <summary> /// Used to provide the new user with a username. This username can be used for logging in the user instead of email-id when /// duplicate email-ids are present. For external user, it is necessary to provide the domain name along with the username /// (domainName\\username). To create a company user, the company id or name needs to be provided in the company entity. /// </summary> string Name { get; set; } /// <summary> /// Used to provide a password to the user being created. This will be accepted when the useSystemGeneratePassword tag is /// false. The password has to be provided in Base64 format. /// </summary> string Password { get; set; } Commvault.Powershell.Models.IIdName Plan { get; set; } long? PlanId { get; set; } string PlanName { get; set; } /// <summary> /// Choose to provide a system generated password to the user instead of providing your own password. An email will be sent /// to the user to reset the password. If it is set to true, password tag need not be provided. If it is set to false, password /// needs to be provided in the password tag in Base64 format. /// </summary> bool? UseSystemGeneratePassword { get; set; } /// <summary> /// Provide a list of userGroups that the user should be a part of. Either id or name or both can be provided. /// </summary> System.Collections.Generic.List<Commvault.Powershell.Models.IIdName> UserGroups { get; set; } } } |