amazonka-health-2.0: Amazon Health APIs and Notifications SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Description

Returns a list of accounts in the organization from Organizations that are affected by the provided event. For more information about the different types of Health events, see Event.

Before you can call this operation, you must first enable Health to work with Organizations. To do this, call the EnableHealthServiceAccessForOrganization operation from your organization's management account.

This API operation uses pagination. Specify the nextToken parameter in the next request to return more results.

This operation returns paginated results.

Synopsis

Creating a Request

data DescribeAffectedAccountsForOrganization Source #

Constructors

DescribeAffectedAccountsForOrganization' 

Fields

  • maxResults :: Maybe Natural

    The maximum number of items to return in one batch, between 10 and 100, inclusive.

  • nextToken :: Maybe Text

    If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.

  • eventArn :: Text

    The unique identifier for the event. The event ARN has the arn:aws:health:event-region::event/SERVICE/EVENT_TYPE_CODE/EVENT_TYPE_PLUS_ID format.

    For example, an event ARN might look like the following:

    arn:aws:health:us-east-1::event/EC2/EC2_INSTANCE_RETIREMENT_SCHEDULED/EC2_INSTANCE_RETIREMENT_SCHEDULED_ABC123-DEF456

Instances

Instances details
ToJSON DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

ToHeaders DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

ToPath DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

ToQuery DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

AWSPager DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

AWSRequest DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Generic DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Read DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Show DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

NFData DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Eq DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Hashable DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

type AWSResponse DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

type Rep DescribeAffectedAccountsForOrganization Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

