Navigation
This version of the documentation is archived and no longer supported. It will be removed on EOL_DATE. To learn how to upgrade your version of MongoDB Ops Manager, refer to the upgrade documentation.
You were redirected from a different version of the documentation. Click here to go back.
This version of the manual is no longer supported. It will be removed on EOL_DATE.

Server Pool Properties

Server Pools deprecated as of Ops Manager 4.0

As of Ops Manager 4.0, server pools are deprecated and disabled by default.

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. This page uses the more familiar term group when referring to descriptions. The endpoint remains as stated in the document.

The serverPool/properties resource retrieves and updates the properties and property values that define servers in the server pool.

For a list of all server pool API resources, see Server Pool. For information on the server pool, see Provision Servers for the Server Pool.

Base URL: https://{OPSMANAGER-HOST}:{PORT}/api/public/v1.0

Endpoints

Get All Properties and Values Defined in the Server Pool

GET /serverPool/properties

You must have the the Global Read Only role or higher.

Update a Property’s Settings

PATCH /serverPool/properties/PROPERTY-ID

PROPERTY-ID is the value of the id field in the property entity.

You can send only the description, multiSelect, and statusName fields. You can send a subset of those fields.

You must have the Global Owner role to use this endpoint.

Update a Property Value

PATCH /serverPool/properties/PROPERTY-ID/values/PROPERTY-VALUE

Where:

  • PROPERTY-ID is the value of the id field in the property entity.
  • PROPERTY-VALUE is the value of a values.value field in the property entity.

You can send only the fields found in the values array object. You can send a subset of those fields.

You must have the Global Owner role to use this endpoint.

Delete a Property and all its Values

DELETE /serverPool/properties/PROPERTY-ID

PROPERTY-ID is the value of the id field in the property entity.

You must have the Global Owner role to use this endpoint.

Delete a Property Value

DELETE /serverPool/properties/PROPERTY-ID/values/PROPERTY-VALUE

Where:

  • PROPERTY-ID is the value of the id field in the property entity.
  • PROPERTY-VALUE is the value of a values.value field in the property entity.

You must have the Global Owner role to use this endpoint.

Sample Entity

