libZSservicesZSamazonka-cloudformationZSamazonka-cloudformation
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.CloudFormation.GetTemplate

Description

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 does not exist, a ValidationError is returned.

Synopsis

Creating a Request

data GetTemplate Source #

The input for a GetTemplate action.

See: newGetTemplate smart constructor.

Constructors

GetTemplate' 

Fields

  • changeSetName :: Maybe Text

    The name or Amazon Resource Name (ARN) of a change set for which CloudFormation returns the associated template. If you specify a name, you must also specify the StackName.

  • templateStage :: Maybe TemplateStage

    For templates that include transforms, the stage of the template that CloudFormation returns. To get the user-submitted template, specify Original. To get the template after CloudFormation has processed all transforms, specify Processed.

    If the template doesn't include transforms, Original and Processed return the same template. By default, CloudFormation specifies Processed.

  • stackName :: Maybe Text

    The name or the unique stack ID that is associated with the stack, which are not always interchangeable:

    • Running stacks: You can specify either the stack's name or its unique stack ID.
    • Deleted stacks: You must specify the unique stack ID.

    Default: There is no default value.

Instances

Instances details
Eq GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Read GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Show GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Generic GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Associated Types

type Rep GetTemplate :: Type -> Type #

NFData GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Methods

rnf :: GetTemplate -> () #

Hashable GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

AWSRequest GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Associated Types

type AWSResponse GetTemplate #

ToHeaders GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Methods

toHeaders :: GetTemplate -> [Header] #

ToPath GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

ToQuery GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

type Rep GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

type Rep GetTemplate = D1 ('MetaData "GetTemplate" "Amazonka.CloudFormation.GetTemplate" "libZSservicesZSamazonka-cloudformationZSamazonka-cloudformation" 'False) (C1 ('MetaCons "GetTemplate'" 'PrefixI 'True) (S1 ('MetaSel ('Just "changeSetName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "templateStage") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe TemplateStage)) :*: S1 ('MetaSel ('Just "stackName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)))))
type AWSResponse GetTemplate Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

newGetTemplate :: GetTemplate Source #

Create a value of GetTemplate with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:changeSetName:GetTemplate', getTemplate_changeSetName - The name or Amazon Resource Name (ARN) of a change set for which CloudFormation returns the associated template. If you specify a name, you must also specify the StackName.

$sel:templateStage:GetTemplate', getTemplate_templateStage - For templates that include transforms, the stage of the template that CloudFormation returns. To get the user-submitted template, specify Original. To get the template after CloudFormation has processed all transforms, specify Processed.

If the template doesn't include transforms, Original and Processed return the same template. By default, CloudFormation specifies Processed.

$sel:stackName:GetTemplate', getTemplate_stackName - The name or the unique stack ID that is associated with the stack, which are not always interchangeable:

  • Running stacks: You can specify either the stack's name or its unique stack ID.
  • Deleted stacks: You must specify the unique stack ID.

Default: There is no default value.

Request Lenses

getTemplate_changeSetName :: Lens' GetTemplate (Maybe Text) Source #

The name or Amazon Resource Name (ARN) of a change set for which CloudFormation returns the associated template. If you specify a name, you must also specify the StackName.

getTemplate_templateStage :: Lens' GetTemplate (Maybe TemplateStage) Source #

For templates that include transforms, the stage of the template that CloudFormation returns. To get the user-submitted template, specify Original. To get the template after CloudFormation has processed all transforms, specify Processed.

If the template doesn't include transforms, Original and Processed return the same template. By default, CloudFormation specifies Processed.

getTemplate_stackName :: Lens' GetTemplate (Maybe Text) Source #

The name or the unique stack ID that is associated with the stack, which are not always interchangeable:

  • Running stacks: You can specify either the stack's name or its unique stack ID.
  • Deleted stacks: You must specify the unique stack ID.

Default: There is no default value.

Destructuring the Response

data GetTemplateResponse Source #

The output for GetTemplate action.

See: newGetTemplateResponse smart constructor.

Constructors

GetTemplateResponse' 

Fields

  • stagesAvailable :: Maybe [TemplateStage]

    The stage of the template that you can retrieve. For stacks, the Original and Processed templates are always available. For change sets, the Original template is always available. After CloudFormation finishes creating the change set, the Processed template becomes available.

  • templateBody :: Maybe Text

    Structure containing the template body. (For more information, go to Template Anatomy in the CloudFormation User Guide.)

    CloudFormation returns the same template that was used when the stack was created.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Eq GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Read GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Show GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Generic GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Associated Types

type Rep GetTemplateResponse :: Type -> Type #

NFData GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

Methods

rnf :: GetTemplateResponse -> () #

type Rep GetTemplateResponse Source # 
Instance details

Defined in Amazonka.CloudFormation.GetTemplate

type Rep GetTemplateResponse = D1 ('MetaData "GetTemplateResponse" "Amazonka.CloudFormation.GetTemplate" "libZSservicesZSamazonka-cloudformationZSamazonka-cloudformation" 'False) (C1 ('MetaCons "GetTemplateResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "stagesAvailable") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [TemplateStage])) :*: (S1 ('MetaSel ('Just "templateBody") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newGetTemplateResponse Source #

Create a value of GetTemplateResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:stagesAvailable:GetTemplateResponse', getTemplateResponse_stagesAvailable - The stage of the template that you can retrieve. For stacks, the Original and Processed templates are always available. For change sets, the Original template is always available. After CloudFormation finishes creating the change set, the Processed template becomes available.

$sel:templateBody:GetTemplateResponse', getTemplateResponse_templateBody - Structure containing the template body. (For more information, go to Template Anatomy in the CloudFormation User Guide.)

CloudFormation returns the same template that was used when the stack was created.

$sel:httpStatus:GetTemplateResponse', getTemplateResponse_httpStatus - The response's http status code.

Response Lenses

getTemplateResponse_stagesAvailable :: Lens' GetTemplateResponse (Maybe [TemplateStage]) Source #

The stage of the template that you can retrieve. For stacks, the Original and Processed templates are always available. For change sets, the Original template is always available. After CloudFormation finishes creating the change set, the Processed template becomes available.

getTemplateResponse_templateBody :: Lens' GetTemplateResponse (Maybe Text) Source #

Structure containing the template body. (For more information, go to Template Anatomy in the CloudFormation User Guide.)

CloudFormation returns the same template that was used when the stack was created.