Deletes an organizational unit (OU) from a root or another OU. You must first remove all accounts and child OUs from the OU that you want to delete.
This operation can be called only from the organization's management account.
Use a bare-bones client and the command you need to make an API call.
import { OrganizationsClient, DeleteOrganizationalUnitCommand } from "@aws-sdk/client-organizations"; // ES Modules import // const { OrganizationsClient, DeleteOrganizationalUnitCommand } = require("@aws-sdk/client-organizations"); // CommonJS import const client = new OrganizationsClient(config); const command = new DeleteOrganizationalUnitCommand(input); const response = await client.send(command);
DeleteOrganizationalUnitCommandInput for command's input shape.
input
DeleteOrganizationalUnitCommandOutput for command's response shape.
response
config for OrganizationsClient's config shape.
config
Deletes an organizational unit (OU) from a root or another OU. You must first remove all accounts and child OUs from the OU that you want to delete.
This operation can be called only from the organization's management account.
Use a bare-bones client and the command you need to make an API call.
import { OrganizationsClient, DeleteOrganizationalUnitCommand } from "@aws-sdk/client-organizations"; // ES Modules import // const { OrganizationsClient, DeleteOrganizationalUnitCommand } = require("@aws-sdk/client-organizations"); // CommonJS import const client = new OrganizationsClient(config); const command = new DeleteOrganizationalUnitCommand(input); const response = await client.send(command);
DeleteOrganizationalUnitCommandInput for command's
input
shape.DeleteOrganizationalUnitCommandOutput for command's
response
shape.config for OrganizationsClient's
config
shape.