Skip to content

Commit 4c8871d

Browse files
authored
Merge pull request #11038 from joannawang-msft/patch-3
Update app-only-auth-powershell-v2.md
2 parents 6803c8c + 9e798ea commit 4c8871d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

exchange/docs-conceptual/app-only-auth-powershell-v2.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -433,15 +433,15 @@ To assign custom role groups to the application using service principals, do the
433433
- Store the details of the service principal in a variable.
434434

435435
```powershell
436-
New-ServicePrincipal -AppId $<VariableName1>.AppId -ServiceId $<VariableName1>.ObjectId -DisplayName "<Descriptive Name>"
436+
New-ServicePrincipal -AppId $<VariableName1>.AppId -ObjectId $<VariableName1>.ObjectId -DisplayName "<Descriptive Name>"
437437
438438
$<VariableName2> = Get-ServicePrincipal -Identity "<Descriptive Name>"
439439
```
440440

441441
For example:
442442

443443
```powershell
444-
New-ServicePrincipal -AppId $AADApp.AppId -ServiceId $AADApp.ObjectId -DisplayName "SP for Azure App ExO PowerShell CBA"
444+
New-ServicePrincipal -AppId $AADApp.AppId -ObjectId $AADApp.ObjectId -DisplayName "SP for Azure App ExO PowerShell CBA"
445445
446446
$SP = Get-ServicePrincipal -Identity "SP for Azure App ExO PowerShell CBA"
447447
```
@@ -451,7 +451,7 @@ To assign custom role groups to the application using service principals, do the
451451
3. In Exchange Online PowerShell or Security & Compliance PowerShell, run the following command to add the service principal as a member of the custom role group:
452452

453453
```powershell
454-
Add-RoleGroupMember -Identity "<CustomRoleGroupName>" -Member <$<VariableName2>.Identity | $<VariableName2>.ServiceId | $<VariableName2>.Id>
454+
Add-RoleGroupMember -Identity "<CustomRoleGroupName>" -Member <$<VariableName2>.Identity | $<VariableName2>.ObjectId | $<VariableName2>.Id>
455455
```
456456

457457
For example:

0 commit comments

Comments
 (0)