{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-opensearch/json-schema/amazon-opensearch-update-package-request-schema.json",
  "title": "UpdatePackageRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-opensearch-packages-api-openapi.yml#/components/schemas/UpdatePackageRequest",
  "type": "object",
  "properties": {
    "PackageID": {
      "type": "string",
      "description": "The unique identifier for the package."
    },
    "PackageSource": {
      "$ref": "#/$defs/PackageSource"
    },
    "PackageDescription": {
      "type": "string",
      "description": "A new description of the package."
    },
    "CommitMessage": {
      "type": "string",
      "description": "Commit message for the updated file, which is shown as part of GetPackageVersionHistoryResponse."
    },
    "PackageConfiguration": {
      "$ref": "#/$defs/PackageConfiguration"
    },
    "PackageEncryptionOptions": {
      "$ref": "#/$defs/PackageEncryptionOptions"
    }
  },
  "required": [
    "PackageID",
    "PackageSource"
  ],
  "$defs": {
    "PackageConfiguration": {
      "type": "object",
      "properties": {
        "LicenseRequirement": {
          "type": "string",
          "enum": [
            "REQUIRED",
            "OPTIONAL",
            "NONE"
          ],
          "description": "The license requirements for the package."
        },
        "LicenseFilepath": {
          "type": "string",
          "description": "The relative file path for the license associated with the package."
        },
        "ConfigurationRequirement": {
          "type": "string",
          "enum": [
            "REQUIRED",
            "OPTIONAL",
            "NONE"
          ],
          "description": "The configuration requirements for the package."
        },
        "RequiresRestartForConfigurationUpdate": {
          "type": "boolean",
          "description": "This indicates whether a B/G deployment is required for updating the configuration that the plugin is prerequisite for."
        }
      },
      "required": [
        "LicenseRequirement",
        "ConfigurationRequirement"
      ]
    },
    "PackageEncryptionOptions": {
      "type": "object",
      "properties": {
        "KmsKeyIdentifier": {
          "type": "string",
          "description": "KMS key ID for encrypting the package."
        },
        "EncryptionEnabled": {
          "type": "boolean",
          "description": "Whether encryption is enabled for the package."
        }
      },
      "required": [
        "EncryptionEnabled"
      ]
    },
    "PackageSource": {
      "type": "object",
      "properties": {
        "S3BucketName": {
          "type": "string",
          "description": "The name of the Amazon S3 bucket containing the package."
        },
        "S3Key": {
          "type": "string",
          "description": "Key (file name) of the package."
        }
      }
    }
  }
}