Skip to content

describe_db_cluster_snapshots

describe_db_cluster_snapshots(
    *,
    config_overrides: Optional[NeptuneClientConfig] = None,
    db_cluster_identifier: Optional[String] = None,
    db_cluster_snapshot_identifier: Optional[String] = None,
    snapshot_type: Optional[String] = None,
    filters: Optional[FilterList] = None,
    max_records: Optional[IntegerOptional] = None,
    marker: Optional[String] = None,
    include_shared: Optional[Boolean] = None,
    include_public: Optional[Boolean] = None,
) -> DBClusterSnapshotMessage

Returns information about DB cluster snapshots. This API action supports pagination.

Parameters:

  • db_cluster_identifier (Optional[String], default: None ) –

    The ID of the DB cluster to retrieve the list of DB cluster snapshots for. This parameter can't be used in conjunction with the DBClusterSnapshotIdentifier parameter. This parameter is not case-sensitive.

    Constraints:

    • If supplied, must match the identifier of an existing DBCluster.

  • db_cluster_snapshot_identifier (Optional[String], default: None ) –

    A specific DB cluster snapshot identifier to describe. This parameter can't be used in conjunction with the DBClusterIdentifier parameter. This value is stored as a lowercase string.

    Constraints:

    • If supplied, must match the identifier of an existing DBClusterSnapshot.

    • If this identifier is for an automated snapshot, the SnapshotType parameter must also be specified.

  • snapshot_type (Optional[String], default: None ) –

    The type of DB cluster snapshots to be returned. You can specify one of the following values:

    • automated - Return all DB cluster snapshots that have been automatically taken by Amazon Neptune for my Amazon account.

    • manual - Return all DB cluster snapshots that have been taken by my Amazon account.

    • shared - Return all manual DB cluster snapshots that have been shared to my Amazon account.

    • public - Return all DB cluster snapshots that have been marked as public.

    If you don't specify a SnapshotType value, then both automated and manual DB cluster snapshots are returned. You can include shared DB cluster snapshots with these results by setting the IncludeShared parameter to true. You can include public DB cluster snapshots with these results by setting the IncludePublic parameter to true.

    The IncludeShared and IncludePublic parameters don't apply for SnapshotType values of manual or automated. The IncludePublic parameter doesn't apply when SnapshotType is set to shared. The IncludeShared parameter doesn't apply when SnapshotType is set to public.

  • filters (Optional[FilterList], default: None ) –

    This parameter is not currently supported.

  • max_records (Optional[IntegerOptional], default: None ) –

    The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a pagination token called a marker is included in the response so that the remaining results can be retrieved.

    Default: 100

    Constraints: Minimum 20, maximum 100.

  • marker (Optional[String], default: None ) –

    An optional pagination token provided by a previous DescribeDBClusterSnapshots request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

  • include_shared (Optional[Boolean], default: None ) –

    True to include shared manual DB cluster snapshots from other Amazon accounts that this Amazon account has been given permission to copy or restore, and otherwise false. The default is false.

    You can give an Amazon account permission to restore a manual DB cluster snapshot from another Amazon account by the ModifyDBClusterSnapshotAttribute API action.

  • include_public (Optional[Boolean], default: None ) –

    True to include manual DB cluster snapshots that are public and can be copied or restored by any Amazon account, and otherwise false. The default is false. The default is false.

    You can share a manual DB cluster snapshot as public by using the ModifyDBClusterSnapshotAttribute API action.

Raises:

