Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
### Example 1: Using the Get-MgApplicationTemplate Cmdlet
```powershell
Import-Module Microsoft.Graph.Applications
Get-MgApplicationTemplate -ApplicationTemplateId $applicationTemplateId
```
This example shows how to use the Get-MgApplicationTemplate Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 2: Using the Get-MgApplicationTemplate Cmdlet
```powershell
Import-Module Microsoft.Graph.Applications
Get-MgApplicationTemplate
```
This example shows how to use the Get-MgApplicationTemplate Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Applications

Get-MgApplicationTemplate -ApplicationTemplateId $applicationTemplateId
```
This example shows how to use the Get-MgApplicationTemplate Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
### Example 1: Using the Remove-MgServicePrincipal Cmdlet
```powershell
Import-Module Microsoft.Graph.Applications
Remove-MgServicePrincipal -ServicePrincipalId $servicePrincipalId
```
This example shows how to use the Remove-MgServicePrincipal Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Applications

Remove-MgServicePrincipal -ServicePrincipalId $servicePrincipalId
```
This example shows how to use the Remove-MgServicePrincipal Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
53 changes: 15 additions & 38 deletions src/Calendar/Calendar/examples/v1.0/Update-MgPlace.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,18 @@
### Example 1: Using the Update-MgPlace Cmdlet
```powershell
Import-Module Microsoft.Graph.Calendar
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Calendar

$params = @{
"@odata.type" = "microsoft.graph.room"
Nickname = "Conf Room"
Building = "1"
Label = "100"
Capacity =
IsWheelChairAccessible = $false
nickname = "Conf Room"
building = "1"
label = "100"
capacity =
isWheelChairAccessible = $false
}
Update-MgPlace -PlaceId $placeId -BodyParameter $params
```
This example shows how to use the Update-MgPlace Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 2: Using the Update-MgPlace Cmdlet
```powershell
Import-Module Microsoft.Graph.Calendar
$params = @{
"@odata.type" = "microsoft.graph.roomList"
DisplayName = "Building 1"
Phone = "555-555-0100"
Address = @{
Street = "4567 Main Street"
City = "Buffalo"
State = "NY"
PostalCode = "98052"
CountryOrRegion = "USA"
}
GeoCoordinates = @{
Altitude = $null
Latitude = 47
Longitude = -122
Accuracy = $null
AltitudeAccuracy = $null
}
}
Update-MgPlace -PlaceId $placeId -BodyParameter $params
```
This example shows how to use the Update-MgPlace Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Update-MgPlace -PlaceId $placeId -BodyParameter $params
```
This example shows how to use the Update-MgPlace Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
### Example 1: Using the Get-MgSubscription Cmdlet
```powershell
Import-Module Microsoft.Graph.ChangeNotifications
Get-MgSubscription -SubscriptionId $subscriptionId
```
This example shows how to use the Get-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 2: Using the Get-MgSubscription Cmdlet
```powershell
Import-Module Microsoft.Graph.ChangeNotifications
Get-MgSubscription
```
This example shows how to use the Get-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.ChangeNotifications

Get-MgSubscription -SubscriptionId $subscriptionId
```
This example shows how to use the Get-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
### Example 1: Using the New-MgSubscription Cmdlet
```powershell
Import-Module Microsoft.Graph.ChangeNotifications
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.ChangeNotifications

$params = @{
ChangeType = "created"
NotificationUrl = "https://webhook.azurewebsites.net/api/send/myNotifyClient"
Resource = "me/mailFolders('Inbox')/messages"
ExpirationDateTime = [System.DateTime]::Parse("2016-11-20T18:23:45.9356913Z")
ClientState = "secretClientValue"
LatestSupportedTlsVersion = "v1_2"
changeType = "created"
notificationUrl = "https://webhook.azurewebsites.net/api/send/myNotifyClient"
resource = "me/mailFolders('Inbox')/messages"
expirationDateTime = [System.DateTime]::Parse("2016-11-20T18:23:45.9356913Z")
clientState = "secretClientValue"
latestSupportedTlsVersion = "v1_2"
}
New-MgSubscription -BodyParameter $params
```
This example shows how to use the New-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

New-MgSubscription -BodyParameter $params
```
This example shows how to use the New-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
### Example 1: Using the Remove-MgSubscription Cmdlet
```powershell
Import-Module Microsoft.Graph.ChangeNotifications
Remove-MgSubscription -SubscriptionId $subscriptionId
```
This example shows how to use the Remove-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.ChangeNotifications

Remove-MgSubscription -SubscriptionId $subscriptionId
```
This example shows how to use the Remove-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
### Example 1: Using the Update-MgSubscription Cmdlet
```powershell
Import-Module Microsoft.Graph.ChangeNotifications
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.ChangeNotifications

$params = @{
ExpirationDateTime = [System.DateTime]::Parse("2016-11-22T18:23:45.9356913Z")
expirationDateTime = [System.DateTime]::Parse("2016-11-22T18:23:45.9356913Z")
}
Update-MgSubscription -SubscriptionId $subscriptionId -BodyParameter $params
```
This example shows how to use the Update-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Update-MgSubscription -SubscriptionId $subscriptionId -BodyParameter $params
```
This example shows how to use the Update-MgSubscription Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
### Example 1: Using the Get-MgDirectoryObject Cmdlet
```powershell
Import-Module Microsoft.Graph.DirectoryObjects
Get-MgDirectoryObject -DirectoryObjectId $directoryObjectId
```
This example shows how to use the Get-MgDirectoryObject Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.DirectoryObjects

Get-MgDirectoryObject -DirectoryObjectId $directoryObjectId
```
This example shows how to use the Get-MgDirectoryObject Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
### Example 1: Using the Remove-MgDirectoryObject Cmdlet
```powershell
Import-Module Microsoft.Graph.DirectoryObjects
Remove-MgDirectoryObject -DirectoryObjectId $directoryObjectId
```
This example shows how to use the Remove-MgDirectoryObject Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.DirectoryObjects

