forked from hashicorp/terraform-provider-aws
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create the documentation of data.aws_organizations_accounts
- Loading branch information
Showing
1 changed file
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
subcategory: "Organizations" | ||
layout: "aws" | ||
page_title: "AWS: aws_organizations_accounts" | ||
description: |- | ||
Get all direct child organizational units under a parent organizational unit. This only provides immediate children, not all children. | ||
--- | ||
|
||
# Data Source: aws_organizations_accounts | ||
|
||
Get all direct child organizational units under a parent organizational unit. This only provides immediate children, not all children. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
data "aws_organizations_organization" "org" {} | ||
data "aws_organizations_accounts" "ou" { | ||
parent_id = data.aws_organizations_organization.org.roots[0].id | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
* `parent_id` - (Required) The parent ID of the accounts. | ||
|
||
## Attributes Reference | ||
|
||
* `children` - List of child accounts, which have the following attributes: | ||
* `arn` - ARN of the organizational account | ||
* `name` - Name of the organizational account | ||
* `id` - ID of the organizational account | ||
* `email` - `email` - Email of the account | ||
* `id` - Parent identifier of the accounts. |