UpdateTemplate - Amazon QuickSight

UpdateTemplate

Updates a template from an existing Amazon QuickSight analysis or another template.

Request Syntax

PUT /accounts/AwsAccountId/templates/TemplateId HTTP/1.1 Content-type: application/json { "Definition": { "AnalysisDefaults": { "DefaultNewSheetConfiguration": { ... } }, "CalculatedFields": [ { ... } ], "ColumnConfigurations": [ { ... } ], "DataSetConfigurations": [ { ... } ], "FilterGroups": [ { ... } ], "Options": { "Timezone": "string", "WeekStart": "string" }, "ParameterDeclarations": [ { ... } ], "QueryExecutionOptions": { "QueryExecutionMode": "string" }, "Sheets": [ { ... } ] }, "Name": "string", "SourceEntity": { "SourceAnalysis": { "Arn": "string", "DataSetReferences": [ { "DataSetArn": "string", "DataSetPlaceholder": "string" } ] }, "SourceTemplate": { "Arn": "string" } }, "ValidationStrategy": { "Mode": "string" }, "VersionDescription": "string" }

URI Request Parameters

The request uses the following URI parameters.

AwsAccountId

The ID of the AWS account that contains the template that you're updating.

Length Constraints: Fixed length of 12.

Pattern: ^[0-9]{12}$

Required: Yes

TemplateId

The ID for the template.

Length Constraints: Minimum length of 1. Maximum length of 512.

Pattern: [\w\-]+

Required: Yes

Request Body

The request accepts the following data in JSON format.

Definition

The definition of a template.

A definition is the data model of all features in a Dashboard, Template, or Analysis.

Type: TemplateVersionDefinition object

Required: No

Name

The name for the template.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 2048.

Required: No

SourceEntity

The entity that you are using as a source when you update the template. In SourceEntity, you specify the type of object you're using as source: SourceTemplate for a template or SourceAnalysis for an analysis. Both of these require an Amazon Resource Name (ARN). For SourceTemplate, specify the ARN of the source template. For SourceAnalysis, specify the ARN of the source analysis. The SourceTemplate ARN can contain any AWS account and any Amazon QuickSight-supported AWS Region;.

Use the DataSetReferences entity within SourceTemplate or SourceAnalysis to list the replacement datasets for the placeholders listed in the original. The schema in each dataset must match its placeholder.

Type: TemplateSourceEntity object

Required: No

ValidationStrategy

The option to relax the validation needed to update a template with definition objects. This skips the validation step for specific errors.

Type: ValidationStrategy object

Required: No

VersionDescription

A description of the current template version that is being updated. Every time you call UpdateTemplate, you create a new version of the template. Each version of the template maintains a description of the version in the VersionDescription field.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 512.

Required: No

Response Syntax

HTTP/1.1 Status Content-type: application/json { "Arn": "string", "CreationStatus": "string", "RequestId": "string", "TemplateId": "string", "VersionArn": "string" }

Response Elements

If the action is successful, the service sends back the following HTTP response.

Status

The HTTP status of the request.

The following data is returned in JSON format by the service.

Arn

The Amazon Resource Name (ARN) for the template.

Type: String

CreationStatus

The creation status of the template.

Type: String

Valid Values: CREATION_IN_PROGRESS | CREATION_SUCCESSFUL | CREATION_FAILED | UPDATE_IN_PROGRESS | UPDATE_SUCCESSFUL | UPDATE_FAILED | DELETED

RequestId

The AWS request ID for this operation.

Type: String

TemplateId

The ID for the template.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 512.

Pattern: [\w\-]+

VersionArn

The ARN for the template, including the version information of the first version.

Type: String

Errors

For information about the errors that are common to all actions, see Common Errors.

ConflictException

Updating or deleting a resource can cause an inconsistent state.

HTTP Status Code: 409

InternalFailureException

An internal failure occurred.

HTTP Status Code: 500

InvalidParameterValueException

One or more parameters has a value that isn't valid.

HTTP Status Code: 400

LimitExceededException

A limit is exceeded.

HTTP Status Code: 409

ResourceExistsException

The resource specified already exists.

HTTP Status Code: 409

ResourceNotFoundException

One or more resources can't be found.

HTTP Status Code: 404

ThrottlingException

Access is throttled.

HTTP Status Code: 429

UnsupportedUserEditionException

This error indicates that you are calling an operation on an Amazon QuickSight subscription where the edition doesn't include support for that operation. Amazon Amazon QuickSight currently has Standard Edition and Enterprise Edition. Not every operation and capability is available in every edition.

HTTP Status Code: 403

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: