{
  "description": "View is the Schema for the Views API.\nSee also https://coralogix.com/docs/user-guides/monitoring-and-insights/explore-screen/custom-views/\n\n**Added in v0.4.0**",
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
      "type": "string"
    },
    "kind": {
      "description": "Kind is a string value representing the REST resource this object represents.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": "string"
    },
    "metadata": {
      "type": "object"
    },
    "spec": {
      "description": "ViewSpec defines the desired state of View.",
      "properties": {
        "filters": {
          "description": "Filters is the filters for the view.",
          "properties": {
            "filters": {
              "description": "Filters is the list of filters for the view.",
              "items": {
                "properties": {
                  "name": {
                    "description": "Name is the name of the filter.",
                    "type": "string"
                  },
                  "selectedValues": {
                    "additionalProperties": {
                      "type": "boolean"
                    },
                    "description": "SelectedValues is the selected values for the filter.",
                    "type": "object"
                  }
                },
                "required": [
                  "name",
                  "selectedValues"
                ],
                "type": "object",
                "additionalProperties": false
              },
              "minItems": 1,
              "type": "array"
            }
          },
          "required": [
            "filters"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "folder": {
          "description": "Folder is the folder to which the view belongs.",
          "properties": {
            "resourceRef": {
              "description": "ViewFolder custom resource name and namespace. If namespace is not set, the View namespace will be used.",
              "properties": {
                "name": {
                  "description": "Name of the resource (not id).",
                  "type": "string"
                },
                "namespace": {
                  "description": "Kubernetes namespace.",
                  "type": "string"
                }
              },
              "required": [
                "name"
              ],
              "type": "object",
              "additionalProperties": false
            }
          },
          "required": [
            "resourceRef"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "name": {
          "description": "Name of the view.",
          "type": "string"
        },
        "searchQuery": {
          "description": "SearchQuery is the search query for the view.",
          "properties": {
            "query": {
              "description": "Query is the search query.",
              "type": "string"
            }
          },
          "required": [
            "query"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "timeSelection": {
          "description": "TimeSelection is the time selection for the view. Exactly one of quickSelection or customSelection must be set.",
          "properties": {
            "customSelection": {
              "description": "CustomSelection is the custom selection for the view.",
              "properties": {
                "fromTime": {
                  "description": "FromTime is the start time for the custom selection.",
                  "format": "date-time",
                  "type": "string"
                },
                "toTime": {
                  "description": "ToTime is the end time for the custom selection.",
                  "format": "date-time",
                  "type": "string"
                }
              },
              "required": [
                "fromTime",
                "toTime"
              ],
              "type": "object",
              "additionalProperties": false
            },
            "quickSelection": {
              "description": "QuickSelection is the quick selection for the view.",
              "properties": {
                "seconds": {
                  "description": "Seconds is the number of seconds for the quick selection.",
                  "format": "int32",
                  "type": "integer"
                }
              },
              "required": [
                "seconds"
              ],
              "type": "object",
              "additionalProperties": false
            }
          },
          "type": "object",
          "x-kubernetes-validations": [
            {
              "message": "Exactly one of quickSelection or customSelection must be set",
              "rule": "has(self.quickSelection) != has(self.customSelection)"
            }
          ],
          "additionalProperties": false
        }
      },
      "required": [
        "filters",
        "name",
        "timeSelection"
      ],
      "type": "object",
      "additionalProperties": false
    },
    "status": {
      "description": "ViewStatus defines the observed state of View.",
      "properties": {
        "conditions": {
          "items": {
            "description": "Condition contains details for one aspect of the current state of this API Resource.",
            "properties": {
              "lastTransitionTime": {
                "description": "lastTransitionTime is the last time the condition transitioned from one status to another.\nThis should be when the underlying condition changed.  If that is not known, then using the time when the API field changed is acceptable.",
                "format": "date-time",
                "type": "string"
              },
              "message": {
                "description": "message is a human readable message indicating details about the transition.\nThis may be an empty string.",
                "maxLength": 32768,
                "type": "string"
              },
              "observedGeneration": {
                "description": "observedGeneration represents the .metadata.generation that the condition was set based upon.\nFor instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date\nwith respect to the current state of the instance.",
                "format": "int64",
                "minimum": 0,
                "type": "integer"
              },
              "reason": {
                "description": "reason contains a programmatic identifier indicating the reason for the condition's last transition.\nProducers of specific condition types may define expected values and meanings for this field,\nand whether the values are considered a guaranteed API.\nThe value should be a CamelCase string.\nThis field may not be empty.",
                "maxLength": 1024,
                "minLength": 1,
                "pattern": "^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$",
                "type": "string"
              },
              "status": {
                "description": "status of the condition, one of True, False, Unknown.",
                "enum": [
                  "True",
                  "False",
                  "Unknown"
                ],
                "type": "string"
              },
              "type": {
                "description": "type of condition in CamelCase or in foo.example.com/CamelCase.",
                "maxLength": 316,
                "pattern": "^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$",
                "type": "string"
              }
            },
            "required": [
              "lastTransitionTime",
              "message",
              "reason",
              "status",
              "type"
            ],
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "id": {
          "type": "string"
        },
        "printableStatus": {
          "type": "string"
        }
      },
      "type": "object",
      "additionalProperties": false
    }
  },
  "type": "object"
}
