diff --git a/src/Applications/Applications/examples/v1.0-beta/Confirm-MgApplicationMemberGroup.md b/src/Applications/Applications/examples/v1.0-beta/Confirm-MgApplicationMemberGroup.md index 093355d11d5..1627559222d 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Confirm-MgApplicationMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0-beta/Confirm-MgApplicationMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Confirm-MgServicePrincipalMemberGroup.md b/src/Applications/Applications/examples/v1.0-beta/Confirm-MgServicePrincipalMemberGroup.md index 093355d11d5..2cdac1ffa65 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Confirm-MgServicePrincipalMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0-beta/Confirm-MgServicePrincipalMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationById.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationById.md index 093355d11d5..6d01ed3cf43 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationById.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberGroup.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberGroup.md index 093355d11d5..552403968eb 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberObject.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberObject.md index 093355d11d5..fc9ad8eebec 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberObject.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgApplicationMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalById.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalById.md index 093355d11d5..fd9ab342921 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalById.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberGroup.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberGroup.md index 093355d11d5..599a29ad413 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberObject.md b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberObject.md index 093355d11d5..24ead0cd144 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberObject.md +++ b/src/Applications/Applications/examples/v1.0-beta/Get-MgServicePrincipalMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Test-MgApplicationProperty.md b/src/Applications/Applications/examples/v1.0-beta/Test-MgApplicationProperty.md index 093355d11d5..a1a8d89bc09 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Test-MgApplicationProperty.md +++ b/src/Applications/Applications/examples/v1.0-beta/Test-MgApplicationProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgApplicationProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0-beta/Test-MgServicePrincipalProperty.md b/src/Applications/Applications/examples/v1.0-beta/Test-MgServicePrincipalProperty.md index 093355d11d5..5a93a8aa2c4 100644 --- a/src/Applications/Applications/examples/v1.0-beta/Test-MgServicePrincipalProperty.md +++ b/src/Applications/Applications/examples/v1.0-beta/Test-MgServicePrincipalProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgServicePrincipalProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Confirm-MgApplicationMemberGroup.md b/src/Applications/Applications/examples/v1.0/Confirm-MgApplicationMemberGroup.md index 093355d11d5..1627559222d 100644 --- a/src/Applications/Applications/examples/v1.0/Confirm-MgApplicationMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0/Confirm-MgApplicationMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Confirm-MgServicePrincipalMemberGroup.md b/src/Applications/Applications/examples/v1.0/Confirm-MgServicePrincipalMemberGroup.md index 093355d11d5..2cdac1ffa65 100644 --- a/src/Applications/Applications/examples/v1.0/Confirm-MgServicePrincipalMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0/Confirm-MgServicePrincipalMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgApplicationById.md b/src/Applications/Applications/examples/v1.0/Get-MgApplicationById.md index 093355d11d5..6d01ed3cf43 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgApplicationById.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgApplicationById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberGroup.md b/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberGroup.md index 093355d11d5..552403968eb 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberObject.md b/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberObject.md index 093355d11d5..fc9ad8eebec 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberObject.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgApplicationMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgApplicationMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalById.md b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalById.md index 093355d11d5..fd9ab342921 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalById.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberGroup.md b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberGroup.md index 093355d11d5..599a29ad413 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberGroup.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberObject.md b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberObject.md index 093355d11d5..24ead0cd144 100644 --- a/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberObject.md +++ b/src/Applications/Applications/examples/v1.0/Get-MgServicePrincipalMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgServicePrincipalMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Test-MgApplicationProperty.md b/src/Applications/Applications/examples/v1.0/Test-MgApplicationProperty.md index 093355d11d5..a1a8d89bc09 100644 --- a/src/Applications/Applications/examples/v1.0/Test-MgApplicationProperty.md +++ b/src/Applications/Applications/examples/v1.0/Test-MgApplicationProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgApplicationProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Applications/Applications/examples/v1.0/Test-MgServicePrincipalProperty.md b/src/Applications/Applications/examples/v1.0/Test-MgServicePrincipalProperty.md index 093355d11d5..5a93a8aa2c4 100644 --- a/src/Applications/Applications/examples/v1.0/Test-MgServicePrincipalProperty.md +++ b/src/Applications/Applications/examples/v1.0/Test-MgServicePrincipalProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgServicePrincipalProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/CloudCommunications/CloudCommunications/examples/v1.0-beta/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md b/src/CloudCommunications/CloudCommunications/examples/v1.0-beta/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md index 093355d11d5..8b997a230fa 100644 --- a/src/CloudCommunications/CloudCommunications/examples/v1.0-beta/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md +++ b/src/CloudCommunications/CloudCommunications/examples/v1.0-beta/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md @@ -1,18 +1,29 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + StartDateTime = [System.DateTime]::Parse("2020-02-06T01:49:21.3524945+00:00") + EndDateTime = [System.DateTime]::Parse("2020-02-06T02:19:21.3524945+00:00") + Subject = "Create a meeting with customId provided" + ExternalId = "7eb8263f-d0e0-4149-bb1c-1f0476083c56" + Participants = @{ + Attendees = @( + @{ + Identity = @{ + User = @{ + Id = "1f35f2e6-9cab-44ad-8d5a-b74c14720000" + } + } + Upn = "test1@contoso.com" + } + ) + } +} +# A UPN can also be used as -UserId. +Invoke-MgCreateOrGetUserOnlineMeeting -UserId $userId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCreateOrGetCommunicationOnlineMeeting Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/CloudCommunications/CloudCommunications/examples/v1.0/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md b/src/CloudCommunications/CloudCommunications/examples/v1.0/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md index 093355d11d5..8b997a230fa 100644 --- a/src/CloudCommunications/CloudCommunications/examples/v1.0/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md +++ b/src/CloudCommunications/CloudCommunications/examples/v1.0/Invoke-MgCreateOrGetCommunicationOnlineMeeting.md @@ -1,18 +1,29 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + StartDateTime = [System.DateTime]::Parse("2020-02-06T01:49:21.3524945+00:00") + EndDateTime = [System.DateTime]::Parse("2020-02-06T02:19:21.3524945+00:00") + Subject = "Create a meeting with customId provided" + ExternalId = "7eb8263f-d0e0-4149-bb1c-1f0476083c56" + Participants = @{ + Attendees = @( + @{ + Identity = @{ + User = @{ + Id = "1f35f2e6-9cab-44ad-8d5a-b74c14720000" + } + } + Upn = "test1@contoso.com" + } + ) + } +} +# A UPN can also be used as -UserId. +Invoke-MgCreateOrGetUserOnlineMeeting -UserId $userId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCreateOrGetCommunicationOnlineMeeting Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md index 093355d11d5..749bd5f6871 100644 --- a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md +++ b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.DeviceManagement.Enrolment +Stop-MgRoleManagementDirectoryRoleAssignmentScheduleRequest -UnifiedRoleAssignmentScheduleRequestId $unifiedRoleAssignmentScheduleRequestId +``` +This example shows how to use the Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md index 093355d11d5..72e950ef413 100644 --- a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md +++ b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0-beta/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.DeviceManagement.Enrolment +Stop-MgRoleManagementDirectoryRoleEligibilityScheduleRequest -UnifiedRoleEligibilityScheduleRequestId $unifiedRoleEligibilityScheduleRequestId +``` +This example shows how to use the Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md index 093355d11d5..749bd5f6871 100644 --- a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md +++ b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.DeviceManagement.Enrolment +Stop-MgRoleManagementDirectoryRoleAssignmentScheduleRequest -UnifiedRoleAssignmentScheduleRequestId $unifiedRoleAssignmentScheduleRequestId +``` +This example shows how to use the Stop-MgRoleManagementEntitlementManagementRoleAssignmentScheduleRequest Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md index 093355d11d5..72e950ef413 100644 --- a/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md +++ b/src/DeviceManagement.Enrolment/DeviceManagement.Enrolment/examples/v1.0/Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.DeviceManagement.Enrolment +Stop-MgRoleManagementDirectoryRoleEligibilityScheduleRequest -UnifiedRoleEligibilityScheduleRequestId $unifiedRoleEligibilityScheduleRequestId +``` +This example shows how to use the Stop-MgRoleManagementEntitlementManagementRoleEligibilityScheduleRequest Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/DirectoryObjects/DirectoryObjects/examples/v1.0-beta/Get-MgDirectoryObjectMemberObject.md b/src/DirectoryObjects/DirectoryObjects/examples/v1.0-beta/Get-MgDirectoryObjectMemberObject.md index 093355d11d5..f663c5a8826 100644 --- a/src/DirectoryObjects/DirectoryObjects/examples/v1.0-beta/Get-MgDirectoryObjectMemberObject.md +++ b/src/DirectoryObjects/DirectoryObjects/examples/v1.0-beta/Get-MgDirectoryObjectMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryObjectMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationMeAssignmentSubmission.md index 093355d11d5..1a389760868 100644 --- a/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgReturnEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgReturnEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationUserAssignmentSubmission.md index 093355d11d5..744eef9a72a 100644 --- a/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Invoke-MgReturnEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgReturnEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgReturnEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md index 093355d11d5..44f5f342e35 100644 --- a/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgUnsubmitEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgUnsubmitEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md index 093355d11d5..a655241fe5d 100644 --- a/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgUnsubmitEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgUnsubmitEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Publish-MgEducationMeAssignment.md b/src/Education/Education/examples/v1.0-beta/Publish-MgEducationMeAssignment.md index 093355d11d5..cc81d88e4c6 100644 --- a/src/Education/Education/examples/v1.0-beta/Publish-MgEducationMeAssignment.md +++ b/src/Education/Education/examples/v1.0-beta/Publish-MgEducationMeAssignment.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Publish-MgEducationClassAssignment -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId +``` +This example shows how to use the Publish-MgEducationMeAssignment Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Publish-MgEducationUserAssignment.md b/src/Education/Education/examples/v1.0-beta/Publish-MgEducationUserAssignment.md index 093355d11d5..ac1664e61a4 100644 --- a/src/Education/Education/examples/v1.0-beta/Publish-MgEducationUserAssignment.md +++ b/src/Education/Education/examples/v1.0-beta/Publish-MgEducationUserAssignment.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Publish-MgEducationClassAssignment -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId +``` +This example shows how to use the Publish-MgEducationUserAssignment Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Submit-MgEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Submit-MgEducationMeAssignmentSubmission.md index 093355d11d5..4a1e08d8fe6 100644 --- a/src/Education/Education/examples/v1.0-beta/Submit-MgEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Submit-MgEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Submit-MgEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Submit-MgEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0-beta/Submit-MgEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0-beta/Submit-MgEducationUserAssignmentSubmission.md index 093355d11d5..418ef34f455 100644 --- a/src/Education/Education/examples/v1.0-beta/Submit-MgEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0-beta/Submit-MgEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Submit-MgEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Submit-MgEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationMeAssignmentSubmission.md index 093355d11d5..1a389760868 100644 --- a/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgReturnEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgReturnEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationUserAssignmentSubmission.md index 093355d11d5..744eef9a72a 100644 --- a/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Invoke-MgReturnEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgReturnEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgReturnEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md index 093355d11d5..44f5f342e35 100644 --- a/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgUnsubmitEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgUnsubmitEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md index 093355d11d5..a655241fe5d 100644 --- a/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Invoke-MgUnsubmitEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Invoke-MgUnsubmitEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Invoke-MgUnsubmitEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Publish-MgEducationMeAssignment.md b/src/Education/Education/examples/v1.0/Publish-MgEducationMeAssignment.md index 093355d11d5..cc81d88e4c6 100644 --- a/src/Education/Education/examples/v1.0/Publish-MgEducationMeAssignment.md +++ b/src/Education/Education/examples/v1.0/Publish-MgEducationMeAssignment.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Publish-MgEducationClassAssignment -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId +``` +This example shows how to use the Publish-MgEducationMeAssignment Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Publish-MgEducationUserAssignment.md b/src/Education/Education/examples/v1.0/Publish-MgEducationUserAssignment.md index 093355d11d5..ac1664e61a4 100644 --- a/src/Education/Education/examples/v1.0/Publish-MgEducationUserAssignment.md +++ b/src/Education/Education/examples/v1.0/Publish-MgEducationUserAssignment.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Publish-MgEducationClassAssignment -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId +``` +This example shows how to use the Publish-MgEducationUserAssignment Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Submit-MgEducationMeAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Submit-MgEducationMeAssignmentSubmission.md index 093355d11d5..4a1e08d8fe6 100644 --- a/src/Education/Education/examples/v1.0/Submit-MgEducationMeAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Submit-MgEducationMeAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Submit-MgEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Submit-MgEducationMeAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Education/Education/examples/v1.0/Submit-MgEducationUserAssignmentSubmission.md b/src/Education/Education/examples/v1.0/Submit-MgEducationUserAssignmentSubmission.md index 093355d11d5..418ef34f455 100644 --- a/src/Education/Education/examples/v1.0/Submit-MgEducationUserAssignmentSubmission.md +++ b/src/Education/Education/examples/v1.0/Submit-MgEducationUserAssignmentSubmission.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Education +Submit-MgEducationClassAssignmentSubmission -EducationClassId $educationClassId -EducationAssignmentId $educationAssignmentId -EducationSubmissionId $educationSubmissionId +``` +This example shows how to use the Submit-MgEducationUserAssignmentSubmission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Files/Files/examples/v1.0-beta/Restore-MgDriveListItemVersion.md b/src/Files/Files/examples/v1.0-beta/Restore-MgDriveListItemVersion.md index 093355d11d5..ea2b1d02022 100644 --- a/src/Files/Files/examples/v1.0-beta/Restore-MgDriveListItemVersion.md +++ b/src/Files/Files/examples/v1.0-beta/Restore-MgDriveListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgDriveListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Files/Files/examples/v1.0-beta/Restore-MgShareListItemVersion.md b/src/Files/Files/examples/v1.0-beta/Restore-MgShareListItemVersion.md index 093355d11d5..d3e1e042285 100644 --- a/src/Files/Files/examples/v1.0-beta/Restore-MgShareListItemVersion.md +++ b/src/Files/Files/examples/v1.0-beta/Restore-MgShareListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgShareListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Files/Files/examples/v1.0/Restore-MgDriveListItemVersion.md b/src/Files/Files/examples/v1.0/Restore-MgDriveListItemVersion.md index 093355d11d5..ea2b1d02022 100644 --- a/src/Files/Files/examples/v1.0/Restore-MgDriveListItemVersion.md +++ b/src/Files/Files/examples/v1.0/Restore-MgDriveListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgDriveListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Files/Files/examples/v1.0/Restore-MgShareListItemVersion.md b/src/Files/Files/examples/v1.0/Restore-MgShareListItemVersion.md index 093355d11d5..d3e1e042285 100644 --- a/src/Files/Files/examples/v1.0/Restore-MgShareListItemVersion.md +++ b/src/Files/Files/examples/v1.0/Restore-MgShareListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgShareListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopy.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopy.md index 093355d11d5..20ef36cf54b 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md index 093355d11d5..d8e9f3405d8 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopy.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopy.md index 093355d11d5..786bb789ba6 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md index 093355d11d5..df305c5cb98 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopy.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopy.md index 093355d11d5..fb73eacda86 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md index 093355d11d5..1723e67ff68 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0-beta/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupMemberGroup.md b/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupMemberGroup.md index 093355d11d5..abb97f1cdf6 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupPermissionGrantMemberGroup.md b/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupPermissionGrantMemberGroup.md index 093355d11d5..ad70b2f1159 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupPermissionGrantMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0-beta/Confirm-MgGroupPermissionGrantMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md index 093355d11d5..8d619750093 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupDriveListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteNotebook.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteNotebook.md index 093355d11d5..823360dbfc2 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteNotebook.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteNotebook.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteNotebook -UserId $userId -NotebookId $notebookId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenotePageToSection.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenotePageToSection.md index 093355d11d5..5b71558b3a2 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenotePageToSection.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenotePageToSection.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenotePageToSection -UserId $userId -OnenotePageId $onenotePageId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenotePageToSection Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToNotebook.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToNotebook.md index 093355d11d5..3768165ad57 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToNotebook.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToNotebook.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToNotebook -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteSectionToNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToSectionGroup.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToSectionGroup.md index 093355d11d5..28e4680d161 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToSectionGroup.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupOnenoteSectionToSectionGroup.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToSectionGroup -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteSectionToSectionGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md index 093355d11d5..c909beda839 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupSiteContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md index 093355d11d5..06e5517fe09 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0-beta/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupSiteListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupById.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupById.md index 093355d11d5..93632a147f1 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupById.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgGroupById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupCalendarSchedule.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupCalendarSchedule.md index 093355d11d5..a116df3befa 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupCalendarSchedule.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupCalendarSchedule.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Schedules = @( + "adelev@contoso.onmicrosoft.com" + "meganb@contoso.onmicrosoft.com" + ) + StartTime = @{ + DateTime = "2019-03-15T09:00:00" + TimeZone = "Pacific Standard Time" + } + EndTime = @{ + DateTime = "2019-03-15T18:00:00" + TimeZone = "Pacific Standard Time" + } + AvailabilityViewInterval = 60 +} +# A UPN can also be used as -UserId. +Get-MgUserDefaultCalendarSchedule -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupCalendarSchedule Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberGroup.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberGroup.md index 093355d11d5..5b701bf01d4 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberObject.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberObject.md index 093355d11d5..3f17a303441 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberObject.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupOnenoteNotebookFromWebUrl.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupOnenoteNotebookFromWebUrl.md index 093355d11d5..986aea89529 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupOnenoteNotebookFromWebUrl.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupOnenoteNotebookFromWebUrl.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + WebUrl = "webUrl value" +} +# A UPN can also be used as -UserId. +Get-MgUserOnenoteNotebookFromWebUrl -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupOnenoteNotebookFromWebUrl Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberGroup.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberGroup.md index 093355d11d5..36c41ab2509 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberObject.md b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberObject.md index 093355d11d5..fbda4de79dd 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberObject.md +++ b/src/Groups/Groups/examples/v1.0-beta/Get-MgGroupPermissionGrantMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveItemPermission.md b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveItemPermission.md index 093355d11d5..4bc44b3421f 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveItemPermission.md +++ b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveItemPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupDriveItemPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveRootPermission.md b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveRootPermission.md index 093355d11d5..37dcac81bff 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveRootPermission.md +++ b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupDriveRootPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupDriveRootPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupSitePermission.md b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupSitePermission.md index 093355d11d5..7b5b1efe4c4 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupSitePermission.md +++ b/src/Groups/Groups/examples/v1.0-beta/Grant-MgGroupSitePermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupSitePermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEvent.md index 093355d11d5..b0503c64933 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEvent.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEventTentatively.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEventTentatively.md index 093355d11d5..262158d64b1 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEventTentatively.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupCalendarEventTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupCalendarEventTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEvent.md index 093355d11d5..7da0b0a71ff 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEvent.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEventTentatively.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEventTentatively.md index 093355d11d5..f4fb3296bd8 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEventTentatively.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgAcceptGroupEventTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupEventTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveItem.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveItem.md index 093355d11d5..210876c140b 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveItem.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveItem.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinGroupDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveRoot.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveRoot.md index 093355d11d5..bea20b741e9 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveRoot.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckinGroupDriveRoot.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinGroupDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveItem.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveItem.md index 093355d11d5..7967ddad643 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveItem.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveItem.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutGroupDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveRoot.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveRoot.md index 093355d11d5..43b97013b82 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveRoot.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgCheckoutGroupDriveRoot.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutGroupDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupCalendarEvent.md index 093355d11d5..1e7c66d8439 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupCalendarEvent.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupEvent.md index 093355d11d5..3104012aa9e 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDeclineGroupEvent.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupCalendarEventReminder.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupCalendarEventReminder.md index 093355d11d5..ca9cc6eff1b 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupCalendarEventReminder.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupCalendarEventReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissGroupCalendarEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupEventReminder.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupEventReminder.md index 093355d11d5..6baea04a224 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupEventReminder.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgDismissGroupEventReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissGroupEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupCalendarEvent.md index 093355d11d5..5fe8fc1f2d6 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupCalendarEvent.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPost.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPost.md index 093355d11d5..2e27648056d 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPost.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPost.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupConversationThreadPost Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md index 093355d11d5..d8d0528f100 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupConversationThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupEvent.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupEvent.md index 093355d11d5..558cf55176a 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupEvent.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupThreadPostInReplyTo.md index 093355d11d5..949da4f90df 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgForwardGroupThreadPostInReplyTo.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThread.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThread.md index 093355d11d5..cf82bf5ba7c 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThread.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThread.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Include a file attachment -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "Which quarter does that file cover? See my attachment." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + Name = "Another file as attachment" + ContentBytes = "VGhpcyBpcyBhIGZpbGUgdG8gYmUgYXR0YWNoZWQu" + } + ) + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Include an item attachment -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "I attached an event." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.itemAttachment" + Name = "Holiday event" + Item = @{ + "@odata.type" = "microsoft.graph.event" + Subject = "Discuss gifts for children" + } + } + ) + } +} +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Include a reference attachment + +```powershell Import-Module Microsoft.Graph.Groups + +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "I attached a reference to a file on OneDrive." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.referenceAttachment" + Name = "Personal pictures" + SourceUrl = "https://contoso.com/personal/mario_contoso_net/Documents/Pics" + ProviderType = "oneDriveConsumer" + Permission = "Edit" + IsFolder = "True" + } + ) + } +} + +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPost.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPost.md index 093355d11d5..9d43fe66a89 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPost.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPost.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThreadPost Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md index 093355d11d5..4b229e75ed6 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupThreadPostInReplyTo.md index 093355d11d5..24bd9f8fdef 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgReplyGroupThreadPostInReplyTo.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupCalendarEventReminder.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupCalendarEventReminder.md index 093355d11d5..c9aa5016e01 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupCalendarEventReminder.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupCalendarEventReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeGroupCalendarEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupEventReminder.md b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupEventReminder.md index 093355d11d5..412c0070b67 100644 --- a/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupEventReminder.md +++ b/src/Groups/Groups/examples/v1.0-beta/Invoke-MgSnoozeGroupEventReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeGroupEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostAttachmentUploadSession.md b/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostAttachmentUploadSession.md index 093355d11d5..6647ae0737c 100644 --- a/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostAttachmentUploadSession.md +++ b/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md b/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md index 093355d11d5..96c7bb5ed5c 100644 --- a/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md +++ b/src/Groups/Groups/examples/v1.0-beta/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopy.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopy.md index 093355d11d5..20ef36cf54b 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md index 093355d11d5..d8e9f3405d8 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupDriveListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopy.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopy.md index 093355d11d5..786bb789ba6 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md index 093355d11d5..df305c5cb98 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopy.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopy.md index 093355d11d5..fb73eacda86 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopy.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md index 093355d11d5..1723e67ff68 100644 --- a/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md +++ b/src/Groups/Groups/examples/v1.0/Add-MgGroupSiteListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgGroupSiteListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Confirm-MgGroupMemberGroup.md b/src/Groups/Groups/examples/v1.0/Confirm-MgGroupMemberGroup.md index 093355d11d5..abb97f1cdf6 100644 --- a/src/Groups/Groups/examples/v1.0/Confirm-MgGroupMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0/Confirm-MgGroupMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Confirm-MgGroupPermissionGrantMemberGroup.md b/src/Groups/Groups/examples/v1.0/Confirm-MgGroupPermissionGrantMemberGroup.md index 093355d11d5..ad70b2f1159 100644 --- a/src/Groups/Groups/examples/v1.0/Confirm-MgGroupPermissionGrantMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0/Confirm-MgGroupPermissionGrantMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md index 093355d11d5..8d619750093 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupDriveListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupDriveListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteNotebook.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteNotebook.md index 093355d11d5..823360dbfc2 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteNotebook.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteNotebook.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteNotebook -UserId $userId -NotebookId $notebookId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenotePageToSection.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenotePageToSection.md index 093355d11d5..5b71558b3a2 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenotePageToSection.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenotePageToSection.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenotePageToSection -UserId $userId -OnenotePageId $onenotePageId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenotePageToSection Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToNotebook.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToNotebook.md index 093355d11d5..3768165ad57 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToNotebook.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToNotebook.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToNotebook -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteSectionToNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToSectionGroup.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToSectionGroup.md index 093355d11d5..28e4680d161 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToSectionGroup.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupOnenoteSectionToSectionGroup.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToSectionGroup -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupOnenoteSectionToSectionGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md index 093355d11d5..c909beda839 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupSiteContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md b/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md index 093355d11d5..06e5517fe09 100644 --- a/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md +++ b/src/Groups/Groups/examples/v1.0/Copy-MgGroupSiteListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgGroupSiteListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupById.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupById.md index 093355d11d5..93632a147f1 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupById.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgGroupById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupCalendarSchedule.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupCalendarSchedule.md index 093355d11d5..a116df3befa 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupCalendarSchedule.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupCalendarSchedule.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Schedules = @( + "adelev@contoso.onmicrosoft.com" + "meganb@contoso.onmicrosoft.com" + ) + StartTime = @{ + DateTime = "2019-03-15T09:00:00" + TimeZone = "Pacific Standard Time" + } + EndTime = @{ + DateTime = "2019-03-15T18:00:00" + TimeZone = "Pacific Standard Time" + } + AvailabilityViewInterval = 60 +} +# A UPN can also be used as -UserId. +Get-MgUserDefaultCalendarSchedule -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupCalendarSchedule Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberGroup.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberGroup.md index 093355d11d5..5b701bf01d4 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberObject.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberObject.md index 093355d11d5..3f17a303441 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberObject.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupOnenoteNotebookFromWebUrl.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupOnenoteNotebookFromWebUrl.md index 093355d11d5..986aea89529 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupOnenoteNotebookFromWebUrl.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupOnenoteNotebookFromWebUrl.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + WebUrl = "webUrl value" +} +# A UPN can also be used as -UserId. +Get-MgUserOnenoteNotebookFromWebUrl -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupOnenoteNotebookFromWebUrl Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberGroup.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberGroup.md index 093355d11d5..36c41ab2509 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberGroup.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberObject.md b/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberObject.md index 093355d11d5..fbda4de79dd 100644 --- a/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberObject.md +++ b/src/Groups/Groups/examples/v1.0/Get-MgGroupPermissionGrantMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgGroupPermissionGrantMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveItemPermission.md b/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveItemPermission.md index 093355d11d5..4bc44b3421f 100644 --- a/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveItemPermission.md +++ b/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveItemPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupDriveItemPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveRootPermission.md b/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveRootPermission.md index 093355d11d5..37dcac81bff 100644 --- a/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveRootPermission.md +++ b/src/Groups/Groups/examples/v1.0/Grant-MgGroupDriveRootPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupDriveRootPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Grant-MgGroupSitePermission.md b/src/Groups/Groups/examples/v1.0/Grant-MgGroupSitePermission.md index 093355d11d5..7b5b1efe4c4 100644 --- a/src/Groups/Groups/examples/v1.0/Grant-MgGroupSitePermission.md +++ b/src/Groups/Groups/examples/v1.0/Grant-MgGroupSitePermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgGroupSitePermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEvent.md index 093355d11d5..b0503c64933 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEvent.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEventTentatively.md b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEventTentatively.md index 093355d11d5..262158d64b1 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEventTentatively.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupCalendarEventTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupCalendarEventTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEvent.md index 093355d11d5..7da0b0a71ff 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEvent.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEventTentatively.md b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEventTentatively.md index 093355d11d5..f4fb3296bd8 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEventTentatively.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgAcceptGroupEventTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptGroupEventTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveItem.md b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveItem.md index 093355d11d5..210876c140b 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveItem.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveItem.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinGroupDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveRoot.md b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveRoot.md index 093355d11d5..bea20b741e9 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveRoot.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckinGroupDriveRoot.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinGroupDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveItem.md b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveItem.md index 093355d11d5..7967ddad643 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveItem.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveItem.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutGroupDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveRoot.md b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveRoot.md index 093355d11d5..43b97013b82 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveRoot.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgCheckoutGroupDriveRoot.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutGroupDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupCalendarEvent.md index 093355d11d5..1e7c66d8439 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupCalendarEvent.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupEvent.md index 093355d11d5..3104012aa9e 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgDeclineGroupEvent.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupCalendarEventReminder.md b/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupCalendarEventReminder.md index 093355d11d5..ca9cc6eff1b 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupCalendarEventReminder.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupCalendarEventReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissGroupCalendarEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupEventReminder.md b/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupEventReminder.md index 093355d11d5..6baea04a224 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupEventReminder.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgDismissGroupEventReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissGroupEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupCalendarEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupCalendarEvent.md index 093355d11d5..5fe8fc1f2d6 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupCalendarEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupCalendarEvent.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupCalendarEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPost.md b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPost.md index 093355d11d5..2e27648056d 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPost.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPost.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupConversationThreadPost Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md index 093355d11d5..d8d0528f100 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupConversationThreadPostInReplyTo.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupConversationThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupEvent.md b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupEvent.md index 093355d11d5..558cf55176a 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupEvent.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupEvent.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupEvent Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupThreadPostInReplyTo.md index 093355d11d5..949da4f90df 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgForwardGroupThreadPostInReplyTo.md @@ -1,18 +1,21 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +Invoke-MgForwardGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardGroupThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThread.md b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThread.md index 093355d11d5..cf82bf5ba7c 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThread.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThread.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Include a file attachment -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "Which quarter does that file cover? See my attachment." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + Name = "Another file as attachment" + ContentBytes = "VGhpcyBpcyBhIGZpbGUgdG8gYmUgYXR0YWNoZWQu" + } + ) + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Include an item attachment -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "I attached an event." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.itemAttachment" + Name = "Holiday event" + Item = @{ + "@odata.type" = "microsoft.graph.event" + Subject = "Discuss gifts for children" + } + } + ) + } +} +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Include a reference attachment + +```powershell Import-Module Microsoft.Graph.Groups + +$params = @{ + Post = @{ + Body = @{ + ContentType = "text" + Content = "I attached a reference to a file on OneDrive." + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.referenceAttachment" + Name = "Personal pictures" + SourceUrl = "https://contoso.com/personal/mario_contoso_net/Documents/Pics" + ProviderType = "oneDriveConsumer" + Permission = "Edit" + IsFolder = "True" + } + ) + } +} + +Invoke-MgReplyGroupThread -GroupId $groupId -ConversationThreadId $conversationThreadId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThread Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPost.md b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPost.md index 093355d11d5..9d43fe66a89 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPost.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPost.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThreadPost Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md index 093355d11d5..4b229e75ed6 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupConversationThreadPostInReplyTo.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupConversationThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupThreadPostInReplyTo.md b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupThreadPostInReplyTo.md index 093355d11d5..24bd9f8fdef 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupThreadPostInReplyTo.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgReplyGroupThreadPostInReplyTo.md @@ -1,18 +1,62 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Groups -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Post = @{ + Body = @{ + ContentType = "" + Content = "content-value" + } + ReceivedDateTime = [System.DateTime]::Parse("datetime-value") + HasAttachments = $true + From = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + Sender = @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ConversationThreadId = "conversationThreadId-value" + NewParticipants = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) + ConversationId = "conversationId-value" + CreatedDateTime = [System.DateTime]::Parse("datetime-value") + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + ChangeKey = "changeKey-value" + Categories = @( + "categories-value" + ) + Id = "id-value" + InReplyTo = @{ + } + Attachments = @( + @{ + "@odata.type" = "#microsoft.graph.fileAttachment" + LastModifiedDateTime = [System.DateTime]::Parse("datetime-value") + Name = "name-value" + ContentType = "contentType-value" + Size = 99 + IsInline = $true + Id = "id-value" + } + ) + } +} +Invoke-MgReplyGroupThreadPost -GroupId $groupId -ConversationThreadId $conversationThreadId -PostId $postId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyGroupThreadPostInReplyTo Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupCalendarEventReminder.md b/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupCalendarEventReminder.md index 093355d11d5..c9aa5016e01 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupCalendarEventReminder.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupCalendarEventReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeGroupCalendarEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupEventReminder.md b/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupEventReminder.md index 093355d11d5..412c0070b67 100644 --- a/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupEventReminder.md +++ b/src/Groups/Groups/examples/v1.0/Invoke-MgSnoozeGroupEventReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeGroupEventReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostAttachmentUploadSession.md b/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostAttachmentUploadSession.md index 093355d11d5..6647ae0737c 100644 --- a/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostAttachmentUploadSession.md +++ b/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md b/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md index 093355d11d5..96c7bb5ed5c 100644 --- a/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md +++ b/src/Groups/Groups/examples/v1.0/New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgGroupConversationThreadPostInReplyToAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContactMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContactMemberGroup.md index 093355d11d5..c2f1a54d157 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContactMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContactMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContractMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContractMemberGroup.md index 093355d11d5..9beef18574f 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContractMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgContractMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDeviceMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDeviceMemberGroup.md index 093355d11d5..0b26e89fb1a 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDeviceMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryDeletedItemMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryDeletedItemMemberGroup.md index 093355d11d5..8850d054cf0 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryDeletedItemMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryDeletedItemMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleMemberGroup.md index 093355d11d5..a3a21a1b96a 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleTemplateMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleTemplateMemberGroup.md index 093355d11d5..797def08b4c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleTemplateMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgDirectoryRoleTemplateMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgOrganizationMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgOrganizationMemberGroup.md index 093355d11d5..9a35811edf0 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgOrganizationMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Confirm-MgOrganizationMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactById.md index 093355d11d5..1e82d69f22b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgContactById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberGroup.md index 093355d11d5..98ab06f094c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberObject.md index 093355d11d5..7f2c5fcc28f 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContactMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractById.md index 093355d11d5..501933fcf2b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgContractById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberGroup.md index 093355d11d5..0ff7f0945ff 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberObject.md index 093355d11d5..abac6db6f2b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgContractMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceById.md index 093355d11d5..397285288d3 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberGroup.md index 093355d11d5..6aec58a36af 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberObject.md index 093355d11d5..6d715b2ffa2 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberGroup.md index 093355d11d5..57a88279c1c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberObject.md index 093355d11d5..75c85b7a184 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryDeletedItemMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleById.md index 093355d11d5..75ad194fbe7 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberGroup.md index 093355d11d5..e7f06c3ba0c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberObject.md index 093355d11d5..4714a552dab 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateById.md index 093355d11d5..2d55f5b3529 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberGroup.md index 093355d11d5..80558feafec 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberObject.md index 093355d11d5..70b4645d729 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgDirectoryRoleTemplateMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationById.md index 093355d11d5..e106f33861e 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberGroup.md index 093355d11d5..d218d66d378 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberObject.md index 093355d11d5..074dd4a196c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Get-MgOrganizationMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContactProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContactProperty.md index 093355d11d5..6ed12437d5e 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContactProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContactProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgContactProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContractProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContractProperty.md index 093355d11d5..f3a5be3627c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContractProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgContractProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgContractProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDeviceProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDeviceProperty.md index 093355d11d5..19c3b050503 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDeviceProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDeviceProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDeviceProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryDeletedItemProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryDeletedItemProperty.md index 093355d11d5..10301c6c2e6 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryDeletedItemProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryDeletedItemProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryDeletedItemProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleProperty.md index 093355d11d5..f3b93bb711c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryRoleProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleTemplateProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleTemplateProperty.md index 093355d11d5..13064928e97 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleTemplateProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgDirectoryRoleTemplateProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryRoleTemplateProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgOrganizationProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgOrganizationProperty.md index 093355d11d5..a22b3de6dd5 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgOrganizationProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0-beta/Test-MgOrganizationProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgOrganizationProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContactMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContactMemberGroup.md index 093355d11d5..c2f1a54d157 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContactMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContactMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContractMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContractMemberGroup.md index 093355d11d5..9beef18574f 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContractMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgContractMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDeviceMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDeviceMemberGroup.md index 093355d11d5..0b26e89fb1a 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDeviceMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryDeletedItemMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryDeletedItemMemberGroup.md index 093355d11d5..8850d054cf0 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryDeletedItemMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryDeletedItemMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleMemberGroup.md index 093355d11d5..a3a21a1b96a 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleTemplateMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleTemplateMemberGroup.md index 093355d11d5..797def08b4c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleTemplateMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgDirectoryRoleTemplateMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgOrganizationMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgOrganizationMemberGroup.md index 093355d11d5..9a35811edf0 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgOrganizationMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Confirm-MgOrganizationMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactById.md index 093355d11d5..1e82d69f22b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgContactById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberGroup.md index 093355d11d5..98ab06f094c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberObject.md index 093355d11d5..7f2c5fcc28f 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContactMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContactMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractById.md index 093355d11d5..501933fcf2b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgContractById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberGroup.md index 093355d11d5..0ff7f0945ff 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberObject.md index 093355d11d5..abac6db6f2b 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgContractMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgContractMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceById.md index 093355d11d5..397285288d3 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberGroup.md index 093355d11d5..6aec58a36af 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberObject.md index 093355d11d5..6d715b2ffa2 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberGroup.md index 093355d11d5..57a88279c1c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberObject.md index 093355d11d5..75c85b7a184 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryDeletedItemMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryDeletedItemMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleById.md index 093355d11d5..75ad194fbe7 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberGroup.md index 093355d11d5..e7f06c3ba0c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberObject.md index 093355d11d5..4714a552dab 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateById.md index 093355d11d5..2d55f5b3529 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberGroup.md index 093355d11d5..80558feafec 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberObject.md index 093355d11d5..70b4645d729 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgDirectoryRoleTemplateMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgDirectoryRoleTemplateMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationById.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationById.md index 093355d11d5..e106f33861e 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationById.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberGroup.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberGroup.md index 093355d11d5..d218d66d378 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberGroup.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberObject.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberObject.md index 093355d11d5..074dd4a196c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberObject.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Get-MgOrganizationMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgOrganizationMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContactProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContactProperty.md index 093355d11d5..6ed12437d5e 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContactProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContactProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgContactProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContractProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContractProperty.md index 093355d11d5..f3a5be3627c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContractProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgContractProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgContractProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDeviceProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDeviceProperty.md index 093355d11d5..19c3b050503 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDeviceProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDeviceProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDeviceProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryDeletedItemProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryDeletedItemProperty.md index 093355d11d5..10301c6c2e6 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryDeletedItemProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryDeletedItemProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryDeletedItemProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleProperty.md index 093355d11d5..f3b93bb711c 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryRoleProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleTemplateProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleTemplateProperty.md index 093355d11d5..13064928e97 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleTemplateProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgDirectoryRoleTemplateProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgDirectoryRoleTemplateProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgOrganizationProperty.md b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgOrganizationProperty.md index 093355d11d5..a22b3de6dd5 100644 --- a/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgOrganizationProperty.md +++ b/src/Identity.DirectoryManagement/Identity.DirectoryManagement/examples/v1.0/Test-MgOrganizationProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgOrganizationProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md index 093355d11d5..c356c861e44 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md index 093355d11d5..7c98327e444 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation.md b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation.md index 093355d11d5..4786bb8b890 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Identity.Governance +Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation -AccessReviewScheduleDefinitionId $accessReviewScheduleDefinitionId -AccessReviewInstanceId $accessReviewInstanceId +``` +This example shows how to use the Invoke-MgAcceptIdentityGovernanceAccessReviewDefinitionInstanceRecommendation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision.md b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision.md index 093355d11d5..a2909b00e5e 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0-beta/Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Identity.Governance -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Decision = "Approve" + Justification = "All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team" + ResourceId = "a5c51e59-3fcd-4a37-87a1-835c0c21488a" +} +Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision -AccessReviewScheduleDefinitionId $accessReviewScheduleDefinitionId -AccessReviewInstanceId $accessReviewInstanceId -BodyParameter $params +``` +This example shows how to use the Invoke-MgBatchIdentityGovernanceAccessReviewDefinitionInstanceRecordDecision Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md b/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md index 093355d11d5..c356c861e44 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgEntitlementManagementConnectedOrganizationExternalSponsorById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md b/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md index 093355d11d5..7c98327e444 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0/Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgEntitlementManagementConnectedOrganizationInternalSponsorById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationExternalSponsorProperty.md b/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationExternalSponsorProperty.md index 093355d11d5..43d66917ed2 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationExternalSponsorProperty.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationExternalSponsorProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgEntitlementManagementConnectedOrganizationExternalSponsorProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationInternalSponsorProperty.md b/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationInternalSponsorProperty.md index 093355d11d5..5f09feb7e09 100644 --- a/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationInternalSponsorProperty.md +++ b/src/Identity.Governance/Identity.Governance/examples/v1.0/Test-MgEntitlementManagementConnectedOrganizationInternalSponsorProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgEntitlementManagementConnectedOrganizationInternalSponsorProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Get-MgPolicyFeatureRolloutPolicyApplyToById.md b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Get-MgPolicyFeatureRolloutPolicyApplyToById.md index 093355d11d5..09b2e72d3bb 100644 --- a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Get-MgPolicyFeatureRolloutPolicyApplyToById.md +++ b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Get-MgPolicyFeatureRolloutPolicyApplyToById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgPolicyFeatureRolloutPolicyApplyToById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder.md b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder.md index 093355d11d5..cdf8fae776a 100644 --- a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder.md +++ b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder.md @@ -1,18 +1,18 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Identity.SignIns -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewAssignmentOrder = @{ + Order = @( + "City" + "extension_GUID_ShoeSize" + ) + } +} +Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder -B2xIdentityUserFlowId $b2xIdentityUserFlowId -BodyParameter $params +``` +This example shows how to use the Set-MgIdentityB2XUserFlowUserAttributeAssignmentOrder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md index 093355d11d5..dd1ecf2a5c8 100644 --- a/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md +++ b/src/Identity.SignIns/Identity.SignIns/examples/v1.0-beta/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgPolicyFeatureRolloutPolicyApplyToProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Get-MgPolicyFeatureRolloutPolicyApplyToById.md b/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Get-MgPolicyFeatureRolloutPolicyApplyToById.md index 093355d11d5..09b2e72d3bb 100644 --- a/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Get-MgPolicyFeatureRolloutPolicyApplyToById.md +++ b/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Get-MgPolicyFeatureRolloutPolicyApplyToById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgPolicyFeatureRolloutPolicyApplyToById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md b/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md index 093355d11d5..dd1ecf2a5c8 100644 --- a/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md +++ b/src/Identity.SignIns/Identity.SignIns/examples/v1.0/Test-MgPolicyFeatureRolloutPolicyApplyToProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgPolicyFeatureRolloutPolicyApplyToProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopy.md b/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopy.md index 093355d11d5..294801639ce 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopy.md +++ b/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopyFromContentTypeHub.md b/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopyFromContentTypeHub.md index 093355d11d5..d7a7c014bfe 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopyFromContentTypeHub.md +++ b/src/Sites/Sites/examples/v1.0-beta/Add-MgSiteContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteListContentTypeToDefaultContentLocation.md b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteListContentTypeToDefaultContentLocation.md index 093355d11d5..11427cc5b11 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteListContentTypeToDefaultContentLocation.md +++ b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteNotebook.md b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteNotebook.md index 093355d11d5..7ef478c7320 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteNotebook.md +++ b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteNotebook.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteNotebook -UserId $userId -NotebookId $notebookId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenotePageToSection.md b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenotePageToSection.md index 093355d11d5..4069ed9d420 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenotePageToSection.md +++ b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenotePageToSection.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenotePageToSection -UserId $userId -OnenotePageId $onenotePageId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenotePageToSection Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToNotebook.md b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToNotebook.md index 093355d11d5..ea5201ecdf4 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToNotebook.md +++ b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToNotebook.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToNotebook -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteSectionToNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToSectionGroup.md b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToSectionGroup.md index 093355d11d5..ae69ac19bd0 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToSectionGroup.md +++ b/src/Sites/Sites/examples/v1.0-beta/Copy-MgSiteOnenoteSectionToSectionGroup.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToSectionGroup -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteSectionToSectionGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Get-MgSiteOnenoteNotebookFromWebUrl.md b/src/Sites/Sites/examples/v1.0-beta/Get-MgSiteOnenoteNotebookFromWebUrl.md index 093355d11d5..1a2e157a705 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Get-MgSiteOnenoteNotebookFromWebUrl.md +++ b/src/Sites/Sites/examples/v1.0-beta/Get-MgSiteOnenoteNotebookFromWebUrl.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + WebUrl = "webUrl value" +} +# A UPN can also be used as -UserId. +Get-MgUserOnenoteNotebookFromWebUrl -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgSiteOnenoteNotebookFromWebUrl Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Grant-MgSitePermission.md b/src/Sites/Sites/examples/v1.0-beta/Grant-MgSitePermission.md index 093355d11d5..ee2c0011b36 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Grant-MgSitePermission.md +++ b/src/Sites/Sites/examples/v1.0-beta/Grant-MgSitePermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgSitePermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Publish-MgSiteListContentType.md b/src/Sites/Sites/examples/v1.0-beta/Publish-MgSiteListContentType.md index 093355d11d5..9a52a137e47 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Publish-MgSiteListContentType.md +++ b/src/Sites/Sites/examples/v1.0-beta/Publish-MgSiteListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Publish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Publish-MgSiteListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Restore-MgSiteListItemVersion.md b/src/Sites/Sites/examples/v1.0-beta/Restore-MgSiteListItemVersion.md index 093355d11d5..df649ece3f7 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Restore-MgSiteListItemVersion.md +++ b/src/Sites/Sites/examples/v1.0-beta/Restore-MgSiteListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgSiteListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0-beta/Unpublish-MgSiteListContentType.md b/src/Sites/Sites/examples/v1.0-beta/Unpublish-MgSiteListContentType.md index 093355d11d5..7fd53c8bcdf 100644 --- a/src/Sites/Sites/examples/v1.0-beta/Unpublish-MgSiteListContentType.md +++ b/src/Sites/Sites/examples/v1.0-beta/Unpublish-MgSiteListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Unpublish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Unpublish-MgSiteListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopy.md b/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopy.md index 093355d11d5..294801639ce 100644 --- a/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopy.md +++ b/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopyFromContentTypeHub.md b/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopyFromContentTypeHub.md index 093355d11d5..d7a7c014bfe 100644 --- a/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopyFromContentTypeHub.md +++ b/src/Sites/Sites/examples/v1.0/Add-MgSiteContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgSiteContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Copy-MgSiteListContentTypeToDefaultContentLocation.md b/src/Sites/Sites/examples/v1.0/Copy-MgSiteListContentTypeToDefaultContentLocation.md index 093355d11d5..11427cc5b11 100644 --- a/src/Sites/Sites/examples/v1.0/Copy-MgSiteListContentTypeToDefaultContentLocation.md +++ b/src/Sites/Sites/examples/v1.0/Copy-MgSiteListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteNotebook.md b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteNotebook.md index 093355d11d5..7ef478c7320 100644 --- a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteNotebook.md +++ b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteNotebook.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteNotebook -UserId $userId -NotebookId $notebookId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenotePageToSection.md b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenotePageToSection.md index 093355d11d5..4069ed9d420 100644 --- a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenotePageToSection.md +++ b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenotePageToSection.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenotePageToSection -UserId $userId -OnenotePageId $onenotePageId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenotePageToSection Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToNotebook.md b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToNotebook.md index 093355d11d5..ea5201ecdf4 100644 --- a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToNotebook.md +++ b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToNotebook.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToNotebook -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteSectionToNotebook Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToSectionGroup.md b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToSectionGroup.md index 093355d11d5..ae69ac19bd0 100644 --- a/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToSectionGroup.md +++ b/src/Sites/Sites/examples/v1.0/Copy-MgSiteOnenoteSectionToSectionGroup.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Id = "id-value" + GroupId = "groupId-value" + RenameAs = "renameAs-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserOnenoteSectionToSectionGroup -UserId $userId -OnenoteSectionId $onenoteSectionId -BodyParameter $params +``` +This example shows how to use the Copy-MgSiteOnenoteSectionToSectionGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Get-MgSiteOnenoteNotebookFromWebUrl.md b/src/Sites/Sites/examples/v1.0/Get-MgSiteOnenoteNotebookFromWebUrl.md index 093355d11d5..1a2e157a705 100644 --- a/src/Sites/Sites/examples/v1.0/Get-MgSiteOnenoteNotebookFromWebUrl.md +++ b/src/Sites/Sites/examples/v1.0/Get-MgSiteOnenoteNotebookFromWebUrl.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + WebUrl = "webUrl value" +} +# A UPN can also be used as -UserId. +Get-MgUserOnenoteNotebookFromWebUrl -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgSiteOnenoteNotebookFromWebUrl Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Grant-MgSitePermission.md b/src/Sites/Sites/examples/v1.0/Grant-MgSitePermission.md index 093355d11d5..ee2c0011b36 100644 --- a/src/Sites/Sites/examples/v1.0/Grant-MgSitePermission.md +++ b/src/Sites/Sites/examples/v1.0/Grant-MgSitePermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgSitePermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Publish-MgSiteListContentType.md b/src/Sites/Sites/examples/v1.0/Publish-MgSiteListContentType.md index 093355d11d5..9a52a137e47 100644 --- a/src/Sites/Sites/examples/v1.0/Publish-MgSiteListContentType.md +++ b/src/Sites/Sites/examples/v1.0/Publish-MgSiteListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Publish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Publish-MgSiteListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Sites/Sites/examples/v1.0/Unpublish-MgSiteListContentType.md b/src/Sites/Sites/examples/v1.0/Unpublish-MgSiteListContentType.md index 093355d11d5..7fd53c8bcdf 100644 --- a/src/Sites/Sites/examples/v1.0/Unpublish-MgSiteListContentType.md +++ b/src/Sites/Sites/examples/v1.0/Unpublish-MgSiteListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Unpublish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Unpublish-MgSiteListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/Add-MgChatMember.md b/src/Teams/Teams/examples/v1.0-beta/Add-MgChatMember.md index 093355d11d5..f01f11743c4 100644 --- a/src/Teams/Teams/examples/v1.0-beta/Add-MgChatMember.md +++ b/src/Teams/Teams/examples/v1.0-beta/Add-MgChatMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamChannelMember.md b/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamChannelMember.md index 093355d11d5..be431fb184e 100644 --- a/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamChannelMember.md +++ b/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamChannelMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamPrimaryChannelMember.md b/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamPrimaryChannelMember.md index 093355d11d5..5f8c199978a 100644 --- a/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamPrimaryChannelMember.md +++ b/src/Teams/Teams/examples/v1.0-beta/Add-MgTeamPrimaryChannelMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/Complete-MgTeamPrimaryChannelMigration.md b/src/Teams/Teams/examples/v1.0-beta/Complete-MgTeamPrimaryChannelMigration.md index 093355d11d5..7174462bea4 100644 --- a/src/Teams/Teams/examples/v1.0-beta/Complete-MgTeamPrimaryChannelMigration.md +++ b/src/Teams/Teams/examples/v1.0-beta/Complete-MgTeamPrimaryChannelMigration.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Complete-MgTeamChannelMigration -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the Complete-MgTeamPrimaryChannelMigration Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/New-MgTeamPrimaryChannelEmail.md b/src/Teams/Teams/examples/v1.0-beta/New-MgTeamPrimaryChannelEmail.md index 093355d11d5..a81956e93a4 100644 --- a/src/Teams/Teams/examples/v1.0-beta/New-MgTeamPrimaryChannelEmail.md +++ b/src/Teams/Teams/examples/v1.0-beta/New-MgTeamPrimaryChannelEmail.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +New-MgTeamChannelEmail -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the New-MgTeamPrimaryChannelEmail Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0-beta/Remove-MgTeamPrimaryChannelEmail.md b/src/Teams/Teams/examples/v1.0-beta/Remove-MgTeamPrimaryChannelEmail.md index 093355d11d5..3fcf19fafe2 100644 --- a/src/Teams/Teams/examples/v1.0-beta/Remove-MgTeamPrimaryChannelEmail.md +++ b/src/Teams/Teams/examples/v1.0-beta/Remove-MgTeamPrimaryChannelEmail.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Remove-MgTeamChannelEmail -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the Remove-MgTeamPrimaryChannelEmail Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/Add-MgChatMember.md b/src/Teams/Teams/examples/v1.0/Add-MgChatMember.md index 093355d11d5..f01f11743c4 100644 --- a/src/Teams/Teams/examples/v1.0/Add-MgChatMember.md +++ b/src/Teams/Teams/examples/v1.0/Add-MgChatMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/Add-MgTeamChannelMember.md b/src/Teams/Teams/examples/v1.0/Add-MgTeamChannelMember.md index 093355d11d5..be431fb184e 100644 --- a/src/Teams/Teams/examples/v1.0/Add-MgTeamChannelMember.md +++ b/src/Teams/Teams/examples/v1.0/Add-MgTeamChannelMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/Add-MgTeamPrimaryChannelMember.md b/src/Teams/Teams/examples/v1.0/Add-MgTeamPrimaryChannelMember.md index 093355d11d5..5f8c199978a 100644 --- a/src/Teams/Teams/examples/v1.0/Add-MgTeamPrimaryChannelMember.md +++ b/src/Teams/Teams/examples/v1.0/Add-MgTeamPrimaryChannelMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgTeamPrimaryChannelMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/Complete-MgTeamPrimaryChannelMigration.md b/src/Teams/Teams/examples/v1.0/Complete-MgTeamPrimaryChannelMigration.md index 093355d11d5..7174462bea4 100644 --- a/src/Teams/Teams/examples/v1.0/Complete-MgTeamPrimaryChannelMigration.md +++ b/src/Teams/Teams/examples/v1.0/Complete-MgTeamPrimaryChannelMigration.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Complete-MgTeamChannelMigration -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the Complete-MgTeamPrimaryChannelMigration Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/New-MgTeamPrimaryChannelEmail.md b/src/Teams/Teams/examples/v1.0/New-MgTeamPrimaryChannelEmail.md index 093355d11d5..a81956e93a4 100644 --- a/src/Teams/Teams/examples/v1.0/New-MgTeamPrimaryChannelEmail.md +++ b/src/Teams/Teams/examples/v1.0/New-MgTeamPrimaryChannelEmail.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +New-MgTeamChannelEmail -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the New-MgTeamPrimaryChannelEmail Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Teams/Teams/examples/v1.0/Remove-MgTeamPrimaryChannelEmail.md b/src/Teams/Teams/examples/v1.0/Remove-MgTeamPrimaryChannelEmail.md index 093355d11d5..3fcf19fafe2 100644 --- a/src/Teams/Teams/examples/v1.0/Remove-MgTeamPrimaryChannelEmail.md +++ b/src/Teams/Teams/examples/v1.0/Remove-MgTeamPrimaryChannelEmail.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Remove-MgTeamChannelEmail -TeamId $teamId -ChannelId $channelId +``` +This example shows how to use the Remove-MgTeamPrimaryChannelEmail Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserChatMember.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserChatMember.md index 093355d11d5..0356bd9d9d2 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserChatMember.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserChatMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopy.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopy.md index 093355d11d5..f8c4f9e0b92 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopy.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md index 093355d11d5..e7a68a5df2d 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md index 093355d11d5..3e902e8d1d2 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md index 093355d11d5..adecb5940f6 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md index 093355d11d5..445347704fc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserDriveListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolder.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolder.md index 093355d11d5..051b88ab4f5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolder.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMailFolder -UserId $userId -MailFolderId $mailFolderId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderChildFolder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolderMessage.md index 093355d11d5..84ae1584d18 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderMessage.md index 093355d11d5..dc7699eff52 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Copy-MgUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md index 093355d11d5..76f62acd4a7 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md index 093355d11d5..aeadf0b5981 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md index 093355d11d5..0a4b218b967 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md index 093355d11d5..bbc628d4fcf 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserById.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserById.md index 093355d11d5..76a8aa65ee7 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserById.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgUserById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserCalendarSchedule.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserCalendarSchedule.md index 093355d11d5..046e57d6575 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserCalendarSchedule.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Get-MgUserCalendarSchedule.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Schedules = @( + "adelev@contoso.onmicrosoft.com" + "meganb@contoso.onmicrosoft.com" + ) + StartTime = @{ + DateTime = "2019-03-15T09:00:00" + TimeZone = "Pacific Standard Time" + } + EndTime = @{ + DateTime = "2019-03-15T18:00:00" + TimeZone = "Pacific Standard Time" + } + AvailabilityViewInterval = 60 +} +# A UPN can also be used as -UserId. +Get-MgUserDefaultCalendarSchedule -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserCalendarSchedule Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveItemPermission.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveItemPermission.md index 093355d11d5..4d1fdc1f646 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveItemPermission.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveItemPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgUserDriveItemPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveRootPermission.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveRootPermission.md index 093355d11d5..3fb1b62a5c6 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveRootPermission.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Grant-MgUserDriveRootPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgUserDriveRootPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstance.md index 093355d11d5..cb86a452b48 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstance.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstanceTentatively.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstanceTentatively.md index 093355d11d5..25f934ca8de 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstanceTentatively.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgAcceptUserEventInstanceTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptUserEventInstanceTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveItem.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveItem.md index 093355d11d5..8f638a5f8cd 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveItem.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveItem.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinUserDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveRoot.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveRoot.md index 093355d11d5..27308cc618f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveRoot.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckinUserDriveRoot.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinUserDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveItem.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveItem.md index 093355d11d5..60730186efe 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveItem.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveItem.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutUserDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveRoot.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveRoot.md index 093355d11d5..a98823b5db5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveRoot.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgCheckoutUserDriveRoot.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutUserDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDeclineUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDeclineUserEventInstance.md index 093355d11d5..a234c78ff37 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDeclineUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDeclineUserEventInstance.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDismissUserEventInstanceReminder.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDismissUserEventInstanceReminder.md index 093355d11d5..df58336be21 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDismissUserEventInstanceReminder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgDismissUserEventInstanceReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissUserEventInstanceReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserEventInstance.md index 093355d11d5..3dec9ed2cd5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserEventInstance.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderChildFolderMessage.md index 093355d11d5..35563597482 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderChildFolderMessage.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderMessage.md index 093355d11d5..1ddbae7dcfc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgForwardUserMailFolderMessage.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md index 093355d11d5..85095ef3084 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyAllUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyAllUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderMessage.md index 093355d11d5..ab86853170f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyAllUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyAllUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyAllUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderChildFolderMessage.md index 093355d11d5..071140060cd 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderChildFolderMessage.md @@ -1,18 +1,30 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Reply in JSON format to an existing message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Message = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "samanthab@contoso.onmicrosoft.com" + Name = "Samantha Booth" + } + } + @{ + EmailAddress = @{ + Address = "randiw@contoso.onmicrosoft.com" + Name = "Randi Welch" + } + } + ) + } + Comment = "Samantha, Randi, would you name the group please?" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderMessage.md index 093355d11d5..52098f52e1c 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgReplyUserMailFolderMessage.md @@ -1,18 +1,30 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Reply in JSON format to an existing message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Message = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "samanthab@contoso.onmicrosoft.com" + Name = "Samantha Booth" + } + } + @{ + EmailAddress = @{ + Address = "randiw@contoso.onmicrosoft.com" + Name = "Randi Welch" + } + } + ) + } + Comment = "Samantha, Randi, would you name the group please?" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgSnoozeUserEventInstanceReminder.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgSnoozeUserEventInstanceReminder.md index 093355d11d5..81763cdfc02 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgSnoozeUserEventInstanceReminder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Invoke-MgSnoozeUserEventInstanceReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeUserEventInstanceReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolder.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolder.md index 093355d11d5..370c9176d9e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolder.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Move-MgUserMailFolder -UserId $userId -MailFolderId $mailFolderId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderChildFolder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolderMessage.md index 093355d11d5..8fe114b45bb 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "deleteditems" +} +# A UPN can also be used as -UserId. +Move-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderMessage.md index 093355d11d5..95da4d63458 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Move-MgUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "deleteditems" +} +# A UPN can also be used as -UserId. +Move-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventAttachmentUploadSession.md index 093355d11d5..fa387e60be3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventInstanceAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventInstanceAttachmentUploadSession.md index 093355d11d5..8924d1609a3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventInstanceAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserEventInstanceAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventInstanceAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventInstanceAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md index 093355d11d5..5389e66879f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageForward.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageForward.md index 093355d11d5..f18d8d15fab 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageForward.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageForward.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageForward -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageForward Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReply.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReply.md index 093355d11d5..cb4b65893fc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReply.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReply.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReply -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageReply Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReplyAll.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReplyAll.md index 093355d11d5..758cb737c61 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReplyAll.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderChildFolderMessageReplyAll.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReplyAll -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageReplyAll Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageAttachmentUploadSession.md index 093355d11d5..96fea451bfb 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageForward.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageForward.md index 093355d11d5..5b54feb3733 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageForward.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageForward.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageForward -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageForward Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReply.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReply.md index 093355d11d5..b5e01819a5c 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReply.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReply.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReply -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageReply Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReplyAll.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReplyAll.md index 093355d11d5..da05634057f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReplyAll.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/New-MgUserMailFolderMessageReplyAll.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReplyAll -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageReplyAll Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Publish-MgUserDriveListContentType.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Publish-MgUserDriveListContentType.md index 093355d11d5..8fd52d70b60 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Publish-MgUserDriveListContentType.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Publish-MgUserDriveListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Publish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Publish-MgUserDriveListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemDocumentSetVersion.md index 093355d11d5..80ddf586691 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveItemListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemVersion.md index 093355d11d5..be8a6f9250e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveItemListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemVersion.md index 093355d11d5..eac675e665e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Restore-MgDriveItemVersion -DriveId $driveId -DriveItemId $driveItemId -DriveItemVersionId $driveItemVersionId +``` +This example shows how to use the Restore-MgUserDriveItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemDocumentSetVersion.md index 093355d11d5..f9642a3a347 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemVersion.md index 093355d11d5..0eef97795b3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemDocumentSetVersion.md index 093355d11d5..9d6fbba489a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveRootListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemVersion.md index 093355d11d5..95457d40c66 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveRootListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootVersion.md index 093355d11d5..0c25ae4e992 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Restore-MgUserDriveRootVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Restore-MgDriveItemVersion -DriveId $driveId -DriveItemId $driveItemId -DriveItemVersionId $driveItemVersionId +``` +This example shows how to use the Restore-MgUserDriveRootVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserChatActivityNotification.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserChatActivityNotification.md index 093355d11d5..01706ed6638 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserChatActivityNotification.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserChatActivityNotification.md @@ -1,18 +1,121 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Notify a user about a task created in a chat -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}" + } + ActivityType = "taskCreated" + PreviewText = @{ + Content = "New Task Created" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "taskId" + Value = "Task 12322" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Notify a user about an approval needed in a chat message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}/messages/{messageId}" + } + ActivityType = "approvalRequired" + PreviewText = @{ + Content = "Deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "approvalTaskId" + Value = "2020AAGGTAPP" + } + ) +} +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Notify a user about an approval needed in a chat message using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}/messages/{messageId}" + } + ActivityType = "approvalRequired" + PreviewText = @{ + Content = "Deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "jacob@contoso.com" + } + TemplateParameters = @( + @{ + Name = "approvalTaskId" + Value = "2020AAGGTAPP" + } + ) +} + +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 4: Notify a user about an event in relation to a chat + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Topic = @{ + Source = "text" + Value = "Deployment Approvals Channel" + WebUrl = "https://teams.microsoft.com/l/message/19:448cfd2ac2a7490a9084a9ed14cttr78c@thread.skype/1605223780000?tenantId=c8b1bf45-3834-4ecf-971a-b4c755ee677d&groupId=d4c2a937-f097-435a-bc91-5c1683ca7245&parentMessageId=1605223771864&teamName=Approvals&channelName=Azure%20DevOps&createdTime=1605223780000" + } + ActivityType = "deploymentApprovalRequired" + PreviewText = @{ + Content = "New deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "deploymentId" + Value = "6788662" + } + ) +} + +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderChildFolderMessage.md index 093355d11d5..c403d03f08a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Send an existing draft message -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Send-MgUserMessage -UserId $userId -MessageId $messageId +``` +This example shows how to use the Send-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderMessage.md index 093355d11d5..39ab51b6b42 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Send-MgUserMailFolderMessage.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Send an existing draft message -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Send-MgUserMessage -UserId $userId -MessageId $messageId +``` +This example shows how to use the Send-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Stop-MgUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Stop-MgUserEventInstance.md index 093355d11d5..79ec1599496 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Stop-MgUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Stop-MgUserEventInstance.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Cancelling for this week due to all hands" +} +# A UPN can also be used as -UserId. +Stop-MgUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Stop-MgUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Test-MgUserProperty.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Test-MgUserProperty.md index 093355d11d5..9736bc8d879 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Test-MgUserProperty.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Test-MgUserProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgUserProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Unpublish-MgUserDriveListContentType.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Unpublish-MgUserDriveListContentType.md index 093355d11d5..ff66e2ef2bc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Unpublish-MgUserDriveListContentType.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Unpublish-MgUserDriveListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Unpublish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Unpublish-MgUserDriveListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Update-MgUserChatInstalledApp.md b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Update-MgUserChatInstalledApp.md index 093355d11d5..122cedeb49a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0-beta/Update-MgUserChatInstalledApp.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0-beta/Update-MgUserChatInstalledApp.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Update-MgChatInstalledApp -ChatId $chatId -TeamsAppInstallationId $teamsAppInstallationId +``` +This example shows how to use the Update-MgUserChatInstalledApp Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserChatMember.md b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserChatMember.md index 093355d11d5..0356bd9d9d2 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserChatMember.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserChatMember.md @@ -1,18 +1,81 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Add members in bulk to a team -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Add members in bulk and encounter partial failure -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('18a80140-b0fb-4489-b360-2f6efaf225a0')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('86503198-b81b-43fe-81ee-ad45b8848ac9')" + } + ) +} +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Add members in bulk to a team using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Values = @( + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('jacob@contoso.com')" + } + @{ + "@odata.type" = "microsoft.graph.aadUserConversationMember" + Roles = @( + "owner" + ) + "User@odata.bind" = "https://graph.microsoft.com/v1.0/users('alex@contoso.com')" + } + ) +} + +Add-MgTeamMember -TeamId $teamId -BodyParameter $params +``` +This example shows how to use the Add-MgUserChatMember Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopy.md b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopy.md index 093355d11d5..f8c4f9e0b92 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopy.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopy.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ContentType = "https://graph.microsoft.com/v1.0/sites/{site-id}/contentTypes/0x0101" +} +Add-MgSiteListContentTypeCopy -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopy Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md index 093355d11d5..e7a68a5df2d 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Add-MgUserDriveListContentTypeCopyFromContentTypeHub.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Synchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Asynchronous pull -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} +$params = @{ + ContentTypeId = "0x0101" +} +Add-MgSiteListContentTypeCopyFromContentTypeHub -SiteId $siteId -ListId $listId -BodyParameter $params +``` +This example shows how to use the Add-MgUserDriveListContentTypeCopyFromContentTypeHub Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md index 093355d11d5..3e902e8d1d2 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md index 093355d11d5..adecb5940f6 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md @@ -1,18 +1,36 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + GroupIds = @( + "f448435d-3ca7-4073-8152-a1fd73c0fd09" + "bd7c6263-4dd5-4ae8-8c96-556e1c0bece6" + "93670da6-d731-4366-94b5-abed40b6016b" + "f5484ab1-4d4d-41ec-a9b8-754b3957bfc7" + "c9103f26-f3cf-4004-a611-2a14e81b8f79" + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Confirm-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + GroupIds = @( + "fee2c45b-915a-4a64b130f4eb9e75525e" + "4fe90ae065a-478b9400e0a0e1cbd540" + ) +} +# A UPN can also be used as -UserId. +Confirm-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Confirm-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md index 093355d11d5..445347704fc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserDriveListContentTypeToDefaultContentLocation.md @@ -1,18 +1,19 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Sites -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SourceFile = @{ + SharepointIds = @{ + ListId = "e2ecf63b-b0fd-48f7-a54a-d8c15479e3b0" + ListItemId = "2" + } + } + DestinationFileName = "newname.txt" +} +Copy-MgSiteContentTypeToDefaultContentLocation -SiteId $siteId -ContentTypeId $contentTypeId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserDriveListContentTypeToDefaultContentLocation Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolder.md b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolder.md index 093355d11d5..051b88ab4f5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolder.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMailFolder -UserId $userId -MailFolderId $mailFolderId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderChildFolder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolderMessage.md index 093355d11d5..84ae1584d18 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderMessage.md index 093355d11d5..dc7699eff52 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Copy-MgUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Copy-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Copy-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md index 093355d11d5..76f62acd4a7 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md index 093355d11d5..aeadf0b5981 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationMicrosoftAuthenticatorMethodDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md index 093355d11d5..0a4b218b967 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup.md @@ -1,18 +1,27 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Check group memberships for a directory object -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $false +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Get-MgDirectoryObjectMemberGroup -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Check group memberships for the signed-in user -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +# A UPN can also be used as -UserId. +Get-MgUserMemberGroup -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberGroup Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md index 093355d11d5..bbc628d4fcf 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserAuthenticationWindowHelloForBusinessMethodDeviceMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserById.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserById.md index 093355d11d5..76a8aa65ee7 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserById.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserById.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Ids = @( + "84b80893-8749-40a3-97b7-68513b600544" + "5d6059b6-368d-45f8-91e1-8e07d485f1d0" + "0b944de3-e0fc-4774-a49a-b135213725ef" + "b75a5ab2-fe55-4463-bd31-d21ad555c6e0" + ) + Types = @( + "user" + "group" + "device" + ) +} +Get-MgDirectoryObjectById -BodyParameter $params +``` +This example shows how to use the Get-MgUserById Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserCalendarSchedule.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserCalendarSchedule.md index 093355d11d5..046e57d6575 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserCalendarSchedule.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserCalendarSchedule.md @@ -1,18 +1,26 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Schedules = @( + "adelev@contoso.onmicrosoft.com" + "meganb@contoso.onmicrosoft.com" + ) + StartTime = @{ + DateTime = "2019-03-15T09:00:00" + TimeZone = "Pacific Standard Time" + } + EndTime = @{ + DateTime = "2019-03-15T18:00:00" + TimeZone = "Pacific Standard Time" + } + AvailabilityViewInterval = 60 +} +# A UPN can also be used as -UserId. +Get-MgUserDefaultCalendarSchedule -UserId $userId -BodyParameter $params +``` +This example shows how to use the Get-MgUserCalendarSchedule Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserMemberObject.md b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserMemberObject.md index 093355d11d5..f6036bc7644 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserMemberObject.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Get-MgUserMemberObject.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + SecurityEnabledOnly = $true +} +Get-MgDirectoryObjectMemberObject -DirectoryObjectId $directoryObjectId -BodyParameter $params +``` +This example shows how to use the Get-MgUserMemberObject Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveItemPermission.md b/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveItemPermission.md index 093355d11d5..4d1fdc1f646 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveItemPermission.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveItemPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgUserDriveItemPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveRootPermission.md b/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveRootPermission.md index 093355d11d5..3fb1b62a5c6 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveRootPermission.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Grant-MgUserDriveRootPermission.md @@ -1,18 +1,23 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Recipients = @( + @{ + Email = "john@contoso.com" + } + @{ + Email = "ryan@external.com" + } + ) + Roles = @( + "read" + ) +} +Grant-MgSharePermission -SharedDriveItemId $sharedDriveItemId -BodyParameter $params +``` +This example shows how to use the Grant-MgUserDriveRootPermission Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstance.md index 093355d11d5..cb86a452b48 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstance.md @@ -1,18 +1,15 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + SendResponse = $true +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstanceTentatively.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstanceTentatively.md index 093355d11d5..25f934ca8de 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstanceTentatively.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgAcceptUserEventInstanceTentatively.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I may not be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgAcceptUserEventTentatively -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgAcceptUserEventInstanceTentatively Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveItem.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveItem.md index 093355d11d5..8f638a5f8cd 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveItem.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveItem.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinUserDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveRoot.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveRoot.md index 093355d11d5..27308cc618f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveRoot.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckinUserDriveRoot.md @@ -1,18 +1,13 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Files -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Updating the latest guidelines" +} +Invoke-MgCheckinDriveItem -DriveId $driveId -DriveItemId $driveItemId -BodyParameter $params +``` +This example shows how to use the Invoke-MgCheckinUserDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveItem.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveItem.md index 093355d11d5..60730186efe 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveItem.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveItem.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutUserDriveItem Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveRoot.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveRoot.md index 093355d11d5..a98823b5db5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveRoot.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgCheckoutUserDriveRoot.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Invoke-MgCheckoutDriveItem -DriveId $driveId -DriveItemId $driveItemId +``` +This example shows how to use the Invoke-MgCheckoutUserDriveRoot Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDeclineUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDeclineUserEventInstance.md index 093355d11d5..a234c78ff37 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDeclineUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDeclineUserEventInstance.md @@ -1,18 +1,25 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "I won't be able to make this week. How about next week?" + SendResponse = $true + ProposedNewTime = @{ + Start = @{ + DateTime = "2019-12-02T18:00:00" + TimeZone = "Pacific Standard Time" + } + End = @{ + DateTime = "2019-12-02T19:00:00" + TimeZone = "Pacific Standard Time" + } + } +} +# A UPN can also be used as -UserId. +Invoke-MgDeclineUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgDeclineUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDismissUserEventInstanceReminder.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDismissUserEventInstanceReminder.md index 093355d11d5..df58336be21 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDismissUserEventInstanceReminder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgDismissUserEventInstanceReminder.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Invoke-MgDismissUserEventReminder -UserId $userId -EventId $eventId +``` +This example shows how to use the Invoke-MgDismissUserEventInstanceReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserEventInstance.md index 093355d11d5..3dec9ed2cd5 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserEventInstance.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "danas@contoso.onmicrosoft.com" + Name = "Dana Swope" + } + } + ) + Comment = "Dana, hope you can make this meeting." +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderChildFolderMessage.md index 093355d11d5..35563597482 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderChildFolderMessage.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderMessage.md index 093355d11d5..1ddbae7dcfc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgForwardUserMailFolderMessage.md @@ -1,18 +1,22 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" + ToRecipients = @( + @{ + EmailAddress = @{ + Name = "name-value" + Address = "address-value" + } + } + ) +} +# A UPN can also be used as -UserId. +Invoke-MgForwardUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgForwardUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md index 093355d11d5..85095ef3084 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyAllUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyAllUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderMessage.md index 093355d11d5..ab86853170f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyAllUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "comment-value" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyAllUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyAllUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderChildFolderMessage.md index 093355d11d5..071140060cd 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderChildFolderMessage.md @@ -1,18 +1,30 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Reply in JSON format to an existing message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Message = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "samanthab@contoso.onmicrosoft.com" + Name = "Samantha Booth" + } + } + @{ + EmailAddress = @{ + Address = "randiw@contoso.onmicrosoft.com" + Name = "Randi Welch" + } + } + ) + } + Comment = "Samantha, Randi, would you name the group please?" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderMessage.md index 093355d11d5..52098f52e1c 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgReplyUserMailFolderMessage.md @@ -1,18 +1,30 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Reply in JSON format to an existing message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Message = @{ + ToRecipients = @( + @{ + EmailAddress = @{ + Address = "samanthab@contoso.onmicrosoft.com" + Name = "Samantha Booth" + } + } + @{ + EmailAddress = @{ + Address = "randiw@contoso.onmicrosoft.com" + Name = "Randi Welch" + } + } + ) + } + Comment = "Samantha, Randi, would you name the group please?" +} +# A UPN can also be used as -UserId. +Invoke-MgReplyUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Invoke-MgReplyUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgSnoozeUserEventInstanceReminder.md b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgSnoozeUserEventInstanceReminder.md index 093355d11d5..81763cdfc02 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgSnoozeUserEventInstanceReminder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Invoke-MgSnoozeUserEventInstanceReminder.md @@ -1,18 +1,17 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + NewReminderTime = @{ + DateTime = "dateTime-value" + TimeZone = "timeZone-value" + } +} +# A UPN can also be used as -UserId. +Invoke-MgSnoozeUserEventReminder -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Invoke-MgSnoozeUserEventInstanceReminder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolder.md b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolder.md index 093355d11d5..370c9176d9e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolder.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolder.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "destinationId-value" +} +# A UPN can also be used as -UserId. +Move-MgUserMailFolder -UserId $userId -MailFolderId $mailFolderId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderChildFolder Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolderMessage.md index 093355d11d5..8fe114b45bb 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "deleteditems" +} +# A UPN can also be used as -UserId. +Move-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderMessage.md index 093355d11d5..95da4d63458 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Move-MgUserMailFolderMessage.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + DestinationId = "deleteditems" +} +# A UPN can also be used as -UserId. +Move-MgUserMessage -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the Move-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventAttachmentUploadSession.md index 093355d11d5..fa387e60be3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventInstanceAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventInstanceAttachmentUploadSession.md index 093355d11d5..8924d1609a3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventInstanceAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserEventInstanceAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventInstanceAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserEventInstanceAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md index 093355d11d5..5389e66879f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageForward.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageForward.md index 093355d11d5..f18d8d15fab 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageForward.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageForward.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageForward -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageForward Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReply.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReply.md index 093355d11d5..cb4b65893fc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReply.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReply.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReply -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageReply Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReplyAll.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReplyAll.md index 093355d11d5..758cb737c61 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReplyAll.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderChildFolderMessageReplyAll.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReplyAll -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderChildFolderMessageReplyAll Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageAttachmentUploadSession.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageAttachmentUploadSession.md index 093355d11d5..96fea451bfb 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageAttachmentUploadSession.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageAttachmentUploadSession.md @@ -1,18 +1,38 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Create an upload session to add a large attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "flower" + Size = 3483322 + } +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Create an upload session to add a large in-line attachment to a draft message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} +$params = @{ + AttachmentItem = @{ + AttachmentType = "file" + Name = "scenary" + Size = 7208534 + IsInline = $true + ContentId = "my_inline_picture" + } +} +# A UPN can also be used as -UserId. +New-MgUserMessageAttachmentUploadSession -UserId $userId -MessageId $messageId -BodyParameter $params +``` +This example shows how to use the New-MgUserMailFolderMessageAttachmentUploadSession Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageForward.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageForward.md index 093355d11d5..5b54feb3733 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageForward.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageForward.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageForward -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageForward Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReply.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReply.md index 093355d11d5..b5e01819a5c 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReply.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReply.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReply -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageReply Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReplyAll.md b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReplyAll.md index 093355d11d5..da05634057f 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReplyAll.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/New-MgUserMailFolderMessageReplyAll.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +New-MgUserMessageReplyAll -UserId $userId -MessageId $messageId +``` +This example shows how to use the New-MgUserMailFolderMessageReplyAll Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Publish-MgUserDriveListContentType.md b/src/Users.Actions/Users.Actions/examples/v1.0/Publish-MgUserDriveListContentType.md index 093355d11d5..8fd52d70b60 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Publish-MgUserDriveListContentType.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Publish-MgUserDriveListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Publish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Publish-MgUserDriveListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemDocumentSetVersion.md index 093355d11d5..80ddf586691 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveItemListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemVersion.md index 093355d11d5..be8a6f9250e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveItemListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemVersion.md index 093355d11d5..eac675e665e 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Restore-MgDriveItemVersion -DriveId $driveId -DriveItemId $driveItemId -DriveItemVersionId $driveItemVersionId +``` +This example shows how to use the Restore-MgUserDriveItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemDocumentSetVersion.md index 093355d11d5..f9642a3a347 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemVersion.md index 093355d11d5..0eef97795b3 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemDocumentSetVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemDocumentSetVersion.md index 093355d11d5..9d6fbba489a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemDocumentSetVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemDocumentSetVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemDocumentSetVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -DocumentSetVersionId $documentSetVersionId +``` +This example shows how to use the Restore-MgUserDriveRootListItemDocumentSetVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemVersion.md index 093355d11d5..95457d40c66 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootListItemVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Restore-MgSiteListItemVersion -SiteId $siteId -ListId $listId -ListItemId $listItemId -ListItemVersionId $listItemVersionId +``` +This example shows how to use the Restore-MgUserDriveRootListItemVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootVersion.md b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootVersion.md index 093355d11d5..0c25ae4e992 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootVersion.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Restore-MgUserDriveRootVersion.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Files +Restore-MgDriveItemVersion -DriveId $driveId -DriveItemId $driveItemId -DriveItemVersionId $driveItemVersionId +``` +This example shows how to use the Restore-MgUserDriveRootVersion Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserChatActivityNotification.md b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserChatActivityNotification.md index 093355d11d5..01706ed6638 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserChatActivityNotification.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserChatActivityNotification.md @@ -1,18 +1,121 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Notify a user about a task created in a chat -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}" + } + ActivityType = "taskCreated" + PreviewText = @{ + Content = "New Task Created" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "taskId" + Value = "Task 12322" + } + ) +} -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 2: Notify a user about an approval needed in a chat message -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Teams -{{ Add description here }} +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}/messages/{messageId}" + } + ActivityType = "approvalRequired" + PreviewText = @{ + Content = "Deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "approvalTaskId" + Value = "2020AAGGTAPP" + } + ) +} +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 3: Notify a user about an approval needed in a chat message using user principal name + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Topic = @{ + Source = "entityUrl" + Value = "https://graph.microsoft.com/v1.0/chats/{chatId}/messages/{messageId}" + } + ActivityType = "approvalRequired" + PreviewText = @{ + Content = "Deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "jacob@contoso.com" + } + TemplateParameters = @( + @{ + Name = "approvalTaskId" + Value = "2020AAGGTAPP" + } + ) +} + +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + +### Example 4: Notify a user about an event in relation to a chat + +```powershell Import-Module Microsoft.Graph.Teams + +$params = @{ + Topic = @{ + Source = "text" + Value = "Deployment Approvals Channel" + WebUrl = "https://teams.microsoft.com/l/message/19:448cfd2ac2a7490a9084a9ed14cttr78c@thread.skype/1605223780000?tenantId=c8b1bf45-3834-4ecf-971a-b4c755ee677d&groupId=d4c2a937-f097-435a-bc91-5c1683ca7245&parentMessageId=1605223771864&teamName=Approvals&channelName=Azure%20DevOps&createdTime=1605223780000" + } + ActivityType = "deploymentApprovalRequired" + PreviewText = @{ + Content = "New deployment requires your approval" + } + Recipient = @{ + "@odata.type" = "microsoft.graph.aadUserNotificationRecipient" + UserId = "569363e2-4e49-4661-87f2-16f245c5d66a" + } + TemplateParameters = @( + @{ + Name = "deploymentId" + Value = "6788662" + } + ) +} + +Send-MgChatActivityNotification -ChatId $chatId -BodyParameter $params +``` +This example shows how to use the Send-MgUserChatActivityNotification Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderChildFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderChildFolderMessage.md index 093355d11d5..c403d03f08a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderChildFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderChildFolderMessage.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Send an existing draft message -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Send-MgUserMessage -UserId $userId -MessageId $messageId +``` +This example shows how to use the Send-MgUserMailFolderChildFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderMessage.md b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderMessage.md index 093355d11d5..39ab51b6b42 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderMessage.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Send-MgUserMailFolderMessage.md @@ -1,18 +1,10 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Send an existing draft message -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Users.Actions +# A UPN can also be used as -UserId. +Send-MgUserMessage -UserId $userId -MessageId $messageId +``` +This example shows how to use the Send-MgUserMailFolderMessage Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Stop-MgUserEventInstance.md b/src/Users.Actions/Users.Actions/examples/v1.0/Stop-MgUserEventInstance.md index 093355d11d5..79ec1599496 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Stop-MgUserEventInstance.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Stop-MgUserEventInstance.md @@ -1,18 +1,14 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.Users.Actions -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + Comment = "Cancelling for this week due to all hands" +} +# A UPN can also be used as -UserId. +Stop-MgUserEvent -UserId $userId -EventId $eventId -BodyParameter $params +``` +This example shows how to use the Stop-MgUserEventInstance Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Test-MgUserProperty.md b/src/Users.Actions/Users.Actions/examples/v1.0/Test-MgUserProperty.md index 093355d11d5..9736bc8d879 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Test-MgUserProperty.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Test-MgUserProperty.md @@ -1,18 +1,16 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` +```powershell Import-Module Microsoft.Graph.DirectoryObjects -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +$params = @{ + EntityType = "Group" + DisplayName = "Myprefix_test_mysuffix" + MailNickname = "Myprefix_test_mysuffix" + OnBehalfOfUserId = "onBehalfOfUserId-value" +} +Test-MgDirectoryObjectProperty -BodyParameter $params +``` +This example shows how to use the Test-MgUserProperty Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Unpublish-MgUserDriveListContentType.md b/src/Users.Actions/Users.Actions/examples/v1.0/Unpublish-MgUserDriveListContentType.md index 093355d11d5..ff66e2ef2bc 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Unpublish-MgUserDriveListContentType.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Unpublish-MgUserDriveListContentType.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Sites +Unpublish-MgSiteContentType -SiteId $siteId -ContentTypeId $contentTypeId +``` +This example shows how to use the Unpublish-MgUserDriveListContentType Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). + diff --git a/src/Users.Actions/Users.Actions/examples/v1.0/Update-MgUserChatInstalledApp.md b/src/Users.Actions/Users.Actions/examples/v1.0/Update-MgUserChatInstalledApp.md index 093355d11d5..122cedeb49a 100644 --- a/src/Users.Actions/Users.Actions/examples/v1.0/Update-MgUserChatInstalledApp.md +++ b/src/Users.Actions/Users.Actions/examples/v1.0/Update-MgUserChatInstalledApp.md @@ -1,18 +1,9 @@ -### Example 1: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} +### Example 1: Code snippet -{{ Add output here }} -``` - -{{ Add description here }} - -### Example 2: {{ Add title here }} -```powershell -PS C:\> {{ Add code here }} - -{{ Add output here }} -``` - -{{ Add description here }} +```powershell Import-Module Microsoft.Graph.Teams +Update-MgChatInstalledApp -ChatId $chatId -TeamsAppInstallationId $teamsAppInstallationId +``` +This example shows how to use the Update-MgUserChatInstalledApp Cmdlet. + To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference). +