Skip to main content

subscribers

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

Overview

Namesubscribers
TypeResource
Idaws.securitylake.subscribers

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
access_typesarrayYou can choose to notify subscribers of new objects with an Amazon Simple Queue Service (Amazon SQS) queue or through messaging to an HTTPS endpoint provided by the subscriber. Subscribers can consume data by directly querying Lake Formation tables in your Amazon S3 bucket through services like Amazon Athena. This subscription type is defined as LAKEFORMATION.
created_atstring (date-time)The date and time when the subscriber was created.
resource_share_arnstringThe Amazon Resource Name (ARN) which uniquely defines the Amazon Web Services RAM resource share. Before accepting the RAM resource share invitation, you can view details related to the RAM resource share. This field is available only for Lake Formation subscribers created after March 8, 2023.
resource_share_namestringThe name of the resource share. (pattern: <code>^LakeFormation(?:-V[0-9]+)-([a-zA-Z0-9]+)-([\\w-_:/.@=+]*)$</code>)
role_arnstringThe Amazon Resource Name (ARN) specifying the role of the subscriber. (pattern: <code>^arn:(aws[a-zA-Z-]*)?:iam::\d{12}:role/?[a-zA-Z_0-9+=,.@-_/]+$</code>)
s_3_bucket_arnstringThe ARN for the Amazon S3 bucket.
sourcesarrayAmazon Security Lake supports log and event collection for natively supported Amazon Web Services services. For more information, see the Amazon Security Lake User Guide.
subscriber_arnstringThe subscriber ARN of the Amazon Security Lake subscriber account. (pattern: <code>^arn:(aws|aws-us-gov|aws-cn):securitylake:[A-Za-z0-9_/.-]{0,63}:[A-Za-z0-9_/.-]{0,63}:[A-Za-z0-9][A-Za-z0-9_/.-]{0,127}$</code>)
subscriber_descriptionstringThe subscriber descriptions for a subscriber account. The description for a subscriber includes subscriberName, accountID, externalID, and subscriberId. (pattern: <code>^[\\w-_:/.@=+]*$</code>)
subscriber_endpointstringThe subscriber endpoint to which exception messages are posted. (pattern: <code>^[\\w-_:/.@=+]*$</code>)
subscriber_idstringThe subscriber ID of the Amazon Security Lake subscriber account. (pattern: <code>^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$</code>)
subscriber_identityobjectThe Amazon Web Services identity.
subscriber_namestringThe name of your Amazon Security Lake subscriber account. (pattern: <code>^[\\w-_:/.@=+]*$</code>)
subscriber_statusstringThe subscriber status of the Amazon Security Lake subscriber account. (ACTIVE, DEACTIVATED, PENDING, READY)
updated_atstring (date-time)The date and time when the subscriber was last updated.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_subscriberselectsubscriber_id, regionRetrieves the subscription information for the specified subscription ID. You can get information about a specific subscriber.
list_subscribersselectregionmaxResults, nextTokenLists all subscribers for the specific Amazon Security Lake account ID. You can retrieve a list of subscriptions associated with a specific organization or Amazon Web Services account.
create_subscriberinsertregion, sources, subscriberIdentity, subscriberNameCreates a subscriber for accounts that are already enabled in Amazon Security Lake. You can create a subscriber with access to data in the current Amazon Web Services Region.
create_subscriber_notificationinsertsubscriber_id, region, configurationNotifies the subscriber when new data is written to the data lake for the sources that the subscriber consumes in Security Lake. You can create only one subscriber notification per subscriber.
update_subscriber_notificationupdatesubscriber_id, region, configurationUpdates an existing notification method for the subscription (SQS or HTTPs endpoint) or switches the notification subscription endpoint for a subscriber.
update_subscriberupdatesubscriber_id, regionUpdates an existing subscription for the given Amazon Security Lake account ID. You can update a subscriber by changing the sources that the subscriber consumes data from.
delete_subscriberdeletesubscriber_id, regionDeletes the subscription permission and all notification settings for accounts that are already enabled in Amazon Security Lake. When you run DeleteSubscriber, the subscriber will no longer consume data from Security Lake and the subscriber is removed. This operation deletes the subscriber and removes access to data in the current Amazon Web Services Region.
delete_subscriber_notificationexecsubscriber_id, regionDeletes the specified subscription notification in Amazon Security Lake for the organization you specify.

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)
subscriber_idstringThe ID of the Security Lake subscriber account.
maxResultsintegerThe maximum number of accounts for which the configuration is displayed.
nextTokenstringIf nextToken is returned, there are more results available. You can repeat the call using the returned token to retrieve the next page.

SELECT examples

Retrieves the subscription information for the specified subscription ID. You can get information about a specific subscriber.

SELECT
access_types,
created_at,
resource_share_arn,
resource_share_name,
role_arn,
s_3_bucket_arn,
sources,
subscriber_arn,
subscriber_description,
subscriber_endpoint,
subscriber_id,
subscriber_identity,
subscriber_name,
subscriber_status,
updated_at
FROM aws.securitylake.subscribers
WHERE subscriber_id = '{{ subscriber_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a subscriber for accounts that are already enabled in Amazon Security Lake. You can create a subscriber with access to data in the current Amazon Web Services Region.

INSERT INTO aws.securitylake.subscribers (
accessTypes,
sources,
subscriberDescription,
subscriberIdentity,
subscriberName,
tags,
region
)
SELECT
'{{ accessTypes }}',
'{{ sources }}' /* required */,
'{{ subscriberDescription }}',
'{{ subscriberIdentity }}' /* required */,
'{{ subscriberName }}' /* required */,
'{{ tags }}',
'{{ region }}'
RETURNING
subscriber
;

UPDATE examples

Updates an existing notification method for the subscription (SQS or HTTPs endpoint) or switches the notification subscription endpoint for a subscriber.

UPDATE aws.securitylake.subscribers
SET
configuration = '{{ configuration }}'
WHERE
subscriber_id = '{{ subscriber_id }}' --required
AND region = '{{ region }}' --required
AND configuration = '{{ configuration }}' --required
RETURNING
subscriber_endpoint;

DELETE examples

Deletes the subscription permission and all notification settings for accounts that are already enabled in Amazon Security Lake. When you run DeleteSubscriber, the subscriber will no longer consume data from Security Lake and the subscriber is removed. This operation deletes the subscriber and removes access to data in the current Amazon Web Services Region.

DELETE FROM aws.securitylake.subscribers
WHERE subscriber_id = '{{ subscriber_id }}' --required
AND region = '{{ region }}' --required
;

Lifecycle Methods

Deletes the specified subscription notification in Amazon Security Lake for the organization you specify.

EXEC aws.securitylake.subscribers.delete_subscriber_notification
@subscriber_id='{{ subscriber_id }}' --required,
@region='{{ region }}' --required
;