Skip to main content

indices

Creates, updates, deletes or gets an index resource or lists indices in a region

Overview

Nameindices
TypeResource
DescriptionA Kendra index
Idawscc.kendra.indices

Fields

NameDatatypeDescription
idstringUnique ID of index
arnstring
descriptionstringA description for the index
server_side_encryption_configurationobjectServer side encryption configuration
tagsarrayTags for labeling the index
namestringName of index
role_arnstringRole Arn
editionstringEdition of index
document_metadata_configurationsarrayDocument metadata configurations
capacity_unitsobjectCapacity units
user_context_policystring
user_token_configurationsarray
regionstringAWS region.

For more information, see AWS::Kendra::Index.

Methods

NameResourceAccessible byRequired Params
create_resourceindicesINSERTName, RoleArn, Edition, region
delete_resourceindicesDELETEIdentifier, region
update_resourceindicesUPDATEIdentifier, PatchDocument, region
list_resourcesindices_list_onlySELECTregion
get_resourceindicesSELECTIdentifier, region

SELECT examples

Gets all properties from an individual index.

SELECT
region,
id,
arn,
description,
server_side_encryption_configuration,
tags,
name,
role_arn,
edition,
document_metadata_configurations,
capacity_units,
user_context_policy,
user_token_configurations
FROM awscc.kendra.indices
WHERE
region = 'us-east-1' AND
Identifier = '{{ id }}';

INSERT example

Use the following StackQL query and manifest file to create a new index resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.kendra.indices (
Name,
RoleArn,
Edition,
region
)
SELECT
'{{ name }}',
'{{ role_arn }}',
'{{ edition }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a index resource, using stack-deploy.

/*+ update */
UPDATE awscc.kendra.indices
SET PatchDocument = string('{{ {
"Description": description,
"Tags": tags,
"Name": name,
"RoleArn": role_arn,
"DocumentMetadataConfigurations": document_metadata_configurations,
"CapacityUnits": capacity_units,
"UserContextPolicy": user_context_policy,
"UserTokenConfigurations": user_token_configurations
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}';

DELETE example

/*+ delete */
DELETE FROM awscc.kendra.indices
WHERE
Identifier = '{{ id }}' AND
region = 'us-east-1';

Permissions

To operate on the indices resource, the following permissions are required:

kendra:CreateIndex,
kendra:DescribeIndex,
kendra:UpdateIndex,
kendra:ListTagsForResource,
iam:PassRole,
kendra:TagResource,
kms:DescribeKey,
kms:CreateGrant