{
  "swagger": "2.0",
  "schemes": [
    "https"
  ],
  "host": "management.azure.com",
  "info": {
    "description": "REST API for Azure Server Management Service.",
    "title": "ServerManagement",
    "version": "2015-07-01-preview",
    "x-apisguru-categories": [
      "cloud"
    ],
    "x-logo": {
      "url": "https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png"
    },
    "x-origin": [
      {
        "format": "swagger",
        "url": "https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/servermanagement/resource-manager/Microsoft.ServerManagement/preview/2015-07-01-preview/servermanagement.json",
        "version": "2.0"
      }
    ],
    "x-preferred": false,
    "x-providerName": "azure.com",
    "x-serviceName": "servermanagement",
    "x-tags": [
      "Azure",
      "Microsoft"
    ]
  },
  "consumes": [
    "application/json",
    "text/json"
  ],
  "produces": [
    "application/json",
    "text/json"
  ],
  "securityDefinitions": {
    "azure_auth": {
      "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
      "description": "Azure Active Directory OAuth2 Flow.",
      "flow": "implicit",
      "scopes": {
        "user_impersonation": "impersonate your user account"
      },
      "type": "oauth2"
    }
  },
  "security": [
    {
      "azure_auth": [
        "user_impersonation"
      ]
    }
  ],
  "parameters": {
    "ApiVersionParameter": {
      "description": "Client API Version.",
      "in": "query",
      "name": "api-version",
      "required": true,
      "type": "string"
    },
    "SubscriptionIdParameter": {
      "description": "Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.",
      "in": "path",
      "name": "subscriptionId",
      "required": true,
      "type": "string"
    }
  },
  "paths": {
    "/subscriptions/{subscriptionId}/providers/Microsoft.ServerManagement/gateways": {
      "get": {
        "description": "Lists gateways in a subscription.",
        "operationId": "Gateway_List",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResources"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/providers/Microsoft.ServerManagement/nodes": {
      "get": {
        "description": "Lists nodes in a subscription.",
        "operationId": "Node_List",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResources"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways": {
      "get": {
        "description": "Returns gateways in a resource group.",
        "operationId": "Gateway_ListForResourceGroup",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResources"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}": {
      "delete": {
        "description": "Deletes a gateway from a resource group.",
        "operationId": "Gateway_Delete",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The object exists and was deleted successfully."
          },
          "204": {
            "description": "The request is well formed but the resource does not exist."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ]
      },
      "get": {
        "description": "Gets a gateway.",
        "operationId": "Gateway_Get",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.",
            "enum": [
              "status"
            ],
            "in": "query",
            "name": "$expand",
            "required": false,
            "type": "string",
            "x-ms-enum": {
              "modelAsString": false,
              "name": "GatewayExpandOption"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResource"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ]
      },
      "patch": {
        "description": "Updates a gateway belonging to a resource group.",
        "operationId": "Gateway_Update",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the Update operation.",
            "in": "body",
            "name": "GatewayParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/GatewayParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "Update completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResource"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "x-ms-long-running-operation": true
      },
      "put": {
        "description": "Creates or updates a ManagementService gateway.",
        "operationId": "Gateway_Create",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the CreateOrUpdate operation.",
            "in": "body",
            "name": "GatewayParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/GatewayParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResource"
            }
          },
          "201": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayResource"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/profile": {
      "post": {
        "description": "Gets a gateway profile.",
        "operationId": "Gateway_GetProfile",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/GatewayProfile"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/regenerateprofile": {
      "post": {
        "description": "Regenerates a gateway's profile",
        "operationId": "Gateway_RegenerateProfile",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully."
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/upgradetolatest": {
      "post": {
        "description": "Upgrades a gateway.",
        "operationId": "Gateway_Upgrade",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The gateway name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "gatewayName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully."
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Gateways"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes": {
      "get": {
        "description": "Lists nodes in a resource group.",
        "operationId": "Node_ListForResourceGroup",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResources"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}": {
      "delete": {
        "description": "Deletes a management node.",
        "operationId": "Node_Delete",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The object exists and was deleted successfully."
          },
          "204": {
            "description": "The request is well formed but the resource does not exist."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ]
      },
      "get": {
        "description": "Gets a management node.",
        "operationId": "Node_Get",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The object exists and was deleted successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResource"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ]
      },
      "patch": {
        "description": "Updates a management node.",
        "operationId": "Node_Update",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the CreateOrUpdate operation.",
            "in": "body",
            "name": "NodeParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/NodeParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResource"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ],
        "x-ms-long-running-operation": true
      },
      "put": {
        "description": "Creates or updates a management node.",
        "operationId": "Node_Create",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the CreateOrUpdate operation.",
            "in": "body",
            "name": "GatewayParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/NodeParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResource"
            }
          },
          "201": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/NodeResource"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Nodes"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}": {
      "delete": {
        "description": "Deletes a session for a node.",
        "operationId": "Session_Delete",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully."
          },
          "204": {
            "description": "The request is well formed but the resource does not exist."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Sessions"
        ]
      },
      "get": {
        "description": "Gets a session for a node.",
        "operationId": "Session_Get",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/SessionResource"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Sessions"
        ]
      },
      "put": {
        "description": "Creates a session for a node.",
        "operationId": "Session_Create",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the CreateOrUpdate operation.",
            "in": "body",
            "name": "SessionParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/SessionParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/SessionResource"
            }
          },
          "201": {
            "description": "Created: the session has been created.",
            "schema": {
              "$ref": "#/definitions/SessionResource"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "Sessions"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}/features/powerShellConsole/pssessions": {
      "get": {
        "description": "Gets a list of the active sessions.",
        "operationId": "PowerShell_ListSession",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellSessionResources"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ]
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}/features/powerShellConsole/pssessions/{pssession}": {
      "get": {
        "description": "Gets the status of a command.",
        "operationId": "PowerShell_GetCommandStatus",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          },
          {
            "description": "Gets current output from an ongoing call.",
            "enum": [
              "output"
            ],
            "in": "query",
            "name": "$expand",
            "required": false,
            "type": "string",
            "x-ms-enum": {
              "modelAsString": false,
              "name": "PowerShellExpandOption"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellCommandStatus"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ]
      },
      "patch": {
        "description": "updates a running PowerShell command with more data.",
        "operationId": "PowerShell_UpdateCommand",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellCommandResults"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ],
        "x-ms-long-running-operation": true
      },
      "put": {
        "description": "Creates a PowerShell session.",
        "operationId": "PowerShell_CreateSession",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed succesfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellSessionResource"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}/features/powerShellConsole/pssessions/{pssession}/cancel": {
      "post": {
        "description": "Cancels a PowerShell command.",
        "operationId": "PowerShell_CancelCommand",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "The cancellation was completed successfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellCommandResults"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}/features/powerShellConsole/pssessions/{pssession}/invokeCommand": {
      "post": {
        "description": "Creates a PowerShell script and invokes it.",
        "operationId": "PowerShell_InvokeCommand",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the Invoke PowerShell Command operation.",
            "in": "body",
            "name": "PowerShellCommandParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/PowerShellCommandParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The operation completed successfully.",
            "schema": {
              "$ref": "#/definitions/PowerShellCommandResults"
            }
          },
          "202": {
            "description": "Accepted: Location header contains the URL where the status of the long running operation can be checked."
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ],
        "x-ms-long-running-operation": true
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/nodes/{nodeName}/sessions/{session}/features/powerShellConsole/pssessions/{pssession}/tab": {
      "post": {
        "description": "Gets tab completion values for a command.",
        "operationId": "PowerShell_TabCompletion",
        "parameters": [
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "description": "The resource group name uniquely identifies the resource group within the user subscriptionId.",
            "in": "path",
            "minLength": 3,
            "name": "resourceGroupName",
            "pattern": "[a-zA-Z0-9]+",
            "required": true,
            "type": "string"
          },
          {
            "description": "The node name (256 characters maximum).",
            "in": "path",
            "maxLength": 256,
            "minLength": 1,
            "name": "nodeName",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9_.-]*$",
            "required": true,
            "type": "string"
          },
          {
            "description": "The sessionId from the user.",
            "in": "path",
            "name": "session",
            "required": true,
            "type": "string"
          },
          {
            "description": "The PowerShell sessionId from the user.",
            "in": "path",
            "name": "pssession",
            "required": true,
            "type": "string"
          },
          {
            "description": "Parameters supplied to the tab completion call.",
            "in": "body",
            "name": "PowerShellTabCompletionParamters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/PowerShellTabCompletionParameters"
            },
            "x-ms-client-flatten": true
          }
        ],
        "responses": {
          "200": {
            "description": "The request was succesfully completed.",
            "schema": {
              "$ref": "#/definitions/PowerShellTabCompletionResults"
            }
          },
          "default": {
            "description": "Default Response. It will be deserialized as per the error definition specified in the schema and an exception will be thrown.",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "tags": [
          "PowerShell"
        ]
      }
    }
  },
  "definitions": {
    "Error": {
      "description": "Error message.",
      "properties": {
        "code": {
          "format": "int32",
          "type": "integer"
        },
        "fields": {
          "type": "string"
        },
        "message": {
          "type": "string"
        }
      }
    },
    "GatewayParameters": {
      "properties": {
        "location": {
          "description": "Location of the resource.",
          "type": "string"
        },
        "properties": {
          "properties": {
            "autoUpgrade": {
              "description": "The autoUpgrade property gives the flexibility to gateway to auto upgrade itself. If properties value not specified, then we assume autoUpgrade = Off.",
              "enum": [
                "On",
                "Off"
              ],
              "type": "string",
              "x-ms-enum": {
                "modelAsString": false,
                "name": "AutoUpgrade"
              }
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        },
        "tags": {
          "description": "Resource tags.",
          "type": "object"
        }
      }
    },
    "GatewayProfile": {
      "description": "JSON properties that the gateway service uses know how to communicate with the resource.",
      "properties": {
        "dataPlaneServiceBaseAddress": {
          "description": "The Dataplane connection URL.",
          "type": "string"
        },
        "environment": {
          "description": "The environment for the gateway (DEV, DogFood, or Production).",
          "type": "string"
        },
        "gatewayId": {
          "description": "The ID of the gateway.",
          "type": "string"
        },
        "messagingAccount": {
          "description": "Messaging Account.",
          "type": "string"
        },
        "messagingKey": {
          "description": "Messaging Key.",
          "type": "string"
        },
        "messagingNamespace": {
          "description": "Messaging namespace.",
          "type": "string"
        },
        "requestQueue": {
          "description": "Request queue name.",
          "type": "string"
        },
        "responseTopic": {
          "description": "Response topic name.",
          "type": "string"
        },
        "statusBlobSignature": {
          "description": "The gateway status blob SAS URL.",
          "type": "string"
        },
        "upgradeManifestUrl": {
          "description": "Gateway upgrade manifest URL.",
          "type": "string"
        }
      }
    },
    "GatewayResource": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "properties": {
        "properties": {
          "properties": {
            "activeMessageCount": {
              "description": "number of active messages",
              "type": "integer"
            },
            "autoUpgrade": {
              "description": "Setting of the autoupgrade.",
              "enum": [
                "On",
                "Off"
              ],
              "type": "string",
              "x-ms-enum": {
                "modelAsString": false,
                "name": "AutoUpgrade"
              }
            },
            "created": {
              "description": "UTC date and time when gateway was first added to management service.",
              "format": "date-time",
              "type": "string"
            },
            "desiredVersion": {
              "description": "Latest available MSI version.",
              "type": "string"
            },
            "instances": {
              "description": "Names of the nodes in the gateway.",
              "items": {
                "$ref": "#/definitions/GatewayStatus"
              },
              "type": "array"
            },
            "latestPublishedMsiVersion": {
              "description": "Last published MSI version.",
              "type": "string"
            },
            "publishedTimeUtc": {
              "description": "The date/time of the last published gateway.",
              "format": "date-time",
              "type": "string"
            },
            "updated": {
              "description": "UTC date and time when node was last updated.",
              "format": "date-time",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "GatewayResources": {
      "description": "Collection of Gateway Resources.",
      "properties": {
        "nextLink": {
          "description": "The URL to the next set of resources.",
          "type": "string"
        },
        "value": {
          "description": "Collection of Gateway Resources.",
          "items": {
            "$ref": "#/definitions/GatewayResource"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "GatewayStatus": {
      "description": "Expanded gateway status information.",
      "properties": {
        "availableMemoryMByte": {
          "description": "The available memory on the gateway host machine in megabytes.",
          "type": "number"
        },
        "friendlyOsName": {
          "description": "The Plaintext description of the OS on the gateway.",
          "type": "string"
        },
        "gatewayCpuUtilizationPercent": {
          "description": "The CPU utilization of the gateway process (numeric value between 0 and 100).",
          "format": "float",
          "maximum": 100,
          "minimum": 0,
          "type": "number"
        },
        "gatewayId": {
          "description": "The gateway resource ID.",
          "type": "string"
        },
        "gatewayVersion": {
          "description": "The version of the gateway that is installed on the system.",
          "type": "string"
        },
        "gatewayWorkingSetMByte": {
          "description": "The working set size of the gateway process in megabytes.",
          "type": "number"
        },
        "installedDate": {
          "description": "The date the gateway was installed.",
          "format": "date-time",
          "type": "string"
        },
        "logicalProcessorCount": {
          "description": "Number of logical processors in the gateway system.",
          "type": "integer"
        },
        "name": {
          "description": "The computer name of the gateway system.",
          "type": "string"
        },
        "statusUpdated": {
          "description": "UTC date and time when gateway status was last updated.",
          "format": "date-time",
          "type": "string"
        },
        "totalCpuUtilizationPercent": {
          "description": "CPU Utilization of the whole system.",
          "type": "number"
        }
      }
    },
    "NodeParameters": {
      "properties": {
        "location": {
          "description": "Location of the resource.",
          "type": "string"
        },
        "properties": {
          "properties": {
            "connectionName": {
              "description": "myhost.domain.com",
              "type": "string"
            },
            "gatewayId": {
              "description": "Gateway ID which will manage this node.",
              "type": "string"
            },
            "password": {
              "description": "Password associated with user name.",
              "format": "password",
              "type": "string"
            },
            "userName": {
              "description": "User name to be used to connect to node.",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        },
        "tags": {
          "description": "Resource tags.",
          "type": "object"
        }
      }
    },
    "NodeResource": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "description": "A Node Resource.",
      "properties": {
        "properties": {
          "properties": {
            "connectionName": {
              "description": "myhost.domain.com",
              "type": "string"
            },
            "created": {
              "description": "UTC date and time when node was first added to management service.",
              "format": "date-time",
              "type": "string"
            },
            "gatewayId": {
              "description": "ID of the gateway.",
              "type": "string"
            },
            "updated": {
              "description": "UTC date and time when node was last updated.",
              "format": "date-time",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "NodeResources": {
      "description": "A collection of node resource objects.",
      "properties": {
        "nextLink": {
          "description": "The URL to the next set of resources.",
          "type": "string"
        },
        "value": {
          "description": "Collection of Node Resources.",
          "items": {
            "$ref": "#/definitions/NodeResource"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "PowerShellCommandParameters": {
      "description": "The parameters to a PowerShell script execution command.",
      "properties": {
        "properties": {
          "properties": {
            "command": {
              "description": "Script to execute.",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "PowerShellCommandResult": {
      "properties": {
        "backgroundColor": {
          "description": "The HTML color string representing the background color.",
          "type": "string"
        },
        "caption": {
          "description": "Text that precedes the prompt.",
          "type": "string"
        },
        "descriptions": {
          "description": "Collection of PromptFieldDescription objects that contains the user input",
          "items": {
            "$ref": "#/definitions/PromptFieldDescription"
          },
          "type": "array"
        },
        "exitCode": {
          "description": "The exit code from a executable that was called from PowerShell.",
          "type": "integer"
        },
        "foregroundColor": {
          "description": "The HTML color string representing the foreground color.",
          "type": "string"
        },
        "id": {
          "description": "ID of the prompt message.",
          "type": "integer"
        },
        "message": {
          "description": "Text of the prompt.",
          "type": "string"
        },
        "messageType": {
          "description": "The type of message.",
          "type": "integer"
        },
        "prompt": {
          "description": "The interactive prompt message.",
          "type": "string"
        },
        "value": {
          "description": "Actual result text from the PowerShell Command.",
          "type": "string"
        }
      }
    },
    "PowerShellCommandResults": {
      "description": "A collection of results from a PowerShell command.",
      "properties": {
        "command": {
          "type": "string"
        },
        "completed": {
          "type": "boolean"
        },
        "pssession": {
          "type": "string"
        },
        "results": {
          "items": {
            "$ref": "#/definitions/PowerShellCommandResult"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "PowerShellCommandStatus": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "properties": {
        "properties": {
          "$ref": "#/definitions/PowerShellCommandResults",
          "x-ms-client-flatten": true
        }
      }
    },
    "PowerShellSessionResource": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "description": "A PowerShell session resource (practically equivalent to a runspace instance).",
      "properties": {
        "properties": {
          "properties": {
            "disconnectedOn": {
              "description": "Timestamp of last time the service disconnected from the runspace.",
              "format": "date-time",
              "type": "string"
            },
            "expiresOn": {
              "description": "Timestamp when the runspace expires.",
              "format": "date-time",
              "type": "string"
            },
            "name": {
              "description": "Name of the runspace.",
              "type": "string"
            },
            "runspaceAvailability": {
              "description": "The availability of the runspace.",
              "type": "string"
            },
            "sessionId": {
              "description": "The PowerShell Session ID.",
              "type": "string"
            },
            "state": {
              "description": "The runspace state.",
              "type": "string"
            },
            "version": {
              "$ref": "#/definitions/Version"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "PowerShellSessionResources": {
      "description": "A collection of PowerShell session resources.",
      "properties": {
        "nextLink": {
          "description": "The URL to the next set of resources.",
          "type": "string"
        },
        "value": {
          "description": "Collection of PowerShell session resources.",
          "items": {
            "$ref": "#/definitions/PowerShellSessionResource"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "PowerShellTabCompletionParameters": {
      "properties": {
        "command": {
          "description": "Command to get tab completion for.",
          "type": "string"
        }
      }
    },
    "PowerShellTabCompletionResults": {
      "description": "An array of strings representing the different values that can be selected through.",
      "properties": {
        "results": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      }
    },
    "PromptFieldDescription": {
      "description": "Field description for the implementation of PSHostUserInterface.Prompt.",
      "properties": {
        "helpMessage": {
          "description": "The help message of the prompt.",
          "type": "string"
        },
        "label": {
          "description": "The label text of the prompt.",
          "type": "string"
        },
        "name": {
          "description": "The name of the prompt.",
          "type": "string"
        },
        "promptFieldType": {
          "enum": [
            "String",
            "SecureString",
            "Credential"
          ],
          "type": "string",
          "x-ms-enum": {
            "modelAsString": false,
            "name": "PromptFieldType"
          }
        },
        "promptFieldTypeIsList": {
          "description": "When set to 'true' the prompt field type is a list of values.",
          "type": "boolean"
        }
      }
    },
    "PromptMessageResponse": {
      "description": "The response to a prompt message.",
      "properties": {
        "response": {
          "description": "The list of responses a cmdlet expects.",
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      }
    },
    "Resource": {
      "description": "Resource Manager Resource Information.",
      "properties": {
        "etag": {
          "type": "string"
        },
        "id": {
          "description": "Resource Manager Resource ID.",
          "readOnly": true,
          "type": "string"
        },
        "location": {
          "description": "Resource Manager Resource Location.",
          "readOnly": true,
          "type": "string"
        },
        "name": {
          "description": "Resource Manager Resource Name.",
          "readOnly": true,
          "type": "string"
        },
        "tags": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "Resource Manager Resource Tags.",
          "type": "object"
        },
        "type": {
          "description": "Resource Manager Resource Type.",
          "readOnly": true,
          "type": "string"
        }
      },
      "x-ms-azure-resource": true
    },
    "SessionParameters": {
      "properties": {
        "properties": {
          "properties": {
            "password": {
              "description": "Password associated with user name.",
              "format": "password",
              "type": "string"
            },
            "userName": {
              "description": "User name to be used to connect to node.",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "SessionResource": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "description": "The session object.",
      "properties": {
        "properties": {
          "properties": {
            "created": {
              "description": "UTC date and time when node was first added to management service.",
              "format": "date-time",
              "type": "string"
            },
            "updated": {
              "description": "UTC date and time when node was last updated.",
              "format": "date-time",
              "type": "string"
            },
            "userName": {
              "description": "The username connecting to the session.",
              "type": "string"
            }
          },
          "type": "object",
          "x-ms-client-flatten": true
        }
      }
    },
    "Version": {
      "description": "A multipart-numeric version number.",
      "properties": {
        "build": {
          "description": "The third number of the version.",
          "type": "integer"
        },
        "major": {
          "description": "The leftmost number of the version.",
          "type": "integer"
        },
        "majorRevision": {
          "description": "The MSW of the fourth part.",
          "type": "integer"
        },
        "minor": {
          "description": "The second leftmost number of the version.",
          "type": "integer"
        },
        "minorRevision": {
          "description": "The LSW of the fourth part.",
          "type": "integer"
        },
        "revision": {
          "description": "The fourth number of the version.",
          "type": "integer"
        }
      }
    }
  }
}