{
  "description": "DataDownload acts as the protocol between data mover plugins and data mover controller for the datamover restore operation",
  "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",
        "null"
      ]
    },
    "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",
        "null"
      ]
    },
    "metadata": {
      "type": [
        "object",
        "null"
      ]
    },
    "spec": {
      "additionalProperties": false,
      "description": "DataDownloadSpec is the specification for a DataDownload.",
      "properties": {
        "backupStorageLocation": {
          "description": "BackupStorageLocation is the name of the backup storage location\nwhere the backup repository is stored.",
          "type": "string"
        },
        "cancel": {
          "description": "Cancel indicates request to cancel the ongoing DataDownload. It can be set\nwhen the DataDownload is in InProgress phase",
          "type": [
            "boolean",
            "null"
          ]
        },
        "dataMoverConfig": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "DataMoverConfig is for data-mover-specific configuration fields.",
          "type": [
            "object",
            "null"
          ]
        },
        "datamover": {
          "description": "DataMover specifies the data mover to be used by the backup.\nIf DataMover is \"\" or \"velero\", the built-in data mover will be used.",
          "type": [
            "string",
            "null"
          ]
        },
        "nodeOS": {
          "description": "NodeOS is OS of the node where the DataDownload is processed.",
          "enum": [
            "auto",
            "linux",
            "windows"
          ],
          "type": [
            "string",
            "null"
          ]
        },
        "operationTimeout": {
          "description": "OperationTimeout specifies the time used to wait internal operations,\nbefore returning error as timeout.",
          "type": "string"
        },
        "snapshotID": {
          "description": "SnapshotID is the ID of the Velero backup snapshot to be restored from.",
          "type": "string"
        },
        "sourceNamespace": {
          "description": "SourceNamespace is the original namespace where the volume is backed up from.\nIt may be different from SourcePVC's namespace if namespace is remapped during restore.",
          "type": "string"
        },
        "targetVolume": {
          "additionalProperties": false,
          "description": "TargetVolume is the information of the target PVC and PV.",
          "properties": {
            "namespace": {
              "description": "Namespace is the target namespace",
              "type": "string"
            },
            "pv": {
              "description": "PV is the name of the target PV that is created by Velero restore",
              "type": "string"
            },
            "pvc": {
              "description": "PVC is the name of the target PVC that is created by Velero restore",
              "type": "string"
            }
          },
          "required": [
            "namespace",
            "pv",
            "pvc"
          ],
          "type": "object"
        }
      },
      "required": [
        "backupStorageLocation",
        "operationTimeout",
        "snapshotID",
        "sourceNamespace",
        "targetVolume"
      ],
      "type": [
        "object",
        "null"
      ]
    },
    "status": {
      "additionalProperties": false,
      "description": "DataDownloadStatus is the current status of a DataDownload.",
      "properties": {
        "acceptedByNode": {
          "description": "Node is name of the node where the DataUpload is prepared.",
          "type": [
            "string",
            "null"
          ]
        },
        "acceptedTimestamp": {
          "description": "AcceptedTimestamp records the time the DataUpload is to be prepared.\nThe server's time is used for AcceptedTimestamp",
          "format": "date-time",
          "nullable": true,
          "type": [
            "string",
            "null"
          ]
        },
        "completionTimestamp": {
          "description": "CompletionTimestamp records the time a restore was completed.\nCompletion time is recorded even on failed restores.\nThe server's time is used for CompletionTimestamps",
          "format": "date-time",
          "nullable": true,
          "type": [
            "string",
            "null"
          ]
        },
        "message": {
          "description": "Message is a message about the DataDownload's status.",
          "type": [
            "string",
            "null"
          ]
        },
        "node": {
          "description": "Node is name of the node where the DataDownload is processed.",
          "type": [
            "string",
            "null"
          ]
        },
        "phase": {
          "description": "Phase is the current state of the DataDownload.",
          "enum": [
            "New",
            "Accepted",
            "Prepared",
            "InProgress",
            "Canceling",
            "Canceled",
            "Completed",
            "Failed"
          ],
          "type": [
            "string",
            "null"
          ]
        },
        "progress": {
          "additionalProperties": false,
          "description": "Progress holds the total number of bytes of the snapshot and the current\nnumber of restored bytes. This can be used to display progress information\nabout the restore operation.",
          "properties": {
            "bytesDone": {
              "format": "int64",
              "type": [
                "integer",
                "null"
              ]
            },
            "totalBytes": {
              "format": "int64",
              "type": [
                "integer",
                "null"
              ]
            }
          },
          "type": [
            "object",
            "null"
          ]
        },
        "startTimestamp": {
          "description": "StartTimestamp records the time a restore was started.\nThe server's time is used for StartTimestamps",
          "format": "date-time",
          "nullable": true,
          "type": [
            "string",
            "null"
          ]
        }
      },
      "type": [
        "object",
        "null"
      ]
    }
  },
  "type": "object"
}