Patch a Cluster
Patch attributes of a MongoDB cluster.
For 'Basic' authentication, take your credentials by first combining the username and password with a colon (username:password) and then encoding the resulting string in base64 (YWxhZGRpbjpvcGVuc2VzYW1l).
Example Request Header
Authorization: Basic YWxhZGRpbjpvcGVuc2Vzl
More details: https://en.wikipedia.org/wiki/Basic_access_authentication
The unique ID of the cluster.
Request payload to change a cluster.
Successful operation.
A database cluster.
The resource type.
The unique ID of the resource.
498ae72f-411f-11eb-9d07-046c59cc737eAny erroneous status code: 400 (parse error), 401 (authorization error), 402 (trial access), 403 (insufficient permissions), 404 (not found), 405 (unsupported HTTP method), 415 (unsupported content type), 422 (validation error), 429 (request rate limit exceeded), 500 (server error), 503 (maintenance)
PATCH /databases/mongodb/clusters/{clusterId} HTTP/1.1
Host: api.ionos.com
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 805
{
"metadata": {
"createdDate": "2020-12-10T13:37:50+01:00",
"createdBy": "john.doe@example.com",
"createdByUserId": "87f9a82e-b28d-49ed-9d04-fba2c0459cd3",
"lastModifiedDate": "2020-12-11T13:37:50+01:00",
"lastModifiedBy": "jane.doe@example.com",
"lastModifiedByUserId": "87f9a82e-b28d-49ed-9d04-fba2c0459cd3",
"state": "AVAILABLE",
"health": "HEALTHY"
},
"properties": {
"type": "replicaset",
"displayName": "MongoDB cluster",
"maintenanceWindow": {
"time": "16:30:59",
"dayOfTheWeek": "Monday"
},
"instances": 3,
"shards": 2,
"backup": {
"location": "de"
},
"biConnector": {
"enabled": false
},
"connections": [
{
"datacenterId": "5a029f4a-72e5-11ec-90d6-0242ac120003",
"lanId": "2",
"cidrList": [
"192.168.1.100/24",
"192.168.1.101/24"
]
}
],
"templateID": "498ae72f-411f-11eb-9d07-046c59cc737e",
"mongoDBVersion": "6.0",
"edition": "playground",
"cores": 4,
"ram": 2048
}
}{
"type": "cluster",
"id": "498ae72f-411f-11eb-9d07-046c59cc737e",
"metadata": {
"createdDate": "2020-12-10T13:37:50+01:00",
"createdBy": "john.doe@example.com",
"createdByUserId": "87f9a82e-b28d-49ed-9d04-fba2c0459cd3",
"lastModifiedDate": "2020-12-11T13:37:50+01:00",
"lastModifiedBy": "jane.doe@example.com",
"lastModifiedByUserId": "87f9a82e-b28d-49ed-9d04-fba2c0459cd3",
"state": "AVAILABLE",
"health": "HEALTHY"
},
"properties": {
"type": "replicaset",
"displayName": "MongoDB cluster",
"mongoDBVersion": "6.0",
"location": "de/txl",
"backup": {
"location": "de"
},
"instances": 3,
"shards": 2,
"connections": [
{
"datacenterId": "5a029f4a-72e5-11ec-90d6-0242ac120003",
"lanId": "2",
"cidrList": [
"192.168.1.100/24",
"192.168.1.101/24"
]
}
],
"maintenanceWindow": {
"time": "16:30:59",
"dayOfTheWeek": "Monday"
},
"templateID": "498ae72f-411f-11eb-9d07-046c59cc737e",
"connectionString": "mongo+srv://m-498ae72f-411f-11eb-9d07-046c59cc737e.mongodb.de-txl.ionos.com",
"biConnector": {
"enabled": false,
"host": "text",
"port": "text"
},
"edition": "playground",
"cores": 4,
"ram": 2048,
"storageSize": 5000,
"storageType": "HDD"
}
}Last updated
Was this helpful?