Skip to main content

account_log_services

Creates, updates, deletes, gets or lists an account_log_services resource.

Overview​

Nameaccount_log_services
TypeResource
Idfivetran.external_logging.account_log_services

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe unique identifier for the log service within the Fivetran system. (example: log_id)
configobjectThe config object for the service in question (a JSON value; its keys depend on the service). The accepted keys per type are documented in the vendor's API reference and returned by the connector metadata endpoints.
enabledbooleanThe boolean value specifying whether the log service is enabled.
servicestringThe name of the log service type within the Fivetran system. We support the following log services: azure_monitor_log, cloudwatch, datadog_log, dynatrace, grafana_loki, splunkLog, new_relic_log, stackdriver (Google Cloud Logging). (example: log_service_type)
setup_testsarrayResults of the most recent setup test run.
statusobjectSetup status of the log service. Present when a setup status exists for the log service.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectReturns the account-level [logging service](https:​//fivetran.com/docs/logs/external-logs) if it exists.
createinsertCreates an account-level [logging service](https:​//fivetran.com/docs/logs/external-logs).
updateupdateUpdates information for the account-level [logging service](https:​//fivetran.com/docs/logs/external-logs).
deletedeleteDeletes the account-level [logging service](https:​//fivetran.com/docs/logs/external-logs).
run_setup_testsexecRuns the setup tests for the account-level [logging service](https:​//fivetran.com/docs/logs/external-logs).

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

SELECT examples​

Returns the account-level logging service if it exists.

SELECT
id,
config,
enabled,
service,
setup_tests,
status
FROM fivetran.external_logging.account_log_services
;

INSERT examples​

Creates an account-level logging service.

INSERT INTO fivetran.external_logging.account_log_services (
service,
enabled,
config,
run_setup_tests
)
SELECT
'{{ service }}',
{{ enabled }},
'{{ config }}',
{{ run_setup_tests }}
RETURNING
id,
config,
enabled,
service,
setup_tests,
status
;

UPDATE examples​

Updates information for the account-level logging service.

UPDATE fivetran.external_logging.account_log_services
SET
enabled = {{ enabled }},
config = '{{ config }}',
run_setup_tests = {{ run_setup_tests }}
RETURNING
id,
config,
enabled,
service,
setup_tests,
status;

DELETE examples​

Deletes the account-level logging service.

DELETE FROM fivetran.external_logging.account_log_services
;

Lifecycle Methods​

EXEC variables use wire (API) names.

Runs the setup tests for the account-level logging service.

EXEC fivetran.external_logging.account_log_services.run_setup_tests

;