{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/aws-glue/json-schema/aws-glue-get-database-response-schema.json",
  "title": "GetDatabaseResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/aws-glue-aws-glue-x-amz-target-awsglue-getdatabase-api-api-openapi.yml#/components/schemas/GetDatabaseResponse",
  "type": "object",
  "properties": {
    "Database": {
      "$ref": "#/$defs/Database"
    }
  },
  "$defs": {
    "DataLakePrincipal": {
      "type": "object",
      "properties": {
        "DataLakePrincipalIdentifier": {
          "type": "string",
          "description": "An identifier for the Lake Formation principal."
        }
      }
    },
    "Database": {
      "type": "object",
      "properties": {
        "Name": {
          "type": "string",
          "description": "The name of the database. For Hive compatibility, this is folded to lowercase when it is stored."
        },
        "Description": {
          "type": "string",
          "description": "A description of the database."
        },
        "LocationUri": {
          "type": "string",
          "description": "The location of the database (for example, an HDFS path)."
        },
        "Parameters": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "These key-value pairs define parameters and properties of the database."
        },
        "CreateTime": {
          "type": "string",
          "format": "date-time",
          "description": "The time at which the metadata database was created in the catalog."
        },
        "CreateTableDefaultPermissions": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/PrincipalPermissions"
          },
          "description": "Creates a set of default permissions on the table for principals. Used by Lake Formation. Not used in the normal course of Glue operations."
        },
        "TargetDatabase": {
          "$ref": "#/$defs/DatabaseIdentifier"
        },
        "CatalogId": {
          "type": "string",
          "description": "The ID of the Data Catalog in which the database resides."
        },
        "FederatedDatabase": {
          "$ref": "#/$defs/FederatedDatabase"
        }
      },
      "required": [
        "Name"
      ]
    },
    "DatabaseIdentifier": {
      "type": "object",
      "properties": {
        "CatalogId": {
          "type": "string",
          "description": "The ID of the Data Catalog in which the database resides."
        },
        "DatabaseName": {
          "type": "string",
          "description": "The name of the catalog database."
        },
        "Region": {
          "type": "string",
          "description": "Region of the target database."
        }
      }
    },
    "FederatedDatabase": {
      "type": "object",
      "properties": {
        "Identifier": {
          "type": "string",
          "description": "A unique identifier for the federated database."
        },
        "ConnectionName": {
          "type": "string",
          "description": "The name of the connection to the external metastore."
        },
        "ConnectionType": {
          "type": "string",
          "description": "The type of connection used to access the federated database, such as JDBC, ODBC, or other supported connection protocols."
        }
      }
    },
    "PrincipalPermissions": {
      "type": "object",
      "properties": {
        "Principal": {
          "$ref": "#/$defs/DataLakePrincipal"
        },
        "Permissions": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "ALL",
              "SELECT",
              "ALTER",
              "DROP",
              "DELETE",
              "INSERT",
              "CREATE_DATABASE",
              "CREATE_TABLE",
              "DATA_LOCATION_ACCESS"
            ]
          },
          "description": "The permissions that are granted to the principal."
        }
      }
    }
  }
}