Navigation

Get All Checkpoints

Get all checkpoints for a sharded cluster.

Info With Circle IconCreated with Sketch.Note

Groups and projects are synonymous terms. Your {GROUP-ID} is the same as your project ID. For existing groups, your group/project ID remains the same. The resource and corresponding endpoints use the term groups.

The Atlas API authenticates using HTTP Digest Authentication. Provide a programmatic API public key and corresponding private key as the username and password when constructing the HTTP request.

To learn how to configure API access for an Atlas project, see Configure Atlas API Access.

https://cloud.mongodb.com/api/atlas/v1.0

GET /groups/{GROUP-ID}/clusters/{CLUSTER-NAME}/backupCheckpoints
Path ElementRequired/OptionalDescription
{GROUP-ID}Required.The unique identifier of the project that owns the checkpoints.
{CLUSTER-NAME}RequiredThe name of the cluster that contains the checkpoints that you want to retrieve.

This endpoint may use any of the HTTP request query parameters available to all Atlas API resources. These are all optional.

NameTypeNecessityDescriptionDefault
pageNumintegerOptionalPage number, starting with one, that Atlas returns of the total number of objects.1
itemsPerPageintegerOptionalNumber of items that Atlas returns per page, up to a maximum of 500.100
includeCountbooleanOptionalFlag that indicates whether Atlas returns the totalCount parameter in the response body.true
prettybooleanOptionalFlag that indicates whether Atlas returns the JSON response in the prettyprint format.false
envelopebooleanOptional

Flag that indicates whether Atlas wraps the response in an envelope.

Some API clients cannot access the HTTP response headers or status code. To remediate this, set envelope=true in the query.

Endpoints that return a list of results use the results object as an envelope. Atlas adds the status parameter to the response body.

false

This endpoint does not use HTTP request body parameters.

The response JSON document includes an array of result objects, an array of link objects, and a count of the total number of result objects retrieved.

NameTypeDescription
resultsobject arrayIncludes one object for each item detailed in the results array section.
linksobject arrayIncludes one or more links to sub-resources and/or related resources. The relations between URLs are explained in the Web Linking Specification.
totalCountnumberCount of the total number of items in the result set. It may be greater than the number of objects in the results array if the entire result set is paginated.

Each result is one cluster checkpoint.

NameTypeDescription
clusterIdstringID of the cluster containing the checkpoint.
completedBSON timestampThe point in time the checkpoint completed and the balancer restarted.
groupIdstringThe unique identifier of the project that owns the checkpoint.
idstringThe checkpoint ID.
linksarray of objectsThis array includes one or more links to sub-resources and/or related resources. The relations between URLs are explained in the Web Linking Specification.
partsarray of objectsThe individual parts that comprise the complete checkpoint. There will be one element for each shard plus one element for the config servers.
parts[i].replicaSetNamestringName of the replica set. Not present for config servers.
parts[i].shardNamestringThe name of the shard.
parts[i].tokenDiscoveredBooleanIndicates whether the token exists.
parts[i].tokenTimestampdocument

The timestamp of the checkpoint token entry in the oplog, as specified by the entry’s ts field. The ts field is a BSON timestamp and has two components:

  • timestamp: the value in seconds since the Unix epoch
  • increment: an incrementing ordinal for operations within a given second
parts[i].typeNamestring

The type of server represented by the part. Possible values are:

  • REPLICA_SET, which indicates the part is a shard.
  • CONFIG_SERVER
restorableBooleanIndicates whether the checkpoint can be used for a restore.
startedBSON timestampThe point in time Atlas stopped the balancer and began the checkpoint.
timestampBSON timestampThe point in time the checkpoint restores to.
curl --user "{PUBLIC-KEY}:{PRIVATE-KEY}" --digest \
--header "Content-Type: application/json" \
--include \
-X GET "https://cloud.mongodb.com/api/atlas/v1.0/groups/6b8cd3c380eef5349ef77gf7/clusters/Cluster0/backupCheckpoints"
{
"links":[
{
"href":"https://cloud.mongodb.com/api/atlas/v1.0/groups/6b8cd3c380eef5349ef77gf7/clusters/Cluster0/backupCheckpoints?pageNum=1&itemsPerPage=100",
"rel":"self"
}
],
"results":[
{
"clusterId":"6b8cd61180eef547110159d9",
"completed":"2018-02-08T23:20:25Z",
"groupId":"6b8cd3c380eef5349ef77gf7",
"id":"5a7cdb3980eef53de5bffdcf",
"links":[
{
"href":"https://cloud.mongodb.com/api/atlas/v1.0/groups/6b8cd3c380eef5349ef77gf7/clusters/Cluster0/backupCheckpoints",
"rel":"self"
}
],
"parts":[
{
"replicaSetName":"Cluster0-shard-1",
"shardName":"Cluster0-shard-1",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-08T23:20:25Z",
"increment":1
},
"typeName":"REPLICA_SET"
},
{
"replicaSetName":"Cluster0-shard-0",
"shardName":"Cluster0-shard-0",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-08T23:20:25Z",
"increment":1
},
"typeName":"REPLICA_SET"
},
{
"replicaSetName":"Cluster0-config-0",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-08T23:20:25Z",
"increment":2
},
"typeName":"CONFIG_SERVER_REPLICA_SET"
}
],
"restorable":true,
"started":"2018-02-08T23:20:25Z",
"timestamp":"2018-02-08T23:19:37Z"
},
{
"clusterId":"6b8cd61180eef547110159d9",
"completed":"2018-02-09T14:50:33Z",
"groupId":"6b8cd3c380eef5349ef77gf7",
"id":"5a7db53987d9d64fe298ff46",
"links":[
{
"href":"https://cloud.mongodb.com/api/atlas/v1.0/groups/6b8cd3c380eef5349ef77gf7/clusters/Cluster0/backupCheckpoints?pretty=true",
"rel":"self"
}
],
"parts":[
{
"replicaSetName":"Cluster0-shard-1",
"shardName":"Cluster0-shard-1",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-09T14:50:33Z",
"increment":1
},
"typeName":"REPLICA_SET"
},
{
"replicaSetName":"Cluster0-shard-0",
"shardName":"Cluster0-shard-0",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-09T14:50:33Z",
"increment":2
},
"typeName":"REPLICA_SET"
},
{
"replicaSetName":"Cluster0-config-0",
"tokenDiscovered":true,
"tokenTimestamp":{
"date":"2018-02-09T14:50:33Z",
"increment":4
},
"typeName":"CONFIG_SERVER_REPLICA_SET"
}
],
"restorable":true,
"started":"2018-02-09T14:50:33Z",
"timestamp":"2018-02-09T14:50:18Z"
},
{
...
}
],
"totalCount":61
}
Give Feedback