Module Smaws_Client_Organizations.AttachPolicy

Attaches a policy to a root, an organizational unit (OU), or an individual account. How the policy affects accounts depends on the type of policy. Refer to the Organizations User Guide for information about each policy type:

You can only call this operation from the management account or a member account that is a delegated administrator.

val error_to_string : [ Smaws_Lib.Protocols.AwsJson.error | `AccessDeniedException of Types.access_denied_exception | `AWSOrganizationsNotInUseException of Types.aws_organizations_not_in_use_exception | `ConcurrentModificationException of Types.concurrent_modification_exception | `ConstraintViolationException of Types.constraint_violation_exception | `DuplicatePolicyAttachmentException of Types.duplicate_policy_attachment_exception | `InvalidInputException of Types.invalid_input_exception | `PolicyChangesInProgressException of Types.policy_changes_in_progress_exception | `PolicyNotFoundException of Types.policy_not_found_exception | `PolicyTypeNotEnabledException of Types.policy_type_not_enabled_exception | `ServiceException of Types.service_exception | `TargetNotFoundException of Types.target_not_found_exception | `TooManyRequestsException of Types.too_many_requests_exception | `UnsupportedAPIEndpointException of Types.unsupported_api_endpoint_exception ] -> string
val request : 'http_type Smaws_Lib.Context.t -> Types.attach_policy_request -> (Smaws_Lib.Smithy_api.Types.unit_, [> Smaws_Lib.Protocols.AwsJson.error | `AccessDeniedException of Types.access_denied_exception | `AWSOrganizationsNotInUseException of Types.aws_organizations_not_in_use_exception | `ConcurrentModificationException of Types.concurrent_modification_exception | `ConstraintViolationException of Types.constraint_violation_exception | `DuplicatePolicyAttachmentException of Types.duplicate_policy_attachment_exception | `InvalidInputException of Types.invalid_input_exception | `PolicyChangesInProgressException of Types.policy_changes_in_progress_exception | `PolicyNotFoundException of Types.policy_not_found_exception | `PolicyTypeNotEnabledException of Types.policy_type_not_enabled_exception | `ServiceException of Types.service_exception | `TargetNotFoundException of Types.target_not_found_exception | `TooManyRequestsException of Types.too_many_requests_exception | `UnsupportedAPIEndpointException of Types.unsupported_api_endpoint_exception ]) Stdlib.result
val request_with_metadata : 'http_type Smaws_Lib.Context.t -> Types.attach_policy_request -> (Smaws_Lib.Smithy_api.Types.unit_ Smaws_Lib.Response.t, [> Smaws_Lib.Protocols.AwsJson.error | `AccessDeniedException of Types.access_denied_exception | `AWSOrganizationsNotInUseException of Types.aws_organizations_not_in_use_exception | `ConcurrentModificationException of Types.concurrent_modification_exception | `ConstraintViolationException of Types.constraint_violation_exception | `DuplicatePolicyAttachmentException of Types.duplicate_policy_attachment_exception | `InvalidInputException of Types.invalid_input_exception | `PolicyChangesInProgressException of Types.policy_changes_in_progress_exception | `PolicyNotFoundException of Types.policy_not_found_exception | `PolicyTypeNotEnabledException of Types.policy_type_not_enabled_exception | `ServiceException of Types.service_exception | `TargetNotFoundException of Types.target_not_found_exception | `TooManyRequestsException of Types.too_many_requests_exception | `UnsupportedAPIEndpointException of Types.unsupported_api_endpoint_exception ] * Smaws_Lib.Response.metadata) Stdlib.result