Skip to main content

connectors

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

Overview

Nameconnectors
TypeResource
Idaws.securityhub.connectors

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
connector_arnstringThe Amazon Resource Name (ARN) of the connector. (pattern: <code>.\S.</code>)
connector_idstringThe unique identifier of the connector. (pattern: <code>.\S.</code>)
created_atstring (date-time)The ISO 8601 UTC timestamp indicating when the connector was created.
created_bystringThe service principal that created the connector. (pattern: <code>.\S.</code>)
descriptionstringThe description of the connector. (pattern: <code>.\S.</code>)
enablement_statusstringThe enablement status of a CSPM connector. Indicates the lifecycle state of the connector resource. (ENABLED, PENDING_ENABLEMENT, PENDING_UPDATE, PENDING_DELETION)
healthobjectThe health status of the connector, including connectivity status and last check time.
last_updated_atstring (date-time)The ISO 8601 UTC timestamp indicating when the connector was last updated.
namestringThe name of the connector. (pattern: <code>.\S.</code>)
provider_detailobjectThe cloud provider configuration details for the connector.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_connectorselectconnector_id, regionRetrieves details for a CSPM connector based on the connector ID.
list_connectorsselectregionNextToken, MaxResults, ProviderName, ConnectorStatus, EnablementStatusLists the CSPM connectors and their metadata for the calling account.
create_connectorinsertregion, ProviderCreates a connector to a third-party cloud provider in Security Hub CSPM. A connector establishes a connection between Security Hub CSPM and a third-party cloud provider, enabling Security Hub CSPM to ingest security findings and resource data from the connected environment.
update_connectorupdateconnector_id, regionUpdates a CSPM connector's configuration, such as the scope or regions for the connected cloud provider.
delete_connectordeleteconnector_id, regionDeletes a CSPM connector. When you delete a connector, Security Hub CSPM stops ingesting findings and resource data from the connected cloud provider environment.

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
connector_idstringThe unique identifier of the connector to delete.
regionstringAWS region (default: us-east-1)
ConnectorStatusstringThe connectivity status to filter connectors by.
EnablementStatusstringThe enablement status to filter connectors by.
MaxResultsintegerThe maximum number of results to return.
NextTokenstringThe pagination token to request the next page of results.
ProviderNamestringThe name of the cloud provider to filter connectors by.

SELECT examples

Retrieves details for a CSPM connector based on the connector ID.

SELECT
connector_arn,
connector_id,
created_at,
created_by,
description,
enablement_status,
health,
last_updated_at,
name,
provider_detail
FROM aws.securityhub.connectors
WHERE connector_id = '{{ connector_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a connector to a third-party cloud provider in Security Hub CSPM. A connector establishes a connection between Security Hub CSPM and a third-party cloud provider, enabling Security Hub CSPM to ingest security findings and resource data from the connected environment.

INSERT INTO aws.securityhub.connectors (
Name,
Description,
Provider,
Tags,
ClientToken,
region
)
SELECT
'{{ Name }}',
'{{ Description }}',
'{{ Provider }}' /* required */,
'{{ Tags }}',
'{{ ClientToken }}',
'{{ region }}'
RETURNING
connector_arn,
connector_id,
connector_status,
enablement_status
;

UPDATE examples

Updates a CSPM connector's configuration, such as the scope or regions for the connected cloud provider.

UPDATE aws.securityhub.connectors
SET
Description = '{{ Description }}',
Provider = '{{ Provider }}'
WHERE
connector_id = '{{ connector_id }}' --required
AND region = '{{ region }}' --required
RETURNING
connector_status,
enablement_status;

DELETE examples

Deletes a CSPM connector. When you delete a connector, Security Hub CSPM stops ingesting findings and resource data from the connected cloud provider environment.

DELETE FROM aws.securityhub.connectors
WHERE connector_id = '{{ connector_id }}' --required
AND region = '{{ region }}' --required
;