MSGraphStuff

1.1.3

Microsoft Graph API related functions. Some of them are explained at https://doitpshway.com/.

Some of the functions:
- Expand-MgAdditionalProperties - Function for expanding "AdditionalProperties" hash property to the main object aka flattens the returned object
- Get-CodeGraphModuleDependency - Function for getting Graph SDK modules required to run given code
-
Microsoft Graph API related functions. Some of them are explained at https://doitpshway.com/.

Some of the functions:
- Expand-MgAdditionalProperties - Function for expanding "AdditionalProperties" hash property to the main object aka flattens the returned object
- Get-CodeGraphModuleDependency - Function for getting Graph SDK modules required to run given code
- Get-CodeGraphPermissionRequirement - Function for getting Graph API permissions (scopes) that are needed tu run selected code
- Invoke-GraphAPIRequest - Function for creating request against Microsoft Graph API. Unlike official one supports paging and throttling
- Invoke-GraphBatchRequest - Function for invoking Graph Api batch request(s) that handles pagination, throttling and server-side errors
- New-GraphAPIAuthHeader - Function for generating header that can be used for authentication of Graph API requests
- New-GraphBatchRequest - Function for creating PSObject that can be used in Graph Api batching requests
- ...
Show more

Minimum PowerShell version

5.1

Installation Options

Copy and Paste the following command to install this package using PowerShellGet More Info

Install-Module -Name MSGraphStuff -RequiredVersion 1.1.3

Copy and Paste the following command to install this package using Microsoft.PowerShell.PSResourceGet More Info

Install-PSResource -Name MSGraphStuff -Version 1.1.3

You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More

Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More

Owners

Copyright

(c) 2022 @AndrewZtrhgf. All rights reserved.

Package Details

Author(s)

  • @AndrewZtrhgf

Tags

PowerShell Graph Microsoft API MSGraph MSGraphStuff

Functions

Expand-MgAdditionalProperties Get-CodeGraphModuleDependency Get-CodeGraphPermissionRequirement Get-MgGraphAllPages Invoke-GraphAPIRequest Invoke-GraphBatchRequest New-GraphAPIAuthHeader New-GraphBatchRequest

PSEditions

Core Desktop

Dependencies

Release Notes


           1.1.3
               CHANGED
                   Invoke-GraphBatchRequest - added parameter "dontAddRequestId"
               FIXED
                   Invoke-GraphBatchRequest - pipeline fixes
                   New-GraphBatchRequest - header no longer [string], other minor edits
           1.1.2
               ADDED
                   New-GraphBatchRequest
                   Invoke-GraphBatchRequest
           1.1.1
               CHANGED
                   New-GraphAPIAuthHeader - support for Az 5.x (SecureString returned by Get-AzAccessToken)

           1.1.0
               CHANGED
                   Get-CodeGraphPermissionRequirement - requires module Microsoft.Graph.Authentication (at least version 2.18.0) where output of the Find-MgGraphCommand command used for getting the permissions was significantly changed
                                                      - change in permission filtering logic, change in the returned output (error messages), ...
           1.0.11
               FIXED
                   Get-CodeGraphPermissionRequirement - ignore #requires module statements
           1.0.10
               CHANGED
                   Get-CodeGraphModuleDependency - omit type property as it is useless
           1.0.9
               ADDED
                   Get-MgGraphAllPages
               CHANGED
                   Get-CodeGraphPermissionRequirement - added Get-MgContext as command that doesnt require any privileges
                   Invoke-GraphAPIRequest - better detection of value property
           1.0.8
               FIXED
                   Get-CodeGraphModuleDependency - ignore Import-Module results, fixed DependencyPath extraction
               CHANGED
                   Get-CodeGraphPermissionRequirement - added switch allOccurrences, removed unknownDependencyAsObject parameter when searching for dependencies, because there is no real reason to return such results
           1.0.7
               CHANGED
                   Get-CodeGraphPermissionRequirement - permissions output optimized by default, to change that use dontFilterPermissions
           1.0.6
               CHANGED
                   Get-CodeGraphPermissionRequirement - new examples and checks
               ADDED
                   Get-CodeGraphModuleDependency
           1.0.5
               CHANGED
                   Get-CodeGraphPermissionRequirement - new aliases, support for both permType, added method, apiVersion to the output, added searching for graph api calls using Invoke-MsGraphRequest, Invoke-RestMethod, Invoke-WebRequest and their aliases
               FIXED
                   Get-CodeDependency - fixed skipping of modules when processJustMSGraphSDK switch is used
               

FileList

Version History

Version Downloads Last updated
1.1.4 37 6/6/2025
1.1.3 (current version) 95 6/6/2025
1.1.2 1,188 6/2/2025
1.1.1 10,464 3/19/2025
1.1.0 61,515 9/16/2024
1.0.11 16,084 6/10/2024
1.0.10 2,683 5/19/2024
1.0.9 8,294 3/11/2024
1.0.8 16 3/11/2024
1.0.7 1,560 2/29/2024
1.0.6 551 2/26/2024
1.0.5 53 2/25/2024
1.0.4 113 2/24/2024
1.0.3 14 2/24/2024
1.0.2 125 2/23/2024
1.0.1 12,484 7/11/2023
1.0.0 70 4/7/2023
Show more