ListOrganizationRecommendationResources
List Resources of a Recommendation within an Organization. This API only supports prioritized recommendations and provides global priority recommendations, eliminating the need to call the API in each AWS Region.
Request Syntax
GET /v1/organization-recommendations/organizationRecommendationIdentifier
/resources?affectedAccountId=affectedAccountId
&exclusionStatus=exclusionStatus
&maxResults=maxResults
&nextToken=nextToken
®ionCode=regionCode
&status=status
HTTP/1.1
URI Request Parameters
The request uses the following URI parameters.
- affectedAccountId
-
An account affected by this organization recommendation
Length Constraints: Fixed length of 12.
Pattern:
^\d+$
- exclusionStatus
-
The exclusion status of the resource
Valid Values:
excluded | included
- maxResults
-
The maximum number of results to return per page.
Valid Range: Minimum value of 1. Maximum value of 200.
- nextToken
-
The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
Length Constraints: Minimum length of 4. Maximum length of 10000.
- organizationRecommendationIdentifier
-
The AWS Organization organization's Recommendation identifier
Length Constraints: Minimum length of 20. Maximum length of 200.
Pattern:
^arn:[\w-]+:trustedadvisor:::organization-recommendation\/[\w-]+$
Required: Yes
- regionCode
-
The AWS Region code of the resource
- status
-
The status of the resource
Valid Values:
ok | warning | error
Request Body
The request does not have a request body.
Response Syntax
HTTP/1.1 200
Content-type: application/json
{
"nextToken": "string",
"organizationRecommendationResourceSummaries": [
{
"accountId": "string",
"arn": "string",
"awsResourceId": "string",
"exclusionStatus": "string",
"id": "string",
"lastUpdatedAt": "string",
"metadata": {
"string" : "string"
},
"recommendationArn": "string",
"regionCode": "string",
"status": "string"
}
]
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- nextToken
-
The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
Type: String
Length Constraints: Minimum length of 4. Maximum length of 10000.
- organizationRecommendationResourceSummaries
-
A list of Recommendation Resources
Type: Array of OrganizationRecommendationResourceSummary objects
Errors
For information about the errors that are common to all actions, see Common Errors.
- AccessDeniedException
-
Exception that access has been denied due to insufficient access
HTTP Status Code: 403
- InternalServerException
-
Exception to notify that an unexpected internal error occurred during processing of the request
HTTP Status Code: 500
- ResourceNotFoundException
-
Exception that the requested resource has not been found
HTTP Status Code: 404
- ThrottlingException
-
Exception to notify that requests are being throttled
HTTP Status Code: 429
- ValidationException
-
Exception that the request failed to satisfy service constraints
HTTP Status Code: 400
Examples
List All Organization Recommendation Resources
List all resources for an organization recommendation by its identifier.
Sample Request
{
"organizationRecommendationIdentifier": "arn:aws:trustedadvisor:::organization-recommendation/5a694939-2e54-45a2-ae72-730598fa89d0"
}
Sample Response
{
"organizationRecommendationResourceSummaries": [
{
"arn": "arn:aws:trustedadvisor::000000000000:recommendation-resource/5a694939-2e54-45a2-ae72-730598fa89d0/bb38affc0ce0681d9a6cd13f30238ba03a8f63dfe7a379dc403c619119d86af",
"awsResourceId": "database-1-instance-1",
"id": "bb38affc0ce0681d9a6cd13f302383ba03a8f63dfe7a379dc403c619119d86af",
"lastUpdatedAt": "2023-11-01T15:09:51.891Z",
"metadata": {
"0": "14",
"1": "208.79999999999998",
"2": "database-1-instance-1",
"3": "db.r5.large",
"4": "false",
"5": "us-west-2",
"6": "arn:aws:rds:us-west-2:000000000000:db:database-1-instance-1",
"7": "1"
},
"recommendationArn": "arn:aws:trustedadvisor:::organization-recommendation/5a694939-2e54-45a2-ae72-730598fa89d0",
"regionCode": "us-west-2",
"exclusionStatus": "included",
"status": "warning"
},
{
"arn": "arn:aws:trustedadvisor::000000000000:recommendation-resource/5a694939-2e54-45a2-ae72-730598fa89d0/51fded4d7a3278818df9cfe344ff5762cec46c095a6763d1ba1ba53bd0e1b0e6",
"awsResourceId": "database-1",
"id": "51fded4d7a3278818df9cfe344ff5762cec46c095a6763d1ba1ba53bd0e1b0e6",
"lastUpdatedAt": "2023-11-01T15:09:51.891Z",
"metadata": {
"0": "14",
"1": "31.679999999999996",
"2": "database-1",
"3": "db.t3.small",
"4": "false",
"5": "us-west-2",
"6": "arn:aws:rds:us-west-2:000000000000:db:database-1",
"7": "20"
},
"recommendationArn": "arn:aws:trustedadvisor:::organization-recommendation/5a694939-2e54-45a2-ae72-730598fa89d0",
"regionCode": "us-west-2",
"exclusionStatus": "included",
"status": "warning"
},
{
"arn": "arn:aws:trustedadvisor::000000000000:recommendation-resource/5a694939-2e54-45a2-ae72-730598fa89d0/f4d01bd20f4cd5372062aafc8786c489e48f0ead7cdab121463bf9f89e40a36b",
"awsResourceId": "database-2-instance-1-us-west-2a",
"id": "f4d01bd20f4cd5372062aafc8786c489e48f0ead7cdab121463bf9f89e40a36b",
"lastUpdatedAt": "2023-11-01T15:09:51.891Z",
"metadata": {
"0": "14",
"1": "187.20000000000002",
"2": "database-2-instance-1-us-west-2a",
"3": "db.r6g.large",
"4": "true",
"5": "us-west-2",
"6": "arn:aws:rds:us-west-2:000000000000:db:database-2-instance-1-us-west-2a",
"7": "1"
},
"recommendationArn": "arn:aws:trustedadvisor:::organization-recommendation/5a694939-2e54-45a2-ae72-730598fa89d0",
"regionCode": "us-west-2",
"exclusionStatus": "included",
"status": "warning"
},
],
"nextToken": "REDACTED"
}
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: