- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
SetTypeDefaultVersionCommand
Specify the default version of an extension. The default version of an extension will be used in CloudFormation operations.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { CloudFormationClient, SetTypeDefaultVersionCommand } from "@aws-sdk/client-cloudformation"; // ES Modules import
// const { CloudFormationClient, SetTypeDefaultVersionCommand } = require("@aws-sdk/client-cloudformation"); // CommonJS import
const client = new CloudFormationClient(config);
const input = { // SetTypeDefaultVersionInput
Arn: "STRING_VALUE",
Type: "RESOURCE" || "MODULE" || "HOOK",
TypeName: "STRING_VALUE",
VersionId: "STRING_VALUE",
};
const command = new SetTypeDefaultVersionCommand(input);
const response = await client.send(command);
// {};
SetTypeDefaultVersionCommand Input
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
Arn | string | undefined | The Amazon Resource Name (ARN) of the extension for which you want version summary information. Conditional: You must specify either |
Type | RegistryType | undefined | The kind of extension. Conditional: You must specify either |
TypeName | string | undefined | The name of the extension. Conditional: You must specify either |
VersionId | string | undefined | The ID of a specific version of the extension. The version ID is the value at the end of the Amazon Resource Name (ARN) assigned to the extension version when it is registered. |
SetTypeDefaultVersionCommand Output
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
CFNRegistryException | client | An error occurred during a CloudFormation registry operation. |
TypeNotFoundException | client | The specified extension doesn't exist in the CloudFormation registry. |
CloudFormationServiceException | Base exception class for all service exceptions from CloudFormation service. |