Skip to content

CloudFormation  >  Operations  >  get_template_summary

get_template_summary

Operation

get_template_summary async

get_template_summary(input: GetTemplateSummaryInput, plugins: list[Plugin] | None = None) -> GetTemplateSummaryOutput

Returns information about a new or existing template. The GetTemplateSummary action is useful for viewing parameter information, such as default parameter values and parameter types, before you create or update a stack or StackSet.

You can use the GetTemplateSummary action when you submit a template, or you can get template information for a StackSet, or a running or deleted stack.

For deleted stacks, GetTemplateSummary returns the template information for up to 90 days after the stack has been deleted. If the template doesn't exist, a ValidationError is returned.

Parameters:

Name Type Description Default
input GetTemplateSummaryInput

An instance of GetTemplateSummaryInput.

required
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None

Returns:

Type Description
GetTemplateSummaryOutput

An instance of GetTemplateSummaryOutput.

Input

GetTemplateSummaryInput dataclass

Bases: _SerdeShape

The input for the GetTemplateSummary action.

Attributes

call_as class-attribute instance-attribute
call_as: str | None = ...

[Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account.

By default, SELF is specified. Use SELF for StackSets with self-managed permissions.

  • If you are signed in to the management account, specify SELF.

  • If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN.

Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.

stack_name class-attribute instance-attribute
stack_name: str | None = ...

The name or the stack ID that's associated with the stack, which aren't always interchangeable. For running stacks, you can specify either the stack's name or its unique stack ID. For deleted stack, you must specify the unique stack ID.

Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.

stack_set_name class-attribute instance-attribute
stack_set_name: str | None = ...

The name or unique ID of the StackSet from which the stack was created.

Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.

template_body class-attribute instance-attribute
template_body: str | None = ...

Structure that contains the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes.

Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.

template_summary_config class-attribute instance-attribute
template_summary_config: TemplateSummaryConfig | None = ...

Specifies options for the GetTemplateSummary API action.

template_url class-attribute instance-attribute
template_url: str | None = ...

The URL of a file that contains the template body. The URL must point to a template (max size: 1 MB) that's located in an Amazon S3 bucket or a Systems Manager document. The location for an Amazon S3 bucket must start with https://.

Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.

Output

GetTemplateSummaryOutput dataclass

Bases: _SerdeShape

The output for the GetTemplateSummary action.

Attributes

capabilities class-attribute instance-attribute
capabilities: list[str] | None = ...

The capabilities found within the template. If your template contains IAM resources, you must specify the CAPABILITY_IAM or CAPABILITY_NAMED_IAM value for this parameter when you use the CreateStack or UpdateStack actions with your template; otherwise, those actions return an InsufficientCapabilities error.

For more information, see Acknowledging IAM resources in CloudFormation templates.

capabilities_reason class-attribute instance-attribute
capabilities_reason: str | None = ...

The list of resources that generated the values in the Capabilities response element.

declared_transforms class-attribute instance-attribute
declared_transforms: list[str] | None = ...

A list of the transforms that are declared in the template.

description class-attribute instance-attribute
description: str | None = ...

The value that's defined in the Description property of the template.

metadata class-attribute instance-attribute
metadata: str | None = ...

The value that's defined for the Metadata property of the template.

parameters class-attribute instance-attribute
parameters: list[ParameterDeclaration] | None = ...

A list of parameter declarations that describe various properties for each parameter.

resource_identifier_summaries class-attribute instance-attribute
resource_identifier_summaries: list[ResourceIdentifierSummary] | None = ...

A list of resource identifier summaries that describe the target resources of an import operation and the properties you can provide during the import to identify the target resources. For example, BucketName is a possible identifier property for an AWS::S3::Bucket resource.

resource_types class-attribute instance-attribute
resource_types: list[str] | None = ...

A list of all the template resource types that are defined in the template, such as AWS::EC2::Instance, AWS::Dynamo::Table, and Custom::MyCustomInstance.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.

version class-attribute instance-attribute
version: str | None = ...

The Amazon Web Services template format version, which identifies the capabilities of the template.

warnings class-attribute instance-attribute
warnings: Warnings | None = ...

An object that contains any warnings returned.