Building, integrating, or customizing apps and workflows within Microsoft Teams using developer tools and APIs
Thank you for posting your question in the Microsoft Q&A forum.
When updating place-related entities with Microsoft Graph, it’s important to understand how PATCH requests handle default values and immutable properties differently from POST operations.
Building resource: If you send a PATCH request for a Building without including the wifiState property, the backend interprets the omitted value as the default enum value Unknown. While Unknown is allowed during POST (create) operations, it is not valid for PATCH, causing the request to fail.
Workaround: Always include a valid wifiState value in PATCH requests, even if the value is not being changed.
Reference: building resource type - Microsoft Graph v1.0 | Microsoft Learn.
Desk resource: The same behavior applies to Desk resources. If heightAdjustableState is omitted in a PATCH request, it is interpreted as Unknown, which PATCH does not allow.
Workaround: Explicitly include a valid heightAdjustableState value in PATCH requests.
Reference: desk resource type - Microsoft Graph v1.0 | Microsoft Learn.
Room and Workspace resources expose a placeId property, which is an immutable unique identifier and cannot be edited.
You did not change the id, but Microsoft Graph still rejects the PATCH request because the id or placeId property is included in the payload, and PATCH requests must not include immutable identifiers.
Reference: Microsoft Graph what's new history - Microsoft Graph | Microsoft Learn.
There is currently no official documentation or community discussion explaining why PATCH requests for a Building may start failing with “ServiceMetadata cannot be changed via API” one or more days after creation. As moderators, we cannot investigate backend causes, we can only provide guidance based on public resources and experience. If needed, you can report this issue on Github.
Reference: Participating in a discussion - GitHub Docs.
I hope this information is helpful.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.