You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I run Update-MgSitePage -BodyParameter @{ canvasLayout = @{ ... } to change the content in canvasLayout, the command tries to PATCH "/v1.0/sites/{site-id}/pages/{page-id}", which doesn't work.
Per the doc page, the command is supposed to PATCH "/v1.0/sites/{site-id}/pages/{page-id}/microsoft.graph.sitePage"
Expected behavior
This command should not return an HTTP 400 when providing the ID of a site page.
</details>
### Configuration
- Windows 11 23H2 build 22631.4037
- x64 architecture
- PowerShell 7.4.5
### Other information
I assume the problem here is that the MgSitePage cmdlets aren't aware of the microsoft.graph.sitePage type, hence the lack of a `-SitePageId` argument instead of `-BaseSitePageId`.
The text was updated successfully, but these errors were encountered:
Describe the bug
When I run
Update-MgSitePage -BodyParameter @{ canvasLayout = @{ ... }
to change the content in canvasLayout, the command tries to PATCH "/v1.0/sites/{site-id}/pages/{page-id}", which doesn't work.Per the doc page, the command is supposed to PATCH "/v1.0/sites/{site-id}/pages/{page-id}/microsoft.graph.sitePage"
Expected behavior
This command should not return an HTTP 400 when providing the ID of a site page.
How to reproduce
SDK Version
No response
Latest version known to work for scenario above?
2.22.0
Known Workarounds
As a workaround, I simply add '/microsoft.graph.sitePage' to the value I plug into {page-id}, and that seems to resolve the issue.
Debug output
Click to expand log
``` API not foundStatus: 400 (BadRequest)
ErrorCode: invalidRequest
Date: 2024-08-22T14:50:41
Headers:
Cache-Control : no-store, no-cache
Vary : Accept-Encoding
Strict-Transport-Security : max-age=31536000
(add'l headers removed for privacy)
The text was updated successfully, but these errors were encountered: