Get-NAVServerUser

Returns information about all users created in the current Business Central database.

Syntax

Get-NAVServerUser
   [-Tenant <TenantId>]
   [-ServerInstance] <String>
   [-Force]
   [-ProgressAction <ActionPreference>]
   [<CommonParameters>]

Description

Use the Get-NAVServerUser cmdlet to return information about all users created in the current Business Central database. The following information is returned for each user: User Security ID User Name Full Name State Expiry Date Windows Security ID Change Password License Type AuthenticationEmail Password NameIdentifier AuthenticationKey WebServicesKey WebServicesKeyExpiryDate ProfileID For more information about these values, see the Help for the User page in the Business Central Windows client.

Examples

EXAMPLE 1

Get-NAVServerUser BC

 User Security ID         : b5013678-36e5-4469-8f07-dcc453fed66f
 User Name                : MyDomain_x005C_User1
 Full Name                : MyDomain_x005C_User1
 State                    : Enabled
 Expiry Date              : 1/1/0001 12:00:00 AM
 Windows Security ID      : S-1-5-21-xxxxxxxxxx-xxxxxxxxx-xxxxxxxxxx-xxxxxxx
 Change Password          : False
 License Type             : Full User
 AuthenticationEmail      :
 Password                 :
 NameIdentifier           :
 AuthenticationKey        :
 WebServicesKey           :
 WebServicesKeyExpiryDate : 1/1/0001 12:00:00 AM
 ProfileID                : BOOKKEEPER

This example returns information about Business Central users.

EXAMPLE 2

Get-NAVServerUser BC -Tenant "Tenant1"

User Security ID         : b5013678-36e5-4469-8f07-dcc453fed66f
User Name                : MyDomain_x005C_User1
Full Name                : MyDomain_x005C_User1
State                    : Enabled
Expiry Date              : 1/1/0001 12:00:00 AM
Windows Security ID      : S-1-5-21-xxxxxxxxxx-xxxxxxxxx-xxxxxxxxxx-xxxxxxx
Change Password          : False
License Type             : Full User
AuthenticationEmail      :
Password                 :
NameIdentifier           :
AuthenticationKey        :
WebServicesKey           :
WebServicesKeyExpiryDate : 1/1/0001 12:00:00 AM
ProfileID                : BOOKKEEPER

This example returns information about Business Central users who belong to the tenant Tenant1 on the Business Central Server instance.

Parameters

-Force

Forces the command to run without asking for user confirmation.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ProgressAction

A common PowerShell parameter that determines how PowerShell responds to progress updates generated by a script, cmdlet, or provider. Learn more.

Type:ActionPreference
Aliases:proga
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ServerInstance

Specifies the name of a Business Central Server instance, for example, BC or myinstance. You can specify either the full name of an instance, such as MicrosoftDynamicsNavServer$myinstance or the short name such as myinstance.

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Tenant

Specifies the ID of the tenant that the users are stored in, such as Tenant1. This parameter is required unless the specified service instance is not configured to run multiple tenants.

Type:TenantId
Aliases:Id
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

Inputs

System.String

You can pipe a string that contains a Business Central Server instance name and tenant ID, if applicable) to the cmdlet.

Outputs

System.Data.DataRow

Returns the user information as a row.