Skip to content

DocDBElasticClient#

Index > DocDBElastic > DocDBElasticClient

Auto-generated documentation for DocDBElastic type annotations stubs module mypy-boto3-docdb-elastic.

DocDBElasticClient#

Type annotations and code completion for boto3.client("docdb-elastic"). boto3 documentation

# DocDBElasticClient usage example

from boto3.session import Session
from mypy_boto3_docdb_elastic.client import DocDBElasticClient

def get_docdb-elastic_client() -> DocDBElasticClient:
    return Session().client("docdb-elastic")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("docdb-elastic").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("docdb-elastic")

try:
    do_something(client)
except (
    client.exceptions.AccessDeniedException,
    client.exceptions.ClientError,
    client.exceptions.ConflictException,
    client.exceptions.InternalServerException,
    client.exceptions.ResourceNotFoundException,
    client.exceptions.ServiceQuotaExceededException,
    client.exceptions.ThrottlingException,
    client.exceptions.ValidationException,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_docdb_elastic.client import Exceptions

def handle_error(exc: Exceptions.AccessDeniedException) -> None:
    ...

Methods#

can_paginate#

Type annotations and code completion for boto3.client("docdb-elastic").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

generate_presigned_url#

Type annotations and code completion for boto3.client("docdb-elastic").generate_presigned_url method. boto3 documentation

# generate_presigned_url method definition

def generate_presigned_url(
    self,
    ClientMethod: str,
    Params: Mapping[str, Any] = ...,
    ExpiresIn: int = 3600,
    HttpMethod: str = ...,
) -> str:
    ...

apply_pending_maintenance_action#

The type of pending maintenance action to be applied to the resource.

Type annotations and code completion for boto3.client("docdb-elastic").apply_pending_maintenance_action method. boto3 documentation

# apply_pending_maintenance_action method definition

def apply_pending_maintenance_action(
    self,
    *,
    applyAction: str,
    optInType: OptInTypeType,  # (1)
    resourceArn: str,
    applyOn: str = ...,
) -> ApplyPendingMaintenanceActionOutputTypeDef:  # (2)
    ...
  1. See OptInTypeType
  2. See ApplyPendingMaintenanceActionOutputTypeDef
# apply_pending_maintenance_action method usage example with argument unpacking

kwargs: ApplyPendingMaintenanceActionInputRequestTypeDef = {  # (1)
    "applyAction": ...,
    "optInType": ...,
    "resourceArn": ...,
}

parent.apply_pending_maintenance_action(**kwargs)
  1. See ApplyPendingMaintenanceActionInputRequestTypeDef

copy_cluster_snapshot#

Copies a snapshot of an elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").copy_cluster_snapshot method. boto3 documentation

# copy_cluster_snapshot method definition

def copy_cluster_snapshot(
    self,
    *,
    snapshotArn: str,
    targetSnapshotName: str,
    copyTags: bool = ...,
    kmsKeyId: str = ...,
    tags: Mapping[str, str] = ...,
) -> CopyClusterSnapshotOutputTypeDef:  # (1)
    ...
  1. See CopyClusterSnapshotOutputTypeDef
# copy_cluster_snapshot method usage example with argument unpacking

kwargs: CopyClusterSnapshotInputRequestTypeDef = {  # (1)
    "snapshotArn": ...,
    "targetSnapshotName": ...,
}

parent.copy_cluster_snapshot(**kwargs)
  1. See CopyClusterSnapshotInputRequestTypeDef

create_cluster#

Creates a new Amazon DocumentDB elastic cluster and returns its cluster structure.

Type annotations and code completion for boto3.client("docdb-elastic").create_cluster method. boto3 documentation

# create_cluster method definition

def create_cluster(
    self,
    *,
    adminUserName: str,
    adminUserPassword: str,
    authType: AuthType,  # (1)
    clusterName: str,
    shardCapacity: int,
    shardCount: int,
    backupRetentionPeriod: int = ...,
    clientToken: str = ...,
    kmsKeyId: str = ...,
    preferredBackupWindow: str = ...,
    preferredMaintenanceWindow: str = ...,
    shardInstanceCount: int = ...,
    subnetIds: Sequence[str] = ...,
    tags: Mapping[str, str] = ...,
    vpcSecurityGroupIds: Sequence[str] = ...,
) -> CreateClusterOutputTypeDef:  # (2)
    ...
  1. See AuthType
  2. See CreateClusterOutputTypeDef
# create_cluster method usage example with argument unpacking

kwargs: CreateClusterInputRequestTypeDef = {  # (1)
    "adminUserName": ...,
    "adminUserPassword": ...,
    "authType": ...,
    "clusterName": ...,
    "shardCapacity": ...,
    "shardCount": ...,
}

parent.create_cluster(**kwargs)
  1. See CreateClusterInputRequestTypeDef

create_cluster_snapshot#

Creates a snapshot of an elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").create_cluster_snapshot method. boto3 documentation

# create_cluster_snapshot method definition

def create_cluster_snapshot(
    self,
    *,
    clusterArn: str,
    snapshotName: str,
    tags: Mapping[str, str] = ...,
) -> CreateClusterSnapshotOutputTypeDef:  # (1)
    ...
  1. See CreateClusterSnapshotOutputTypeDef
# create_cluster_snapshot method usage example with argument unpacking

kwargs: CreateClusterSnapshotInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
    "snapshotName": ...,
}

