import { Command as $Command } from "@smithy/core/client"; import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { CopyDBSnapshotMessage, CopyDBSnapshotResult } from "../models/models_0"; import type { RDSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../RDSClient"; /** * @public */ export type { __MetadataBearer }; export { $Command }; /** * @public * * The input for {@link CopyDBSnapshotCommand}. */ export interface CopyDBSnapshotCommandInput extends CopyDBSnapshotMessage { } /** * @public * * The output of {@link CopyDBSnapshotCommand}. */ export interface CopyDBSnapshotCommandOutput extends CopyDBSnapshotResult, __MetadataBearer { } declare const CopyDBSnapshotCommand_base: { new (input: CopyDBSnapshotCommandInput): import("@smithy/core/client").CommandImpl; new (input: CopyDBSnapshotCommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): { [x: string]: unknown; }; }; /** *

Copies the specified DB snapshot. The source DB snapshot must be in the available state.

You can copy a snapshot from one Amazon Web Services Region to another. In that case, the Amazon Web Services Region where you call the CopyDBSnapshot operation is the destination Amazon Web Services Region for the DB snapshot copy.

This command doesn't apply to RDS Custom.

For more information about copying snapshots, see Copying a DB Snapshot in the Amazon RDS User Guide.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { RDSClient, CopyDBSnapshotCommand } from "@aws-sdk/client-rds"; // ES Modules import * // const { RDSClient, CopyDBSnapshotCommand } = require("@aws-sdk/client-rds"); // CommonJS import * // import type { RDSClientConfig } from "@aws-sdk/client-rds"; * const config = {}; // type is RDSClientConfig * const client = new RDSClient(config); * const input = { // CopyDBSnapshotMessage * SourceDBSnapshotIdentifier: "STRING_VALUE", // required * TargetDBSnapshotIdentifier: "STRING_VALUE", // required * KmsKeyId: "STRING_VALUE", * Tags: [ // TagList * { // Tag * Key: "STRING_VALUE", * Value: "STRING_VALUE", * }, * ], * CopyTags: true || false, * PreSignedUrl: "STRING_VALUE", * OptionGroupName: "STRING_VALUE", * TargetCustomAvailabilityZone: "STRING_VALUE", * SnapshotTarget: "STRING_VALUE", * CopyOptionGroup: true || false, * SnapshotAvailabilityZone: "STRING_VALUE", * }; * const command = new CopyDBSnapshotCommand(input); * const response = await client.send(command); * // { // CopyDBSnapshotResult * // DBSnapshot: { // DBSnapshot * // DBSnapshotIdentifier: "STRING_VALUE", * // DBInstanceIdentifier: "STRING_VALUE", * // SnapshotCreateTime: new Date("TIMESTAMP"), * // Engine: "STRING_VALUE", * // AllocatedStorage: Number("int"), * // Status: "STRING_VALUE", * // Port: Number("int"), * // AvailabilityZone: "STRING_VALUE", * // VpcId: "STRING_VALUE", * // InstanceCreateTime: new Date("TIMESTAMP"), * // MasterUsername: "STRING_VALUE", * // EngineVersion: "STRING_VALUE", * // LicenseModel: "STRING_VALUE", * // SnapshotType: "STRING_VALUE", * // Iops: Number("int"), * // StorageThroughput: Number("int"), * // OptionGroupName: "STRING_VALUE", * // PercentProgress: Number("int"), * // SourceRegion: "STRING_VALUE", * // SourceDBSnapshotIdentifier: "STRING_VALUE", * // StorageType: "STRING_VALUE", * // TdeCredentialArn: "STRING_VALUE", * // Encrypted: true || false, * // StorageEncryptionType: "none" || "sse-kms" || "sse-rds", * // BackupRetentionPeriod: Number("int"), * // PreferredBackupWindow: "STRING_VALUE", * // KmsKeyId: "STRING_VALUE", * // DBSnapshotArn: "STRING_VALUE", * // Timezone: "STRING_VALUE", * // IAMDatabaseAuthenticationEnabled: true || false, * // ProcessorFeatures: [ // ProcessorFeatureList * // { // ProcessorFeature * // Name: "STRING_VALUE", * // Value: "STRING_VALUE", * // }, * // ], * // DbiResourceId: "STRING_VALUE", * // TagList: [ // TagList * // { // Tag * // Key: "STRING_VALUE", * // Value: "STRING_VALUE", * // }, * // ], * // SnapshotTarget: "STRING_VALUE", * // OriginalSnapshotCreateTime: new Date("TIMESTAMP"), * // SnapshotDatabaseTime: new Date("TIMESTAMP"), * // DBSystemId: "STRING_VALUE", * // MultiTenant: true || false, * // DedicatedLogVolume: true || false, * // AdditionalStorageVolumes: [ // AdditionalStorageVolumesList * // { // AdditionalStorageVolume * // VolumeName: "STRING_VALUE", // required * // AllocatedStorage: Number("int"), * // IOPS: Number("int"), * // MaxAllocatedStorage: Number("int"), * // StorageThroughput: Number("int"), * // StorageType: "STRING_VALUE", * // }, * // ], * // SnapshotAvailabilityZone: "STRING_VALUE", * // }, * // }; * * ``` * * @param CopyDBSnapshotCommandInput - {@link CopyDBSnapshotCommandInput} * @returns {@link CopyDBSnapshotCommandOutput} * @see {@link CopyDBSnapshotCommandInput} for command's `input` shape. * @see {@link CopyDBSnapshotCommandOutput} for command's `response` shape. * @see {@link RDSClientResolvedConfig | config} for RDSClient's `config` shape. * * @throws {@link CustomAvailabilityZoneNotFoundFault} (client fault) *

CustomAvailabilityZoneId doesn't refer to an existing custom Availability Zone identifier.

* * @throws {@link DBSnapshotAlreadyExistsFault} (client fault) *

DBSnapshotIdentifier is already used by an existing snapshot.

* * @throws {@link DBSnapshotNotFoundFault} (client fault) *

DBSnapshotIdentifier doesn't refer to an existing DB snapshot.

* * @throws {@link InvalidDBSnapshotStateFault} (client fault) *

The state of the DB snapshot doesn't allow deletion.

* * @throws {@link KMSKeyNotAccessibleFault} (client fault) *

An error occurred accessing an Amazon Web Services KMS key.

* * @throws {@link SnapshotQuotaExceededFault} (client fault) *

The request would result in the user exceeding the allowed number of DB snapshots.

* * @throws {@link RDSServiceException} *

Base exception class for all service exceptions from RDS service.

* * * @example To copy a DB snapshot * ```javascript * // The following example creates a copy of a DB snapshot. * const input = { * SourceDBSnapshotIdentifier: "rds:database-mysql-2019-06-06-08-38", * TargetDBSnapshotIdentifier: "mydbsnapshotcopy" * }; * const command = new CopyDBSnapshotCommand(input); * const response = await client.send(command); * /* response is * { * DBSnapshot: { * AllocatedStorage: 100, * AvailabilityZone: "us-east-1f", * DBInstanceIdentifier: "database-mysql", * DBSnapshotArn: "arn:aws:rds:us-east-1:123456789012:snapshot:mydbsnapshotcopy", * DBSnapshotIdentifier: "mydbsnapshotcopy", * DbiResourceId: "db-ZI7UJ5BLKMBYFGX7FDENCKADC4", * Encrypted: true, * Engine: "mysql", * EngineVersion: "5.6.40", * IAMDatabaseAuthenticationEnabled: false, * InstanceCreateTime: "2019-04-30T15:45:53.663Z", * Iops: 1000, * KmsKeyId: "arn:aws:kms:us-east-1:123456789012:key/AKIAIOSFODNN7EXAMPLE", * LicenseModel: "general-public-license", * MasterUsername: "admin", * OptionGroupName: "default:mysql-5-6", * PercentProgress: 0, * Port: 3306, * ProcessorFeatures: [], * SnapshotType: "manual", * SourceDBSnapshotIdentifier: "arn:aws:rds:us-east-1:123456789012:snapshot:rds:database-mysql-2019-06-06-08-38", * SourceRegion: "us-east-1", * Status: "creating", * StorageType: "io1", * VpcId: "vpc-6594f31c" * } * } * *\/ * ``` * * @public */ export declare class CopyDBSnapshotCommand extends CopyDBSnapshotCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: CopyDBSnapshotMessage; output: CopyDBSnapshotResult; }; sdk: { input: CopyDBSnapshotCommandInput; output: CopyDBSnapshotCommandOutput; }; }; }