Skip to content

aws.docdb.describe_db_instances

Example SQL Queries

SELECT * FROM
aws.docdb.describe_db_instances;

Description

Returns information about provisioned Amazon DocumentDB instances. This API supports pagination.

Table Definition

Column NameColumn Data Type
db_instance_identifier Input Column

Contains a user-provided database identifier. This identifier is the unique key that identifies an instance.

VARCHAR
filters Input Column

A filter that specifies one or more instances to describe.

Supported filters:

  • db-cluster-id - Accepts cluster identifiers and cluster Amazon Resource Names (ARNs). The results list includes only the information about the instances that are associated with the clusters that are identified by these ARNs.

  • db-instance-id - Accepts instance identifiers and instance ARNs. The results list includes only the information about the instances that are identified by these ARNs.

STRUCT(
"name" VARCHAR,
"values" VARCHAR[]
)[]
Show child fields
filters[]
Show child fields
filters[].name

The name of the filter. Filter names are case sensitive.

filters[].values[]
_aws_profile Input Column

The AWS profile defines the AWS identity used. It can be defined via credentials or by assuming a IAM role.

STRUCT(
"type" VARCHAR,
"name" VARCHAR,
"account_id" VARCHAR,
"via_profile_name" VARCHAR,
"assumed_role_arn" VARCHAR,
"organization" STRUCT(
"account_name" VARCHAR,
"id" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[],
"master_account" STRUCT(
"id" VARCHAR,
"email" VARCHAR
),
"parents" STRUCT(
"type" VARCHAR,
"id" VARCHAR,
"name" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[]
)[]
)
)
Show child fields
_aws_profile.account_id

The AWS account id

_aws_profile.assumed_role_arn

The ARN of the assumed role

_aws_profile.name

The unique name of the profile.

_aws_profile.organization

Information about this profile's membership in the AWS organization.

Show child fields
_aws_profile.organization.account_name

The name of account speciifed by the organization

_aws_profile.organization.id

The organization id

_aws_profile.organization.master_account
Show child fields
_aws_profile.organization.master_account.email

The organization master account email address

_aws_profile.organization.master_account.id

The organization master account id

_aws_profile.organization.parents[]
Show child fields
_aws_profile.organization.parents[].id

The id of the parent

_aws_profile.organization.parents[].name

The name of the parent

_aws_profile.organization.parents[].tags[]
Show child fields
_aws_profile.organization.parents[].tags[].key
_aws_profile.organization.parents[].tags[].value
_aws_profile.organization.parents[].type

The type of parent can be an organization unit or a root

_aws_profile.organization.tags[]
Show child fields
_aws_profile.organization.tags[].key
_aws_profile.organization.tags[].value
_aws_profile.type

The type of profile, either 'credentials' or 'assumed_role'

_aws_profile.via_profile_name

This IAM role for this profile is assumed by first utilizing another profile with this name to obtain credentials.

_aws_region Input Column

The AWS region to use.

VARCHAR
auto_minor_version_upgrade

Does not apply. This parameter does not apply to Amazon DocumentDB. Amazon DocumentDB does not perform minor version upgrades regardless of the value set.

BOOLEAN
availability_zone

Specifies the name of the Availability Zone that the instance is located in.

VARCHAR
backup_retention_period

Specifies the number of days for which automatic snapshots are retained.

BIGINT
ca_certificate_identifier

The identifier of the CA certificate for this DB instance.

VARCHAR
certificate_details

The details of the DB instance's server certificate.

STRUCT(
"ca_identifier" VARCHAR,
"valid_till" TIMESTAMP_S
)
Show child fields
certificate_details.ca_identifier

The CA identifier of the CA certificate used for the DB instance's server certificate.

certificate_details.valid_till

The expiration date of the DB instance’s server certificate.

copy_tags_to_snapshot

A value that indicates whether to copy tags from the DB instance to snapshots of the DB instance. By default, tags are not copied.

BOOLEAN
db_cluster_identifier

Contains the name of the cluster that the instance is a member of if the instance is a member of a cluster.

VARCHAR
db_instance_arn

The Amazon Resource Name (ARN) for the instance.

VARCHAR
db_instance_class

Contains the name of the compute and memory capacity class of the instance.

VARCHAR
db_instance_status

Specifies the current state of this database.

VARCHAR
db_subnet_group

Specifies information on the subnet group that is associated with the instance, including the name, description, and subnets in the subnet group.

STRUCT(
"db_subnet_group_name" VARCHAR,
"db_subnet_group_description" VARCHAR,
"vpc_id" VARCHAR,
"subnet_group_status" VARCHAR,
"subnets" STRUCT(
"subnet_identifier" VARCHAR,
"subnet_availability_zone" STRUCT(
"name" VARCHAR
),
"subnet_status" VARCHAR
)[],
"db_subnet_group_arn" VARCHAR
)
Show child fields
db_subnet_group.db_subnet_group_arn

The Amazon Resource Name (ARN) for the DB subnet group.

db_subnet_group.db_subnet_group_description

Provides the description of the subnet group.

db_subnet_group.db_subnet_group_name

The name of the subnet group.

db_subnet_group.subnet_group_status

Provides the status of the subnet group.

db_subnet_group.subnets[]
Show child fields
db_subnet_group.subnets[].subnet_availability_zone

Specifies the Availability Zone for the subnet.

Show child fields
db_subnet_group.subnets[].subnet_availability_zone.name

The name of the Availability Zone.

db_subnet_group.subnets[].subnet_identifier

Specifies the identifier of the subnet.

db_subnet_group.subnets[].subnet_status

Specifies the status of the subnet.

db_subnet_group.vpc_id

