Commands › Microsoft Teams

New-CsCallingLineIdentity

Microsoft Teams MicrosoftTeams New-*

Create a new Caller ID policy for your organization.

Quick start script

# New-CsCallingLineIdentity — 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-CsCallingLineIdentity
$before | Format-List

# 3. Make the change (dry run first)
New-CsCallingLineIdentity -Identity <String> -WhatIf
New-CsCallingLineIdentity -Identity <String>

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

Syntax

New-CsCallingLineIdentity [-Identity] <string> [-BlockIncomingPstnCallerID <bool>] [-CallingIDSubstitute <string>] [-CompanyName <string>]
[-Description <string>] [-EnableUserOverride <bool>] [-ResourceAccount <string>]
[-WhatIf] [-Confirm] [<CommonParameters>]

Parameters (9)

ParameterTypeRequiredWhat it controls
-BlockIncomingPstnCallerID Boolean The BlockIncomingPstnCallerID switch determines whether to block the incoming Caller ID. The default value is false.
-CallingIDSubstitute String The CallingIDSubstitute parameter lets you specify an alternate Caller ID. The default value is LineUri. Supported values are Anonymous, LineUri, and Resource.
-CompanyName String This parameter sets the Calling party name (typically referred to as CNAM) on the outgoing PSTN call.
-Confirm SwitchParameter The Confirm switch causes the command to pause processing and requires confirmation to proceed.
-Description String The Description parameter briefly describes the Caller ID policy.
-EnableUserOverride Boolean The EnableUserOverride parameter gives Microsoft Teams users the option under Settings and Calls to hide their phone number when making outgoing calls. The CallerID will be Anonymous.
-Identity String yes The Identity parameter identifies the Caller ID policy.
-ResourceAccount String This parameter specifies the ObjectId of a resource account/online application instance used for Teams Auto Attendant or Call Queue. The outgoing PSTN call will use the phone number defined on the resource account as...
-WhatIf SwitchParameter The WhatIf switch causes the command to simulate its results. By using this switch, you can view what changes would occur without having to commit those changes.

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