parent.create_cluster_snapshot(**kwargs)
  1. See CreateClusterSnapshotInputRequestTypeDef

delete_cluster#

Delete an elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").delete_cluster method. boto3 documentation

# delete_cluster method definition

def delete_cluster(
    self,
    *,
    clusterArn: str,
) -> DeleteClusterOutputTypeDef:  # (1)
    ...
  1. See DeleteClusterOutputTypeDef
# delete_cluster method usage example with argument unpacking

kwargs: DeleteClusterInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.delete_cluster(**kwargs)
  1. See DeleteClusterInputRequestTypeDef

delete_cluster_snapshot#

Delete an elastic cluster snapshot.

Type annotations and code completion for boto3.client("docdb-elastic").delete_cluster_snapshot method. boto3 documentation

# delete_cluster_snapshot method definition

def delete_cluster_snapshot(
    self,
    *,
    snapshotArn: str,
) -> DeleteClusterSnapshotOutputTypeDef:  # (1)
    ...
  1. See DeleteClusterSnapshotOutputTypeDef
# delete_cluster_snapshot method usage example with argument unpacking

kwargs: DeleteClusterSnapshotInputRequestTypeDef = {  # (1)
    "snapshotArn": ...,
}

parent.delete_cluster_snapshot(**kwargs)
  1. See DeleteClusterSnapshotInputRequestTypeDef

get_cluster#

Returns information about a specific elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").get_cluster method. boto3 documentation

# get_cluster method definition

def get_cluster(
    self,
    *,
    clusterArn: str,
) -> GetClusterOutputTypeDef:  # (1)
    ...
  1. See GetClusterOutputTypeDef
# get_cluster method usage example with argument unpacking

kwargs: GetClusterInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.get_cluster(**kwargs)
  1. See GetClusterInputRequestTypeDef

get_cluster_snapshot#

Returns information about a specific elastic cluster snapshot.

Type annotations and code completion for boto3.client("docdb-elastic").get_cluster_snapshot method. boto3 documentation

# get_cluster_snapshot method definition

def get_cluster_snapshot(
    self,
    *,
    snapshotArn: str,
) -> GetClusterSnapshotOutputTypeDef:  # (1)
    ...
  1. See GetClusterSnapshotOutputTypeDef
# get_cluster_snapshot method usage example with argument unpacking

kwargs: GetClusterSnapshotInputRequestTypeDef = {  # (1)
    "snapshotArn": ...,
}

parent.get_cluster_snapshot(**kwargs)
  1. See GetClusterSnapshotInputRequestTypeDef

get_pending_maintenance_action#

Retrieves all maintenance actions that are pending.

