Resource URL: /platform/<<version=4>>/protocols/ndmp/settings/preferred-ips

    Overview: This resource applies to manage preferred ip preferences.

     Methods: GET, POST

********************************************************************************

Method GET: Get list of preferences.

       URL: GET /platform/<<version=4>>/protocols/ndmp/settings/preferred-ips

Query arguments:
limit=<integer> Return no more than this many results at once (see resume).
resume=<string> Continue returning results from previous call using this token
                (token should come from the previous call, resume cannot be
                used with other options).

GET response body schema:
{
  "type": [
    {
      "additionalProperties": false, 
      "type": "object", 
      "description": "A list of errors that may be returned.", 
      "properties": {
        "errors": {
          "items": {
            "additionalProperties": false, 
            "type": "object", 
            "description": "An object describing a single error.", 
            "properties": {
              "field": {
                "type": "string", 
                "description": "The field with the error if applicable."
              }, 
              "message": {
                "type": "string", 
                "description": "The error message."
              }, 
              "code": {
                "type": "string", 
                "description": "The error code."
              }
            }
          }, 
          "type": "array"
        }
      }
    }, 
    {
      "type": "object", 
      "description": "Get a list of preferred ip preferences.", 
      "properties": {
        "total": {
          "type": "integer", 
          "description": "The number of preferences."
        }, 
        "preferences": {
          "type": "array", 
          "properties": {
            "scope": {
              "type": "string", 
              "description": "Either cluster or a network subnet defined in OneFS."
            }, 
            "id": {
              "type": "string", 
              "description": "The unique display id, same as scope"
            }, 
            "data_subnets": {
              "type": "array", 
              "properties": {
                "subnet": {
                  "type": "string", 
                  "description": "The name of a subnet."
                }
              }
            }
          }
        }, 
        "resume": {
          "type": "string", 
          "description": "Resume string returned by previous query."
        }
      }
    }
  ]
}

********************************************************************************

Method POST: Create a preferred ip preference.

        URL: POST /platform/<<version=4>>/protocols/ndmp/settings/preferred-ips

There are no query arguments for this method.

Required POST request body fields:
scope, data_subnets

POST request body schema:
{
  "type": "object", 
  "properties": {
    "scope": {
      "required": true, 
      "type": "string", 
      "description": "Either cluster or a network subnet defined in OneFS."
    }, 
    "data_subnets": {
      "required": true, 
      "type": "array", 
      "properties": {
        "subnet": {
          "type": "string", 
          "description": "The name of a subnet."
        }
      }
    }
  }
}

POST response body schema:
{
  "type": [
    {
      "additionalProperties": false, 
      "type": "object", 
      "description": "A list of errors that may be returned.", 
      "properties": {
        "errors": {
          "items": {
            "additionalProperties": false, 
            "type": "object", 
            "description": "An object describing a single error.", 
            "properties": {
              "field": {
                "type": "string", 
                "description": "The field with the error if applicable."
              }, 
              "message": {
                "type": "string", 
                "description": "The error message."
              }, 
              "code": {
                "type": "string", 
                "description": "The error code."
              }
            }
          }, 
          "type": "array"
        }
      }
    }, 
    {
      "type": [
        "null", 
        "object"
      ], 
      "description": "Null or any empty JSON object.", 
      "properties": {}
    }
  ]
}
