{
  "$schema": "http://json-schema.org/draft-06/schema#",
  "title": "TimeSeriesParametersResponse",
  "description": "TimeSeriesParameters PI_JSON",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "version",
    "timeSeriesParameters"
  ],
  "properties": {
    "version": {
      "type": "string",
      "description": "PI Version"
    },
    "timeSeriesParameters": {
      "type": "array",
      "description": "TimeSeriesParameters",
      "items": {
        "$ref": "#/definitions/TimeSeriesParameter"
      }
    }
  },
  "definitions": {
    "TimeSeriesParameter": {
      "type": "object",
      "required": [
        "id"
      ],
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string",
          "description": "the id of the parameter"
        },
        "name": {
          "type": "string",
          "description": "The parameter name"
        },
        "parameterType": {
          "type": "string",
          "description": "The parameter type"
        },
        "unit": {
          "type": "string",
          "description": "The parameter unit"
        },
        "displayUnit": {
          "type": "string",
          "description": "The parameter display unit"
        },
        "usesDatum": {
          "type": "string",
          "title": "UseDatum",
          "enum": [
            "true",
            "false"
          ],
          "description": "Is a datum used"
        },
        "parameterGroup": {
          "type": "string",
          "description": "The id of the parameter group this parameter is a member of"
        },
        "parameterGroupName": {
          "type": "string",
          "description": "The name of parameter group this parameter is a member of"
        },
        "shortName": {
          "type": "string",
          "description": "The parameter group this parameter is a member of"
        },
        "attributes": {
          "type": "array",
          "description": "Parameter Attributes",
          "items": {
            "$ref": "#/definitions/TimeSeriesParameterAttributes"
          }
        }
      }
    },
    "TimeSeriesParameterAttributes": {
      "type": "object",
      "title": "TimeSeriesParameterAttributes",
      "additionalProperties": false,
      "required": [
        "name"
      ],
      "properties": {
        "name": {
          "type": "string",
          "description": "Name"
        },
        "description": {
          "type": "string",
          "description": "Description"
        },
        "type": {
          "enum": [
            "text",
            "boolean",
            "number",
            "dateTime"
          ],
          "type": "string",
          "description": "Type"
        },
        "id": {
          "type": "string",
          "description": "Id"
        },
        "startDateTime": {
          "type": "string",
          "description": "Start date time"
        },
        "endDateTime": {
          "type": "string",
          "description": "End date time"
        },
        "value": {
          "type": "string",
          "description": "Value"
        }
      }
    }
  }
}

