msgraph-sdk-powershell
msgraph-sdk-powershell copied to clipboard
Document troubleshooting with -Debug and other support techniques
We should document the use of hte Debug
parameter for all MS Graph PS SDK commands and also provide guidance on how to follow the documented support practices for the REST API.
When troubleshooting issues with Microsoft Graph PowerShell SDK commands most failures are actually failures interacting with the Microsoft Graph API itself. Debugging then usually requires understanding the underlying REST requests and responses. Use of the Debug
option provides the following information:
- The
client-request-id
submitted by Microsoft Graph PowerShell SDK in the request - The
request-id
returned by Microsoft Graph (should be the same asclient-request-id
). - The time stamp (
Date
field) - The generated URL for the request -- this can be cross-referenced with REST API documentation for instance
- The response status and content
A troubleshooting article should provide steps to reproduce issues using Debug
and explain which fields are important. The article should link to the REST API docs and the troubleshooting best practices of those docs which include the instructions to provide the request id and timestamp which are crucial for getting support.
The output including the URI and body can also be provided in bug reports in this forum which can identify if MS Graph PowerShell SDK is incorrectly generating requests or misinterpreting responses from Microsoft Graph.