Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Creates an organizational unit (OU) within a root or parent OU. An OU is a container for accounts that enables you to organize your accounts to apply policies according to your business requirements. The number of levels deep that you can nest OUs is dependent upon the policy types enabled for that root. For service control policies, the limit is five.
For more information about OUs, see Managing Organizational Units in the AWS Organizations User Guide .
This operation can be called only from the organization's master account.
- createOrganizationalUnit :: Text -> Text -> CreateOrganizationalUnit
- data CreateOrganizationalUnit
- couParentId :: Lens' CreateOrganizationalUnit Text
- couName :: Lens' CreateOrganizationalUnit Text
- createOrganizationalUnitResponse :: Int -> CreateOrganizationalUnitResponse
- data CreateOrganizationalUnitResponse
- coursOrganizationalUnit :: Lens' CreateOrganizationalUnitResponse (Maybe OrganizationalUnit)
- coursResponseStatus :: Lens' CreateOrganizationalUnitResponse Int
Creating a Request
createOrganizationalUnit Source #
Creates a value of CreateOrganizationalUnit
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
couParentId
- The unique identifier (ID) of the parent root or OU in which you want to create the new OU. The regex pattern for a parent ID string requires one of the following: * Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits. * Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.couName
- The friendly name to assign to the new OU.
data CreateOrganizationalUnit Source #
See: createOrganizationalUnit
smart constructor.
Request Lenses
couParentId :: Lens' CreateOrganizationalUnit Text Source #
The unique identifier (ID) of the parent root or OU in which you want to create the new OU. The regex pattern for a parent ID string requires one of the following: * Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits. * Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.
Destructuring the Response
createOrganizationalUnitResponse Source #
Creates a value of CreateOrganizationalUnitResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
coursOrganizationalUnit
- A structure that contains details about the newly created OU.coursResponseStatus
- -- | The response status code.
data CreateOrganizationalUnitResponse Source #
See: createOrganizationalUnitResponse
smart constructor.
Response Lenses
coursOrganizationalUnit :: Lens' CreateOrganizationalUnitResponse (Maybe OrganizationalUnit) Source #
A structure that contains details about the newly created OU.
coursResponseStatus :: Lens' CreateOrganizationalUnitResponse Int Source #
- - | The response status code.