SDK for PHP 3.x

Client: Aws\BedrockAgent\BedrockAgentClient
Service ID: bedrock-agent
Version: 2023-06-05

This page describes the parameters and results for the operations of the Agents for Amazon Bedrock (2023-06-05), and shows how to use the Aws\BedrockAgent\BedrockAgentClient object to call the described operations. This documentation is specific to the 2023-06-05 API version of the service.

Operation Summary

Each of the following operations can be created from a client using $client->getCommand('CommandName'), where "CommandName" is the name of one of the following operations. Note: a command is a value that encapsulates an operation and the parameters used to create an HTTP request.

You can also create and send a command immediately using the magic methods available on a client object: $client->commandName(/* parameters */). You can send the command asynchronously (returning a promise) by appending the word "Async" to the operation name: $client->commandNameAsync(/* parameters */).

AssociateAgentKnowledgeBase ( array $params = [] )
Associates a knowledge base with an agent.
CreateAgent ( array $params = [] )
Creates an agent that orchestrates interactions between foundation models, data sources, software applications, user conversations, and APIs to carry out tasks to help customers.
CreateAgentActionGroup ( array $params = [] )
Creates an action group for an agent.
CreateAgentAlias ( array $params = [] )
Creates an alias of an agent that can be used to deploy the agent.
CreateDataSource ( array $params = [] )
Creates a data source connector for a knowledge base.
CreateFlow ( array $params = [] )
Creates a prompt flow that you can use to send an input through various steps to yield an output.
CreateFlowAlias ( array $params = [] )
Creates an alias of a flow for deployment.
CreateFlowVersion ( array $params = [] )
Creates a version of the flow that you can deploy.
CreateKnowledgeBase ( array $params = [] )
Creates a knowledge base that contains data sources from which information can be queried and used by LLMs.
CreatePrompt ( array $params = [] )
Creates a prompt in your prompt library that you can add to a flow.
CreatePromptVersion ( array $params = [] )
Creates a static snapshot of your prompt that can be deployed to production.
DeleteAgent ( array $params = [] )
Deletes an agent.
DeleteAgentActionGroup ( array $params = [] )
Deletes an action group in an agent.
DeleteAgentAlias ( array $params = [] )
Deletes an alias of an agent.
DeleteAgentVersion ( array $params = [] )
Deletes a version of an agent.
DeleteDataSource ( array $params = [] )
Deletes a data source from a knowledge base.
DeleteFlow ( array $params = [] )
Deletes a flow.
DeleteFlowAlias ( array $params = [] )
Deletes an alias of a flow.
DeleteFlowVersion ( array $params = [] )
Deletes a version of a flow.
DeleteKnowledgeBase ( array $params = [] )
Deletes a knowledge base.
DeletePrompt ( array $params = [] )
Deletes a prompt or a prompt version from the Prompt management tool.
DisassociateAgentKnowledgeBase ( array $params = [] )
Disassociates a knowledge base from an agent.
GetAgent ( array $params = [] )
Gets information about an agent.
GetAgentActionGroup ( array $params = [] )
Gets information about an action group for an agent.
GetAgentAlias ( array $params = [] )
Gets information about an alias of an agent.
GetAgentKnowledgeBase ( array $params = [] )
Gets information about a knowledge base associated with an agent.
GetAgentVersion ( array $params = [] )
Gets details about a version of an agent.
GetDataSource ( array $params = [] )
Gets information about a data source.
GetFlow ( array $params = [] )
Retrieves information about a flow.
GetFlowAlias ( array $params = [] )
Retrieves information about a flow.
GetFlowVersion ( array $params = [] )
Retrieves information about a version of a flow.
GetIngestionJob ( array $params = [] )
Gets information about a ingestion job, in which a data source is added to a knowledge base.
GetKnowledgeBase ( array $params = [] )
Gets information about a knoweldge base.
GetPrompt ( array $params = [] )
Retrieves information about a prompt or a version of it.
ListAgentActionGroups ( array $params = [] )
Lists the action groups for an agent and information about each one.
ListAgentAliases ( array $params = [] )
Lists the aliases of an agent and information about each one.
ListAgentKnowledgeBases ( array $params = [] )
Lists knowledge bases associated with an agent and information about each one.
ListAgentVersions ( array $params = [] )
Lists the versions of an agent and information about each version.
ListAgents ( array $params = [] )
Lists the agents belonging to an account and information about each agent.
ListDataSources ( array $params = [] )
Lists the data sources in a knowledge base and information about each one.
ListFlowAliases ( array $params = [] )
Returns a list of aliases for a flow.
ListFlowVersions ( array $params = [] )
Returns a list of information about each flow.
ListFlows ( array $params = [] )
Returns a list of flows and information about each flow.
ListIngestionJobs ( array $params = [] )
Lists the ingestion jobs for a data source and information about each of them.
ListKnowledgeBases ( array $params = [] )
Lists the knowledge bases in an account and information about each of them.
ListPrompts ( array $params = [] )
Returns a list of prompts from the Prompt management tool and information about each prompt.
ListTagsForResource ( array $params = [] )
List all the tags for the resource you specify.
PrepareAgent ( array $params = [] )
Creates a DRAFT version of the agent that can be used for internal testing.
PrepareFlow ( array $params = [] )
Prepares the DRAFT version of a flow so that it can be invoked.
StartIngestionJob ( array $params = [] )
Begins an ingestion job, in which a data source is added to a knowledge base.
TagResource ( array $params = [] )
Associate tags with a resource.
UntagResource ( array $params = [] )
Remove tags from a resource.
UpdateAgent ( array $params = [] )
Updates the configuration of an agent.
UpdateAgentActionGroup ( array $params = [] )
Updates the configuration for an action group for an agent.
UpdateAgentAlias ( array $params = [] )
Updates configurations for an alias of an agent.
UpdateAgentKnowledgeBase ( array $params = [] )
Updates the configuration for a knowledge base that has been associated with an agent.
UpdateDataSource ( array $params = [] )
Updates the configurations for a data source connector.
UpdateFlow ( array $params = [] )
Modifies a flow.
UpdateFlowAlias ( array $params = [] )
Modifies the alias of a flow.
UpdateKnowledgeBase ( array $params = [] )
Updates the configuration of a knowledge base with the fields that you specify.
UpdatePrompt ( array $params = [] )
Modifies a prompt in your prompt library.

Paginators

Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:

ListAgentActionGroups
ListAgentAliases
ListAgentKnowledgeBases
ListAgentVersions
ListAgents
ListDataSources
ListFlowAliases
ListFlowVersions
ListFlows
ListIngestionJobs
ListKnowledgeBases
ListPrompts

Operations

AssociateAgentKnowledgeBase

$result = $client->associateAgentKnowledgeBase([/* ... */]);
$promise = $client->associateAgentKnowledgeBaseAsync([/* ... */]);

Associates a knowledge base with an agent. If a knowledge base is associated and its indexState is set to Enabled, the agent queries the knowledge base for information to augment its response to the user.

Parameter Syntax

