Skip to main content

connections

Creates, updates, deletes, gets or lists a connections resource.

Overview

Nameconnections
TypeResource
Idaws.events.connections

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
auth_parametersobjectThe parameters to use for authorization for the connection.
authorization_typestringThe type of authorization specified for the connection. (BASIC, OAUTH_CLIENT_CREDENTIALS, API_KEY)
connection_arnstringThe ARN of the connection retrieved. (pattern: <code>^arn:aws([a-z]|-):events:([a-z]|\d|-):([0-9]{12})?:connection/[.-_A-Za-z0-9]+/[-A-Za-z0-9]+$</code>)
connection_statestringThe state of the connection retrieved. (CREATING, UPDATING, DELETING, AUTHORIZED, DEAUTHORIZED, AUTHORIZING, DEAUTHORIZING, ACTIVE, FAILED_CONNECTIVITY)
creation_timestring (date-time)A time stamp for the time that the connection was created.
descriptionstringThe description for the connection retrieved. (pattern: <code>.*</code>)
invocation_connectivity_parametersobjectFor connections to private APIs The parameters EventBridge uses to invoke the resource endpoint. For more information, see Connecting to private APIs in the Amazon EventBridge User Guide .
kms_key_identifierstringThe identifier of the KMS customer managed key for EventBridge to use to encrypt the connection, if one has been specified. For more information, see Encrypting connections in the Amazon EventBridge User Guide. (pattern: <code>^[a-zA-Z0-9_-/:]*$</code>)
last_authorized_timestring (date-time)A time stamp for the time that the connection was last authorized.
last_modified_timestring (date-time)A time stamp for the time that the connection was last modified.
namestringThe name of the connection retrieved. (pattern: <code>[.-_A-Za-z0-9]+</code>)
secret_arnstringThe ARN of the secret created from the authorization parameters specified for the connection. (pattern: <code>^arn:aws([a-z]|-):secretsmanager:([a-z]|\d|-):([0-9]{12})?㊙️[/_+=.@-A-Za-z0-9]+$</code>)
state_reasonstringThe reason that the connection is in the current connection state. (pattern: <code>.*</code>)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_connectionselectregionRetrieves details about a connection.
create_connectioninsertregion, AuthorizationType, AuthParametersCreates a connection. A connection defines the authorization type and credentials to use for authorization with an API destination HTTP endpoint. For more information, see Connections for endpoint targets in the Amazon EventBridge User Guide.
update_connectionupdateregionUpdates settings for a connection.
delete_connectiondeleteregionDeletes a connection.
list_connectionsexecregionRetrieves a list of connections from the account.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Retrieves details about a connection.

SELECT
auth_parameters,
authorization_type,
connection_arn,
connection_state,
creation_time,
description,
invocation_connectivity_parameters,
kms_key_identifier,
last_authorized_time,
last_modified_time,
name,
secret_arn,
state_reason
FROM aws.events.connections
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a connection. A connection defines the authorization type and credentials to use for authorization with an API destination HTTP endpoint. For more information, see Connections for endpoint targets in the Amazon EventBridge User Guide.

INSERT INTO aws.events.connections (
Name,
Description,
AuthorizationType,
AuthParameters,
InvocationConnectivityParameters,
KmsKeyIdentifier,
region
)
SELECT
'{{ Name }}',
'{{ Description }}',
'{{ AuthorizationType }}' /* required */,
'{{ AuthParameters }}' /* required */,
'{{ InvocationConnectivityParameters }}',
'{{ KmsKeyIdentifier }}',
'{{ region }}'
RETURNING
connection_arn,
connection_state,
creation_time,
last_modified_time
;

UPDATE examples

Updates settings for a connection.

UPDATE aws.events.connections
SET
Name = '{{ Name }}',
Description = '{{ Description }}',
AuthorizationType = '{{ AuthorizationType }}',
AuthParameters = '{{ AuthParameters }}',
InvocationConnectivityParameters = '{{ InvocationConnectivityParameters }}',
KmsKeyIdentifier = '{{ KmsKeyIdentifier }}'
WHERE
region = '{{ region }}' --required
RETURNING
connection_arn,
connection_state,
creation_time,
last_authorized_time,
last_modified_time;

DELETE examples

Deletes a connection.

DELETE FROM aws.events.connections
WHERE region = '{{ region }}' --required
;

Lifecycle Methods

Retrieves a list of connections from the account.

EXEC aws.events.connections.list_connections
@region='{{ region }}' --required
@@json=
'{
"NamePrefix": "{{ NamePrefix }}",
"ConnectionState": "{{ ConnectionState }}",
"NextToken": "{{ NextToken }}",
"Limit": {{ Limit }}
}'
;