planetscale_databases (Data Source)
June 1, 2026 ยท View on GitHub
Databases DataSource
Example Usage
data "planetscale_databases" "my_databases" {
organization = "...my_organization..."
q = "...my_q..."
}
Schema
Required
organization(String) Organization name slug fromlist_organizations. Example:acme.
Optional
q(String) Search term to filter databases by name
Read-Only
data(Attributes List) (see below for nested schema)type(String) The response type. Always "list" for paginated responses.
Nested Schema for data
Read-Only:
allow_data_branching(Boolean) Whether seeding branches with data is enabled for all branchesat_backup_restore_branches_limit(Boolean) If the database has reached its backup restored branch limitat_development_branch_usage_limit(Boolean) If the database has reached its development branch limitautomatic_migrations(Boolean) Whether to automatically manage Rails migrations during deploy requests.branches_count(Number) The total number of database branchesbranches_url(String) The URL to retrieve this database's branches via the APIcreated_at(String) When the database was createddata_import(Attributes) (see below for nested schema)default_branch(String) The default branch for the databasedefault_branch_read_only_regions_count(Number) Number of read only regions in the default branchdefault_branch_shard_count(Number) Number of shards in the default branchdefault_branch_table_count(Number) Number of tables in the default branch schemadevelopment_branches_count(Number) The total number of database development branchesforeign_keys_enabled(Boolean) Whether foreign key constraints are enabledhtml_url(String) The URL to see this database's branches in the web UIid(String) The ID of the databaseinsights_enabled(Boolean) True if query insights is enabled for the databaseinsights_raw_queries(Boolean) Whether raw SQL queries are collectedissues_count(Number) The total number of ongoing issues within a databasekind(String) The kind of databasemigration_framework(String) Framework used for applying migrations.migration_table_name(String) Table name to use for copying schema migration data.multiple_admins_required_for_deletion(Boolean) If the database requires multiple admins for deletionname(String) Name of the databaseopen_schema_recommendations_count(Number) The total number of schema recommendationsplan(String) The database planproduction_branch_web_console(Boolean) Whether web console is enabled for production branchesproduction_branches_count(Number) The total number of database production branchesready(Boolean) If the database is ready to be usedregion(Attributes) (see below for nested schema)require_approval_for_deploy(Boolean) Whether an approval is required to deploy schema changes to this databaseresize_queued(Boolean) True if a branch has a queued resize requestresizing(Boolean) True if a branch is currently resizingrestrict_branch_region(Boolean) Whether to restrict branch creation to one regionschema_last_updated_at(String) When the default branch schema was last changed.sharded(Boolean) If the database is shardedstate(String) State of the databaseupdated_at(String) When the database was last updatedurl(String) The URL to the database API endpoint
Nested Schema for data.data_import
Read-Only:
data_source(Attributes) (see below for nested schema)finished_at(String) When the import finishedimport_check_errors(String) Errors encountered during the import checkstarted_at(String) When the import startedstate(String) State of the data import
Nested Schema for data.data_import.data_source
Read-Only:
database(String) Database name of the data sourcehostname(String) Hostname of the data sourceport(Number) Port of the data source
Nested Schema for data.region
Read-Only:
current_default(Boolean) True if the region is the default for new branch creationdisplay_name(String) Name of the regionenabled(Boolean) Whether or not the region is currently activeid(String) The ID of the regionlocation(String) Location of the regionmysql_supported(Boolean) Whether the region supports MySQL/Vitess databasespostgresql_supported(Boolean) Whether the region supports PostgreSQL databasesprovider(String) Provider for the region (ex. AWS)public_ip_addresses(List of String) Public IP addresses for the regionslug(String) The slug of the region