object_types
Creates, updates, deletes or gets an object_type resource or lists object_types in a region
Overview
| Name | object_types |
| Type | Resource |
| Description | An ObjectType resource of Amazon Connect Customer Profiles |
| Id | awscc.customerprofiles.object_types |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
domain_name | string | The unique name of the domain. |
object_type_name | string | The name of the profile object type. |
allow_profile_creation | boolean | Indicates whether a profile should be created when data is received. |
description | string | Description of the profile object type. |
encryption_key | string | The default encryption key |
expiration_days | integer | The default number of days until the data within the domain expires. |
fields | array | A list of the name and ObjectType field. |
keys | array | A list of unique keys that can be used to map data to the profile. |
created_at | string | The time of this integration got created. |
last_updated_at | string | The time of this integration got last updated at. |
source_last_updated_timestamp_format | string | The format of your sourceLastUpdatedTimestamp that was previously set up. |
tags | array | The tags (keys and values) associated with the integration. |
template_id | string | A unique identifier for the object template. |
max_profile_object_count | integer | The maximum number of profile objects for this object type |
max_available_profile_object_count | integer | The maximum available number of profile objects |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
domain_name | string | The unique name of the domain. |
object_type_name | string | The name of the profile object type. |
region | string | AWS region. |
For more information, see AWS::CustomerProfiles::ObjectType.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | object_types | INSERT | DomainName, ObjectTypeName, Description, region |
delete_resource | object_types | DELETE | Identifier, region |
update_resource | object_types | UPDATE | Identifier, PatchDocument, region |
list_resources | object_types_list_only | SELECT | region |
get_resource | object_types | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual object_type.
SELECT
region,
domain_name,
object_type_name,
allow_profile_creation,
description,
encryption_key,
expiration_days,
fields,
keys,
created_at,
last_updated_at,
source_last_updated_timestamp_format,
tags,
template_id,
max_profile_object_count,
max_available_profile_object_count
FROM awscc.customerprofiles.object_types
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_name }}|{{ object_type_name }}';
Lists all object_types in a region.
SELECT
region,
domain_name,
object_type_name
FROM awscc.customerprofiles.object_types_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new object_type resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.customerprofiles.object_types (
DomainName,
ObjectTypeName,
Description,
region
)
SELECT
'{{ domain_name }}',
'{{ object_type_name }}',
'{{ description }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.customerprofiles.object_types (
DomainName,
ObjectTypeName,
AllowProfileCreation,
Description,
EncryptionKey,
ExpirationDays,
Fields,
Keys,
SourceLastUpdatedTimestampFormat,
Tags,
TemplateId,
MaxProfileObjectCount,
region
)
SELECT
'{{ domain_name }}',
'{{ object_type_name }}',
'{{ allow_profile_creation }}',
'{{ description }}',
'{{ encryption_key }}',
'{{ expiration_days }}',
'{{ fields }}',
'{{ keys }}',
'{{ source_last_updated_timestamp_format }}',
'{{ tags }}',
'{{ template_id }}',
'{{ max_profile_object_count }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: object_type
props:
- name: domain_name
value: '{{ domain_name }}'
- name: object_type_name
value: '{{ object_type_name }}'
- name: allow_profile_creation
value: '{{ allow_profile_creation }}'
- name: description
value: '{{ description }}'
- name: encryption_key
value: '{{ encryption_key }}'
- name: expiration_days
value: '{{ expiration_days }}'
- name: fields
value:
- name: '{{ name }}'
object_type_field:
source: '{{ source }}'
target: '{{ target }}'
content_type: '{{ content_type }}'
- name: keys
value:
- name: '{{ name }}'
object_type_key_list:
- field_names:
- '{{ field_names[0] }}'
standard_identifiers:
- '{{ standard_identifiers[0] }}'
- name: source_last_updated_timestamp_format
value: '{{ source_last_updated_timestamp_format }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
- name: template_id
value: '{{ template_id }}'
- name: max_profile_object_count
value: '{{ max_profile_object_count }}'
UPDATE example
Use the following StackQL query and manifest file to update a object_type resource, using stack-deploy.
/*+ update */
UPDATE awscc.customerprofiles.object_types
SET PatchDocument = string('{{ {
"AllowProfileCreation": allow_profile_creation,
"Description": description,
"EncryptionKey": encryption_key,
"ExpirationDays": expiration_days,
"Fields": fields,
"Keys": keys,
"SourceLastUpdatedTimestampFormat": source_last_updated_timestamp_format,
"Tags": tags,
"TemplateId": template_id,
"MaxProfileObjectCount": max_profile_object_count
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ domain_name }}|{{ object_type_name }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.customerprofiles.object_types
WHERE
Identifier = '{{ domain_name }}|{{ object_type_name }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the object_types resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
profile:GetProfileObjectType,
profile:PutProfileObjectType,
profile:TagResource,
kms:GenerateDataKey,
kms:Decrypt
profile:GetProfileObjectType,
kms:GenerateDataKey,
kms:Decrypt
profile:GetProfileObjectType,
profile:PutProfileObjectType,
profile:UntagResource,
profile:TagResource,
kms:GenerateDataKey,
kms:Decrypt
profile:DeleteProfileObjectType
profile:ListProfileObjectTypes,
kms:GenerateDataKey,
kms:Decrypt