Method: orgunits.insert
Оптимизируйте свои подборки
Сохраняйте и классифицируйте контент в соответствии со своими настройками.
Добавляет организационное подразделение.
HTTP-запрос
POST https://admin.googleapis.com/admin/directory/v1/customer/{customerId}/orgunits
URL-адрес использует синтаксис транскодирования gRPC .
Параметры пути
Параметры |
---|
customerId | string Уникальный идентификатор аккаунта Google Workspace клиента. Как администратор учетной записи вы также можете использовать псевдоним my_customer для представления customerId вашей учетной записи. customerId также возвращается как часть ресурса Users . |
Тело запроса
Тело запроса содержит экземпляр OrgUnit
.
Тело ответа
В случае успеха тело ответа содержит вновь созданный экземпляр OrgUnit
.
Области авторизации
Требуется одна из следующих областей OAuth:
-
https://apps-apis.google.com/a/feeds/policies/
-
https://www.googleapis.com/auth/admin.directory.orgunit
Дополнительную информацию см. в руководстве по авторизации .
Если не указано иное, контент на этой странице предоставляется по лицензии Creative Commons "С указанием авторства 4.0", а примеры кода – по лицензии Apache 2.0. Подробнее об этом написано в правилах сайта. Java – это зарегистрированный товарный знак корпорации Oracle и ее аффилированных лиц.
Последнее обновление: 2025-07-25 UTC.
[null,null,["Последнее обновление: 2025-07-25 UTC."],[],[],null,["# Method: orgunits.insert\n\nAdds an organizational unit.\n\n### HTTP request\n\n`POST https://admin.googleapis.com/admin/directory/v1/customer/{customerId}/orgunits`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|--------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `customerId` | `string` The unique ID for the customer's Google Workspace account. As an account administrator, you can also use the `my_customer` alias to represent your account's `customerId`. The `customerId` is also returned as part of the [Users resource](https://developers.google.com/workspace/admin/directory/v1/reference/users). |\n\n### Request body\n\nThe request body contains an instance of [OrgUnit](/workspace/admin/directory/reference/rest/v1/orgunits#OrgUnit).\n\n### Response body\n\nIf successful, the response body contains a newly created instance of [OrgUnit](/workspace/admin/directory/reference/rest/v1/orgunits#OrgUnit).\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://apps-apis.google.com/a/feeds/policies/`\n- `\n https://www.googleapis.com/auth/admin.directory.orgunit`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]