{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/microsoft-azure-mysql/json-schema/microsoft-azure-mysql-backup-and-export-request-schema.json",
  "title": "BackupAndExportRequest",
  "description": "BackupAndExport API Request",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/microsoft-azure-mysql-backupandexport-api-openapi.yml#/components/schemas/BackupAndExportRequest",
  "type": "object",
  "properties": {
    "targetDetails": {
      "$ref": "#/$defs/BackupStoreDetails",
      "description": "Backup Target Store Details"
    }
  },
  "required": [
    "targetDetails"
  ],
  "allOf": [
    {
      "$ref": "#/$defs/BackupRequestBase"
    }
  ],
  "$defs": {
    "BackupFormat": {
      "type": "string",
      "description": "Backup Format for the current backup. (CollatedFormat is INTERNAL – DO NOT USE)",
      "enum": [
        "CollatedFormat",
        "Raw"
      ],
      "x-ms-enum": {
        "name": "BackupFormat",
        "modelAsString": true,
        "values": [
          {
            "name": "CollatedFormat",
            "value": "CollatedFormat"
          },
          {
            "name": "Raw",
            "value": "Raw"
          }
        ]
      }
    },
    "BackupRequestBase": {
      "type": "object",
      "description": "BackupRequestBase is the base for all backup request.",
      "properties": {
        "backupSettings": {
          "$ref": "#/$defs/BackupSettings",
          "description": "Backup Settings"
        }
      },
      "required": [
        "backupSettings"
      ]
    },
    "BackupSettings": {
      "type": "object",
      "description": "Backup Settings",
      "properties": {
        "backupName": {
          "type": "string",
          "description": "The name of the backup.",
          "pattern": "(^[a-z0-9]$)|(^[a-z0-9][a-z0-9-]*[a-z0-9]$)"
        },
        "backupFormat": {
          "$ref": "#/$defs/BackupFormat",
          "description": "Backup Format for the current backup. (CollatedFormat is INTERNAL – DO NOT USE)"
        }
      },
      "required": [
        "backupName"
      ]
    },
    "BackupStoreDetails": {
      "type": "object",
      "description": "Details about the target where the backup content will be stored.",
      "properties": {
        "objectType": {
          "type": "string",
          "description": "Type of the specific object - used for deserializing"
        }
      },
      "required": [
        "objectType"
      ]
    }
  }
}