Skip to main content

reports

Creates, updates, deletes, gets or lists a reports resource.

Overview

Namereports
TypeResource
Idaws.resiliencehubv2.reports

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
assessment_idstringPresent for FAILURE_MODE reports. (pattern: <code>[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}</code>)
created_atstring (date-time)The timestamp when the report was created.
report_outputobjectPresent when status is SUCCEEDED or FAILED.
report_typestringThe type of the generated report. (FAILURE_MODE, TESTING)
service_arnstringARN identifier. (pattern: <code>arn:(aws|aws-cn|aws-iso|aws-iso-[a-z]{1}|aws-us-gov):[A-Za-z0-9][A-Za-z0-9_/.-]{0,62}:([a-z]{2}-((iso[a-z]{0,1}-)|(gov-)){0,1}[a-z]+-[0-9]):[0-9]{12}:[A-Za-z0-9/][A-Za-z0-9:_/+.-]{0,1023}</code>)
statusstringThe status of the report generation. (PENDING, SUCCEEDED, FAILED)
test_run_idstringThe unique identifier of a test run.
test_template_arnstringAn ARN owned by the service. Accepts either a standard 12-digit account ID or the literal "aws" for AWS-managed resources, such as AWS-managed test templates. (pattern: <code>arn:(aws|aws-cn|aws-iso|aws-iso-[a-z]{1}|aws-us-gov):[A-Za-z0-9][A-Za-z0-9_/.-]{0,62}:([a-z]{2}-((iso[a-z]{0,1}-)|(gov-)){0,1}[a-z]+-[0-9]):([0-9]{12}|aws):[A-Za-z0-9/][A-Za-z0-9:_/+.-]{0,1023}</code>)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_reportsselectregionserviceArn, reportType, testRunId, maxResults, nextTokenList reports for a service, or all reports owned by the account if serviceArn is not provided.
create_reportinsertregion, serviceArn, reportTypeOn-demand report creation. Idempotent — duplicate requests with same clientToken return existing result.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)
maxResultsinteger
nextTokenstring
reportTypestringFilter reports by type.
serviceArnstringOptional. If not provided, lists all reports owned by the account.
testRunIdstring

SELECT examples

List reports for a service, or all reports owned by the account if serviceArn is not provided.

SELECT
assessment_id,
created_at,
report_output,
report_type,
service_arn,
status,
test_run_id,
test_template_arn
FROM aws.resiliencehubv2.reports
WHERE region = '{{ region }}' -- required
AND serviceArn = '{{ serviceArn }}'
AND reportType = '{{ reportType }}'
AND testRunId = '{{ testRunId }}'
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
;

INSERT examples

On-demand report creation. Idempotent — duplicate requests with same clientToken return existing result.

INSERT INTO aws.resiliencehubv2.reports (
serviceArn,
reportType,
clientToken,
region
)
SELECT
'{{ serviceArn }}' /* required */,
'{{ reportType }}' /* required */,
'{{ clientToken }}',
'{{ region }}'
RETURNING
report_generation_result
;