Remove-MgDirectoryObject -DirectoryObjectId $directoryObjectId
```
This example shows how to use the Remove-MgDirectoryObject Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
### Example 1: Using the Get-MgShareSharedDriveItemSharedDriveItem Cmdlet
### Example 1: Code snippet

```powershell
Import-Module Microsoft.Graph.Files

Get-MgShareSharedDriveItemSharedDriveItem -SharedDriveItemId $sharedDriveItemId
```
This example shows how to use the Get-MgShareSharedDriveItemSharedDriveItem Cmdlet.

To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

23 changes: 9 additions & 14 deletions src/Groups/Groups/examples/v1.0/Get-MgGroupLifecyclePolicy.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
### Example 1: Using the Get-MgGroupLifecyclePolicy Cmdlet
```powershell
Import-Module Microsoft.Graph.Groups
Get-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId
```
This example shows how to use the Get-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 2: Using the Get-MgGroupLifecyclePolicy Cmdlet
```powershell
Import-Module Microsoft.Graph.Groups
Get-MgGroupLifecyclePolicy
```
This example shows how to use the Get-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Groups

Get-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId
```
This example shows how to use the Get-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -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 }}
```powershellImport-Module Microsoft.Graph.Groups

Get-MgGroupSettingTemplateGroupSettingTemplateGroupSettingTemplate -GroupSettingTemplateId $groupSettingTemplateId
```
This example shows how to use the Get-MgGroupSettingTemplateGroupSettingTemplateGroupSettingTemplate Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
23 changes: 13 additions & 10 deletions src/Groups/Groups/examples/v1.0/New-MgGroupLifecyclePolicy.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
### Example 1: Using the New-MgGroupLifecyclePolicy Cmdlet
```powershell
Import-Module Microsoft.Graph.Groups
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Groups

$params = @{
GroupLifetimeInDays = 100
ManagedGroupTypes = "Selected"
AlternateNotificationEmails = "admin@contoso.com"
groupLifetimeInDays = 100
managedGroupTypes = "Selected"
alternateNotificationEmails = "admin@contoso.com"
}
New-MgGroupLifecyclePolicy -BodyParameter $params
```
This example shows how to use the New-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

New-MgGroupLifecyclePolicy -BodyParameter $params
```
This example shows how to use the New-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
### Example 1: Using the Remove-MgGroupLifecyclePolicy Cmdlet
```powershell
Import-Module Microsoft.Graph.Groups
Remove-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId
```
This example shows how to use the Remove-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Groups

Remove-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId
```
This example shows how to use the Remove-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
23 changes: 13 additions & 10 deletions src/Groups/Groups/examples/v1.0/Update-MgGroupLifecyclePolicy.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
### Example 1: Using the Update-MgGroupLifecyclePolicy Cmdlet
```powershell
Import-Module Microsoft.Graph.Groups
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Groups

$params = @{
GroupLifetimeInDays = 180
ManagedGroupTypes = "Selected"
AlternateNotificationEmails = "admin@contoso.com"
groupLifetimeInDays = 180
managedGroupTypes = "Selected"
alternateNotificationEmails = "admin@contoso.com"
}
Update-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId -BodyParameter $params
```
This example shows how to use the Update-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Update-MgGroupLifecyclePolicy -GroupLifecyclePolicyId $groupLifecyclePolicyId -BodyParameter $params
```
This example shows how to use the Update-MgGroupLifecyclePolicy Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
### Example 1: Using the Get-MgContract Cmdlet
```powershell
Import-Module Microsoft.Graph.Identity.DirectoryManagement
Get-MgContract -ContractId $contractId
```
This example shows how to use the Get-MgContract Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 2: Using the Get-MgContract Cmdlet
```powershell
Import-Module Microsoft.Graph.Identity.DirectoryManagement
Get-MgContract
```
This example shows how to use the Get-MgContract Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).
### Example 1: Code snippet

```powershellImport-Module Microsoft.Graph.Identity.DirectoryManagement

Get-MgContract -ContractId $contractId
```
This example shows how to use the Get-MgContract Cmdlet.
To learn about permissions for this resource, see the [permissions reference](/graph/permissions-reference).

Expand Down
Loading