Provides the virtual private cloud (VPC) ID of the subnet group.

dbi_resource_id

The Amazon Web Services Region-unique, immutable identifier for the instance. This identifier is found in CloudTrail log entries whenever the KMS key for the instance is accessed.

VARCHAR
enabled_cloudwatch_logs_exports

A list of log types that this instance is configured to export to CloudWatch Logs.

VARCHAR[]
Show child fields
enabled_cloudwatch_logs_exports[]
endpoint

Specifies the connection endpoint.

STRUCT(
"address" VARCHAR,
"port" BIGINT,
"hosted_zone_id" VARCHAR
)
Show child fields
endpoint.address

Specifies the DNS address of the instance.

endpoint.hosted_zone_id

Specifies the ID that Amazon Route 53 assigns when you create a hosted zone.

endpoint.port

Specifies the port that the database engine is listening on.

engine

Provides the name of the database engine to be used for this instance.

VARCHAR
engine_version

Indicates the database engine version.

VARCHAR
instance_create_time

Provides the date and time that the instance was created.

TIMESTAMP_S
kms_key_id

If StorageEncrypted is true, the KMS key identifier for the encrypted instance.

VARCHAR
latest_restorable_time

Specifies the latest time to which a database can be restored with point-in-time restore.

TIMESTAMP_S
pending_modified_values

Specifies that changes to the instance are pending. This element is included only when changes are pending. Specific changes are identified by subelements.

STRUCT(
"db_instance_class" VARCHAR,
"allocated_storage" BIGINT,
"master_user_password" VARCHAR,
"port" BIGINT,
"backup_retention_period" BIGINT,
"multi_az" BOOLEAN,
"engine_version" VARCHAR,
"license_model" VARCHAR,
"iops" BIGINT,
"db_instance_identifier" VARCHAR,
"storage_type" VARCHAR,
"ca_certificate_identifier" VARCHAR,
"db_subnet_group_name" VARCHAR,
"pending_cloudwatch_logs_exports" STRUCT(
"log_types_to_enable" VARCHAR[],
"log_types_to_disable" VARCHAR[]
)
)
Show child fields
pending_modified_values.allocated_storage

Contains the new AllocatedStorage size for then instance that will be applied or is currently being applied.

pending_modified_values.backup_retention_period

Specifies the pending number of days for which automated backups are retained.

pending_modified_values.ca_certificate_identifier

Specifies the identifier of the certificate authority (CA) certificate for the DB instance.

pending_modified_values.db_instance_class

Contains the new DBInstanceClass for the instance that will be applied or is currently being applied.

pending_modified_values.db_instance_identifier

Contains the new DBInstanceIdentifier for the instance that will be applied or is currently being applied.

pending_modified_values.db_subnet_group_name

The new subnet group for the instance.

pending_modified_values.engine_version

Indicates the database engine version.

pending_modified_values.iops

Specifies the new Provisioned IOPS value for the instance that will be applied or is currently being applied.

pending_modified_values.license_model

The license model for the instance.

Valid values: license-included, bring-your-own-license, general-public-license

pending_modified_values.master_user_password

Contains the pending or currently in-progress change of the master credentials for the instance.

pending_modified_values.multi_az

Indicates that the Single-AZ instance is to change to a Multi-AZ deployment.

pending_modified_values.pending_cloudwatch_logs_exports

A list of the log types whose configuration is still pending. These log types are in the process of being activated or deactivated.

Show child fields
pending_modified_values.pending_cloudwatch_logs_exports.log_types_to_disable[]
pending_modified_values.pending_cloudwatch_logs_exports.log_types_to_enable[]
pending_modified_values.port

Specifies the pending port for the instance.

pending_modified_values.storage_type

Specifies the storage type to be associated with the instance.

performance_insights_enabled

Set to true if Amazon RDS Performance Insights is enabled for the DB instance, and otherwise false.

BOOLEAN
performance_insights_kms_key_id

The KMS key identifier for encryption of Performance Insights data. The KMS key ID is the Amazon Resource Name (ARN), KMS key identifier, or the KMS key alias for the KMS encryption key.

VARCHAR
preferred_backup_window

Specifies the daily time range during which automated backups are created if automated backups are enabled, as determined by the BackupRetentionPeriod.

VARCHAR
preferred_maintenance_window

Specifies the weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).

VARCHAR
promotion_tier

A value that specifies the order in which an Amazon DocumentDB replica is promoted to the primary instance after a failure of the existing primary instance.

BIGINT
publicly_accessible

Not supported. Amazon DocumentDB does not currently support public endpoints. The value of PubliclyAccessible is always false.

BOOLEAN
status_infos

The status of a read replica. If the instance is not a read replica, this is blank.

STRUCT(
"status_type" VARCHAR,
"normal" BOOLEAN,
"status" VARCHAR,
"message" VARCHAR
)[]
Show child fields
status_infos[]
Show child fields
status_infos[].message

Details of the error if there is an error for the instance. If the instance is not in an error state, this value is blank.

status_infos[].normal

A Boolean value that is true if the instance is operating normally, or false if the instance is in an error state.

status_infos[].status

Status of the instance. For a StatusType of read replica, the values can be replicating, error, stopped, or terminated.

status_infos[].status_type

This value is currently "read replication."

storage_encrypted

Specifies whether or not the instance is encrypted.

BOOLEAN
vpc_security_groups

Provides a list of VPC security group elements that the instance belongs to.

STRUCT(
"vpc_security_group_id" VARCHAR,
"status" VARCHAR
)[]
Show child fields
vpc_security_groups[]
Show child fields
vpc_security_groups[].status

The status of the VPC security group.

vpc_security_groups[].vpc_security_group_id

The name of the VPC security group.