Source code in docs_src/capo_neptune/_services/neptune.py
def describe_db_cluster_snapshots(
    self,
    *,
    config_overrides: Optional[NeptuneClientConfig] = None,
    db_cluster_identifier: Optional["capo_neptune.types.string.String"] = None,
    db_cluster_snapshot_identifier: Optional[
        "capo_neptune.types.string.String"
    ] = None,
    snapshot_type: Optional["capo_neptune.types.string.String"] = None,
    filters: Optional["capo_neptune.types.filter_list.FilterList"] = None,
    max_records: Optional[
        "capo_neptune.types.integer_optional.IntegerOptional"
    ] = None,
    marker: Optional["capo_neptune.types.string.String"] = None,
    include_shared: Optional["capo_neptune.types.boolean.Boolean"] = None,
    include_public: Optional["capo_neptune.types.boolean.Boolean"] = None,
) -> "capo_neptune.types.db_cluster_snapshot_message.DBClusterSnapshotMessage":
    """<p>Returns information about DB cluster snapshots. This API action supports pagination.</p>

    Args:
        db_cluster_identifier: <p>The ID of the DB cluster to retrieve the list of DB cluster snapshots for. This parameter can't be used in conjunction with the <code>DBClusterSnapshotIdentifier</code> parameter. This parameter is not case-sensitive.</p> <p>Constraints:</p> <ul> <li> <p>If supplied, must match the identifier of an existing DBCluster.</p> </li> </ul>
        db_cluster_snapshot_identifier: <p>A specific DB cluster snapshot identifier to describe. This parameter can't be used in conjunction with the <code>DBClusterIdentifier</code> parameter. This value is stored as a lowercase string.</p> <p>Constraints:</p> <ul> <li> <p>If supplied, must match the identifier of an existing DBClusterSnapshot.</p> </li> <li> <p>If this identifier is for an automated snapshot, the <code>SnapshotType</code> parameter must also be specified.</p> </li> </ul>
        snapshot_type: <p>The type of DB cluster snapshots to be returned. You can specify one of the following values:</p> <ul> <li> <p> <code>automated</code> - Return all DB cluster snapshots that have been automatically taken by Amazon Neptune for my Amazon account.</p> </li> <li> <p> <code>manual</code> - Return all DB cluster snapshots that have been taken by my Amazon account.</p> </li> <li> <p> <code>shared</code> - Return all manual DB cluster snapshots that have been shared to my Amazon account.</p> </li> <li> <p> <code>public</code> - Return all DB cluster snapshots that have been marked as public.</p> </li> </ul> <p>If you don't specify a <code>SnapshotType</code> value, then both automated and manual DB cluster snapshots are returned. You can include shared DB cluster snapshots with these results by setting the <code>IncludeShared</code> parameter to <code>true</code>. You can include public DB cluster snapshots with these results by setting the <code>IncludePublic</code> parameter to <code>true</code>.</p> <p>The <code>IncludeShared</code> and <code>IncludePublic</code> parameters don't apply for <code>SnapshotType</code> values of <code>manual</code> or <code>automated</code>. The <code>IncludePublic</code> parameter doesn't apply when <code>SnapshotType</code> is set to <code>shared</code>. The <code>IncludeShared</code> parameter doesn't apply when <code>SnapshotType</code> is set to <code>public</code>.</p>
        filters: <p>This parameter is not currently supported.</p>
        max_records: <p>The maximum number of records to include in the response. If more records exist than the specified <code>MaxRecords</code> value, a pagination token called a marker is included in the response so that the remaining results can be retrieved.</p> <p>Default: 100</p> <p>Constraints: Minimum 20, maximum 100.</p>
        marker: <p>An optional pagination token provided by a previous <code>DescribeDBClusterSnapshots</code> request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by <code>MaxRecords</code>. </p>
        include_shared: <p>True to include shared manual DB cluster snapshots from other Amazon accounts that this Amazon account has been given permission to copy or restore, and otherwise false. The default is <code>false</code>.</p> <p>You can give an Amazon account permission to restore a manual DB cluster snapshot from another Amazon account by the <a>ModifyDBClusterSnapshotAttribute</a> API action.</p>
        include_public: <p>True to include manual DB cluster snapshots that are public and can be copied or restored by any Amazon account, and otherwise false. The default is <code>false</code>. The default is false.</p> <p>You can share a manual DB cluster snapshot as public by using the <a>ModifyDBClusterSnapshotAttribute</a> API action.</p>

    Raises:
        capo_neptune.errors.db_cluster_snapshot_not_found_fault.DBClusterSnapshotNotFoundFault: <p> <i>DBClusterSnapshotIdentifier</i> does not refer to an existing DB cluster snapshot.</p>
        capo_neptune.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_neptune.types.describe_db_cluster_snapshots_message.DescribeDBClusterSnapshotsMessage]",
    ) -> OperationResponse[
        "capo_neptune.types.db_cluster_snapshot_message.DBClusterSnapshotMessage"
    ]:
        import capo_neptune._operations.amazon_rd_sv19.describe_db_cluster_snapshots

        output, http_response = (
            capo_neptune._operations.amazon_rd_sv19.describe_db_cluster_snapshots.describe_db_cluster_snapshots(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DescribeDBClusterSnapshots")
    )
    input_: capo_neptune.types.describe_db_cluster_snapshots_message.DescribeDBClusterSnapshotsMessage = {}
    if db_cluster_identifier is not None:
        input_["db_cluster_identifier"] = db_cluster_identifier
    if db_cluster_snapshot_identifier is not None:
        input_["db_cluster_snapshot_identifier"] = db_cluster_snapshot_identifier
    if snapshot_type is not None:
        input_["snapshot_type"] = snapshot_type
    if filters is not None:
        input_["filters"] = filters
    if max_records is not None:
        input_["max_records"] = max_records
    if marker is not None:
        input_["marker"] = marker
    if include_shared is not None:
        input_["include_shared"] = include_shared
    if include_public is not None:
        input_["include_public"] = include_public

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output