Skip to main content

sync_jobs

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

Overview

Namesync_jobs
TypeResource
Idaws.iottwinmaker.sync_jobs

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
arnstringThe sync job ARN. (pattern: <code>arn:((aws)|(aws-cn)|(aws-us-gov)):iottwinmaker:[a-z0-9-]+:[0-9]{12}:[/a-zA-Z0-9_-.:]+</code>)
creation_date_timestring (date-time)supports epoch seconds value
statusobjectThe SyncJob response status.
sync_rolestringThe sync IAM role. (pattern: <code>arn:((aws)|(aws-cn)|(aws-us-gov)):iam::[0-9]{12}:role/.*</code>)
sync_sourcestringThe sync soucre. Currently the only supported syncSource is SITEWISE . (pattern: <code>[a-zA-Z_0-9]+</code>)
update_date_timestring (date-time)supports epoch seconds value
workspace_idstringThe ID of the workspace that contains the sync job. (pattern: <code>[a-zA-Z_0-9][a-zA-Z_-0-9]*[a-zA-Z0-9]+</code>)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_sync_jobselectsync_source, regionworkspaceGets the SyncJob.
list_sync_jobsselectworkspace_id, regionList all SyncJobs.
create_sync_jobinsertworkspace_id, sync_source, region, syncRoleThis action creates a SyncJob.
delete_sync_jobdeleteworkspace_id, sync_source, regionDelete the SyncJob.

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)
sync_sourcestringThe sync source. Currently the only supported syncSource is SITEWISE .
workspace_idstringThe workspace ID.
workspacestringThe workspace ID.

SELECT examples

Gets the SyncJob.

SELECT
arn,
creation_date_time,
status,
sync_role,
sync_source,
update_date_time,
workspace_id
FROM aws.iottwinmaker.sync_jobs
WHERE sync_source = '{{ sync_source }}' -- required
AND region = '{{ region }}' -- required
AND workspace = '{{ workspace }}'
;

INSERT examples

This action creates a SyncJob.

INSERT INTO aws.iottwinmaker.sync_jobs (
syncRole,
tags,
workspace_id,
sync_source,
region
)
SELECT
'{{ syncRole }}' /* required */,
'{{ tags }}',
'{{ workspace_id }}',
'{{ sync_source }}',
'{{ region }}'
RETURNING
arn,
creation_date_time,
state
;

DELETE examples

Delete the SyncJob.

DELETE FROM aws.iottwinmaker.sync_jobs
WHERE workspace_id = '{{ workspace_id }}' --required
AND sync_source = '{{ sync_source }}' --required
AND region = '{{ region }}' --required
;