r/GraphAPI • u/GonzoZH • Apr 11 '25
Simple MS Graph API PowerShell Module
Hi all,
For a larger Entra ID enumeration script, I wanted to move away from the official Microsoft Graph PowerShell modules, since they’re not always available on customer systems. Furthermore, some API calls are not available (PIM for Group related stuff).
I ended up creating a simple, single-file PowerShell module to work directly with the Graph API.
It handles the usual stuff like:
Automatic Pagination
Retry logic (with backoff for throttling (HTTP 429), or other errors like HTTP 504 etc.)
v1.0 / beta endpoint switch
Query parameters and custom headers
Simple proxy support
Basic error handling and logging
Maybe it is useful for someone else: https://github.com/zh54321/GraphRequest
2
Upvotes
2
u/srozemuller Apr 12 '25
Great approach. But there is a reason why users use the Graph PowerShell. It is because of the authentication part.
It is in the graph.authentication module. Installing that helps you creating a lot extra logic and don’t need the whole module ;)