DisableOrganizationLevelResources
Disables your organization's ability to create organization-level resources. An organization-level resource is an IAM resource that your organization owns instead of an individual AWS account owning it. After you disable this capability, your organization returns to its default state and cannot create organization-level resources until the management account enables the capability again.
The organization-level resources that this capability governs include workload
identity providers and workload identity templates that you create with a
ResourceScope of ORGANIZATION.
Delete your organization's organization-level resources before you call this
operation. If any organization-level resource still exists, IAM rejects the request
with OrganizationLevelResourcesExistException. To delete an
organization-scoped workload identity provider or workload identity template, see DeleteWorkloadIdentityProvider and DeleteWorkloadIdentityTemplate.
This operation acts on the organization that the calling account belongs to. Only the management account of that organization can call this operation. A delegated administrator for IAM cannot call it.
Response Elements
The following elements are returned by the service.
- EnabledFeatures.member.N
-
The features that are enabled for your organization after this call. This is the organization's complete set of enabled features, so the feature that you disabled is no longer in the list.
Type: Array of strings
Valid Values:
RootCredentialsManagement | RootSessions | OrganizationIamResources - OrganizationId
-
The unique identifier (ID) of the organization that the calling account belongs to.
Type: String
Length Constraints: Maximum length of 34.
Pattern:
^o-[a-z0-9]{10,32}$
Errors
For information about the errors that are common to all actions, see Common Error Types.
- CallerIsNotManagementAccount
-
The request was rejected because the account making the request is not the management account for the organization.
HTTP Status Code: 400
- OrganizationLevelResourcesExist
-
The request was rejected because your organization still has organization-level resources. Delete them before you disable organization-level resources for your organization.
HTTP Status Code: 400
- OrganizationNotFound
-
The request was rejected because no organization is associated with your account.
HTTP Status Code: 400
- OrganizationNotInAllFeaturesMode
-
The request was rejected because your organization does not have All features enabled. For more information, see Available feature sets in the AWS Organizations User Guide.
HTTP Status Code: 400
- ServiceAccessNotEnabled
-
The request was rejected because trusted access is not enabled for IAM in AWS Organizations. For details, see IAM and AWS Organizations in the AWS Organizations User Guide.
HTTP Status Code: 400
- ServiceFailure
-
The request processing has failed because of an unknown error, exception or failure.
HTTP Status Code: 500
Examples
Example – Disable organization-level resources
This example illustrates one usage of DisableOrganizationLevelResources.
Sample Request
https://iam.us-east-1.amazonaws.com/?Action=DisableOrganizationLevelResources
&Version=2010-05-08
&AUTHPARAMS
Sample Response
<DisableOrganizationLevelResourcesResponse xmlns="https://iam.amazonaws.com/doc/2010-05-08/">
<DisableOrganizationLevelResourcesResult>
<OrganizationId>o-aa111bb222</OrganizationId>
<EnabledFeatures>
<member>RootCredentialsManagement</member>
<member>RootSessions</member>
</EnabledFeatures>
</DisableOrganizationLevelResourcesResult>
<ResponseMetadata>
<RequestId>4a93ceee-9966-11e1-b624-b1aEXAMPLE7c</RequestId>
</ResponseMetadata>
</DisableOrganizationLevelResourcesResponse>
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: