New-SharedMailbox
SYNOPSIS
Create a shared mailbox in Exchange 2016 or the Exchange Online tenant for Onderwijs Gent.
SYNTAX
Cloud (Default)
New-SharedMailbox -EmailUserPart <String> [-DisplayName <String>] -Type <String> [-Beheerders <String[]>]
-TaskNr <Int32> [-Departement <String>] [-Dienst <String>] [-Batch] [-Cloud] [-RoutingSuffix <String>]
[-DNVariable <String>] [<CommonParameters>]
OnPrem
New-SharedMailbox -EmailUserPart <String> [-DisplayName <String>] -Type <String> [-Beheerders <String[]>]
-TaskNr <Int32> [-Departement <String>] [-Dienst <String>] [-Batch] [-DNVariable <String>]
[<CommonParameters>]
Onderwijs
New-SharedMailbox -EmailUserPart <String> [-DisplayName <String>] [-Beheerders <String[]>] -TaskNr <Int32>
[-Departement <String>] [-Dienst <String>] [-Batch] [-Onderwijs] [-DNVariable <String>] [<CommonParameters>]
DESCRIPTION
The `New-SharedMailbox` function creates a shared mailbox. It supports multiple types (Dienstmailbox, Equipment, Room) and customers, and assigns permissions to users. The function can create mailboxes on-premises, in the cloud, or in the Onderwijs tenant.
EXAMPLES
EXAMPLE 1
New-SharedMailbox -EmailUserPart "info" -DisplayName "Info Mailbox" -Type "D" -Beheerders @("Admin1", "Admin2") -Suffix "example.com" -TaskNr 12345
Creates a Dienstmailbox named "Info Mailbox" with the specified administrators and logs the action with task number 12345.
EXAMPLE 2
Creates a shared cloud mailbox for equipment named "projector1@example.com".
EXAMPLE 3
Creates a shared mailbox for a meeting room in the Onderwijs tenant.
PARAMETERS
-EmailUserPart
The desired email address without the domain (user part only).
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-DisplayName
The desired display name of the mailbox. Defaults to the value of `EmailUserPart`.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Type
The type of mailbox to create. Valid options are: - D (Dienstmailbox): A regular shared mailbox. - E (Equipment): A resource or equipment that can be booked, excluding rooms. - R (Room): A meeting room.
Type: String
Parameter Sets: Cloud, OnPrem
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Beheerders
Administrators of the mailbox. They will receive full mailbox access via an L_MBX group (except for OND Dienstmailbox).
Type: String[]
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-TaskNr
{{ Fill TaskNr Description }}
Type: Int32
Parameter Sets: (All)
Aliases: InfraNr
Required: True
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False
-Departement
{{ Fill Departement Description }}
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Dienst
{{ Fill Dienst Description }}
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Batch
{{ Fill Batch Description }}
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-Onderwijs
Switch to create the mailbox as a shared mailbox in the Onderwijs tenant.
Type: SwitchParameter
Parameter Sets: Onderwijs
Aliases:
Required: True
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-Cloud
Switch to create the mailbox as a shared cloud mailbox.
Type: SwitchParameter
Parameter Sets: Cloud
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-RoutingSuffix
{{ Fill RoutingSuffix Description }}
Type: String
Parameter Sets: Cloud
Aliases:
Required: False
Position: Named
Default value: Gentplus.mail.onmicrosoft.com
Accept pipeline input: False
Accept wildcard characters: False
-DNVariable
A variable in the parent scope where the DN of the newly created mailbox will be stored.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.