Skip to content

CloudFormation  >  Operations  >  create_generated_template

create_generated_template

Operation

create_generated_template async

create_generated_template(request: CreateGeneratedTemplateInput | CreateGeneratedTemplateInputDict, /, *, plugins: list[Plugin] | None = None) -> CreateGeneratedTemplateOutput
create_generated_template(*, plugins: list[Plugin] | None = None, **kwargs: Unpack[CreateGeneratedTemplateInputDict]) -> CreateGeneratedTemplateOutput

Creates a template from existing resources that are not already managed with CloudFormation. You can check the status of the template generation using the DescribeGeneratedTemplate API action.

Parameters:

Name Type Description Default
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
CreateGeneratedTemplateOutput

An instance of CreateGeneratedTemplateOutput.

Input

Pass the input fields as keyword arguments, or pass a model or dictionary as the first positional argument. Pass plugins separately as a keyword argument.

Model

CreateGeneratedTemplateInput dataclass

Bases: _SerdeShape

Dataclass for CreateGeneratedTemplateInput structure.

Attributes
generated_template_name class-attribute instance-attribute
generated_template_name: str | None = ...

The name assigned to the generated template.

resources class-attribute instance-attribute
resources: list[ResourceDefinition] | None = ...

An optional list of resources to be included in the generated template.

If no resources are specified,the template will be created without any resources. Resources can be added to the template using the UpdateGeneratedTemplate API action.

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

An optional name or ARN of a stack to use as the base stack for the generated template.

template_configuration class-attribute instance-attribute
template_configuration: TemplateConfiguration | None = ...

The configuration details of the generated template, including the DeletionPolicy and UpdateReplacePolicy.

Dictionaries

CreateGeneratedTemplateInputDict

Bases: TypedDict

Dictionary form of CreateGeneratedTemplateInput.

Attributes
generated_template_name instance-attribute
generated_template_name: Required[str]

The name assigned to the generated template.

resources instance-attribute

An optional list of resources to be included in the generated template.

If no resources are specified,the template will be created without any resources. Resources can be added to the template using the UpdateGeneratedTemplate API action.

stack_name instance-attribute
stack_name: str | None

An optional name or ARN of a stack to use as the base stack for the generated template.

template_configuration instance-attribute
template_configuration: TemplateConfiguration | TemplateConfigurationDict | None

The configuration details of the generated template, including the DeletionPolicy and UpdateReplacePolicy.

Output

CreateGeneratedTemplateOutput dataclass

Bases: _SerdeShape

Dataclass for CreateGeneratedTemplateOutput structure.

Attributes

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

The ID of the generated template.

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.