For the complete documentation index, see llms.txt. This page is also available as Markdown.

Get all Cluster Users

Retrieves a list of MongoDB users.

get
Authorizations
AuthorizationstringRequired

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

Path parameters
clusterIdstringRequired

The unique ID of the cluster.

Query parameters
limitinteger · min: 1 · max: 1000Optional

The maximum number of elements to return. Use together with 'offset' for pagination.

Default: 100Example: 100
offsetintegerOptional

The first element to return. Use together with 'limit' for pagination.

Default: 0Example: 200
Responses
200

Successful operation.

application/json

List of cluster users.

typestring · enumOptional

The resource type.

Possible values:
idstringOptional

The unique ID of the resource.

Example: 498ae72f-411f-11eb-9d07-046c59cc737e
get/clusters/{clusterId}/users
GET /databases/mongodb/clusters/{clusterId}/users HTTP/1.1
Host: api.ionos.com
Authorization: Basic username:password
Accept: */*
{
  "type": "collection",
  "id": "498ae72f-411f-11eb-9d07-046c59cc737e",
  "items": [
    {
      "type": "user",
      "metadata": {
        "createdDate": "2020-12-10T13:37:50+01:00",
        "createdBy": "john.doe@example.com",
        "createdByUserId": "87f9a82e-b28d-49ed-9d04-fba2c0459cd3"
      },
      "properties": {
        "username": "text",
        "roles": [
          {
            "role": "read",
            "database": "text"
          }
        ]
      }
    }
  ]
}

Last updated

Was this helpful?