1. Packages
  2. Packages
  3. Tencentcloud Provider
  4. API Docs
  5. PostgresqlRestoreDbInstanceObjectsOperation
Viewing docs for tencentcloud 1.82.93
published on Monday, May 11, 2026 by tencentcloudstack
Viewing docs for tencentcloud 1.82.93
published on Monday, May 11, 2026 by tencentcloudstack

    Example Usage

    Restore by backup set

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const example = new tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example", {
        dbInstanceId: "postgres-6bwgamo3",
        restoreObjects: ["user"],
        backupSetId: "your-backup-set-id",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    example = tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example",
        db_instance_id="postgres-6bwgamo3",
        restore_objects=["user"],
        backup_set_id="your-backup-set-id")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewPostgresqlRestoreDbInstanceObjectsOperation(ctx, "example", &tencentcloud.PostgresqlRestoreDbInstanceObjectsOperationArgs{
    			DbInstanceId: pulumi.String("postgres-6bwgamo3"),
    			RestoreObjects: pulumi.StringArray{
    				pulumi.String("user"),
    			},
    			BackupSetId: pulumi.String("your-backup-set-id"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example", new()
        {
            DbInstanceId = "postgres-6bwgamo3",
            RestoreObjects = new[]
            {
                "user",
            },
            BackupSetId = "your-backup-set-id",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation;
    import com.pulumi.tencentcloud.PostgresqlRestoreDbInstanceObjectsOperationArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new PostgresqlRestoreDbInstanceObjectsOperation("example", PostgresqlRestoreDbInstanceObjectsOperationArgs.builder()
                .dbInstanceId("postgres-6bwgamo3")
                .restoreObjects("user")
                .backupSetId("your-backup-set-id")
                .build());
    
        }
    }
    
    resources:
      example:
        type: tencentcloud:PostgresqlRestoreDbInstanceObjectsOperation
        properties:
          dbInstanceId: postgres-6bwgamo3
          restoreObjects:
            - user
          backupSetId: your-backup-set-id
    
    Example coming soon!
    

    Restore by point-in-time

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const example = new tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example", {
        dbInstanceId: "postgres-6bwgamo3",
        restoreObjects: [
            "user",
            "orders",
        ],
        restoreTargetTime: "2024-04-30 00:20:27",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    example = tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example",
        db_instance_id="postgres-6bwgamo3",
        restore_objects=[
            "user",
            "orders",
        ],
        restore_target_time="2024-04-30 00:20:27")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewPostgresqlRestoreDbInstanceObjectsOperation(ctx, "example", &tencentcloud.PostgresqlRestoreDbInstanceObjectsOperationArgs{
    			DbInstanceId: pulumi.String("postgres-6bwgamo3"),
    			RestoreObjects: pulumi.StringArray{
    				pulumi.String("user"),
    				pulumi.String("orders"),
    			},
    			RestoreTargetTime: pulumi.String("2024-04-30 00:20:27"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation("example", new()
        {
            DbInstanceId = "postgres-6bwgamo3",
            RestoreObjects = new[]
            {
                "user",
                "orders",
            },
            RestoreTargetTime = "2024-04-30 00:20:27",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.PostgresqlRestoreDbInstanceObjectsOperation;
    import com.pulumi.tencentcloud.PostgresqlRestoreDbInstanceObjectsOperationArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new PostgresqlRestoreDbInstanceObjectsOperation("example", PostgresqlRestoreDbInstanceObjectsOperationArgs.builder()
                .dbInstanceId("postgres-6bwgamo3")
                .restoreObjects(            
                    "user",
                    "orders")
                .restoreTargetTime("2024-04-30 00:20:27")
                .build());
    
        }
    }
    
    resources:
      example:
        type: tencentcloud:PostgresqlRestoreDbInstanceObjectsOperation
        properties:
          dbInstanceId: postgres-6bwgamo3
          restoreObjects:
            - user
            - orders
          restoreTargetTime: 2024-04-30 00:20:27
    
    Example coming soon!
    

    Create PostgresqlRestoreDbInstanceObjectsOperation Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new PostgresqlRestoreDbInstanceObjectsOperation(name: string, args: PostgresqlRestoreDbInstanceObjectsOperationArgs, opts?: CustomResourceOptions);
    @overload
    def PostgresqlRestoreDbInstanceObjectsOperation(resource_name: str,
                                                    args: PostgresqlRestoreDbInstanceObjectsOperationArgs,
                                                    opts: Optional[ResourceOptions] = None)
    
    @overload
    def PostgresqlRestoreDbInstanceObjectsOperation(resource_name: str,
                                                    opts: Optional[ResourceOptions] = None,
                                                    db_instance_id: Optional[str] = None,
                                                    restore_objects: Optional[Sequence[str]] = None,
                                                    backup_set_id: Optional[str] = None,
                                                    postgresql_restore_db_instance_objects_operation_id: Optional[str] = None,
                                                    restore_target_time: Optional[str] = None,
                                                    timeouts: Optional[PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs] = None)
    func NewPostgresqlRestoreDbInstanceObjectsOperation(ctx *Context, name string, args PostgresqlRestoreDbInstanceObjectsOperationArgs, opts ...ResourceOption) (*PostgresqlRestoreDbInstanceObjectsOperation, error)
    public PostgresqlRestoreDbInstanceObjectsOperation(string name, PostgresqlRestoreDbInstanceObjectsOperationArgs args, CustomResourceOptions? opts = null)
    public PostgresqlRestoreDbInstanceObjectsOperation(String name, PostgresqlRestoreDbInstanceObjectsOperationArgs args)
    public PostgresqlRestoreDbInstanceObjectsOperation(String name, PostgresqlRestoreDbInstanceObjectsOperationArgs args, CustomResourceOptions options)
    
    type: tencentcloud:PostgresqlRestoreDbInstanceObjectsOperation
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "tencentcloud_postgresqlrestoredbinstanceobjectsoperation" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args PostgresqlRestoreDbInstanceObjectsOperationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args PostgresqlRestoreDbInstanceObjectsOperationArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args PostgresqlRestoreDbInstanceObjectsOperationArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PostgresqlRestoreDbInstanceObjectsOperationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PostgresqlRestoreDbInstanceObjectsOperationArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    PostgresqlRestoreDbInstanceObjectsOperation Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The PostgresqlRestoreDbInstanceObjectsOperation resource accepts the following input properties:

    DbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    RestoreObjects List<string>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    BackupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    PostgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    RestoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    Timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    DbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    RestoreObjects []string
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    BackupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    PostgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    RestoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    Timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs
    db_instance_id string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    restore_objects list(string)
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    backup_set_id string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    postgresql_restore_db_instance_objects_operation_id string
    ID of the resource.
    restore_target_time string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts object
    dbInstanceId String
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    restoreObjects List<String>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    backupSetId String
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    postgresqlRestoreDbInstanceObjectsOperationId String
    ID of the resource.
    restoreTargetTime String
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    dbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    restoreObjects string[]
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    backupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    postgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    restoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    db_instance_id str
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    restore_objects Sequence[str]
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    backup_set_id str
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    postgresql_restore_db_instance_objects_operation_id str
    ID of the resource.
    restore_target_time str
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs
    dbInstanceId String
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    restoreObjects List<String>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    backupSetId String
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    postgresqlRestoreDbInstanceObjectsOperationId String
    ID of the resource.
    restoreTargetTime String
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts Property Map

    Outputs

    All input properties are implicitly available as output properties. Additionally, the PostgresqlRestoreDbInstanceObjectsOperation resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing PostgresqlRestoreDbInstanceObjectsOperation Resource

    Get an existing PostgresqlRestoreDbInstanceObjectsOperation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: PostgresqlRestoreDbInstanceObjectsOperationState, opts?: CustomResourceOptions): PostgresqlRestoreDbInstanceObjectsOperation
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            backup_set_id: Optional[str] = None,
            db_instance_id: Optional[str] = None,
            postgresql_restore_db_instance_objects_operation_id: Optional[str] = None,
            restore_objects: Optional[Sequence[str]] = None,
            restore_target_time: Optional[str] = None,
            timeouts: Optional[PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs] = None) -> PostgresqlRestoreDbInstanceObjectsOperation
    func GetPostgresqlRestoreDbInstanceObjectsOperation(ctx *Context, name string, id IDInput, state *PostgresqlRestoreDbInstanceObjectsOperationState, opts ...ResourceOption) (*PostgresqlRestoreDbInstanceObjectsOperation, error)
    public static PostgresqlRestoreDbInstanceObjectsOperation Get(string name, Input<string> id, PostgresqlRestoreDbInstanceObjectsOperationState? state, CustomResourceOptions? opts = null)
    public static PostgresqlRestoreDbInstanceObjectsOperation get(String name, Output<String> id, PostgresqlRestoreDbInstanceObjectsOperationState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:PostgresqlRestoreDbInstanceObjectsOperation    get:      id: ${id}
    import {
      to = tencentcloud_postgresqlrestoredbinstanceobjectsoperation.example
      id = "${id}"
    }
    
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    BackupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    DbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    PostgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    RestoreObjects List<string>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    RestoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    Timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    BackupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    DbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    PostgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    RestoreObjects []string
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    RestoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    Timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs
    backup_set_id string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    db_instance_id string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    postgresql_restore_db_instance_objects_operation_id string
    ID of the resource.
    restore_objects list(string)
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    restore_target_time string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts object
    backupSetId String
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    dbInstanceId String
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    postgresqlRestoreDbInstanceObjectsOperationId String
    ID of the resource.
    restoreObjects List<String>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    restoreTargetTime String
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    backupSetId string
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    dbInstanceId string
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    postgresqlRestoreDbInstanceObjectsOperationId string
    ID of the resource.
    restoreObjects string[]
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    restoreTargetTime string
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeouts
    backup_set_id str
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    db_instance_id str
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    postgresql_restore_db_instance_objects_operation_id str
    ID of the resource.
    restore_objects Sequence[str]
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    restore_target_time str
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs
    backupSetId String
    Backup set ID used for restoration. Exactly one of backup_set_id or restore_target_time must be specified.
    dbInstanceId String
    PostgreSQL instance ID, e.g. postgres-6bwgamo3.
    postgresqlRestoreDbInstanceObjectsOperationId String
    ID of the resource.
    restoreObjects List<String>
    List of database objects to restore. The restored object name format will be ${original}_bak_${timestamp}.
    restoreTargetTime String
    Point-in-time target for restoration (Beijing time), e.g. 2024-04-30 00:20:27. Exactly one of backup_set_id or restore_target_time must be specified.
    timeouts Property Map

    Supporting Types

    PostgresqlRestoreDbInstanceObjectsOperationTimeouts, PostgresqlRestoreDbInstanceObjectsOperationTimeoutsArgs

    Create string
    Create string
    create string
    create String
    create string
    create str
    create String

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    Viewing docs for tencentcloud 1.82.93
    published on Monday, May 11, 2026 by tencentcloudstack
      Try Pulumi Cloud free. Your team will thank you.