Commands › Microsoft Teams

New-CsPhoneNumberBulkUpdateLocationIdOrder

Microsoft Teams MicrosoftTeams New-*

This cmdlet allows the admin to update LocationId for one or multiple telephone numbers at once.

Quick start script

# New-CsPhoneNumberBulkUpdateLocationIdOrder — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-MicrosoftTeams -CertificateThumbprint $thumb -ApplicationId $appId -TenantId $tenantId

# 2. Capture the current state first — you cannot roll back what you never recorded
$before = Get-CsPhoneNumberBulkUpdateLocationIdOrder
$before | Format-List

# 3. Make the change
New-CsPhoneNumberBulkUpdateLocationIdOrder

# 4. Verify and diff
$after = Get-CsPhoneNumberBulkUpdateLocationIdOrder
Compare-Object ($before | Out-String) ($after | Out-String)

Syntax

New-CsPhoneNumberBulkUpdateLocationIdOrder [-LocationId <String>] [-PhoneNumbers <String>] [<CommonParameters>]

Parameters (2)

ParameterTypeRequiredWhat it controls
-LocationId String The LocationId of the location to assign to the specific user. You can get it using Get-CsOnlineLisLocation. You can set the location on both assigned and unassigned phone numbers.
-PhoneNumbers String The phone numbers to update LocationId for.

Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.