Skip to content

aws.synthetics.get_canary

Example SQL Queries

SELECT * FROM
aws.synthetics.get_canary
WHERE
"name" = 'VALUE';

Description

Retrieves complete information about one canary. You must specify the name of the canary that you want. To get a list of canaries and their names, use DescribeCanaries.

Table Definition

Column NameColumn Data Type
name Required Input Column

The name of the canary that you want details for.

VARCHAR
_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
canary

A structure that contains the full information about the canary.

STRUCT(
"id" VARCHAR,
"name" VARCHAR,
"code" STRUCT(
"source_location_arn" VARCHAR,
"handler" VARCHAR
),
"execution_role_arn" VARCHAR,
"schedule" STRUCT(
"expression" VARCHAR,
"duration_in_seconds" BIGINT
),
"run_config" STRUCT(
"timeout_in_seconds" BIGINT,
"memory_in_mb" BIGINT,
"active_tracing" BOOLEAN
),
"success_retention_period_in_days" BIGINT,
"failure_retention_period_in_days" BIGINT,
"status" STRUCT(
"state" VARCHAR,
"state_reason" VARCHAR,
"state_reason_code" VARCHAR
),
"timeline" STRUCT(
"created" TIMESTAMP_S,
"last_modified" TIMESTAMP_S,
"last_started" TIMESTAMP_S,
"last_stopped" TIMESTAMP_S
),
"artifact_s3_location" VARCHAR,
"engine_arn" VARCHAR,
"runtime_version" VARCHAR,
"vpc_config" STRUCT(
"vpc_id" VARCHAR,
"subnet_ids" VARCHAR[],
"security_group_ids" VARCHAR[]
),
"visual_reference" STRUCT(
"base_screenshots" STRUCT(
"screenshot_name" VARCHAR,
"ignore_coordinates" VARCHAR[]
)[],
"base_canary_run_id" VARCHAR
),
"tags" MAP(VARCHAR, VARCHAR),
"artifact_config" STRUCT(
"s3_encryption" STRUCT(
"encryption_mode" VARCHAR,
"kms_key_arn" VARCHAR
)
)
)
Show child fields
canary.artifact_config

A structure that contains the configuration for canary artifacts, including the encryption-at-rest settings for artifacts that the canary uploads to Amazon S3.

Show child fields
canary.artifact_config.s3_encryption

A structure that contains the configuration of encryption settings for canary artifacts that are stored in Amazon S3.

Show child fields
canary.artifact_config.s3_encryption.encryption_mode

The encryption method to use for artifacts created by this canary. Specify SSE_S3 to use server-side encryption (SSE) with an Amazon S3-managed key. Specify SSE-KMS to use server-side encryption with a customer-managed KMS key.

If you omit this parameter, an Amazon Web Services-managed KMS key is used.

canary.artifact_config.s3_encryption.kms_key_arn

The ARN of the customer-managed KMS key to use, if you specify SSE-KMS for EncryptionMode

canary.artifact_s3_location

The location in Amazon S3 where Synthetics stores artifacts from the runs of this canary. Artifacts include the log file, screenshots, and HAR files.

canary.code

This structure contains information about the canary's Lambda handler and where its code is stored by CloudWatch Synthetics.

Show child fields
canary.code.handler

The entry point to use for the source code when running the canary.

canary.code.source_location_arn

The ARN of the Lambda layer where Synthetics stores the canary script code.

canary.engine_arn

The ARN of the Lambda function that is used as your canary's engine. For more information about Lambda ARN format, see Resources and Conditions for Lambda Actions.

canary.execution_role_arn

The ARN of the IAM role used to run the canary. This role must include lambda.amazonaws.com as a principal in the trust policy.

canary.failure_retention_period_in_days

The number of days to retain data about failed runs of this canary.

canary.id

The unique ID of this canary.

canary.name

The name of the canary.

canary.run_config

A structure that contains information about a canary run.

Show child fields
canary.run_config.active_tracing

Displays whether this canary run used active X-Ray tracing.

canary.run_config.memory_in_mb

The maximum amount of memory available to the canary while it is running, in MB. This value must be a multiple of 64.

canary.run_config.timeout_in_seconds

How long the canary is allowed to run before it must stop.

canary.runtime_version

Specifies the runtime version to use for the canary. For more information about runtime versions, see Canary Runtime Versions.

canary.schedule

A structure that contains information about how often the canary is to run, and when these runs are to stop.

Show child fields
canary.schedule.duration_in_seconds

How long, in seconds, for the canary to continue making regular runs after it was created. The runs are performed according to the schedule in the Expression value.

canary.schedule.expression

A rate expression or a cron expression that defines how often the canary is to run.

For a rate expression, The syntax is rate(number unit). unit can be minute, minutes, or hour.

For example, rate(1 minute) runs the canary once a minute, rate(10 minutes) runs it once every 10 minutes, and rate(1 hour) runs it once every hour. You can specify a frequency between rate(1 minute) and rate(1 hour).

Specifying rate(0 minute) or rate(0 hour) is a special value that causes the canary to run only once when it is started.

Use cron(expression) to specify a cron expression. For information about the syntax for cron expressions, see Scheduling canary runs using cron.

canary.status

A structure that contains information about the canary's status.

Show child fields
canary.status.state

The current state of the canary.

canary.status.state_reason

If the canary has insufficient permissions to run, this field provides more details.

canary.status.state_reason_code

If the canary cannot run or has failed, this field displays the reason.

canary.success_retention_period_in_days

The number of days to retain data about successful runs of this canary.

canary.tags

The list of key-value pairs that are associated with the canary.

canary.timeline

A structure that contains information about when the canary was created, modified, and most recently run.

Show child fields
canary.timeline.created

The date and time the canary was created.

canary.timeline.last_modified

The date and time the canary was most recently modified.

canary.timeline.last_started

The date and time that the canary's most recent run started.

canary.timeline.last_stopped

The date and time that the canary's most recent run ended.

canary.visual_reference

If this canary performs visual monitoring by comparing screenshots, this structure contains the ID of the canary run to use as the baseline for screenshots, and the coordinates of any parts of the screen to ignore during the visual monitoring comparison.

Show child fields
canary.visual_reference.base_canary_run_id

The ID of the canary run that produced the baseline screenshots that are used for visual monitoring comparisons by this canary.

canary.visual_reference.base_screenshots[]
Show child fields
canary.visual_reference.base_screenshots[].ignore_coordinates[]
canary.visual_reference.base_screenshots[].screenshot_name

The name of the screenshot. This is generated the first time the canary is run after the UpdateCanary operation that specified for this canary to perform visual monitoring.

canary.vpc_config

If this canary is to test an endpoint in a VPC, this structure contains information about the subnets and security groups of the VPC endpoint. For more information, see Running a Canary in a VPC.

Show child fields
canary.vpc_config.security_group_ids[]
canary.vpc_config.subnet_ids[]
canary.vpc_config.vpc_id

The IDs of the VPC where this canary is to run.