AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Returns the template body for a specified stack. You can get the template for running or deleted stacks.

For deleted stacks, GetTemplate returns the template for up to 90 days after the stack has been deleted.

If the template doesn't exist, a ValidationError is returned.

Note:

For .NET Core this operation is only available in asynchronous form. Please refer to GetTemplateAsync.

Namespace: Amazon.CloudFormation
Assembly: AWSSDK.CloudFormation.dll
Version: 3.x.y.z

Syntax

C#
public virtual GetTemplateResponse GetTemplate(
         GetTemplateRequest request
)

Parameters

request
Type: Amazon.CloudFormation.Model.GetTemplateRequest

Container for the necessary parameters to execute the GetTemplate service method.

Return Value


The response from the GetTemplate service method, as returned by CloudFormation.

Exceptions

ExceptionCondition
ChangeSetNotFoundException The specified change set name or ID doesn't exit. To view valid change sets for a stack, use the ListChangeSets operation.

Version Information

.NET Framework:
Supported in: 4.5, 4.0, 3.5

See Also