| title | Update organization |
|---|---|
| description | Update the properties of the currently authenticated organization. |
| ms.localizationpriority | medium |
| author | suawat |
| ms.reviewer | alvarorahul, iamut |
| ms.subservice | entra-directory-management |
| doc_type | apiPageType |
| ms.date | 04/05/2024 |
Namespace: microsoft.graph
[!INCLUDE beta-disclaimer]
Update the properties of the currently authenticated organization. In this case, organization is defined as a collection of exactly one record, and so its ID must be specified in the request. The ID is also known as the tenantId of the organization.
[!INCLUDE national-cloud-support]
Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.
[!INCLUDE permissions-table]
[!INCLUDE rbac-organization-apis-write]
PATCH /organization/{id}| Name | Description |
|---|---|
| Authorization | Bearer {token}. Required. Learn more about authentication and authorization. |
| Content-Type | application/json |
In the request body, supply the values for relevant fields that should be updated. Existing properties that are not included in the request body will maintain their previous values or be recalculated based on changes to other property values. For best performance you shouldn't include existing values that haven't changed.
| Property | Type | Description |
|---|---|---|
| businessPhones | String collection | Telephone number for the organization. Although this is a string collection, only one number can be set for this property. |
| city | String | City name of the address for the organization. |
| marketingNotificationEmails | String collection | Notes: not nullable. |
| onPremisesSyncEnabled | Boolean | true to enable this object to be synced from an on-premises directory; false to disable syncing from an on-premises directory; Nullable. null if this object has never been synced from an on-premises directory (default). |
| postalCode | String | Postal code of the address for the organization. |
| preferredLanguage | String | The preferred language for the organization. Should follow ISO 639-1 Code; for example, en. |
| privacyProfile | privacyProfile | The privacy profile of an organization (set statementUrl and contactEmail). |
| securityComplianceNotificationMails | String collection | |
| securityComplianceNotificationPhones | String collection | |
| state | String | State name of the address for the organization. |
| street | String | Street name of the address for organization. |
| technicalNotificationMails | String collection | Notes: not nullable. |
Since the organization resource supports extensions, you can use the PATCH operation to
add, update, or delete your own app-specific data in custom properties of an extension in an existing organization instance.
If successful, this method returns 204 No Content response code. It doesn't return anything in the response body.
The following example shows a request.
PATCH https://graph.microsoft.com/beta/organization/84841066-274d-4ec0-a5c1-276be684bdd3
Content-type: application/json
{
"marketingNotificationEmails" : ["marketing@contoso.com"],
"onPremisesSyncEnabled" : true,
"privacyProfile" :
{
"contactEmail":"alice@contoso.com",
"statementUrl":"https://contoso.com/privacyStatement"
},
"securityComplianceNotificationMails" : ["security@contoso.com"],
"securityComplianceNotificationPhones" : ["(123) 456-7890"],
"technicalNotificationMails" : ["tech@contoso.com"]
}[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
[!INCLUDE sample-code] [!INCLUDE sdk-documentation]
The following example shows the response.
HTTP/1.1 204 No Content