Type annotations and code completion for boto3.client("docdb-elastic").get_pending_maintenance_action method. boto3 documentation

# get_pending_maintenance_action method definition

def get_pending_maintenance_action(
    self,
    *,
    resourceArn: str,
) -> GetPendingMaintenanceActionOutputTypeDef:  # (1)
    ...
  1. See GetPendingMaintenanceActionOutputTypeDef
# get_pending_maintenance_action method usage example with argument unpacking

kwargs: GetPendingMaintenanceActionInputRequestTypeDef = {  # (1)
    "resourceArn": ...,
}

parent.get_pending_maintenance_action(**kwargs)
  1. See GetPendingMaintenanceActionInputRequestTypeDef

list_cluster_snapshots#

Returns information about snapshots for a specified elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").list_cluster_snapshots method. boto3 documentation

# list_cluster_snapshots method definition

def list_cluster_snapshots(
    self,
    *,
    clusterArn: str = ...,
    maxResults: int = ...,
    nextToken: str = ...,
    snapshotType: str = ...,
) -> ListClusterSnapshotsOutputTypeDef:  # (1)
    ...
  1. See ListClusterSnapshotsOutputTypeDef
# list_cluster_snapshots method usage example with argument unpacking

kwargs: ListClusterSnapshotsInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.list_cluster_snapshots(**kwargs)
  1. See ListClusterSnapshotsInputRequestTypeDef

list_clusters#

Returns information about provisioned Amazon DocumentDB elastic clusters.

Type annotations and code completion for boto3.client("docdb-elastic").list_clusters method. boto3 documentation

# list_clusters method definition

def list_clusters(
    self,
    *,
    maxResults: int = ...,
    nextToken: str = ...,
) -> ListClustersOutputTypeDef:  # (1)
    ...
  1. See ListClustersOutputTypeDef
# list_clusters method usage example with argument unpacking

kwargs: ListClustersInputRequestTypeDef = {  # (1)
    "maxResults": ...,
}

parent.list_clusters(**kwargs)
  1. See ListClustersInputRequestTypeDef

list_pending_maintenance_actions#

Retrieves a list of all maintenance actions that are pending.

Type annotations and code completion for boto3.client("docdb-elastic").list_pending_maintenance_actions method. boto3 documentation

# list_pending_maintenance_actions method definition

def list_pending_maintenance_actions(
    self,
    *,
    maxResults: int = ...,
    nextToken: str = ...,
) -> ListPendingMaintenanceActionsOutputTypeDef:  # (1)
    ...
  1. See ListPendingMaintenanceActionsOutputTypeDef
# list_pending_maintenance_actions method usage example with argument unpacking

kwargs: ListPendingMaintenanceActionsInputRequestTypeDef = {  # (1)
    "maxResults": ...,
}

parent.list_pending_maintenance_actions(**kwargs)
  1. See ListPendingMaintenanceActionsInputRequestTypeDef

list_tags_for_resource#

Lists all tags on a elastic cluster resource.

Type annotations and code completion for boto3.client("docdb-elastic").list_tags_for_resource method. boto3 documentation

# list_tags_for_resource method definition

def list_tags_for_resource(
    self,
    *,
    resourceArn: str,
) -> ListTagsForResourceResponseTypeDef:  # (1)
    ...
  1. See ListTagsForResourceResponseTypeDef
# list_tags_for_resource method usage example with argument unpacking

kwargs: ListTagsForResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
}

parent.list_tags_for_resource(**kwargs)
  1. See ListTagsForResourceRequestRequestTypeDef

restore_cluster_from_snapshot#

Restores an elastic cluster from a snapshot.

Type annotations and code completion for boto3.client("docdb-elastic").restore_cluster_from_snapshot method. boto3 documentation

# restore_cluster_from_snapshot method definition

