< Back

New-AzureRmApiManagementUser

Tue Jan 29, 2019 9:30 pm

NAME New-AzureRmApiManagementUser



SYNOPSIS

Registers a new user.





SYNTAX

New-AzureRmApiManagementUser -Context <PsApiManagementContext> [-DefaultProfile <IAzureContextContainer>] -Email <String> -FirstName <String>

-LastName <String> [-Note <String>] -Password <SecureString> [-State {Active | Blocked}] [-UserId <String>] [<CommonParameters>]





DESCRIPTION

The New-AzureRmApiManagementUser cmdlet registers a new user.





PARAMETERS

-Context <PsApiManagementContext>

Specifies a PsApiManagementContext object.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-DefaultProfile <IAzureContextContainer>

The credentials, account, tenant, and subscription used for communication with azure.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-Email <String>

Specifies the email address of the user.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-FirstName <String>

Specifies the first name of the user. This parameter must be 1 to 100 characters long.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-LastName <String>

Specifies the last name of the user. This parameter must be 1 to 100 characters long.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Note <String>

Specifies a note about the user. This parameter is optional. The default value is $Null.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Password <SecureString>

Specifies the user password. This parameter is required.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-State <PsApiManagementUserState>

Specifies the user state. This parameter is optional. The default value of this parameter is $Null.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-UserId <String>

Specifies the user ID. This parameter is optional. If this parameter is not specified, this cmdlet generates a user ID.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

None

This cmdlet does not accept any input.





OUTPUTS

Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementUser







NOTES









Example 1: Register a new user



PS C:\\>$apimContext = New-AzureRmApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"

PS C:\\>$securePassword = ConvertTo-SecureString "qwerty" -AsPlainText -Force

PS C:\\>New-AzureRmApiManagementUser -Context $apimContext -FirstName "Patti" -LastName "Fuller" -Email "Patti.Fuller@contoso.com" -Password

$securePassword



This command registers a new user named Patti Fuller.







RELATED LINKS

Online Version: https://docs.microsoft.com/en-us/powers ... gementuser

Get-AzureRmApiManagementUser

Set-AzureRmApiManagementUser