$result = $client->associateAgentKnowledgeBase([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'description' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
    'knowledgeBaseState' => 'ENABLED|DISABLED',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent with which you want to associate the knowledge base.

agentVersion
Required: Yes
Type: string

The version of the agent with which you want to associate the knowledge base.

description
Required: Yes
Type: string

A description of what the agent should use the knowledge base for.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to associate with the agent.

knowledgeBaseState
Type: string

Specifies whether to use the knowledge base or not when sending an InvokeAgent request.

Result Syntax

[
    'agentKnowledgeBase' => [
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'knowledgeBaseId' => '<string>',
        'knowledgeBaseState' => 'ENABLED|DISABLED',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentKnowledgeBase
Required: Yes
Type: AgentKnowledgeBase structure

Contains details about the knowledge base that has been associated with the agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateAgent

$result = $client->createAgent([/* ... */]);
$promise = $client->createAgentAsync([/* ... */]);

Creates an agent that orchestrates interactions between foundation models, data sources, software applications, user conversations, and APIs to carry out tasks to help customers.

  • Specify the following fields for security purposes.

    • agentResourceRoleArn – The Amazon Resource Name (ARN) of the role with permissions to invoke API operations on an agent.

    • (Optional) customerEncryptionKeyArn – The Amazon Resource Name (ARN) of a KMS key to encrypt the creation of the agent.

    • (Optional) idleSessionTTLinSeconds – Specify the number of seconds for which the agent should maintain session information. After this time expires, the subsequent InvokeAgent request begins a new session.

  • To enable your agent to retain conversational context across multiple sessions, include a memoryConfiguration object. For more information, see Configure memory.

  • To override the default prompt behavior for agent orchestration and to use advanced prompts, include a promptOverrideConfiguration object. For more information, see Advanced prompts.

  • If you agent fails to be created, the response returns a list of failureReasons alongside a list of recommendedActions for you to troubleshoot.

Parameter Syntax

$result = $client->createAgent([
    'agentName' => '<string>', // REQUIRED
    'agentResourceRoleArn' => '<string>',
    'clientToken' => '<string>',
    'customerEncryptionKeyArn' => '<string>',
    'description' => '<string>',
    'foundationModel' => '<string>',
    'guardrailConfiguration' => [
        'guardrailIdentifier' => '<string>',
        'guardrailVersion' => '<string>',
    ],
    'idleSessionTTLInSeconds' => <integer>,
    'instruction' => '<string>',
    'memoryConfiguration' => [
        'enabledMemoryTypes' => ['<string>', ...], // REQUIRED
        'storageDays' => <integer>,
    ],
    'promptOverrideConfiguration' => [
        'overrideLambda' => '<string>',
        'promptConfigurations' => [ // REQUIRED
            [
                'basePromptTemplate' => '<string>',
                'inferenceConfiguration' => [
                    'maximumLength' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
                'parserMode' => 'DEFAULT|OVERRIDDEN',
                'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                'promptState' => 'ENABLED|DISABLED',
                'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
            ],
            // ...
        ],
    ],
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
agentName
Required: Yes
Type: string

A name for the agent that you create.

agentResourceRoleArn
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the agent.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent.

description
Type: string

A description of the agent.

foundationModel
Type: string

The foundation model to be used for orchestration by the agent you create.

guardrailConfiguration
Type: GuardrailConfiguration structure

The unique Guardrail configuration assigned to the agent when it is created.

idleSessionTTLInSeconds
Type: int

The number of seconds for which Amazon Bedrock keeps information about a user's conversation with the agent.

A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Bedrock deletes any data provided before the timeout.

instruction
Type: string

Instructions that tell the agent what it should do and how it should interact with users.

memoryConfiguration
Type: MemoryConfiguration structure

Contains the details of the memory configured for the agent.

promptOverrideConfiguration
Type: PromptOverrideConfiguration structure

Contains configurations to override prompts in different parts of an agent sequence. For more information, see Advanced prompts.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the agent.

Result Syntax

[
    'agent' => [
        'agentArn' => '<string>',
        'agentId' => '<string>',
        'agentName' => '<string>',
        'agentResourceRoleArn' => '<string>',
        'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
        'agentVersion' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'customerEncryptionKeyArn' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'foundationModel' => '<string>',
        'guardrailConfiguration' => [
            'guardrailIdentifier' => '<string>',
            'guardrailVersion' => '<string>',
        ],
        'idleSessionTTLInSeconds' => <integer>,
        'instruction' => '<string>',
        'memoryConfiguration' => [
            'enabledMemoryTypes' => ['<string>', ...],
            'storageDays' => <integer>,
        ],
        'preparedAt' => <DateTime>,
        'promptOverrideConfiguration' => [
            'overrideLambda' => '<string>',
            'promptConfigurations' => [
                [
                    'basePromptTemplate' => '<string>',
                    'inferenceConfiguration' => [
                        'maximumLength' => <integer>,
                        'stopSequences' => ['<string>', ...],
                        'temperature' => <float>,
                        'topK' => <integer>,
                        'topP' => <float>,
                    ],
                    'parserMode' => 'DEFAULT|OVERRIDDEN',
                    'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                    'promptState' => 'ENABLED|DISABLED',
                    'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
                ],
                // ...
            ],
        ],
        'recommendedActions' => ['<string>', ...],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agent
Required: Yes
Type: Agent structure

Contains details about the agent created.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateAgentActionGroup

$result = $client->createAgentActionGroup([/* ... */]);
$promise = $client->createAgentActionGroupAsync([/* ... */]);

Creates an action group for an agent. An action group represents the actions that an agent can carry out for the customer by defining the APIs that an agent can call and the logic for calling them.

To allow your agent to request the user for additional information when trying to complete a task, add an action group with the parentActionGroupSignature field set to AMAZON.UserInput.

To allow your agent to generate, run, and troubleshoot code when trying to complete a task, add an action group with the parentActionGroupSignature field set to AMAZON.CodeInterpreter.

You must leave the description, apiSchema, and actionGroupExecutor fields blank for this action group. During orchestration, if your agent determines that it needs to invoke an API in an action group, but doesn't have enough information to complete the API request, it will invoke this action group instead and return an Observation reprompting the user for more information.

Parameter Syntax

$result = $client->createAgentActionGroup([
    'actionGroupExecutor' => [
        'customControl' => 'RETURN_CONTROL',
        'lambda' => '<string>',
    ],
    'actionGroupName' => '<string>', // REQUIRED
    'actionGroupState' => 'ENABLED|DISABLED',
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'apiSchema' => [
        'payload' => '<string>',
        's3' => [
            's3BucketName' => '<string>',
            's3ObjectKey' => '<string>',
        ],
    ],
    'clientToken' => '<string>',
    'description' => '<string>',
    'functionSchema' => [
        'functions' => [
            [
                'description' => '<string>',
                'name' => '<string>', // REQUIRED
                'parameters' => [
                    '<Name>' => [
                        'description' => '<string>',
                        'required' => true || false,
                        'type' => 'string|number|integer|boolean|array', // REQUIRED
                    ],
                    // ...
                ],
            ],
            // ...
        ],
    ],
    'parentActionGroupSignature' => 'AMAZON.UserInput|AMAZON.CodeInterpreter',
]);

Parameter Details

Members
actionGroupExecutor
Type: ActionGroupExecutor structure

The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking the action or the custom control method for handling the information elicited from the user.

actionGroupName
Required: Yes
Type: string

The name to give the action group.

actionGroupState
Type: string

Specifies whether the action group is available for the agent to invoke or not when sending an InvokeAgent request.

agentId
Required: Yes
Type: string

The unique identifier of the agent for which to create the action group.

agentVersion
Required: Yes
Type: string

The version of the agent for which to create the action group.

apiSchema
Type: APISchema structure

Contains either details about the S3 object containing the OpenAPI schema for the action group or the JSON or YAML-formatted payload defining the schema. For more information, see Action group OpenAPI schemas.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description of the action group.

functionSchema
Type: FunctionSchema structure

Contains details about the function schema for the action group or the JSON or YAML-formatted payload defining the schema.

parentActionGroupSignature
Type: string

To allow your agent to request the user for additional information when trying to complete a task, set this field to AMAZON.UserInput. You must leave the description, apiSchema, and actionGroupExecutor fields blank for this action group.

To allow your agent to generate, run, and troubleshoot code when trying to complete a task, set this field to AMAZON.CodeInterpreter. You must leave the description, apiSchema, and actionGroupExecutor fields blank for this action group.

During orchestration, if your agent determines that it needs to invoke an API in an action group, but doesn't have enough information to complete the API request, it will invoke this action group instead and return an Observation reprompting the user for more information.

Result Syntax

[
    'agentActionGroup' => [
        'actionGroupExecutor' => [
            'customControl' => 'RETURN_CONTROL',
            'lambda' => '<string>',
        ],
        'actionGroupId' => '<string>',
        'actionGroupName' => '<string>',
        'actionGroupState' => 'ENABLED|DISABLED',
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'apiSchema' => [
            'payload' => '<string>',
            's3' => [
                's3BucketName' => '<string>',
                's3ObjectKey' => '<string>',
            ],
        ],
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'functionSchema' => [
            'functions' => [
                [
                    'description' => '<string>',
                    'name' => '<string>',
                    'parameters' => [
                        '<Name>' => [
                            'description' => '<string>',
                            'required' => true || false,
                            'type' => 'string|number|integer|boolean|array',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
        ],
        'parentActionSignature' => 'AMAZON.UserInput|AMAZON.CodeInterpreter',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentActionGroup
Required: Yes
Type: AgentActionGroup structure

Contains details about the action group that was created.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateAgentAlias

$result = $client->createAgentAlias([/* ... */]);
$promise = $client->createAgentAliasAsync([/* ... */]);

Creates an alias of an agent that can be used to deploy the agent.

Parameter Syntax

$result = $client->createAgentAlias([
    'agentAliasName' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'description' => '<string>',
    'routingConfiguration' => [
        [
            'agentVersion' => '<string>',
            'provisionedThroughput' => '<string>',
        ],
        // ...
    ],
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
agentAliasName
Required: Yes
Type: string

The name of the alias.

agentId
Required: Yes
Type: string

The unique identifier of the agent.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description of the alias of the agent.

routingConfiguration
Type: Array of AgentAliasRoutingConfigurationListItem structures

Contains details about the routing configuration of the alias.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the alias of the agent.

Result Syntax

[
    'agentAlias' => [
        'agentAliasArn' => '<string>',
        'agentAliasHistoryEvents' => [
            [
                'endDate' => <DateTime>,
                'routingConfiguration' => [
                    [
                        'agentVersion' => '<string>',
                        'provisionedThroughput' => '<string>',
                    ],
                    // ...
                ],
                'startDate' => <DateTime>,
            ],
            // ...
        ],
        'agentAliasId' => '<string>',
        'agentAliasName' => '<string>',
        'agentAliasStatus' => 'CREATING|PREPARED|FAILED|UPDATING|DELETING',
        'agentId' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'routingConfiguration' => [
            [
                'agentVersion' => '<string>',
                'provisionedThroughput' => '<string>',
            ],
            // ...
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentAlias
Required: Yes
Type: AgentAlias structure

Contains details about the alias that was created.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateDataSource

$result = $client->createDataSource([/* ... */]);
$promise = $client->createDataSourceAsync([/* ... */]);

Creates a data source connector for a knowledge base.

You can't change the chunkingConfiguration after you create the data source connector.

Parameter Syntax

$result = $client->createDataSource([
    'clientToken' => '<string>',
    'dataDeletionPolicy' => 'RETAIN|DELETE',
    'dataSourceConfiguration' => [ // REQUIRED
        'confluenceConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'BASIC|OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'hostType' => 'SAAS', // REQUIRED
                'hostUrl' => '<string>', // REQUIRED
            ],
        ],
        's3Configuration' => [
            'bucketArn' => '<string>', // REQUIRED
            'bucketOwnerAccountId' => '<string>',
            'inclusionPrefixes' => ['<string>', ...],
        ],
        'salesforceConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'hostUrl' => '<string>', // REQUIRED
            ],
        ],
        'sharePointConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'domain' => '<string>', // REQUIRED
                'hostType' => 'ONLINE', // REQUIRED
                'siteUrls' => ['<string>', ...], // REQUIRED
                'tenantId' => '<string>',
            ],
        ],
        'type' => 'S3|WEB|CONFLUENCE|SALESFORCE|SHAREPOINT', // REQUIRED
        'webConfiguration' => [
            'crawlerConfiguration' => [
                'crawlerLimits' => [
                    'rateLimit' => <integer>,
                ],
                'exclusionFilters' => ['<string>', ...],
                'inclusionFilters' => ['<string>', ...],
                'scope' => 'HOST_ONLY|SUBDOMAINS',
            ],
            'sourceConfiguration' => [ // REQUIRED
                'urlConfiguration' => [ // REQUIRED
                    'seedUrls' => [
                        [
                            'url' => '<string>',
                        ],
                        // ...
                    ],
                ],
            ],
        ],
    ],
    'description' => '<string>',
    'knowledgeBaseId' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'serverSideEncryptionConfiguration' => [
        'kmsKeyArn' => '<string>',
    ],
    'vectorIngestionConfiguration' => [
        'chunkingConfiguration' => [
            'chunkingStrategy' => 'FIXED_SIZE|NONE|HIERARCHICAL|SEMANTIC', // REQUIRED
            'fixedSizeChunkingConfiguration' => [
                'maxTokens' => <integer>, // REQUIRED
                'overlapPercentage' => <integer>, // REQUIRED
            ],
            'hierarchicalChunkingConfiguration' => [
                'levelConfigurations' => [ // REQUIRED
                    [
                        'maxTokens' => <integer>, // REQUIRED
                    ],
                    // ...
                ],
                'overlapTokens' => <integer>, // REQUIRED
            ],
            'semanticChunkingConfiguration' => [
                'breakpointPercentileThreshold' => <integer>, // REQUIRED
                'bufferSize' => <integer>, // REQUIRED
                'maxTokens' => <integer>, // REQUIRED
            ],
        ],
        'customTransformationConfiguration' => [
            'intermediateStorage' => [ // REQUIRED
                's3Location' => [ // REQUIRED
                    'uri' => '<string>', // REQUIRED
                ],
            ],
            'transformations' => [ // REQUIRED
                [
                    'stepToApply' => 'POST_CHUNKING', // REQUIRED
                    'transformationFunction' => [ // REQUIRED
                        'transformationLambdaConfiguration' => [ // REQUIRED
                            'lambdaArn' => '<string>', // REQUIRED
                        ],
                    ],
                ],
                // ...
            ],
        ],
        'parsingConfiguration' => [
            'bedrockFoundationModelConfiguration' => [
                'modelArn' => '<string>', // REQUIRED
                'parsingPrompt' => [
                    'parsingPromptText' => '<string>', // REQUIRED
                ],
            ],
            'parsingStrategy' => 'BEDROCK_FOUNDATION_MODEL', // REQUIRED
        ],
    ],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

dataDeletionPolicy
Type: string

The data deletion policy for the data source.

You can set the data deletion policy to:

  • DELETE: Deletes all underlying data belonging to the data source from the vector store upon deletion of a knowledge base or data source resource. Note that the vector store itself is not deleted, only the underlying data. This flag is ignored if an Amazon Web Services account is deleted.

  • RETAIN: Retains all underlying data in your vector store upon deletion of a knowledge base or data source resource.

dataSourceConfiguration
Required: Yes
Type: DataSourceConfiguration structure

The connection configuration for the data source.

description
Type: string

A description of the data source.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which to add the data source.

name
Required: Yes
Type: string

The name of the data source.

serverSideEncryptionConfiguration

Contains details about the server-side encryption for the data source.

vectorIngestionConfiguration

Contains details about how to ingest the documents in the data source.

Result Syntax

[
    'dataSource' => [
        'createdAt' => <DateTime>,
        'dataDeletionPolicy' => 'RETAIN|DELETE',
        'dataSourceConfiguration' => [
            'confluenceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'BASIC|OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostType' => 'SAAS',
                    'hostUrl' => '<string>',
                ],
            ],
            's3Configuration' => [
                'bucketArn' => '<string>',
                'bucketOwnerAccountId' => '<string>',
                'inclusionPrefixes' => ['<string>', ...],
            ],
            'salesforceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostUrl' => '<string>',
                ],
            ],
            'sharePointConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'domain' => '<string>',
                    'hostType' => 'ONLINE',
                    'siteUrls' => ['<string>', ...],
                    'tenantId' => '<string>',
                ],
            ],
            'type' => 'S3|WEB|CONFLUENCE|SALESFORCE|SHAREPOINT',
            'webConfiguration' => [
                'crawlerConfiguration' => [
                    'crawlerLimits' => [
                        'rateLimit' => <integer>,
                    ],
                    'exclusionFilters' => ['<string>', ...],
                    'inclusionFilters' => ['<string>', ...],
                    'scope' => 'HOST_ONLY|SUBDOMAINS',
                ],
                'sourceConfiguration' => [
                    'urlConfiguration' => [
                        'seedUrls' => [
                            [
                                'url' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                ],
            ],
        ],
        'dataSourceId' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'serverSideEncryptionConfiguration' => [
            'kmsKeyArn' => '<string>',
        ],
        'status' => 'AVAILABLE|DELETING|DELETE_UNSUCCESSFUL',
        'updatedAt' => <DateTime>,
        'vectorIngestionConfiguration' => [
            'chunkingConfiguration' => [
                'chunkingStrategy' => 'FIXED_SIZE|NONE|HIERARCHICAL|SEMANTIC',
                'fixedSizeChunkingConfiguration' => [
                    'maxTokens' => <integer>,
                    'overlapPercentage' => <integer>,
                ],
                'hierarchicalChunkingConfiguration' => [
                    'levelConfigurations' => [
                        [
                            'maxTokens' => <integer>,
                        ],
                        // ...
                    ],
                    'overlapTokens' => <integer>,
                ],
                'semanticChunkingConfiguration' => [
                    'breakpointPercentileThreshold' => <integer>,
                    'bufferSize' => <integer>,
                    'maxTokens' => <integer>,
                ],
            ],
            'customTransformationConfiguration' => [
                'intermediateStorage' => [
                    's3Location' => [
                        'uri' => '<string>',
                    ],
                ],
                'transformations' => [
                    [
                        'stepToApply' => 'POST_CHUNKING',
                        'transformationFunction' => [
                            'transformationLambdaConfiguration' => [
                                'lambdaArn' => '<string>',
                            ],
                        ],
                    ],
                    // ...
                ],
            ],
            'parsingConfiguration' => [
                'bedrockFoundationModelConfiguration' => [
                    'modelArn' => '<string>',
                    'parsingPrompt' => [
                        'parsingPromptText' => '<string>',
                    ],
                ],
                'parsingStrategy' => 'BEDROCK_FOUNDATION_MODEL',
            ],
        ],
    ],
]

Result Details

Members
dataSource
Required: Yes
Type: DataSource structure

Contains details about the data source.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateFlow

$result = $client->createFlow([/* ... */]);
$promise = $client->createFlowAsync([/* ... */]);

Creates a prompt flow that you can use to send an input through various steps to yield an output. Configure nodes, each of which corresponds to a step of the flow, and create connections between the nodes to create paths to different outputs. For more information, see How it works and Create a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->createFlow([
    'clientToken' => '<string>',
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>', // REQUIRED
                    ],
                    'data' => [
                        'sourceOutput' => '<string>', // REQUIRED
                        'targetInput' => '<string>', // REQUIRED
                    ],
                ],
                'name' => '<string>', // REQUIRED
                'source' => '<string>', // REQUIRED
                'target' => '<string>', // REQUIRED
                'type' => 'Data|Conditional', // REQUIRED
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>', // REQUIRED
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [ // REQUIRED
                            [
                                'expression' => '<string>',
                                'name' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>', // REQUIRED
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>', // REQUIRED
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>', // REQUIRED
                        'localeId' => '<string>', // REQUIRED
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [ // REQUIRED
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>', // REQUIRED
                                'templateConfiguration' => [ // REQUIRED
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>', // REQUIRED
                                    ],
                                ],
                                'templateType' => 'TEXT', // REQUIRED
                            ],
                            'resource' => [
                                'promptArn' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [ // REQUIRED
                            's3' => [
                                'bucketName' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [ // REQUIRED
                            's3' => [
                                'bucketName' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>', // REQUIRED
                        'name' => '<string>', // REQUIRED
                        'type' => 'String|Number|Boolean|Object|Array', // REQUIRED
                    ],
                    // ...
                ],
                'name' => '<string>', // REQUIRED
                'outputs' => [
                    [
                        'name' => '<string>', // REQUIRED
                        'type' => 'String|Number|Boolean|Object|Array', // REQUIRED
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector', // REQUIRED
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the flow.

definition
Type: FlowDefinition structure

A definition of the nodes and connections between nodes in the flow.

description
Type: string

A description for the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create and manage a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

name
Required: Yes
Type: string

A name for the flow.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the flow. For more information, see Tagging resources in Amazon Bedrock.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>',
                    ],
                    'data' => [
                        'sourceOutput' => '<string>',
                        'targetInput' => '<string>',
                    ],
                ],
                'name' => '<string>',
                'source' => '<string>',
                'target' => '<string>',
                'type' => 'Data|Conditional',
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>',
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [
                            [
                                'expression' => '<string>',
                                'name' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>',
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>',
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>',
                        'localeId' => '<string>',
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>',
                                'templateConfiguration' => [
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>',
                                    ],
                                ],
                                'templateType' => 'TEXT',
                            ],
                            'resource' => [
                                'promptArn' => '<string>',
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>',
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'name' => '<string>',
                'outputs' => [
                    [
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector',
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
    'updatedAt' => <DateTime>,
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that you encrypted the flow with.

definition
Type: FlowDefinition structure

A definition of the nodes and connections between nodes in the flow.

description
Type: string

The description of the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow.

status
Required: Yes
Type: string

The status of the flow. When you submit this request, the status will be NotPrepared. If creation fails, the status becomes Failed.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was last updated.

version
Required: Yes
Type: string

The version of the flow. When you create a flow, the version created is the DRAFT version.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateFlowAlias

$result = $client->createFlowAlias([/* ... */]);
$promise = $client->createFlowAliasAsync([/* ... */]);

Creates an alias of a flow for deployment. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->createFlowAlias([
    'clientToken' => '<string>',
    'description' => '<string>',
    'flowIdentifier' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'routingConfiguration' => [ // REQUIRED
        [
            'flowVersion' => '<string>',
        ],
        // ...
    ],
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description for the alias.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow for which to create an alias.

name
Required: Yes
Type: string

A name for the alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

Contains information about the version to which to map the alias.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the alias of the flow. For more information, see Tagging resources in Amazon Bedrock.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'description' => '<string>',
    'flowId' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'routingConfiguration' => [
        [
            'flowVersion' => '<string>',
        ],
        // ...
    ],
    'updatedAt' => <DateTime>,
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the alias.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias was created.

description
Type: string

The description of the alias.

flowId
Required: Yes
Type: string

The unique identifier of the flow that the alias belongs to.

id
Required: Yes
Type: string

The unique identifier of the alias.

name
Required: Yes
Type: string

The name of the alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

Contains information about the version that the alias is mapped to.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias of the flow was last updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateFlowVersion

$result = $client->createFlowVersion([/* ... */]);
$promise = $client->createFlowVersionAsync([/* ... */]);

Creates a version of the flow that you can deploy. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->createFlowVersion([
    'clientToken' => '<string>',
    'description' => '<string>',
    'flowIdentifier' => '<string>', // REQUIRED
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description of the version of the flow.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow that you want to create a version of.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>',
                    ],
                    'data' => [
                        'sourceOutput' => '<string>',
                        'targetInput' => '<string>',
                    ],
                ],
                'name' => '<string>',
                'source' => '<string>',
                'target' => '<string>',
                'type' => 'Data|Conditional',
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>',
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [
                            [
                                'expression' => '<string>',
                                'name' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>',
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>',
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>',
                        'localeId' => '<string>',
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>',
                                'templateConfiguration' => [
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>',
                                    ],
                                ],
                                'templateType' => 'TEXT',
                            ],
                            'resource' => [
                                'promptArn' => '<string>',
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>',
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'name' => '<string>',
                'outputs' => [
                    [
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector',
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

customerEncryptionKeyArn
Type: string

The KMS key that the flow is encrypted with.

definition
Type: FlowDefinition structure

A definition of the nodes and connections in the flow.

description
Type: string

The description of the flow version.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow version.

status
Required: Yes
Type: string

The status of the flow.

version
Required: Yes
Type: string

The version of the flow that was created. Versions are numbered incrementally, starting from 1.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreateKnowledgeBase

$result = $client->createKnowledgeBase([/* ... */]);
$promise = $client->createKnowledgeBaseAsync([/* ... */]);

Creates a knowledge base that contains data sources from which information can be queried and used by LLMs. To create a knowledge base, you must first set up your data sources and configure a supported vector store. For more information, see Set up your data for ingestion.

If you prefer to let Amazon Bedrock create and manage a vector store for you in Amazon OpenSearch Service, use the console. For more information, see Create a knowledge base.

  • Provide the name and an optional description.

  • Provide the Amazon Resource Name (ARN) with permissions to create a knowledge base in the roleArn field.

  • Provide the embedding model to use in the embeddingModelArn field in the knowledgeBaseConfiguration object.

  • Provide the configuration for your vector store in the storageConfiguration object.

Parameter Syntax

$result = $client->createKnowledgeBase([
    'clientToken' => '<string>',
    'description' => '<string>',
    'knowledgeBaseConfiguration' => [ // REQUIRED
        'type' => 'VECTOR', // REQUIRED
        'vectorKnowledgeBaseConfiguration' => [
            'embeddingModelArn' => '<string>', // REQUIRED
            'embeddingModelConfiguration' => [
                'bedrockEmbeddingModelConfiguration' => [
                    'dimensions' => <integer>,
                ],
            ],
        ],
    ],
    'name' => '<string>', // REQUIRED
    'roleArn' => '<string>', // REQUIRED
    'storageConfiguration' => [ // REQUIRED
        'mongoDbAtlasConfiguration' => [
            'collectionName' => '<string>', // REQUIRED
            'credentialsSecretArn' => '<string>', // REQUIRED
            'databaseName' => '<string>', // REQUIRED
            'endpoint' => '<string>', // REQUIRED
            'endpointServiceName' => '<string>',
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'opensearchServerlessConfiguration' => [
            'collectionArn' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'pineconeConfiguration' => [
            'connectionString' => '<string>', // REQUIRED
            'credentialsSecretArn' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
            ],
            'namespace' => '<string>',
        ],
        'rdsConfiguration' => [
            'credentialsSecretArn' => '<string>', // REQUIRED
            'databaseName' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'primaryKeyField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'resourceArn' => '<string>', // REQUIRED
            'tableName' => '<string>', // REQUIRED
        ],
        'redisEnterpriseCloudConfiguration' => [
            'credentialsSecretArn' => '<string>', // REQUIRED
            'endpoint' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'type' => 'OPENSEARCH_SERVERLESS|PINECONE|REDIS_ENTERPRISE_CLOUD|RDS|MONGO_DB_ATLAS', // REQUIRED
    ],
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description of the knowledge base.

knowledgeBaseConfiguration
Required: Yes
Type: KnowledgeBaseConfiguration structure

Contains details about the embeddings model used for the knowledge base.

name
Required: Yes
Type: string

A name for the knowledge base.

roleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the knowledge base.

storageConfiguration
Required: Yes
Type: StorageConfiguration structure

Contains details about the configuration of the vector database used for the knowledge base.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Specify the key-value pairs for the tags that you want to attach to your knowledge base in this object.

Result Syntax

[
    'knowledgeBase' => [
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseArn' => '<string>',
        'knowledgeBaseConfiguration' => [
            'type' => 'VECTOR',
            'vectorKnowledgeBaseConfiguration' => [
                'embeddingModelArn' => '<string>',
                'embeddingModelConfiguration' => [
                    'bedrockEmbeddingModelConfiguration' => [
                        'dimensions' => <integer>,
                    ],
                ],
            ],
        ],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'roleArn' => '<string>',
        'status' => 'CREATING|ACTIVE|DELETING|UPDATING|FAILED|DELETE_UNSUCCESSFUL',
        'storageConfiguration' => [
            'mongoDbAtlasConfiguration' => [
                'collectionName' => '<string>',
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'endpoint' => '<string>',
                'endpointServiceName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'opensearchServerlessConfiguration' => [
                'collectionArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'pineconeConfiguration' => [
                'connectionString' => '<string>',
                'credentialsSecretArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                ],
                'namespace' => '<string>',
            ],
            'rdsConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'primaryKeyField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'resourceArn' => '<string>',
                'tableName' => '<string>',
            ],
            'redisEnterpriseCloudConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'endpoint' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'type' => 'OPENSEARCH_SERVERLESS|PINECONE|REDIS_ENTERPRISE_CLOUD|RDS|MONGO_DB_ATLAS',
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
knowledgeBase
Required: Yes
Type: KnowledgeBase structure

Contains details about the knowledge base.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreatePrompt

$result = $client->createPrompt([/* ... */]);
$promise = $client->createPromptAsync([/* ... */]);

Creates a prompt in your prompt library that you can add to a flow. For more information, see Prompt management in Amazon Bedrock, Create a prompt using Prompt management and Prompt flows in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->createPrompt([
    'clientToken' => '<string>',
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'name' => '<string>', // REQUIRED
    'tags' => ['<string>', ...],
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>', // REQUIRED
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>', // REQUIRED
                ],
            ],
            'templateType' => 'TEXT', // REQUIRED
        ],
        // ...
    ],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt.

defaultVariant
Type: string

The name of the default variant for the prompt. This value must match the name field in the relevant PromptVariant object.

description
Type: string

A description for the prompt.

name
Required: Yes
Type: string

A name for the prompt.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the prompt. For more information, see Tagging resources in Amazon Bedrock.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'updatedAt' => <DateTime>,
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>',
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>',
                ],
            ],
            'templateType' => 'TEXT',
        ],
        // ...
    ],
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the prompt.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that you encrypted the prompt with.

defaultVariant
Type: string

The name of the default variant for your prompt.

description
Type: string

The description of the prompt.

id
Required: Yes
Type: string

The unique identifier of the prompt.

name
Required: Yes
Type: string

The name of the prompt.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was last updated.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

version
Required: Yes
Type: string

The version of the prompt. When you create a prompt, the version created is the DRAFT version.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

CreatePromptVersion

$result = $client->createPromptVersion([/* ... */]);
$promise = $client->createPromptVersionAsync([/* ... */]);

Creates a static snapshot of your prompt that can be deployed to production. For more information, see Deploy prompts using Prompt management by creating versions in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->createPromptVersion([
    'clientToken' => '<string>',
    'description' => '<string>',
    'promptIdentifier' => '<string>', // REQUIRED
    'tags' => ['<string>', ...],
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

description
Type: string

A description for the version of the prompt.

promptIdentifier
Required: Yes
Type: string

The unique identifier of the prompt that you want to create a version of.

tags
Type: Associative array of custom strings keys (TagKey) to strings

Any tags that you want to attach to the version of the prompt. For more information, see Tagging resources in Amazon Bedrock.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'updatedAt' => <DateTime>,
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>',
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>',
                ],
            ],
            'templateType' => 'TEXT',
        ],
        // ...
    ],
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the version of the prompt.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the version of the prompt.

defaultVariant
Type: string

The name of the default variant for the prompt. This value must match the name field in the relevant PromptVariant object.

description
Type: string

A description for the prompt version.

id
Required: Yes
Type: string

The unique identifier of the prompt.

name
Required: Yes
Type: string

The name of the prompt version.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was last updated.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

version
Required: Yes
Type: string

The version of the prompt that was created. Versions are numbered incrementally, starting from 1.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

DeleteAgent

$result = $client->deleteAgent([/* ... */]);
$promise = $client->deleteAgentAsync([/* ... */]);

Deletes an agent.

Parameter Syntax

$result = $client->deleteAgent([
    'agentId' => '<string>', // REQUIRED
    'skipResourceInUseCheck' => true || false,
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent to delete.

skipResourceInUseCheck
Type: boolean

By default, this value is false and deletion is stopped if the resource is in use. If you set it to true, the resource will be deleted even if the resource is in use.

Result Syntax

[
    'agentId' => '<string>',
    'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
]

Result Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent that was deleted.

agentStatus
Required: Yes
Type: string

The status of the agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteAgentActionGroup

$result = $client->deleteAgentActionGroup([/* ... */]);
$promise = $client->deleteAgentActionGroupAsync([/* ... */]);

Deletes an action group in an agent.

Parameter Syntax

$result = $client->deleteAgentActionGroup([
    'actionGroupId' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'skipResourceInUseCheck' => true || false,
]);

Parameter Details

Members
actionGroupId
Required: Yes
Type: string

The unique identifier of the action group to delete.

agentId
Required: Yes
Type: string

The unique identifier of the agent that the action group belongs to.

agentVersion
Required: Yes
Type: string

The version of the agent that the action group belongs to.

skipResourceInUseCheck
Type: boolean

By default, this value is false and deletion is stopped if the resource is in use. If you set it to true, the resource will be deleted even if the resource is in use.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteAgentAlias

$result = $client->deleteAgentAlias([/* ... */]);
$promise = $client->deleteAgentAliasAsync([/* ... */]);

Deletes an alias of an agent.

Parameter Syntax

$result = $client->deleteAgentAlias([
    'agentAliasId' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentAliasId
Required: Yes
Type: string

The unique identifier of the alias to delete.

agentId
Required: Yes
Type: string

The unique identifier of the agent that the alias belongs to.

Result Syntax

[
    'agentAliasId' => '<string>',
    'agentAliasStatus' => 'CREATING|PREPARED|FAILED|UPDATING|DELETING',
    'agentId' => '<string>',
]

Result Details

Members
agentAliasId
Required: Yes
Type: string

The unique identifier of the alias that was deleted.

agentAliasStatus
Required: Yes
Type: string

The status of the alias.

agentId
Required: Yes
Type: string

The unique identifier of the agent that the alias belongs to.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

DeleteAgentVersion

$result = $client->deleteAgentVersion([/* ... */]);
$promise = $client->deleteAgentVersionAsync([/* ... */]);

Deletes a version of an agent.

Parameter Syntax

$result = $client->deleteAgentVersion([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'skipResourceInUseCheck' => true || false,
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent that the version belongs to.

agentVersion
Required: Yes
Type: string

The version of the agent to delete.

skipResourceInUseCheck
Type: boolean

By default, this value is false and deletion is stopped if the resource is in use. If you set it to true, the resource will be deleted even if the resource is in use.

Result Syntax

[
    'agentId' => '<string>',
    'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
    'agentVersion' => '<string>',
]

Result Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent that the version belongs to.

agentStatus
Required: Yes
Type: string

The status of the agent version.

agentVersion
Required: Yes
Type: string

The version that was deleted.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteDataSource

$result = $client->deleteDataSource([/* ... */]);
$promise = $client->deleteDataSourceAsync([/* ... */]);

Deletes a data source from a knowledge base.

Parameter Syntax

$result = $client->deleteDataSource([
    'dataSourceId' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source to delete.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base from which to delete the data source.

Result Syntax

[
    'dataSourceId' => '<string>',
    'knowledgeBaseId' => '<string>',
    'status' => 'AVAILABLE|DELETING|DELETE_UNSUCCESSFUL',
]

Result Details

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source that was deleted.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which the data source that was deleted belonged.

status
Required: Yes
Type: string

The status of the data source.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteFlow

$result = $client->deleteFlow([/* ... */]);
$promise = $client->deleteFlowAsync([/* ... */]);

Deletes a flow.

Parameter Syntax

$result = $client->deleteFlow([
    'flowIdentifier' => '<string>', // REQUIRED
    'skipResourceInUseCheck' => true || false,
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

skipResourceInUseCheck
Type: boolean

By default, this value is false and deletion is stopped if the resource is in use. If you set it to true, the resource will be deleted even if the resource is in use.

Result Syntax

[
    'id' => '<string>',
]

Result Details

Members
id
Required: Yes
Type: string

The unique identifier of the flow.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteFlowAlias

$result = $client->deleteFlowAlias([/* ... */]);
$promise = $client->deleteFlowAliasAsync([/* ... */]);

Deletes an alias of a flow.

Parameter Syntax

$result = $client->deleteFlowAlias([
    'aliasIdentifier' => '<string>', // REQUIRED
    'flowIdentifier' => '<string>', // REQUIRED
]);

Parameter Details

Members
aliasIdentifier
Required: Yes
Type: string

The unique identifier of the alias to be deleted.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow that the alias belongs to.

Result Syntax

[
    'flowId' => '<string>',
    'id' => '<string>',
]

Result Details

Members
flowId
Required: Yes
Type: string

The unique identifier of the flow that the alias belongs to.

id
Required: Yes
Type: string

The unique identifier of the flow.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteFlowVersion

$result = $client->deleteFlowVersion([/* ... */]);
$promise = $client->deleteFlowVersionAsync([/* ... */]);

Deletes a version of a flow.

Parameter Syntax

$result = $client->deleteFlowVersion([
    'flowIdentifier' => '<string>', // REQUIRED
    'flowVersion' => '<string>', // REQUIRED
    'skipResourceInUseCheck' => true || false,
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow whose version that you want to delete

flowVersion
Required: Yes
Type: string

The version of the flow that you want to delete.

skipResourceInUseCheck
Type: boolean

By default, this value is false and deletion is stopped if the resource is in use. If you set it to true, the resource will be deleted even if the resource is in use.

Result Syntax

[
    'id' => '<string>',
    'version' => '<string>',
]

Result Details

Members
id
Required: Yes
Type: string

The unique identifier of the flow.

version
Required: Yes
Type: string

The version of the flow being deleted.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeleteKnowledgeBase

$result = $client->deleteKnowledgeBase([/* ... */]);
$promise = $client->deleteKnowledgeBaseAsync([/* ... */]);

Deletes a knowledge base. Before deleting a knowledge base, you should disassociate the knowledge base from any agents that it is associated with by making a DisassociateAgentKnowledgeBase request.

Parameter Syntax

$result = $client->deleteKnowledgeBase([
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to delete.

Result Syntax

[
    'knowledgeBaseId' => '<string>',
    'status' => 'CREATING|ACTIVE|DELETING|UPDATING|FAILED|DELETE_UNSUCCESSFUL',
]

Result Details

Members
knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base that was deleted.

status
Required: Yes
Type: string

The status of the knowledge base and whether it has been successfully deleted.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DeletePrompt

$result = $client->deletePrompt([/* ... */]);
$promise = $client->deletePromptAsync([/* ... */]);

Deletes a prompt or a prompt version from the Prompt management tool. For more information, see Delete prompts from the Prompt management tool and Delete a version of a prompt from the Prompt management tool in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->deletePrompt([
    'promptIdentifier' => '<string>', // REQUIRED
    'promptVersion' => '<string>',
]);

Parameter Details

Members
promptIdentifier
Required: Yes
Type: string

The unique identifier of the prompt.

promptVersion
Type: string

The version of the prompt to delete.

Result Syntax

[
    'id' => '<string>',
    'version' => '<string>',
]

Result Details

Members
id
Required: Yes
Type: string

The unique identifier of the prompt that was deleted.

version
Type: string

The version of the prompt that was deleted.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

DisassociateAgentKnowledgeBase

$result = $client->disassociateAgentKnowledgeBase([/* ... */]);
$promise = $client->disassociateAgentKnowledgeBaseAsync([/* ... */]);

Disassociates a knowledge base from an agent.

Parameter Syntax

$result = $client->disassociateAgentKnowledgeBase([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent from which to disassociate the knowledge base.

agentVersion
Required: Yes
Type: string

The version of the agent from which to disassociate the knowledge base.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to disassociate.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

GetAgent

$result = $client->getAgent([/* ... */]);
$promise = $client->getAgentAsync([/* ... */]);

Gets information about an agent.

Parameter Syntax

$result = $client->getAgent([
    'agentId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

Result Syntax

[
    'agent' => [
        'agentArn' => '<string>',
        'agentId' => '<string>',
        'agentName' => '<string>',
        'agentResourceRoleArn' => '<string>',
        'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
        'agentVersion' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'customerEncryptionKeyArn' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'foundationModel' => '<string>',
        'guardrailConfiguration' => [
            'guardrailIdentifier' => '<string>',
            'guardrailVersion' => '<string>',
        ],
        'idleSessionTTLInSeconds' => <integer>,
        'instruction' => '<string>',
        'memoryConfiguration' => [
            'enabledMemoryTypes' => ['<string>', ...],
            'storageDays' => <integer>,
        ],
        'preparedAt' => <DateTime>,
        'promptOverrideConfiguration' => [
            'overrideLambda' => '<string>',
            'promptConfigurations' => [
                [
                    'basePromptTemplate' => '<string>',
                    'inferenceConfiguration' => [
                        'maximumLength' => <integer>,
                        'stopSequences' => ['<string>', ...],
                        'temperature' => <float>,
                        'topK' => <integer>,
                        'topP' => <float>,
                    ],
                    'parserMode' => 'DEFAULT|OVERRIDDEN',
                    'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                    'promptState' => 'ENABLED|DISABLED',
                    'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
                ],
                // ...
            ],
        ],
        'recommendedActions' => ['<string>', ...],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agent
Required: Yes
Type: Agent structure

Contains details about the agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetAgentActionGroup

$result = $client->getAgentActionGroup([/* ... */]);
$promise = $client->getAgentActionGroupAsync([/* ... */]);

Gets information about an action group for an agent.

Parameter Syntax

$result = $client->getAgentActionGroup([
    'actionGroupId' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
]);

Parameter Details

Members
actionGroupId
Required: Yes
Type: string

The unique identifier of the action group for which to get information.

agentId
Required: Yes
Type: string

The unique identifier of the agent that the action group belongs to.

agentVersion
Required: Yes
Type: string

The version of the agent that the action group belongs to.

Result Syntax

[
    'agentActionGroup' => [
        'actionGroupExecutor' => [
            'customControl' => 'RETURN_CONTROL',
            'lambda' => '<string>',
        ],
        'actionGroupId' => '<string>',
        'actionGroupName' => '<string>',
        'actionGroupState' => 'ENABLED|DISABLED',
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'apiSchema' => [
            'payload' => '<string>',
            's3' => [
                's3BucketName' => '<string>',
                's3ObjectKey' => '<string>',
            ],
        ],
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'functionSchema' => [
            'functions' => [
                [
                    'description' => '<string>',
                    'name' => '<string>',
                    'parameters' => [
                        '<Name>' => [
                            'description' => '<string>',
                            'required' => true || false,
                            'type' => 'string|number|integer|boolean|array',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
        ],
        'parentActionSignature' => 'AMAZON.UserInput|AMAZON.CodeInterpreter',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentActionGroup
Required: Yes
Type: AgentActionGroup structure

Contains details about the action group.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetAgentAlias

$result = $client->getAgentAlias([/* ... */]);
$promise = $client->getAgentAliasAsync([/* ... */]);

Gets information about an alias of an agent.

Parameter Syntax

$result = $client->getAgentAlias([
    'agentAliasId' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentAliasId
Required: Yes
Type: string

The unique identifier of the alias for which to get information.

agentId
Required: Yes
Type: string

The unique identifier of the agent to which the alias to get information belongs.

Result Syntax

[
    'agentAlias' => [
        'agentAliasArn' => '<string>',
        'agentAliasHistoryEvents' => [
            [
                'endDate' => <DateTime>,
                'routingConfiguration' => [
                    [
                        'agentVersion' => '<string>',
                        'provisionedThroughput' => '<string>',
                    ],
                    // ...
                ],
                'startDate' => <DateTime>,
            ],
            // ...
        ],
        'agentAliasId' => '<string>',
        'agentAliasName' => '<string>',
        'agentAliasStatus' => 'CREATING|PREPARED|FAILED|UPDATING|DELETING',
        'agentId' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'routingConfiguration' => [
            [
                'agentVersion' => '<string>',
                'provisionedThroughput' => '<string>',
            ],
            // ...
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentAlias
Required: Yes
Type: AgentAlias structure

Contains information about the alias.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetAgentKnowledgeBase

$result = $client->getAgentKnowledgeBase([/* ... */]);
$promise = $client->getAgentKnowledgeBaseAsync([/* ... */]);

Gets information about a knowledge base associated with an agent.

Parameter Syntax

$result = $client->getAgentKnowledgeBase([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent with which the knowledge base is associated.

agentVersion
Required: Yes
Type: string

The version of the agent with which the knowledge base is associated.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base associated with the agent.

Result Syntax

[
    'agentKnowledgeBase' => [
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'knowledgeBaseId' => '<string>',
        'knowledgeBaseState' => 'ENABLED|DISABLED',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentKnowledgeBase
Required: Yes
Type: AgentKnowledgeBase structure

Contains details about a knowledge base attached to an agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetAgentVersion

$result = $client->getAgentVersion([/* ... */]);
$promise = $client->getAgentVersionAsync([/* ... */]);

Gets details about a version of an agent.

Parameter Syntax

$result = $client->getAgentVersion([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

agentVersion
Required: Yes
Type: string

The version of the agent.

Result Syntax

[
    'agentVersion' => [
        'agentArn' => '<string>',
        'agentId' => '<string>',
        'agentName' => '<string>',
        'agentResourceRoleArn' => '<string>',
        'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
        'createdAt' => <DateTime>,
        'customerEncryptionKeyArn' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'foundationModel' => '<string>',
        'guardrailConfiguration' => [
            'guardrailIdentifier' => '<string>',
            'guardrailVersion' => '<string>',
        ],
        'idleSessionTTLInSeconds' => <integer>,
        'instruction' => '<string>',
        'memoryConfiguration' => [
            'enabledMemoryTypes' => ['<string>', ...],
            'storageDays' => <integer>,
        ],
        'promptOverrideConfiguration' => [
            'overrideLambda' => '<string>',
            'promptConfigurations' => [
                [
                    'basePromptTemplate' => '<string>',
                    'inferenceConfiguration' => [
                        'maximumLength' => <integer>,
                        'stopSequences' => ['<string>', ...],
                        'temperature' => <float>,
                        'topK' => <integer>,
                        'topP' => <float>,
                    ],
                    'parserMode' => 'DEFAULT|OVERRIDDEN',
                    'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                    'promptState' => 'ENABLED|DISABLED',
                    'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
                ],
                // ...
            ],
        ],
        'recommendedActions' => ['<string>', ...],
        'updatedAt' => <DateTime>,
        'version' => '<string>',
    ],
]

Result Details

Members
agentVersion
Required: Yes
Type: AgentVersion structure

Contains details about the version of the agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetDataSource

$result = $client->getDataSource([/* ... */]);
$promise = $client->getDataSourceAsync([/* ... */]);

Gets information about a data source.

Parameter Syntax

$result = $client->getDataSource([
    'dataSourceId' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base that the data source was added to.

Result Syntax

[
    'dataSource' => [
        'createdAt' => <DateTime>,
        'dataDeletionPolicy' => 'RETAIN|DELETE',
        'dataSourceConfiguration' => [
            'confluenceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'BASIC|OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostType' => 'SAAS',
                    'hostUrl' => '<string>',
                ],
            ],
            's3Configuration' => [
                'bucketArn' => '<string>',
                'bucketOwnerAccountId' => '<string>',
                'inclusionPrefixes' => ['<string>', ...],
            ],
            'salesforceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostUrl' => '<string>',
                ],
            ],
            'sharePointConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'domain' => '<string>',
                    'hostType' => 'ONLINE',
                    'siteUrls' => ['<string>', ...],
                    'tenantId' => '<string>',
                ],
            ],
            'type' => 'S3|WEB|CONFLUENCE|SALESFORCE|SHAREPOINT',
            'webConfiguration' => [
                'crawlerConfiguration' => [
                    'crawlerLimits' => [
                        'rateLimit' => <integer>,
                    ],
                    'exclusionFilters' => ['<string>', ...],
                    'inclusionFilters' => ['<string>', ...],
                    'scope' => 'HOST_ONLY|SUBDOMAINS',
                ],
                'sourceConfiguration' => [
                    'urlConfiguration' => [
                        'seedUrls' => [
                            [
                                'url' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                ],
            ],
        ],
        'dataSourceId' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'serverSideEncryptionConfiguration' => [
            'kmsKeyArn' => '<string>',
        ],
        'status' => 'AVAILABLE|DELETING|DELETE_UNSUCCESSFUL',
        'updatedAt' => <DateTime>,
        'vectorIngestionConfiguration' => [
            'chunkingConfiguration' => [
                'chunkingStrategy' => 'FIXED_SIZE|NONE|HIERARCHICAL|SEMANTIC',
                'fixedSizeChunkingConfiguration' => [
                    'maxTokens' => <integer>,
                    'overlapPercentage' => <integer>,
                ],
                'hierarchicalChunkingConfiguration' => [
                    'levelConfigurations' => [
                        [
                            'maxTokens' => <integer>,
                        ],
                        // ...
                    ],
                    'overlapTokens' => <integer>,
                ],
                'semanticChunkingConfiguration' => [
                    'breakpointPercentileThreshold' => <integer>,
                    'bufferSize' => <integer>,
                    'maxTokens' => <integer>,
                ],
            ],
            'customTransformationConfiguration' => [
                'intermediateStorage' => [
                    's3Location' => [
                        'uri' => '<string>',
                    ],
                ],
                'transformations' => [
                    [
                        'stepToApply' => 'POST_CHUNKING',
                        'transformationFunction' => [
                            'transformationLambdaConfiguration' => [
                                'lambdaArn' => '<string>',
                            ],
                        ],
                    ],
                    // ...
                ],
            ],
            'parsingConfiguration' => [
                'bedrockFoundationModelConfiguration' => [
                    'modelArn' => '<string>',
                    'parsingPrompt' => [
                        'parsingPromptText' => '<string>',
                    ],
                ],
                'parsingStrategy' => 'BEDROCK_FOUNDATION_MODEL',
            ],
        ],
    ],
]

Result Details

Members
dataSource
Required: Yes
Type: DataSource structure

Contains details about the data source.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetFlow

$result = $client->getFlow([/* ... */]);
$promise = $client->getFlowAsync([/* ... */]);

Retrieves information about a flow. For more information, see Manage a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->getFlow([
    'flowIdentifier' => '<string>', // REQUIRED
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>',
                    ],
                    'data' => [
                        'sourceOutput' => '<string>',
                        'targetInput' => '<string>',
                    ],
                ],
                'name' => '<string>',
                'source' => '<string>',
                'target' => '<string>',
                'type' => 'Data|Conditional',
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>',
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [
                            [
                                'expression' => '<string>',
                                'name' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>',
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>',
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>',
                        'localeId' => '<string>',
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>',
                                'templateConfiguration' => [
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>',
                                    ],
                                ],
                                'templateType' => 'TEXT',
                            ],
                            'resource' => [
                                'promptArn' => '<string>',
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>',
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'name' => '<string>',
                'outputs' => [
                    [
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector',
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
    'updatedAt' => <DateTime>,
    'validations' => [
        [
            'message' => '<string>',
            'severity' => 'Warning|Error',
        ],
        // ...
    ],
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that the flow is encrypted with.

definition
Type: FlowDefinition structure

The definition of the nodes and connections between the nodes in the flow.

description
Type: string

The description of the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create a flow. For more information, see Create a service row for flows in the Amazon Bedrock User Guide.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow.

status
Required: Yes
Type: string

The status of the flow. The following statuses are possible:

  • NotPrepared – The flow has been created or updated, but hasn't been prepared. If you just created the flow, you can't test it. If you updated the flow, the DRAFT version won't contain the latest changes for testing. Send a PrepareFlow request to package the latest changes into the DRAFT version.

  • Preparing – The flow is being prepared so that the DRAFT version contains the latest changes for testing.

  • Prepared – The flow is prepared and the DRAFT version contains the latest changes for testing.

  • Failed – The last API operation that you invoked on the flow failed. Send a GetFlow request and check the error message in the validations field.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was last updated.

validations
Type: Array of FlowValidation structures

A list of validation error messages related to the last failed operation on the flow.

version
Required: Yes
Type: string

The version of the flow for which information was retrieved.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetFlowAlias

$result = $client->getFlowAlias([/* ... */]);
$promise = $client->getFlowAliasAsync([/* ... */]);

Retrieves information about a flow. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->getFlowAlias([
    'aliasIdentifier' => '<string>', // REQUIRED
    'flowIdentifier' => '<string>', // REQUIRED
]);

Parameter Details

Members
aliasIdentifier
Required: Yes
Type: string

The unique identifier of the alias for which to retrieve information.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow that the alias belongs to.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'description' => '<string>',
    'flowId' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'routingConfiguration' => [
        [
            'flowVersion' => '<string>',
        ],
        // ...
    ],
    'updatedAt' => <DateTime>,
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

description
Type: string

The description of the flow.

flowId
Required: Yes
Type: string

The unique identifier of the flow that the alias belongs to.

id
Required: Yes
Type: string

The unique identifier of the alias of the flow.

name
Required: Yes
Type: string

The name of the flow alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

Contains information about the version that the alias is mapped to.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow alias was last updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetFlowVersion

$result = $client->getFlowVersion([/* ... */]);
$promise = $client->getFlowVersionAsync([/* ... */]);

Retrieves information about a version of a flow. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->getFlowVersion([
    'flowIdentifier' => '<string>', // REQUIRED
    'flowVersion' => '<string>', // REQUIRED
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow for which to get information.

flowVersion
Required: Yes
Type: string

The version of the flow for which to get information.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>',
                    ],
                    'data' => [
                        'sourceOutput' => '<string>',
                        'targetInput' => '<string>',
                    ],
                ],
                'name' => '<string>',
                'source' => '<string>',
                'target' => '<string>',
                'type' => 'Data|Conditional',
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>',
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [
                            [
                                'expression' => '<string>',
                                'name' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>',
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>',
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>',
                        'localeId' => '<string>',
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>',
                                'templateConfiguration' => [
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>',
                                    ],
                                ],
                                'templateType' => 'TEXT',
                            ],
                            'resource' => [
                                'promptArn' => '<string>',
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>',
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'name' => '<string>',
                'outputs' => [
                    [
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector',
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that the version of the flow is encrypted with.

definition
Type: FlowDefinition structure

The definition of the nodes and connections between nodes in the flow.

description
Type: string

The description of the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow version.

status
Required: Yes
Type: string

The status of the flow.

version
Required: Yes
Type: string

The version of the flow for which information was retrieved.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetIngestionJob

$result = $client->getIngestionJob([/* ... */]);
$promise = $client->getIngestionJobAsync([/* ... */]);

Gets information about a ingestion job, in which a data source is added to a knowledge base.

Parameter Syntax

$result = $client->getIngestionJob([
    'dataSourceId' => '<string>', // REQUIRED
    'ingestionJobId' => '<string>', // REQUIRED
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source in the ingestion job.

ingestionJobId
Required: Yes
Type: string

The unique identifier of the ingestion job.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base for which the ingestion job applies.

Result Syntax

[
    'ingestionJob' => [
        'dataSourceId' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'ingestionJobId' => '<string>',
        'knowledgeBaseId' => '<string>',
        'startedAt' => <DateTime>,
        'statistics' => [
            'numberOfDocumentsDeleted' => <integer>,
            'numberOfDocumentsFailed' => <integer>,
            'numberOfDocumentsScanned' => <integer>,
            'numberOfMetadataDocumentsModified' => <integer>,
            'numberOfMetadataDocumentsScanned' => <integer>,
            'numberOfModifiedDocumentsIndexed' => <integer>,
            'numberOfNewDocumentsIndexed' => <integer>,
        ],
        'status' => 'STARTING|IN_PROGRESS|COMPLETE|FAILED',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
ingestionJob
Required: Yes
Type: IngestionJob structure

Contains details about the ingestion job.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetKnowledgeBase

$result = $client->getKnowledgeBase([/* ... */]);
$promise = $client->getKnowledgeBaseAsync([/* ... */]);

Gets information about a knoweldge base.

Parameter Syntax

$result = $client->getKnowledgeBase([
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base for which to get information.

Result Syntax

[
    'knowledgeBase' => [
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseArn' => '<string>',
        'knowledgeBaseConfiguration' => [
            'type' => 'VECTOR',
            'vectorKnowledgeBaseConfiguration' => [
                'embeddingModelArn' => '<string>',
                'embeddingModelConfiguration' => [
                    'bedrockEmbeddingModelConfiguration' => [
                        'dimensions' => <integer>,
                    ],
                ],
            ],
        ],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'roleArn' => '<string>',
        'status' => 'CREATING|ACTIVE|DELETING|UPDATING|FAILED|DELETE_UNSUCCESSFUL',
        'storageConfiguration' => [
            'mongoDbAtlasConfiguration' => [
                'collectionName' => '<string>',
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'endpoint' => '<string>',
                'endpointServiceName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'opensearchServerlessConfiguration' => [
                'collectionArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'pineconeConfiguration' => [
                'connectionString' => '<string>',
                'credentialsSecretArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                ],
                'namespace' => '<string>',
            ],
            'rdsConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'primaryKeyField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'resourceArn' => '<string>',
                'tableName' => '<string>',
            ],
            'redisEnterpriseCloudConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'endpoint' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'type' => 'OPENSEARCH_SERVERLESS|PINECONE|REDIS_ENTERPRISE_CLOUD|RDS|MONGO_DB_ATLAS',
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
knowledgeBase
Required: Yes
Type: KnowledgeBase structure

Contains details about the knowledge base.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

GetPrompt

$result = $client->getPrompt([/* ... */]);
$promise = $client->getPromptAsync([/* ... */]);

Retrieves information about a prompt or a version of it. For more information, see View information about prompts using Prompt management and View information about a version of your prompt in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->getPrompt([
    'promptIdentifier' => '<string>', // REQUIRED
    'promptVersion' => '<string>',
]);

Parameter Details

Members
promptIdentifier
Required: Yes
Type: string

The unique identifier of the prompt.

promptVersion
Type: string

The version of the prompt about which you want to retrieve information.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'updatedAt' => <DateTime>,
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>',
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>',
                ],
            ],
            'templateType' => 'TEXT',
        ],
        // ...
    ],
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the prompt.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that the prompt is encrypted with.

defaultVariant
Type: string

The name of the default variant for the prompt. This value must match the name field in the relevant PromptVariant object.

description
Type: string

The descriptino of the prompt.

id
Required: Yes
Type: string

The unique identifier of the prompt.

name
Required: Yes
Type: string

The name of the prompt.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was last updated.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

version
Required: Yes
Type: string

The version of the prompt.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListAgentActionGroups

$result = $client->listAgentActionGroups([/* ... */]);
$promise = $client->listAgentActionGroupsAsync([/* ... */]);

Lists the action groups for an agent and information about each one.

Parameter Syntax

$result = $client->listAgentActionGroups([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

agentVersion
Required: Yes
Type: string

The version of the agent.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'actionGroupSummaries' => [
        [
            'actionGroupId' => '<string>',
            'actionGroupName' => '<string>',
            'actionGroupState' => 'ENABLED|DISABLED',
            'description' => '<string>',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
actionGroupSummaries
Required: Yes
Type: Array of ActionGroupSummary structures

A list of objects, each of which contains information about an action group.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListAgentAliases

$result = $client->listAgentAliases([/* ... */]);
$promise = $client->listAgentAliasesAsync([/* ... */]);

Lists the aliases of an agent and information about each one.

Parameter Syntax

$result = $client->listAgentAliases([
    'agentId' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'agentAliasSummaries' => [
        [
            'agentAliasId' => '<string>',
            'agentAliasName' => '<string>',
            'agentAliasStatus' => 'CREATING|PREPARED|FAILED|UPDATING|DELETING',
            'createdAt' => <DateTime>,
            'description' => '<string>',
            'routingConfiguration' => [
                [
                    'agentVersion' => '<string>',
                    'provisionedThroughput' => '<string>',
                ],
                // ...
            ],
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
agentAliasSummaries
Required: Yes
Type: Array of AgentAliasSummary structures

A list of objects, each of which contains information about an alias of the agent.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListAgentKnowledgeBases

$result = $client->listAgentKnowledgeBases([/* ... */]);
$promise = $client->listAgentKnowledgeBasesAsync([/* ... */]);

Lists knowledge bases associated with an agent and information about each one.

Parameter Syntax

$result = $client->listAgentKnowledgeBases([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent for which to return information about knowledge bases associated with it.

agentVersion
Required: Yes
Type: string

The version of the agent for which to return information about knowledge bases associated with it.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'agentKnowledgeBaseSummaries' => [
        [
            'description' => '<string>',
            'knowledgeBaseId' => '<string>',
            'knowledgeBaseState' => 'ENABLED|DISABLED',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
agentKnowledgeBaseSummaries
Required: Yes
Type: Array of AgentKnowledgeBaseSummary structures

A list of objects, each of which contains information about a knowledge base associated with the agent.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListAgentVersions

$result = $client->listAgentVersions([/* ... */]);
$promise = $client->listAgentVersionsAsync([/* ... */]);

Lists the versions of an agent and information about each version.

Parameter Syntax

$result = $client->listAgentVersions([
    'agentId' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'agentVersionSummaries' => [
        [
            'agentName' => '<string>',
            'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
            'agentVersion' => '<string>',
            'createdAt' => <DateTime>,
            'description' => '<string>',
            'guardrailConfiguration' => [
                'guardrailIdentifier' => '<string>',
                'guardrailVersion' => '<string>',
            ],
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
agentVersionSummaries
Required: Yes
Type: Array of AgentVersionSummary structures

A list of objects, each of which contains information about a version of the agent.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListAgents

$result = $client->listAgents([/* ... */]);
$promise = $client->listAgentsAsync([/* ... */]);

Lists the agents belonging to an account and information about each agent.

Parameter Syntax

$result = $client->listAgents([
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'agentSummaries' => [
        [
            'agentId' => '<string>',
            'agentName' => '<string>',
            'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
            'description' => '<string>',
            'guardrailConfiguration' => [
                'guardrailIdentifier' => '<string>',
                'guardrailVersion' => '<string>',
            ],
            'latestAgentVersion' => '<string>',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
agentSummaries
Required: Yes
Type: Array of AgentSummary structures

A list of objects, each of which contains information about an agent.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ListDataSources

$result = $client->listDataSources([/* ... */]);
$promise = $client->listDataSourcesAsync([/* ... */]);

Lists the data sources in a knowledge base and information about each one.

Parameter Syntax

$result = $client->listDataSources([
    'knowledgeBaseId' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base for which to return a list of information.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'dataSourceSummaries' => [
        [
            'dataSourceId' => '<string>',
            'description' => '<string>',
            'knowledgeBaseId' => '<string>',
            'name' => '<string>',
            'status' => 'AVAILABLE|DELETING|DELETE_UNSUCCESSFUL',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
dataSourceSummaries
Required: Yes
Type: Array of DataSourceSummary structures

A list of objects, each of which contains information about a data source.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListFlowAliases

$result = $client->listFlowAliases([/* ... */]);
$promise = $client->listFlowAliasesAsync([/* ... */]);

Returns a list of aliases for a flow.

Parameter Syntax

$result = $client->listFlowAliases([
    'flowIdentifier' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow for which aliases are being returned.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'flowAliasSummaries' => [
        [
            'arn' => '<string>',
            'createdAt' => <DateTime>,
            'description' => '<string>',
            'flowId' => '<string>',
            'id' => '<string>',
            'name' => '<string>',
            'routingConfiguration' => [
                [
                    'flowVersion' => '<string>',
                ],
                // ...
            ],
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
flowAliasSummaries
Required: Yes
Type: Array of FlowAliasSummary structures

A list, each member of which contains information about a flow alias.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListFlowVersions

$result = $client->listFlowVersions([/* ... */]);
$promise = $client->listFlowVersionsAsync([/* ... */]);

Returns a list of information about each flow. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->listFlowVersions([
    'flowIdentifier' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'flowVersionSummaries' => [
        [
            'arn' => '<string>',
            'createdAt' => <DateTime>,
            'id' => '<string>',
            'status' => 'Failed|Prepared|Preparing|NotPrepared',
            'version' => '<string>',
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
flowVersionSummaries
Required: Yes
Type: Array of FlowVersionSummary structures

A list, each member of which contains information about a flow.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListFlows

$result = $client->listFlows([/* ... */]);
$promise = $client->listFlowsAsync([/* ... */]);

Returns a list of flows and information about each flow. For more information, see Manage a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->listFlows([
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'flowSummaries' => [
        [
            'arn' => '<string>',
            'createdAt' => <DateTime>,
            'description' => '<string>',
            'id' => '<string>',
            'name' => '<string>',
            'status' => 'Failed|Prepared|Preparing|NotPrepared',
            'updatedAt' => <DateTime>,
            'version' => '<string>',
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
flowSummaries
Required: Yes
Type: Array of FlowSummary structures

A list, each member of which contains information about a flow.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ListIngestionJobs

$result = $client->listIngestionJobs([/* ... */]);
$promise = $client->listIngestionJobsAsync([/* ... */]);

Lists the ingestion jobs for a data source and information about each of them.

Parameter Syntax

$result = $client->listIngestionJobs([
    'dataSourceId' => '<string>', // REQUIRED
    'filters' => [
        [
            'attribute' => 'STATUS', // REQUIRED
            'operator' => 'EQ', // REQUIRED
            'values' => ['<string>', ...], // REQUIRED
        ],
        // ...
    ],
    'knowledgeBaseId' => '<string>', // REQUIRED
    'maxResults' => <integer>,
    'nextToken' => '<string>',
    'sortBy' => [
        'attribute' => 'STATUS|STARTED_AT', // REQUIRED
        'order' => 'ASCENDING|DESCENDING', // REQUIRED
    ],
]);

Parameter Details

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source for which to return ingestion jobs.

filters
Type: Array of IngestionJobFilter structures

Contains a definition of a filter for which to filter the results.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base for which to return ingestion jobs.

maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

sortBy
Type: IngestionJobSortBy structure

Contains details about how to sort the results.

Result Syntax

[
    'ingestionJobSummaries' => [
        [
            'dataSourceId' => '<string>',
            'description' => '<string>',
            'ingestionJobId' => '<string>',
            'knowledgeBaseId' => '<string>',
            'startedAt' => <DateTime>,
            'statistics' => [
                'numberOfDocumentsDeleted' => <integer>,
                'numberOfDocumentsFailed' => <integer>,
                'numberOfDocumentsScanned' => <integer>,
                'numberOfMetadataDocumentsModified' => <integer>,
                'numberOfMetadataDocumentsScanned' => <integer>,
                'numberOfModifiedDocumentsIndexed' => <integer>,
                'numberOfNewDocumentsIndexed' => <integer>,
            ],
            'status' => 'STARTING|IN_PROGRESS|COMPLETE|FAILED',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
ingestionJobSummaries
Required: Yes
Type: Array of IngestionJobSummary structures

A list of objects, each of which contains information about an ingestion job.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListKnowledgeBases

$result = $client->listKnowledgeBases([/* ... */]);
$promise = $client->listKnowledgeBasesAsync([/* ... */]);

Lists the knowledge bases in an account and information about each of them.

Parameter Syntax

$result = $client->listKnowledgeBases([
    'maxResults' => <integer>,
    'nextToken' => '<string>',
]);

Parameter Details

Members
maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

Result Syntax

[
    'knowledgeBaseSummaries' => [
        [
            'description' => '<string>',
            'knowledgeBaseId' => '<string>',
            'name' => '<string>',
            'status' => 'CREATING|ACTIVE|DELETING|UPDATING|FAILED|DELETE_UNSUCCESSFUL',
            'updatedAt' => <DateTime>,
        ],
        // ...
    ],
    'nextToken' => '<string>',
]

Result Details

Members
knowledgeBaseSummaries
Required: Yes
Type: Array of KnowledgeBaseSummary structures

A list of objects, each of which contains information about a knowledge base.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ListPrompts

$result = $client->listPrompts([/* ... */]);
$promise = $client->listPromptsAsync([/* ... */]);

Returns a list of prompts from the Prompt management tool and information about each prompt. For more information, see View information about prompts using Prompt management in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->listPrompts([
    'maxResults' => <integer>,
    'nextToken' => '<string>',
    'promptIdentifier' => '<string>',
]);

Parameter Details

Members
maxResults
Type: int

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

promptIdentifier
Type: string

The unique identifier of the prompt.

Result Syntax

[
    'nextToken' => '<string>',
    'promptSummaries' => [
        [
            'arn' => '<string>',
            'createdAt' => <DateTime>,
            'description' => '<string>',
            'id' => '<string>',
            'name' => '<string>',
            'updatedAt' => <DateTime>,
            'version' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
nextToken
Type: string

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

promptSummaries
Required: Yes
Type: Array of PromptSummary structures

A list, each member of which contains information about a prompt using Prompt management.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ListTagsForResource

$result = $client->listTagsForResource([/* ... */]);
$promise = $client->listTagsForResourceAsync([/* ... */]);

List all the tags for the resource you specify.

Parameter Syntax

$result = $client->listTagsForResource([
    'resourceArn' => '<string>', // REQUIRED
]);

Parameter Details

Members
resourceArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the resource for which to list tags.

Result Syntax

[
    'tags' => ['<string>', ...],
]

Result Details

Members
tags
Type: Associative array of custom strings keys (TagKey) to strings

The key-value pairs for the tags associated with the resource.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

PrepareAgent

$result = $client->prepareAgent([/* ... */]);
$promise = $client->prepareAgentAsync([/* ... */]);

Creates a DRAFT version of the agent that can be used for internal testing.

Parameter Syntax

$result = $client->prepareAgent([
    'agentId' => '<string>', // REQUIRED
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent for which to create a DRAFT version.

Result Syntax

[
    'agentId' => '<string>',
    'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
    'agentVersion' => '<string>',
    'preparedAt' => <DateTime>,
]

Result Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent for which the DRAFT version was created.

agentStatus
Required: Yes
Type: string

The status of the DRAFT version and whether it is ready for use.

agentVersion
Required: Yes
Type: string

The version of the agent.

preparedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the DRAFT version of the agent was last prepared.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

PrepareFlow

$result = $client->prepareFlow([/* ... */]);
$promise = $client->prepareFlowAsync([/* ... */]);

Prepares the DRAFT version of a flow so that it can be invoked. For more information, see Test a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->prepareFlow([
    'flowIdentifier' => '<string>', // REQUIRED
]);

Parameter Details

Members
flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

Result Syntax

[
    'id' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
]

Result Details

Members
id
Required: Yes
Type: string

The unique identifier of the flow.

status
Required: Yes
Type: string

The status of the flow. When you submit this request, the status will be NotPrepared. If preparation succeeds, the status becomes Prepared. If it fails, the status becomes FAILED.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

StartIngestionJob

$result = $client->startIngestionJob([/* ... */]);
$promise = $client->startIngestionJobAsync([/* ... */]);

Begins an ingestion job, in which a data source is added to a knowledge base.

Parameter Syntax

$result = $client->startIngestionJob([
    'clientToken' => '<string>',
    'dataSourceId' => '<string>', // REQUIRED
    'description' => '<string>',
    'knowledgeBaseId' => '<string>', // REQUIRED
]);

Parameter Details

Members
clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

dataSourceId
Required: Yes
Type: string

The unique identifier of the data source to ingest.

description
Type: string

A description of the ingestion job.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which to add the data source.

Result Syntax

[
    'ingestionJob' => [
        'dataSourceId' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'ingestionJobId' => '<string>',
        'knowledgeBaseId' => '<string>',
        'startedAt' => <DateTime>,
        'statistics' => [
            'numberOfDocumentsDeleted' => <integer>,
            'numberOfDocumentsFailed' => <integer>,
            'numberOfDocumentsScanned' => <integer>,
            'numberOfMetadataDocumentsModified' => <integer>,
            'numberOfMetadataDocumentsScanned' => <integer>,
            'numberOfModifiedDocumentsIndexed' => <integer>,
            'numberOfNewDocumentsIndexed' => <integer>,
        ],
        'status' => 'STARTING|IN_PROGRESS|COMPLETE|FAILED',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
ingestionJob
Required: Yes
Type: IngestionJob structure

An object containing information about the ingestion job.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

TagResource

$result = $client->tagResource([/* ... */]);
$promise = $client->tagResourceAsync([/* ... */]);

Associate tags with a resource. For more information, see Tagging resources in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->tagResource([
    'resourceArn' => '<string>', // REQUIRED
    'tags' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
resourceArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the resource to tag.

tags
Required: Yes
Type: Associative array of custom strings keys (TagKey) to strings

An object containing key-value pairs that define the tags to attach to the resource.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UntagResource

$result = $client->untagResource([/* ... */]);
$promise = $client->untagResourceAsync([/* ... */]);

Remove tags from a resource.

Parameter Syntax

$result = $client->untagResource([
    'resourceArn' => '<string>', // REQUIRED
    'tagKeys' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
resourceArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the resource from which to remove tags.

tagKeys
Required: Yes
Type: Array of strings

A list of keys of the tags to remove from the resource.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

UpdateAgent

$result = $client->updateAgent([/* ... */]);
$promise = $client->updateAgentAsync([/* ... */]);

Updates the configuration of an agent.

Parameter Syntax

$result = $client->updateAgent([
    'agentId' => '<string>', // REQUIRED
    'agentName' => '<string>', // REQUIRED
    'agentResourceRoleArn' => '<string>', // REQUIRED
    'customerEncryptionKeyArn' => '<string>',
    'description' => '<string>',
    'foundationModel' => '<string>', // REQUIRED
    'guardrailConfiguration' => [
        'guardrailIdentifier' => '<string>',
        'guardrailVersion' => '<string>',
    ],
    'idleSessionTTLInSeconds' => <integer>,
    'instruction' => '<string>',
    'memoryConfiguration' => [
        'enabledMemoryTypes' => ['<string>', ...], // REQUIRED
        'storageDays' => <integer>,
    ],
    'promptOverrideConfiguration' => [
        'overrideLambda' => '<string>',
        'promptConfigurations' => [ // REQUIRED
            [
                'basePromptTemplate' => '<string>',
                'inferenceConfiguration' => [
                    'maximumLength' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
                'parserMode' => 'DEFAULT|OVERRIDDEN',
                'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                'promptState' => 'ENABLED|DISABLED',
                'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
            ],
            // ...
        ],
    ],
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

agentName
Required: Yes
Type: string

Specifies a new name for the agent.

agentResourceRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the agent.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent.

description
Type: string

Specifies a new description of the agent.

foundationModel
Required: Yes
Type: string

Specifies a new foundation model to be used for orchestration by the agent.

guardrailConfiguration
Type: GuardrailConfiguration structure

The unique Guardrail configuration assigned to the agent when it is updated.

idleSessionTTLInSeconds
Type: int

The number of seconds for which Amazon Bedrock keeps information about a user's conversation with the agent.

A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Bedrock deletes any data provided before the timeout.

instruction
Type: string

Specifies new instructions that tell the agent what it should do and how it should interact with users.

memoryConfiguration
Type: MemoryConfiguration structure

Specifies the new memory configuration for the agent.

promptOverrideConfiguration
Type: PromptOverrideConfiguration structure

Contains configurations to override prompts in different parts of an agent sequence. For more information, see Advanced prompts.

Result Syntax

[
    'agent' => [
        'agentArn' => '<string>',
        'agentId' => '<string>',
        'agentName' => '<string>',
        'agentResourceRoleArn' => '<string>',
        'agentStatus' => 'CREATING|PREPARING|PREPARED|NOT_PREPARED|DELETING|FAILED|VERSIONING|UPDATING',
        'agentVersion' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'customerEncryptionKeyArn' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'foundationModel' => '<string>',
        'guardrailConfiguration' => [
            'guardrailIdentifier' => '<string>',
            'guardrailVersion' => '<string>',
        ],
        'idleSessionTTLInSeconds' => <integer>,
        'instruction' => '<string>',
        'memoryConfiguration' => [
            'enabledMemoryTypes' => ['<string>', ...],
            'storageDays' => <integer>,
        ],
        'preparedAt' => <DateTime>,
        'promptOverrideConfiguration' => [
            'overrideLambda' => '<string>',
            'promptConfigurations' => [
                [
                    'basePromptTemplate' => '<string>',
                    'inferenceConfiguration' => [
                        'maximumLength' => <integer>,
                        'stopSequences' => ['<string>', ...],
                        'temperature' => <float>,
                        'topK' => <integer>,
                        'topP' => <float>,
                    ],
                    'parserMode' => 'DEFAULT|OVERRIDDEN',
                    'promptCreationMode' => 'DEFAULT|OVERRIDDEN',
                    'promptState' => 'ENABLED|DISABLED',
                    'promptType' => 'PRE_PROCESSING|ORCHESTRATION|POST_PROCESSING|KNOWLEDGE_BASE_RESPONSE_GENERATION',
                ],
                // ...
            ],
        ],
        'recommendedActions' => ['<string>', ...],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agent
Required: Yes
Type: Agent structure

Contains details about the agent that was updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UpdateAgentActionGroup

$result = $client->updateAgentActionGroup([/* ... */]);
$promise = $client->updateAgentActionGroupAsync([/* ... */]);

Updates the configuration for an action group for an agent.

Parameter Syntax

$result = $client->updateAgentActionGroup([
    'actionGroupExecutor' => [
        'customControl' => 'RETURN_CONTROL',
        'lambda' => '<string>',
    ],
    'actionGroupId' => '<string>', // REQUIRED
    'actionGroupName' => '<string>', // REQUIRED
    'actionGroupState' => 'ENABLED|DISABLED',
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'apiSchema' => [
        'payload' => '<string>',
        's3' => [
            's3BucketName' => '<string>',
            's3ObjectKey' => '<string>',
        ],
    ],
    'description' => '<string>',
    'functionSchema' => [
        'functions' => [
            [
                'description' => '<string>',
                'name' => '<string>', // REQUIRED
                'parameters' => [
                    '<Name>' => [
                        'description' => '<string>',
                        'required' => true || false,
                        'type' => 'string|number|integer|boolean|array', // REQUIRED
                    ],
                    // ...
                ],
            ],
            // ...
        ],
    ],
    'parentActionGroupSignature' => 'AMAZON.UserInput|AMAZON.CodeInterpreter',
]);

Parameter Details

Members
actionGroupExecutor
Type: ActionGroupExecutor structure

The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking the action.

actionGroupId
Required: Yes
Type: string

The unique identifier of the action group.

actionGroupName
Required: Yes
Type: string

Specifies a new name for the action group.

actionGroupState
Type: string

Specifies whether the action group is available for the agent to invoke or not when sending an InvokeAgent request.

agentId
Required: Yes
Type: string

The unique identifier of the agent for which to update the action group.

agentVersion
Required: Yes
Type: string

The unique identifier of the agent version for which to update the action group.

apiSchema
Type: APISchema structure

Contains either details about the S3 object containing the OpenAPI schema for the action group or the JSON or YAML-formatted payload defining the schema. For more information, see Action group OpenAPI schemas.

description
Type: string

Specifies a new name for the action group.

functionSchema
Type: FunctionSchema structure

Contains details about the function schema for the action group or the JSON or YAML-formatted payload defining the schema.

parentActionGroupSignature
Type: string

To allow your agent to request the user for additional information when trying to complete a task, set this field to AMAZON.UserInput. You must leave the description, apiSchema, and actionGroupExecutor fields blank for this action group.

During orchestration, if your agent determines that it needs to invoke an API in an action group, but doesn't have enough information to complete the API request, it will invoke this action group instead and return an Observation reprompting the user for more information.

Result Syntax

[
    'agentActionGroup' => [
        'actionGroupExecutor' => [
            'customControl' => 'RETURN_CONTROL',
            'lambda' => '<string>',
        ],
        'actionGroupId' => '<string>',
        'actionGroupName' => '<string>',
        'actionGroupState' => 'ENABLED|DISABLED',
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'apiSchema' => [
            'payload' => '<string>',
            's3' => [
                's3BucketName' => '<string>',
                's3ObjectKey' => '<string>',
            ],
        ],
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'functionSchema' => [
            'functions' => [
                [
                    'description' => '<string>',
                    'name' => '<string>',
                    'parameters' => [
                        '<Name>' => [
                            'description' => '<string>',
                            'required' => true || false,
                            'type' => 'string|number|integer|boolean|array',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
        ],
        'parentActionSignature' => 'AMAZON.UserInput|AMAZON.CodeInterpreter',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentActionGroup
Required: Yes
Type: AgentActionGroup structure

Contains details about the action group that was updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UpdateAgentAlias

$result = $client->updateAgentAlias([/* ... */]);
$promise = $client->updateAgentAliasAsync([/* ... */]);

Updates configurations for an alias of an agent.

Parameter Syntax

$result = $client->updateAgentAlias([
    'agentAliasId' => '<string>', // REQUIRED
    'agentAliasName' => '<string>', // REQUIRED
    'agentId' => '<string>', // REQUIRED
    'description' => '<string>',
    'routingConfiguration' => [
        [
            'agentVersion' => '<string>',
            'provisionedThroughput' => '<string>',
        ],
        // ...
    ],
]);

Parameter Details

Members
agentAliasId
Required: Yes
Type: string

The unique identifier of the alias.

agentAliasName
Required: Yes
Type: string

Specifies a new name for the alias.

agentId
Required: Yes
Type: string

The unique identifier of the agent.

description
Type: string

Specifies a new description for the alias.

routingConfiguration
Type: Array of AgentAliasRoutingConfigurationListItem structures

Contains details about the routing configuration of the alias.

Result Syntax

[
    'agentAlias' => [
        'agentAliasArn' => '<string>',
        'agentAliasHistoryEvents' => [
            [
                'endDate' => <DateTime>,
                'routingConfiguration' => [
                    [
                        'agentVersion' => '<string>',
                        'provisionedThroughput' => '<string>',
                    ],
                    // ...
                ],
                'startDate' => <DateTime>,
            ],
            // ...
        ],
        'agentAliasId' => '<string>',
        'agentAliasName' => '<string>',
        'agentAliasStatus' => 'CREATING|PREPARED|FAILED|UPDATING|DELETING',
        'agentId' => '<string>',
        'clientToken' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'routingConfiguration' => [
            [
                'agentVersion' => '<string>',
                'provisionedThroughput' => '<string>',
            ],
            // ...
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentAlias
Required: Yes
Type: AgentAlias structure

Contains details about the alias that was updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UpdateAgentKnowledgeBase

$result = $client->updateAgentKnowledgeBase([/* ... */]);
$promise = $client->updateAgentKnowledgeBaseAsync([/* ... */]);

Updates the configuration for a knowledge base that has been associated with an agent.

Parameter Syntax

$result = $client->updateAgentKnowledgeBase([
    'agentId' => '<string>', // REQUIRED
    'agentVersion' => '<string>', // REQUIRED
    'description' => '<string>',
    'knowledgeBaseId' => '<string>', // REQUIRED
    'knowledgeBaseState' => 'ENABLED|DISABLED',
]);

Parameter Details

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent associated with the knowledge base that you want to update.

agentVersion
Required: Yes
Type: string

The version of the agent associated with the knowledge base that you want to update.

description
Type: string

Specifies a new description for the knowledge base associated with an agent.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base that has been associated with an agent.

knowledgeBaseState
Type: string

Specifies whether the agent uses the knowledge base or not when sending an InvokeAgent request.

Result Syntax

[
    'agentKnowledgeBase' => [
        'agentId' => '<string>',
        'agentVersion' => '<string>',
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'knowledgeBaseId' => '<string>',
        'knowledgeBaseState' => 'ENABLED|DISABLED',
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
agentKnowledgeBase
Required: Yes
Type: AgentKnowledgeBase structure

Contains details about the knowledge base that has been associated with an agent.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

UpdateDataSource

$result = $client->updateDataSource([/* ... */]);
$promise = $client->updateDataSourceAsync([/* ... */]);

Updates the configurations for a data source connector.

You can't change the chunkingConfiguration after you create the data source connector. Specify the existing chunkingConfiguration.

Parameter Syntax

$result = $client->updateDataSource([
    'dataDeletionPolicy' => 'RETAIN|DELETE',
    'dataSourceConfiguration' => [ // REQUIRED
        'confluenceConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'BASIC|OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'hostType' => 'SAAS', // REQUIRED
                'hostUrl' => '<string>', // REQUIRED
            ],
        ],
        's3Configuration' => [
            'bucketArn' => '<string>', // REQUIRED
            'bucketOwnerAccountId' => '<string>',
            'inclusionPrefixes' => ['<string>', ...],
        ],
        'salesforceConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'hostUrl' => '<string>', // REQUIRED
            ],
        ],
        'sharePointConfiguration' => [
            'crawlerConfiguration' => [
                'filterConfiguration' => [
                    'patternObjectFilter' => [
                        'filters' => [ // REQUIRED
                            [
                                'exclusionFilters' => ['<string>', ...],
                                'inclusionFilters' => ['<string>', ...],
                                'objectType' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'type' => 'PATTERN', // REQUIRED
                ],
            ],
            'sourceConfiguration' => [ // REQUIRED
                'authType' => 'OAUTH2_CLIENT_CREDENTIALS', // REQUIRED
                'credentialsSecretArn' => '<string>', // REQUIRED
                'domain' => '<string>', // REQUIRED
                'hostType' => 'ONLINE', // REQUIRED
                'siteUrls' => ['<string>', ...], // REQUIRED
                'tenantId' => '<string>',
            ],
        ],
        'type' => 'S3|WEB|CONFLUENCE|SALESFORCE|SHAREPOINT', // REQUIRED
        'webConfiguration' => [
            'crawlerConfiguration' => [
                'crawlerLimits' => [
                    'rateLimit' => <integer>,
                ],
                'exclusionFilters' => ['<string>', ...],
                'inclusionFilters' => ['<string>', ...],
                'scope' => 'HOST_ONLY|SUBDOMAINS',
            ],
            'sourceConfiguration' => [ // REQUIRED
                'urlConfiguration' => [ // REQUIRED
                    'seedUrls' => [
                        [
                            'url' => '<string>',
                        ],
                        // ...
                    ],
                ],
            ],
        ],
    ],
    'dataSourceId' => '<string>', // REQUIRED
    'description' => '<string>',
    'knowledgeBaseId' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'serverSideEncryptionConfiguration' => [
        'kmsKeyArn' => '<string>',
    ],
    'vectorIngestionConfiguration' => [
        'chunkingConfiguration' => [
            'chunkingStrategy' => 'FIXED_SIZE|NONE|HIERARCHICAL|SEMANTIC', // REQUIRED
            'fixedSizeChunkingConfiguration' => [
                'maxTokens' => <integer>, // REQUIRED
                'overlapPercentage' => <integer>, // REQUIRED
            ],
            'hierarchicalChunkingConfiguration' => [
                'levelConfigurations' => [ // REQUIRED
                    [
                        'maxTokens' => <integer>, // REQUIRED
                    ],
                    // ...
                ],
                'overlapTokens' => <integer>, // REQUIRED
            ],
            'semanticChunkingConfiguration' => [
                'breakpointPercentileThreshold' => <integer>, // REQUIRED
                'bufferSize' => <integer>, // REQUIRED
                'maxTokens' => <integer>, // REQUIRED
            ],
        ],
        'customTransformationConfiguration' => [
            'intermediateStorage' => [ // REQUIRED
                's3Location' => [ // REQUIRED
                    'uri' => '<string>', // REQUIRED
                ],
            ],
            'transformations' => [ // REQUIRED
                [
                    'stepToApply' => 'POST_CHUNKING', // REQUIRED
                    'transformationFunction' => [ // REQUIRED
                        'transformationLambdaConfiguration' => [ // REQUIRED
                            'lambdaArn' => '<string>', // REQUIRED
                        ],
                    ],
                ],
                // ...
            ],
        ],
        'parsingConfiguration' => [
            'bedrockFoundationModelConfiguration' => [
                'modelArn' => '<string>', // REQUIRED
                'parsingPrompt' => [
                    'parsingPromptText' => '<string>', // REQUIRED
                ],
            ],
            'parsingStrategy' => 'BEDROCK_FOUNDATION_MODEL', // REQUIRED
        ],
    ],
]);

Parameter Details

Members
dataDeletionPolicy
Type: string

The data deletion policy for the data source that you want to update.

dataSourceConfiguration
Required: Yes
Type: DataSourceConfiguration structure

The connection configuration for the data source that you want to update.

dataSourceId
Required: Yes
Type: string

The unique identifier of the data source.

description
Type: string

Specifies a new description for the data source.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base for the data source.

name
Required: Yes
Type: string

Specifies a new name for the data source.

serverSideEncryptionConfiguration

Contains details about server-side encryption of the data source.

vectorIngestionConfiguration

Contains details about how to ingest the documents in the data source.

Result Syntax

[
    'dataSource' => [
        'createdAt' => <DateTime>,
        'dataDeletionPolicy' => 'RETAIN|DELETE',
        'dataSourceConfiguration' => [
            'confluenceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'BASIC|OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostType' => 'SAAS',
                    'hostUrl' => '<string>',
                ],
            ],
            's3Configuration' => [
                'bucketArn' => '<string>',
                'bucketOwnerAccountId' => '<string>',
                'inclusionPrefixes' => ['<string>', ...],
            ],
            'salesforceConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'hostUrl' => '<string>',
                ],
            ],
            'sharePointConfiguration' => [
                'crawlerConfiguration' => [
                    'filterConfiguration' => [
                        'patternObjectFilter' => [
                            'filters' => [
                                [
                                    'exclusionFilters' => ['<string>', ...],
                                    'inclusionFilters' => ['<string>', ...],
                                    'objectType' => '<string>',
                                ],
                                // ...
                            ],
                        ],
                        'type' => 'PATTERN',
                    ],
                ],
                'sourceConfiguration' => [
                    'authType' => 'OAUTH2_CLIENT_CREDENTIALS',
                    'credentialsSecretArn' => '<string>',
                    'domain' => '<string>',
                    'hostType' => 'ONLINE',
                    'siteUrls' => ['<string>', ...],
                    'tenantId' => '<string>',
                ],
            ],
            'type' => 'S3|WEB|CONFLUENCE|SALESFORCE|SHAREPOINT',
            'webConfiguration' => [
                'crawlerConfiguration' => [
                    'crawlerLimits' => [
                        'rateLimit' => <integer>,
                    ],
                    'exclusionFilters' => ['<string>', ...],
                    'inclusionFilters' => ['<string>', ...],
                    'scope' => 'HOST_ONLY|SUBDOMAINS',
                ],
                'sourceConfiguration' => [
                    'urlConfiguration' => [
                        'seedUrls' => [
                            [
                                'url' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                ],
            ],
        ],
        'dataSourceId' => '<string>',
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'serverSideEncryptionConfiguration' => [
            'kmsKeyArn' => '<string>',
        ],
        'status' => 'AVAILABLE|DELETING|DELETE_UNSUCCESSFUL',
        'updatedAt' => <DateTime>,
        'vectorIngestionConfiguration' => [
            'chunkingConfiguration' => [
                'chunkingStrategy' => 'FIXED_SIZE|NONE|HIERARCHICAL|SEMANTIC',
                'fixedSizeChunkingConfiguration' => [
                    'maxTokens' => <integer>,
                    'overlapPercentage' => <integer>,
                ],
                'hierarchicalChunkingConfiguration' => [
                    'levelConfigurations' => [
                        [
                            'maxTokens' => <integer>,
                        ],
                        // ...
                    ],
                    'overlapTokens' => <integer>,
                ],
                'semanticChunkingConfiguration' => [
                    'breakpointPercentileThreshold' => <integer>,
                    'bufferSize' => <integer>,
                    'maxTokens' => <integer>,
                ],
            ],
            'customTransformationConfiguration' => [
                'intermediateStorage' => [
                    's3Location' => [
                        'uri' => '<string>',
                    ],
                ],
                'transformations' => [
                    [
                        'stepToApply' => 'POST_CHUNKING',
                        'transformationFunction' => [
                            'transformationLambdaConfiguration' => [
                                'lambdaArn' => '<string>',
                            ],
                        ],
                    ],
                    // ...
                ],
            ],
            'parsingConfiguration' => [
                'bedrockFoundationModelConfiguration' => [
                    'modelArn' => '<string>',
                    'parsingPrompt' => [
                        'parsingPromptText' => '<string>',
                    ],
                ],
                'parsingStrategy' => 'BEDROCK_FOUNDATION_MODEL',
            ],
        ],
    ],
]

Result Details

Members
dataSource
Required: Yes
Type: DataSource structure

Contains details about the data source.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

UpdateFlow

$result = $client->updateFlow([/* ... */]);
$promise = $client->updateFlowAsync([/* ... */]);

Modifies a flow. Include both fields that you want to keep and fields that you want to change. For more information, see How it works and Create a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->updateFlow([
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>', // REQUIRED
                    ],
                    'data' => [
                        'sourceOutput' => '<string>', // REQUIRED
                        'targetInput' => '<string>', // REQUIRED
                    ],
                ],
                'name' => '<string>', // REQUIRED
                'source' => '<string>', // REQUIRED
                'target' => '<string>', // REQUIRED
                'type' => 'Data|Conditional', // REQUIRED
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>', // REQUIRED
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [ // REQUIRED
                            [
                                'expression' => '<string>',
                                'name' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>', // REQUIRED
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>', // REQUIRED
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>', // REQUIRED
                        'localeId' => '<string>', // REQUIRED
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [ // REQUIRED
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>', // REQUIRED
                                'templateConfiguration' => [ // REQUIRED
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>', // REQUIRED
                                    ],
                                ],
                                'templateType' => 'TEXT', // REQUIRED
                            ],
                            'resource' => [
                                'promptArn' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [ // REQUIRED
                            's3' => [
                                'bucketName' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [ // REQUIRED
                            's3' => [
                                'bucketName' => '<string>', // REQUIRED
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>', // REQUIRED
                        'name' => '<string>', // REQUIRED
                        'type' => 'String|Number|Boolean|Object|Array', // REQUIRED
                    ],
                    // ...
                ],
                'name' => '<string>', // REQUIRED
                'outputs' => [
                    [
                        'name' => '<string>', // REQUIRED
                        'type' => 'String|Number|Boolean|Object|Array', // REQUIRED
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector', // REQUIRED
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>', // REQUIRED
    'flowIdentifier' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
]);

Parameter Details

Members
customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the flow.

definition
Type: FlowDefinition structure

A definition of the nodes and the connections between the nodes in the flow.

description
Type: string

A description for the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create and manage a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

A name for the flow.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'definition' => [
        'connections' => [
            [
                'configuration' => [
                    'conditional' => [
                        'condition' => '<string>',
                    ],
                    'data' => [
                        'sourceOutput' => '<string>',
                        'targetInput' => '<string>',
                    ],
                ],
                'name' => '<string>',
                'source' => '<string>',
                'target' => '<string>',
                'type' => 'Data|Conditional',
            ],
            // ...
        ],
        'nodes' => [
            [
                'configuration' => [
                    'agent' => [
                        'agentAliasArn' => '<string>',
                    ],
                    'collector' => [
                    ],
                    'condition' => [
                        'conditions' => [
                            [
                                'expression' => '<string>',
                                'name' => '<string>',
                            ],
                            // ...
                        ],
                    ],
                    'input' => [
                    ],
                    'iterator' => [
                    ],
                    'knowledgeBase' => [
                        'knowledgeBaseId' => '<string>',
                        'modelId' => '<string>',
                    ],
                    'lambdaFunction' => [
                        'lambdaArn' => '<string>',
                    ],
                    'lex' => [
                        'botAliasArn' => '<string>',
                        'localeId' => '<string>',
                    ],
                    'output' => [
                    ],
                    'prompt' => [
                        'sourceConfiguration' => [
                            'inline' => [
                                'inferenceConfiguration' => [
                                    'text' => [
                                        'maxTokens' => <integer>,
                                        'stopSequences' => ['<string>', ...],
                                        'temperature' => <float>,
                                        'topK' => <integer>,
                                        'topP' => <float>,
                                    ],
                                ],
                                'modelId' => '<string>',
                                'templateConfiguration' => [
                                    'text' => [
                                        'inputVariables' => [
                                            [
                                                'name' => '<string>',
                                            ],
                                            // ...
                                        ],
                                        'text' => '<string>',
                                    ],
                                ],
                                'templateType' => 'TEXT',
                            ],
                            'resource' => [
                                'promptArn' => '<string>',
                            ],
                        ],
                    ],
                    'retrieval' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                    'storage' => [
                        'serviceConfiguration' => [
                            's3' => [
                                'bucketName' => '<string>',
                            ],
                        ],
                    ],
                ],
                'inputs' => [
                    [
                        'expression' => '<string>',
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'name' => '<string>',
                'outputs' => [
                    [
                        'name' => '<string>',
                        'type' => 'String|Number|Boolean|Object|Array',
                    ],
                    // ...
                ],
                'type' => 'Input|Output|KnowledgeBase|Condition|Lex|Prompt|LambdaFunction|Storage|Agent|Retrieval|Iterator|Collector',
            ],
            // ...
        ],
    ],
    'description' => '<string>',
    'executionRoleArn' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'status' => 'Failed|Prepared|Preparing|NotPrepared',
    'updatedAt' => <DateTime>,
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that the flow was encrypted with.

definition
Type: FlowDefinition structure

A definition of the nodes and the connections between nodes in the flow.

description
Type: string

The description of the flow.

executionRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the service role with permissions to create a flow. For more information, see Create a service role for flows in Amazon Bedrock in the Amazon Bedrock User Guide.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow.

status
Required: Yes
Type: string

The status of the flow. When you submit this request, the status will be NotPrepared. If updating fails, the status becomes Failed.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was last updated.

version
Required: Yes
Type: string

The version of the flow. When you update a flow, the version updated is the DRAFT version.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UpdateFlowAlias

$result = $client->updateFlowAlias([/* ... */]);
$promise = $client->updateFlowAliasAsync([/* ... */]);

Modifies the alias of a flow. Include both fields that you want to keep and ones that you want to change. For more information, see Deploy a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->updateFlowAlias([
    'aliasIdentifier' => '<string>', // REQUIRED
    'description' => '<string>',
    'flowIdentifier' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'routingConfiguration' => [ // REQUIRED
        [
            'flowVersion' => '<string>',
        ],
        // ...
    ],
]);

Parameter Details

Members
aliasIdentifier
Required: Yes
Type: string

The unique identifier of the alias.

description
Type: string

A description for the flow alias.

flowIdentifier
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

Contains information about the version to which to map the alias.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'description' => '<string>',
    'flowId' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'routingConfiguration' => [
        [
            'flowVersion' => '<string>',
        ],
        // ...
    ],
    'updatedAt' => <DateTime>,
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

description
Type: string

The description of the flow.

flowId
Required: Yes
Type: string

The unique identifier of the flow.

id
Required: Yes
Type: string

The unique identifier of the alias.

name
Required: Yes
Type: string

The name of the flow alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

Contains information about the version that the alias is mapped to.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow alias was last updated.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

UpdateKnowledgeBase

$result = $client->updateKnowledgeBase([/* ... */]);
$promise = $client->updateKnowledgeBaseAsync([/* ... */]);

Updates the configuration of a knowledge base with the fields that you specify. Because all fields will be overwritten, you must include the same values for fields that you want to keep the same.

You can change the following fields:

  • name

  • description

  • roleArn

You can't change the knowledgeBaseConfiguration or storageConfiguration fields, so you must specify the same configurations as when you created the knowledge base. You can send a GetKnowledgeBase request and copy the same configurations.

Parameter Syntax

$result = $client->updateKnowledgeBase([
    'description' => '<string>',
    'knowledgeBaseConfiguration' => [ // REQUIRED
        'type' => 'VECTOR', // REQUIRED
        'vectorKnowledgeBaseConfiguration' => [
            'embeddingModelArn' => '<string>', // REQUIRED
            'embeddingModelConfiguration' => [
                'bedrockEmbeddingModelConfiguration' => [
                    'dimensions' => <integer>,
                ],
            ],
        ],
    ],
    'knowledgeBaseId' => '<string>', // REQUIRED
    'name' => '<string>', // REQUIRED
    'roleArn' => '<string>', // REQUIRED
    'storageConfiguration' => [ // REQUIRED
        'mongoDbAtlasConfiguration' => [
            'collectionName' => '<string>', // REQUIRED
            'credentialsSecretArn' => '<string>', // REQUIRED
            'databaseName' => '<string>', // REQUIRED
            'endpoint' => '<string>', // REQUIRED
            'endpointServiceName' => '<string>',
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'opensearchServerlessConfiguration' => [
            'collectionArn' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'pineconeConfiguration' => [
            'connectionString' => '<string>', // REQUIRED
            'credentialsSecretArn' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
            ],
            'namespace' => '<string>',
        ],
        'rdsConfiguration' => [
            'credentialsSecretArn' => '<string>', // REQUIRED
            'databaseName' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'primaryKeyField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'resourceArn' => '<string>', // REQUIRED
            'tableName' => '<string>', // REQUIRED
        ],
        'redisEnterpriseCloudConfiguration' => [
            'credentialsSecretArn' => '<string>', // REQUIRED
            'endpoint' => '<string>', // REQUIRED
            'fieldMapping' => [ // REQUIRED
                'metadataField' => '<string>', // REQUIRED
                'textField' => '<string>', // REQUIRED
                'vectorField' => '<string>', // REQUIRED
            ],
            'vectorIndexName' => '<string>', // REQUIRED
        ],
        'type' => 'OPENSEARCH_SERVERLESS|PINECONE|REDIS_ENTERPRISE_CLOUD|RDS|MONGO_DB_ATLAS', // REQUIRED
    ],
]);

Parameter Details

Members
description
Type: string

Specifies a new description for the knowledge base.

knowledgeBaseConfiguration
Required: Yes
Type: KnowledgeBaseConfiguration structure

Specifies the configuration for the embeddings model used for the knowledge base. You must use the same configuration as when the knowledge base was created.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to update.

name
Required: Yes
Type: string

Specifies a new name for the knowledge base.

roleArn
Required: Yes
Type: string

Specifies a different Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the knowledge base.

storageConfiguration
Required: Yes
Type: StorageConfiguration structure

Specifies the configuration for the vector store used for the knowledge base. You must use the same configuration as when the knowledge base was created.

Result Syntax

[
    'knowledgeBase' => [
        'createdAt' => <DateTime>,
        'description' => '<string>',
        'failureReasons' => ['<string>', ...],
        'knowledgeBaseArn' => '<string>',
        'knowledgeBaseConfiguration' => [
            'type' => 'VECTOR',
            'vectorKnowledgeBaseConfiguration' => [
                'embeddingModelArn' => '<string>',
                'embeddingModelConfiguration' => [
                    'bedrockEmbeddingModelConfiguration' => [
                        'dimensions' => <integer>,
                    ],
                ],
            ],
        ],
        'knowledgeBaseId' => '<string>',
        'name' => '<string>',
        'roleArn' => '<string>',
        'status' => 'CREATING|ACTIVE|DELETING|UPDATING|FAILED|DELETE_UNSUCCESSFUL',
        'storageConfiguration' => [
            'mongoDbAtlasConfiguration' => [
                'collectionName' => '<string>',
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'endpoint' => '<string>',
                'endpointServiceName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'opensearchServerlessConfiguration' => [
                'collectionArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'pineconeConfiguration' => [
                'connectionString' => '<string>',
                'credentialsSecretArn' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                ],
                'namespace' => '<string>',
            ],
            'rdsConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'databaseName' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'primaryKeyField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'resourceArn' => '<string>',
                'tableName' => '<string>',
            ],
            'redisEnterpriseCloudConfiguration' => [
                'credentialsSecretArn' => '<string>',
                'endpoint' => '<string>',
                'fieldMapping' => [
                    'metadataField' => '<string>',
                    'textField' => '<string>',
                    'vectorField' => '<string>',
                ],
                'vectorIndexName' => '<string>',
            ],
            'type' => 'OPENSEARCH_SERVERLESS|PINECONE|REDIS_ENTERPRISE_CLOUD|RDS|MONGO_DB_ATLAS',
        ],
        'updatedAt' => <DateTime>,
    ],
]

Result Details

Members
knowledgeBase
Required: Yes
Type: KnowledgeBase structure

Contains details about the knowledge base.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

UpdatePrompt

$result = $client->updatePrompt([/* ... */]);
$promise = $client->updatePromptAsync([/* ... */]);

Modifies a prompt in your prompt library. Include both fields that you want to keep and fields that you want to replace. For more information, see Prompt management in Amazon Bedrock and Edit prompts in your prompt library in the Amazon Bedrock User Guide.

Parameter Syntax

$result = $client->updatePrompt([
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'name' => '<string>', // REQUIRED
    'promptIdentifier' => '<string>', // REQUIRED
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>', // REQUIRED
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>', // REQUIRED
                ],
            ],
            'templateType' => 'TEXT', // REQUIRED
        ],
        // ...
    ],
]);

Parameter Details

Members
customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt.

defaultVariant
Type: string

The name of the default variant for the prompt. This value must match the name field in the relevant PromptVariant object.

description
Type: string

A description for the prompt.

name
Required: Yes
Type: string

A name for the prompt.

promptIdentifier
Required: Yes
Type: string

The unique identifier of the prompt.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

Result Syntax

[
    'arn' => '<string>',
    'createdAt' => <DateTime>,
    'customerEncryptionKeyArn' => '<string>',
    'defaultVariant' => '<string>',
    'description' => '<string>',
    'id' => '<string>',
    'name' => '<string>',
    'updatedAt' => <DateTime>,
    'variants' => [
        [
            'inferenceConfiguration' => [
                'text' => [
                    'maxTokens' => <integer>,
                    'stopSequences' => ['<string>', ...],
                    'temperature' => <float>,
                    'topK' => <integer>,
                    'topP' => <float>,
                ],
            ],
            'modelId' => '<string>',
            'name' => '<string>',
            'templateConfiguration' => [
                'text' => [
                    'inputVariables' => [
                        [
                            'name' => '<string>',
                        ],
                        // ...
                    ],
                    'text' => '<string>',
                ],
            ],
            'templateType' => 'TEXT',
        ],
        // ...
    ],
    'version' => '<string>',
]

Result Details

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the prompt.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt.

defaultVariant
Type: string

The name of the default variant for the prompt. This value must match the name field in the relevant PromptVariant object.

description
Type: string

The description of the prompt.

id
Required: Yes
Type: string

The unique identifier of the prompt.

name
Required: Yes
Type: string

The name of the prompt.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was last updated.

variants
Type: Array of PromptVariant structures

A list of objects, each containing details about a variant of the prompt.

version
Required: Yes
Type: string

The version of the prompt. When you update a prompt, the version updated is the DRAFT version.

Errors

ThrottlingException:

The number of requests exceeds the limit. Resubmit your request later.

AccessDeniedException:

The request is denied because of missing access permissions.

ValidationException:

Input validation failed. Check your request parameters and retry the request.

InternalServerException:

An internal server error occurred. Retry your request.

ResourceNotFoundException:

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

ConflictException:

There was a conflict performing an operation.

ServiceQuotaExceededException:

The number of requests exceeds the service quota. Resubmit your request later.

Shapes

APISchema

Description

Contains details about the OpenAPI schema for the action group. For more information, see Action group OpenAPI schemas. You can either include the schema directly in the payload field or you can upload it to an S3 bucket and specify the S3 bucket location in the s3 field.

Members
payload
Type: string

The JSON or YAML-formatted payload defining the OpenAPI schema for the action group. For more information, see Action group OpenAPI schemas.

s3
Type: S3Identifier structure

Contains details about the S3 object containing the OpenAPI schema for the action group. For more information, see Action group OpenAPI schemas.

AccessDeniedException

Description

The request is denied because of missing access permissions.

Members
message
Type: string

ActionGroupExecutor

Description

Contains details about the Lambda function containing the business logic that is carried out upon invoking the action or the custom control method for handling the information elicited from the user.

Members
customControl
Type: string

To return the action group invocation results directly in the InvokeAgent response, specify RETURN_CONTROL.

lambda
Type: string

The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking the action.

ActionGroupSummary

Description

Contains details about an action group.

Members
actionGroupId
Required: Yes
Type: string

The unique identifier of the action group.

actionGroupName
Required: Yes
Type: string

The name of the action group.

actionGroupState
Required: Yes
Type: string

Specifies whether the action group is available for the agent to invoke or not when sending an InvokeAgent request.

description
Type: string

The description of the action group.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the action group was last updated.

Agent

Description

Contains details about an agent.

Members
agentArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the agent.

agentId
Required: Yes
Type: string

The unique identifier of the agent.

agentName
Required: Yes
Type: string

The name of the agent.

agentResourceRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the agent.

agentStatus
Required: Yes
Type: string

The status of the agent and whether it is ready for use. The following statuses are possible:

  • CREATING – The agent is being created.

  • PREPARING – The agent is being prepared.

  • PREPARED – The agent is prepared and ready to be invoked.

  • NOT_PREPARED – The agent has been created but not yet prepared.

  • FAILED – The agent API operation failed.

  • UPDATING – The agent is being updated.

  • DELETING – The agent is being deleted.

agentVersion
Required: Yes
Type: string

The version of the agent.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the agent was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that encrypts the agent.

description
Type: string

The description of the agent.

failureReasons
Type: Array of strings

Contains reasons that the agent-related API that you invoked failed.

foundationModel
Type: string

The foundation model used for orchestration by the agent.

guardrailConfiguration
Type: GuardrailConfiguration structure

Details about the guardrail associated with the agent.

idleSessionTTLInSeconds
Required: Yes
Type: int

The number of seconds for which Amazon Bedrock keeps information about a user's conversation with the agent.

A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Bedrock deletes any data provided before the timeout.

instruction
Type: string

Instructions that tell the agent what it should do and how it should interact with users.

memoryConfiguration
Type: MemoryConfiguration structure

Contains memory configuration for the agent.

preparedAt
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the agent was last prepared.

promptOverrideConfiguration
Type: PromptOverrideConfiguration structure

Contains configurations to override prompt templates in different parts of an agent sequence. For more information, see Advanced prompts.

recommendedActions
Type: Array of strings

Contains recommended actions to take for the agent-related API that you invoked to succeed.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the agent was last updated.

AgentActionGroup

Description

Contains details about an action group.

Members
actionGroupExecutor
Type: ActionGroupExecutor structure

The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking the action or the custom control method for handling the information elicited from the user.

actionGroupId
Required: Yes
Type: string

The unique identifier of the action group.

actionGroupName
Required: Yes
Type: string

The name of the action group.

actionGroupState
Required: Yes
Type: string

Specifies whether the action group is available for the agent to invoke or not when sending an InvokeAgent request.

agentId
Required: Yes
Type: string

The unique identifier of the agent to which the action group belongs.

agentVersion
Required: Yes
Type: string

The version of the agent to which the action group belongs.

apiSchema
Type: APISchema structure

Contains either details about the S3 object containing the OpenAPI schema for the action group or the JSON or YAML-formatted payload defining the schema. For more information, see Action group OpenAPI schemas.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the action group was created.

description
Type: string

The description of the action group.

functionSchema
Type: FunctionSchema structure

Defines functions that each define parameters that the agent needs to invoke from the user. Each function represents an action in an action group.

parentActionSignature
Type: string

If this field is set as AMAZON.UserInput, the agent can request the user for additional information when trying to complete a task. The description, apiSchema, and actionGroupExecutor fields must be blank for this action group.

During orchestration, if the agent determines that it needs to invoke an API in an action group, but doesn't have enough information to complete the API request, it will invoke this action group instead and return an Observation reprompting the user for more information.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the action group was last updated.

AgentAlias

Description

Contains details about an alias of an agent.

Members
agentAliasArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the alias of the agent.

agentAliasHistoryEvents
Type: Array of AgentAliasHistoryEvent structures

Contains details about the history of the alias.

agentAliasId
Required: Yes
Type: string

The unique identifier of the alias of the agent.

agentAliasName
Required: Yes
Type: string

The name of the alias of the agent.

agentAliasStatus
Required: Yes
Type: string

The status of the alias of the agent and whether it is ready for use. The following statuses are possible:

  • CREATING – The agent alias is being created.

  • PREPARED – The agent alias is finished being created or updated and is ready to be invoked.

  • FAILED – The agent alias API operation failed.

  • UPDATING – The agent alias is being updated.

  • DELETING – The agent alias is being deleted.

agentId
Required: Yes
Type: string

The unique identifier of the agent.

clientToken
Type: string

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias of the agent was created.

description
Type: string

The description of the alias of the agent.

failureReasons
Type: Array of strings

Information on the failure of Provisioned Throughput assigned to an agent alias.

routingConfiguration
Required: Yes
Type: Array of AgentAliasRoutingConfigurationListItem structures

Contains details about the routing configuration of the alias.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias was last updated.

AgentAliasHistoryEvent

Description

Contains details about the history of the alias.

Members
endDate
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date that the alias stopped being associated to the version in the routingConfiguration object

routingConfiguration
Type: Array of AgentAliasRoutingConfigurationListItem structures

Contains details about the version of the agent with which the alias is associated.

startDate
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date that the alias began being associated to the version in the routingConfiguration object.

AgentAliasRoutingConfigurationListItem

Description

Contains details about the routing configuration of the alias.

Members
agentVersion
Type: string

The version of the agent with which the alias is associated.

provisionedThroughput
Type: string

Information on the Provisioned Throughput assigned to an agent alias.

AgentAliasSummary

Description

Contains details about an alias of an agent.

Members
agentAliasId
Required: Yes
Type: string

Contains details about

agentAliasName
Required: Yes
Type: string

The name of the alias.

agentAliasStatus
Required: Yes
Type: string

The status of the alias.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias of the agent was created.

description
Type: string

The description of the alias.

routingConfiguration
Type: Array of AgentAliasRoutingConfigurationListItem structures

Contains details about the version of the agent with which the alias is associated.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias was last updated.

AgentFlowNodeConfiguration

Description

Defines an agent node in your flow. You specify the agent to invoke at this point in the flow. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
agentAliasArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the alias of the agent to invoke.

AgentKnowledgeBase

Description

Contains details about a knowledge base that is associated with an agent.

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent with which the knowledge base is associated.

agentVersion
Required: Yes
Type: string

The version of the agent with which the knowledge base is associated.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the association between the agent and the knowledge base was created.

description
Required: Yes
Type: string

The description of the association between the agent and the knowledge base.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the association between the agent and the knowledge base.

knowledgeBaseState
Required: Yes
Type: string

Specifies whether to use the knowledge base or not when sending an InvokeAgent request.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the association between the agent and the knowledge base was last updated.

AgentKnowledgeBaseSummary

Description

Contains details about a knowledge base associated with an agent.

Members
description
Type: string

The description of the knowledge base associated with an agent.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base associated with an agent.

knowledgeBaseState
Required: Yes
Type: string

Specifies whether the agent uses the knowledge base or not when sending an InvokeAgent request.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the knowledge base associated with an agent was last updated.

AgentSummary

Description

Contains details about an agent.

Members
agentId
Required: Yes
Type: string

The unique identifier of the agent.

agentName
Required: Yes
Type: string

The name of the agent.

agentStatus
Required: Yes
Type: string

The status of the agent.

description
Type: string

The description of the agent.

guardrailConfiguration
Type: GuardrailConfiguration structure

Details about the guardrail associated with the agent.

latestAgentVersion
Type: string

The latest version of the agent.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the agent was last updated.

AgentVersion

Description

Contains details about a version of an agent.

Members
agentArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the agent that the version belongs to.

agentId
Required: Yes
Type: string

The unique identifier of the agent that the version belongs to.

agentName
Required: Yes
Type: string

The name of the agent that the version belongs to.

agentResourceRoleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the agent.

agentStatus
Required: Yes
Type: string

The status of the agent that the version belongs to.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the version was created.

customerEncryptionKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key that encrypts the agent.

description
Type: string

The description of the version.

failureReasons
Type: Array of strings

A list of reasons that the API operation on the version failed.

foundationModel
Type: string

The foundation model that the version invokes.

guardrailConfiguration
Type: GuardrailConfiguration structure

Details about the guardrail associated with the agent.

idleSessionTTLInSeconds
Required: Yes
Type: int

The number of seconds for which Amazon Bedrock keeps information about a user's conversation with the agent.

A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Bedrock deletes any data provided before the timeout.

instruction
Type: string

The instructions provided to the agent.

memoryConfiguration
Type: MemoryConfiguration structure

Contains details of the memory configuration on the version of the agent.

promptOverrideConfiguration
Type: PromptOverrideConfiguration structure

Contains configurations to override prompt templates in different parts of an agent sequence. For more information, see Advanced prompts.

recommendedActions
Type: Array of strings

A list of recommended actions to take for the failed API operation on the version to succeed.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the version was last updated.

version
Required: Yes
Type: string

The version number.

AgentVersionSummary

Description

Contains details about a version of an agent.

Members
agentName
Required: Yes
Type: string

The name of the agent to which the version belongs.

agentStatus
Required: Yes
Type: string

The status of the agent to which the version belongs.

agentVersion
Required: Yes
Type: string

The version of the agent.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the version was created.

description
Type: string

The description of the version of the agent.

guardrailConfiguration
Type: GuardrailConfiguration structure

Details about the guardrail associated with the agent.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the version was last updated.

BedrockEmbeddingModelConfiguration

Description

The vector configuration details for the Bedrock embeddings model.

Members
dimensions
Type: int

The dimensions details for the vector configuration used on the Bedrock embeddings model.

BedrockFoundationModelConfiguration

Description

Settings for a foundation model used to parse documents for a data source.

Members
modelArn
Required: Yes
Type: string

The model's ARN.

parsingPrompt
Type: ParsingPrompt structure

Instructions for interpreting the contents of a document.

ChunkingConfiguration

Description

Details about how to chunk the documents in the data source. A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried.

Members
chunkingStrategy
Required: Yes
Type: string

Knowledge base can split your source data into chunks. A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried. You have the following options for chunking your data. If you opt for NONE, then you may want to pre-process your files by splitting them up such that each file corresponds to a chunk.

  • FIXED_SIZE – Amazon Bedrock splits your source data into chunks of the approximate size that you set in the fixedSizeChunkingConfiguration.

  • HIERARCHICAL – Split documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.

  • SEMANTIC – Split documents into chunks based on groups of similar content derived with natural language processing.

  • NONE – Amazon Bedrock treats each file as one chunk. If you choose this option, you may want to pre-process your documents by splitting them into separate files.

fixedSizeChunkingConfiguration

Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy as NONE, exclude this field.

hierarchicalChunkingConfiguration

Settings for hierarchical document chunking for a data source. Hierarchical chunking splits documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.

semanticChunkingConfiguration

Settings for semantic document chunking for a data source. Semantic chunking splits a document into into smaller documents based on groups of similar content derived from the text with natural language processing.

CollectorFlowNodeConfiguration

Description

Defines a collector node in your flow. This node takes an iteration of inputs and consolidates them into an array in the output. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members

ConditionFlowNodeConfiguration

Description

Defines a condition node in your flow. You can specify conditions that determine which node comes next in the flow. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
conditions
Required: Yes
Type: Array of FlowCondition structures

An array of conditions. Each member contains the name of a condition and an expression that defines the condition.

ConflictException

Description

There was a conflict performing an operation.

Members
message
Type: string

ConfluenceCrawlerConfiguration

Description

The configuration of the Confluence content. For example, configuring specific types of Confluence content.

Members
filterConfiguration
Type: CrawlFilterConfiguration structure

The configuration of filtering the Confluence content. For example, configuring regular expression patterns to include or exclude certain content.

ConfluenceDataSourceConfiguration

Description

The configuration information to connect to Confluence as your data source.

Members
crawlerConfiguration

The configuration of the Confluence content. For example, configuring specific types of Confluence content.

sourceConfiguration
Required: Yes
Type: ConfluenceSourceConfiguration structure

The endpoint information to connect to your Confluence data source.

ConfluenceSourceConfiguration

Description

The endpoint information to connect to your Confluence data source.

Members
authType
Required: Yes
Type: string

The supported authentication type to authenticate and connect to your Confluence instance.

credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name of an Secrets Manager secret that stores your authentication credentials for your SharePoint site/sites. For more information on the key-value pairs that must be included in your secret, depending on your authentication type, see Confluence connection configuration.

hostType
Required: Yes
Type: string

The supported host type, whether online/cloud or server/on-premises.

hostUrl
Required: Yes
Type: string

The Confluence host URL or instance URL.

CrawlFilterConfiguration

Description

The configuration of filtering the data source content. For example, configuring regular expression patterns to include or exclude certain content.

Members
patternObjectFilter

The configuration of filtering certain objects or content types of the data source.

type
Required: Yes
Type: string

The type of filtering that you want to apply to certain objects or content of the data source. For example, the PATTERN type is regular expression patterns you can apply to filter your content.

CustomTransformationConfiguration

Description

Settings for customizing steps in the data source content ingestion pipeline.

You can configure the data source to process documents with a Lambda function after they are parsed and converted into chunks. When you add a post-chunking transformation, the service stores chunked documents in an S3 bucket and invokes a Lambda function to process them.

To process chunked documents with a Lambda function, define an S3 bucket path for input and output objects, and a transformation that specifies the Lambda function to invoke. You can use the Lambda function to customize how chunks are split, and the metadata for each chunk.

Members
intermediateStorage
Required: Yes
Type: IntermediateStorage structure

An S3 bucket path for input and output objects.

transformations
Required: Yes
Type: Array of Transformation structures

A Lambda function that processes documents.

DataSource

Description

Contains details about a data source.

Members
createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the data source was created.

dataDeletionPolicy
Type: string

The data deletion policy for the data source.

dataSourceConfiguration
Required: Yes
Type: DataSourceConfiguration structure

The connection configuration for the data source.

dataSourceId
Required: Yes
Type: string

The unique identifier of the data source.

description
Type: string

The description of the data source.

failureReasons
Type: Array of strings

The detailed reasons on the failure to delete a data source.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which the data source belongs.

name
Required: Yes
Type: string

The name of the data source.

serverSideEncryptionConfiguration

Contains details about the configuration of the server-side encryption.

status
Required: Yes
Type: string

The status of the data source. The following statuses are possible:

  • Available – The data source has been created and is ready for ingestion into the knowledge base.

  • Deleting – The data source is being deleted.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the data source was last updated.

vectorIngestionConfiguration

Contains details about how to ingest the documents in the data source.

DataSourceConfiguration

Description

The connection configuration for the data source.

Members
confluenceConfiguration

The configuration information to connect to Confluence as your data source.

Confluence data source connector is in preview release and is subject to change.

s3Configuration
Type: S3DataSourceConfiguration structure

The configuration information to connect to Amazon S3 as your data source.

salesforceConfiguration

The configuration information to connect to Salesforce as your data source.

Salesforce data source connector is in preview release and is subject to change.

sharePointConfiguration

The configuration information to connect to SharePoint as your data source.

SharePoint data source connector is in preview release and is subject to change.

type
Required: Yes
Type: string

The type of data source.

webConfiguration
Type: WebDataSourceConfiguration structure

The configuration of web URLs to crawl for your data source. You should be authorized to crawl the URLs.

Crawling web URLs as your data source is in preview release and is subject to change.

DataSourceSummary

Description

Contains details about a data source.

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source.

description
Type: string

The description of the data source.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which the data source belongs.

name
Required: Yes
Type: string

The name of the data source.

status
Required: Yes
Type: string

The status of the data source.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the data source was last updated.

EmbeddingModelConfiguration

Description

The configuration details for the embeddings model.

Members
bedrockEmbeddingModelConfiguration

The vector configuration details on the Bedrock embeddings model.

FixedSizeChunkingConfiguration

Description

Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy as NONE, exclude this field.

Members
maxTokens
Required: Yes
Type: int

The maximum number of tokens to include in a chunk.

overlapPercentage
Required: Yes
Type: int

The percentage of overlap between adjacent chunks of a data source.

FlowAliasRoutingConfigurationListItem

Description

Contains information about a version that the alias maps to.

Members
flowVersion
Type: string

The version that the alias maps to.

FlowAliasSummary

Description

Contains information about an alias of a flow.

This data type is used in the following API operations:

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow alias.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias was created.

description
Type: string

A description of the alias.

flowId
Required: Yes
Type: string

The unique identifier of the flow.

id
Required: Yes
Type: string

The unique identifier of the alias of the flow.

name
Required: Yes
Type: string

The name of the alias.

routingConfiguration
Required: Yes
Type: Array of FlowAliasRoutingConfigurationListItem structures

A list of configurations about the versions that the alias maps to. Currently, you can only specify one.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the alias was last updated.

FlowCondition

Description

Defines a condition in the condition node.

Members
expression
Type: string

Defines the condition. You must refer to at least one of the inputs in the condition. For more information, expand the Condition node section in Node types in prompt flows.

name
Required: Yes
Type: string

A name for the condition that you can reference.

FlowConditionalConnectionConfiguration

Description

The configuration of a connection between a condition node and another node.

Members
condition
Required: Yes
Type: string

The condition that triggers this connection. For more information about how to write conditions, see the Condition node type in the Node types topic in the Amazon Bedrock User Guide.

FlowConnection

Description

Contains information about a connection between two nodes in the flow.

Members
configuration
Type: FlowConnectionConfiguration structure

The configuration of the connection.

name
Required: Yes
Type: string

A name for the connection that you can reference.

source
Required: Yes
Type: string

The node that the connection starts at.

target
Required: Yes
Type: string

The node that the connection ends at.

type
Required: Yes
Type: string

Whether the source node that the connection begins from is a condition node (Conditional) or not (Data).

FlowConnectionConfiguration

Description

The configuration of the connection.

Members
conditional

The configuration of a connection originating from a Condition node.

data

The configuration of a connection originating from a node that isn't a Condition node.

FlowDataConnectionConfiguration

Description

The configuration of a connection originating from a node that isn't a Condition node.

Members
sourceOutput
Required: Yes
Type: string

The name of the output in the source node that the connection begins from.

targetInput
Required: Yes
Type: string

The name of the input in the target node that the connection ends at.

FlowDefinition

Description

The definition of the nodes and connections between nodes in the flow.

Members
connections
Type: Array of FlowConnection structures

An array of connection definitions in the flow.

nodes
Type: Array of FlowNode structures

An array of node definitions in the flow.

FlowNode

Description

Contains configurations about a node in the flow.

Members
configuration
Type: FlowNodeConfiguration structure

Contains configurations for the node.

inputs
Type: Array of FlowNodeInput structures

An array of objects, each of which contains information about an input into the node.

name
Required: Yes
Type: string

A name for the node.

outputs
Type: Array of FlowNodeOutput structures

A list of objects, each of which contains information about an output from the node.

type
Required: Yes
Type: string

The type of node. This value must match the name of the key that you provide in the configuration you provide in the FlowNodeConfiguration field.

FlowNodeConfiguration

Description

Contains configurations for a node in your flow. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
agent
Type: AgentFlowNodeConfiguration structure

Contains configurations for an agent node in your flow. Invokes an alias of an agent and returns the response.

collector

Contains configurations for a collector node in your flow. Collects an iteration of inputs and consolidates them into an array of outputs.

condition

Contains configurations for a Condition node in your flow. Defines conditions that lead to different branches of the flow.

input
Type: InputFlowNodeConfiguration structure

Contains configurations for an input flow node in your flow. The first node in the flow. inputs can't be specified for this node.

iterator

Contains configurations for an iterator node in your flow. Takes an input that is an array and iteratively sends each item of the array as an output to the following node. The size of the array is also returned in the output.

The output flow node at the end of the flow iteration will return a response for each member of the array. To return only one response, you can include a collector node downstream from the iterator node.

knowledgeBase

Contains configurations for a knowledge base node in your flow. Queries a knowledge base and returns the retrieved results or generated response.

lambdaFunction

Contains configurations for a Lambda function node in your flow. Invokes an Lambda function.

lex
Type: LexFlowNodeConfiguration structure

Contains configurations for a Lex node in your flow. Invokes an Amazon Lex bot to identify the intent of the input and return the intent as the output.

output
Type: OutputFlowNodeConfiguration structure

Contains configurations for an output flow node in your flow. The last node in the flow. outputs can't be specified for this node.

prompt
Type: PromptFlowNodeConfiguration structure

Contains configurations for a prompt node in your flow. Runs a prompt and generates the model response as the output. You can use a prompt from Prompt management or you can configure one in this node.

retrieval

Contains configurations for a Retrieval node in your flow. Retrieves data from an Amazon S3 location and returns it as the output.

storage

Contains configurations for a Storage node in your flow. Stores an input in an Amazon S3 location.

FlowNodeInput

Description

Contains configurations for an input to a node.

Members
expression
Required: Yes
Type: string

An expression that formats the input for the node. For an explanation of how to create expressions, see Expressions in Prompt flows in Amazon Bedrock.

name
Required: Yes
Type: string

A name for the input that you can reference.

type
Required: Yes
Type: string

The data type of the input. If the input doesn't match this type at runtime, a validation error will be thrown.

FlowNodeOutput

Description

Contains configurations for an output from a node.

Members
name
Required: Yes
Type: string

A name for the output that you can reference.

type
Required: Yes
Type: string

The data type of the output. If the output doesn't match this type at runtime, a validation error will be thrown.

FlowSummary

Description

Contains the definition of a flow.

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was created.

description
Type: string

A description of the flow.

id
Required: Yes
Type: string

The unique identifier of the flow.

name
Required: Yes
Type: string

The name of the flow.

status
Required: Yes
Type: string

The status of the flow. The following statuses are possible:

  • NotPrepared – The flow has been created or updated, but hasn't been prepared. If you just created the flow, you can't test it. If you updated the flow, the DRAFT version won't contain the latest changes for testing. Send a PrepareFlow request to package the latest changes into the DRAFT version.

  • Preparing – The flow is being prepared so that the DRAFT version contains the latest changes for testing.

  • Prepared – The flow is prepared and the DRAFT version contains the latest changes for testing.

  • Failed – The last API operation that you invoked on the flow failed. Send a GetFlow request and check the error message in the validations field.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the flow was last updated.

version
Required: Yes
Type: string

The latest version of the flow.

FlowValidation

Description

Contains information about validation of the flow.

This data type is used in the following API operations:

Members
message
Required: Yes
Type: string

A message describing the validation error.

severity
Required: Yes
Type: string

The severity of the issue described in the message.

FlowVersionSummary

Description

Contains information about the flow version.

This data type is used in the following API operations:

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the flow that the version belongs to.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at the flow version was created.

id
Required: Yes
Type: string

The unique identifier of the flow.

status
Required: Yes
Type: string

The status of the flow.

version
Required: Yes
Type: string

The version of the flow.

Function

Description

Defines parameters that the agent needs to invoke from the user to complete the function. Corresponds to an action in an action group.

This data type is used in the following API operations:

Members
description
Type: string

A description of the function and its purpose.

name
Required: Yes
Type: string

A name for the function.

parameters
Type: Associative array of custom strings keys (Name) to ParameterDetail structures

The parameters that the agent elicits from the user to fulfill the function.

FunctionSchema

Description

Defines functions that each define parameters that the agent needs to invoke from the user. Each function represents an action in an action group.

This data type is used in the following API operations:

Members
functions
Type: Array of Function structures

A list of functions that each define an action in the action group.

GuardrailConfiguration

Description

Details about the guardrail associated with an agent.

Members
guardrailIdentifier
Type: string

The unique identifier of the guardrail.

guardrailVersion
Type: string

The version of the guardrail.

HierarchicalChunkingConfiguration

Description

Settings for hierarchical document chunking for a data source. Hierarchical chunking splits documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.

You configure the number of tokens to overlap, or repeat across adjacent chunks. For example, if you set overlap tokens to 60, the last 60 tokens in the first chunk are also included at the beginning of the second chunk. For each layer, you must also configure the maximum number of tokens in a chunk.

Members
levelConfigurations
Required: Yes
Type: Array of HierarchicalChunkingLevelConfiguration structures

Token settings for each layer.

overlapTokens
Required: Yes
Type: int

The number of tokens to repeat across chunks in the same layer.

HierarchicalChunkingLevelConfiguration

Description

Token settings for a layer in a hierarchical chunking configuration.

Members
maxTokens
Required: Yes
Type: int

The maximum number of tokens that a chunk can contain in this layer.

InferenceConfiguration

Description

Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence defined by the promptType. For more information, see Inference parameters for foundation models.

Members
maximumLength
Type: int

The maximum number of tokens to allow in the generated response.

stopSequences
Type: Array of strings

A list of stop sequences. A stop sequence is a sequence of characters that causes the model to stop generating the response.

temperature
Type: float

The likelihood of the model selecting higher-probability options while generating a response. A lower value makes the model more likely to choose higher-probability options, while a higher value makes the model more likely to choose lower-probability options.

topK
Type: int

While generating a response, the model determines the probability of the following token at each point of generation. The value that you set for topK is the number of most-likely candidates from which the model chooses the next token in the sequence. For example, if you set topK to 50, the model selects the next token from among the top 50 most likely choices.

topP
Type: float

While generating a response, the model determines the probability of the following token at each point of generation. The value that you set for Top P determines the number of most-likely candidates from which the model chooses the next token in the sequence. For example, if you set topP to 80, the model only selects the next token from the top 80% of the probability distribution of next tokens.

IngestionJob

Description

Contains details about an ingestion job, which converts a data source to embeddings for a vector store in knowledge base.

This data type is used in the following API operations:

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the ingested data source.

description
Type: string

The description of the ingestion job.

failureReasons
Type: Array of strings

A list of reasons that the ingestion job failed.

ingestionJobId
Required: Yes
Type: string

The unique identifier of the ingestion job.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which the data source is being added.

startedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the ingestion job started.

statistics
Type: IngestionJobStatistics structure

Contains statistics about the ingestion job.

status
Required: Yes
Type: string

The status of the ingestion job.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the ingestion job was last updated.

IngestionJobFilter

Description

Defines a filter by which to filter the results.

Members
attribute
Required: Yes
Type: string

The attribute by which to filter the results.

operator
Required: Yes
Type: string

The operation to carry out between the attribute and the values.

values
Required: Yes
Type: Array of strings

A list of values for the attribute.

IngestionJobSortBy

Description

Parameters by which to sort the results.

Members
attribute
Required: Yes
Type: string

The attribute by which to sort the results.

order
Required: Yes
Type: string

The order by which to sort the results.

IngestionJobStatistics

Description

Contains the statistics for the ingestion job.

Members
numberOfDocumentsDeleted
Type: long (int|float)

The number of source documents that was deleted.

numberOfDocumentsFailed
Type: long (int|float)

The number of source documents that failed to be ingested.

numberOfDocumentsScanned
Type: long (int|float)

The total number of source documents that were scanned. Includes new, updated, and unchanged documents.

numberOfMetadataDocumentsModified
Type: long (int|float)

The number of metadata files that were updated or deleted.

numberOfMetadataDocumentsScanned
Type: long (int|float)

The total number of metadata files that were scanned. Includes new, updated, and unchanged files.

numberOfModifiedDocumentsIndexed
Type: long (int|float)

The number of modified source documents in the data source that were successfully indexed.

numberOfNewDocumentsIndexed
Type: long (int|float)

The number of new source documents in the data source that were successfully indexed.

IngestionJobSummary

Description

Contains details about an ingestion job.

Members
dataSourceId
Required: Yes
Type: string

The unique identifier of the data source in the ingestion job.

description
Type: string

The description of the ingestion job.

ingestionJobId
Required: Yes
Type: string

The unique identifier of the ingestion job.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to which the data source is added.

startedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the ingestion job was started.

statistics
Type: IngestionJobStatistics structure

Contains statistics for the ingestion job.

status
Required: Yes
Type: string

The status of the ingestion job.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the ingestion job was last updated.

InputFlowNodeConfiguration

Description

Contains configurations for the input flow node for a flow. This node takes the input from flow invocation and passes it to the next node in the data type that you specify.

Members

IntermediateStorage

Description

A location for storing content from data sources temporarily as it is processed by custom components in the ingestion pipeline.

Members
s3Location
Required: Yes
Type: S3Location structure

An S3 bucket path.

InternalServerException

Description

An internal server error occurred. Retry your request.

Members
message
Type: string

IteratorFlowNodeConfiguration

Description

Contains configurations for an iterator node in a flow. Takes an input that is an array and iteratively sends each item of the array as an output to the following node. The size of the array is also returned in the output.

The output flow node at the end of the flow iteration will return a response for each member of the array. To return only one response, you can include a collector node downstream from the iterator node.

Members

KnowledgeBase

Description

Contains information about a knowledge base.

Members
createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the knowledge base was created.

description
Type: string

The description of the knowledge base.

failureReasons
Type: Array of strings

A list of reasons that the API operation on the knowledge base failed.

knowledgeBaseArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the knowledge base.

knowledgeBaseConfiguration
Required: Yes
Type: KnowledgeBaseConfiguration structure

Contains details about the embeddings configuration of the knowledge base.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base.

name
Required: Yes
Type: string

The name of the knowledge base.

roleArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the IAM role with permissions to invoke API operations on the knowledge base.

status
Required: Yes
Type: string

The status of the knowledge base. The following statuses are possible:

  • CREATING – The knowledge base is being created.

  • ACTIVE – The knowledge base is ready to be queried.

  • DELETING – The knowledge base is being deleted.

  • UPDATING – The knowledge base is being updated.

  • FAILED – The knowledge base API operation failed.

storageConfiguration
Required: Yes
Type: StorageConfiguration structure

Contains details about the storage configuration of the knowledge base.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the knowledge base was last updated.

KnowledgeBaseConfiguration

Description

Contains details about the embeddings configuration of the knowledge base.

Members
type
Required: Yes
Type: string

The type of data that the data source is converted into for the knowledge base.

vectorKnowledgeBaseConfiguration

Contains details about the embeddings model that'sused to convert the data source.

KnowledgeBaseFlowNodeConfiguration

Description

Contains configurations for a knowledge base node in a flow. This node takes a query as the input and returns, as the output, the retrieved responses directly (as an array) or a response generated based on the retrieved responses. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base to query.

modelId
Type: string

The unique identifier of the model to use to generate a response from the query results. Omit this field if you want to return the retrieved results as an array.

KnowledgeBaseSummary

Description

Contains details about a knowledge base.

Members
description
Type: string

The description of the knowledge base.

knowledgeBaseId
Required: Yes
Type: string

The unique identifier of the knowledge base.

name
Required: Yes
Type: string

The name of the knowledge base.

status
Required: Yes
Type: string

The status of the knowledge base.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the knowledge base was last updated.

LambdaFunctionFlowNodeConfiguration

Description

Contains configurations for a Lambda function node in the flow. You specify the Lambda function to invoke and the inputs into the function. The output is the response that is defined in the Lambda function. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
lambdaArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the Lambda function to invoke.

LexFlowNodeConfiguration

Description

Contains configurations for a Lex node in the flow. You specify a Amazon Lex bot to invoke. This node takes an utterance as the input and returns as the output the intent identified by the Amazon Lex bot. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
botAliasArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the Amazon Lex bot alias to invoke.

localeId
Required: Yes
Type: string

The Region to invoke the Amazon Lex bot in.

MemoryConfiguration

Description

Details of the memory configuration.

Members
enabledMemoryTypes
Required: Yes
Type: Array of strings

The type of memory that is stored.

storageDays
Type: int

The number of days the agent is configured to retain the conversational context.

MongoDbAtlasConfiguration

Description

Contains details about the storage configuration of the knowledge base in MongoDB Atlas.

Members
collectionName
Required: Yes
Type: string

The collection name of the knowledge base in MongoDB Atlas.

credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that contains user credentials for your MongoDB Atlas cluster.

databaseName
Required: Yes
Type: string

The database name in your MongoDB Atlas cluster for your knowledge base.

endpoint
Required: Yes
Type: string

The endpoint URL of your MongoDB Atlas cluster for your knowledge base.

endpointServiceName
Type: string

The name of the VPC endpoint service in your account that is connected to your MongoDB Atlas cluster.

fieldMapping
Required: Yes
Type: MongoDbAtlasFieldMapping structure

Contains the names of the fields to which to map information about the vector store.

vectorIndexName
Required: Yes
Type: string

The name of the MongoDB Atlas vector search index.

MongoDbAtlasFieldMapping

Description

Contains the names of the fields to which to map information about the vector store.

Members
metadataField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores metadata about the vector store.

textField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the raw text from your data. The text is split according to the chunking strategy you choose.

vectorField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

OpenSearchServerlessConfiguration

Description

Contains details about the storage configuration of the knowledge base in Amazon OpenSearch Service. For more information, see Create a vector index in Amazon OpenSearch Service.

Members
collectionArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the OpenSearch Service vector store.

fieldMapping
Required: Yes
Type: OpenSearchServerlessFieldMapping structure

Contains the names of the fields to which to map information about the vector store.

vectorIndexName
Required: Yes
Type: string

The name of the vector store.

OpenSearchServerlessFieldMapping

Description

Contains the names of the fields to which to map information about the vector store.

Members
metadataField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores metadata about the vector store.

textField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the raw text from your data. The text is split according to the chunking strategy you choose.

vectorField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

OutputFlowNodeConfiguration

Description

Contains configurations for an output flow node in the flow. You specify the data type expected for the input into the node in the type field and how to return the final output in the expression field.

Members

ParameterDetail

Description

Contains details about a parameter in a function for an action group.

This data type is used in the following API operations:

Members
description
Type: string

A description of the parameter. Helps the foundation model determine how to elicit the parameters from the user.

required
Type: boolean

Whether the parameter is required for the agent to complete the function for action group invocation.

type
Required: Yes
Type: string

The data type of the parameter.

ParsingConfiguration

Description

Settings for parsing document contents. By default, the service converts the contents of each document into text before splitting it into chunks. To improve processing of PDF files with tables and images, you can configure the data source to convert the pages of text into images and use a model to describe the contents of each page.

To use a model to parse PDF documents, set the parsing strategy to BEDROCK_FOUNDATION_MODEL and specify the model to use by ARN. You can also override the default parsing prompt with instructions for how to interpret images and tables in your documents. The following models are supported.

  • Anthropic Claude 3 Sonnet - anthropic.claude-3-sonnet-20240229-v1:0

  • Anthropic Claude 3 Haiku - anthropic.claude-3-haiku-20240307-v1:0

You can get the ARN of a model with the action. Standard model usage charges apply for the foundation model parsing strategy.

Members
bedrockFoundationModelConfiguration

Settings for a foundation model used to parse documents for a data source.

parsingStrategy
Required: Yes
Type: string

The parsing strategy for the data source.

ParsingPrompt

Description

Instructions for interpreting the contents of a document.

Members
parsingPromptText
Required: Yes
Type: string

Instructions for interpreting the contents of a document.

PatternObjectFilter

Description

The specific filters applied to your data source content. You can filter out or include certain content.

Members
exclusionFilters
Type: Array of strings

A list of one or more exclusion regular expression patterns to exclude certain object types that adhere to the pattern. If you specify an inclusion and exclusion filter/pattern and both match a document, the exclusion filter takes precedence and the document isn’t crawled.

inclusionFilters
Type: Array of strings

A list of one or more inclusion regular expression patterns to include certain object types that adhere to the pattern. If you specify an inclusion and exclusion filter/pattern and both match a document, the exclusion filter takes precedence and the document isn’t crawled.

objectType
Required: Yes
Type: string

The supported object type or content type of the data source.

PatternObjectFilterConfiguration

Description

The configuration of filtering certain objects or content types of the data source.

Members
filters
Required: Yes
Type: Array of PatternObjectFilter structures

The configuration of specific filters applied to your data source content. You can filter out or include certain content.

PineconeConfiguration

Description

Contains details about the storage configuration of the knowledge base in Pinecone. For more information, see Create a vector index in Pinecone.

Members
connectionString
Required: Yes
Type: string

The endpoint URL for your index management page.

credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Pinecone API key.

fieldMapping
Required: Yes
Type: PineconeFieldMapping structure

Contains the names of the fields to which to map information about the vector store.

namespace
Type: string

The namespace to be used to write new data to your database.

PineconeFieldMapping

Description

Contains the names of the fields to which to map information about the vector store.

Members
metadataField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores metadata about the vector store.

textField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the raw text from your data. The text is split according to the chunking strategy you choose.

PromptConfiguration

Description

Contains configurations to override a prompt template in one part of an agent sequence. For more information, see Advanced prompts.

Members
basePromptTemplate
Type: string

Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see Prompt template placeholder variables. For more information, see Configure the prompt templates.

inferenceConfiguration
Type: InferenceConfiguration structure

Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence defined by the promptType. For more information, see Inference parameters for foundation models.

parserMode
Type: string

Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in the part of the agent sequence defined by the promptType. If you set the field as OVERRIDEN, the overrideLambda field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.

promptCreationMode
Type: string

Specifies whether to override the default prompt template for this promptType. Set this value to OVERRIDDEN to use the prompt that you provide in the basePromptTemplate. If you leave it as DEFAULT, the agent uses a default prompt template.

promptState
Type: string

Specifies whether to allow the agent to carry out the step specified in the promptType. If you set this value to DISABLED, the agent skips that step. The default state for each promptType is as follows.

  • PRE_PROCESSINGENABLED

  • ORCHESTRATIONENABLED

  • KNOWLEDGE_BASE_RESPONSE_GENERATIONENABLED

  • POST_PROCESSINGDISABLED

promptType
Type: string

The step in the agent sequence that this prompt configuration applies to.

PromptFlowNodeConfiguration

Description

Contains configurations for a prompt node in the flow. You can use a prompt from Prompt management or you can define one in this node. If the prompt contains variables, the inputs into this node will fill in the variables. The output from this node is the response generated by the model. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

Members
sourceConfiguration
Required: Yes
Type: PromptFlowNodeSourceConfiguration structure

Specifies whether the prompt is from Prompt management or defined inline.

PromptFlowNodeInlineConfiguration

Description

Contains configurations for a prompt defined inline in the node.

Members
inferenceConfiguration

Contains inference configurations for the prompt.

modelId
Required: Yes
Type: string

The unique identifier of the model to run inference with.

templateConfiguration
Required: Yes
Type: PromptTemplateConfiguration structure

Contains a prompt and variables in the prompt that can be replaced with values at runtime.

templateType
Required: Yes
Type: string

The type of prompt template.

PromptFlowNodeResourceConfiguration

Description

Contains configurations for a prompt from Prompt management to use in a node.

Members
promptArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the prompt from Prompt management.

PromptFlowNodeSourceConfiguration

Description

Contains configurations for a prompt and whether it is from Prompt management or defined inline.

Members
inline

Contains configurations for a prompt that is defined inline

resource

Contains configurations for a prompt from Prompt management.

PromptInferenceConfiguration

Description

Contains inference configurations for the prompt.

Members
text

Contains inference configurations for a text prompt.

PromptInputVariable

Description

Contains information about a variable in the prompt.

Members
name
Type: string

The name of the variable.

PromptModelInferenceConfiguration

Description

Contains inference configurations related to model inference for a prompt. For more information, see Inference parameters.

Members
maxTokens
Type: int

The maximum number of tokens to return in the response.

stopSequences
Type: Array of strings

A list of strings that define sequences after which the model will stop generating.

temperature
Type: float

Controls the randomness of the response. Choose a lower value for more predictable outputs and a higher value for more surprising outputs.

topK
Type: int

The number of most-likely candidates that the model considers for the next token during generation.

topP
Type: float

The percentage of most-likely candidates that the model considers for the next token.

PromptOverrideConfiguration

Description

Contains configurations to override prompts in different parts of an agent sequence. For more information, see Advanced prompts.

Members
overrideLambda
Type: string

The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence. If you specify this field, at least one of the promptConfigurations must contain a parserMode value that is set to OVERRIDDEN. For more information, see Parser Lambda function in Agents for Amazon Bedrock.

promptConfigurations
Required: Yes
Type: Array of PromptConfiguration structures

Contains configurations to override a prompt template in one part of an agent sequence. For more information, see Advanced prompts.

PromptSummary

Description

Contains information about a prompt in your Prompt management tool.

This data type is used in the following API operations:

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the prompt.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was created.

description
Type: string

The description of the prompt.

id
Required: Yes
Type: string

The unique identifier of the prompt.

name
Required: Yes
Type: string

The name of the prompt.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time at which the prompt was last updated.

version
Required: Yes
Type: string

The version of the prompt that this summary applies to.

PromptVariant

Description

Contains details about a variant of the prompt.

Members
inferenceConfiguration

Contains inference configurations for the prompt variant.

modelId
Type: string

The unique identifier of the model with which to run inference on the prompt.

name
Required: Yes
Type: string

The name of the prompt variant.

templateConfiguration
Type: PromptTemplateConfiguration structure

Contains configurations for the prompt template.

templateType
Required: Yes
Type: string

The type of prompt template to use.

RdsConfiguration

Description

Contains details about the storage configuration of the knowledge base in Amazon RDS. For more information, see Create a vector index in Amazon RDS.

Members
credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Amazon RDS database.

databaseName
Required: Yes
Type: string

The name of your Amazon RDS database.

fieldMapping
Required: Yes
Type: RdsFieldMapping structure

Contains the names of the fields to which to map information about the vector store.

resourceArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the vector store.

tableName
Required: Yes
Type: string

The name of the table in the database.

RdsFieldMapping

Description

Contains the names of the fields to which to map information about the vector store.

Members
metadataField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores metadata about the vector store.

primaryKeyField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the ID for each entry.

textField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the raw text from your data. The text is split according to the chunking strategy you choose.

vectorField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

RedisEnterpriseCloudConfiguration

Description

Contains details about the storage configuration of the knowledge base in Redis Enterprise Cloud. For more information, see Create a vector index in Redis Enterprise Cloud.

Members
credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Redis Enterprise Cloud database.

endpoint
Required: Yes
Type: string

The endpoint URL of the Redis Enterprise Cloud database.

fieldMapping
Required: Yes
Type: RedisEnterpriseCloudFieldMapping structure

Contains the names of the fields to which to map information about the vector store.

vectorIndexName
Required: Yes
Type: string

The name of the vector index.

RedisEnterpriseCloudFieldMapping

Description

Contains the names of the fields to which to map information about the vector store.

Members
metadataField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores metadata about the vector store.

textField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the raw text from your data. The text is split according to the chunking strategy you choose.

vectorField
Required: Yes
Type: string

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

ResourceNotFoundException

Description

The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.

Members
message
Type: string

RetrievalFlowNodeConfiguration

Description

Contains configurations for a Retrieval node in a flow. This node retrieves data from the Amazon S3 location that you specify and returns it as the output.

Members
serviceConfiguration
Required: Yes
Type: RetrievalFlowNodeServiceConfiguration structure

Contains configurations for the service to use for retrieving data to return as the output from the node.

RetrievalFlowNodeS3Configuration

Description

Contains configurations for the Amazon S3 location from which to retrieve data to return as the output from the node.

Members
bucketName
Required: Yes
Type: string

The name of the Amazon S3 bucket from which to retrieve data.

RetrievalFlowNodeServiceConfiguration

Description

Contains configurations for the service to use for retrieving data to return as the output from the node.

Members
s3

Contains configurations for the Amazon S3 location from which to retrieve data to return as the output from the node.

S3DataSourceConfiguration

Description

The configuration information to connect to Amazon S3 as your data source.

Members
bucketArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the S3 bucket that contains your data.

bucketOwnerAccountId
Type: string

The account ID for the owner of the S3 bucket.

inclusionPrefixes
Type: Array of strings

A list of S3 prefixes to include certain files or content. For more information, see Organizing objects using prefixes.

S3Identifier

Description

The identifier information for an Amazon S3 bucket.

Members
s3BucketName
Type: string

The name of the S3 bucket.

s3ObjectKey
Type: string

The S3 object key for the S3 resource.

S3Location

Description

An Amazon S3 location.

Members
uri
Required: Yes
Type: string

The location's URI. For example, s3://my-bucket/chunk-processor/.

SalesforceCrawlerConfiguration

Description

The configuration of the Salesforce content. For example, configuring specific types of Salesforce content.

Members
filterConfiguration
Type: CrawlFilterConfiguration structure

The configuration of filtering the Salesforce content. For example, configuring regular expression patterns to include or exclude certain content.

SalesforceDataSourceConfiguration

Description

The configuration information to connect to Salesforce as your data source.

Members
crawlerConfiguration

The configuration of the Salesforce content. For example, configuring specific types of Salesforce content.

sourceConfiguration
Required: Yes
Type: SalesforceSourceConfiguration structure

The endpoint information to connect to your Salesforce data source.

SalesforceSourceConfiguration

Description

The endpoint information to connect to your Salesforce data source.

Members
authType
Required: Yes
Type: string

The supported authentication type to authenticate and connect to your Salesforce instance.

credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name of an Secrets Manager secret that stores your authentication credentials for your SharePoint site/sites. For more information on the key-value pairs that must be included in your secret, depending on your authentication type, see Salesforce connection configuration.

hostUrl
Required: Yes
Type: string

The Salesforce host URL or instance URL.

SeedUrl

Description

The seed or starting point URL. You should be authorized to crawl the URL.

Members
url
Type: string

A seed or starting point URL.

SemanticChunkingConfiguration

Description

Settings for semantic document chunking for a data source. Semantic chunking splits a document into into smaller documents based on groups of similar content derived from the text with natural language processing.

With semantic chunking, each sentence is compared to the next to determine how similar they are. You specify a threshold in the form of a percentile, where adjacent sentences that are less similar than that percentage of sentence pairs are divided into separate chunks. For example, if you set the threshold to 90, then the 10 percent of sentence pairs that are least similar are split. So if you have 101 sentences, 100 sentence pairs are compared, and the 10 with the least similarity are split, creating 11 chunks. These chunks are further split if they exceed the max token size.

You must also specify a buffer size, which determines whether sentences are compared in isolation, or within a moving context window that includes the previous and following sentence. For example, if you set the buffer size to 1, the embedding for sentence 10 is derived from sentences 9, 10, and 11 combined.

Members
breakpointPercentileThreshold
Required: Yes
Type: int

The dissimilarity threshold for splitting chunks.

bufferSize
Required: Yes
Type: int

The buffer size.

maxTokens
Required: Yes
Type: int

The maximum number of tokens that a chunk can contain.

ServerSideEncryptionConfiguration

Description

Contains the configuration for server-side encryption.

Members
kmsKeyArn
Type: string

The Amazon Resource Name (ARN) of the KMS key used to encrypt the resource.

ServiceQuotaExceededException

Description

The number of requests exceeds the service quota. Resubmit your request later.

Members
message
Type: string

SharePointCrawlerConfiguration

Description

The configuration of the SharePoint content. For example, configuring specific types of SharePoint content.

Members
filterConfiguration
Type: CrawlFilterConfiguration structure

The configuration of filtering the SharePoint content. For example, configuring regular expression patterns to include or exclude certain content.

SharePointDataSourceConfiguration

Description

The configuration information to connect to SharePoint as your data source.

Members
crawlerConfiguration

The configuration of the SharePoint content. For example, configuring specific types of SharePoint content.

sourceConfiguration
Required: Yes
Type: SharePointSourceConfiguration structure

The endpoint information to connect to your SharePoint data source.

SharePointSourceConfiguration

Description

The endpoint information to connect to your SharePoint data source.

Members
authType
Required: Yes
Type: string

The supported authentication type to authenticate and connect to your SharePoint site/sites.

credentialsSecretArn
Required: Yes
Type: string

The Amazon Resource Name of an Secrets Manager secret that stores your authentication credentials for your SharePoint site/sites. For more information on the key-value pairs that must be included in your secret, depending on your authentication type, see SharePoint connection configuration.

domain
Required: Yes
Type: string

The domain of your SharePoint instance or site URL/URLs.

hostType
Required: Yes
Type: string

The supported host type, whether online/cloud or server/on-premises.

siteUrls
Required: Yes
Type: Array of strings

A list of one or more SharePoint site URLs.

tenantId
Type: string

The identifier of your Microsoft 365 tenant.

StorageConfiguration

Description

Contains the storage configuration of the knowledge base.

Members
mongoDbAtlasConfiguration
Type: MongoDbAtlasConfiguration structure

Contains the storage configuration of the knowledge base in MongoDB Atlas.

opensearchServerlessConfiguration

Contains the storage configuration of the knowledge base in Amazon OpenSearch Service.

pineconeConfiguration
Type: PineconeConfiguration structure

Contains the storage configuration of the knowledge base in Pinecone.

rdsConfiguration
Type: RdsConfiguration structure

Contains details about the storage configuration of the knowledge base in Amazon RDS. For more information, see Create a vector index in Amazon RDS.

redisEnterpriseCloudConfiguration

Contains the storage configuration of the knowledge base in Redis Enterprise Cloud.

type
Required: Yes
Type: string

The vector store service in which the knowledge base is stored.

StorageFlowNodeConfiguration

Description

Contains configurations for a Storage node in a flow. This node stores the input in an Amazon S3 location that you specify.

Members
serviceConfiguration
Required: Yes
Type: StorageFlowNodeServiceConfiguration structure

Contains configurations for the service to use for storing the input into the node.

StorageFlowNodeS3Configuration

Description

Contains configurations for the Amazon S3 location in which to store the input into the node.

Members
bucketName
Required: Yes
Type: string

The name of the Amazon S3 bucket in which to store the input into the node.

StorageFlowNodeServiceConfiguration

Description

Contains configurations for the service to use for storing the input into the node.

Members
s3

Contains configurations for the Amazon S3 location in which to store the input into the node.

TextPromptTemplateConfiguration

Description

Contains configurations for a text prompt template. To include a variable, enclose a word in double curly braces as in {{variable}}.

Members
inputVariables
Type: Array of PromptInputVariable structures

An array of the variables in the prompt template.

text
Required: Yes
Type: string

The message for the prompt.

ThrottlingException

Description

The number of requests exceeds the limit. Resubmit your request later.

Members
message
Type: string

Transformation

Description

A custom processing step for documents moving through a data source ingestion pipeline. To process documents after they have been converted into chunks, set the step to apply to POST_CHUNKING.

Members
stepToApply
Required: Yes
Type: string

When the service applies the transformation.

transformationFunction
Required: Yes
Type: TransformationFunction structure

A Lambda function that processes documents.

TransformationFunction

Description

A Lambda function that processes documents.

Members
transformationLambdaConfiguration
Required: Yes
Type: TransformationLambdaConfiguration structure

The Lambda function.

TransformationLambdaConfiguration

Description

A Lambda function that processes documents.

Members
lambdaArn
Required: Yes
Type: string

The function's ARN identifier.

UrlConfiguration

Description

The configuration of web URLs that you want to crawl. You should be authorized to crawl the URLs.

Members
seedUrls
Type: Array of SeedUrl structures

One or more seed or starting point URLs.

ValidationException

Description

Input validation failed. Check your request parameters and retry the request.

Members
fieldList
Type: Array of ValidationExceptionField structures

A list of objects containing fields that caused validation errors and their corresponding validation error messages.

message
Type: string

ValidationExceptionField

Description

Stores information about a field passed inside a request that resulted in an validation error.

Members
message
Required: Yes
Type: string

A message describing why this field failed validation.

name
Required: Yes
Type: string

The name of the field.

VectorIngestionConfiguration

Description

Contains details about how to ingest the documents in a data source.

Members
chunkingConfiguration
Type: ChunkingConfiguration structure

Details about how to chunk the documents in the data source. A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried.

customTransformationConfiguration

A custom document transformer for parsed data source documents.

parsingConfiguration
Type: ParsingConfiguration structure

A custom parser for data source documents.

VectorKnowledgeBaseConfiguration

Description

Contains details about the model used to create vector embeddings for the knowledge base.

Members
embeddingModelArn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the model used to create vector embeddings for the knowledge base.

embeddingModelConfiguration
Type: EmbeddingModelConfiguration structure

The embeddings model configuration details for the vector model used in Knowledge Base.

WebCrawlerConfiguration

Description

The configuration of web URLs that you want to crawl. You should be authorized to crawl the URLs.

Members
crawlerLimits
Type: WebCrawlerLimits structure

The configuration of crawl limits for the web URLs.

exclusionFilters
Type: Array of strings

A list of one or more exclusion regular expression patterns to exclude certain URLs. If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.

inclusionFilters
Type: Array of strings

A list of one or more inclusion regular expression patterns to include certain URLs. If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.

scope
Type: string

The scope of what is crawled for your URLs.

You can choose to crawl only web pages that belong to the same host or primary domain. For example, only web pages that contain the seed URL "https://docs.aws.amazon.com/bedrock/latest/userguide/" and no other domains. You can choose to include sub domains in addition to the host or primary domain. For example, web pages that contain "aws.amazon.com" can also include sub domain "docs.aws.amazon.com".

WebCrawlerLimits

Description

The rate limits for the URLs that you want to crawl. You should be authorized to crawl the URLs.

Members
rateLimit
Type: int

The max rate at which pages are crawled, up to 300 per minute per host.

WebDataSourceConfiguration

Description

The configuration details for the web data source.

Members
crawlerConfiguration
Type: WebCrawlerConfiguration structure

The Web Crawler configuration details for the web data source.

sourceConfiguration
Required: Yes
Type: WebSourceConfiguration structure

The source configuration details for the web data source.

WebSourceConfiguration

Description

The configuration of the URL/URLs for the web content that you want to crawl. You should be authorized to crawl the URLs.

Members
urlConfiguration
Required: Yes
Type: UrlConfiguration structure

The configuration of the URL/URLs.