{
  "id" : "region",
  "description" : "Location",
  "multiSelect" : false,
  "statusName" : "AVAILABLE",
  "values" : [ {
      "description" : "Eastern region",
      "statusName" : "AVAILABLE",
      "value" : "east"
  }, ... ],
  "links" : [],

Entity Fields

Name Type Description
id string The property name.
multiSelect boolean If set to true, a user can specify multiple values for the property when requesting servers. If a user specifies multiple values for the property when requesting multiple servers, Ops Manager provisions servers in a round-robin fashion; i.e. Ops Manager provisions a server for each value before provisioning a second server for a given value.
statusName string Specifies whether the property can be used to provision a server. If set to AVAILABLE, the property can be specified when a user provisions a server. If set to UNAVAILABLE, the property cannot be specified.
values object array The property’s values.
values.description string A description of the property value.
values.statusName string Specifies whether the property value can be used to provision a server. If set to AVAILABLE, the value can be specified when a user provisions a server. If set to UNAVAILABLE, the value cannot be specified.
values.value string A value that exists for the property.

Examples

Get All Properties and Values Defined in the Server Pool

Request

curl -i -u "username:apiKey" --digest "https://<ops-manager-host>/api/public/v1.0/serverPool/properties"

Response

Response Header

HTTP/1.1 401 Unauthorized
Content-Type: application/json;charset=ISO-8859-1
Date: {dateInUnixFormat}
WWW-Authenticate: Digest realm="MMS Public API", domain="", nonce="{nonce}", algorithm=MD5, op="auth", stale=false
Content-Length: {requestLengthInBytes}
Connection: keep-alive
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/json
Strict-Transport-Security: max-age=300
Date: {dateInUnixFormat}
Connection: keep-alive
Content-Length: {requestLengthInBytes}

Response Body

{
  "links" : [],
  "results" : [ {
    "id" : "region",
    "description" : "Location",
    "links" : [ { ... } ],
    "multiSelect" : false,
    "statusName" : "AVAILABLE",
    "values" : [ {
      "description" : "Eastern region",
      "statusName" : "AVAILABLE",
      "value" : "east"
    }, {
      "description" : "Western region",
      "statusName" : "AVAILABLE",
      "value" : "west"
    } ]
  }, {
    "id" : "size",
    "description" : "CPU, RAM",
    "links" : [],
    "multiSelect" : false,
    "statusName" : "AVAILABLE",
    "values" : [ {
      "statusName" : "AVAILABLE",
      "value" : "large"
    }, {
      "statusName" : "AVAILABLE",
      "value" : "medium"
    } ]
  } ],
  "totalCount" : 2
}

Update a Property’s Settings

Request

curl -i -u "username:apiKey" --digest -H "Content-Type: application/json" -X PATCH "https://<ops-manager-host>/api/public/v1.0/serverPool/properties/region" --data '
{
  "description" : "The location of the server."
}'

Response

Response Header

HTTP/1.1 401 Unauthorized
Content-Type: application/json;charset=ISO-8859-1
Date: {dateInUnixFormat}
WWW-Authenticate: Digest realm="MMS Public API", domain="", nonce="{nonce}", algorithm=MD5, op="auth", stale=false
Content-Length: {requestLengthInBytes}
Connection: keep-alive
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/json
Strict-Transport-Security: max-age=300
Date: {dateInUnixFormat}
Connection: keep-alive
Content-Length: {requestLengthInBytes}

Response Body

{
  "id" : "region",
  "description" : "The location of the server.",
  "multiSelect" : false,
  "statusName" : "AVAILABLE",
  "values" : [ {
    "description" : "Eastern region",
    "statusName" : "AVAILABLE",
    "value" : "east"
  }, {
    "description" : "Western region",
    "statusName" : "AVAILABLE",
    "value" : "west"
  } ],
  "links" : []
}

Update a Property Value

Request

curl -i -u "username:apiKey" --digest -H "Content-Type: application/json" -X PATCH "https://<ops-manager-host>/api/public/v1.0/serverPool/properties/region/values/east" --data '
{
  "statusName" : "UNAVAILABLE"
}'

Response

Response Header

HTTP/1.1 401 Unauthorized
Content-Type: application/json;charset=ISO-8859-1
Date: {dateInUnixFormat}
WWW-Authenticate: Digest realm="MMS Public API", domain="", nonce="{nonce}", algorithm=MD5, op="auth", stale=false
Content-Length: {requestLengthInBytes}
Connection: keep-alive
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/json
Strict-Transport-Security: max-age=300
Date: {dateInUnixFormat}
Connection: keep-alive
Content-Length: {requestLengthInBytes}

Response Body

{
  "id" : "region",
  "description" : "The location of the server.",
  "multiSelect" : false,
  "statusName" : "AVAILABLE",
  "values" : [ {
    "description" : "Eastern region",
    "statusName" : "UNAVAILABLE",
    "value" : "east"
  }, {
    "description" : "Western region",
    "statusName" : "AVAILABLE",
    "value" : "west"
  } ],
  "links" : []
}

Delete a Property and all its Values

Request

curl -i -u "username:apiKey" --digest -X DELETE "https://<ops-manager-host>/api/public/v1.0/serverPool/properties/properties/team"

Response

HTTP/1.1 401 Unauthorized
Content-Type: application/json;charset=ISO-8859-1
Date: {dateInUnixFormat}
WWW-Authenticate: Digest realm="MMS Public API", domain="", nonce="{nonce}", algorithm=MD5, op="auth", stale=false
Content-Length: {requestLengthInBytes}
Connection: keep-alive
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/json
Strict-Transport-Security: max-age=300
Date: {dateInUnixFormat}
Connection: keep-alive
Content-Length: {requestLengthInBytes}

This endpoint does not return a response body.

Delete a Property Value

Request

curl -i -u "username:apiKey" --digest -X DELETE "https://<ops-manager-host>/api/public/v1.0/serverPool/properties/region/values/east"

Response

HTTP/1.1 401 Unauthorized
Content-Type: application/json;charset=ISO-8859-1
Date: {dateInUnixFormat}
WWW-Authenticate: Digest realm="MMS Public API", domain="", nonce="{nonce}", algorithm=MD5, op="auth", stale=false
Content-Length: {requestLengthInBytes}
Connection: keep-alive
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/json
Strict-Transport-Security: max-age=300
Date: {dateInUnixFormat}
Connection: keep-alive
Content-Length: {requestLengthInBytes}

This endpoint does not return a response body.