< Back

Export-ADUsersForBB

Sun Jan 12, 2020 6:30 pm

NAME Export-ADUsersForBB



SYNOPSIS

Get user information from ActiveDirectory with the information needed in GoBright BrightBooking and export it to a

CSV file for import in GoBright BrightBooking





SYNTAX

Export-ADUsersForBB [-Filter] <String> [[-SearchBase] <String>] [[-Server] <String>] [[-ADUserPincodePropertyName]

<String>] [[-ADUserNamePropertyName] <String>] [[-ADUserMobilePropertyName] <String>] [[-ADUserNFCIdPropertyName]

<String>] [-ExportCsvPath] <String> [<CommonParameters>]





DESCRIPTION

Get user information via the Get-ADUser command, retreiving the information needed for GoBright BrightBooking.

(Requiring RSAT tools: Remote Server Administration Tools)





PARAMETERS

-Filter <String>

A filter used to pass to Get-ADUser, if you don't need a filter, then use: '*'

Example: 'samAccountName -like "admin*"'

More information: https://technet.microsoft.com/en-us/lib ... s.10).aspx



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-SearchBase <String>

A SearchBase used to pass to Get-ADUser, specifies an Active Directory path to search under.

Example: "OU=Office,DC=Company,DC=com"

More information: https://technet.microsoft.com/library/hh852208.aspx



Required? false

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Server <String>

Specifies the AD DS instance to connect to, by providing one of the following values for a corresponding

domain name or directory server.

More information: https://technet.microsoft.com/library/hh852208.aspx



Required? false

Position? 3

Default value

Accept pipeline input? false

Accept wildcard characters? false



-ADUserPincodePropertyName <String>

Optional ActiveDirectory User Property which contains the pincode



Required? false

Position? 4

Default value

Accept pipeline input? false

Accept wildcard characters? false



-ADUserNamePropertyName <String>

Optional ActiveDirectory User Property which contains the name of the user, in case you do not want to use the

default property



Required? false

Position? 5

Default value

Accept pipeline input? false

Accept wildcard characters? false



-ADUserMobilePropertyName <String>



Required? false

Position? 6

Default value Mobile

Accept pipeline input? false

Accept wildcard characters? false



-ADUserNFCIdPropertyName <String>



Required? false

Position? 7

Default value

Accept pipeline input? false

Accept wildcard characters? false



-ExportCsvPath <String>

Optional ActiveDirectory User Property which contains the pincode



Required? true

Position? 8

Default value

Accept pipeline input? false

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 (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Export-ADUsersForBB -Filter * -ExportCsvPath "BrightBookingUsers.csv"



# Get all users in the Active Directory and export to a GoBright BrightBooking users CSV file









-------------------------- EXAMPLE 2 --------------------------



PS C:\\>Export-ADUsersForBB -Filter * -SearchBase "OU=Office,DC=Company,DC=com" -ExportCsvPath

"BrightBookingUsers.csv"



# Get the users in the Active Directory, which are member of the given group and export to a GoBright

BrightBooking users CSV file









-------------------------- EXAMPLE 3 --------------------------



PS C:\\>Export-ADUsersForBB -Filter { memberOf -RecursiveMatch "CN=Administrators,DC=Company,DC=com" } -SearchBase

"OU=Office,DC=Company,DC=com" -ADUserPincodePropertyName PersonnelNumber -ADUserNamePropertyName FullUserName

-ExportCsvPath "BrightBookingUsers.csv"



# Get the users in the Active Directory, which in the specified SearchBase path, and use the custom property

'PersonnelNumber' as pincode, the custom property 'FullUserName' as username and export to a GoBright

BrightBooking users CSV file











RELATED LINKS

https://support.gobright.com/

https://technet.microsoft.com/library/hh852208.aspx

Get-ADUsersForBB

Convert-ADUsersToBBUserExport