{
  "description": "AtlasBackupSchedule is the Schema for the atlasbackupschedules API.",
  "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": "AtlasBackupScheduleSpec defines the target state of AtlasBackupSchedule.",
      "properties": {
        "autoExportEnabled": {
          "default": false,
          "description": "Specify true to enable automatic export of cloud backup snapshots to the AWS bucket. You must also define the export policy using export. If omitted, defaults to false.",
          "type": "boolean"
        },
        "copySettings": {
          "description": "Copy backups to other regions for increased resiliency and faster restores.",
          "items": {
            "properties": {
              "cloudProvider": {
                "default": "AWS",
                "description": "Identifies the cloud provider that stores the snapshot copy.",
                "enum": [
                  "AWS",
                  "GCP",
                  "AZURE"
                ],
                "type": "string"
              },
              "frequencies": {
                "description": "List that describes which types of snapshots to copy.",
                "items": {
                  "type": "string"
                },
                "minItems": 1,
                "type": "array"
              },
              "regionName": {
                "description": "Target region to copy snapshots belonging to replicationSpecId to.",
                "type": "string"
              },
              "shouldCopyOplogs": {
                "description": "Flag that indicates whether to copy the oplogs to the target region.",
                "type": "boolean"
              }
            },
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "export": {
          "description": "Export policy for automatically exporting cloud backup snapshots to AWS bucket.",
          "properties": {
            "exportBucketId": {
              "description": "Unique Atlas identifier of the AWS bucket which was granted access to export backup snapshot.",
              "type": "string"
            },
            "frequencyType": {
              "default": "monthly",
              "description": "Human-readable label that indicates the rate at which the export policy item occurs.",
              "enum": [
                "monthly"
              ],
              "type": "string"
            }
          },
          "required": [
            "exportBucketId",
            "frequencyType"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "policy": {
          "description": "A reference (name & namespace) for backup policy in the desired updated backup policy.",
          "properties": {
            "name": {
              "description": "Name of the Kubernetes Resource",
              "type": "string"
            },
            "namespace": {
              "description": "Namespace of the Kubernetes Resource",
              "type": "string"
            }
          },
          "required": [
            "name"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "referenceHourOfDay": {
          "description": "UTC Hour of day between 0 and 23, inclusive, representing which hour of the day that Atlas takes snapshots for backup policy items",
          "format": "int64",
          "maximum": 23,
          "minimum": 0,
          "type": "integer"
        },
        "referenceMinuteOfHour": {
          "description": "UTC Minutes after ReferenceHourOfDay that Atlas takes snapshots for backup policy items. Must be between 0 and 59, inclusive.",
          "format": "int64",
          "maximum": 59,
          "minimum": 0,
          "type": "integer"
        },
        "restoreWindowDays": {
          "default": 1,
          "description": "Number of days back in time you can restore to with Continuous Cloud Backup accuracy. Must be a positive, non-zero integer. Applies to continuous cloud backups only.",
          "format": "int64",
          "type": "integer"
        },
        "updateSnapshots": {
          "description": "Specify true to apply the retention changes in the updated backup policy to snapshots that Atlas took previously.",
          "type": "boolean"
        },
        "useOrgAndGroupNamesInExportPrefix": {
          "description": "Specify true to use organization and project names instead of organization and project UUIDs in the path for the metadata files that Atlas uploads to your S3 bucket after it finishes exporting the snapshots",
          "type": "boolean"
        }
      },
      "required": [
        "policy"
      ],
      "type": "object",
      "additionalProperties": false
    },
    "status": {
      "description": "BackupScheduleStatus defines the observed state of AtlasBackupSchedule.",
      "properties": {
        "conditions": {
          "description": "Conditions is the list of statuses showing the current state of the Atlas Custom Resource",
          "items": {
            "description": "Condition describes the state of an Atlas Custom Resource at a certain point.",
            "properties": {
              "lastTransitionTime": {
                "description": "Last time the condition transitioned from one status to another.\nRepresented in ISO 8601 format.",
                "format": "date-time",
                "type": "string"
              },
              "message": {
                "description": "A message providing details about the transition.",
                "type": "string"
              },
              "reason": {
                "description": "The reason for the condition's last transition.",
                "type": "string"
              },
              "status": {
                "description": "Status of the condition; one of True, False, Unknown.",
                "type": "string"
              },
              "type": {
                "description": "Type of Atlas Custom Resource condition.",
                "type": "string"
              }
            },
            "required": [
              "status",
              "type"
            ],
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "deploymentID": {
          "description": "List of the human-readable names of all deployments utilizing this backup schedule.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "observedGeneration": {
          "description": "ObservedGeneration indicates the generation of the resource specification of which the Atlas Operator is aware.\nThe Atlas Operator updates this field to the value of 'metadata.generation' as soon as it starts reconciliation of the resource.",
          "format": "int64",
          "type": "integer"
        }
      },
      "required": [
        "conditions"
      ],
      "type": "object",
      "additionalProperties": false
    }
  },
  "type": "object"
}
