import_resources_to_draft_app_version

ResilienceHub.Client.import_resources_to_draft_app_version(**kwargs)

Imports resources to AWS Resilience Hub application draft version from different input sources. For more information about the input sources supported by AWS Resilience Hub, see Discover the structure and describe your Resilience Hub application.

See also: AWS API Documentation

Request Syntax

response = client.import_resources_to_draft_app_version(
    appArn='string',
    importStrategy='AddOnly'|'ReplaceAll',
    sourceArns=[
        'string',
    ],
    terraformSources=[
        {
            's3StateFileUrl': 'string'
        },
    ]
)
Parameters
  • appArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the AWS Resilience Hub application. The format for this ARN is: arn: partition :resiliencehub: region : account :app/ app-id . For more information about ARNs, see Amazon Resource Names (ARNs) in the AWS General Reference guide.

  • importStrategy (string) -- The import strategy you would like to set to import resources into AWS Resilience Hub application.
  • sourceArns (list) --

    The Amazon Resource Names (ARNs) for the resources that you want to import.

    • (string) --
  • terraformSources (list) --

    A list of terraform file s3 URLs you need to import.

    • (dict) --

      The Terraform s3 state file you need to import.

      • s3StateFileUrl (string) -- [REQUIRED]

        The Terraform s3 state file you need to import.

Return type

dict

Returns

Response Syntax

{
    'appArn': 'string',
    'appVersion': 'string',
    'sourceArns': [
        'string',
    ],
    'status': 'Pending'|'InProgress'|'Failed'|'Success',
    'terraformSources': [
        {
            's3StateFileUrl': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    • appArn (string) --

      The Amazon Resource Name (ARN) of the AWS Resilience Hub application. The format for this ARN is: arn: partition :resiliencehub: region : account :app/ app-id . For more information about ARNs, see Amazon Resource Names (ARNs) in the AWS General Reference guide.

    • appVersion (string) --

      The version of the application.

    • sourceArns (list) --

      The Amazon Resource Names (ARNs) for the resources that you imported.

      • (string) --
    • status (string) --

      The status of the action.

    • terraformSources (list) --

      A list of terraform file s3 URLs you need to import.

      • (dict) --

        The Terraform s3 state file you need to import.

        • s3StateFileUrl (string) --

          The Terraform s3 state file you need to import.

Exceptions

  • ResilienceHub.Client.exceptions.InternalServerException
  • ResilienceHub.Client.exceptions.ResourceNotFoundException
  • ResilienceHub.Client.exceptions.ConflictException
  • ResilienceHub.Client.exceptions.ThrottlingException
  • ResilienceHub.Client.exceptions.ValidationException
  • ResilienceHub.Client.exceptions.AccessDeniedException