type Rep DescribeAffectedAccountsForOrganization = D1 ('MetaData "DescribeAffectedAccountsForOrganization" "Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization" "amazonka-health-2.0-97kQZARXu4I8k4sVSmOp5K" 'False) (C1 ('MetaCons "DescribeAffectedAccountsForOrganization'" 'PrefixI 'True) (S1 ('MetaSel ('Just "maxResults") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Natural)) :*: (S1 ('MetaSel ('Just "nextToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "eventArn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text))))

newDescribeAffectedAccountsForOrganization Source #

Create a value of DescribeAffectedAccountsForOrganization with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:maxResults:DescribeAffectedAccountsForOrganization', describeAffectedAccountsForOrganization_maxResults - The maximum number of items to return in one batch, between 10 and 100, inclusive.

DescribeAffectedAccountsForOrganization, describeAffectedAccountsForOrganization_nextToken - If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.

DescribeAffectedAccountsForOrganization, describeAffectedAccountsForOrganization_eventArn - The unique identifier for the event. The event ARN has the arn:aws:health:event-region::event/SERVICE/EVENT_TYPE_CODE/EVENT_TYPE_PLUS_ID format.

For example, an event ARN might look like the following:

arn:aws:health:us-east-1::event/EC2/EC2_INSTANCE_RETIREMENT_SCHEDULED/EC2_INSTANCE_RETIREMENT_SCHEDULED_ABC123-DEF456

Request Lenses

describeAffectedAccountsForOrganization_maxResults :: Lens' DescribeAffectedAccountsForOrganization (Maybe Natural) Source #

The maximum number of items to return in one batch, between 10 and 100, inclusive.

describeAffectedAccountsForOrganization_nextToken :: Lens' DescribeAffectedAccountsForOrganization (Maybe Text) Source #

If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.

describeAffectedAccountsForOrganization_eventArn :: Lens' DescribeAffectedAccountsForOrganization Text Source #

The unique identifier for the event. The event ARN has the arn:aws:health:event-region::event/SERVICE/EVENT_TYPE_CODE/EVENT_TYPE_PLUS_ID format.

For example, an event ARN might look like the following:

arn:aws:health:us-east-1::event/EC2/EC2_INSTANCE_RETIREMENT_SCHEDULED/EC2_INSTANCE_RETIREMENT_SCHEDULED_ABC123-DEF456

Destructuring the Response

data DescribeAffectedAccountsForOrganizationResponse Source #

Constructors

DescribeAffectedAccountsForOrganizationResponse' 

Fields

  • affectedAccounts :: Maybe [Text]

    A JSON set of elements of the affected accounts.

  • eventScopeCode :: Maybe EventScopeCode

    This parameter specifies if the Health event is a public Amazon Web Services service event or an account-specific event.

    • If the eventScopeCode value is PUBLIC, then the affectedAccounts value is always empty.
    • If the eventScopeCode value is ACCOUNT_SPECIFIC, then the affectedAccounts value lists the affected Amazon Web Services accounts in your organization. For example, if an event affects a service such as Amazon Elastic Compute Cloud and you have Amazon Web Services accounts that use that service, those account IDs appear in the response.
    • If the eventScopeCode value is NONE, then the eventArn that you specified in the request is invalid or doesn't exist.
  • nextToken :: Maybe Text

    If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Generic DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Read DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Show DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

NFData DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

Eq DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

type Rep DescribeAffectedAccountsForOrganizationResponse Source # 
Instance details

Defined in Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization

type Rep DescribeAffectedAccountsForOrganizationResponse = D1 ('MetaData "DescribeAffectedAccountsForOrganizationResponse" "Amazonka.AWSHealth.DescribeAffectedAccountsForOrganization" "amazonka-health-2.0-97kQZARXu4I8k4sVSmOp5K" 'False) (C1 ('MetaCons "DescribeAffectedAccountsForOrganizationResponse'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "affectedAccounts") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Text])) :*: S1 ('MetaSel ('Just "eventScopeCode") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe EventScopeCode))) :*: (S1 ('MetaSel ('Just "nextToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newDescribeAffectedAccountsForOrganizationResponse Source #

Create a value of DescribeAffectedAccountsForOrganizationResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:affectedAccounts:DescribeAffectedAccountsForOrganizationResponse', describeAffectedAccountsForOrganizationResponse_affectedAccounts - A JSON set of elements of the affected accounts.

DescribeAffectedAccountsForOrganizationResponse, describeAffectedAccountsForOrganizationResponse_eventScopeCode - This parameter specifies if the Health event is a public Amazon Web Services service event or an account-specific event.

  • If the eventScopeCode value is PUBLIC, then the affectedAccounts value is always empty.
  • If the eventScopeCode value is ACCOUNT_SPECIFIC, then the affectedAccounts value lists the affected Amazon Web Services accounts in your organization. For example, if an event affects a service such as Amazon Elastic Compute Cloud and you have Amazon Web Services accounts that use that service, those account IDs appear in the response.
  • If the eventScopeCode value is NONE, then the eventArn that you specified in the request is invalid or doesn't exist.

DescribeAffectedAccountsForOrganization, describeAffectedAccountsForOrganizationResponse_nextToken - If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.

$sel:httpStatus:DescribeAffectedAccountsForOrganizationResponse', describeAffectedAccountsForOrganizationResponse_httpStatus - The response's http status code.

Response Lenses

describeAffectedAccountsForOrganizationResponse_eventScopeCode :: Lens' DescribeAffectedAccountsForOrganizationResponse (Maybe EventScopeCode) Source #

This parameter specifies if the Health event is a public Amazon Web Services service event or an account-specific event.

  • If the eventScopeCode value is PUBLIC, then the affectedAccounts value is always empty.
  • If the eventScopeCode value is ACCOUNT_SPECIFIC, then the affectedAccounts value lists the affected Amazon Web Services accounts in your organization. For example, if an event affects a service such as Amazon Elastic Compute Cloud and you have Amazon Web Services accounts that use that service, those account IDs appear in the response.
  • If the eventScopeCode value is NONE, then the eventArn that you specified in the request is invalid or doesn't exist.

describeAffectedAccountsForOrganizationResponse_nextToken :: Lens' DescribeAffectedAccountsForOrganizationResponse (Maybe Text) Source #

If the results of a search are large, only a portion of the results are returned, and a nextToken pagination token is returned in the response. To retrieve the next batch of results, reissue the search request and include the returned token. When all results have been returned, the response does not contain a pagination token value.