Skip to main content

ai_agents

Creates, updates, deletes or gets an ai_agent resource or lists ai_agents in a region

Overview

Nameai_agents
TypeResource
DescriptionDefinition of AWS::Wisdom::AIAgent Resource Type
Idawscc.wisdom.ai_agents

Fields

NameDatatypeDescription
a_iagent_idstring
a_iagent_arnstring
assistant_idstring
assistant_arnstring
configurationobject
descriptionstring
namestring
tagsobject
typestring
modified_time_secondsnumber
regionstringAWS region.

For more information, see AWS::Wisdom::AIAgent.

Methods

NameResourceAccessible byRequired Params
create_resourceai_agentsINSERTAssistantId, Configuration, Type, region
delete_resourceai_agentsDELETEIdentifier, region
update_resourceai_agentsUPDATEIdentifier, PatchDocument, region
list_resourcesai_agents_list_onlySELECTregion
get_resourceai_agentsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual ai_agent.

SELECT
region,
a_iagent_id,
a_iagent_arn,
assistant_id,
assistant_arn,
configuration,
description,
name,
tags,
type,
modified_time_seconds
FROM awscc.wisdom.ai_agents
WHERE
region = '{{ region }}' AND
Identifier = '{{ a_iagent_id }}|{{ assistant_id }}';

INSERT example

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

/*+ create */
INSERT INTO awscc.wisdom.ai_agents (
AssistantId,
Configuration,
Type,
region
)
SELECT
'{{ assistant_id }}',
'{{ configuration }}',
'{{ type }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

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

/*+ update */
UPDATE awscc.wisdom.ai_agents
SET PatchDocument = string('{{ {
"Configuration": configuration,
"Description": description
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ a_iagent_id }}|{{ assistant_id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.wisdom.ai_agents
WHERE
Identifier = '{{ a_iagent_id }}|{{ assistant_id }}' 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:

ParameterDescription
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 ai_agents resource, the following permissions are required:

wisdom:CreateAIAgent,
wisdom:TagResource