Hi @Omar BELHASSINE
Here is link about Add custom data to resources using extensions for your reference:
https://learn.microsoft.com/en-us/graph/api/resources/searchrequest?view=graph-rest-1.0
According to the link, you can use different types of extensions to add custom data to resources, such as users, groups, or devices.
One of the options is to use open extensions, which are untyped name-value pairs that can be added to any resource.
To update an open extension, you can use the PATCH method with the following syntax:
PATCH /{resource}/{id}/extensions/{extensionName} Content-type: application/json { “extensionName”: { “property1”: “value1”, “property2”: “value2” } }
For example, if you have added an open extension named com.contoso.roamingSettings to a user with the id 1234, and you want to update the property theme with the value dark, you can use the following request:
PATCH /users/1234/extensions/com.contoso.roamingSettings Content-type: application/json { “com.contoso.roamingSettings”: { "theme":"dark" } }
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.
Best Regards
Cheng Feng