Skip to content
31 changes: 27 additions & 4 deletions teams/teams-ps/MicrosoftTeams/Get-CsOnlineTelephoneNumberOrder.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Get-CsOnlineTelephoneNumberOrder -OrderId <String> [-OrderType <String>]

## DESCRIPTION

This `Get-CsOnlineTelephoneNumberOrder` cmdlet can be used to get the status of specific telephone number orders. Currently supported orders for retrievals are: Search [New-CsOnlineTelephoneNumberOrder](https://learn.microsoft.com/powershell/module/microsoftteams/new-csonlinetelephonenumberorder), Direct Routing Number Upload [New-CsOnlineDirectRoutingTelephoneNumberUploadOrder](https://learn.microsoft.com/powershell/module/microsoftteams/new-csonlinedirectroutingtelephonenumberuploadorder), and Direct Routing Number Release [New-CsOnlineTelephoneNumberReleaseOrder](https://learn.microsoft.com/powershell/module/microsoftteams/New-csonlinetelephonenumberreleaseorder). When the OrderType is not indicated, the cmdlet will default to a Search order.
This `Get-CsOnlineTelephoneNumberOrder` cmdlet can be used to get the status of specific telephone number orders. Currently supported orders for retrievals are: Search [New-CsOnlineTelephoneNumberOrder](https://learn.microsoft.com/powershell/module/microsoftteams/new-csonlinetelephonenumberorder), Direct Routing Number Upload [New-CsOnlineDirectRoutingTelephoneNumberUploadOrder](https://learn.microsoft.com/powershell/module/microsoftteams/new-csonlinedirectroutingtelephonenumberuploadorder), Direct Routing Number Release [New-CsOnlineTelephoneNumberReleaseOrder](https://learn.microsoft.com/powershell/module/microsoftteams/New-csonlinetelephonenumberreleaseorder), and SMS Activation/Deactivation. When the OrderType is not indicated, the cmdlet will default to a Search order.

## EXAMPLES

Expand Down Expand Up @@ -183,12 +183,34 @@ PS C:\> $results.AdditionalDetails
Key Value
--- -----
TelephoneNumber +100001
Status Error
Message The Number is not found.
Status Error
Message The Number is not found.
```

This example returns the status of a partially successful NumberUpdate order for a telephone number tags.

### Example 7
```powershell
PS C:\> $results = Get-CsOnlineTelephoneNumberOrder -OrderId 0fba1633-81f0-435d-b0a8-81d073cc6f29 -OrderType SmsActivation

Key Value
--- -----
OrderId 0fba1633-81f0-435d-b0a8-81d073cc6f29
Status PendingTelcoCallback
OrderType SmsActivation
CreatedAt 1/6/2026 7:28:09 PM +00:00
CreatedBy UNATTRIBUTED
TelephoneNumbers {System.Collections.Generic.Dictionary`2[System.String,System.Object]}

PS C:\> $results.TelephoneNumbers

Key Value
--- -----
TelephoneNumber +12065555555
```

This example returns the status of an in progress SMS Activation order.

## PARAMETERS

### -OrderId
Expand All @@ -207,7 +229,7 @@ Accept wildcard characters: False
```

### -OrderType
Specifies the type of telephone number order to look up. Currently supported values are **Search**, **Release**, and **DirectRoutingNumberCreation**. If this value is unspecified, then it will default to a **Search** order.
Specifies the type of telephone number order to look up. Currently supported values are **Search**, **Release**, **DirectRoutingNumberCreation**, and **SmsActivation/Deactivation**. If this value is unspecified, then it will default to a **Search** order.

```yaml
Type: String
Expand Down Expand Up @@ -243,3 +265,4 @@ Updates in Teams PowerShell Module version 6.7.1 and later:
[Clear-CsOnlineTelephoneNumberOrder](https://learn.microsoft.com/powershell/module/microsoftteams/clear-csonlinetelephonenumberorder)
[New-CsOnlineDirectRoutingTelephoneNumberUploadOrder](https://learn.microsoft.com/powershell/module/microsoftteams/new-csonlinedirectroutingtelephonenumberuploadorder)
[New-CsOnlineTelephoneNumberReleaseOrder](https://learn.microsoft.com/powershell/module/microsoftteams/New-csonlinetelephonenumberreleaseorder)

80 changes: 79 additions & 1 deletion teams/teams-ps/MicrosoftTeams/Get-CsPhoneNumberAssignment.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example displays information about the Microsoft Calling Plan subscriber phone number +1 (402) 555-1234. You can see that it is assigned to a user.

Expand Down Expand Up @@ -118,6 +119,7 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example displays information about the Direct Routing phone number +1 (206) 555-1000;ext=524. You can see that it is assigned to a user.

Expand Down Expand Up @@ -192,6 +194,7 @@ ReverseNumberLookup : {SkipInternalVoip}
Tag : {}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example displays when SkipInternalVoip option is turned on for a number.

Expand Down Expand Up @@ -223,6 +226,7 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example shows a way to use -Filter parameter to display information of a specific number.

Expand Down Expand Up @@ -254,6 +258,7 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example shows a way to get filtered results using multiple Filter parameters.

Expand Down Expand Up @@ -285,6 +290,7 @@ ReverseNumberLookup : {}
Tag : {Engineering}
AssignmentBlockedState :
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example shows a way to get filtered results using tags. Tags are not case sensitive.

Expand Down Expand Up @@ -316,6 +322,7 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState : BlockedForever
AssignmentBlockedUntil :
SmsActivationState : NotActivated
```
This example displays information about the telephone number +1 (402) 555-1234 which has a permanent assignment block. This block prevents the number from being assigned to any other user. Admin can remove the block using [Remove-CsPhoneNumberAssignmentBlock](./remove-csphonenumberassignmentblock.md).

Expand Down Expand Up @@ -347,9 +354,74 @@ ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState : BlockedUntil
AssignmentBlockedUntil : 2025-10-11T21:30:00.0000000Z
SmsActivationState : NotActivated
```
This example displays information about the telephone number +1 (402) 555-1234 which has a temporary assignment block. This block prevents the number from being assigned to any other user. Once the period shown in AssignmentBlockUntil passes, the AssignmentBlock will be automatically removed and the number will become available to be assigned to any user. Admin can also remove the block manually using [Remove-CsPhoneNumberAssignmentBlock](./remove-csphonenumberassignmentblock.md).

### Example 16
```powershell
Get-CsPhoneNumberAssignment -TelephoneNumber +13603227351
```
```output
TelephoneNumber : +13603227351
OperatorId : 0019adbc-b82a-47b4-a799-4e993a9982f1
NumberType : CallingPlan
ActivationState : Activated
AssignedPstnTargetId : 2d43c5da-649b-406b-9d32-d130d2c53018
AssignmentCategory : Primary
Capability : {Geographic, InboundCalling, OutboundCalling, UserAssignment}
City : Marysville
CivicAddressId : 822d4d26-2c43-460f-921c-179163b106f8
IsoCountryCode : US
IsoSubdivision : Washington
LocationId : 4040949c-2424-469c-a9bc-563a5e5964f3
LocationUpdateSupported : True
NetworkSiteId :
PortInOrderStatus :
PstnAssignmentStatus : UserAssigned
PstnPartnerId : 7fc2f2eb-89aa-41d7-93de-73d015d22ff0
PstnPartnerName : Microsoft
NumberSource : Online
ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState : NotBlocked
AssignmentBlockedUntil :
SmsActivationState : Activated
```
This example displays information about the telephone number +1 (360) 322-7351 that is enabled for SMS.

### Example 17
```powershell
Get-CsPhoneNumberAssignment -TelephoneNumber +13603227351
```
```output
TelephoneNumber : +13603227351
OperatorId : 0019adbc-b82a-47b4-a799-4e993a9982f1
NumberType : CallingPlan
ActivationState : Activated
AssignedPstnTargetId : 2d43c5da-649b-406b-9d32-d130d2c53018
AssignmentCategory : Primary
Capability : {Geographic, InboundCalling, OutboundCalling, UserAssignment}
City : Marysville
CivicAddressId : 822d4d26-2c43-460f-921c-179163b106f8
IsoCountryCode : US
IsoSubdivision : Washington
LocationId : 4040949c-2424-469c-a9bc-563a5e5964f3
LocationUpdateSupported : True
NetworkSiteId :
PortInOrderStatus :
PstnAssignmentStatus : UserAssigned
PstnPartnerId : 7fc2f2eb-89aa-41d7-93de-73d015d22ff0
PstnPartnerName : Microsoft
NumberSource : Online
ReverseNumberLookup : {}
Tag : {}
AssignmentBlockedState : NotBlocked
AssignmentBlockedUntil :
SmsActivationState : UpdatePending
```
This example displays information about the telephone number +1 (360) 322-7351 where SMS activation is pending.


## PARAMETERS

Expand Down Expand Up @@ -785,7 +857,7 @@ The activation state of the telephone number.
The ID of the object the phone number is assigned to, either the ObjectId of a user or resource account or the policy instance ID of a Teams shared calling routing policy instance.

### AssignmentBlockedState
The state of the number in terms of blocked assignment: NotBlocked if there is no assignment block on the number, BlockedForever if assignment is blocked indefinitely for the number, BlockedUntil if assignment is blocked for a specific amount of days.
The state of the number in terms of blocked assignment: NotBlocked if there is no assignment block on the number, BlockedForever if assignment is blocked indefinitely for the number, BlockedUntil if assignment is blocked for a specific amount of days (limited time assignment block currently not available).

### AssignmentBlockedUntil
The date until which assignment is blocked for the phone number. Null if the number is blocked for assignment indefinitely.
Expand Down Expand Up @@ -838,6 +910,12 @@ The ID of the PSTN partner providing the phone number.
### PstnPartnerName
The name of the PSTN partner.

### SmsActivationState
The SMS activation state of the number.

### SmsProfileId
The Id of the SMS partner.

### TelephoneNumber
The phone number. The number is always displayed with prefixed "+", even if it was not assigned using prefixed "+".

Expand Down
Loading