def restore_cluster_from_snapshot(
    self,
    *,
    clusterName: str,
    snapshotArn: str,
    kmsKeyId: str = ...,
    shardCapacity: int = ...,
    shardInstanceCount: int = ...,
    subnetIds: Sequence[str] = ...,
    tags: Mapping[str, str] = ...,
    vpcSecurityGroupIds: Sequence[str] = ...,
) -> RestoreClusterFromSnapshotOutputTypeDef:  # (1)
    ...
  1. See RestoreClusterFromSnapshotOutputTypeDef
# restore_cluster_from_snapshot method usage example with argument unpacking

kwargs: RestoreClusterFromSnapshotInputRequestTypeDef = {  # (1)
    "clusterName": ...,
    "snapshotArn": ...,
}

parent.restore_cluster_from_snapshot(**kwargs)
  1. See RestoreClusterFromSnapshotInputRequestTypeDef

start_cluster#

Restarts the stopped elastic cluster that is specified by clusterARN.

Type annotations and code completion for boto3.client("docdb-elastic").start_cluster method. boto3 documentation

# start_cluster method definition

def start_cluster(
    self,
    *,
    clusterArn: str,
) -> StartClusterOutputTypeDef:  # (1)
    ...
  1. See StartClusterOutputTypeDef
# start_cluster method usage example with argument unpacking

kwargs: StartClusterInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.start_cluster(**kwargs)
  1. See StartClusterInputRequestTypeDef

stop_cluster#

Stops the running elastic cluster that is specified by clusterArn.

Type annotations and code completion for boto3.client("docdb-elastic").stop_cluster method. boto3 documentation

# stop_cluster method definition

def stop_cluster(
    self,
    *,
    clusterArn: str,
) -> StopClusterOutputTypeDef:  # (1)
    ...
  1. See StopClusterOutputTypeDef
# stop_cluster method usage example with argument unpacking

kwargs: StopClusterInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.stop_cluster(**kwargs)
  1. See StopClusterInputRequestTypeDef

tag_resource#

Adds metadata tags to an elastic cluster resource.

Type annotations and code completion for boto3.client("docdb-elastic").tag_resource method. boto3 documentation

# tag_resource method definition

def tag_resource(
    self,
    *,
    resourceArn: str,
    tags: Mapping[str, str],
) -> dict[str, Any]:
    ...
# tag_resource method usage example with argument unpacking

kwargs: TagResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
    "tags": ...,
}

parent.tag_resource(**kwargs)
  1. See TagResourceRequestRequestTypeDef

untag_resource#

Removes metadata tags from an elastic cluster resource.

Type annotations and code completion for boto3.client("docdb-elastic").untag_resource method. boto3 documentation

# untag_resource method definition

def untag_resource(
    self,
    *,
    resourceArn: str,
    tagKeys: Sequence[str],
) -> dict[str, Any]:
    ...
# untag_resource method usage example with argument unpacking

kwargs: UntagResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
    "tagKeys": ...,
}

parent.untag_resource(**kwargs)
  1. See UntagResourceRequestRequestTypeDef

update_cluster#

Modifies an elastic cluster.

Type annotations and code completion for boto3.client("docdb-elastic").update_cluster method. boto3 documentation

# update_cluster method definition

def update_cluster(
    self,
    *,
    clusterArn: str,
    adminUserPassword: str = ...,
    authType: AuthType = ...,  # (1)
    backupRetentionPeriod: int = ...,
    clientToken: str = ...,
    preferredBackupWindow: str = ...,
    preferredMaintenanceWindow: str = ...,
    shardCapacity: int = ...,
    shardCount: int = ...,
    shardInstanceCount: int = ...,
    subnetIds: Sequence[str] = ...,
    vpcSecurityGroupIds: Sequence[str] = ...,
) -> UpdateClusterOutputTypeDef:  # (2)
    ...
  1. See AuthType
  2. See UpdateClusterOutputTypeDef
# update_cluster method usage example with argument unpacking

kwargs: UpdateClusterInputRequestTypeDef = {  # (1)
    "clusterArn": ...,
}

parent.update_cluster(**kwargs)
  1. See UpdateClusterInputRequestTypeDef

get_paginator#

Type annotations and code completion for boto3.client("docdb-elastic").get_paginator method with overloads.