diff --git a/CHANGELOG.md b/CHANGELOG.md index b23536f2288..11058dc2def 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,21 @@ +Release v1.54.18 (2024-07-10) +=== + +### Service Client Updates +* `service/batch`: Updates service API and documentation + * This feature allows AWS Batch Jobs with EKS container orchestration type to be run as Multi-Node Parallel Jobs. +* `service/bedrock`: Updates service API and documentation +* `service/bedrock-agent`: Updates service API, documentation, and paginators +* `service/bedrock-agent-runtime`: Updates service API, documentation, and paginators +* `service/bedrock-runtime`: Updates service API and documentation +* `service/ec2`: Updates service API and documentation + * Add parameters to enable provisioning IPAM BYOIPv4 space at a Local Zone Network Border Group level +* `service/glue`: Updates service API and documentation + * Add recipe step support for recipe node +* `service/groundstation`: Updates service API and documentation +* `service/license-manager-linux-subscriptions`: Updates service API, documentation, and paginators +* `service/mediaconnect`: Updates service API and documentation + Release v1.54.17 (2024-07-09) === diff --git a/aws/endpoints/defaults.go b/aws/endpoints/defaults.go index 27446c59eb1..fd47b5b36b9 100644 --- a/aws/endpoints/defaults.go +++ b/aws/endpoints/defaults.go @@ -5357,6 +5357,18 @@ var awsPartition = partition{ Region: "ca-central-1", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "ca-central-1", + Variant: fipsVariant, + }: endpoint{ + Hostname: "cloud9-fips.ca-central-1.amazonaws.com", + }, + endpointKey{ + Region: "ca-central-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloud9-fips.ca-central-1.api.aws", + }, endpointKey{ Region: "eu-central-1", }: endpoint{}, @@ -5399,6 +5411,51 @@ var awsPartition = partition{ Region: "eu-west-3", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "fips-ca-central-1", + }: endpoint{ + Hostname: "cloud9-fips.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + Deprecated: boxedTrue, + }, + endpointKey{ + Region: "fips-us-east-1", + }: endpoint{ + Hostname: "cloud9-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + Deprecated: boxedTrue, + }, + endpointKey{ + Region: "fips-us-east-2", + }: endpoint{ + Hostname: "cloud9-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + Deprecated: boxedTrue, + }, + endpointKey{ + Region: "fips-us-west-1", + }: endpoint{ + Hostname: "cloud9-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + Deprecated: boxedTrue, + }, + endpointKey{ + Region: "fips-us-west-2", + }: endpoint{ + Hostname: "cloud9-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + Deprecated: boxedTrue, + }, endpointKey{ Region: "il-central-1", }: endpoint{}, @@ -5427,6 +5484,18 @@ var awsPartition = partition{ Region: "us-east-1", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "us-east-1", + Variant: fipsVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-east-1.amazonaws.com", + }, + endpointKey{ + Region: "us-east-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-east-1.api.aws", + }, endpointKey{ Region: "us-east-2", }: endpoint{}, @@ -5434,6 +5503,18 @@ var awsPartition = partition{ Region: "us-east-2", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "us-east-2", + Variant: fipsVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-east-2.amazonaws.com", + }, + endpointKey{ + Region: "us-east-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-east-2.api.aws", + }, endpointKey{ Region: "us-west-1", }: endpoint{}, @@ -5441,6 +5522,18 @@ var awsPartition = partition{ Region: "us-west-1", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "us-west-1", + Variant: fipsVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-west-1.amazonaws.com", + }, + endpointKey{ + Region: "us-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-west-1.api.aws", + }, endpointKey{ Region: "us-west-2", }: endpoint{}, @@ -5448,6 +5541,18 @@ var awsPartition = partition{ Region: "us-west-2", Variant: dualStackVariant, }: endpoint{}, + endpointKey{ + Region: "us-west-2", + Variant: fipsVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-west-2.amazonaws.com", + }, + endpointKey{ + Region: "us-west-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloud9-fips.us-west-2.api.aws", + }, }, }, "cloudcontrolapi": service{ @@ -5455,78 +5560,216 @@ var awsPartition = partition{ endpointKey{ Region: "af-south-1", }: endpoint{}, + endpointKey{ + Region: "af-south-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.af-south-1.api.aws", + }, endpointKey{ Region: "ap-east-1", }: endpoint{}, + endpointKey{ + Region: "ap-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-east-1.api.aws", + }, endpointKey{ Region: "ap-northeast-1", }: endpoint{}, + endpointKey{ + Region: "ap-northeast-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-northeast-1.api.aws", + }, endpointKey{ Region: "ap-northeast-2", }: endpoint{}, + endpointKey{ + Region: "ap-northeast-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-northeast-2.api.aws", + }, endpointKey{ Region: "ap-northeast-3", }: endpoint{}, + endpointKey{ + Region: "ap-northeast-3", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-northeast-3.api.aws", + }, endpointKey{ Region: "ap-south-1", }: endpoint{}, + endpointKey{ + Region: "ap-south-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-south-1.api.aws", + }, endpointKey{ Region: "ap-south-2", }: endpoint{}, + endpointKey{ + Region: "ap-south-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-south-2.api.aws", + }, endpointKey{ Region: "ap-southeast-1", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-southeast-1.api.aws", + }, endpointKey{ Region: "ap-southeast-2", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-southeast-2.api.aws", + }, endpointKey{ Region: "ap-southeast-3", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-3", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-southeast-3.api.aws", + }, endpointKey{ Region: "ap-southeast-4", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-4", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ap-southeast-4.api.aws", + }, endpointKey{ Region: "ca-central-1", }: endpoint{}, + endpointKey{ + Region: "ca-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ca-central-1.api.aws", + }, endpointKey{ Region: "ca-central-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.ca-central-1.amazonaws.com", }, + endpointKey{ + Region: "ca-central-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.ca-central-1.api.aws", + }, endpointKey{ Region: "ca-west-1", }: endpoint{}, + endpointKey{ + Region: "ca-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.ca-west-1.api.aws", + }, endpointKey{ Region: "ca-west-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.ca-west-1.amazonaws.com", }, + endpointKey{ + Region: "ca-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.ca-west-1.api.aws", + }, endpointKey{ Region: "eu-central-1", }: endpoint{}, + endpointKey{ + Region: "eu-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-central-1.api.aws", + }, endpointKey{ Region: "eu-central-2", }: endpoint{}, + endpointKey{ + Region: "eu-central-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-central-2.api.aws", + }, endpointKey{ Region: "eu-north-1", }: endpoint{}, + endpointKey{ + Region: "eu-north-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-north-1.api.aws", + }, endpointKey{ Region: "eu-south-1", }: endpoint{}, + endpointKey{ + Region: "eu-south-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-south-1.api.aws", + }, endpointKey{ Region: "eu-south-2", }: endpoint{}, + endpointKey{ + Region: "eu-south-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-south-2.api.aws", + }, endpointKey{ Region: "eu-west-1", }: endpoint{}, + endpointKey{ + Region: "eu-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-west-1.api.aws", + }, endpointKey{ Region: "eu-west-2", }: endpoint{}, + endpointKey{ + Region: "eu-west-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-west-2.api.aws", + }, endpointKey{ Region: "eu-west-3", }: endpoint{}, + endpointKey{ + Region: "eu-west-3", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.eu-west-3.api.aws", + }, endpointKey{ Region: "fips-ca-central-1", }: endpoint{ @@ -5584,51 +5827,123 @@ var awsPartition = partition{ endpointKey{ Region: "il-central-1", }: endpoint{}, + endpointKey{ + Region: "il-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.il-central-1.api.aws", + }, endpointKey{ Region: "me-central-1", }: endpoint{}, + endpointKey{ + Region: "me-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.me-central-1.api.aws", + }, endpointKey{ Region: "me-south-1", }: endpoint{}, + endpointKey{ + Region: "me-south-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.me-south-1.api.aws", + }, endpointKey{ Region: "sa-east-1", }: endpoint{}, + endpointKey{ + Region: "sa-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.sa-east-1.api.aws", + }, endpointKey{ Region: "us-east-1", }: endpoint{}, + endpointKey{ + Region: "us-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-east-1.api.aws", + }, endpointKey{ Region: "us-east-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-east-1.amazonaws.com", }, + endpointKey{ + Region: "us-east-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-east-1.api.aws", + }, endpointKey{ Region: "us-east-2", }: endpoint{}, + endpointKey{ + Region: "us-east-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-east-2.api.aws", + }, endpointKey{ Region: "us-east-2", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-east-2.amazonaws.com", }, + endpointKey{ + Region: "us-east-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-east-2.api.aws", + }, endpointKey{ Region: "us-west-1", }: endpoint{}, + endpointKey{ + Region: "us-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-west-1.api.aws", + }, endpointKey{ Region: "us-west-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-west-1.amazonaws.com", }, + endpointKey{ + Region: "us-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-west-1.api.aws", + }, endpointKey{ Region: "us-west-2", }: endpoint{}, + endpointKey{ + Region: "us-west-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-west-2.api.aws", + }, endpointKey{ Region: "us-west-2", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-west-2.amazonaws.com", }, + endpointKey{ + Region: "us-west-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-west-2.api.aws", + }, }, }, "clouddirectory": service{ @@ -33284,36 +33599,96 @@ var awsPartition = partition{ endpointKey{ Region: "ap-northeast-2", }: endpoint{}, + endpointKey{ + Region: "ap-northeast-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.ap-northeast-2.api.aws", + }, endpointKey{ Region: "ap-south-1", }: endpoint{}, + endpointKey{ + Region: "ap-south-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.ap-south-1.api.aws", + }, endpointKey{ Region: "ap-southeast-1", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.ap-southeast-1.api.aws", + }, endpointKey{ Region: "ap-southeast-2", }: endpoint{}, + endpointKey{ + Region: "ap-southeast-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.ap-southeast-2.api.aws", + }, endpointKey{ Region: "ca-central-1", }: endpoint{}, + endpointKey{ + Region: "ca-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.ca-central-1.api.aws", + }, endpointKey{ Region: "ca-central-1", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.ca-central-1.amazonaws.com", }, + endpointKey{ + Region: "ca-central-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.ca-central-1.api.aws", + }, endpointKey{ Region: "eu-central-1", }: endpoint{}, + endpointKey{ + Region: "eu-central-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.eu-central-1.api.aws", + }, endpointKey{ Region: "eu-west-1", }: endpoint{}, + endpointKey{ + Region: "eu-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.eu-west-1.api.aws", + }, endpointKey{ Region: "eu-west-2", }: endpoint{}, + endpointKey{ + Region: "eu-west-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.eu-west-2.api.aws", + }, endpointKey{ Region: "eu-west-3", }: endpoint{}, + endpointKey{ + Region: "eu-west-3", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.eu-west-3.api.aws", + }, endpointKey{ Region: "fips-ca-central-1", }: endpoint{ @@ -33362,39 +33737,87 @@ var awsPartition = partition{ endpointKey{ Region: "us-east-1", }: endpoint{}, + endpointKey{ + Region: "us-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-east-1.api.aws", + }, endpointKey{ Region: "us-east-1", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-east-1.amazonaws.com", }, + endpointKey{ + Region: "us-east-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-east-1.api.aws", + }, endpointKey{ Region: "us-east-2", }: endpoint{}, + endpointKey{ + Region: "us-east-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-east-2.api.aws", + }, endpointKey{ Region: "us-east-2", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-east-2.amazonaws.com", }, + endpointKey{ + Region: "us-east-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-east-2.api.aws", + }, endpointKey{ Region: "us-west-1", }: endpoint{}, + endpointKey{ + Region: "us-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-west-1.api.aws", + }, endpointKey{ Region: "us-west-1", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-west-1.amazonaws.com", }, + endpointKey{ + Region: "us-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-west-1.api.aws", + }, endpointKey{ Region: "us-west-2", }: endpoint{}, + endpointKey{ + Region: "us-west-2", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-west-2.api.aws", + }, endpointKey{ Region: "us-west-2", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-west-2.amazonaws.com", }, + endpointKey{ + Region: "us-west-2", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-west-2.api.aws", + }, }, }, "thinclient": service{ @@ -36839,9 +37262,21 @@ var awscnPartition = partition{ endpointKey{ Region: "cn-north-1", }: endpoint{}, + endpointKey{ + Region: "cn-north-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.cn-north-1.api.amazonwebservices.com.cn", + }, endpointKey{ Region: "cn-northwest-1", }: endpoint{}, + endpointKey{ + Region: "cn-northwest-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.cn-northwest-1.api.amazonwebservices.com.cn", + }, }, }, "cloudformation": service{ @@ -39739,21 +40174,45 @@ var awsusgovPartition = partition{ endpointKey{ Region: "us-gov-east-1", }: endpoint{}, + endpointKey{ + Region: "us-gov-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-gov-east-1.api.aws", + }, endpointKey{ Region: "us-gov-east-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-gov-east-1.amazonaws.com", }, + endpointKey{ + Region: "us-gov-east-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-gov-east-1.api.aws", + }, endpointKey{ Region: "us-gov-west-1", }: endpoint{}, + endpointKey{ + Region: "us-gov-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi.us-gov-west-1.api.aws", + }, endpointKey{ Region: "us-gov-west-1", Variant: fipsVariant, }: endpoint{ Hostname: "cloudcontrolapi-fips.us-gov-west-1.amazonaws.com", }, + endpointKey{ + Region: "us-gov-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "cloudcontrolapi-fips.us-gov-west-1.api.aws", + }, }, }, "clouddirectory": service{ @@ -45387,21 +45846,45 @@ var awsusgovPartition = partition{ endpointKey{ Region: "us-gov-east-1", }: endpoint{}, + endpointKey{ + Region: "us-gov-east-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-gov-east-1.api.aws", + }, endpointKey{ Region: "us-gov-east-1", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-gov-east-1.amazonaws.com", }, + endpointKey{ + Region: "us-gov-east-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-gov-east-1.api.aws", + }, endpointKey{ Region: "us-gov-west-1", }: endpoint{}, + endpointKey{ + Region: "us-gov-west-1", + Variant: dualStackVariant, + }: endpoint{ + Hostname: "textract.us-gov-west-1.api.aws", + }, endpointKey{ Region: "us-gov-west-1", Variant: fipsVariant, }: endpoint{ Hostname: "textract-fips.us-gov-west-1.amazonaws.com", }, + endpointKey{ + Region: "us-gov-west-1", + Variant: fipsVariant | dualStackVariant, + }: endpoint{ + Hostname: "textract-fips.us-gov-west-1.api.aws", + }, }, }, "transcribe": service{ diff --git a/aws/version.go b/aws/version.go index a6b3fe4364a..d3f3eeb6ac1 100644 --- a/aws/version.go +++ b/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.54.17" +const SDKVersion = "1.54.18" diff --git a/models/apis/batch/2016-08-10/api-2.json b/models/apis/batch/2016-08-10/api-2.json index d3884b4234a..2a4d538e943 100644 --- a/models/apis/batch/2016-08-10/api-2.json +++ b/models/apis/batch/2016-08-10/api-2.json @@ -1024,6 +1024,7 @@ "members":{ "containers":{"shape":"EksAttemptContainerDetails"}, "initContainers":{"shape":"EksAttemptContainerDetails"}, + "eksClusterArn":{"shape":"String"}, "podName":{"shape":"String"}, "nodeName":{"shape":"String"}, "startedAt":{"shape":"Long"}, @@ -1792,7 +1793,8 @@ "targetNodes":{"shape":"String"}, "containerOverrides":{"shape":"ContainerOverrides"}, "ecsPropertiesOverride":{"shape":"EcsPropertiesOverride"}, - "instanceTypes":{"shape":"StringList"} + "instanceTypes":{"shape":"StringList"}, + "eksPropertiesOverride":{"shape":"EksPropertiesOverride"} } }, "NodePropertyOverrides":{ @@ -1810,7 +1812,8 @@ "targetNodes":{"shape":"String"}, "container":{"shape":"ContainerProperties"}, "instanceTypes":{"shape":"StringList"}, - "ecsProperties":{"shape":"EcsProperties"} + "ecsProperties":{"shape":"EcsProperties"}, + "eksProperties":{"shape":"EksProperties"} } }, "OrchestrationType":{ diff --git a/models/apis/batch/2016-08-10/docs-2.json b/models/apis/batch/2016-08-10/docs-2.json index 52e6d86e632..5fdf66985e5 100644 --- a/models/apis/batch/2016-08-10/docs-2.json +++ b/models/apis/batch/2016-08-10/docs-2.json @@ -634,6 +634,7 @@ "base": "

An object that contains the properties for the Kubernetes resources of a job.

", "refs": { "JobDefinition$eksProperties": "

An object with properties that are specific to Amazon EKS-based jobs. When eksProperties is used in the job definition, it can't be used in addition to containerProperties, ecsProperties, or nodeProperties.

", + "NodeRangeProperty$eksProperties": "

This is an object that represents the properties of the node range for a multi-node parallel job.

", "RegisterJobDefinitionRequest$eksProperties": "

An object with properties that are specific to Amazon EKS-based jobs. This must not be specified for Amazon ECS based job definitions.

" } }, @@ -646,6 +647,7 @@ "EksPropertiesOverride": { "base": "

An object that contains overrides for the Kubernetes resources of a job.

", "refs": { + "NodePropertyOverride$eksPropertiesOverride": "

An object that contains the properties that you want to replace for the existing Amazon EKS resources of a job.

", "SubmitJobRequest$eksPropertiesOverride": "

An object, with properties that override defaults for the job definition, can only be specified for jobs that are run on Amazon EKS resources.

" } }, @@ -1484,6 +1486,7 @@ "EcsTaskProperties$pidMode": "

The process namespace to use for the containers in the task. The valid values are host or task. For example, monitoring sidecars might need pidMode to access information about other containers running in the same task.

If host is specified, all containers within the tasks that specified the host PID mode on the same container instance share the process namespace with the host Amazon EC2 instance.

If task is specified, all containers within the specified task share the same process namespace.

If no value is specified, the default is a private namespace for each container. For more information, see PID settings in the Docker run reference.

", "EksAttemptContainerDetail$name": "

The name of a container.

", "EksAttemptContainerDetail$reason": "

A short (255 max characters) human-readable string to provide additional details for a running or stopped container.

", + "EksAttemptDetail$eksClusterArn": "

The Amazon Resource Name (ARN) of the Amazon EKS cluster.

", "EksAttemptDetail$podName": "

The name of the pod for this job attempt.

", "EksAttemptDetail$nodeName": "

The name of the node for this job attempt.

", "EksAttemptDetail$statusReason": "

A short, human-readable string to provide additional details for the current status of the job attempt.

", diff --git a/models/apis/bedrock-agent-runtime/2023-07-26/api-2.json b/models/apis/bedrock-agent-runtime/2023-07-26/api-2.json index 9065a6dd75b..7916dcfd238 100644 --- a/models/apis/bedrock-agent-runtime/2023-07-26/api-2.json +++ b/models/apis/bedrock-agent-runtime/2023-07-26/api-2.json @@ -11,6 +11,93 @@ "uid": "bedrock-agent-runtime-2023-07-26" }, "operations": { + "DeleteAgentMemory": { + "errors": [ + { + "shape": "ConflictException" + }, + { + "shape": "ResourceNotFoundException" + }, + { + "shape": "ValidationException" + }, + { + "shape": "InternalServerException" + }, + { + "shape": "DependencyFailedException" + }, + { + "shape": "BadGatewayException" + }, + { + "shape": "ThrottlingException" + }, + { + "shape": "AccessDeniedException" + }, + { + "shape": "ServiceQuotaExceededException" + } + ], + "http": { + "method": "DELETE", + "requestUri": "/agents/{agentId}/agentAliases/{agentAliasId}/memories", + "responseCode": 202 + }, + "idempotent": true, + "input": { + "shape": "DeleteAgentMemoryRequest" + }, + "name": "DeleteAgentMemory", + "output": { + "shape": "DeleteAgentMemoryResponse" + } + }, + "GetAgentMemory": { + "errors": [ + { + "shape": "ConflictException" + }, + { + "shape": "ResourceNotFoundException" + }, + { + "shape": "ValidationException" + }, + { + "shape": "InternalServerException" + }, + { + "shape": "DependencyFailedException" + }, + { + "shape": "BadGatewayException" + }, + { + "shape": "ThrottlingException" + }, + { + "shape": "AccessDeniedException" + }, + { + "shape": "ServiceQuotaExceededException" + } + ], + "http": { + "method": "GET", + "requestUri": "/agents/{agentId}/agentAliases/{agentAliasId}/memories", + "responseCode": 200 + }, + "input": { + "shape": "GetAgentMemoryRequest" + }, + "name": "GetAgentMemory", + "output": { + "shape": "GetAgentMemoryResponse" + } + }, "InvokeAgent": { "errors": [ { @@ -54,6 +141,49 @@ "shape": "InvokeAgentResponse" } }, + "InvokeFlow": { + "errors": [ + { + "shape": "ConflictException" + }, + { + "shape": "ResourceNotFoundException" + }, + { + "shape": "ValidationException" + }, + { + "shape": "InternalServerException" + }, + { + "shape": "DependencyFailedException" + }, + { + "shape": "BadGatewayException" + }, + { + "shape": "ThrottlingException" + }, + { + "shape": "AccessDeniedException" + }, + { + "shape": "ServiceQuotaExceededException" + } + ], + "http": { + "method": "POST", + "requestUri": "/flows/{flowIdentifier}/aliases/{flowAliasIdentifier}", + "responseCode": 200 + }, + "input": { + "shape": "InvokeFlowRequest" + }, + "name": "InvokeFlow", + "output": { + "shape": "InvokeFlowResponse" + } + }, "Retrieve": { "errors": [ { @@ -163,9 +293,15 @@ "apiPath": { "shape": "ApiPath" }, + "executionType": { + "shape": "ExecutionType" + }, "function": { "shape": "Function" }, + "invocationId": { + "shape": "String" + }, "parameters": { "shape": "Parameters" }, @@ -366,6 +502,21 @@ ], "type": "structure" }, + "ByteContentFile": { + "members": { + "data": { + "shape": "ByteContentBlob" + }, + "mediaType": { + "shape": "MimeType" + } + }, + "required": [ + "data", + "mediaType" + ], + "type": "structure" + }, "Citation": { "members": { "generatedResponsePart": { @@ -383,6 +534,34 @@ }, "type": "list" }, + "CodeInterpreterInvocationInput": { + "members": { + "code": { + "shape": "String" + }, + "files": { + "shape": "Files" + } + }, + "type": "structure" + }, + "CodeInterpreterInvocationOutput": { + "members": { + "executionError": { + "shape": "String" + }, + "executionOutput": { + "shape": "String" + }, + "executionTimeout": { + "shape": "Boolean" + }, + "files": { + "shape": "Files" + } + }, + "type": "structure" + }, "ConflictException": { "error": { "httpStatusCode": 409, @@ -424,6 +603,38 @@ ], "type": "string" }, + "DateTimestamp": { + "timestampFormat": "iso8601", + "type": "timestamp" + }, + "DeleteAgentMemoryRequest": { + "members": { + "agentAliasId": { + "location": "uri", + "locationName": "agentAliasId", + "shape": "AgentAliasId" + }, + "agentId": { + "location": "uri", + "locationName": "agentId", + "shape": "AgentId" + }, + "memoryId": { + "location": "querystring", + "locationName": "memoryId", + "shape": "MemoryId" + } + }, + "required": [ + "agentAliasId", + "agentId" + ], + "type": "structure" + }, + "DeleteAgentMemoryResponse": { + "members": {}, + "type": "structure" + }, "DependencyFailedException": { "error": { "httpStatusCode": 424, @@ -444,6 +655,13 @@ "box": true, "type": "double" }, + "ExecutionType": { + "enum": [ + "LAMBDA", + "RETURN_CONTROL" + ], + "type": "string" + }, "ExternalSource": { "members": { "byteContent": { @@ -524,23 +742,204 @@ "sensitive": true, "type": "structure" }, + "FileBody": { + "max": 1000000, + "min": 0, + "sensitive": true, + "type": "blob" + }, + "FilePart": { + "event": true, + "members": { + "files": { + "shape": "OutputFiles" + } + }, + "type": "structure" + }, + "FileSource": { + "members": { + "byteContent": { + "shape": "ByteContentFile" + }, + "s3Location": { + "shape": "S3ObjectFile" + }, + "sourceType": { + "shape": "FileSourceType" + } + }, + "required": [ + "sourceType" + ], + "type": "structure" + }, + "FileSourceType": { + "enum": [ + "S3", + "BYTE_CONTENT" + ], + "type": "string" + }, + "FileUseCase": { + "enum": [ + "CODE_INTERPRETER", + "CHAT" + ], + "type": "string" + }, + "Files": { + "member": { + "shape": "String" + }, + "type": "list" + }, "FilterKey": { "max": 100, "min": 1, "type": "string" }, - "FinalResponse": { + "FinalResponse": { + "members": { + "text": { + "shape": "FinalResponseString" + } + }, + "type": "structure" + }, + "FinalResponseString": { + "sensitive": true, + "type": "string" + }, + "FlowAliasIdentifier": { + "max": 2048, + "min": 0, + "pattern": "^(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10}/alias/[0-9a-zA-Z]{10})|(\\bTSTALIASID\\b|[0-9a-zA-Z]+)$", + "type": "string" + }, + "FlowCompletionEvent": { + "event": true, + "members": { + "completionReason": { + "shape": "FlowCompletionReason" + } + }, + "required": [ + "completionReason" + ], + "sensitive": true, + "type": "structure" + }, + "FlowCompletionReason": { + "enum": [ + "SUCCESS" + ], + "type": "string" + }, + "FlowIdentifier": { + "max": 2048, + "min": 0, + "pattern": "^(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10})|([0-9a-zA-Z]{10})$", + "type": "string" + }, + "FlowInput": { + "members": { + "content": { + "shape": "FlowInputContent" + }, + "nodeName": { + "shape": "NodeName" + }, + "nodeOutputName": { + "shape": "NodeOutputName" + } + }, + "required": [ + "content", + "nodeName", + "nodeOutputName" + ], + "type": "structure" + }, + "FlowInputContent": { + "members": {}, + "sensitive": true, + "type": "structure", + "union": true + }, + "FlowInputs": { + "max": 1, + "member": { + "shape": "FlowInput" + }, + "min": 1, + "type": "list" + }, + "FlowOutputContent": { + "members": {}, + "type": "structure", + "union": true + }, + "FlowOutputEvent": { + "event": true, + "members": { + "content": { + "shape": "FlowOutputContent" + }, + "nodeName": { + "shape": "NodeName" + }, + "nodeType": { + "shape": "NodeType" + } + }, + "required": [ + "content", + "nodeName", + "nodeType" + ], + "sensitive": true, + "type": "structure" + }, + "FlowResponseStream": { + "eventstream": true, "members": { - "text": { - "shape": "FinalResponseString" + "accessDeniedException": { + "shape": "AccessDeniedException" + }, + "badGatewayException": { + "shape": "BadGatewayException" + }, + "conflictException": { + "shape": "ConflictException" + }, + "dependencyFailedException": { + "shape": "DependencyFailedException" + }, + "flowCompletionEvent": { + "shape": "FlowCompletionEvent" + }, + "flowOutputEvent": { + "shape": "FlowOutputEvent" + }, + "internalServerException": { + "shape": "InternalServerException" + }, + "resourceNotFoundException": { + "shape": "ResourceNotFoundException" + }, + "serviceQuotaExceededException": { + "shape": "ServiceQuotaExceededException" + }, + "throttlingException": { + "shape": "ThrottlingException" + }, + "validationException": { + "shape": "ValidationException" } }, "type": "structure" }, - "FinalResponseString": { - "sensitive": true, - "type": "string" - }, "Function": { "sensitive": true, "type": "string" @@ -624,6 +1023,58 @@ }, "type": "structure" }, + "GetAgentMemoryRequest": { + "members": { + "agentAliasId": { + "location": "uri", + "locationName": "agentAliasId", + "shape": "AgentAliasId" + }, + "agentId": { + "location": "uri", + "locationName": "agentId", + "shape": "AgentId" + }, + "maxItems": { + "location": "querystring", + "locationName": "maxItems", + "shape": "MaxResults" + }, + "memoryId": { + "location": "querystring", + "locationName": "memoryId", + "shape": "MemoryId" + }, + "memoryType": { + "location": "querystring", + "locationName": "memoryType", + "shape": "MemoryType" + }, + "nextToken": { + "location": "querystring", + "locationName": "nextToken", + "shape": "NextToken" + } + }, + "required": [ + "agentAliasId", + "agentId", + "memoryId", + "memoryType" + ], + "type": "structure" + }, + "GetAgentMemoryResponse": { + "members": { + "memoryContents": { + "shape": "Memories" + }, + "nextToken": { + "shape": "NextToken" + } + }, + "type": "structure" + }, "GuadrailAction": { "enum": [ "INTERVENED", @@ -1008,6 +1459,31 @@ }, "type": "structure" }, + "InputFile": { + "members": { + "name": { + "shape": "String" + }, + "source": { + "shape": "FileSource" + }, + "useCase": { + "shape": "FileUseCase" + } + }, + "required": [ + "name", + "source", + "useCase" + ], + "type": "structure" + }, + "InputFiles": { + "member": { + "shape": "InputFile" + }, + "type": "list" + }, "InputText": { "max": 25000000, "min": 0, @@ -1036,6 +1512,9 @@ "actionGroupInvocationInput": { "shape": "ActionGroupInvocationInput" }, + "codeInterpreterInvocationInput": { + "shape": "CodeInterpreterInvocationInput" + }, "invocationType": { "shape": "InvocationType" }, @@ -1085,7 +1564,8 @@ "enum": [ "ACTION_GROUP", "KNOWLEDGE_BASE", - "FINISH" + "FINISH", + "ACTION_GROUP_CODE_INTERPRETER" ], "type": "string" }, @@ -1110,6 +1590,9 @@ "inputText": { "shape": "InputText" }, + "memoryId": { + "shape": "MemoryId" + }, "sessionId": { "location": "uri", "locationName": "sessionId", @@ -1136,6 +1619,11 @@ "locationName": "x-amzn-bedrock-agent-content-type", "shape": "MimeType" }, + "memoryId": { + "location": "header", + "locationName": "x-amz-bedrock-agent-memory-id", + "shape": "MemoryId" + }, "sessionId": { "location": "header", "locationName": "x-amz-bedrock-agent-session-id", @@ -1150,12 +1638,69 @@ ], "type": "structure" }, + "InvokeFlowRequest": { + "members": { + "flowAliasIdentifier": { + "location": "uri", + "locationName": "flowAliasIdentifier", + "shape": "FlowAliasIdentifier" + }, + "flowIdentifier": { + "location": "uri", + "locationName": "flowIdentifier", + "shape": "FlowIdentifier" + }, + "inputs": { + "shape": "FlowInputs" + } + }, + "required": [ + "flowAliasIdentifier", + "flowIdentifier", + "inputs" + ], + "type": "structure" + }, + "InvokeFlowResponse": { + "members": { + "responseStream": { + "shape": "FlowResponseStream" + } + }, + "payload": "responseStream", + "required": [ + "responseStream" + ], + "type": "structure" + }, "KmsKeyArn": { "max": 2048, "min": 1, "pattern": "^arn:aws(|-cn|-us-gov):kms:[a-zA-Z0-9-]*:[0-9]{12}:key/[a-zA-Z0-9-]{36}$", "type": "string" }, + "KnowledgeBaseConfiguration": { + "members": { + "knowledgeBaseId": { + "shape": "KnowledgeBaseId" + }, + "retrievalConfiguration": { + "shape": "KnowledgeBaseRetrievalConfiguration" + } + }, + "required": [ + "knowledgeBaseId", + "retrievalConfiguration" + ], + "type": "structure" + }, + "KnowledgeBaseConfigurations": { + "member": { + "shape": "KnowledgeBaseConfiguration" + }, + "min": 1, + "type": "list" + }, "KnowledgeBaseId": { "max": 10, "min": 0, @@ -1248,6 +1793,9 @@ "modelArn": { "shape": "BedrockModelArn" }, + "orchestrationConfiguration": { + "shape": "OrchestrationConfiguration" + }, "retrievalConfiguration": { "shape": "KnowledgeBaseRetrievalConfiguration" } @@ -1282,6 +1830,12 @@ "LambdaArn": { "type": "string" }, + "MaxResults": { + "box": true, + "max": 1000, + "min": 1, + "type": "integer" + }, "MaxTokens": { "box": true, "max": 65536, @@ -1294,6 +1848,53 @@ "min": 0, "type": "integer" }, + "Memories": { + "member": { + "shape": "Memory" + }, + "type": "list" + }, + "Memory": { + "members": { + "sessionSummary": { + "shape": "MemorySessionSummary" + } + }, + "type": "structure", + "union": true + }, + "MemoryId": { + "max": 100, + "min": 2, + "pattern": "^[0-9a-zA-Z._:-]+$", + "type": "string" + }, + "MemorySessionSummary": { + "members": { + "memoryId": { + "shape": "MemoryId" + }, + "sessionExpiryTime": { + "shape": "DateTimestamp" + }, + "sessionId": { + "shape": "SessionId" + }, + "sessionStartTime": { + "shape": "DateTimestamp" + }, + "summaryText": { + "shape": "SummaryText" + } + }, + "type": "structure" + }, + "MemoryType": { + "enum": [ + "SESSION_SUMMARY" + ], + "type": "string" + }, "MimeType": { "type": "string" }, @@ -1330,6 +1931,26 @@ "pattern": "^\\S*$", "type": "string" }, + "NodeName": { + "pattern": "^[a-zA-Z]([_]?[0-9a-zA-Z]){0,99}$", + "type": "string" + }, + "NodeOutputName": { + "pattern": "^[a-zA-Z]([_]?[0-9a-zA-Z]){0,99}$", + "type": "string" + }, + "NodeType": { + "enum": [ + "FlowInputNode", + "FlowOutputNode", + "LambdaFunctionNode", + "KnowledgeBaseNode", + "PromptNode", + "ConditionNode", + "LexNode" + ], + "type": "string" + }, "NonBlankString": { "pattern": "^[\\s\\S]*$", "type": "string" @@ -1339,6 +1960,9 @@ "actionGroupInvocationOutput": { "shape": "ActionGroupInvocationOutput" }, + "codeInterpreterInvocationOutput": { + "shape": "CodeInterpreterInvocationOutput" + }, "finalResponse": { "shape": "FinalResponse" }, @@ -1358,6 +1982,17 @@ "sensitive": true, "type": "structure" }, + "OrchestrationConfiguration": { + "members": { + "queryTransformationConfiguration": { + "shape": "QueryTransformationConfiguration" + } + }, + "required": [ + "queryTransformationConfiguration" + ], + "type": "structure" + }, "OrchestrationTrace": { "members": { "invocationInput": { @@ -1377,6 +2012,29 @@ "type": "structure", "union": true }, + "OutputFile": { + "members": { + "bytes": { + "shape": "FileBody" + }, + "name": { + "shape": "String" + }, + "type": { + "shape": "MimeType" + } + }, + "sensitive": true, + "type": "structure" + }, + "OutputFiles": { + "max": 5, + "member": { + "shape": "OutputFile" + }, + "min": 0, + "type": "list" + }, "OutputString": { "sensitive": true, "type": "string" @@ -1535,6 +2193,23 @@ }, "type": "structure" }, + "QueryTransformationConfiguration": { + "members": { + "type": { + "shape": "QueryTransformationType" + } + }, + "required": [ + "type" + ], + "type": "structure" + }, + "QueryTransformationType": { + "enum": [ + "QUERY_DECOMPOSITION" + ], + "type": "string" + }, "RAGStopSequences": { "max": 4, "member": { @@ -1631,6 +2306,9 @@ "dependencyFailedException": { "shape": "DependencyFailedException" }, + "files": { + "shape": "FilePart" + }, "internalServerException": { "shape": "InternalServerException" }, @@ -1676,6 +2354,14 @@ "min": 2, "type": "list" }, + "RetrievalResultConfluenceLocation": { + "members": { + "url": { + "shape": "String" + } + }, + "type": "structure" + }, "RetrievalResultContent": { "members": { "text": { @@ -1690,11 +2376,23 @@ }, "RetrievalResultLocation": { "members": { + "confluenceLocation": { + "shape": "RetrievalResultConfluenceLocation" + }, "s3Location": { "shape": "RetrievalResultS3Location" }, + "salesforceLocation": { + "shape": "RetrievalResultSalesforceLocation" + }, + "sharePointLocation": { + "shape": "RetrievalResultSharePointLocation" + }, "type": { "shape": "RetrievalResultLocationType" + }, + "webLocation": { + "shape": "RetrievalResultWebLocation" } }, "required": [ @@ -1705,7 +2403,11 @@ }, "RetrievalResultLocationType": { "enum": [ - "S3" + "S3", + "WEB", + "CONFLUENCE", + "SALESFORCE", + "SHAREPOINT" ], "type": "string" }, @@ -1722,6 +2424,30 @@ }, "type": "structure" }, + "RetrievalResultSalesforceLocation": { + "members": { + "url": { + "shape": "String" + } + }, + "type": "structure" + }, + "RetrievalResultSharePointLocation": { + "members": { + "url": { + "shape": "String" + } + }, + "type": "structure" + }, + "RetrievalResultWebLocation": { + "members": { + "url": { + "shape": "String" + } + }, + "type": "structure" + }, "RetrieveAndGenerateConfiguration": { "members": { "externalSourcesConfiguration": { @@ -1913,6 +2639,17 @@ ], "type": "structure" }, + "S3ObjectFile": { + "members": { + "uri": { + "shape": "S3Uri" + } + }, + "required": [ + "uri" + ], + "type": "structure" + }, "S3Uri": { "max": 1024, "min": 1, @@ -1956,9 +2693,15 @@ }, "SessionState": { "members": { + "files": { + "shape": "InputFiles" + }, "invocationId": { "shape": "String" }, + "knowledgeBaseConfigurations": { + "shape": "KnowledgeBaseConfigurations" + }, "promptSessionAttributes": { "shape": "PromptSessionAttributesMap" }, @@ -2012,6 +2755,11 @@ "String": { "type": "string" }, + "SummaryText": { + "max": 25000000, + "min": 0, + "type": "string" + }, "Temperature": { "box": true, "max": 1, diff --git a/models/apis/bedrock-agent-runtime/2023-07-26/docs-2.json b/models/apis/bedrock-agent-runtime/2023-07-26/docs-2.json index 4017c0da51d..dff89f557b8 100644 --- a/models/apis/bedrock-agent-runtime/2023-07-26/docs-2.json +++ b/models/apis/bedrock-agent-runtime/2023-07-26/docs-2.json @@ -2,7 +2,10 @@ "version": "2.0", "service": "

Contains APIs related to model invocation and querying of knowledge bases.

", "operations": { - "InvokeAgent": "

The CLI doesn't support InvokeAgent.

Sends a prompt for the agent to process and respond to. Note the following fields for the request:

The response is returned in the bytes field of the chunk object.

", + "DeleteAgentMemory": "

Deletes memory from the specified memory identifier.

", + "GetAgentMemory": "

Gets the sessions stored in the memory of the agent.

", + "InvokeAgent": "

The CLI doesn't support streaming operations in Amazon Bedrock, including InvokeAgent.

Sends a prompt for the agent to process and respond to. Note the following fields for the request:

The response is returned in the bytes field of the chunk object.

", + "InvokeFlow": "

Invokes an alias of a flow to run the inputs that you specify and return the output of each node as a stream. If there's an error, the error is returned. For more information, see Test a flow in Amazon Bedrock in the Amazon Bedrock User Guide.

", "Retrieve": "

Queries a knowledge base and retrieves information from it.

", "RetrieveAndGenerate": "

Queries a knowledge base and generates responses based on the retrieved results. The response only cites sources that are relevant to the query.

" }, @@ -10,6 +13,7 @@ "AccessDeniedException": { "base": "

The request is denied because of missing access permissions. Check your permissions and retry your request.

", "refs": { + "FlowResponseStream$accessDeniedException": "

The request is denied because of missing access permissions. Check your permissions and retry your request.

", "ResponseStream$accessDeniedException": "

The request is denied because of missing access permissions. Check your permissions and retry your request.

" } }, @@ -59,6 +63,8 @@ "AgentAliasId": { "base": null, "refs": { + "DeleteAgentMemoryRequest$agentAliasId": "

The unique identifier of an alias of an agent.

", + "GetAgentMemoryRequest$agentAliasId": "

The unique identifier of an alias of an agent.

", "InvokeAgentRequest$agentAliasId": "

The alias of the agent to use.

", "TracePart$agentAliasId": "

The unique identifier of the alias of the agent.

" } @@ -66,6 +72,8 @@ "AgentId": { "base": null, "refs": { + "DeleteAgentMemoryRequest$agentId": "

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

", + "GetAgentMemoryRequest$agentId": "

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

", "InvokeAgentRequest$agentId": "

The unique identifier of the agent to use.

", "TracePart$agentId": "

The unique identifier of the agent.

" } @@ -129,6 +137,7 @@ "BadGatewayException": { "base": "

There was an issue with a dependency due to a server issue. Retry your request.

", "refs": { + "FlowResponseStream$badGatewayException": "

There was an issue with a dependency due to a server issue. Retry your request.

", "ResponseStream$badGatewayException": "

There was an issue with a dependency due to a server issue. Retry your request.

" } }, @@ -142,6 +151,7 @@ "Boolean": { "base": null, "refs": { + "CodeInterpreterInvocationOutput$executionTimeout": "

Indicates if the execution of the code timed out.

", "InvokeAgentRequest$enableTrace": "

Specifies whether to turn on the trace or not to track the agent's reasoning process. For more information, see Trace enablement.

", "InvokeAgentRequest$endSession": "

Specifies whether to end the session with the agent or not.

", "PreProcessingParsedResponse$isValid": "

Whether the user input is valid or not. If false, the agent doesn't proceed to orchestration.

" @@ -150,7 +160,8 @@ "ByteContentBlob": { "base": null, "refs": { - "ByteContentDoc$data": "

The byte value of the file to upload, encoded as a Base-64 string.

" + "ByteContentDoc$data": "

The byte value of the file to upload, encoded as a Base-64 string.

", + "ByteContentFile$data": "

The byte value of the file to attach, encoded as Base-64 string. The maximum size of all files that is attached is 10MB. You can attach a maximum of 5 files.

" } }, "ByteContentDoc": { @@ -159,6 +170,12 @@ "ExternalSource$byteContent": "

The identifier, contentType, and data of the external source wrapper object.

" } }, + "ByteContentFile": { + "base": "

The property contains the file to chat with, along with its attributes.

", + "refs": { + "FileSource$byteContent": "

The data and the text of the attached files.

" + } + }, "Citation": { "base": "

An object containing a segment of the generated response that is based on a source in the knowledge base, alongside information about the source.

This data type is used in the following API operations:

", "refs": { @@ -172,9 +189,22 @@ "RetrieveAndGenerateResponse$citations": "

A list of segments of the generated response that are based on sources in the knowledge base, alongside information about the sources.

" } }, + "CodeInterpreterInvocationInput": { + "base": "

Contains information about the code interpreter being invoked.

", + "refs": { + "InvocationInput$codeInterpreterInvocationInput": "

Contains information about the code interpreter to be invoked.

" + } + }, + "CodeInterpreterInvocationOutput": { + "base": "

Contains the JSON-formatted string returned by the API invoked by the code interpreter.

", + "refs": { + "Observation$codeInterpreterInvocationOutput": "

Contains the JSON-formatted string returned by the API invoked by the code interpreter.

" + } + }, "ConflictException": { "base": "

There was a conflict performing an operation. Resolve the conflict and retry your request.

", "refs": { + "FlowResponseStream$conflictException": "

There was a conflict performing an operation. Resolve the conflict and retry your request.

", "ResponseStream$conflictException": "

There was a conflict performing an operation. Resolve the conflict and retry your request.

" } }, @@ -203,18 +233,49 @@ "ModelInvocationInput$promptCreationMode": "

Specifies whether the default prompt template was OVERRIDDEN. If it was, the basePromptTemplate that was set in the PromptOverrideConfiguration object when the agent was created or updated is used instead.

" } }, + "DateTimestamp": { + "base": "

Time Stamp.

", + "refs": { + "MemorySessionSummary$sessionExpiryTime": "

The time when the memory duration for the session is set to end.

", + "MemorySessionSummary$sessionStartTime": "

The start time for this session.

" + } + }, + "DeleteAgentMemoryRequest": { + "base": null, + "refs": { + } + }, + "DeleteAgentMemoryResponse": { + "base": null, + "refs": { + } + }, "DependencyFailedException": { "base": "

There was an issue with a dependency. Check the resource configurations and retry the request.

", "refs": { + "FlowResponseStream$dependencyFailedException": "

There was an issue with a dependency. Check the resource configurations and retry the request.

", "ResponseStream$dependencyFailedException": "

There was an issue with a dependency. Check the resource configurations and retry the request.

" } }, + "Document": { + "base": null, + "refs": { + "FlowInputContent$document": "

The input for the flow input node.

", + "FlowOutputContent$document": "

A name for the output of the flow.

" + } + }, "Double": { "base": null, "refs": { "KnowledgeBaseRetrievalResult$score": "

The level of relevance of the result to the query.

" } }, + "ExecutionType": { + "base": null, + "refs": { + "ActionGroupInvocationInput$executionType": "

How fulfillment of the action is handled. For more information, see Handling fulfillment of the action.

" + } + }, "ExternalSource": { "base": "

The unique external source of the content contained in the wrapper object.

", "refs": { @@ -257,6 +318,43 @@ "Trace$failureTrace": "

Contains information about the failure of the interaction.

" } }, + "FileBody": { + "base": null, + "refs": { + "OutputFile$bytes": "

The byte count of files that contains response from code interpreter.

" + } + }, + "FilePart": { + "base": "

Contains intermediate response for code interpreter if any files have been generated.

", + "refs": { + "ResponseStream$files": "

Contains intermediate response for code interpreter if any files have been generated.

" + } + }, + "FileSource": { + "base": "

The source file of the content contained in the wrapper object.

", + "refs": { + "InputFile$source": "

Specifies where the files are located.

" + } + }, + "FileSourceType": { + "base": null, + "refs": { + "FileSource$sourceType": "

The source type of the files to attach.

" + } + }, + "FileUseCase": { + "base": null, + "refs": { + "InputFile$useCase": "

Specifies how the source files will be used by the code interpreter.

" + } + }, + "Files": { + "base": null, + "refs": { + "CodeInterpreterInvocationInput$files": "

Files that are uploaded for code interpreter to use.

", + "CodeInterpreterInvocationOutput$files": "

Contains output files, if generated by code execution.

" + } + }, "FilterAttribute": { "base": "

Specifies the name that the metadata attribute must match and the value to which to compare the value of the metadata attribute. For more information, see Query configurations.

This data type is used in the following API operations:

", "refs": { @@ -297,6 +395,66 @@ "FinalResponse$text": "

The text in the response to the user.

" } }, + "FlowAliasIdentifier": { + "base": null, + "refs": { + "InvokeFlowRequest$flowAliasIdentifier": "

The unique identifier of the flow alias.

" + } + }, + "FlowCompletionEvent": { + "base": "

Contains information about why a flow completed.

This data type is used in the following API operations:

", + "refs": { + "FlowResponseStream$flowCompletionEvent": "

Contains information about why the flow completed.

" + } + }, + "FlowCompletionReason": { + "base": null, + "refs": { + "FlowCompletionEvent$completionReason": "

The reason that the flow completed.

" + } + }, + "FlowIdentifier": { + "base": null, + "refs": { + "InvokeFlowRequest$flowIdentifier": "

The unique identifier of the flow.

" + } + }, + "FlowInput": { + "base": "

Contains information about an input into the flow and what to do with it.

This data type is used in the following API operations:

", + "refs": { + "FlowInputs$member": null + } + }, + "FlowInputContent": { + "base": "

Contains information about an input into the flow.

This data type is used in the following API operations:

", + "refs": { + "FlowInput$content": "

Contains information about an input into the flow.

" + } + }, + "FlowInputs": { + "base": null, + "refs": { + "InvokeFlowRequest$inputs": "

A list of objects, each containing information about an input into the flow.

" + } + }, + "FlowOutputContent": { + "base": "

Contains information about the output node.

This data type is used in the following API operations:

", + "refs": { + "FlowOutputEvent$content": "

The output of the node.

" + } + }, + "FlowOutputEvent": { + "base": "

Contains information about an output from flow invoction.

This data type is used in the following API operations:

", + "refs": { + "FlowResponseStream$flowOutputEvent": "

Contains information about an output from flow invocation.

" + } + }, + "FlowResponseStream": { + "base": "

The output of the flow.

This data type is used in the following API operations:

", + "refs": { + "InvokeFlowResponse$responseStream": "

The output of the flow, returned as a stream. If there's an error, the error is returned.

" + } + }, "Function": { "base": null, "refs": { @@ -336,7 +494,17 @@ "GenerationConfiguration": { "base": "

Contains configurations for response generation based on the knowledge base query results.

This data type is used in the following API operations:

", "refs": { - "KnowledgeBaseRetrieveAndGenerateConfiguration$generationConfiguration": "

Contains configurations for response generation based on the knowwledge base query results.

" + "KnowledgeBaseRetrieveAndGenerateConfiguration$generationConfiguration": "

Contains configurations for response generation based on the knowledge base query results.

" + } + }, + "GetAgentMemoryRequest": { + "base": null, + "refs": { + } + }, + "GetAgentMemoryResponse": { + "base": null, + "refs": { } }, "GuadrailAction": { @@ -560,6 +728,18 @@ "ModelInvocationInput$inferenceConfiguration": "

Specifications about the inference parameters that were provided alongside the prompt. These are specified in the PromptOverrideConfiguration object that was set when the agent was created or updated. For more information, see Inference parameters for foundation models.

" } }, + "InputFile": { + "base": "

Contains details of the source files.

", + "refs": { + "InputFiles$member": null + } + }, + "InputFiles": { + "base": null, + "refs": { + "SessionState$files": "

Contains information about the files used by code interpreter.

" + } + }, "InputText": { "base": null, "refs": { @@ -575,6 +755,7 @@ "InternalServerException": { "base": "

An internal server error occurred. Retry your request.

", "refs": { + "FlowResponseStream$internalServerException": "

An internal server error occurred. Retry your request.

", "ResponseStream$internalServerException": "

An internal server error occurred. Retry your request.

" } }, @@ -618,15 +799,38 @@ "refs": { } }, + "InvokeFlowRequest": { + "base": null, + "refs": { + } + }, + "InvokeFlowResponse": { + "base": null, + "refs": { + } + }, "KmsKeyArn": { "base": null, "refs": { "RetrieveAndGenerateSessionConfiguration$kmsKeyArn": "

The ARN of the KMS key encrypting the session.

" } }, + "KnowledgeBaseConfiguration": { + "base": "

Configurations to apply to a knowledge base attached to the agent during query. For more information, see Knowledge base retrieval configurations.

", + "refs": { + "KnowledgeBaseConfigurations$member": null + } + }, + "KnowledgeBaseConfigurations": { + "base": null, + "refs": { + "SessionState$knowledgeBaseConfigurations": "

An array of configurations, each of which applies to a knowledge base attached to the agent.

" + } + }, "KnowledgeBaseId": { "base": null, "refs": { + "KnowledgeBaseConfiguration$knowledgeBaseId": "

The unique identifier for a knowledge base attached to the agent.

", "KnowledgeBaseRetrieveAndGenerateConfiguration$knowledgeBaseId": "

The unique identifier of the knowledge base that is queried and the foundation model used for generation.

", "RetrieveRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to query.

" } @@ -662,8 +866,9 @@ } }, "KnowledgeBaseRetrievalConfiguration": { - "base": "

Contains configurations for the knowledge base query and retrieval process. For more information, see Query configurations.

This data type is used in the following API operations:

", + "base": "

Contains configurations for knowledge base query. For more information, see Query configurations.

This data type is used in the following API operations:

", "refs": { + "KnowledgeBaseConfiguration$retrievalConfiguration": "

The configurations to apply to the knowledge base during query. For more information, see Query configurations.

", "KnowledgeBaseRetrieveAndGenerateConfiguration$retrievalConfiguration": "

Contains configurations for how to retrieve and return the knowledge base query.

", "RetrieveRequest$retrievalConfiguration": "

Contains configurations for the knowledge base query and retrieval process. For more information, see Query configurations.

" } @@ -704,6 +909,12 @@ "ModelInvocationInput$overrideLambda": "

The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence.

" } }, + "MaxResults": { + "base": "

Max Results.

", + "refs": { + "GetAgentMemoryRequest$maxItems": "

The maximum number of items 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.

" + } + }, "MaxTokens": { "base": null, "refs": { @@ -716,10 +927,46 @@ "InferenceConfiguration$maximumLength": "

The maximum number of tokens allowed in the generated response.

" } }, + "Memories": { + "base": null, + "refs": { + "GetAgentMemoryResponse$memoryContents": "

Contains details of the sessions stored in the memory

" + } + }, + "Memory": { + "base": "

Contains sessions summaries.

", + "refs": { + "Memories$member": null + } + }, + "MemoryId": { + "base": null, + "refs": { + "DeleteAgentMemoryRequest$memoryId": "

The unique identifier of the memory.

", + "GetAgentMemoryRequest$memoryId": "

The unique identifier of the memory.

", + "InvokeAgentRequest$memoryId": "

The unique identifier of the agent memory.

", + "InvokeAgentResponse$memoryId": "

The unique identifier of the agent memory.

", + "MemorySessionSummary$memoryId": "

The unique identifier of the memory where the session summary is stored.

" + } + }, + "MemorySessionSummary": { + "base": "

Contains details of a session summary.

", + "refs": { + "Memory$sessionSummary": "

Contains summary of a session.

" + } + }, + "MemoryType": { + "base": null, + "refs": { + "GetAgentMemoryRequest$memoryType": "

The type of memory.

" + } + }, "MimeType": { "base": null, "refs": { - "InvokeAgentResponse$contentType": "

The MIME type of the input data in the request. The default value is application/json.

" + "ByteContentFile$mediaType": "

The MIME type of data contained in the file used for chat.

", + "InvokeAgentResponse$contentType": "

The MIME type of the input data in the request. The default value is application/json.

", + "OutputFile$type": "

The type of file that contains response from the code interpreter.

" } }, "ModelInvocationInput": { @@ -733,10 +980,31 @@ "NextToken": { "base": null, "refs": { + "GetAgentMemoryRequest$nextToken": "

If the total number of results is greater than the maxItems 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.

", + "GetAgentMemoryResponse$nextToken": "

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

", "RetrieveRequest$nextToken": "

If there are more results than can fit in the response, the response returns a nextToken. Use this token in the nextToken field of another request to retrieve the next batch of results.

", "RetrieveResponse$nextToken": "

If there are more results than can fit in the response, the response returns a nextToken. Use this token in the nextToken field of another request to retrieve the next batch of results.

" } }, + "NodeName": { + "base": null, + "refs": { + "FlowInput$nodeName": "

A name for the input of the flow input node.

", + "FlowOutputEvent$nodeName": "

The name of the node to which input was provided.

" + } + }, + "NodeOutputName": { + "base": null, + "refs": { + "FlowInput$nodeOutputName": "

A name for the output of the flow input node.

" + } + }, + "NodeType": { + "base": null, + "refs": { + "FlowOutputEvent$nodeType": "

The type of node to which input was provided.

" + } + }, "NonBlankString": { "base": null, "refs": { @@ -759,12 +1027,30 @@ "OrchestrationTrace$observation": "

Details about the observation (the output of the action group Lambda or knowledge base) made by the agent.

" } }, + "OrchestrationConfiguration": { + "base": "

Settings for how the model processes the prompt prior to retrieval and generation.

", + "refs": { + "KnowledgeBaseRetrieveAndGenerateConfiguration$orchestrationConfiguration": "

Settings for how the model processes the prompt prior to retrieval and generation.

" + } + }, "OrchestrationTrace": { "base": "

Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.

", "refs": { "Trace$orchestrationTrace": "

Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.

" } }, + "OutputFile": { + "base": "

Contains details of the response from code interpreter.

", + "refs": { + "OutputFiles$member": null + } + }, + "OutputFiles": { + "base": null, + "refs": { + "FilePart$files": "

Files containing intermediate response for the user.

" + } + }, "OutputString": { "base": null, "refs": { @@ -870,6 +1156,18 @@ "ApiContentMap$value": null } }, + "QueryTransformationConfiguration": { + "base": "

To split up the prompt and retrieve multiple sources, set the transformation type to QUERY_DECOMPOSITION.

", + "refs": { + "OrchestrationConfiguration$queryTransformationConfiguration": "

To split up the prompt and retrieve multiple sources, set the transformation type to QUERY_DECOMPOSITION.

" + } + }, + "QueryTransformationType": { + "base": null, + "refs": { + "QueryTransformationConfiguration$type": "

The type of transformation to apply to the prompt.

" + } + }, "RAGStopSequences": { "base": null, "refs": { @@ -910,6 +1208,7 @@ "ResourceNotFoundException": { "base": "

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

", "refs": { + "FlowResponseStream$resourceNotFoundException": "

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

", "ResponseStream$resourceNotFoundException": "

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

" } }, @@ -947,6 +1246,12 @@ "RetrievalFilter$orAll": "

Knowledge base data sources are returned if their metadata attributes fulfill at least one of the filter conditions inside this list.

" } }, + "RetrievalResultConfluenceLocation": { + "base": "

The Confluence data source location.

", + "refs": { + "RetrievalResultLocation$confluenceLocation": "

The Confluence data source location.

" + } + }, "RetrievalResultContent": { "base": "

Contains the cited text from the data source.

This data type is used in the following API operations:

", "refs": { @@ -955,7 +1260,7 @@ } }, "RetrievalResultLocation": { - "base": "

Contains information about the location of the data source.

This data type is used in the following API operations:

", + "base": "

Contains information about the data source location.

This data type is used in the following API operations:

", "refs": { "KnowledgeBaseRetrievalResult$location": "

Contains information about the location of the data source.

", "RetrievedReference$location": "

Contains information about the location of the data source.

" @@ -964,7 +1269,7 @@ "RetrievalResultLocationType": { "base": null, "refs": { - "RetrievalResultLocation$type": "

The type of the location of the data source.

" + "RetrievalResultLocation$type": "

The type of data source location.

" } }, "RetrievalResultMetadata": { @@ -987,9 +1292,27 @@ } }, "RetrievalResultS3Location": { - "base": "

Contains the S3 location of the data source.

This data type is used in the following API operations:

", + "base": "

The S3 data source location.

This data type is used in the following API operations:

", + "refs": { + "RetrievalResultLocation$s3Location": "

The S3 data source location.

" + } + }, + "RetrievalResultSalesforceLocation": { + "base": "

The Salesforce data source location.

", + "refs": { + "RetrievalResultLocation$salesforceLocation": "

The Salesforce data source location.

" + } + }, + "RetrievalResultSharePointLocation": { + "base": "

The SharePoint data source location.

", + "refs": { + "RetrievalResultLocation$sharePointLocation": "

The SharePoint data source location.

" + } + }, + "RetrievalResultWebLocation": { + "base": "

The web URL/URLs data source location.

", "refs": { - "RetrievalResultLocation$s3Location": "

Contains the S3 location of the data source.

" + "RetrievalResultLocation$webLocation": "

The web URL/URLs data source location.

" } }, "RetrieveAndGenerateConfiguration": { @@ -1079,10 +1402,17 @@ "ExternalSource$s3Location": "

The S3 location of the external source wrapper object.

" } }, + "S3ObjectFile": { + "base": "

Contains details of the s3 object where the source file is located.

", + "refs": { + "FileSource$s3Location": "

The s3 location of the files to attach.

" + } + }, "S3Uri": { "base": null, "refs": { - "S3ObjectDoc$uri": "

The file location of the S3 wrapper object.

" + "S3ObjectDoc$uri": "

The file location of the S3 wrapper object.

", + "S3ObjectFile$uri": "

The uri of the s3 object.

" } }, "SearchType": { @@ -1094,6 +1424,7 @@ "ServiceQuotaExceededException": { "base": "

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

", "refs": { + "FlowResponseStream$serviceQuotaExceededException": "

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

", "ResponseStream$serviceQuotaExceededException": "

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

" } }, @@ -1108,8 +1439,9 @@ "refs": { "InvokeAgentRequest$sessionId": "

The unique identifier of the session. Use the same value across requests to continue the same conversation.

", "InvokeAgentResponse$sessionId": "

The unique identifier of the session with the agent.

", - "RetrieveAndGenerateRequest$sessionId": "

The unique identifier of the session. Reuse the same value to continue the same session with the knowledge base.

", - "RetrieveAndGenerateResponse$sessionId": "

The unique identifier of the session. Reuse the same value to continue the same session with the knowledge base.

", + "MemorySessionSummary$sessionId": "

The identifier for this session.

", + "RetrieveAndGenerateRequest$sessionId": "

The unique identifier of the session. When you first make a RetrieveAndGenerate request, Amazon Bedrock automatically generates this value. You must reuse this value for all subsequent requests in the same conversational session. This value allows Amazon Bedrock to maintain context and knowledge from previous interactions. You can't explicitly set the sessionId yourself.

", + "RetrieveAndGenerateResponse$sessionId": "

The unique identifier of the session. When you first make a RetrieveAndGenerate request, Amazon Bedrock automatically generates this value. You must reuse this value for all subsequent requests in the same conversational session. This value allows Amazon Bedrock to maintain context and knowledge from previous interactions. You can't explicitly set the sessionId yourself.

", "TracePart$sessionId": "

The unique identifier of the session with the agent.

" } }, @@ -1152,6 +1484,7 @@ "String": { "base": null, "refs": { + "ActionGroupInvocationInput$invocationId": "

The unique identifier of the invocation. Only returned if the executionType is RETURN_CONTROL.

", "ApiContentMap$key": null, "ApiInvocationInput$actionGroup": "

The action group that the API operation belongs to.

", "ApiInvocationInput$httpMethod": "

The HTTP method of the API operation.

", @@ -1160,8 +1493,12 @@ "ApiParameter$value": "

The value of the parameter.

", "ApiResult$actionGroup": "

The action group that the API operation belongs to.

", "ApiResult$httpMethod": "

The HTTP method for the API operation.

", + "CodeInterpreterInvocationInput$code": "

The code for the code interpreter to use.

", + "CodeInterpreterInvocationOutput$executionError": "

Contains the error returned from code execution.

", + "CodeInterpreterInvocationOutput$executionOutput": "

Contains the successful output returned from code execution

", "ContentBody$body": "

The body of the API response.

", "ContentMap$key": null, + "Files$member": null, "FunctionInvocationInput$actionGroup": "

The action group that the function belongs to.

", "FunctionInvocationInput$function": "

The name of the function.

", "FunctionParameter$name": "

The name of the parameter.

", @@ -1176,6 +1513,8 @@ "GuardrailRegexFilter$name": "

The name details for the regex filter used in the Guardrail.

", "GuardrailRegexFilter$regex": "

The regex details for the regex filter used in the Guardrail.

", "GuardrailTopic$name": "

The name details on a specific topic in the Guardrail.

", + "InputFile$name": "

The name of the source file.

", + "OutputFile$name": "

The name of the file containing response from code interpreter.

", "Parameter$name": "

The name of the parameter.

", "Parameter$type": "

The type of the parameter.

", "Parameter$value": "

The value of the parameter.

", @@ -1183,8 +1522,12 @@ "PromptSessionAttributesMap$value": null, "RepromptResponse$text": "

The text reprompting the input.

", "ResponseBody$key": null, + "RetrievalResultConfluenceLocation$url": "

The Confluence host URL for the data source location.

", "RetrievalResultContent$text": "

The cited text from the data source.

", - "RetrievalResultS3Location$uri": "

The S3 URI of the data source.

", + "RetrievalResultS3Location$uri": "

The S3 URI for the data source location.

", + "RetrievalResultSalesforceLocation$url": "

The Salesforce host URL for the data source location.

", + "RetrievalResultSharePointLocation$url": "

The SharePoint site URL for the data source location.

", + "RetrievalResultWebLocation$url": "

The web URL/URLs for the data source location.

", "RetrieveAndGenerateOutput$text": "

The response generated from querying the knowledge base.

", "ReturnControlPayload$invocationId": "

The identifier of the action group invocation.

", "SessionAttributesMap$key": null, @@ -1194,6 +1537,12 @@ "TextResponsePart$text": "

The part of the generated text that contains a citation.

" } }, + "SummaryText": { + "base": null, + "refs": { + "MemorySessionSummary$summaryText": "

The summarized text for this session.

" + } + }, "Temperature": { "base": null, "refs": { @@ -1222,6 +1571,7 @@ "ThrottlingException": { "base": "

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

", "refs": { + "FlowResponseStream$throttlingException": "

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

", "ResponseStream$throttlingException": "

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

" } }, @@ -1278,6 +1628,7 @@ "ValidationException": { "base": "

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

", "refs": { + "FlowResponseStream$validationException": "

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

", "ResponseStream$validationException": "

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

" } }, diff --git a/models/apis/bedrock-agent-runtime/2023-07-26/paginators-1.json b/models/apis/bedrock-agent-runtime/2023-07-26/paginators-1.json index bd57dfbc67d..3b9d74ec369 100644 --- a/models/apis/bedrock-agent-runtime/2023-07-26/paginators-1.json +++ b/models/apis/bedrock-agent-runtime/2023-07-26/paginators-1.json @@ -1,5 +1,11 @@ { "pagination": { + "GetAgentMemory": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxItems", + "result_key": "memoryContents" + }, "Retrieve": { "input_token": "nextToken", "output_token": "nextToken", diff --git a/models/apis/bedrock-agent/2023-06-05/api-2.json b/models/apis/bedrock-agent/2023-06-05/api-2.json index ea46d63c1f1..08e1c77d4d6 100644 --- a/models/apis/bedrock-agent/2023-06-05/api-2.json +++ b/models/apis/bedrock-agent/2023-06-05/api-2.json @@ -111,6 +111,65 @@ ], "idempotent":true }, + "CreateFlow":{ + "name":"CreateFlow", + "http":{ + "method":"POST", + "requestUri":"/flows/", + "responseCode":201 + }, + "input":{"shape":"CreateFlowRequest"}, + "output":{"shape":"CreateFlowResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, + "CreateFlowAlias":{ + "name":"CreateFlowAlias", + "http":{ + "method":"POST", + "requestUri":"/flows/{flowIdentifier}/aliases", + "responseCode":201 + }, + "input":{"shape":"CreateFlowAliasRequest"}, + "output":{"shape":"CreateFlowAliasResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, + "CreateFlowVersion":{ + "name":"CreateFlowVersion", + "http":{ + "method":"POST", + "requestUri":"/flows/{flowIdentifier}/versions", + "responseCode":201 + }, + "input":{"shape":"CreateFlowVersionRequest"}, + "output":{"shape":"CreateFlowVersionResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, "CreateKnowledgeBase":{ "name":"CreateKnowledgeBase", "http":{ @@ -130,6 +189,45 @@ ], "idempotent":true }, + "CreatePrompt":{ + "name":"CreatePrompt", + "http":{ + "method":"POST", + "requestUri":"/prompts/", + "responseCode":201 + }, + "input":{"shape":"CreatePromptRequest"}, + "output":{"shape":"CreatePromptResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, + "CreatePromptVersion":{ + "name":"CreatePromptVersion", + "http":{ + "method":"POST", + "requestUri":"/prompts/{promptIdentifier}/versions", + "responseCode":201 + }, + "input":{"shape":"CreatePromptVersionRequest"}, + "output":{"shape":"CreatePromptVersionResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, "DeleteAgent":{ "name":"DeleteAgent", "http":{ @@ -224,6 +322,63 @@ ], "idempotent":true }, + "DeleteFlow":{ + "name":"DeleteFlow", + "http":{ + "method":"DELETE", + "requestUri":"/flows/{flowIdentifier}/", + "responseCode":200 + }, + "input":{"shape":"DeleteFlowRequest"}, + "output":{"shape":"DeleteFlowResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"} + ], + "idempotent":true + }, + "DeleteFlowAlias":{ + "name":"DeleteFlowAlias", + "http":{ + "method":"DELETE", + "requestUri":"/flows/{flowIdentifier}/aliases/{aliasIdentifier}", + "responseCode":200 + }, + "input":{"shape":"DeleteFlowAliasRequest"}, + "output":{"shape":"DeleteFlowAliasResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"} + ], + "idempotent":true + }, + "DeleteFlowVersion":{ + "name":"DeleteFlowVersion", + "http":{ + "method":"DELETE", + "requestUri":"/flows/{flowIdentifier}/versions/{flowVersion}/", + "responseCode":200 + }, + "input":{"shape":"DeleteFlowVersionRequest"}, + "output":{"shape":"DeleteFlowVersionResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"} + ], + "idempotent":true + }, "DeleteKnowledgeBase":{ "name":"DeleteKnowledgeBase", "http":{ @@ -243,6 +398,25 @@ ], "idempotent":true }, + "DeletePrompt":{ + "name":"DeletePrompt", + "http":{ + "method":"DELETE", + "requestUri":"/prompts/{promptIdentifier}/", + "responseCode":200 + }, + "input":{"shape":"DeletePromptRequest"}, + "output":{"shape":"DeletePromptResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"} + ], + "idempotent":true + }, "DisassociateAgentKnowledgeBase":{ "name":"DisassociateAgentKnowledgeBase", "http":{ @@ -364,6 +538,57 @@ {"shape":"ResourceNotFoundException"} ] }, + "GetFlow":{ + "name":"GetFlow", + "http":{ + "method":"GET", + "requestUri":"/flows/{flowIdentifier}/", + "responseCode":200 + }, + "input":{"shape":"GetFlowRequest"}, + "output":{"shape":"GetFlowResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, + "GetFlowAlias":{ + "name":"GetFlowAlias", + "http":{ + "method":"GET", + "requestUri":"/flows/{flowIdentifier}/aliases/{aliasIdentifier}", + "responseCode":200 + }, + "input":{"shape":"GetFlowAliasRequest"}, + "output":{"shape":"GetFlowAliasResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, + "GetFlowVersion":{ + "name":"GetFlowVersion", + "http":{ + "method":"GET", + "requestUri":"/flows/{flowIdentifier}/versions/{flowVersion}/", + "responseCode":200 + }, + "input":{"shape":"GetFlowVersionRequest"}, + "output":{"shape":"GetFlowVersionResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "GetIngestionJob":{ "name":"GetIngestionJob", "http":{ @@ -398,6 +623,23 @@ {"shape":"ResourceNotFoundException"} ] }, + "GetPrompt":{ + "name":"GetPrompt", + "http":{ + "method":"GET", + "requestUri":"/prompts/{promptIdentifier}/", + "responseCode":200 + }, + "input":{"shape":"GetPromptRequest"}, + "output":{"shape":"GetPromptResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "ListAgentActionGroups":{ "name":"ListAgentActionGroups", "http":{ @@ -499,6 +741,56 @@ {"shape":"ResourceNotFoundException"} ] }, + "ListFlowAliases":{ + "name":"ListFlowAliases", + "http":{ + "method":"GET", + "requestUri":"/flows/{flowIdentifier}/aliases", + "responseCode":200 + }, + "input":{"shape":"ListFlowAliasesRequest"}, + "output":{"shape":"ListFlowAliasesResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, + "ListFlowVersions":{ + "name":"ListFlowVersions", + "http":{ + "method":"GET", + "requestUri":"/flows/{flowIdentifier}/versions", + "responseCode":200 + }, + "input":{"shape":"ListFlowVersionsRequest"}, + "output":{"shape":"ListFlowVersionsResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, + "ListFlows":{ + "name":"ListFlows", + "http":{ + "method":"GET", + "requestUri":"/flows/", + "responseCode":200 + }, + "input":{"shape":"ListFlowsRequest"}, + "output":{"shape":"ListFlowsResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"} + ] + }, "ListIngestionJobs":{ "name":"ListIngestionJobs", "http":{ @@ -532,6 +824,23 @@ {"shape":"InternalServerException"} ] }, + "ListPrompts":{ + "name":"ListPrompts", + "http":{ + "method":"GET", + "requestUri":"/prompts/", + "responseCode":200 + }, + "input":{"shape":"ListPromptsRequest"}, + "output":{"shape":"ListPromptsResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "ListTagsForResource":{ "name":"ListTagsForResource", "http":{ @@ -568,6 +877,25 @@ {"shape":"ServiceQuotaExceededException"} ] }, + "PrepareFlow":{ + "name":"PrepareFlow", + "http":{ + "method":"POST", + "requestUri":"/flows/{flowIdentifier}/", + "responseCode":202 + }, + "input":{"shape":"PrepareFlowRequest"}, + "output":{"shape":"PrepareFlowResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ] + }, "StartIngestionJob":{ "name":"StartIngestionJob", "http":{ @@ -722,38 +1050,98 @@ ], "idempotent":true }, - "UpdateKnowledgeBase":{ - "name":"UpdateKnowledgeBase", + "UpdateFlow":{ + "name":"UpdateFlow", "http":{ "method":"PUT", - "requestUri":"/knowledgebases/{knowledgeBaseId}", - "responseCode":202 + "requestUri":"/flows/{flowIdentifier}/", + "responseCode":200 }, - "input":{"shape":"UpdateKnowledgeBaseRequest"}, - "output":{"shape":"UpdateKnowledgeBaseResponse"}, + "input":{"shape":"UpdateFlowRequest"}, + "output":{"shape":"UpdateFlowResponse"}, "errors":[ {"shape":"ThrottlingException"}, {"shape":"AccessDeniedException"}, {"shape":"ValidationException"}, {"shape":"InternalServerException"}, {"shape":"ResourceNotFoundException"}, - {"shape":"ConflictException"} + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} ], "idempotent":true - } - }, - "shapes":{ - "APISchema":{ - "type":"structure", - "members":{ - "payload":{"shape":"Payload"}, - "s3":{"shape":"S3Identifier"} - }, - "union":true }, - "AccessDeniedException":{ - "type":"structure", - "members":{ + "UpdateFlowAlias":{ + "name":"UpdateFlowAlias", + "http":{ + "method":"PUT", + "requestUri":"/flows/{flowIdentifier}/aliases/{aliasIdentifier}", + "responseCode":200 + }, + "input":{"shape":"UpdateFlowAliasRequest"}, + "output":{"shape":"UpdateFlowAliasResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + }, + "UpdateKnowledgeBase":{ + "name":"UpdateKnowledgeBase", + "http":{ + "method":"PUT", + "requestUri":"/knowledgebases/{knowledgeBaseId}", + "responseCode":202 + }, + "input":{"shape":"UpdateKnowledgeBaseRequest"}, + "output":{"shape":"UpdateKnowledgeBaseResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"} + ], + "idempotent":true + }, + "UpdatePrompt":{ + "name":"UpdatePrompt", + "http":{ + "method":"PUT", + "requestUri":"/prompts/{promptIdentifier}/", + "responseCode":200 + }, + "input":{"shape":"UpdatePromptRequest"}, + "output":{"shape":"UpdatePromptResponse"}, + "errors":[ + {"shape":"ThrottlingException"}, + {"shape":"AccessDeniedException"}, + {"shape":"ValidationException"}, + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ConflictException"}, + {"shape":"ServiceQuotaExceededException"} + ], + "idempotent":true + } + }, + "shapes":{ + "APISchema":{ + "type":"structure", + "members":{ + "payload":{"shape":"Payload"}, + "s3":{"shape":"S3Identifier"} + }, + "union":true + }, + "AccessDeniedException":{ + "type":"structure", + "members":{ "message":{"shape":"NonBlankString"} }, "error":{ @@ -772,7 +1160,10 @@ }, "ActionGroupSignature":{ "type":"string", - "enum":["AMAZON.UserInput"] + "enum":[ + "AMAZON.UserInput", + "AMAZON.CodeInterpreter" + ] }, "ActionGroupState":{ "type":"string", @@ -832,6 +1223,7 @@ "guardrailConfiguration":{"shape":"GuardrailConfiguration"}, "idleSessionTTLInSeconds":{"shape":"SessionTTL"}, "instruction":{"shape":"Instruction"}, + "memoryConfiguration":{"shape":"MemoryConfiguration"}, "preparedAt":{"shape":"DateTimestamp"}, "promptOverrideConfiguration":{"shape":"PromptOverrideConfiguration"}, "recommendedActions":{"shape":"RecommendedActions"}, @@ -972,6 +1364,13 @@ "min":0, "pattern":"^arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:agent/[0-9a-zA-Z]{10}$" }, + "AgentFlowNodeConfiguration":{ + "type":"structure", + "required":["agentAliasArn"], + "members":{ + "agentAliasArn":{"shape":"AgentAliasArn"} + } + }, "AgentKnowledgeBase":{ "type":"structure", "required":[ @@ -1083,6 +1482,7 @@ "guardrailConfiguration":{"shape":"GuardrailConfiguration"}, "idleSessionTTLInSeconds":{"shape":"SessionTTL"}, "instruction":{"shape":"Instruction"}, + "memoryConfiguration":{"shape":"MemoryConfiguration"}, "promptOverrideConfiguration":{"shape":"PromptOverrideConfiguration"}, "recommendedActions":{"shape":"RecommendedActions"}, "updatedAt":{"shape":"DateTimestamp"}, @@ -1148,7 +1548,8 @@ "BasePromptTemplate":{ "type":"string", "max":100000, - "min":1 + "min":1, + "sensitive":true }, "BedrockEmbeddingModelArn":{ "type":"string", @@ -1162,6 +1563,20 @@ "dimensions":{"shape":"Dimensions"} } }, + "BedrockFoundationModelConfiguration":{ + "type":"structure", + "required":["modelArn"], + "members":{ + "modelArn":{"shape":"BedrockModelArn"}, + "parsingPrompt":{"shape":"ParsingPrompt"} + } + }, + "BedrockModelArn":{ + "type":"string", + "max":2048, + "min":1, + "pattern":"^arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}::foundation-model/([a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}([.]?[a-z0-9-]{1,63})([:][a-z0-9-]{1,63}){0,2})$" + }, "Boolean":{ "type":"boolean", "box":true @@ -1177,21 +1592,30 @@ "required":["chunkingStrategy"], "members":{ "chunkingStrategy":{"shape":"ChunkingStrategy"}, - "fixedSizeChunkingConfiguration":{"shape":"FixedSizeChunkingConfiguration"} + "fixedSizeChunkingConfiguration":{"shape":"FixedSizeChunkingConfiguration"}, + "hierarchicalChunkingConfiguration":{"shape":"HierarchicalChunkingConfiguration"}, + "semanticChunkingConfiguration":{"shape":"SemanticChunkingConfiguration"} } }, "ChunkingStrategy":{ "type":"string", "enum":[ "FIXED_SIZE", - "NONE" + "NONE", + "HIERARCHICAL", + "SEMANTIC" ] }, "ClientToken":{ "type":"string", "max":256, "min":33, - "pattern":"^[a-zA-Z0-9](-*[a-zA-Z0-9])*$" + "pattern":"^[a-zA-Z0-9](-*[a-zA-Z0-9]){0,256}$" + }, + "CollectorFlowNodeConfiguration":{ + "type":"structure", + "members":{ + } }, "ColumnName":{ "type":"string", @@ -1199,6 +1623,13 @@ "min":0, "pattern":"^[a-zA-Z0-9_\\-]+$" }, + "ConditionFlowNodeConfiguration":{ + "type":"structure", + "required":["conditions"], + "members":{ + "conditions":{"shape":"FlowConditions"} + } + }, "ConflictException":{ "type":"structure", "members":{ @@ -1210,6 +1641,58 @@ }, "exception":true }, + "ConfluenceAuthType":{ + "type":"string", + "enum":[ + "BASIC", + "OAUTH2_CLIENT_CREDENTIALS" + ] + }, + "ConfluenceCrawlerConfiguration":{ + "type":"structure", + "members":{ + "filterConfiguration":{"shape":"CrawlFilterConfiguration"} + } + }, + "ConfluenceDataSourceConfiguration":{ + "type":"structure", + "required":["sourceConfiguration"], + "members":{ + "crawlerConfiguration":{"shape":"ConfluenceCrawlerConfiguration"}, + "sourceConfiguration":{"shape":"ConfluenceSourceConfiguration"} + } + }, + "ConfluenceHostType":{ + "type":"string", + "enum":["SAAS"] + }, + "ConfluenceSourceConfiguration":{ + "type":"structure", + "required":[ + "authType", + "credentialsSecretArn", + "hostType", + "hostUrl" + ], + "members":{ + "authType":{"shape":"ConfluenceAuthType"}, + "credentialsSecretArn":{"shape":"SecretArn"}, + "hostType":{"shape":"ConfluenceHostType"}, + "hostUrl":{"shape":"HttpsUrl"} + } + }, + "CrawlFilterConfiguration":{ + "type":"structure", + "required":["type"], + "members":{ + "patternObjectFilter":{"shape":"PatternObjectFilterConfiguration"}, + "type":{"shape":"CrawlFilterConfigurationType"} + } + }, + "CrawlFilterConfigurationType":{ + "type":"string", + "enum":["PATTERN"] + }, "CreateAgentActionGroupRequest":{ "type":"structure", "required":[ @@ -1293,6 +1776,7 @@ "guardrailConfiguration":{"shape":"GuardrailConfiguration"}, "idleSessionTTLInSeconds":{"shape":"SessionTTL"}, "instruction":{"shape":"Instruction"}, + "memoryConfiguration":{"shape":"MemoryConfiguration"}, "promptOverrideConfiguration":{"shape":"PromptOverrideConfiguration"}, "tags":{"shape":"TagsMap"} } @@ -1336,6 +1820,136 @@ "dataSource":{"shape":"DataSource"} } }, + "CreateFlowAliasRequest":{ + "type":"structure", + "required":[ + "flowIdentifier", + "name", + "routingConfiguration" + ], + "members":{ + "clientToken":{ + "shape":"ClientToken", + "idempotencyToken":true + }, + "description":{"shape":"Description"}, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"}, + "tags":{"shape":"TagsMap"} + } + }, + "CreateFlowAliasResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "flowId", + "id", + "name", + "routingConfiguration", + "updatedAt" + ], + "members":{ + "arn":{"shape":"FlowAliasArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"Description"}, + "flowId":{"shape":"FlowId"}, + "id":{"shape":"FlowAliasId"}, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"}, + "updatedAt":{"shape":"DateTimestamp"} + } + }, + "CreateFlowRequest":{ + "type":"structure", + "required":[ + "executionRoleArn", + "name" + ], + "members":{ + "clientToken":{ + "shape":"ClientToken", + "idempotencyToken":true + }, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "name":{"shape":"FlowName"}, + "tags":{"shape":"TagsMap"} + } + }, + "CreateFlowResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "executionRoleArn", + "id", + "name", + "status", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "updatedAt":{"shape":"DateTimestamp"}, + "version":{"shape":"DraftVersion"} + } + }, + "CreateFlowVersionRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "clientToken":{ + "shape":"ClientToken", + "idempotencyToken":true + }, + "description":{"shape":"FlowDescription"}, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + } + } + }, + "CreateFlowVersionResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "executionRoleArn", + "id", + "name", + "status", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "version":{"shape":"NumericalVersion"} + } + }, "CreateKnowledgeBaseRequest":{ "type":"structure", "required":[ @@ -1364,6 +1978,85 @@ "knowledgeBase":{"shape":"KnowledgeBase"} } }, + "CreatePromptRequest":{ + "type":"structure", + "required":["name"], + "members":{ + "clientToken":{ + "shape":"ClientToken", + "idempotencyToken":true + }, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "name":{"shape":"PromptName"}, + "tags":{"shape":"TagsMap"}, + "variants":{"shape":"PromptVariantList"} + } + }, + "CreatePromptResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"PromptArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "id":{"shape":"PromptId"}, + "name":{"shape":"PromptName"}, + "updatedAt":{"shape":"DateTimestamp"}, + "variants":{"shape":"PromptVariantList"}, + "version":{"shape":"Version"} + } + }, + "CreatePromptVersionRequest":{ + "type":"structure", + "required":["promptIdentifier"], + "members":{ + "clientToken":{ + "shape":"ClientToken", + "idempotencyToken":true + }, + "description":{"shape":"PromptDescription"}, + "promptIdentifier":{ + "shape":"PromptIdentifier", + "location":"uri", + "locationName":"promptIdentifier" + }, + "tags":{"shape":"TagsMap"} + } + }, + "CreatePromptVersionResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"PromptArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "id":{"shape":"PromptId"}, + "name":{"shape":"PromptName"}, + "updatedAt":{"shape":"DateTimestamp"}, + "variants":{"shape":"PromptVariantList"}, + "version":{"shape":"Version"} + } + }, "CreationMode":{ "type":"string", "enum":[ @@ -1375,6 +2068,17 @@ "type":"string", "enum":["RETURN_CONTROL"] }, + "CustomTransformationConfiguration":{ + "type":"structure", + "required":[ + "intermediateStorage", + "transformations" + ], + "members":{ + "intermediateStorage":{"shape":"IntermediateStorage"}, + "transformations":{"shape":"Transformations"} + } + }, "DataDeletionPolicy":{ "type":"string", "enum":[ @@ -1412,8 +2116,12 @@ "type":"structure", "required":["type"], "members":{ + "confluenceConfiguration":{"shape":"ConfluenceDataSourceConfiguration"}, "s3Configuration":{"shape":"S3DataSourceConfiguration"}, - "type":{"shape":"DataSourceType"} + "salesforceConfiguration":{"shape":"SalesforceDataSourceConfiguration"}, + "sharePointConfiguration":{"shape":"SharePointDataSourceConfiguration"}, + "type":{"shape":"DataSourceType"}, + "webConfiguration":{"shape":"WebDataSourceConfiguration"} } }, "DataSourceStatus":{ @@ -1448,7 +2156,13 @@ }, "DataSourceType":{ "type":"string", - "enum":["S3"] + "enum":[ + "S3", + "WEB", + "CONFLUENCE", + "SALESFORCE", + "SHAREPOINT" + ] }, "DateTimestamp":{ "type":"timestamp", @@ -1617,11 +2331,99 @@ "status":{"shape":"DataSourceStatus"} } }, - "DeleteKnowledgeBaseRequest":{ + "DeleteFlowAliasRequest":{ "type":"structure", - "required":["knowledgeBaseId"], + "required":[ + "aliasIdentifier", + "flowIdentifier" + ], "members":{ - "knowledgeBaseId":{ + "aliasIdentifier":{ + "shape":"FlowAliasIdentifier", + "location":"uri", + "locationName":"aliasIdentifier" + }, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + } + } + }, + "DeleteFlowAliasResponse":{ + "type":"structure", + "required":[ + "flowId", + "id" + ], + "members":{ + "flowId":{"shape":"FlowId"}, + "id":{"shape":"FlowAliasId"} + } + }, + "DeleteFlowRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "skipResourceInUseCheck":{ + "shape":"Boolean", + "location":"querystring", + "locationName":"skipResourceInUseCheck" + } + } + }, + "DeleteFlowResponse":{ + "type":"structure", + "required":["id"], + "members":{ + "id":{"shape":"FlowId"} + } + }, + "DeleteFlowVersionRequest":{ + "type":"structure", + "required":[ + "flowIdentifier", + "flowVersion" + ], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "flowVersion":{ + "shape":"NumericalVersion", + "location":"uri", + "locationName":"flowVersion" + }, + "skipResourceInUseCheck":{ + "shape":"Boolean", + "location":"querystring", + "locationName":"skipResourceInUseCheck" + } + } + }, + "DeleteFlowVersionResponse":{ + "type":"structure", + "required":[ + "id", + "version" + ], + "members":{ + "id":{"shape":"Id"}, + "version":{"shape":"NumericalVersion"} + } + }, + "DeleteKnowledgeBaseRequest":{ + "type":"structure", + "required":["knowledgeBaseId"], + "members":{ + "knowledgeBaseId":{ "shape":"Id", "location":"uri", "locationName":"knowledgeBaseId" @@ -1639,6 +2441,30 @@ "status":{"shape":"KnowledgeBaseStatus"} } }, + "DeletePromptRequest":{ + "type":"structure", + "required":["promptIdentifier"], + "members":{ + "promptIdentifier":{ + "shape":"PromptIdentifier", + "location":"uri", + "locationName":"promptIdentifier" + }, + "promptVersion":{ + "shape":"NumericalVersion", + "location":"querystring", + "locationName":"promptVersion" + } + } + }, + "DeletePromptResponse":{ + "type":"structure", + "required":["id"], + "members":{ + "id":{"shape":"PromptId"}, + "version":{"shape":"NumericalVersion"} + } + }, "Description":{ "type":"string", "max":200, @@ -1692,6 +2518,12 @@ "bedrockEmbeddingModelConfiguration":{"shape":"BedrockEmbeddingModelConfiguration"} } }, + "EnabledMemoryTypes":{ + "type":"list", + "member":{"shape":"MemoryType"}, + "max":1, + "min":1 + }, "FailureReason":{ "type":"string", "max":2048, @@ -1709,6 +2541,25 @@ "min":0, "pattern":"^.*$" }, + "FilterList":{ + "type":"list", + "member":{"shape":"FilterPattern"}, + "max":25, + "min":1, + "sensitive":true + }, + "FilterPattern":{ + "type":"string", + "max":1000, + "min":1, + "sensitive":true + }, + "FilteredObjectType":{ + "type":"string", + "max":50, + "min":1, + "sensitive":true + }, "FixedSizeChunkingConfiguration":{ "type":"structure", "required":[ @@ -1731,6 +2582,381 @@ "max":99, "min":1 }, + "FlowAliasArn":{ + "type":"string", + "pattern":"^arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10}/alias/(TSTALIASID|[0-9a-zA-Z]{10})$" + }, + "FlowAliasId":{ + "type":"string", + "pattern":"^(TSTALIASID|[0-9a-zA-Z]{10})$" + }, + "FlowAliasIdentifier":{ + "type":"string", + "pattern":"^(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10}/alias/[0-9a-zA-Z]{10})|(TSTALIASID|[0-9a-zA-Z]{10})$" + }, + "FlowAliasRoutingConfiguration":{ + "type":"list", + "member":{"shape":"FlowAliasRoutingConfigurationListItem"}, + "max":1, + "min":1 + }, + "FlowAliasRoutingConfigurationListItem":{ + "type":"structure", + "members":{ + "flowVersion":{"shape":"Version"} + } + }, + "FlowAliasSummaries":{ + "type":"list", + "member":{"shape":"FlowAliasSummary"}, + "max":10, + "min":0 + }, + "FlowAliasSummary":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "flowId", + "id", + "name", + "routingConfiguration", + "updatedAt" + ], + "members":{ + "arn":{"shape":"FlowAliasArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"Description"}, + "flowId":{"shape":"FlowId"}, + "id":{"shape":"FlowAliasId"}, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"}, + "updatedAt":{"shape":"DateTimestamp"} + } + }, + "FlowArn":{ + "type":"string", + "pattern":"^arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10}$" + }, + "FlowCondition":{ + "type":"structure", + "required":["name"], + "members":{ + "expression":{"shape":"FlowConditionExpression"}, + "name":{"shape":"FlowConditionName"} + }, + "sensitive":true + }, + "FlowConditionExpression":{ + "type":"string", + "max":64, + "min":1, + "sensitive":true + }, + "FlowConditionName":{ + "type":"string", + "pattern":"^[a-zA-Z]([_]?[0-9a-zA-Z]){1,50}$" + }, + "FlowConditionalConnectionConfiguration":{ + "type":"structure", + "required":["condition"], + "members":{ + "condition":{"shape":"FlowConditionName"} + } + }, + "FlowConditions":{ + "type":"list", + "member":{"shape":"FlowCondition"}, + "max":5, + "min":1, + "sensitive":true + }, + "FlowConnection":{ + "type":"structure", + "required":[ + "name", + "source", + "target", + "type" + ], + "members":{ + "configuration":{"shape":"FlowConnectionConfiguration"}, + "name":{"shape":"FlowConnectionName"}, + "source":{"shape":"FlowNodeName"}, + "target":{"shape":"FlowNodeName"}, + "type":{"shape":"FlowConnectionType"} + } + }, + "FlowConnectionConfiguration":{ + "type":"structure", + "members":{ + "conditional":{"shape":"FlowConditionalConnectionConfiguration"}, + "data":{"shape":"FlowDataConnectionConfiguration"} + }, + "union":true + }, + "FlowConnectionName":{ + "type":"string", + "pattern":"^[a-zA-Z]([_]?[0-9a-zA-Z]){1,100}$" + }, + "FlowConnectionType":{ + "type":"string", + "enum":[ + "Data", + "Conditional" + ] + }, + "FlowConnections":{ + "type":"list", + "member":{"shape":"FlowConnection"}, + "max":20, + "min":0 + }, + "FlowDataConnectionConfiguration":{ + "type":"structure", + "required":[ + "sourceOutput", + "targetInput" + ], + "members":{ + "sourceOutput":{"shape":"FlowNodeOutputName"}, + "targetInput":{"shape":"FlowNodeInputName"} + } + }, + "FlowDefinition":{ + "type":"structure", + "members":{ + "connections":{"shape":"FlowConnections"}, + "nodes":{"shape":"FlowNodes"} + } + }, + "FlowDescription":{ + "type":"string", + "max":200, + "min":1 + }, + "FlowExecutionRoleArn":{ + "type":"string", + "max":2048, + "min":0, + "pattern":"^arn:aws(-[^:]+)?:iam::([0-9]{12})?:role/(service-role/)?.+$" + }, + "FlowId":{ + "type":"string", + "pattern":"^[0-9a-zA-Z]{10}$" + }, + "FlowIdentifier":{ + "type":"string", + "pattern":"^(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:flow/[0-9a-zA-Z]{10})|([0-9a-zA-Z]{10})$" + }, + "FlowName":{ + "type":"string", + "pattern":"^([0-9a-zA-Z][_-]?){1,100}$" + }, + "FlowNode":{ + "type":"structure", + "required":[ + "name", + "type" + ], + "members":{ + "configuration":{"shape":"FlowNodeConfiguration"}, + "inputs":{"shape":"FlowNodeInputs"}, + "name":{"shape":"FlowNodeName"}, + "outputs":{"shape":"FlowNodeOutputs"}, + "type":{"shape":"FlowNodeType"} + } + }, + "FlowNodeConfiguration":{ + "type":"structure", + "members":{ + "agent":{"shape":"AgentFlowNodeConfiguration"}, + "collector":{"shape":"CollectorFlowNodeConfiguration"}, + "condition":{"shape":"ConditionFlowNodeConfiguration"}, + "input":{"shape":"InputFlowNodeConfiguration"}, + "iterator":{"shape":"IteratorFlowNodeConfiguration"}, + "knowledgeBase":{"shape":"KnowledgeBaseFlowNodeConfiguration"}, + "lambdaFunction":{"shape":"LambdaFunctionFlowNodeConfiguration"}, + "lex":{"shape":"LexFlowNodeConfiguration"}, + "output":{"shape":"OutputFlowNodeConfiguration"}, + "prompt":{"shape":"PromptFlowNodeConfiguration"}, + "retrieval":{"shape":"RetrievalFlowNodeConfiguration"}, + "storage":{"shape":"StorageFlowNodeConfiguration"} + }, + "union":true + }, + "FlowNodeIODataType":{ + "type":"string", + "enum":[ + "String", + "Number", + "Boolean", + "Object", + "Array" + ] + }, + "FlowNodeInput":{ + "type":"structure", + "required":[ + "expression", + "name", + "type" + ], + "members":{ + "expression":{"shape":"FlowNodeInputExpression"}, + "name":{"shape":"FlowNodeInputName"}, + "type":{"shape":"FlowNodeIODataType"} + } + }, + "FlowNodeInputExpression":{ + "type":"string", + "max":64, + "min":1, + "sensitive":true + }, + "FlowNodeInputName":{ + "type":"string", + "pattern":"^[a-zA-Z]([_]?[0-9a-zA-Z]){1,50}$" + }, + "FlowNodeInputs":{ + "type":"list", + "member":{"shape":"FlowNodeInput"}, + "max":5, + "min":0 + }, + "FlowNodeName":{ + "type":"string", + "pattern":"^[a-zA-Z]([_]?[0-9a-zA-Z]){1,50}$" + }, + "FlowNodeOutput":{ + "type":"structure", + "required":[ + "name", + "type" + ], + "members":{ + "name":{"shape":"FlowNodeOutputName"}, + "type":{"shape":"FlowNodeIODataType"} + } + }, + "FlowNodeOutputName":{ + "type":"string", + "pattern":"^[a-zA-Z]([_]?[0-9a-zA-Z]){1,50}$" + }, + "FlowNodeOutputs":{ + "type":"list", + "member":{"shape":"FlowNodeOutput"}, + "max":5, + "min":0 + }, + "FlowNodeType":{ + "type":"string", + "enum":[ + "Input", + "Output", + "KnowledgeBase", + "Condition", + "Lex", + "Prompt", + "LambdaFunction", + "Storage", + "Agent", + "Retrieval", + "Iterator", + "Collector" + ] + }, + "FlowNodes":{ + "type":"list", + "member":{"shape":"FlowNode"}, + "max":20, + "min":0, + "sensitive":true + }, + "FlowStatus":{ + "type":"string", + "enum":[ + "Failed", + "Prepared", + "Preparing", + "NotPrepared" + ] + }, + "FlowSummaries":{ + "type":"list", + "member":{"shape":"FlowSummary"}, + "max":10, + "min":0 + }, + "FlowSummary":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "status", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"FlowDescription"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "updatedAt":{"shape":"DateTimestamp"}, + "version":{"shape":"DraftVersion"} + } + }, + "FlowValidation":{ + "type":"structure", + "required":[ + "message", + "severity" + ], + "members":{ + "message":{"shape":"NonBlankString"}, + "severity":{"shape":"FlowValidationSeverity"} + } + }, + "FlowValidationSeverity":{ + "type":"string", + "enum":[ + "Warning", + "Error" + ] + }, + "FlowValidations":{ + "type":"list", + "member":{"shape":"FlowValidation"}, + "max":100, + "min":0 + }, + "FlowVersionSummaries":{ + "type":"list", + "member":{"shape":"FlowVersionSummary"}, + "max":10, + "min":0 + }, + "FlowVersionSummary":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "status", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "id":{"shape":"FlowId"}, + "status":{"shape":"FlowStatus"}, + "version":{"shape":"NumericalVersion"} + } + }, "Function":{ "type":"structure", "required":["name"], @@ -1916,6 +3142,128 @@ "dataSource":{"shape":"DataSource"} } }, + "GetFlowAliasRequest":{ + "type":"structure", + "required":[ + "aliasIdentifier", + "flowIdentifier" + ], + "members":{ + "aliasIdentifier":{ + "shape":"FlowAliasIdentifier", + "location":"uri", + "locationName":"aliasIdentifier" + }, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + } + } + }, + "GetFlowAliasResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "flowId", + "id", + "name", + "routingConfiguration", + "updatedAt" + ], + "members":{ + "arn":{"shape":"FlowAliasArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"Description"}, + "flowId":{"shape":"FlowId"}, + "id":{"shape":"FlowAliasId"}, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"}, + "updatedAt":{"shape":"DateTimestamp"} + } + }, + "GetFlowRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + } + } + }, + "GetFlowResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "executionRoleArn", + "id", + "name", + "status", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "updatedAt":{"shape":"DateTimestamp"}, + "validations":{"shape":"FlowValidations"}, + "version":{"shape":"DraftVersion"} + } + }, + "GetFlowVersionRequest":{ + "type":"structure", + "required":[ + "flowIdentifier", + "flowVersion" + ], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "flowVersion":{ + "shape":"NumericalVersion", + "location":"uri", + "locationName":"flowVersion" + } + } + }, + "GetFlowVersionResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "executionRoleArn", + "id", + "name", + "status", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "version":{"shape":"NumericalVersion"} + } + }, "GetIngestionJobRequest":{ "type":"structure", "required":[ @@ -1966,6 +3314,45 @@ "knowledgeBase":{"shape":"KnowledgeBase"} } }, + "GetPromptRequest":{ + "type":"structure", + "required":["promptIdentifier"], + "members":{ + "promptIdentifier":{ + "shape":"PromptIdentifier", + "location":"uri", + "locationName":"promptIdentifier" + }, + "promptVersion":{ + "shape":"Version", + "location":"querystring", + "locationName":"promptVersion" + } + } + }, + "GetPromptResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"PromptArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "id":{"shape":"PromptId"}, + "name":{"shape":"PromptName"}, + "updatedAt":{"shape":"DateTimestamp"}, + "variants":{"shape":"PromptVariantList"}, + "version":{"shape":"Version"} + } + }, "GuardrailConfiguration":{ "type":"structure", "members":{ @@ -1979,9 +3366,48 @@ "min":0, "pattern":"^(([a-z0-9]+)|(arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:guardrail/[a-z0-9]+))$" }, - "GuardrailVersion":{ + "GuardrailVersion":{ + "type":"string", + "pattern":"^(([0-9]{1,8})|(DRAFT))$" + }, + "HierarchicalChunkingConfiguration":{ + "type":"structure", + "required":[ + "levelConfigurations", + "overlapTokens" + ], + "members":{ + "levelConfigurations":{"shape":"HierarchicalChunkingLevelConfigurations"}, + "overlapTokens":{"shape":"HierarchicalChunkingConfigurationOverlapTokensInteger"} + } + }, + "HierarchicalChunkingConfigurationOverlapTokensInteger":{ + "type":"integer", + "box":true, + "min":1 + }, + "HierarchicalChunkingLevelConfiguration":{ + "type":"structure", + "required":["maxTokens"], + "members":{ + "maxTokens":{"shape":"HierarchicalChunkingLevelConfigurationMaxTokensInteger"} + } + }, + "HierarchicalChunkingLevelConfigurationMaxTokensInteger":{ + "type":"integer", + "box":true, + "max":8192, + "min":1 + }, + "HierarchicalChunkingLevelConfigurations":{ + "type":"list", + "member":{"shape":"HierarchicalChunkingLevelConfiguration"}, + "max":2, + "min":2 + }, + "HttpsUrl":{ "type":"string", - "pattern":"^(([0-9]{1,8})|(DRAFT))$" + "pattern":"^https://[A-Za-z0-9][^\\s]*$" }, "Id":{ "type":"string", @@ -2122,12 +3548,24 @@ "updatedAt":{"shape":"DateTimestamp"} } }, + "InputFlowNodeConfiguration":{ + "type":"structure", + "members":{ + } + }, "Instruction":{ "type":"string", "max":4000, "min":40, "sensitive":true }, + "IntermediateStorage":{ + "type":"structure", + "required":["s3Location"], + "members":{ + "s3Location":{"shape":"S3Location"} + } + }, "InternalServerException":{ "type":"structure", "members":{ @@ -2137,6 +3575,11 @@ "exception":true, "fault":true }, + "IteratorFlowNodeConfiguration":{ + "type":"structure", + "members":{ + } + }, "KmsKeyArn":{ "type":"string", "max":2048, @@ -2184,6 +3627,20 @@ "vectorKnowledgeBaseConfiguration":{"shape":"VectorKnowledgeBaseConfiguration"} } }, + "KnowledgeBaseFlowNodeConfiguration":{ + "type":"structure", + "required":["knowledgeBaseId"], + "members":{ + "knowledgeBaseId":{"shape":"KnowledgeBaseId"}, + "modelId":{"shape":"ModelIdentifier"} + } + }, + "KnowledgeBaseId":{ + "type":"string", + "max":10, + "min":0, + "pattern":"^[0-9a-zA-Z]+$" + }, "KnowledgeBaseRoleArn":{ "type":"string", "max":2048, @@ -2248,6 +3705,35 @@ "min":0, "pattern":"^arn:(aws[a-zA-Z-]*)?:lambda:[a-z]{2}(-gov)?-[a-z]+-\\d{1}:\\d{12}:function:[a-zA-Z0-9-_\\.]+(:(\\$LATEST|[a-zA-Z0-9-_]+))?$" }, + "LambdaFunctionFlowNodeConfiguration":{ + "type":"structure", + "required":["lambdaArn"], + "members":{ + "lambdaArn":{"shape":"LambdaArn"} + } + }, + "LexBotAliasArn":{ + "type":"string", + "max":78, + "min":0, + "pattern":"^arn:aws(|-us-gov):lex:[a-z]{2}(-gov)?-[a-z]+-\\d{1}:\\d{12}:bot-alias/[0-9a-zA-Z]+/[0-9a-zA-Z]+$" + }, + "LexBotLocaleId":{ + "type":"string", + "max":10, + "min":1 + }, + "LexFlowNodeConfiguration":{ + "type":"structure", + "required":[ + "botAliasArn", + "localeId" + ], + "members":{ + "botAliasArn":{"shape":"LexBotAliasArn"}, + "localeId":{"shape":"LexBotLocaleId"} + } + }, "ListAgentActionGroupsRequest":{ "type":"structure", "required":[ @@ -2384,6 +3870,87 @@ "nextToken":{"shape":"NextToken"} } }, + "ListFlowAliasesRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "maxResults":{ + "shape":"MaxResults", + "location":"querystring", + "locationName":"maxResults" + }, + "nextToken":{ + "shape":"NextToken", + "location":"querystring", + "locationName":"nextToken" + } + } + }, + "ListFlowAliasesResponse":{ + "type":"structure", + "required":["flowAliasSummaries"], + "members":{ + "flowAliasSummaries":{"shape":"FlowAliasSummaries"}, + "nextToken":{"shape":"NextToken"} + } + }, + "ListFlowVersionsRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "maxResults":{ + "shape":"MaxResults", + "location":"querystring", + "locationName":"maxResults" + }, + "nextToken":{ + "shape":"NextToken", + "location":"querystring", + "locationName":"nextToken" + } + } + }, + "ListFlowVersionsResponse":{ + "type":"structure", + "required":["flowVersionSummaries"], + "members":{ + "flowVersionSummaries":{"shape":"FlowVersionSummaries"}, + "nextToken":{"shape":"NextToken"} + } + }, + "ListFlowsRequest":{ + "type":"structure", + "members":{ + "maxResults":{ + "shape":"MaxResults", + "location":"querystring", + "locationName":"maxResults" + }, + "nextToken":{ + "shape":"NextToken", + "location":"querystring", + "locationName":"nextToken" + } + } + }, + "ListFlowsResponse":{ + "type":"structure", + "required":["flowSummaries"], + "members":{ + "flowSummaries":{"shape":"FlowSummaries"}, + "nextToken":{"shape":"NextToken"} + } + }, "ListIngestionJobsRequest":{ "type":"structure", "required":[ @@ -2430,6 +3997,34 @@ "nextToken":{"shape":"NextToken"} } }, + "ListPromptsRequest":{ + "type":"structure", + "members":{ + "maxResults":{ + "shape":"MaxResults", + "location":"querystring", + "locationName":"maxResults" + }, + "nextToken":{ + "shape":"NextToken", + "location":"querystring", + "locationName":"nextToken" + }, + "promptIdentifier":{ + "shape":"PromptIdentifier", + "location":"querystring", + "locationName":"promptIdentifier" + } + } + }, + "ListPromptsResponse":{ + "type":"structure", + "required":["promptSummaries"], + "members":{ + "nextToken":{"shape":"NextToken"}, + "promptSummaries":{"shape":"PromptSummaries"} + } + }, "ListTagsForResourceRequest":{ "type":"structure", "required":["resourceArn"], @@ -2459,6 +4054,24 @@ "max":4096, "min":0 }, + "MemoryConfiguration":{ + "type":"structure", + "required":["enabledMemoryTypes"], + "members":{ + "enabledMemoryTypes":{"shape":"EnabledMemoryTypes"}, + "storageDays":{"shape":"StorageDays"} + } + }, + "MemoryType":{ + "type":"string", + "enum":["SESSION_SUMMARY"] + }, + "Microsoft365TenantId":{ + "type":"string", + "max":36, + "min":36, + "pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$" + }, "ModelIdentifier":{ "type":"string", "max":2048, @@ -2584,6 +4197,11 @@ "min":0, "pattern":"^.*$" }, + "OutputFlowNodeConfiguration":{ + "type":"structure", + "members":{ + } + }, "ParameterDescription":{ "type":"string", "max":500, @@ -2603,6 +4221,53 @@ "key":{"shape":"Name"}, "value":{"shape":"ParameterDetail"} }, + "ParsingConfiguration":{ + "type":"structure", + "required":["parsingStrategy"], + "members":{ + "bedrockFoundationModelConfiguration":{"shape":"BedrockFoundationModelConfiguration"}, + "parsingStrategy":{"shape":"ParsingStrategy"} + } + }, + "ParsingPrompt":{ + "type":"structure", + "required":["parsingPromptText"], + "members":{ + "parsingPromptText":{"shape":"ParsingPromptText"} + } + }, + "ParsingPromptText":{ + "type":"string", + "max":10000, + "min":1 + }, + "ParsingStrategy":{ + "type":"string", + "enum":["BEDROCK_FOUNDATION_MODEL"] + }, + "PatternObjectFilter":{ + "type":"structure", + "required":["objectType"], + "members":{ + "exclusionFilters":{"shape":"FilterList"}, + "inclusionFilters":{"shape":"FilterList"}, + "objectType":{"shape":"FilteredObjectType"} + } + }, + "PatternObjectFilterConfiguration":{ + "type":"structure", + "required":["filters"], + "members":{ + "filters":{"shape":"PatternObjectFilterList"} + } + }, + "PatternObjectFilterList":{ + "type":"list", + "member":{"shape":"PatternObjectFilter"}, + "max":25, + "min":1, + "sensitive":true + }, "Payload":{ "type":"string", "sensitive":true @@ -2670,7 +4335,33 @@ "preparedAt":{"shape":"DateTimestamp"} } }, + "PrepareFlowRequest":{ + "type":"structure", + "required":["flowIdentifier"], + "members":{ + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + } + } + }, + "PrepareFlowResponse":{ + "type":"structure", + "required":[ + "id", + "status" + ], + "members":{ + "id":{"shape":"FlowId"}, + "status":{"shape":"FlowStatus"} + } + }, "PrimitiveLong":{"type":"long"}, + "PromptArn":{ + "type":"string", + "pattern":"^(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:prompt/[0-9a-zA-Z]{10}(?::[0-9]{1,5})?)$" + }, "PromptConfiguration":{ "type":"structure", "members":{ @@ -2688,6 +4379,99 @@ "max":10, "min":0 }, + "PromptDescription":{ + "type":"string", + "max":200, + "min":1 + }, + "PromptFlowNodeConfiguration":{ + "type":"structure", + "required":["sourceConfiguration"], + "members":{ + "sourceConfiguration":{"shape":"PromptFlowNodeSourceConfiguration"} + } + }, + "PromptFlowNodeInlineConfiguration":{ + "type":"structure", + "required":[ + "modelId", + "templateConfiguration", + "templateType" + ], + "members":{ + "inferenceConfiguration":{"shape":"PromptInferenceConfiguration"}, + "modelId":{"shape":"PromptModelIdentifier"}, + "templateConfiguration":{"shape":"PromptTemplateConfiguration"}, + "templateType":{"shape":"PromptTemplateType"} + } + }, + "PromptFlowNodeResourceConfiguration":{ + "type":"structure", + "required":["promptArn"], + "members":{ + "promptArn":{"shape":"PromptArn"} + } + }, + "PromptFlowNodeSourceConfiguration":{ + "type":"structure", + "members":{ + "inline":{"shape":"PromptFlowNodeInlineConfiguration"}, + "resource":{"shape":"PromptFlowNodeResourceConfiguration"} + }, + "union":true + }, + "PromptId":{ + "type":"string", + "pattern":"^[0-9a-zA-Z]{10}$" + }, + "PromptIdentifier":{ + "type":"string", + "pattern":"^([0-9a-zA-Z]{10})|(arn:aws:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:prompt/[0-9a-zA-Z]{10})(?::[0-9]{1,5})?$" + }, + "PromptInferenceConfiguration":{ + "type":"structure", + "members":{ + "text":{"shape":"PromptModelInferenceConfiguration"} + }, + "union":true + }, + "PromptInputVariable":{ + "type":"structure", + "members":{ + "name":{"shape":"PromptInputVariableName"} + } + }, + "PromptInputVariableName":{ + "type":"string", + "pattern":"^([0-9a-zA-Z][_-]?){1,100}$" + }, + "PromptInputVariablesList":{ + "type":"list", + "member":{"shape":"PromptInputVariable"}, + "max":5, + "min":0, + "sensitive":true + }, + "PromptModelIdentifier":{ + "type":"string", + "max":2048, + "min":1, + "pattern":"^(arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}:(([0-9]{12}:custom-model/[a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}/[a-z0-9]{12})|(:foundation-model/[a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}([.:]?[a-z0-9-]{1,63}))|([0-9]{12}:provisioned-model/[a-z0-9]{12})))|([a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}([.:]?[a-z0-9-]{1,63}))|(([0-9a-zA-Z][_-]?)+)$" + }, + "PromptModelInferenceConfiguration":{ + "type":"structure", + "members":{ + "maxTokens":{"shape":"MaximumLength"}, + "stopSequences":{"shape":"StopSequences"}, + "temperature":{"shape":"Temperature"}, + "topK":{"shape":"TopK"}, + "topP":{"shape":"TopP"} + } + }, + "PromptName":{ + "type":"string", + "pattern":"^([0-9a-zA-Z][_-]?){1,100}$" + }, "PromptOverrideConfiguration":{ "type":"structure", "required":["promptConfigurations"], @@ -2704,14 +4488,77 @@ "DISABLED" ] }, - "PromptType":{ + "PromptSummaries":{ + "type":"list", + "member":{"shape":"PromptSummary"}, + "max":10, + "min":0 + }, + "PromptSummary":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"PromptArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"PromptDescription"}, + "id":{"shape":"PromptId"}, + "name":{"shape":"PromptName"}, + "updatedAt":{"shape":"DateTimestamp"}, + "version":{"shape":"Version"} + } + }, + "PromptTemplateConfiguration":{ + "type":"structure", + "members":{ + "text":{"shape":"TextPromptTemplateConfiguration"} + }, + "union":true + }, + "PromptTemplateType":{ + "type":"string", + "enum":["TEXT"] + }, + "PromptType":{ + "type":"string", + "enum":[ + "PRE_PROCESSING", + "ORCHESTRATION", + "POST_PROCESSING", + "KNOWLEDGE_BASE_RESPONSE_GENERATION" + ] + }, + "PromptVariant":{ + "type":"structure", + "required":[ + "name", + "templateType" + ], + "members":{ + "inferenceConfiguration":{"shape":"PromptInferenceConfiguration"}, + "modelId":{"shape":"PromptModelIdentifier"}, + "name":{"shape":"PromptVariantName"}, + "templateConfiguration":{"shape":"PromptTemplateConfiguration"}, + "templateType":{"shape":"PromptTemplateType"} + }, + "sensitive":true + }, + "PromptVariantList":{ + "type":"list", + "member":{"shape":"PromptVariant"}, + "max":3, + "min":0, + "sensitive":true + }, + "PromptVariantName":{ "type":"string", - "enum":[ - "PRE_PROCESSING", - "ORCHESTRATION", - "POST_PROCESSING", - "KNOWLEDGE_BASE_RESPONSE_GENERATION" - ] + "pattern":"^([0-9a-zA-Z][_-]?){1,100}$" }, "ProvisionedModelIdentifier":{ "type":"string", @@ -2829,6 +4676,27 @@ }, "exception":true }, + "RetrievalFlowNodeConfiguration":{ + "type":"structure", + "required":["serviceConfiguration"], + "members":{ + "serviceConfiguration":{"shape":"RetrievalFlowNodeServiceConfiguration"} + } + }, + "RetrievalFlowNodeS3Configuration":{ + "type":"structure", + "required":["bucketName"], + "members":{ + "bucketName":{"shape":"S3BucketName"} + } + }, + "RetrievalFlowNodeServiceConfiguration":{ + "type":"structure", + "members":{ + "s3":{"shape":"RetrievalFlowNodeS3Configuration"} + }, + "union":true + }, "S3BucketArn":{ "type":"string", "max":2048, @@ -2841,6 +4709,12 @@ "min":3, "pattern":"^[a-z0-9][\\.\\-a-z0-9]{1,61}[a-z0-9]$" }, + "S3BucketUri":{ + "type":"string", + "max":2048, + "min":1, + "pattern":"^s3://.{1,128}$" + }, "S3DataSourceConfiguration":{ "type":"structure", "required":["bucketArn"], @@ -2857,6 +4731,13 @@ "s3ObjectKey":{"shape":"S3ObjectKey"} } }, + "S3Location":{ + "type":"structure", + "required":["uri"], + "members":{ + "uri":{"shape":"S3BucketUri"} + } + }, "S3ObjectKey":{ "type":"string", "max":1024, @@ -2866,7 +4747,8 @@ "S3Prefix":{ "type":"string", "max":300, - "min":1 + "min":1, + "sensitive":true }, "S3Prefixes":{ "type":"list", @@ -2874,10 +4756,83 @@ "max":1, "min":1 }, + "SalesforceAuthType":{ + "type":"string", + "enum":["OAUTH2_CLIENT_CREDENTIALS"] + }, + "SalesforceCrawlerConfiguration":{ + "type":"structure", + "members":{ + "filterConfiguration":{"shape":"CrawlFilterConfiguration"} + } + }, + "SalesforceDataSourceConfiguration":{ + "type":"structure", + "required":["sourceConfiguration"], + "members":{ + "crawlerConfiguration":{"shape":"SalesforceCrawlerConfiguration"}, + "sourceConfiguration":{"shape":"SalesforceSourceConfiguration"} + } + }, + "SalesforceSourceConfiguration":{ + "type":"structure", + "required":[ + "authType", + "credentialsSecretArn", + "hostUrl" + ], + "members":{ + "authType":{"shape":"SalesforceAuthType"}, + "credentialsSecretArn":{"shape":"SecretArn"}, + "hostUrl":{"shape":"HttpsUrl"} + } + }, "SecretArn":{ "type":"string", "pattern":"^arn:aws(|-cn|-us-gov):secretsmanager:[a-z0-9-]{1,20}:([0-9]{12}|):secret:[a-zA-Z0-9!/_+=.@-]{1,512}$" }, + "SeedUrl":{ + "type":"structure", + "members":{ + "url":{"shape":"Url"} + } + }, + "SeedUrls":{ + "type":"list", + "member":{"shape":"SeedUrl"}, + "max":100, + "min":1 + }, + "SemanticChunkingConfiguration":{ + "type":"structure", + "required":[ + "breakpointPercentileThreshold", + "bufferSize", + "maxTokens" + ], + "members":{ + "breakpointPercentileThreshold":{"shape":"SemanticChunkingConfigurationBreakpointPercentileThresholdInteger"}, + "bufferSize":{"shape":"SemanticChunkingConfigurationBufferSizeInteger"}, + "maxTokens":{"shape":"SemanticChunkingConfigurationMaxTokensInteger"} + } + }, + "SemanticChunkingConfigurationBreakpointPercentileThresholdInteger":{ + "type":"integer", + "box":true, + "max":99, + "min":50 + }, + "SemanticChunkingConfigurationBufferSizeInteger":{ + "type":"integer", + "box":true, + "max":1, + "min":0 + }, + "SemanticChunkingConfigurationMaxTokensInteger":{ + "type":"integer", + "box":true, + "min":1 + }, "ServerSideEncryptionConfiguration":{ "type":"structure", "members":{ @@ -2901,6 +4856,57 @@ "max":3600, "min":60 }, + "SharePointAuthType":{ + "type":"string", + "enum":["OAUTH2_CLIENT_CREDENTIALS"] + }, + "SharePointCrawlerConfiguration":{ + "type":"structure", + "members":{ + "filterConfiguration":{"shape":"CrawlFilterConfiguration"} + } + }, + "SharePointDataSourceConfiguration":{ + "type":"structure", + "required":["sourceConfiguration"], + "members":{ + "crawlerConfiguration":{"shape":"SharePointCrawlerConfiguration"}, + "sourceConfiguration":{"shape":"SharePointSourceConfiguration"} + } + }, + "SharePointDomain":{ + "type":"string", + "max":50, + "min":1 + }, + "SharePointHostType":{ + "type":"string", + "enum":["ONLINE"] + }, + "SharePointSiteUrls":{ + "type":"list", + "member":{"shape":"HttpsUrl"}, + "max":100, + "min":1 + }, + "SharePointSourceConfiguration":{ + "type":"structure", + "required":[ + "authType", + "credentialsSecretArn", + "domain", + "hostType", + "siteUrls" + ], + "members":{ + "authType":{"shape":"SharePointAuthType"}, + "credentialsSecretArn":{"shape":"SecretArn"}, + "domain":{"shape":"SharePointDomain"}, + "hostType":{"shape":"SharePointHostType"}, + "siteUrls":{"shape":"SharePointSiteUrls"}, + "tenantId":{"shape":"Microsoft365TenantId"} + } + }, "SortOrder":{ "type":"string", "enum":[ @@ -2939,6 +4945,10 @@ "ingestionJob":{"shape":"IngestionJob"} } }, + "StepType":{ + "type":"string", + "enum":["POST_CHUNKING"] + }, "StopSequences":{ "type":"list", "member":{"shape":"String"}, @@ -2957,6 +4967,33 @@ "type":{"shape":"KnowledgeBaseStorageType"} } }, + "StorageDays":{ + "type":"integer", + "box":true, + "max":30, + "min":0 + }, + "StorageFlowNodeConfiguration":{ + "type":"structure", + "required":["serviceConfiguration"], + "members":{ + "serviceConfiguration":{"shape":"StorageFlowNodeServiceConfiguration"} + } + }, + "StorageFlowNodeS3Configuration":{ + "type":"structure", + "required":["bucketName"], + "members":{ + "bucketName":{"shape":"S3BucketName"} + } + }, + "StorageFlowNodeServiceConfiguration":{ + "type":"structure", + "members":{ + "s3":{"shape":"StorageFlowNodeS3Configuration"} + }, + "union":true + }, "String":{"type":"string"}, "TagKey":{ "type":"string", @@ -3000,7 +5037,7 @@ "type":"string", "max":1011, "min":20, - "pattern":"(^arn:aws:bedrock:[a-zA-Z0-9-]+:/d{12}:(agent|agent-alias|knowledge-base)/[A-Z0-9]{10}(?:/[A-Z0-9]{10})?$)" + "pattern":"(^arn:aws:bedrock:[a-zA-Z0-9-]+:/d{12}:(agent|agent-alias|knowledge-base|flow|prompt)/[A-Z0-9]{10}(?:/[A-Z0-9]{10})?$|^arn:aws:bedrock:[a-zA-Z0-9-]+:/d{12}:flow/([A-Z0-9]{10})/alias/([A-Z0-9]{10})$|^arn:aws:bedrock:[a-zA-Z0-9-]+:/d{12}:prompt/([A-Z0-9]{10})?(?::/d+)?$)" }, "TagsMap":{ "type":"map", @@ -3013,6 +5050,21 @@ "max":1, "min":0 }, + "TextPrompt":{ + "type":"string", + "max":200000, + "min":1, + "sensitive":true + }, + "TextPromptTemplateConfiguration":{ + "type":"structure", + "required":["text"], + "members":{ + "inputVariables":{"shape":"PromptInputVariablesList"}, + "text":{"shape":"TextPrompt"} + }, + "sensitive":true + }, "ThrottlingException":{ "type":"structure", "members":{ @@ -3036,6 +5088,37 @@ "max":1, "min":0 }, + "Transformation":{ + "type":"structure", + "required":[ + "stepToApply", + "transformationFunction" + ], + "members":{ + "stepToApply":{"shape":"StepType"}, + "transformationFunction":{"shape":"TransformationFunction"} + } + }, + "TransformationFunction":{ + "type":"structure", + "required":["transformationLambdaConfiguration"], + "members":{ + "transformationLambdaConfiguration":{"shape":"TransformationLambdaConfiguration"} + } + }, + "TransformationLambdaConfiguration":{ + "type":"structure", + "required":["lambdaArn"], + "members":{ + "lambdaArn":{"shape":"LambdaArn"} + } + }, + "Transformations":{ + "type":"list", + "member":{"shape":"Transformation"}, + "max":1, + "min":1 + }, "Type":{ "type":"string", "enum":[ @@ -3196,6 +5279,7 @@ "guardrailConfiguration":{"shape":"GuardrailConfiguration"}, "idleSessionTTLInSeconds":{"shape":"SessionTTL"}, "instruction":{"shape":"Instruction"}, + "memoryConfiguration":{"shape":"MemoryConfiguration"}, "promptOverrideConfiguration":{"shape":"PromptOverrideConfiguration"} } }, @@ -3240,6 +5324,98 @@ "dataSource":{"shape":"DataSource"} } }, + "UpdateFlowAliasRequest":{ + "type":"structure", + "required":[ + "aliasIdentifier", + "flowIdentifier", + "name", + "routingConfiguration" + ], + "members":{ + "aliasIdentifier":{ + "shape":"FlowAliasIdentifier", + "location":"uri", + "locationName":"aliasIdentifier" + }, + "description":{"shape":"Description"}, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"} + } + }, + "UpdateFlowAliasResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "flowId", + "id", + "name", + "routingConfiguration", + "updatedAt" + ], + "members":{ + "arn":{"shape":"FlowAliasArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "description":{"shape":"Description"}, + "flowId":{"shape":"FlowId"}, + "id":{"shape":"FlowAliasId"}, + "name":{"shape":"Name"}, + "routingConfiguration":{"shape":"FlowAliasRoutingConfiguration"}, + "updatedAt":{"shape":"DateTimestamp"} + } + }, + "UpdateFlowRequest":{ + "type":"structure", + "required":[ + "executionRoleArn", + "flowIdentifier", + "name" + ], + "members":{ + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "flowIdentifier":{ + "shape":"FlowIdentifier", + "location":"uri", + "locationName":"flowIdentifier" + }, + "name":{"shape":"FlowName"} + } + }, + "UpdateFlowResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "executionRoleArn", + "id", + "name", + "status", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"FlowArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "definition":{"shape":"FlowDefinition"}, + "description":{"shape":"FlowDescription"}, + "executionRoleArn":{"shape":"FlowExecutionRoleArn"}, + "id":{"shape":"FlowId"}, + "name":{"shape":"FlowName"}, + "status":{"shape":"FlowStatus"}, + "updatedAt":{"shape":"DateTimestamp"}, + "version":{"shape":"DraftVersion"} + } + }, "UpdateKnowledgeBaseRequest":{ "type":"structure", "required":[ @@ -3269,6 +5445,58 @@ "knowledgeBase":{"shape":"KnowledgeBase"} } }, + "UpdatePromptRequest":{ + "type":"structure", + "required":[ + "name", + "promptIdentifier" + ], + "members":{ + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "name":{"shape":"PromptName"}, + "promptIdentifier":{ + "shape":"PromptIdentifier", + "location":"uri", + "locationName":"promptIdentifier" + }, + "variants":{"shape":"PromptVariantList"} + } + }, + "UpdatePromptResponse":{ + "type":"structure", + "required":[ + "arn", + "createdAt", + "id", + "name", + "updatedAt", + "version" + ], + "members":{ + "arn":{"shape":"PromptArn"}, + "createdAt":{"shape":"DateTimestamp"}, + "customerEncryptionKeyArn":{"shape":"KmsKeyArn"}, + "defaultVariant":{"shape":"PromptVariantName"}, + "description":{"shape":"PromptDescription"}, + "id":{"shape":"PromptId"}, + "name":{"shape":"PromptName"}, + "updatedAt":{"shape":"DateTimestamp"}, + "variants":{"shape":"PromptVariantList"}, + "version":{"shape":"Version"} + } + }, + "Url":{ + "type":"string", + "pattern":"^https?://[A-Za-z0-9][^\\s]*$" + }, + "UrlConfiguration":{ + "type":"structure", + "members":{ + "seedUrls":{"shape":"SeedUrls"} + } + }, "ValidationException":{ "type":"structure", "members":{ @@ -3299,7 +5527,9 @@ "VectorIngestionConfiguration":{ "type":"structure", "members":{ - "chunkingConfiguration":{"shape":"ChunkingConfiguration"} + "chunkingConfiguration":{"shape":"ChunkingConfiguration"}, + "customTransformationConfiguration":{"shape":"CustomTransformationConfiguration"}, + "parsingConfiguration":{"shape":"ParsingConfiguration"} } }, "VectorKnowledgeBaseConfiguration":{ @@ -3315,6 +5545,49 @@ "max":5, "min":1, "pattern":"^(DRAFT|[0-9]{0,4}[1-9][0-9]{0,4})$" + }, + "WebCrawlerConfiguration":{ + "type":"structure", + "members":{ + "crawlerLimits":{"shape":"WebCrawlerLimits"}, + "exclusionFilters":{"shape":"FilterList"}, + "inclusionFilters":{"shape":"FilterList"}, + "scope":{"shape":"WebScopeType"} + } + }, + "WebCrawlerLimits":{ + "type":"structure", + "members":{ + "rateLimit":{"shape":"WebCrawlerLimitsRateLimitInteger"} + } + }, + "WebCrawlerLimitsRateLimitInteger":{ + "type":"integer", + "box":true, + "max":300, + "min":1 + }, + "WebDataSourceConfiguration":{ + "type":"structure", + "required":["sourceConfiguration"], + "members":{ + "crawlerConfiguration":{"shape":"WebCrawlerConfiguration"}, + "sourceConfiguration":{"shape":"WebSourceConfiguration"} + } + }, + "WebScopeType":{ + "type":"string", + "enum":[ + "HOST_ONLY", + "SUBDOMAINS" + ] + }, + "WebSourceConfiguration":{ + "type":"structure", + "required":["urlConfiguration"], + "members":{ + "urlConfiguration":{"shape":"UrlConfiguration"} + } } } } diff --git a/models/apis/bedrock-agent/2023-06-05/docs-2.json b/models/apis/bedrock-agent/2023-06-05/docs-2.json index 615a1855e49..61154dfe691 100644 --- a/models/apis/bedrock-agent/2023-06-05/docs-2.json +++ b/models/apis/bedrock-agent/2023-06-05/docs-2.json @@ -3,17 +3,26 @@ "service": "

Describes the API operations for creating and managing Amazon Bedrock agents.

", "operations": { "AssociateAgentKnowledgeBase": "

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.

", - "CreateAgent": "

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": "

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. 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.

", + "CreateAgent": "

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": "

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.

", "CreateAgentAlias": "

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

", - "CreateDataSource": "

Sets up a data source to be added to a knowledge base.

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

", + "CreateDataSource": "

Creates a data source connector for a knowledge base.

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

", + "CreateFlow": "

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.

", + "CreateFlowAlias": "

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

", + "CreateFlowVersion": "

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.

", "CreateKnowledgeBase": "

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.

", + "CreatePrompt": "

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.

", + "CreatePromptVersion": "

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.

", "DeleteAgent": "

Deletes an agent.

", "DeleteAgentActionGroup": "

Deletes an action group in an agent.

", "DeleteAgentAlias": "

Deletes an alias of an agent.

", "DeleteAgentVersion": "

Deletes a version of an agent.

", "DeleteDataSource": "

Deletes a data source from a knowledge base.

", + "DeleteFlow": "

Deletes a flow.

", + "DeleteFlowAlias": "

Deletes an alias of a flow.

", + "DeleteFlowVersion": "

Deletes a version of a flow.

", "DeleteKnowledgeBase": "

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.

", + "DeletePrompt": "

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.

", "DisassociateAgentKnowledgeBase": "

Disassociates a knowledge base from an agent.

", "GetAgent": "

Gets information about an agent.

", "GetAgentActionGroup": "

Gets information about an action group for an agent.

", @@ -21,18 +30,27 @@ "GetAgentKnowledgeBase": "

Gets information about a knowledge base associated with an agent.

", "GetAgentVersion": "

Gets details about a version of an agent.

", "GetDataSource": "

Gets information about a data source.

", + "GetFlow": "

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

", + "GetFlowAlias": "

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

", + "GetFlowVersion": "

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

", "GetIngestionJob": "

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

", "GetKnowledgeBase": "

Gets information about a knoweldge base.

", + "GetPrompt": "

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.

", "ListAgentActionGroups": "

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

", "ListAgentAliases": "

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

", "ListAgentKnowledgeBases": "

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

", "ListAgentVersions": "

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

", "ListAgents": "

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

", "ListDataSources": "

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

", + "ListFlowAliases": "

Returns a list of aliases for a flow.

", + "ListFlowVersions": "

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

", + "ListFlows": "

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.

", "ListIngestionJobs": "

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

", "ListKnowledgeBases": "

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

", + "ListPrompts": "

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.

", "ListTagsForResource": "

List all the tags for the resource you specify.

", "PrepareAgent": "

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

", + "PrepareFlow": "

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.

", "StartIngestionJob": "

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

", "TagResource": "

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

", "UntagResource": "

Remove tags from a resource.

", @@ -40,8 +58,11 @@ "UpdateAgentActionGroup": "

Updates the configuration for an action group for an agent.

", "UpdateAgentAlias": "

Updates configurations for an alias of an agent.

", "UpdateAgentKnowledgeBase": "

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

", - "UpdateDataSource": "

Updates configurations for a data source.

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

", - "UpdateKnowledgeBase": "

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:

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.

" + "UpdateDataSource": "

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.

", + "UpdateFlow": "

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.

", + "UpdateFlowAlias": "

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.

", + "UpdateKnowledgeBase": "

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:

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.

", + "UpdatePrompt": "

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.

" }, "shapes": { "APISchema": { @@ -69,7 +90,7 @@ "base": null, "refs": { "AgentActionGroup$parentActionSignature": "

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.

", - "CreateAgentActionGroupRequest$parentActionGroupSignature": "

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.

", + "CreateAgentActionGroupRequest$parentActionGroupSignature": "

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.

", "UpdateAgentActionGroupRequest$parentActionGroupSignature": "

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.

" } }, @@ -121,7 +142,8 @@ "AgentAliasArn": { "base": null, "refs": { - "AgentAlias$agentAliasArn": "

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

" + "AgentAlias$agentAliasArn": "

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

", + "AgentFlowNodeConfiguration$agentAliasArn": "

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

" } }, "AgentAliasHistoryEvent": { @@ -190,6 +212,12 @@ "AgentVersion$agentArn": "

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

" } }, + "AgentFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$agent": "

Contains configurations for an agent node in your flow. Invokes an alias of an agent and returns the response.

" + } + }, "AgentKnowledgeBase": { "base": "

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

", "refs": { @@ -289,19 +317,33 @@ "EmbeddingModelConfiguration$bedrockEmbeddingModelConfiguration": "

The vector configuration details on the Bedrock embeddings model.

" } }, + "BedrockFoundationModelConfiguration": { + "base": "

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

", + "refs": { + "ParsingConfiguration$bedrockFoundationModelConfiguration": "

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

" + } + }, + "BedrockModelArn": { + "base": null, + "refs": { + "BedrockFoundationModelConfiguration$modelArn": "

The model's ARN.

" + } + }, "Boolean": { "base": null, "refs": { "DeleteAgentActionGroupRequest$skipResourceInUseCheck": "

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.

", "DeleteAgentRequest$skipResourceInUseCheck": "

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.

", "DeleteAgentVersionRequest$skipResourceInUseCheck": "

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.

", + "DeleteFlowRequest$skipResourceInUseCheck": "

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.

", + "DeleteFlowVersionRequest$skipResourceInUseCheck": "

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.

", "ParameterDetail$required": "

Whether the parameter is required for the agent to complete the function for action group invocation.

" } }, "BucketOwnerAccountId": { "base": null, "refs": { - "S3DataSourceConfiguration$bucketOwnerAccountId": "

The bucket account owner ID for the S3 bucket.

" + "S3DataSourceConfiguration$bucketOwnerAccountId": "

The account ID for the owner of the S3 bucket.

" } }, "ChunkingConfiguration": { @@ -313,7 +355,7 @@ "ChunkingStrategy": { "base": null, "refs": { - "ChunkingConfiguration$chunkingStrategy": "

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.

" + "ChunkingConfiguration$chunkingStrategy": "

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.

" } }, "ClientToken": { @@ -326,10 +368,21 @@ "CreateAgentAliasRequest$clientToken": "

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.

", "CreateAgentRequest$clientToken": "

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.

", "CreateDataSourceRequest$clientToken": "

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.

", + "CreateFlowAliasRequest$clientToken": "

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.

", + "CreateFlowRequest$clientToken": "

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.

", + "CreateFlowVersionRequest$clientToken": "

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.

", "CreateKnowledgeBaseRequest$clientToken": "

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.

", + "CreatePromptRequest$clientToken": "

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.

", + "CreatePromptVersionRequest$clientToken": "

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.

", "StartIngestionJobRequest$clientToken": "

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.

" } }, + "CollectorFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$collector": "

Contains configurations for a collector node in your flow. Collects an iteration of inputs and consolidates them into an array of outputs.

" + } + }, "ColumnName": { "base": null, "refs": { @@ -339,11 +392,61 @@ "RdsFieldMapping$vectorField": "

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

" } }, + "ConditionFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$condition": "

Contains configurations for a Condition node in your flow. Defines conditions that lead to different branches of the flow.

" + } + }, "ConflictException": { "base": "

There was a conflict performing an operation.

", "refs": { } }, + "ConfluenceAuthType": { + "base": null, + "refs": { + "ConfluenceSourceConfiguration$authType": "

The supported authentication type to authenticate and connect to your Confluence instance.

" + } + }, + "ConfluenceCrawlerConfiguration": { + "base": "

The configuration of the Confluence content. For example, configuring specific types of Confluence content.

", + "refs": { + "ConfluenceDataSourceConfiguration$crawlerConfiguration": "

The configuration of the Confluence content. For example, configuring specific types of Confluence content.

" + } + }, + "ConfluenceDataSourceConfiguration": { + "base": "

The configuration information to connect to Confluence as your data source.

", + "refs": { + "DataSourceConfiguration$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.

" + } + }, + "ConfluenceHostType": { + "base": null, + "refs": { + "ConfluenceSourceConfiguration$hostType": "

The supported host type, whether online/cloud or server/on-premises.

" + } + }, + "ConfluenceSourceConfiguration": { + "base": "

The endpoint information to connect to your Confluence data source.

", + "refs": { + "ConfluenceDataSourceConfiguration$sourceConfiguration": "

The endpoint information to connect to your Confluence data source.

" + } + }, + "CrawlFilterConfiguration": { + "base": "

The configuration of filtering the data source content. For example, configuring regular expression patterns to include or exclude certain content.

", + "refs": { + "ConfluenceCrawlerConfiguration$filterConfiguration": "

The configuration of filtering the Confluence content. For example, configuring regular expression patterns to include or exclude certain content.

", + "SalesforceCrawlerConfiguration$filterConfiguration": "

The configuration of filtering the Salesforce content. For example, configuring regular expression patterns to include or exclude certain content.

", + "SharePointCrawlerConfiguration$filterConfiguration": "

The configuration of filtering the SharePoint content. For example, configuring regular expression patterns to include or exclude certain content.

" + } + }, + "CrawlFilterConfigurationType": { + "base": null, + "refs": { + "CrawlFilterConfiguration$type": "

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.

" + } + }, "CreateAgentActionGroupRequest": { "base": null, "refs": { @@ -384,6 +487,36 @@ "refs": { } }, + "CreateFlowAliasRequest": { + "base": null, + "refs": { + } + }, + "CreateFlowAliasResponse": { + "base": null, + "refs": { + } + }, + "CreateFlowRequest": { + "base": null, + "refs": { + } + }, + "CreateFlowResponse": { + "base": null, + "refs": { + } + }, + "CreateFlowVersionRequest": { + "base": null, + "refs": { + } + }, + "CreateFlowVersionResponse": { + "base": null, + "refs": { + } + }, "CreateKnowledgeBaseRequest": { "base": null, "refs": { @@ -394,6 +527,26 @@ "refs": { } }, + "CreatePromptRequest": { + "base": null, + "refs": { + } + }, + "CreatePromptResponse": { + "base": null, + "refs": { + } + }, + "CreatePromptVersionRequest": { + "base": null, + "refs": { + } + }, + "CreatePromptVersionResponse": { + "base": null, + "refs": { + } + }, "CreationMode": { "base": null, "refs": { @@ -407,12 +560,18 @@ "ActionGroupExecutor$customControl": "

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

" } }, + "CustomTransformationConfiguration": { + "base": "

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.

", + "refs": { + "VectorIngestionConfiguration$customTransformationConfiguration": "

A custom document transformer for parsed data source documents.

" + } + }, "DataDeletionPolicy": { "base": null, "refs": { - "CreateDataSourceRequest$dataDeletionPolicy": "

The data deletion policy assigned to the data source.

", - "DataSource$dataDeletionPolicy": "

The data deletion policy for a data source.

", - "UpdateDataSourceRequest$dataDeletionPolicy": "

The data deletion policy of the updated data source.

" + "CreateDataSourceRequest$dataDeletionPolicy": "

The data deletion policy for the data source.

You can set the data deletion policy to:

", + "DataSource$dataDeletionPolicy": "

The data deletion policy for the data source.

", + "UpdateDataSourceRequest$dataDeletionPolicy": "

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

" } }, "DataSource": { @@ -424,11 +583,11 @@ } }, "DataSourceConfiguration": { - "base": "

Contains details about how a data source is stored.

", + "base": "

The connection configuration for the data source.

", "refs": { - "CreateDataSourceRequest$dataSourceConfiguration": "

Contains metadata about where the data source is stored.

", - "DataSource$dataSourceConfiguration": "

Contains details about how the data source is stored.

", - "UpdateDataSourceRequest$dataSourceConfiguration": "

Contains details about the storage configuration of the data source.

" + "CreateDataSourceRequest$dataSourceConfiguration": "

The connection configuration for the data source.

", + "DataSource$dataSourceConfiguration": "

The connection configuration for the data source.

", + "UpdateDataSourceRequest$dataSourceConfiguration": "

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

" } }, "DataSourceStatus": { @@ -454,7 +613,7 @@ "DataSourceType": { "base": null, "refs": { - "DataSourceConfiguration$type": "

The type of storage for the data source.

" + "DataSourceConfiguration$type": "

The type of data source.

" } }, "DateTimestamp": { @@ -480,9 +639,30 @@ "AgentVersion$updatedAt": "

The time at which the version was last updated.

", "AgentVersionSummary$createdAt": "

The time at which the version was created.

", "AgentVersionSummary$updatedAt": "

The time at which the version was last updated.

", + "CreateFlowAliasResponse$createdAt": "

The time at which the alias was created.

", + "CreateFlowAliasResponse$updatedAt": "

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

", + "CreateFlowResponse$createdAt": "

The time at which the flow was created.

", + "CreateFlowResponse$updatedAt": "

The time at which the flow was last updated.

", + "CreateFlowVersionResponse$createdAt": "

The time at which the flow was created.

", + "CreatePromptResponse$createdAt": "

The time at which the prompt was created.

", + "CreatePromptResponse$updatedAt": "

The time at which the prompt was last updated.

", + "CreatePromptVersionResponse$createdAt": "

The time at which the prompt was created.

", + "CreatePromptVersionResponse$updatedAt": "

The time at which the prompt was last updated.

", "DataSource$createdAt": "

The time at which the data source was created.

", "DataSource$updatedAt": "

The time at which the data source was last updated.

", "DataSourceSummary$updatedAt": "

The time at which the data source was last updated.

", + "FlowAliasSummary$createdAt": "

The time at which the alias was created.

", + "FlowAliasSummary$updatedAt": "

The time at which the alias was last updated.

", + "FlowSummary$createdAt": "

The time at which the flow was created.

", + "FlowSummary$updatedAt": "

The time at which the flow was last updated.

", + "FlowVersionSummary$createdAt": "

The time at the flow version was created.

", + "GetFlowAliasResponse$createdAt": "

The time at which the flow was created.

", + "GetFlowAliasResponse$updatedAt": "

The time at which the flow alias was last updated.

", + "GetFlowResponse$createdAt": "

The time at which the flow was created.

", + "GetFlowResponse$updatedAt": "

The time at which the flow was last updated.

", + "GetFlowVersionResponse$createdAt": "

The time at which the flow was created.

", + "GetPromptResponse$createdAt": "

The time at which the prompt was created.

", + "GetPromptResponse$updatedAt": "

The time at which the prompt was last updated.

", "IngestionJob$startedAt": "

The time at which the ingestion job started.

", "IngestionJob$updatedAt": "

The time at which the ingestion job was last updated.

", "IngestionJobSummary$startedAt": "

The time at which the ingestion job was started.

", @@ -490,7 +670,15 @@ "KnowledgeBase$createdAt": "

The time at which the knowledge base was created.

", "KnowledgeBase$updatedAt": "

The time at which the knowledge base was last updated.

", "KnowledgeBaseSummary$updatedAt": "

The time at which the knowledge base was last updated.

", - "PrepareAgentResponse$preparedAt": "

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

" + "PrepareAgentResponse$preparedAt": "

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

", + "PromptSummary$createdAt": "

The time at which the prompt was created.

", + "PromptSummary$updatedAt": "

The time at which the prompt was last updated.

", + "UpdateFlowAliasResponse$createdAt": "

The time at which the flow was created.

", + "UpdateFlowAliasResponse$updatedAt": "

The time at which the flow alias was last updated.

", + "UpdateFlowResponse$createdAt": "

The time at which the flow was created.

", + "UpdateFlowResponse$updatedAt": "

The time at which the flow was last updated.

", + "UpdatePromptResponse$createdAt": "

The time at which the prompt was created.

", + "UpdatePromptResponse$updatedAt": "

The time at which the prompt was last updated.

" } }, "DeleteAgentActionGroupRequest": { @@ -543,6 +731,36 @@ "refs": { } }, + "DeleteFlowAliasRequest": { + "base": null, + "refs": { + } + }, + "DeleteFlowAliasResponse": { + "base": null, + "refs": { + } + }, + "DeleteFlowRequest": { + "base": null, + "refs": { + } + }, + "DeleteFlowResponse": { + "base": null, + "refs": { + } + }, + "DeleteFlowVersionRequest": { + "base": null, + "refs": { + } + }, + "DeleteFlowVersionResponse": { + "base": null, + "refs": { + } + }, "DeleteKnowledgeBaseRequest": { "base": null, "refs": { @@ -553,6 +771,16 @@ "refs": { } }, + "DeletePromptRequest": { + "base": null, + "refs": { + } + }, + "DeletePromptResponse": { + "base": null, + "refs": { + } + }, "Description": { "base": null, "refs": { @@ -571,9 +799,13 @@ "CreateAgentAliasRequest$description": "

A description of the alias of the agent.

", "CreateAgentRequest$description": "

A description of the agent.

", "CreateDataSourceRequest$description": "

A description of the data source.

", + "CreateFlowAliasRequest$description": "

A description for the alias.

", + "CreateFlowAliasResponse$description": "

The description of the alias.

", "CreateKnowledgeBaseRequest$description": "

A description of the knowledge base.

", "DataSource$description": "

The description of the data source.

", "DataSourceSummary$description": "

The description of the data source.

", + "FlowAliasSummary$description": "

A description of the alias.

", + "GetFlowAliasResponse$description": "

The description of the flow.

", "IngestionJob$description": "

The description of the ingestion job.

", "IngestionJobSummary$description": "

The description of the ingestion job.

", "KnowledgeBase$description": "

The description of the knowledge base.

", @@ -584,6 +816,8 @@ "UpdateAgentKnowledgeBaseRequest$description": "

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

", "UpdateAgentRequest$description": "

Specifies a new description of the agent.

", "UpdateDataSourceRequest$description": "

Specifies a new description for the data source.

", + "UpdateFlowAliasRequest$description": "

A description for the flow alias.

", + "UpdateFlowAliasResponse$description": "

The description of the flow.

", "UpdateKnowledgeBaseRequest$description": "

Specifies a new description for the knowledge base.

" } }, @@ -609,10 +843,14 @@ "Agent$agentVersion": "

The version of the agent.

", "AssociateAgentKnowledgeBaseRequest$agentVersion": "

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

", "CreateAgentActionGroupRequest$agentVersion": "

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

", + "CreateFlowResponse$version": "

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

", "DeleteAgentActionGroupRequest$agentVersion": "

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

", "DisassociateAgentKnowledgeBaseRequest$agentVersion": "

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

", + "FlowSummary$version": "

The latest version of the flow.

", + "GetFlowResponse$version": "

The version of the flow for which information was retrieved.

", "UpdateAgentActionGroupRequest$agentVersion": "

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

", - "UpdateAgentKnowledgeBaseRequest$agentVersion": "

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

" + "UpdateAgentKnowledgeBaseRequest$agentVersion": "

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

", + "UpdateFlowResponse$version": "

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

" } }, "EmbeddingModelConfiguration": { @@ -621,6 +859,12 @@ "VectorKnowledgeBaseConfiguration$embeddingModelConfiguration": "

The embeddings model configuration details for the vector model used in Knowledge Base.

" } }, + "EnabledMemoryTypes": { + "base": null, + "refs": { + "MemoryConfiguration$enabledMemoryTypes": "

The type of memory that is stored.

" + } + }, "FailureReason": { "base": null, "refs": { @@ -654,6 +898,27 @@ "RedisEnterpriseCloudFieldMapping$vectorField": "

The name of the field in which Amazon Bedrock stores the vector embeddings for your data sources.

" } }, + "FilterList": { + "base": null, + "refs": { + "PatternObjectFilter$exclusionFilters": "

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.

", + "PatternObjectFilter$inclusionFilters": "

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.

", + "WebCrawlerConfiguration$exclusionFilters": "

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.

", + "WebCrawlerConfiguration$inclusionFilters": "

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.

" + } + }, + "FilterPattern": { + "base": null, + "refs": { + "FilterList$member": null + } + }, + "FilteredObjectType": { + "base": null, + "refs": { + "PatternObjectFilter$objectType": "

The supported object type or content type of the data source.

" + } + }, "FixedSizeChunkingConfiguration": { "base": "

Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy as NONE, exclude this field.

", "refs": { @@ -672,190 +937,630 @@ "FixedSizeChunkingConfiguration$overlapPercentage": "

The percentage of overlap between adjacent chunks of a data source.

" } }, - "Function": { - "base": "

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:

", + "FlowAliasArn": { + "base": null, "refs": { - "Functions$member": null + "CreateFlowAliasResponse$arn": "

The Amazon Resource Name (ARN) of the alias.

", + "FlowAliasSummary$arn": "

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

", + "GetFlowAliasResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "UpdateFlowAliasResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

" } }, - "FunctionDescription": { + "FlowAliasId": { "base": null, "refs": { - "Function$description": "

A description of the function and its purpose.

" + "CreateFlowAliasResponse$id": "

The unique identifier of the alias.

", + "DeleteFlowAliasResponse$id": "

The unique identifier of the flow.

", + "FlowAliasSummary$id": "

The unique identifier of the alias of the flow.

", + "GetFlowAliasResponse$id": "

The unique identifier of the alias of the flow.

", + "UpdateFlowAliasResponse$id": "

The unique identifier of the alias.

" } }, - "FunctionSchema": { - "base": "

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:

", + "FlowAliasIdentifier": { + "base": null, "refs": { - "AgentActionGroup$functionSchema": "

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

", - "CreateAgentActionGroupRequest$functionSchema": "

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

", - "UpdateAgentActionGroupRequest$functionSchema": "

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

" + "DeleteFlowAliasRequest$aliasIdentifier": "

The unique identifier of the alias to be deleted.

", + "GetFlowAliasRequest$aliasIdentifier": "

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

", + "UpdateFlowAliasRequest$aliasIdentifier": "

The unique identifier of the alias.

" } }, - "Functions": { + "FlowAliasRoutingConfiguration": { "base": null, "refs": { - "FunctionSchema$functions": "

A list of functions that each define an action in the action group.

" + "CreateFlowAliasRequest$routingConfiguration": "

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

", + "CreateFlowAliasResponse$routingConfiguration": "

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

", + "FlowAliasSummary$routingConfiguration": "

A list of configurations about the versions that the alias maps to. Currently, you can only specify one.

", + "GetFlowAliasResponse$routingConfiguration": "

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

", + "UpdateFlowAliasRequest$routingConfiguration": "

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

", + "UpdateFlowAliasResponse$routingConfiguration": "

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

" } }, - "GetAgentActionGroupRequest": { + "FlowAliasRoutingConfigurationListItem": { + "base": "

Contains information about a version that the alias maps to.

", + "refs": { + "FlowAliasRoutingConfiguration$member": null + } + }, + "FlowAliasSummaries": { "base": null, "refs": { + "ListFlowAliasesResponse$flowAliasSummaries": "

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

" } }, - "GetAgentActionGroupResponse": { + "FlowAliasSummary": { + "base": "

Contains information about an alias of a flow.

This data type is used in the following API operations:

", + "refs": { + "FlowAliasSummaries$member": null + } + }, + "FlowArn": { "base": null, "refs": { + "CreateFlowResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "CreateFlowVersionResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "FlowSummary$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "FlowVersionSummary$arn": "

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

", + "GetFlowResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "GetFlowVersionResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

", + "UpdateFlowResponse$arn": "

The Amazon Resource Name (ARN) of the flow.

" } }, - "GetAgentAliasRequest": { + "FlowCondition": { + "base": "

Defines a condition in the condition node.

", + "refs": { + "FlowConditions$member": null + } + }, + "FlowConditionExpression": { "base": null, "refs": { + "FlowCondition$expression": "

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.

" } }, - "GetAgentAliasResponse": { + "FlowConditionName": { "base": null, "refs": { + "FlowCondition$name": "

A name for the condition that you can reference.

", + "FlowConditionalConnectionConfiguration$condition": "

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.

" } }, - "GetAgentKnowledgeBaseRequest": { + "FlowConditionalConnectionConfiguration": { + "base": "

The configuration of a connection between a condition node and another node.

", + "refs": { + "FlowConnectionConfiguration$conditional": "

The configuration of a connection originating from a Condition node.

" + } + }, + "FlowConditions": { "base": null, "refs": { + "ConditionFlowNodeConfiguration$conditions": "

An array of conditions. Each member contains the name of a condition and an expression that defines the condition.

" } }, - "GetAgentKnowledgeBaseResponse": { + "FlowConnection": { + "base": "

Contains information about a connection between two nodes in the flow.

", + "refs": { + "FlowConnections$member": null + } + }, + "FlowConnectionConfiguration": { + "base": "

The configuration of the connection.

", + "refs": { + "FlowConnection$configuration": "

The configuration of the connection.

" + } + }, + "FlowConnectionName": { "base": null, "refs": { + "FlowConnection$name": "

A name for the connection that you can reference.

" } }, - "GetAgentRequest": { + "FlowConnectionType": { "base": null, "refs": { + "FlowConnection$type": "

Whether the source node that the connection begins from is a condition node (Conditional) or not (Data).

" } }, - "GetAgentResponse": { + "FlowConnections": { "base": null, "refs": { + "FlowDefinition$connections": "

An array of connection definitions in the flow.

" } }, - "GetAgentVersionRequest": { + "FlowDataConnectionConfiguration": { + "base": "

The configuration of a connection originating from a node that isn't a Condition node.

", + "refs": { + "FlowConnectionConfiguration$data": "

The configuration of a connection originating from a node that isn't a Condition node.

" + } + }, + "FlowDefinition": { + "base": "

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

", + "refs": { + "CreateFlowRequest$definition": "

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

", + "CreateFlowResponse$definition": "

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

", + "CreateFlowVersionResponse$definition": "

A definition of the nodes and connections in the flow.

", + "GetFlowResponse$definition": "

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

", + "GetFlowVersionResponse$definition": "

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

", + "UpdateFlowRequest$definition": "

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

", + "UpdateFlowResponse$definition": "

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

" + } + }, + "FlowDescription": { "base": null, "refs": { + "CreateFlowRequest$description": "

A description for the flow.

", + "CreateFlowResponse$description": "

The description of the flow.

", + "CreateFlowVersionRequest$description": "

A description of the version of the flow.

", + "CreateFlowVersionResponse$description": "

The description of the flow version.

", + "FlowSummary$description": "

A description of the flow.

", + "GetFlowResponse$description": "

The description of the flow.

", + "GetFlowVersionResponse$description": "

The description of the flow.

", + "UpdateFlowRequest$description": "

A description for the flow.

", + "UpdateFlowResponse$description": "

The description of the flow.

" } }, - "GetAgentVersionResponse": { + "FlowExecutionRoleArn": { "base": null, "refs": { + "CreateFlowRequest$executionRoleArn": "

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.

", + "CreateFlowResponse$executionRoleArn": "

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.

", + "CreateFlowVersionResponse$executionRoleArn": "

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.

", + "GetFlowResponse$executionRoleArn": "

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.

", + "GetFlowVersionResponse$executionRoleArn": "

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.

", + "UpdateFlowRequest$executionRoleArn": "

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.

", + "UpdateFlowResponse$executionRoleArn": "

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.

" } }, - "GetDataSourceRequest": { + "FlowId": { "base": null, "refs": { + "CreateFlowAliasResponse$flowId": "

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

", + "CreateFlowResponse$id": "

The unique identifier of the flow.

", + "CreateFlowVersionResponse$id": "

The unique identifier of the flow.

", + "DeleteFlowAliasResponse$flowId": "

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

", + "DeleteFlowResponse$id": "

The unique identifier of the flow.

", + "FlowAliasSummary$flowId": "

The unique identifier of the flow.

", + "FlowSummary$id": "

The unique identifier of the flow.

", + "FlowVersionSummary$id": "

The unique identifier of the flow.

", + "GetFlowAliasResponse$flowId": "

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

", + "GetFlowResponse$id": "

The unique identifier of the flow.

", + "GetFlowVersionResponse$id": "

The unique identifier of the flow.

", + "PrepareFlowResponse$id": "

The unique identifier of the flow.

", + "UpdateFlowAliasResponse$flowId": "

The unique identifier of the flow.

", + "UpdateFlowResponse$id": "

The unique identifier of the flow.

" } }, - "GetDataSourceResponse": { + "FlowIdentifier": { "base": null, "refs": { + "CreateFlowAliasRequest$flowIdentifier": "

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

", + "CreateFlowVersionRequest$flowIdentifier": "

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

", + "DeleteFlowAliasRequest$flowIdentifier": "

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

", + "DeleteFlowRequest$flowIdentifier": "

The unique identifier of the flow.

", + "DeleteFlowVersionRequest$flowIdentifier": "

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

", + "GetFlowAliasRequest$flowIdentifier": "

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

", + "GetFlowRequest$flowIdentifier": "

The unique identifier of the flow.

", + "GetFlowVersionRequest$flowIdentifier": "

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

", + "ListFlowAliasesRequest$flowIdentifier": "

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

", + "ListFlowVersionsRequest$flowIdentifier": "

The unique identifier of the flow.

", + "PrepareFlowRequest$flowIdentifier": "

The unique identifier of the flow.

", + "UpdateFlowAliasRequest$flowIdentifier": "

The unique identifier of the flow.

", + "UpdateFlowRequest$flowIdentifier": "

The unique identifier of the flow.

" } }, - "GetIngestionJobRequest": { + "FlowName": { "base": null, "refs": { + "CreateFlowRequest$name": "

A name for the flow.

", + "CreateFlowResponse$name": "

The name of the flow.

", + "CreateFlowVersionResponse$name": "

The name of the flow version.

", + "FlowSummary$name": "

The name of the flow.

", + "GetFlowResponse$name": "

The name of the flow.

", + "GetFlowVersionResponse$name": "

The name of the flow version.

", + "UpdateFlowRequest$name": "

A name for the flow.

", + "UpdateFlowResponse$name": "

The name of the flow.

" } }, - "GetIngestionJobResponse": { + "FlowNode": { + "base": "

Contains configurations about a node in the flow.

", + "refs": { + "FlowNodes$member": null + } + }, + "FlowNodeConfiguration": { + "base": "

Contains configurations for a node in your flow. For more information, see Node types in Amazon Bedrock works in the Amazon Bedrock User Guide.

", + "refs": { + "FlowNode$configuration": "

Contains configurations for the node.

" + } + }, + "FlowNodeIODataType": { "base": null, "refs": { + "FlowNodeInput$type": "

The data type of the input. If the input doesn't match this type at runtime, a validation error will be thrown.

", + "FlowNodeOutput$type": "

The data type of the output. If the output doesn't match this type at runtime, a validation error will be thrown.

" } }, - "GetKnowledgeBaseRequest": { + "FlowNodeInput": { + "base": "

Contains configurations for an input to a node.

", + "refs": { + "FlowNodeInputs$member": null + } + }, + "FlowNodeInputExpression": { "base": null, "refs": { + "FlowNodeInput$expression": "

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.

" } }, - "GetKnowledgeBaseResponse": { + "FlowNodeInputName": { "base": null, "refs": { + "FlowDataConnectionConfiguration$targetInput": "

The name of the input in the target node that the connection ends at.

", + "FlowNodeInput$name": "

A name for the input that you can reference.

" } }, - "GuardrailConfiguration": { - "base": "

The details of the guardrails configuration.

", + "FlowNodeInputs": { + "base": null, "refs": { - "Agent$guardrailConfiguration": "

The guardrails configuration assigned to the agent.

", - "AgentSummary$guardrailConfiguration": "

The details of the guardrails configuration in the agent summary.

", - "AgentVersion$guardrailConfiguration": "

The guardrails configuration assigned to the agent version.

", - "AgentVersionSummary$guardrailConfiguration": "

The details of the guardrails configuration in the agent version summary.

", - "CreateAgentRequest$guardrailConfiguration": "

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

", - "UpdateAgentRequest$guardrailConfiguration": "

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

" + "FlowNode$inputs": "

An array of objects, each of which contains information about an input into the node.

" } }, - "GuardrailIdentifier": { + "FlowNodeName": { "base": null, "refs": { - "GuardrailConfiguration$guardrailIdentifier": "

The guardrails identifier assigned to the guardrails configuration.

" + "FlowConnection$source": "

The node that the connection starts at.

", + "FlowConnection$target": "

The node that the connection ends at.

", + "FlowNode$name": "

A name for the node.

" } }, - "GuardrailVersion": { + "FlowNodeOutput": { + "base": "

Contains configurations for an output from a node.

", + "refs": { + "FlowNodeOutputs$member": null + } + }, + "FlowNodeOutputName": { "base": null, "refs": { - "GuardrailConfiguration$guardrailVersion": "

The guardrails version assigned to the guardrails configuration.

" + "FlowDataConnectionConfiguration$sourceOutput": "

The name of the output in the source node that the connection begins from.

", + "FlowNodeOutput$name": "

A name for the output that you can reference.

" } }, - "Id": { + "FlowNodeOutputs": { "base": null, "refs": { - "ActionGroupSummary$actionGroupId": "

The unique identifier of the action group.

", - "Agent$agentId": "

The unique identifier of the agent.

", - "AgentActionGroup$actionGroupId": "

The unique identifier of the action group.

", - "AgentActionGroup$agentId": "

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

", - "AgentAlias$agentId": "

The unique identifier of the agent.

", - "AgentKnowledgeBase$agentId": "

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

", - "AgentKnowledgeBase$knowledgeBaseId": "

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

", - "AgentKnowledgeBaseSummary$knowledgeBaseId": "

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

", - "AgentSummary$agentId": "

The unique identifier of the agent.

", - "AgentVersion$agentId": "

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

", - "AssociateAgentKnowledgeBaseRequest$agentId": "

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

", - "AssociateAgentKnowledgeBaseRequest$knowledgeBaseId": "

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

", - "CreateAgentActionGroupRequest$agentId": "

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

", - "CreateAgentAliasRequest$agentId": "

The unique identifier of the agent.

", - "CreateDataSourceRequest$knowledgeBaseId": "

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

", - "DataSource$dataSourceId": "

The unique identifier of the data source.

", - "DataSource$knowledgeBaseId": "

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

", - "DataSourceSummary$dataSourceId": "

The unique identifier of the data source.

", - "DataSourceSummary$knowledgeBaseId": "

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

", - "DeleteAgentActionGroupRequest$actionGroupId": "

The unique identifier of the action group to delete.

", - "DeleteAgentActionGroupRequest$agentId": "

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

", - "DeleteAgentAliasRequest$agentId": "

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

", - "DeleteAgentAliasResponse$agentId": "

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

", - "DeleteAgentRequest$agentId": "

The unique identifier of the agent to delete.

", - "DeleteAgentResponse$agentId": "

The unique identifier of the agent that was deleted.

", - "DeleteAgentVersionRequest$agentId": "

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

", - "DeleteAgentVersionResponse$agentId": "

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

", - "DeleteDataSourceRequest$dataSourceId": "

The unique identifier of the data source to delete.

", - "DeleteDataSourceRequest$knowledgeBaseId": "

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

", - "DeleteDataSourceResponse$dataSourceId": "

The unique identifier of the data source that was deleted.

", - "DeleteDataSourceResponse$knowledgeBaseId": "

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

", - "DeleteKnowledgeBaseRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to delete.

", - "DeleteKnowledgeBaseResponse$knowledgeBaseId": "

The unique identifier of the knowledge base that was deleted.

", - "DisassociateAgentKnowledgeBaseRequest$agentId": "

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

", - "DisassociateAgentKnowledgeBaseRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to disassociate.

", - "GetAgentActionGroupRequest$actionGroupId": "

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

", - "GetAgentActionGroupRequest$agentId": "

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

", - "GetAgentAliasRequest$agentId": "

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

", - "GetAgentKnowledgeBaseRequest$agentId": "

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

", - "GetAgentKnowledgeBaseRequest$knowledgeBaseId": "

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

", - "GetAgentRequest$agentId": "

The unique identifier of the agent.

", - "GetAgentVersionRequest$agentId": "

The unique identifier of the agent.

", - "GetDataSourceRequest$dataSourceId": "

The unique identifier of the data source.

", - "GetDataSourceRequest$knowledgeBaseId": "

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

", - "GetIngestionJobRequest$dataSourceId": "

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

", - "GetIngestionJobRequest$ingestionJobId": "

The unique identifier of the ingestion job.

", - "GetIngestionJobRequest$knowledgeBaseId": "

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

", - "GetKnowledgeBaseRequest$knowledgeBaseId": "

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

", - "IngestionJob$dataSourceId": "

The unique identifier of the ingested data source.

", - "IngestionJob$ingestionJobId": "

The unique identifier of the ingestion job.

", - "IngestionJob$knowledgeBaseId": "

The unique identifier of the knowledge base to which the data source is being added.

", - "IngestionJobSummary$dataSourceId": "

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

", + "FlowNode$outputs": "

A list of objects, each of which contains information about an output from the node.

" + } + }, + "FlowNodeType": { + "base": null, + "refs": { + "FlowNode$type": "

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.

" + } + }, + "FlowNodes": { + "base": null, + "refs": { + "FlowDefinition$nodes": "

An array of node definitions in the flow.

" + } + }, + "FlowStatus": { + "base": null, + "refs": { + "CreateFlowResponse$status": "

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

", + "CreateFlowVersionResponse$status": "

The status of the flow.

", + "FlowSummary$status": "

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

", + "FlowVersionSummary$status": "

The status of the flow.

", + "GetFlowResponse$status": "

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

", + "GetFlowVersionResponse$status": "

The status of the flow.

", + "PrepareFlowResponse$status": "

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.

", + "UpdateFlowResponse$status": "

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

" + } + }, + "FlowSummaries": { + "base": null, + "refs": { + "ListFlowsResponse$flowSummaries": "

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

" + } + }, + "FlowSummary": { + "base": "

Contains the definition of a flow.

", + "refs": { + "FlowSummaries$member": null + } + }, + "FlowValidation": { + "base": "

Contains information about validation of the flow.

This data type is used in the following API operations:

", + "refs": { + "FlowValidations$member": null + } + }, + "FlowValidationSeverity": { + "base": null, + "refs": { + "FlowValidation$severity": "

The severity of the issue described in the message.

" + } + }, + "FlowValidations": { + "base": null, + "refs": { + "GetFlowResponse$validations": "

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

" + } + }, + "FlowVersionSummaries": { + "base": null, + "refs": { + "ListFlowVersionsResponse$flowVersionSummaries": "

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

" + } + }, + "FlowVersionSummary": { + "base": "

Contains information about the flow version.

This data type is used in the following API operations:

", + "refs": { + "FlowVersionSummaries$member": null + } + }, + "Function": { + "base": "

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:

", + "refs": { + "Functions$member": null + } + }, + "FunctionDescription": { + "base": null, + "refs": { + "Function$description": "

A description of the function and its purpose.

" + } + }, + "FunctionSchema": { + "base": "

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:

", + "refs": { + "AgentActionGroup$functionSchema": "

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

", + "CreateAgentActionGroupRequest$functionSchema": "

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

", + "UpdateAgentActionGroupRequest$functionSchema": "

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

" + } + }, + "Functions": { + "base": null, + "refs": { + "FunctionSchema$functions": "

A list of functions that each define an action in the action group.

" + } + }, + "GetAgentActionGroupRequest": { + "base": null, + "refs": { + } + }, + "GetAgentActionGroupResponse": { + "base": null, + "refs": { + } + }, + "GetAgentAliasRequest": { + "base": null, + "refs": { + } + }, + "GetAgentAliasResponse": { + "base": null, + "refs": { + } + }, + "GetAgentKnowledgeBaseRequest": { + "base": null, + "refs": { + } + }, + "GetAgentKnowledgeBaseResponse": { + "base": null, + "refs": { + } + }, + "GetAgentRequest": { + "base": null, + "refs": { + } + }, + "GetAgentResponse": { + "base": null, + "refs": { + } + }, + "GetAgentVersionRequest": { + "base": null, + "refs": { + } + }, + "GetAgentVersionResponse": { + "base": null, + "refs": { + } + }, + "GetDataSourceRequest": { + "base": null, + "refs": { + } + }, + "GetDataSourceResponse": { + "base": null, + "refs": { + } + }, + "GetFlowAliasRequest": { + "base": null, + "refs": { + } + }, + "GetFlowAliasResponse": { + "base": null, + "refs": { + } + }, + "GetFlowRequest": { + "base": null, + "refs": { + } + }, + "GetFlowResponse": { + "base": null, + "refs": { + } + }, + "GetFlowVersionRequest": { + "base": null, + "refs": { + } + }, + "GetFlowVersionResponse": { + "base": null, + "refs": { + } + }, + "GetIngestionJobRequest": { + "base": null, + "refs": { + } + }, + "GetIngestionJobResponse": { + "base": null, + "refs": { + } + }, + "GetKnowledgeBaseRequest": { + "base": null, + "refs": { + } + }, + "GetKnowledgeBaseResponse": { + "base": null, + "refs": { + } + }, + "GetPromptRequest": { + "base": null, + "refs": { + } + }, + "GetPromptResponse": { + "base": null, + "refs": { + } + }, + "GuardrailConfiguration": { + "base": "

Details about the guardrail associated with an agent.

", + "refs": { + "Agent$guardrailConfiguration": "

Details about the guardrail associated with the agent.

", + "AgentSummary$guardrailConfiguration": "

Details about the guardrail associated with the agent.

", + "AgentVersion$guardrailConfiguration": "

Details about the guardrail associated with the agent.

", + "AgentVersionSummary$guardrailConfiguration": "

Details about the guardrail associated with the agent.

", + "CreateAgentRequest$guardrailConfiguration": "

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

", + "UpdateAgentRequest$guardrailConfiguration": "

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

" + } + }, + "GuardrailIdentifier": { + "base": null, + "refs": { + "GuardrailConfiguration$guardrailIdentifier": "

The unique identifier of the guardrail.

" + } + }, + "GuardrailVersion": { + "base": null, + "refs": { + "GuardrailConfiguration$guardrailVersion": "

The version of the guardrail.

" + } + }, + "HierarchicalChunkingConfiguration": { + "base": "

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.

", + "refs": { + "ChunkingConfiguration$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.

" + } + }, + "HierarchicalChunkingConfigurationOverlapTokensInteger": { + "base": null, + "refs": { + "HierarchicalChunkingConfiguration$overlapTokens": "

The number of tokens to repeat across chunks in the same layer.

" + } + }, + "HierarchicalChunkingLevelConfiguration": { + "base": "

Token settings for a layer in a hierarchical chunking configuration.

", + "refs": { + "HierarchicalChunkingLevelConfigurations$member": null + } + }, + "HierarchicalChunkingLevelConfigurationMaxTokensInteger": { + "base": null, + "refs": { + "HierarchicalChunkingLevelConfiguration$maxTokens": "

The maximum number of tokens that a chunk can contain in this layer.

" + } + }, + "HierarchicalChunkingLevelConfigurations": { + "base": null, + "refs": { + "HierarchicalChunkingConfiguration$levelConfigurations": "

Token settings for each layer.

" + } + }, + "HttpsUrl": { + "base": null, + "refs": { + "ConfluenceSourceConfiguration$hostUrl": "

The Confluence host URL or instance URL.

", + "SalesforceSourceConfiguration$hostUrl": "

The Salesforce host URL or instance URL.

", + "SharePointSiteUrls$member": null + } + }, + "Id": { + "base": null, + "refs": { + "ActionGroupSummary$actionGroupId": "

The unique identifier of the action group.

", + "Agent$agentId": "

The unique identifier of the agent.

", + "AgentActionGroup$actionGroupId": "

The unique identifier of the action group.

", + "AgentActionGroup$agentId": "

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

", + "AgentAlias$agentId": "

The unique identifier of the agent.

", + "AgentKnowledgeBase$agentId": "

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

", + "AgentKnowledgeBase$knowledgeBaseId": "

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

", + "AgentKnowledgeBaseSummary$knowledgeBaseId": "

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

", + "AgentSummary$agentId": "

The unique identifier of the agent.

", + "AgentVersion$agentId": "

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

", + "AssociateAgentKnowledgeBaseRequest$agentId": "

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

", + "AssociateAgentKnowledgeBaseRequest$knowledgeBaseId": "

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

", + "CreateAgentActionGroupRequest$agentId": "

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

", + "CreateAgentAliasRequest$agentId": "

The unique identifier of the agent.

", + "CreateDataSourceRequest$knowledgeBaseId": "

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

", + "DataSource$dataSourceId": "

The unique identifier of the data source.

", + "DataSource$knowledgeBaseId": "

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

", + "DataSourceSummary$dataSourceId": "

The unique identifier of the data source.

", + "DataSourceSummary$knowledgeBaseId": "

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

", + "DeleteAgentActionGroupRequest$actionGroupId": "

The unique identifier of the action group to delete.

", + "DeleteAgentActionGroupRequest$agentId": "

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

", + "DeleteAgentAliasRequest$agentId": "

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

", + "DeleteAgentAliasResponse$agentId": "

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

", + "DeleteAgentRequest$agentId": "

The unique identifier of the agent to delete.

", + "DeleteAgentResponse$agentId": "

The unique identifier of the agent that was deleted.

", + "DeleteAgentVersionRequest$agentId": "

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

", + "DeleteAgentVersionResponse$agentId": "

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

", + "DeleteDataSourceRequest$dataSourceId": "

The unique identifier of the data source to delete.

", + "DeleteDataSourceRequest$knowledgeBaseId": "

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

", + "DeleteDataSourceResponse$dataSourceId": "

The unique identifier of the data source that was deleted.

", + "DeleteDataSourceResponse$knowledgeBaseId": "

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

", + "DeleteFlowVersionResponse$id": "

The unique identifier of the flow.

", + "DeleteKnowledgeBaseRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to delete.

", + "DeleteKnowledgeBaseResponse$knowledgeBaseId": "

The unique identifier of the knowledge base that was deleted.

", + "DisassociateAgentKnowledgeBaseRequest$agentId": "

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

", + "DisassociateAgentKnowledgeBaseRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to disassociate.

", + "GetAgentActionGroupRequest$actionGroupId": "

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

", + "GetAgentActionGroupRequest$agentId": "

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

", + "GetAgentAliasRequest$agentId": "

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

", + "GetAgentKnowledgeBaseRequest$agentId": "

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

", + "GetAgentKnowledgeBaseRequest$knowledgeBaseId": "

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

", + "GetAgentRequest$agentId": "

The unique identifier of the agent.

", + "GetAgentVersionRequest$agentId": "

The unique identifier of the agent.

", + "GetDataSourceRequest$dataSourceId": "

The unique identifier of the data source.

", + "GetDataSourceRequest$knowledgeBaseId": "

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

", + "GetIngestionJobRequest$dataSourceId": "

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

", + "GetIngestionJobRequest$ingestionJobId": "

The unique identifier of the ingestion job.

", + "GetIngestionJobRequest$knowledgeBaseId": "

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

", + "GetKnowledgeBaseRequest$knowledgeBaseId": "

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

", + "IngestionJob$dataSourceId": "

The unique identifier of the ingested data source.

", + "IngestionJob$ingestionJobId": "

The unique identifier of the ingestion job.

", + "IngestionJob$knowledgeBaseId": "

The unique identifier of the knowledge base to which the data source is being added.

", + "IngestionJobSummary$dataSourceId": "

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

", "IngestionJobSummary$ingestionJobId": "

The unique identifier of the ingestion job.

", "IngestionJobSummary$knowledgeBaseId": "

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

", "KnowledgeBase$knowledgeBaseId": "

The unique identifier of the knowledge base.

", @@ -878,7 +1583,7 @@ "UpdateAgentKnowledgeBaseRequest$knowledgeBaseId": "

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

", "UpdateAgentRequest$agentId": "

The unique identifier of the agent.

", "UpdateDataSourceRequest$dataSourceId": "

The unique identifier of the data source.

", - "UpdateDataSourceRequest$knowledgeBaseId": "

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

", + "UpdateDataSourceRequest$knowledgeBaseId": "

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

", "UpdateKnowledgeBaseRequest$knowledgeBaseId": "

The unique identifier of the knowledge base to update.

" } }, @@ -969,6 +1674,12 @@ "IngestionJobSummaries$member": null } }, + "InputFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$input": "

Contains configurations for an input flow node in your flow. The first node in the flow. inputs can't be specified for this node.

" + } + }, "Instruction": { "base": null, "refs": { @@ -978,19 +1689,44 @@ "UpdateAgentRequest$instruction": "

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

" } }, + "IntermediateStorage": { + "base": "

A location for storing content from data sources temporarily as it is processed by custom components in the ingestion pipeline.

", + "refs": { + "CustomTransformationConfiguration$intermediateStorage": "

An S3 bucket path for input and output objects.

" + } + }, "InternalServerException": { "base": "

An internal server error occurred. Retry your request.

", "refs": { } }, + "IteratorFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$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.

" + } + }, "KmsKeyArn": { "base": null, "refs": { "Agent$customerEncryptionKeyArn": "

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

", "AgentVersion$customerEncryptionKeyArn": "

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

", "CreateAgentRequest$customerEncryptionKeyArn": "

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

", + "CreateFlowRequest$customerEncryptionKeyArn": "

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

", + "CreateFlowResponse$customerEncryptionKeyArn": "

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

", + "CreateFlowVersionResponse$customerEncryptionKeyArn": "

The KMS key that the flow is encrypted with.

", + "CreatePromptRequest$customerEncryptionKeyArn": "

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

", + "CreatePromptResponse$customerEncryptionKeyArn": "

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

", + "CreatePromptVersionResponse$customerEncryptionKeyArn": "

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

", + "GetFlowResponse$customerEncryptionKeyArn": "

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

", + "GetFlowVersionResponse$customerEncryptionKeyArn": "

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

", + "GetPromptResponse$customerEncryptionKeyArn": "

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

", "ServerSideEncryptionConfiguration$kmsKeyArn": "

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

", - "UpdateAgentRequest$customerEncryptionKeyArn": "

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

" + "UpdateAgentRequest$customerEncryptionKeyArn": "

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

", + "UpdateFlowRequest$customerEncryptionKeyArn": "

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

", + "UpdateFlowResponse$customerEncryptionKeyArn": "

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

", + "UpdatePromptRequest$customerEncryptionKeyArn": "

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

", + "UpdatePromptResponse$customerEncryptionKeyArn": "

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

" } }, "KnowledgeBase": { @@ -1015,6 +1751,18 @@ "UpdateKnowledgeBaseRequest$knowledgeBaseConfiguration": "

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.

" } }, + "KnowledgeBaseFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$knowledgeBase": "

Contains configurations for a knowledge base node in your flow. Queries a knowledge base and returns the retrieved results or generated response.

" + } + }, + "KnowledgeBaseId": { + "base": null, + "refs": { + "KnowledgeBaseFlowNodeConfiguration$knowledgeBaseId": "

The unique identifier of the knowledge base to query.

" + } + }, "KnowledgeBaseRoleArn": { "base": null, "refs": { @@ -1068,7 +1816,33 @@ "base": null, "refs": { "ActionGroupExecutor$lambda": "

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

", - "PromptOverrideConfiguration$overrideLambda": "

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.

" + "LambdaFunctionFlowNodeConfiguration$lambdaArn": "

The Amazon Resource Name (ARN) of the Lambda function to invoke.

", + "PromptOverrideConfiguration$overrideLambda": "

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.

", + "TransformationLambdaConfiguration$lambdaArn": "

The function's ARN identifier.

" + } + }, + "LambdaFunctionFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$lambdaFunction": "

Contains configurations for a Lambda function node in your flow. Invokes an Lambda function.

" + } + }, + "LexBotAliasArn": { + "base": null, + "refs": { + "LexFlowNodeConfiguration$botAliasArn": "

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

" + } + }, + "LexBotLocaleId": { + "base": null, + "refs": { + "LexFlowNodeConfiguration$localeId": "

The Region to invoke the Amazon Lex bot in.

" + } + }, + "LexFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$lex": "

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.

" } }, "ListAgentActionGroupsRequest": { @@ -1131,6 +1905,36 @@ "refs": { } }, + "ListFlowAliasesRequest": { + "base": null, + "refs": { + } + }, + "ListFlowAliasesResponse": { + "base": null, + "refs": { + } + }, + "ListFlowVersionsRequest": { + "base": null, + "refs": { + } + }, + "ListFlowVersionsResponse": { + "base": null, + "refs": { + } + }, + "ListFlowsRequest": { + "base": null, + "refs": { + } + }, + "ListFlowsResponse": { + "base": null, + "refs": { + } + }, "ListIngestionJobsRequest": { "base": null, "refs": { @@ -1151,6 +1955,16 @@ "refs": { } }, + "ListPromptsRequest": { + "base": null, + "refs": { + } + }, + "ListPromptsResponse": { + "base": null, + "refs": { + } + }, "ListTagsForResourceRequest": { "base": null, "refs": { @@ -1170,14 +1984,40 @@ "ListAgentVersionsRequest$maxResults": "

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.

", "ListAgentsRequest$maxResults": "

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.

", "ListDataSourcesRequest$maxResults": "

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.

", + "ListFlowAliasesRequest$maxResults": "

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.

", + "ListFlowVersionsRequest$maxResults": "

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.

", + "ListFlowsRequest$maxResults": "

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.

", "ListIngestionJobsRequest$maxResults": "

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.

", - "ListKnowledgeBasesRequest$maxResults": "

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.

" + "ListKnowledgeBasesRequest$maxResults": "

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.

", + "ListPromptsRequest$maxResults": "

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.

" } }, "MaximumLength": { "base": null, "refs": { - "InferenceConfiguration$maximumLength": "

The maximum number of tokens to allow in the generated response.

" + "InferenceConfiguration$maximumLength": "

The maximum number of tokens to allow in the generated response.

", + "PromptModelInferenceConfiguration$maxTokens": "

The maximum number of tokens to return in the response.

" + } + }, + "MemoryConfiguration": { + "base": "

Details of the memory configuration.

", + "refs": { + "Agent$memoryConfiguration": "

Contains memory configuration for the agent.

", + "AgentVersion$memoryConfiguration": "

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

", + "CreateAgentRequest$memoryConfiguration": "

Contains the details of the memory configured for the agent.

", + "UpdateAgentRequest$memoryConfiguration": "

Specifies the new memory configuration for the agent.

" + } + }, + "MemoryType": { + "base": null, + "refs": { + "EnabledMemoryTypes$member": null + } + }, + "Microsoft365TenantId": { + "base": null, + "refs": { + "SharePointSourceConfiguration$tenantId": "

The identifier of your Microsoft 365 tenant.

" } }, "ModelIdentifier": { @@ -1186,6 +2026,7 @@ "Agent$foundationModel": "

The foundation model used for orchestration by the agent.

", "AgentVersion$foundationModel": "

The foundation model that the version invokes.

", "CreateAgentRequest$foundationModel": "

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

", + "KnowledgeBaseFlowNodeConfiguration$modelId": "

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.

", "UpdateAgentRequest$foundationModel": "

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

" } }, @@ -1246,10 +2087,14 @@ "CreateAgentAliasRequest$agentAliasName": "

The name of the alias.

", "CreateAgentRequest$agentName": "

A name for the agent that you create.

", "CreateDataSourceRequest$name": "

The name of the data source.

", + "CreateFlowAliasRequest$name": "

A name for the alias.

", + "CreateFlowAliasResponse$name": "

The name of the alias.

", "CreateKnowledgeBaseRequest$name": "

A name for the knowledge base.

", "DataSource$name": "

The name of the data source.

", "DataSourceSummary$name": "

The name of the data source.

", + "FlowAliasSummary$name": "

The name of the alias.

", "Function$name": "

A name for the function.

", + "GetFlowAliasResponse$name": "

The name of the flow alias.

", "KnowledgeBase$name": "

The name of the knowledge base.

", "KnowledgeBaseSummary$name": "

The name of the knowledge base.

", "ParameterMap$key": null, @@ -1257,6 +2102,8 @@ "UpdateAgentAliasRequest$agentAliasName": "

Specifies a new name for the alias.

", "UpdateAgentRequest$agentName": "

Specifies a new name for the agent.

", "UpdateDataSourceRequest$name": "

Specifies a new name for the data source.

", + "UpdateFlowAliasRequest$name": "

The name of the flow alias.

", + "UpdateFlowAliasResponse$name": "

The name of the flow alias.

", "UpdateKnowledgeBaseRequest$name": "

Specifies a new name for the knowledge base.

" } }, @@ -1275,10 +2122,18 @@ "ListAgentsResponse$nextToken": "

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.

", "ListDataSourcesRequest$nextToken": "

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.

", "ListDataSourcesResponse$nextToken": "

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.

", + "ListFlowAliasesRequest$nextToken": "

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.

", + "ListFlowAliasesResponse$nextToken": "

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.

", + "ListFlowVersionsRequest$nextToken": "

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.

", + "ListFlowVersionsResponse$nextToken": "

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.

", + "ListFlowsRequest$nextToken": "

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.

", + "ListFlowsResponse$nextToken": "

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.

", "ListIngestionJobsRequest$nextToken": "

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.

", "ListIngestionJobsResponse$nextToken": "

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.

", "ListKnowledgeBasesRequest$nextToken": "

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.

", - "ListKnowledgeBasesResponse$nextToken": "

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.

" + "ListKnowledgeBasesResponse$nextToken": "

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.

", + "ListPromptsRequest$nextToken": "

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.

", + "ListPromptsResponse$nextToken": "

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.

" } }, "NonBlankString": { @@ -1286,6 +2141,7 @@ "refs": { "AccessDeniedException$message": null, "ConflictException$message": null, + "FlowValidation$message": "

A message describing the validation error.

", "InternalServerException$message": null, "ResourceNotFoundException$message": null, "ServiceQuotaExceededException$message": null, @@ -1299,9 +2155,17 @@ "base": null, "refs": { "AgentVersion$version": "

The version number.

", + "CreateFlowVersionResponse$version": "

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

", "DeleteAgentVersionRequest$agentVersion": "

The version of the agent to delete.

", "DeleteAgentVersionResponse$agentVersion": "

The version that was deleted.

", - "GetAgentVersionRequest$agentVersion": "

The version of the agent.

" + "DeleteFlowVersionRequest$flowVersion": "

The version of the flow that you want to delete.

", + "DeleteFlowVersionResponse$version": "

The version of the flow being deleted.

", + "DeletePromptRequest$promptVersion": "

The version of the prompt to delete.

", + "DeletePromptResponse$version": "

The version of the prompt that was deleted.

", + "FlowVersionSummary$version": "

The version of the flow.

", + "GetAgentVersionRequest$agentVersion": "

The version of the agent.

", + "GetFlowVersionRequest$flowVersion": "

The version of the flow for which to get information.

", + "GetFlowVersionResponse$version": "

The version of the flow for which information was retrieved.

" } }, "OpenSearchServerlessCollectionArn": { @@ -1328,22 +2192,70 @@ "OpenSearchServerlessConfiguration$vectorIndexName": "

The name of the vector store.

" } }, + "OutputFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$output": "

Contains configurations for an output flow node in your flow. The last node in the flow. outputs can't be specified for this node.

" + } + }, "ParameterDescription": { "base": null, "refs": { - "ParameterDetail$description": "

A description of the parameter. Helps the foundation model determine how to elicit the parameters from the user.

" + "ParameterDetail$description": "

A description of the parameter. Helps the foundation model determine how to elicit the parameters from the user.

" + } + }, + "ParameterDetail": { + "base": "

Contains details about a parameter in a function for an action group.

This data type is used in the following API operations:

", + "refs": { + "ParameterMap$value": null + } + }, + "ParameterMap": { + "base": null, + "refs": { + "Function$parameters": "

The parameters that the agent elicits from the user to fulfill the function.

" + } + }, + "ParsingConfiguration": { + "base": "

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.

You can get the ARN of a model with the action. Standard model usage charges apply for the foundation model parsing strategy.

", + "refs": { + "VectorIngestionConfiguration$parsingConfiguration": "

A custom parser for data source documents.

" + } + }, + "ParsingPrompt": { + "base": "

Instructions for interpreting the contents of a document.

", + "refs": { + "BedrockFoundationModelConfiguration$parsingPrompt": "

Instructions for interpreting the contents of a document.

" + } + }, + "ParsingPromptText": { + "base": null, + "refs": { + "ParsingPrompt$parsingPromptText": "

Instructions for interpreting the contents of a document.

" + } + }, + "ParsingStrategy": { + "base": null, + "refs": { + "ParsingConfiguration$parsingStrategy": "

The parsing strategy for the data source.

" + } + }, + "PatternObjectFilter": { + "base": "

The specific filters applied to your data source content. You can filter out or include certain content.

", + "refs": { + "PatternObjectFilterList$member": null } }, - "ParameterDetail": { - "base": "

Contains details about a parameter in a function for an action group.

This data type is used in the following API operations:

", + "PatternObjectFilterConfiguration": { + "base": "

The configuration of filtering certain objects or content types of the data source.

", "refs": { - "ParameterMap$value": null + "CrawlFilterConfiguration$patternObjectFilter": "

The configuration of filtering certain objects or content types of the data source.

" } }, - "ParameterMap": { + "PatternObjectFilterList": { "base": null, "refs": { - "Function$parameters": "

The parameters that the agent elicits from the user to fulfill the function.

" + "PatternObjectFilterConfiguration$filters": "

The configuration of specific filters applied to your data source content. You can filter out or include certain content.

" } }, "Payload": { @@ -1386,6 +2298,16 @@ "refs": { } }, + "PrepareFlowRequest": { + "base": null, + "refs": { + } + }, + "PrepareFlowResponse": { + "base": null, + "refs": { + } + }, "PrimitiveLong": { "base": null, "refs": { @@ -1398,6 +2320,17 @@ "IngestionJobStatistics$numberOfNewDocumentsIndexed": "

The number of new source documents in the data source that were successfully indexed.

" } }, + "PromptArn": { + "base": null, + "refs": { + "CreatePromptResponse$arn": "

The Amazon Resource Name (ARN) of the prompt.

", + "CreatePromptVersionResponse$arn": "

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

", + "GetPromptResponse$arn": "

The Amazon Resource Name (ARN) of the prompt.

", + "PromptFlowNodeResourceConfiguration$promptArn": "

The Amazon Resource Name (ARN) of the prompt from Prompt management.

", + "PromptSummary$arn": "

The Amazon Resource Name (ARN) of the prompt.

", + "UpdatePromptResponse$arn": "

The Amazon Resource Name (ARN) of the prompt.

" + } + }, "PromptConfiguration": { "base": "

Contains configurations to override a prompt template in one part of an agent sequence. For more information, see Advanced prompts.

", "refs": { @@ -1410,6 +2343,114 @@ "PromptOverrideConfiguration$promptConfigurations": "

Contains configurations to override a prompt template in one part of an agent sequence. For more information, see Advanced prompts.

" } }, + "PromptDescription": { + "base": null, + "refs": { + "CreatePromptRequest$description": "

A description for the prompt.

", + "CreatePromptResponse$description": "

The description of the prompt.

", + "CreatePromptVersionRequest$description": "

A description for the version of the prompt.

", + "CreatePromptVersionResponse$description": "

A description for the prompt version.

", + "GetPromptResponse$description": "

The descriptino of the prompt.

", + "PromptSummary$description": "

The description of the prompt.

", + "UpdatePromptRequest$description": "

A description for the prompt.

", + "UpdatePromptResponse$description": "

The description of the prompt.

" + } + }, + "PromptFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$prompt": "

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.

" + } + }, + "PromptFlowNodeInlineConfiguration": { + "base": "

Contains configurations for a prompt defined inline in the node.

", + "refs": { + "PromptFlowNodeSourceConfiguration$inline": "

Contains configurations for a prompt that is defined inline

" + } + }, + "PromptFlowNodeResourceConfiguration": { + "base": "

Contains configurations for a prompt from Prompt management to use in a node.

", + "refs": { + "PromptFlowNodeSourceConfiguration$resource": "

Contains configurations for a prompt from Prompt management.

" + } + }, + "PromptFlowNodeSourceConfiguration": { + "base": "

Contains configurations for a prompt and whether it is from Prompt management or defined inline.

", + "refs": { + "PromptFlowNodeConfiguration$sourceConfiguration": "

Specifies whether the prompt is from Prompt management or defined inline.

" + } + }, + "PromptId": { + "base": null, + "refs": { + "CreatePromptResponse$id": "

The unique identifier of the prompt.

", + "CreatePromptVersionResponse$id": "

The unique identifier of the prompt.

", + "DeletePromptResponse$id": "

The unique identifier of the prompt that was deleted.

", + "GetPromptResponse$id": "

The unique identifier of the prompt.

", + "PromptSummary$id": "

The unique identifier of the prompt.

", + "UpdatePromptResponse$id": "

The unique identifier of the prompt.

" + } + }, + "PromptIdentifier": { + "base": null, + "refs": { + "CreatePromptVersionRequest$promptIdentifier": "

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

", + "DeletePromptRequest$promptIdentifier": "

The unique identifier of the prompt.

", + "GetPromptRequest$promptIdentifier": "

The unique identifier of the prompt.

", + "ListPromptsRequest$promptIdentifier": "

The unique identifier of the prompt.

", + "UpdatePromptRequest$promptIdentifier": "

The unique identifier of the prompt.

" + } + }, + "PromptInferenceConfiguration": { + "base": "

Contains inference configurations for the prompt.

", + "refs": { + "PromptFlowNodeInlineConfiguration$inferenceConfiguration": "

Contains inference configurations for the prompt.

", + "PromptVariant$inferenceConfiguration": "

Contains inference configurations for the prompt variant.

" + } + }, + "PromptInputVariable": { + "base": "

Contains information about a variable in the prompt.

", + "refs": { + "PromptInputVariablesList$member": null + } + }, + "PromptInputVariableName": { + "base": null, + "refs": { + "PromptInputVariable$name": "

The name of the variable.

" + } + }, + "PromptInputVariablesList": { + "base": null, + "refs": { + "TextPromptTemplateConfiguration$inputVariables": "

An array of the variables in the prompt template.

" + } + }, + "PromptModelIdentifier": { + "base": null, + "refs": { + "PromptFlowNodeInlineConfiguration$modelId": "

The unique identifier of the model to run inference with.

", + "PromptVariant$modelId": "

The unique identifier of the model with which to run inference on the prompt.

" + } + }, + "PromptModelInferenceConfiguration": { + "base": "

Contains inference configurations related to model inference for a prompt. For more information, see Inference parameters.

", + "refs": { + "PromptInferenceConfiguration$text": "

Contains inference configurations for a text prompt.

" + } + }, + "PromptName": { + "base": null, + "refs": { + "CreatePromptRequest$name": "

A name for the prompt.

", + "CreatePromptResponse$name": "

The name of the prompt.

", + "CreatePromptVersionResponse$name": "

The name of the prompt version.

", + "GetPromptResponse$name": "

The name of the prompt.

", + "PromptSummary$name": "

The name of the prompt.

", + "UpdatePromptRequest$name": "

A name for the prompt.

", + "UpdatePromptResponse$name": "

The name of the prompt.

" + } + }, "PromptOverrideConfiguration": { "base": "

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

", "refs": { @@ -1425,12 +2466,67 @@ "PromptConfiguration$promptState": "

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.

" } }, + "PromptSummaries": { + "base": null, + "refs": { + "ListPromptsResponse$promptSummaries": "

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

" + } + }, + "PromptSummary": { + "base": "

Contains information about a prompt in your Prompt management tool.

This data type is used in the following API operations:

", + "refs": { + "PromptSummaries$member": null + } + }, + "PromptTemplateConfiguration": { + "base": "

Contains the message for a prompt. For more information, see Prompt management in Amazon Bedrock.

", + "refs": { + "PromptFlowNodeInlineConfiguration$templateConfiguration": "

Contains a prompt and variables in the prompt that can be replaced with values at runtime.

", + "PromptVariant$templateConfiguration": "

Contains configurations for the prompt template.

" + } + }, + "PromptTemplateType": { + "base": null, + "refs": { + "PromptFlowNodeInlineConfiguration$templateType": "

The type of prompt template.

", + "PromptVariant$templateType": "

The type of prompt template to use.

" + } + }, "PromptType": { "base": null, "refs": { "PromptConfiguration$promptType": "

The step in the agent sequence that this prompt configuration applies to.

" } }, + "PromptVariant": { + "base": "

Contains details about a variant of the prompt.

", + "refs": { + "PromptVariantList$member": null + } + }, + "PromptVariantList": { + "base": null, + "refs": { + "CreatePromptRequest$variants": "

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

", + "CreatePromptResponse$variants": "

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

", + "CreatePromptVersionResponse$variants": "

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

", + "GetPromptResponse$variants": "

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

", + "UpdatePromptRequest$variants": "

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

", + "UpdatePromptResponse$variants": "

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

" + } + }, + "PromptVariantName": { + "base": null, + "refs": { + "CreatePromptRequest$defaultVariant": "

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

", + "CreatePromptResponse$defaultVariant": "

The name of the default variant for your prompt.

", + "CreatePromptVersionResponse$defaultVariant": "

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

", + "GetPromptResponse$defaultVariant": "

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

", + "PromptVariant$name": "

The name of the prompt variant.

", + "UpdatePromptRequest$defaultVariant": "

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

", + "UpdatePromptResponse$defaultVariant": "

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

" + } + }, "ProvisionedModelIdentifier": { "base": null, "refs": { @@ -1509,34 +2605,66 @@ "refs": { } }, + "RetrievalFlowNodeConfiguration": { + "base": "

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.

", + "refs": { + "FlowNodeConfiguration$retrieval": "

Contains configurations for a Retrieval node in your flow. Retrieves data from an Amazon S3 location and returns it as the output.

" + } + }, + "RetrievalFlowNodeS3Configuration": { + "base": "

Contains configurations for the Amazon S3 location from which to retrieve data to return as the output from the node.

", + "refs": { + "RetrievalFlowNodeServiceConfiguration$s3": "

Contains configurations for the Amazon S3 location from which to retrieve data to return as the output from the node.

" + } + }, + "RetrievalFlowNodeServiceConfiguration": { + "base": "

Contains configurations for the service to use for retrieving data to return as the output from the node.

", + "refs": { + "RetrievalFlowNodeConfiguration$serviceConfiguration": "

Contains configurations for the service to use for retrieving data to return as the output from the node.

" + } + }, "S3BucketArn": { "base": null, "refs": { - "S3DataSourceConfiguration$bucketArn": "

The Amazon Resource Name (ARN) of the bucket that contains the data source.

" + "S3DataSourceConfiguration$bucketArn": "

The Amazon Resource Name (ARN) of the S3 bucket that contains your data.

" } }, "S3BucketName": { "base": null, "refs": { - "S3Identifier$s3BucketName": "

The name of the S3 bucket.

" + "RetrievalFlowNodeS3Configuration$bucketName": "

The name of the Amazon S3 bucket from which to retrieve data.

", + "S3Identifier$s3BucketName": "

The name of the S3 bucket.

", + "StorageFlowNodeS3Configuration$bucketName": "

The name of the Amazon S3 bucket in which to store the input into the node.

" + } + }, + "S3BucketUri": { + "base": null, + "refs": { + "S3Location$uri": "

The location's URI. For example, s3://my-bucket/chunk-processor/.

" } }, "S3DataSourceConfiguration": { - "base": "

Contains information about the S3 configuration of the data source.

", + "base": "

The configuration information to connect to Amazon S3 as your data source.

", "refs": { - "DataSourceConfiguration$s3Configuration": "

Contains details about the configuration of the S3 object containing the data source.

" + "DataSourceConfiguration$s3Configuration": "

The configuration information to connect to Amazon S3 as your data source.

" } }, "S3Identifier": { - "base": "

Contains information about the S3 object containing the resource.

", + "base": "

The identifier information for an Amazon S3 bucket.

", "refs": { "APISchema$s3": "

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

" } }, + "S3Location": { + "base": "

An Amazon S3 location.

", + "refs": { + "IntermediateStorage$s3Location": "

An S3 bucket path.

" + } + }, "S3ObjectKey": { "base": null, "refs": { - "S3Identifier$s3ObjectKey": "

The S3 object key containing the resource.

" + "S3Identifier$s3ObjectKey": "

The S3 object key for the S3 resource.

" } }, "S3Prefix": { @@ -1548,16 +2676,79 @@ "S3Prefixes": { "base": null, "refs": { - "S3DataSourceConfiguration$inclusionPrefixes": "

A list of S3 prefixes that define the object containing the data sources. For more information, see Organizing objects using prefixes.

" + "S3DataSourceConfiguration$inclusionPrefixes": "

A list of S3 prefixes to include certain files or content. For more information, see Organizing objects using prefixes.

" + } + }, + "SalesforceAuthType": { + "base": null, + "refs": { + "SalesforceSourceConfiguration$authType": "

The supported authentication type to authenticate and connect to your Salesforce instance.

" + } + }, + "SalesforceCrawlerConfiguration": { + "base": "

The configuration of the Salesforce content. For example, configuring specific types of Salesforce content.

", + "refs": { + "SalesforceDataSourceConfiguration$crawlerConfiguration": "

The configuration of the Salesforce content. For example, configuring specific types of Salesforce content.

" + } + }, + "SalesforceDataSourceConfiguration": { + "base": "

The configuration information to connect to Salesforce as your data source.

", + "refs": { + "DataSourceConfiguration$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.

" + } + }, + "SalesforceSourceConfiguration": { + "base": "

The endpoint information to connect to your Salesforce data source.

", + "refs": { + "SalesforceDataSourceConfiguration$sourceConfiguration": "

The endpoint information to connect to your Salesforce data source.

" } }, "SecretArn": { "base": null, "refs": { + "ConfluenceSourceConfiguration$credentialsSecretArn": "

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.

", "MongoDbAtlasConfiguration$credentialsSecretArn": "

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that contains user credentials for your MongoDB Atlas cluster.

", "PineconeConfiguration$credentialsSecretArn": "

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Pinecone API key.

", "RdsConfiguration$credentialsSecretArn": "

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Amazon RDS database.

", - "RedisEnterpriseCloudConfiguration$credentialsSecretArn": "

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Redis Enterprise Cloud database.

" + "RedisEnterpriseCloudConfiguration$credentialsSecretArn": "

The Amazon Resource Name (ARN) of the secret that you created in Secrets Manager that is linked to your Redis Enterprise Cloud database.

", + "SalesforceSourceConfiguration$credentialsSecretArn": "

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.

", + "SharePointSourceConfiguration$credentialsSecretArn": "

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.

" + } + }, + "SeedUrl": { + "base": "

The seed or starting point URL. You should be authorized to crawl the URL.

", + "refs": { + "SeedUrls$member": null + } + }, + "SeedUrls": { + "base": null, + "refs": { + "UrlConfiguration$seedUrls": "

One or more seed or starting point URLs.

" + } + }, + "SemanticChunkingConfiguration": { + "base": "

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.

", + "refs": { + "ChunkingConfiguration$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.

" + } + }, + "SemanticChunkingConfigurationBreakpointPercentileThresholdInteger": { + "base": null, + "refs": { + "SemanticChunkingConfiguration$breakpointPercentileThreshold": "

The dissimilarity threshold for splitting chunks.

" + } + }, + "SemanticChunkingConfigurationBufferSizeInteger": { + "base": null, + "refs": { + "SemanticChunkingConfiguration$bufferSize": "

The buffer size.

" + } + }, + "SemanticChunkingConfigurationMaxTokensInteger": { + "base": null, + "refs": { + "SemanticChunkingConfiguration$maxTokens": "

The maximum number of tokens that a chunk can contain.

" } }, "ServerSideEncryptionConfiguration": { @@ -1582,6 +2773,48 @@ "UpdateAgentRequest$idleSessionTTLInSeconds": "

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.

" } }, + "SharePointAuthType": { + "base": null, + "refs": { + "SharePointSourceConfiguration$authType": "

The supported authentication type to authenticate and connect to your SharePoint site/sites.

" + } + }, + "SharePointCrawlerConfiguration": { + "base": "

The configuration of the SharePoint content. For example, configuring specific types of SharePoint content.

", + "refs": { + "SharePointDataSourceConfiguration$crawlerConfiguration": "

The configuration of the SharePoint content. For example, configuring specific types of SharePoint content.

" + } + }, + "SharePointDataSourceConfiguration": { + "base": "

The configuration information to connect to SharePoint as your data source.

", + "refs": { + "DataSourceConfiguration$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.

" + } + }, + "SharePointDomain": { + "base": null, + "refs": { + "SharePointSourceConfiguration$domain": "

The domain of your SharePoint instance or site URL/URLs.

" + } + }, + "SharePointHostType": { + "base": null, + "refs": { + "SharePointSourceConfiguration$hostType": "

The supported host type, whether online/cloud or server/on-premises.

" + } + }, + "SharePointSiteUrls": { + "base": null, + "refs": { + "SharePointSourceConfiguration$siteUrls": "

A list of one or more SharePoint site URLs.

" + } + }, + "SharePointSourceConfiguration": { + "base": "

The endpoint information to connect to your SharePoint data source.

", + "refs": { + "SharePointDataSourceConfiguration$sourceConfiguration": "

The endpoint information to connect to your SharePoint data source.

" + } + }, "SortOrder": { "base": null, "refs": { @@ -1598,10 +2831,17 @@ "refs": { } }, + "StepType": { + "base": null, + "refs": { + "Transformation$stepToApply": "

When the service applies the transformation.

" + } + }, "StopSequences": { "base": null, "refs": { - "InferenceConfiguration$stopSequences": "

A list of stop sequences. A stop sequence is a sequence of characters that causes the model to stop generating the response.

" + "InferenceConfiguration$stopSequences": "

A list of stop sequences. A stop sequence is a sequence of characters that causes the model to stop generating the response.

", + "PromptModelInferenceConfiguration$stopSequences": "

A list of strings that define sequences after which the model will stop generating.

" } }, "StorageConfiguration": { @@ -1612,6 +2852,30 @@ "UpdateKnowledgeBaseRequest$storageConfiguration": "

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.

" } }, + "StorageDays": { + "base": null, + "refs": { + "MemoryConfiguration$storageDays": "

The number of days the agent is configured to retain the conversational context.

" + } + }, + "StorageFlowNodeConfiguration": { + "base": "

Contains configurations for a Storage node in a flow. This node stores the input in an Amazon S3 location that you specify.

", + "refs": { + "FlowNodeConfiguration$storage": "

Contains configurations for a Storage node in your flow. Stores an input in an Amazon S3 location.

" + } + }, + "StorageFlowNodeS3Configuration": { + "base": "

Contains configurations for the Amazon S3 location in which to store the input into the node.

", + "refs": { + "StorageFlowNodeServiceConfiguration$s3": "

Contains configurations for the Amazon S3 location in which to store the input into the node.

" + } + }, + "StorageFlowNodeServiceConfiguration": { + "base": "

Contains configurations for the service to use for storing the input into the node.

", + "refs": { + "StorageFlowNodeConfiguration$serviceConfiguration": "

Contains configurations for the service to use for storing the input into the node.

" + } + }, "String": { "base": null, "refs": { @@ -1660,7 +2924,11 @@ "refs": { "CreateAgentAliasRequest$tags": "

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

", "CreateAgentRequest$tags": "

Any tags that you want to attach to the agent.

", + "CreateFlowAliasRequest$tags": "

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

", + "CreateFlowRequest$tags": "

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

", "CreateKnowledgeBaseRequest$tags": "

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

", + "CreatePromptRequest$tags": "

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

", + "CreatePromptVersionRequest$tags": "

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

", "ListTagsForResourceResponse$tags": "

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

", "TagResourceRequest$tags": "

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

" } @@ -1668,7 +2936,20 @@ "Temperature": { "base": null, "refs": { - "InferenceConfiguration$temperature": "

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.

" + "InferenceConfiguration$temperature": "

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.

", + "PromptModelInferenceConfiguration$temperature": "

Controls the randomness of the response. Choose a lower value for more predictable outputs and a higher value for more surprising outputs.

" + } + }, + "TextPrompt": { + "base": null, + "refs": { + "TextPromptTemplateConfiguration$text": "

The message for the prompt.

" + } + }, + "TextPromptTemplateConfiguration": { + "base": "

Contains configurations for a text prompt template. To include a variable, enclose a word in double curly braces as in {{variable}}.

", + "refs": { + "PromptTemplateConfiguration$text": "

Contains configurations for the text in a message for a prompt.

" } }, "ThrottlingException": { @@ -1679,13 +2960,39 @@ "TopK": { "base": null, "refs": { - "InferenceConfiguration$topK": "

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.

" + "InferenceConfiguration$topK": "

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.

", + "PromptModelInferenceConfiguration$topK": "

The number of most-likely candidates that the model considers for the next token during generation.

" } }, "TopP": { "base": null, "refs": { - "InferenceConfiguration$topP": "

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.

" + "InferenceConfiguration$topP": "

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.

", + "PromptModelInferenceConfiguration$topP": "

The percentage of most-likely candidates that the model considers for the next token.

" + } + }, + "Transformation": { + "base": "

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.

", + "refs": { + "Transformations$member": null + } + }, + "TransformationFunction": { + "base": "

A Lambda function that processes documents.

", + "refs": { + "Transformation$transformationFunction": "

A Lambda function that processes documents.

" + } + }, + "TransformationLambdaConfiguration": { + "base": "

A Lambda function that processes documents.

", + "refs": { + "TransformationFunction$transformationLambdaConfiguration": "

The Lambda function.

" + } + }, + "Transformations": { + "base": null, + "refs": { + "CustomTransformationConfiguration$transformations": "

A Lambda function that processes documents.

" } }, "Type": { @@ -1754,6 +3061,26 @@ "refs": { } }, + "UpdateFlowAliasRequest": { + "base": null, + "refs": { + } + }, + "UpdateFlowAliasResponse": { + "base": null, + "refs": { + } + }, + "UpdateFlowRequest": { + "base": null, + "refs": { + } + }, + "UpdateFlowResponse": { + "base": null, + "refs": { + } + }, "UpdateKnowledgeBaseRequest": { "base": null, "refs": { @@ -1764,6 +3091,28 @@ "refs": { } }, + "UpdatePromptRequest": { + "base": null, + "refs": { + } + }, + "UpdatePromptResponse": { + "base": null, + "refs": { + } + }, + "Url": { + "base": null, + "refs": { + "SeedUrl$url": "

A seed or starting point URL.

" + } + }, + "UrlConfiguration": { + "base": "

The configuration of web URLs that you want to crawl. You should be authorized to crawl the URLs.

", + "refs": { + "WebSourceConfiguration$urlConfiguration": "

The configuration of the URL/URLs.

" + } + }, "ValidationException": { "base": "

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

", "refs": { @@ -1803,11 +3152,54 @@ "AgentKnowledgeBase$agentVersion": "

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

", "AgentSummary$latestAgentVersion": "

The latest version of the agent.

", "AgentVersionSummary$agentVersion": "

The version of the agent.

", + "CreatePromptResponse$version": "

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

", + "CreatePromptVersionResponse$version": "

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

", + "FlowAliasRoutingConfigurationListItem$flowVersion": "

The version that the alias maps to.

", "GetAgentActionGroupRequest$agentVersion": "

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

", "GetAgentKnowledgeBaseRequest$agentVersion": "

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

", + "GetPromptRequest$promptVersion": "

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

", + "GetPromptResponse$version": "

The version of the prompt.

", "ListAgentActionGroupsRequest$agentVersion": "

The version of the agent.

", "ListAgentKnowledgeBasesRequest$agentVersion": "

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

", - "PrepareAgentResponse$agentVersion": "

The version of the agent.

" + "PrepareAgentResponse$agentVersion": "

The version of the agent.

", + "PromptSummary$version": "

The version of the prompt that this summary applies to.

", + "UpdatePromptResponse$version": "

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

" + } + }, + "WebCrawlerConfiguration": { + "base": "

The configuration of web URLs that you want to crawl. You should be authorized to crawl the URLs.

", + "refs": { + "WebDataSourceConfiguration$crawlerConfiguration": "

The Web Crawler configuration details for the web data source.

" + } + }, + "WebCrawlerLimits": { + "base": "

The rate limits for the URLs that you want to crawl. You should be authorized to crawl the URLs.

", + "refs": { + "WebCrawlerConfiguration$crawlerLimits": "

The configuration of crawl limits for the web URLs.

" + } + }, + "WebCrawlerLimitsRateLimitInteger": { + "base": null, + "refs": { + "WebCrawlerLimits$rateLimit": "

The max rate at which pages are crawled, up to 300 per minute per host.

" + } + }, + "WebDataSourceConfiguration": { + "base": "

The configuration details for the web data source.

", + "refs": { + "DataSourceConfiguration$webConfiguration": "

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.

" + } + }, + "WebScopeType": { + "base": null, + "refs": { + "WebCrawlerConfiguration$scope": "

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\".

" + } + }, + "WebSourceConfiguration": { + "base": "

The configuration of the URL/URLs for the web content that you want to crawl. You should be authorized to crawl the URLs.

", + "refs": { + "WebDataSourceConfiguration$sourceConfiguration": "

The source configuration details for the web data source.

" } } } diff --git a/models/apis/bedrock-agent/2023-06-05/paginators-1.json b/models/apis/bedrock-agent/2023-06-05/paginators-1.json index 8e00fb72a90..97af0b0e426 100644 --- a/models/apis/bedrock-agent/2023-06-05/paginators-1.json +++ b/models/apis/bedrock-agent/2023-06-05/paginators-1.json @@ -36,6 +36,24 @@ "limit_key": "maxResults", "result_key": "dataSourceSummaries" }, + "ListFlowAliases": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "flowAliasSummaries" + }, + "ListFlowVersions": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "flowVersionSummaries" + }, + "ListFlows": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "flowSummaries" + }, "ListIngestionJobs": { "input_token": "nextToken", "output_token": "nextToken", @@ -47,6 +65,12 @@ "output_token": "nextToken", "limit_key": "maxResults", "result_key": "knowledgeBaseSummaries" + }, + "ListPrompts": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "promptSummaries" } } } diff --git a/models/apis/bedrock-runtime/2023-09-30/api-2.json b/models/apis/bedrock-runtime/2023-09-30/api-2.json index f71fdc1becc..e1ccc1db5a0 100644 --- a/models/apis/bedrock-runtime/2023-09-30/api-2.json +++ b/models/apis/bedrock-runtime/2023-09-30/api-2.json @@ -11,6 +11,40 @@ "uid": "bedrock-runtime-2023-09-30" }, "operations": { + "ApplyGuardrail": { + "errors": [ + { + "shape": "AccessDeniedException" + }, + { + "shape": "ResourceNotFoundException" + }, + { + "shape": "ThrottlingException" + }, + { + "shape": "InternalServerException" + }, + { + "shape": "ValidationException" + }, + { + "shape": "ServiceQuotaExceededException" + } + ], + "http": { + "method": "POST", + "requestUri": "/guardrail/{guardrailIdentifier}/version/{guardrailVersion}/apply", + "responseCode": 200 + }, + "input": { + "shape": "ApplyGuardrailRequest" + }, + "name": "ApplyGuardrail", + "output": { + "shape": "ApplyGuardrailResponse" + } + }, "Converse": { "errors": [ { @@ -199,6 +233,56 @@ "members": {}, "type": "structure" }, + "ApplyGuardrailRequest": { + "members": { + "content": { + "shape": "GuardrailContentBlockList" + }, + "guardrailIdentifier": { + "location": "uri", + "locationName": "guardrailIdentifier", + "shape": "GuardrailIdentifier" + }, + "guardrailVersion": { + "location": "uri", + "locationName": "guardrailVersion", + "shape": "GuardrailVersion" + }, + "source": { + "shape": "GuardrailContentSource" + } + }, + "required": [ + "guardrailIdentifier", + "guardrailVersion", + "source", + "content" + ], + "type": "structure" + }, + "ApplyGuardrailResponse": { + "members": { + "action": { + "shape": "GuardrailAction" + }, + "assessments": { + "shape": "GuardrailAssessmentList" + }, + "outputs": { + "shape": "GuardrailOutputContentList" + }, + "usage": { + "shape": "GuardrailUsage" + } + }, + "required": [ + "usage", + "action", + "outputs", + "assessments" + ], + "type": "structure" + }, "AutoToolChoice": { "members": {}, "type": "structure" @@ -592,11 +676,21 @@ "min": 1, "type": "blob" }, + "GuardrailAction": { + "enum": [ + "NONE", + "GUARDRAIL_INTERVENED" + ], + "type": "string" + }, "GuardrailAssessment": { "members": { "contentPolicy": { "shape": "GuardrailContentPolicyAssessment" }, + "contextualGroundingPolicy": { + "shape": "GuardrailContextualGroundingPolicyAssessment" + }, "sensitiveInformationPolicy": { "shape": "GuardrailSensitiveInformationPolicyAssessment" }, @@ -651,6 +745,21 @@ ], "type": "structure" }, + "GuardrailContentBlock": { + "members": { + "text": { + "shape": "GuardrailTextBlock" + } + }, + "type": "structure", + "union": true + }, + "GuardrailContentBlockList": { + "member": { + "shape": "GuardrailContentBlock" + }, + "type": "list" + }, "GuardrailContentFilter": { "members": { "action": { @@ -713,6 +822,98 @@ ], "type": "structure" }, + "GuardrailContentPolicyUnitsProcessed": { + "box": true, + "type": "integer" + }, + "GuardrailContentQualifier": { + "enum": [ + "grounding_source", + "query", + "guard_content" + ], + "type": "string" + }, + "GuardrailContentQualifierList": { + "member": { + "shape": "GuardrailContentQualifier" + }, + "type": "list" + }, + "GuardrailContentSource": { + "enum": [ + "INPUT", + "OUTPUT" + ], + "type": "string" + }, + "GuardrailContextualGroundingFilter": { + "members": { + "action": { + "shape": "GuardrailContextualGroundingPolicyAction" + }, + "score": { + "shape": "GuardrailContextualGroundingFilterScoreDouble" + }, + "threshold": { + "shape": "GuardrailContextualGroundingFilterThresholdDouble" + }, + "type": { + "shape": "GuardrailContextualGroundingFilterType" + } + }, + "required": [ + "type", + "threshold", + "score", + "action" + ], + "type": "structure" + }, + "GuardrailContextualGroundingFilterScoreDouble": { + "box": true, + "max": 1, + "min": 0, + "type": "double" + }, + "GuardrailContextualGroundingFilterThresholdDouble": { + "box": true, + "max": 1, + "min": 0, + "type": "double" + }, + "GuardrailContextualGroundingFilterType": { + "enum": [ + "GROUNDING", + "RELEVANCE" + ], + "type": "string" + }, + "GuardrailContextualGroundingFilters": { + "member": { + "shape": "GuardrailContextualGroundingFilter" + }, + "type": "list" + }, + "GuardrailContextualGroundingPolicyAction": { + "enum": [ + "BLOCKED", + "NONE" + ], + "type": "string" + }, + "GuardrailContextualGroundingPolicyAssessment": { + "members": { + "filters": { + "shape": "GuardrailContextualGroundingFilters" + } + }, + "type": "structure" + }, + "GuardrailContextualGroundingPolicyUnitsProcessed": { + "box": true, + "type": "integer" + }, "GuardrailConverseContentBlock": { "members": { "text": { @@ -722,8 +923,25 @@ "type": "structure", "union": true }, + "GuardrailConverseContentQualifier": { + "enum": [ + "grounding_source", + "query", + "guard_content" + ], + "type": "string" + }, + "GuardrailConverseContentQualifierList": { + "member": { + "shape": "GuardrailConverseContentQualifier" + }, + "type": "list" + }, "GuardrailConverseTextBlock": { "members": { + "qualifiers": { + "shape": "GuardrailConverseContentQualifierList" + }, "text": { "shape": "String" } @@ -791,6 +1009,20 @@ ], "type": "string" }, + "GuardrailOutputContent": { + "members": { + "text": { + "shape": "GuardrailOutputText" + } + }, + "type": "structure" + }, + "GuardrailOutputContentList": { + "member": { + "shape": "GuardrailOutputContent" + }, + "type": "list" + }, "GuardrailOutputText": { "type": "string" }, @@ -903,6 +1135,14 @@ ], "type": "structure" }, + "GuardrailSensitiveInformationPolicyFreeUnitsProcessed": { + "box": true, + "type": "integer" + }, + "GuardrailSensitiveInformationPolicyUnitsProcessed": { + "box": true, + "type": "integer" + }, "GuardrailStreamConfiguration": { "members": { "guardrailIdentifier": { @@ -931,6 +1171,20 @@ ], "type": "string" }, + "GuardrailTextBlock": { + "members": { + "qualifiers": { + "shape": "GuardrailContentQualifierList" + }, + "text": { + "shape": "String" + } + }, + "required": [ + "text" + ], + "type": "structure" + }, "GuardrailTopic": { "members": { "action": { @@ -973,6 +1227,10 @@ ], "type": "structure" }, + "GuardrailTopicPolicyUnitsProcessed": { + "box": true, + "type": "integer" + }, "GuardrailTopicType": { "enum": [ "DENY" @@ -1000,6 +1258,37 @@ }, "type": "structure" }, + "GuardrailUsage": { + "members": { + "contentPolicyUnits": { + "shape": "GuardrailContentPolicyUnitsProcessed" + }, + "contextualGroundingPolicyUnits": { + "shape": "GuardrailContextualGroundingPolicyUnitsProcessed" + }, + "sensitiveInformationPolicyFreeUnits": { + "shape": "GuardrailSensitiveInformationPolicyFreeUnitsProcessed" + }, + "sensitiveInformationPolicyUnits": { + "shape": "GuardrailSensitiveInformationPolicyUnitsProcessed" + }, + "topicPolicyUnits": { + "shape": "GuardrailTopicPolicyUnitsProcessed" + }, + "wordPolicyUnits": { + "shape": "GuardrailWordPolicyUnitsProcessed" + } + }, + "required": [ + "topicPolicyUnits", + "contentPolicyUnits", + "wordPolicyUnits", + "sensitiveInformationPolicyUnits", + "sensitiveInformationPolicyFreeUnits", + "contextualGroundingPolicyUnits" + ], + "type": "structure" + }, "GuardrailVersion": { "pattern": "(([1-9][0-9]{0,7})|(DRAFT))", "type": "string" @@ -1025,6 +1314,10 @@ ], "type": "structure" }, + "GuardrailWordPolicyUnitsProcessed": { + "box": true, + "type": "integer" + }, "ImageBlock": { "members": { "format": { diff --git a/models/apis/bedrock-runtime/2023-09-30/docs-2.json b/models/apis/bedrock-runtime/2023-09-30/docs-2.json index f9803ea0e2d..e4b04391bc2 100644 --- a/models/apis/bedrock-runtime/2023-09-30/docs-2.json +++ b/models/apis/bedrock-runtime/2023-09-30/docs-2.json @@ -2,6 +2,7 @@ "version": "2.0", "service": "

Describes the API operations for running inference using Amazon Bedrock models.

", "operations": { + "ApplyGuardrail": "

The action to apply a guardrail.

", "Converse": "

Sends messages to the specified Amazon Bedrock model. Converse provides a consistent interface that works with all models that support messages. This allows you to write code once and use it with different models. Should a model have unique inference parameters, you can also pass those unique parameters to the model.

For information about the Converse API, see Use the Converse API in the Amazon Bedrock User Guide. To use a guardrail, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide. To use a tool with a model, see Tool use (Function calling) in the Amazon Bedrock User Guide

For example code, see Converse API examples in the Amazon Bedrock User Guide.

This operation requires permission for the bedrock:InvokeModel action.

", "ConverseStream": "

Sends messages to the specified Amazon Bedrock model and returns the response in a stream. ConverseStream provides a consistent API that works with all Amazon Bedrock models that support messages. This allows you to write code once and use it with different models. Should a model have unique inference parameters, you can also pass those unique parameters to the model.

To find out if a model supports streaming, call GetFoundationModel and check the responseStreamingSupported field in the response.

For information about the Converse API, see Use the Converse API in the Amazon Bedrock User Guide. To use a guardrail, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide. To use a tool with a model, see Tool use (Function calling) in the Amazon Bedrock User Guide

For example code, see Conversation streaming example in the Amazon Bedrock User Guide.

This operation requires permission for the bedrock:InvokeModelWithResponseStream action.

", "InvokeModel": "

Invokes the specified Amazon Bedrock model to run inference using the prompt and inference parameters provided in the request body. You use model inference to generate text, images, and embeddings.

For example code, see Invoke model code examples in the Amazon Bedrock User Guide.

This operation requires permission for the bedrock:InvokeModel action.

", @@ -19,6 +20,16 @@ "ToolChoice$any": "

The model must request at least one tool (no text is generated).

" } }, + "ApplyGuardrailRequest": { + "base": null, + "refs": { + } + }, + "ApplyGuardrailResponse": { + "base": null, + "refs": { + } + }, "AutoToolChoice": { "base": "

The Model automatically decides if a tool should be called or whether to generate text instead. For example, {\"auto\" : {}}.

", "refs": { @@ -34,7 +45,7 @@ } }, "ContentBlock": { - "base": "

A block of content for a message that you pass to, or receive from, a model with the Converse API (Converse and ConverseStream).

", + "base": "

A block of content for a message that you pass to, or receive from, a model with the Converse or ConverseStream API operations.

", "refs": { "ContentBlocks$member": null } @@ -72,7 +83,7 @@ "ContentBlocks": { "base": null, "refs": { - "Message$content": "

The message content.

" + "Message$content": "

The message content. Note the following restrictions:

" } }, "ConversationRole": { @@ -164,13 +175,13 @@ } }, "ConverseStreamTrace": { - "base": "

The trace object in a response from ConverseStream. Currently, you can only trace guardrails.

", + "base": "

The trace object in a response from ConverseStream. Currently, you can only trace guardrails.

", "refs": { - "ConverseStreamMetadataEvent$trace": "

The trace object in the response from ConverseStream that contains information about the guardrail behavior.

" + "ConverseStreamMetadataEvent$trace": "

The trace object in the response from ConverseStream that contains information about the guardrail behavior.

" } }, "ConverseTrace": { - "base": "

The trace object in a response from Converse. Currently, you can only trace guardrails.

", + "base": "

The trace object in a response from Converse. Currently, you can only trace guardrails.

", "refs": { "ConverseResponse$trace": "

A trace object that contains information about the Guardrail behavior.

" } @@ -188,7 +199,7 @@ } }, "DocumentBlock": { - "base": "

A document to include in a message when sending a Converse or ConverseStream request. You can include up to 5 documents in a request. The maximum document size is 50 MB.

", + "base": "

A document to include in a message.

", "refs": { "ContentBlock$document": "

A document to include in the message.

", "ToolResultContentBlock$document": "

A tool result that is a document.

" @@ -197,7 +208,7 @@ "DocumentBlockNameString": { "base": null, "refs": { - "DocumentBlock$name": "

A name for the document.

" + "DocumentBlock$name": "

A name for the document. The name can only contain the following characters:

This field is vulnerable to prompt injections, because the model might inadvertently interpret it as instructions. Therefore, we recommend that you specify a neutral name.

" } }, "DocumentFormat": { @@ -207,7 +218,7 @@ } }, "DocumentSource": { - "base": "

Contains the content of the document included in a message when sending a Converse or ConverseStream request or in the response.

", + "base": "

Contains the content of a document.

", "refs": { "DocumentBlock$source": "

Contains the content of the document.

" } @@ -215,7 +226,13 @@ "DocumentSourceBytesBlob": { "base": null, "refs": { - "DocumentSource$bytes": "

A base64-encoded string of a UTF-8 encoded file, that is the document to include in the message.

" + "DocumentSource$bytes": "

The raw bytes for the document. If you use an Amazon Web Services SDK, you don't need to encode the bytes in base64.

" + } + }, + "GuardrailAction": { + "base": null, + "refs": { + "ApplyGuardrailResponse$action": "

The action taken in the response from the guardrail.

" } }, "GuardrailAssessment": { @@ -228,6 +245,7 @@ "GuardrailAssessmentList": { "base": null, "refs": { + "ApplyGuardrailResponse$assessments": "

The assessment details in the response from the guardrail.

", "GuardrailAssessmentListMap$value": null } }, @@ -244,11 +262,23 @@ } }, "GuardrailConfiguration": { - "base": "

Configuration information for a guardrail that you use with the Converse action.

", + "base": "

Configuration information for a guardrail that you use with the Converse operation.

", "refs": { "ConverseRequest$guardrailConfig": "

Configuration information for a guardrail that you want to use in the request.

" } }, + "GuardrailContentBlock": { + "base": "

The content block to be evaluated by the guardrail.

", + "refs": { + "GuardrailContentBlockList$member": null + } + }, + "GuardrailContentBlockList": { + "base": null, + "refs": { + "ApplyGuardrailRequest$content": "

The content details used in the request to apply the guardrail.

" + } + }, "GuardrailContentFilter": { "base": "

The content filter for a guardrail.

", "refs": { @@ -285,11 +315,95 @@ "GuardrailAssessment$contentPolicy": "

The content policy.

" } }, + "GuardrailContentPolicyUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$contentPolicyUnits": "

The content policy units processed by the guardrail.

" + } + }, + "GuardrailContentQualifier": { + "base": null, + "refs": { + "GuardrailContentQualifierList$member": null + } + }, + "GuardrailContentQualifierList": { + "base": null, + "refs": { + "GuardrailTextBlock$qualifiers": "

The qualifiers describing the text block.

" + } + }, + "GuardrailContentSource": { + "base": null, + "refs": { + "ApplyGuardrailRequest$source": "

The source of data used in the request to apply the guardrail.

" + } + }, + "GuardrailContextualGroundingFilter": { + "base": "

The details for the guardrails contextual grounding filter.

", + "refs": { + "GuardrailContextualGroundingFilters$member": null + } + }, + "GuardrailContextualGroundingFilterScoreDouble": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$score": "

The score generated by contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingFilterThresholdDouble": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$threshold": "

The threshold used by contextual grounding filter to determine whether the content is grounded or not.

" + } + }, + "GuardrailContextualGroundingFilterType": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$type": "

The contextual grounding filter type.

" + } + }, + "GuardrailContextualGroundingFilters": { + "base": null, + "refs": { + "GuardrailContextualGroundingPolicyAssessment$filters": "

The filter details for the guardrails contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingPolicyAction": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$action": "

The action performed by the guardrails contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingPolicyAssessment": { + "base": "

The policy assessment details for the guardrails contextual grounding filter.

", + "refs": { + "GuardrailAssessment$contextualGroundingPolicy": "

The contextual grounding policy used for the guardrail assessment.

" + } + }, + "GuardrailContextualGroundingPolicyUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$contextualGroundingPolicyUnits": "

The contextual grounding policy units processed by the guardrail.

" + } + }, "GuardrailConverseContentBlock": { - "base": "

A content block for selective guarding with the Converse API (Converse and ConverseStream).

", + "base": "

A content block for selective guarding with the Converse or ConverseStream API operations.

", "refs": { "ContentBlock$guardContent": "

Contains the content to assess with the guardrail. If you don't specify guardContent in a call to the Converse API, the guardrail (if passed in the Converse API) assesses the entire message.

For more information, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide.

 </p> 
", - "SystemContentBlock$guardContent": "

A content block to assess with the guardrail. Use with the Converse API (Converse and ConverseStream).

For more information, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide.

" + "SystemContentBlock$guardContent": "

A content block to assess with the guardrail. Use with the Converse or ConverseStream API operations.

For more information, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide.

" + } + }, + "GuardrailConverseContentQualifier": { + "base": null, + "refs": { + "GuardrailConverseContentQualifierList$member": null + } + }, + "GuardrailConverseContentQualifierList": { + "base": null, + "refs": { + "GuardrailConverseTextBlock$qualifiers": "

The qualifier details for the guardrails contextual grounding filter.

" } }, "GuardrailConverseTextBlock": { @@ -313,6 +427,7 @@ "GuardrailIdentifier": { "base": null, "refs": { + "ApplyGuardrailRequest$guardrailIdentifier": "

The guardrail identifier used in the request to apply the guardrail.

", "GuardrailConfiguration$guardrailIdentifier": "

The identifier for the guardrail.

", "GuardrailStreamConfiguration$guardrailIdentifier": "

The identifier for the guardrail.

", "InvokeModelRequest$guardrailIdentifier": "

The unique identifier of the guardrail that you want to use. If you don't provide a value, no guardrail is applied to the invocation.

An error will be thrown in the following situations.

", @@ -337,9 +452,22 @@ "GuardrailManagedWord$type": "

The type for the managed word.

" } }, + "GuardrailOutputContent": { + "base": "

The output content produced by the guardrail.

", + "refs": { + "GuardrailOutputContentList$member": null + } + }, + "GuardrailOutputContentList": { + "base": null, + "refs": { + "ApplyGuardrailResponse$outputs": "

The output details in the response from the guardrail.

" + } + }, "GuardrailOutputText": { "base": null, "refs": { + "GuardrailOutputContent$text": "

The specific text for the output content produced by the guardrail.

", "ModelOutputs$member": null } }, @@ -386,6 +514,18 @@ "GuardrailAssessment$sensitiveInformationPolicy": "

The sensitive information policy.

" } }, + "GuardrailSensitiveInformationPolicyFreeUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$sensitiveInformationPolicyFreeUnits": "

The sensitive information policy free units processed by the guardrail.

" + } + }, + "GuardrailSensitiveInformationPolicyUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$sensitiveInformationPolicyUnits": "

The sensitive information policy units processed by the guardrail.

" + } + }, "GuardrailStreamConfiguration": { "base": "

Configuration information for a guardrail that you use with the ConverseStream action.

", "refs": { @@ -398,6 +538,12 @@ "GuardrailStreamConfiguration$streamProcessingMode": "

The processing mode.

The processing mode. For more information, see Configure streaming response behavior in the Amazon Bedrock User Guide.

" } }, + "GuardrailTextBlock": { + "base": "

The text block to be evaluated by the guardrail.

", + "refs": { + "GuardrailContentBlock$text": "

Text within content block to be evaluated by the guardrail.

" + } + }, "GuardrailTopic": { "base": "

Information about a topic guardrail.

", "refs": { @@ -422,6 +568,12 @@ "GuardrailAssessment$topicPolicy": "

The topic policy.

" } }, + "GuardrailTopicPolicyUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$topicPolicyUnits": "

The topic policy units processed by the guardrail.

" + } + }, "GuardrailTopicType": { "base": null, "refs": { @@ -442,9 +594,16 @@ "ConverseTrace$guardrail": "

The guardrail trace object.

" } }, + "GuardrailUsage": { + "base": "

The details on the use of the guardrail.

", + "refs": { + "ApplyGuardrailResponse$usage": "

The usage details in the response from the guardrail.

" + } + }, "GuardrailVersion": { "base": null, "refs": { + "ApplyGuardrailRequest$guardrailVersion": "

The guardrail version used in the request to apply the guardrail.

", "GuardrailConfiguration$guardrailVersion": "

The version of the guardrail.

", "GuardrailStreamConfiguration$guardrailVersion": "

The version of the guardrail.

", "InvokeModelRequest$guardrailVersion": "

The version number for the guardrail. The value can also be DRAFT.

", @@ -464,6 +623,12 @@ "GuardrailAssessment$wordPolicy": "

The word policy.

" } }, + "GuardrailWordPolicyUnitsProcessed": { + "base": null, + "refs": { + "GuardrailUsage$wordPolicyUnits": "

The word policy units processed by the guardrail.

" + } + }, "ImageBlock": { "base": "

Image content for a message.

", "refs": { @@ -486,7 +651,7 @@ "ImageSourceBytesBlob": { "base": null, "refs": { - "ImageSource$bytes": "

The raw image bytes for the image. If you use an AWS SDK, you don't need to base64 encode the image bytes.

" + "ImageSource$bytes": "

The raw image bytes for the image. If you use an AWS SDK, you don't need to encode the image bytes in base64.

" } }, "InferenceConfiguration": { @@ -722,6 +887,7 @@ "GuardrailRegexFilter$name": "

The regex filter name.

", "GuardrailRegexFilter$match": "

The regesx filter match.

", "GuardrailRegexFilter$regex": "

The regex query.

", + "GuardrailTextBlock$text": "

The input text details to be evaluated by the guardrail.

", "GuardrailTopic$name": "

The name for the guardrail.

", "ToolResultContentBlock$text": "

A tool result that is text.

", "ToolUseBlockDelta$input": "

The input for a requested tool.

" @@ -773,7 +939,7 @@ } }, "Tool": { - "base": "

Information about a tool that you can use with the Converse API.

", + "base": "

Information about a tool that you can use with the Converse API. For more information, see Tool use (function calling) in the Amazon Bedrock User Guide.

", "refs": { "ToolConfigurationToolsList$member": null } @@ -785,7 +951,7 @@ } }, "ToolConfiguration": { - "base": "

Configuration information for the tools that you pass to a model.

This field is only supported by Anthropic Claude 3, Cohere Command R, Cohere Command R+, and Mistral Large models.

", + "base": "

Configuration information for the tools that you pass to a model. For more information, see Tool use (function calling) in the Amazon Bedrock User Guide.

This field is only supported by Anthropic Claude 3, Cohere Command R, Cohere Command R+, and Mistral Large models.

", "refs": { "ConverseRequest$toolConfig": "

Configuration information for the tools that the model can use when generating a response.

This field is only supported by Anthropic Claude 3, Cohere Command R, Cohere Command R+, and Mistral Large models.

", "ConverseStreamRequest$toolConfig": "

Configuration information for the tools that the model can use when generating a response.

This field is only supported by Anthropic Claude 3 models.

" @@ -845,7 +1011,7 @@ "ToolUseBlock": { "base": "

A tool use content block. Contains information about a tool that the model is requesting be run., The model uses the result from the tool to generate a response.

", "refs": { - "ContentBlock$toolUse": "

Information about a tool use request from a model.

" + "ContentBlock$toolUse": "

Information about a tool use request from a model.

" } }, "ToolUseBlockDelta": { diff --git a/models/apis/bedrock/2023-04-20/api-2.json b/models/apis/bedrock/2023-04-20/api-2.json index e700d8d5caf..da802ef9ce8 100644 --- a/models/apis/bedrock/2023-04-20/api-2.json +++ b/models/apis/bedrock/2023-04-20/api-2.json @@ -665,6 +665,7 @@ "contentPolicyConfig":{"shape":"GuardrailContentPolicyConfig"}, "wordPolicyConfig":{"shape":"GuardrailWordPolicyConfig"}, "sensitiveInformationPolicyConfig":{"shape":"GuardrailSensitiveInformationPolicyConfig"}, + "contextualGroundingPolicyConfig":{"shape":"GuardrailContextualGroundingPolicyConfig"}, "blockedInputMessaging":{"shape":"GuardrailBlockedMessaging"}, "blockedOutputsMessaging":{"shape":"GuardrailBlockedMessaging"}, "kmsKeyId":{"shape":"KmsKeyId"}, @@ -1322,6 +1323,7 @@ "contentPolicy":{"shape":"GuardrailContentPolicy"}, "wordPolicy":{"shape":"GuardrailWordPolicy"}, "sensitiveInformationPolicy":{"shape":"GuardrailSensitiveInformationPolicy"}, + "contextualGroundingPolicy":{"shape":"GuardrailContextualGroundingPolicy"}, "createdAt":{"shape":"Timestamp"}, "updatedAt":{"shape":"Timestamp"}, "statusReasons":{"shape":"GuardrailStatusReasons"}, @@ -1506,6 +1508,69 @@ "filtersConfig":{"shape":"GuardrailContentFiltersConfig"} } }, + "GuardrailContextualGroundingFilter":{ + "type":"structure", + "required":[ + "type", + "threshold" + ], + "members":{ + "type":{"shape":"GuardrailContextualGroundingFilterType"}, + "threshold":{"shape":"GuardrailContextualGroundingFilterThresholdDouble"} + } + }, + "GuardrailContextualGroundingFilterConfig":{ + "type":"structure", + "required":[ + "type", + "threshold" + ], + "members":{ + "type":{"shape":"GuardrailContextualGroundingFilterType"}, + "threshold":{"shape":"GuardrailContextualGroundingFilterConfigThresholdDouble"} + } + }, + "GuardrailContextualGroundingFilterConfigThresholdDouble":{ + "type":"double", + "box":true, + "min":0 + }, + "GuardrailContextualGroundingFilterThresholdDouble":{ + "type":"double", + "box":true, + "min":0 + }, + "GuardrailContextualGroundingFilterType":{ + "type":"string", + "enum":[ + "GROUNDING", + "RELEVANCE" + ] + }, + "GuardrailContextualGroundingFilters":{ + "type":"list", + "member":{"shape":"GuardrailContextualGroundingFilter"}, + "min":1 + }, + "GuardrailContextualGroundingFiltersConfig":{ + "type":"list", + "member":{"shape":"GuardrailContextualGroundingFilterConfig"}, + "min":1 + }, + "GuardrailContextualGroundingPolicy":{ + "type":"structure", + "required":["filters"], + "members":{ + "filters":{"shape":"GuardrailContextualGroundingFilters"} + } + }, + "GuardrailContextualGroundingPolicyConfig":{ + "type":"structure", + "required":["filtersConfig"], + "members":{ + "filtersConfig":{"shape":"GuardrailContextualGroundingFiltersConfig"} + } + }, "GuardrailDescription":{ "type":"string", "max":200, @@ -2783,6 +2848,7 @@ "contentPolicyConfig":{"shape":"GuardrailContentPolicyConfig"}, "wordPolicyConfig":{"shape":"GuardrailWordPolicyConfig"}, "sensitiveInformationPolicyConfig":{"shape":"GuardrailSensitiveInformationPolicyConfig"}, + "contextualGroundingPolicyConfig":{"shape":"GuardrailContextualGroundingPolicyConfig"}, "blockedInputMessaging":{"shape":"GuardrailBlockedMessaging"}, "blockedOutputsMessaging":{"shape":"GuardrailBlockedMessaging"}, "kmsKeyId":{"shape":"KmsKeyId"} diff --git a/models/apis/bedrock/2023-04-20/docs-2.json b/models/apis/bedrock/2023-04-20/docs-2.json index c27d99bdd5c..74b08f9ca35 100644 --- a/models/apis/bedrock/2023-04-20/docs-2.json +++ b/models/apis/bedrock/2023-04-20/docs-2.json @@ -3,7 +3,7 @@ "service": "

Describes the API operations for creating, managing, fine-turning, and evaluating Amazon Bedrock models.

", "operations": { "CreateEvaluationJob": "

API operation for creating and managing Amazon Bedrock automatic model evaluation jobs and model evaluation jobs that use human workers. To learn more about the requirements for creating a model evaluation job see, Model evaluations.

", - "CreateGuardrail": "

Creates a guardrail to block topics and to filter out harmful content.

", + "CreateGuardrail": "

Creates a guardrail to block topics and to implement safeguards for your generative AI applications.

You can configure the following policies in a guardrail to avoid undesirable and harmful content, filter out denied topics and words, and remove sensitive information for privacy protection.

In addition to the above policies, you can also configure the messages to be returned to the user if a user input or model response is in violation of the policies defined in the guardrail.

For more information, see Guardrails for Amazon Bedrock in the Amazon Bedrock User Guide.

", "CreateGuardrailVersion": "

Creates a version of the guardrail. Use this API to create a snapshot of the guardrail when you are satisfied with a configuration, or to compare the configuration with another version.

", "CreateModelCustomizationJob": "

Creates a fine-tuning job to customize a base model.

You specify the base foundation model and the location of the training data. After the model-customization job completes successfully, your custom model resource will be ready to use. Amazon Bedrock returns validation loss metrics and output generations after the job completes.

For information on the format of training and validation data, see Prepare the datasets.

Model-customization jobs are asynchronous and the completion time depends on the base model and the training/validation data size. To monitor a job, use the GetModelCustomizationJob operation to retrieve the job status.

For more information, see Custom models in the Amazon Bedrock User Guide.

", "CreateProvisionedModelThroughput": "

Creates dedicated throughput for a base or custom model with the model units and for the duration that you specify. For pricing details, see Amazon Bedrock Pricing. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.

", @@ -30,7 +30,7 @@ "StopModelCustomizationJob": "

Stops an active model customization job. For more information, see Custom models in the Amazon Bedrock User Guide.

", "TagResource": "

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

", "UntagResource": "

Remove one or more tags from a resource. For more information, see Tagging resources in the Amazon Bedrock User Guide.

", - "UpdateGuardrail": "

Updates a guardrail with the values you specify.

", + "UpdateGuardrail": "

Updates a guardrail with the values you specify.

", "UpdateProvisionedModelThroughput": "

Updates the name or associated model for a Provisioned Throughput. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.

" }, "shapes": { @@ -553,10 +553,10 @@ "GuardrailArn": { "base": null, "refs": { - "CreateGuardrailResponse$guardrailArn": "

The ARN of the guardrail that was created.

", - "GetGuardrailResponse$guardrailArn": "

The ARN of the guardrail that was created.

", + "CreateGuardrailResponse$guardrailArn": "

The ARN of the guardrail.

", + "GetGuardrailResponse$guardrailArn": "

The ARN of the guardrail.

", "GuardrailSummary$arn": "

The ARN of the guardrail.

", - "UpdateGuardrailResponse$guardrailArn": "

The ARN of the guardrail that was created.

" + "UpdateGuardrailResponse$guardrailArn": "

The ARN of the guardrail.

" } }, "GuardrailBlockedMessaging": { @@ -577,7 +577,7 @@ } }, "GuardrailContentFilterConfig": { - "base": "

Contains filter strengths for harmful content. Guardrails support the following content filters to detect and filter harmful user inputs and FM-generated outputs.

Content filtering depends on the confidence classification of user inputs and FM responses across each of the four harmful categories. All input and output statements are classified into one of four confidence levels (NONE, LOW, MEDIUM, HIGH) for each harmful category. For example, if a statement is classified as Hate with HIGH confidence, the likelihood of the statement representing hateful content is high. A single statement can be classified across multiple categories with varying confidence levels. For example, a single statement can be classified as Hate with HIGH confidence, Insults with LOW confidence, Sexual with NONE confidence, and Violence with MEDIUM confidence.

For more information, see Guardrails content filters.

This data type is used in the following API operations:

", + "base": "

Contains filter strengths for harmful content. Guardrails support the following content filters to detect and filter harmful user inputs and FM-generated outputs.

Content filtering depends on the confidence classification of user inputs and FM responses across each of the four harmful categories. All input and output statements are classified into one of four confidence levels (NONE, LOW, MEDIUM, HIGH) for each harmful category. For example, if a statement is classified as Hate with HIGH confidence, the likelihood of the statement representing hateful content is high. A single statement can be classified across multiple categories with varying confidence levels. For example, a single statement can be classified as Hate with HIGH confidence, Insults with LOW confidence, Sexual with NONE confidence, and Violence with MEDIUM confidence.

For more information, see Guardrails content filters.

", "refs": { "GuardrailContentFiltersConfig$member": null } @@ -608,12 +608,68 @@ } }, "GuardrailContentPolicyConfig": { - "base": "

Contains details about how to handle harmful content.

This data type is used in the following API operations:

", + "base": "

Contains details about how to handle harmful content.

", "refs": { "CreateGuardrailRequest$contentPolicyConfig": "

The content filter policies to configure for the guardrail.

", "UpdateGuardrailRequest$contentPolicyConfig": "

The content policy to configure for the guardrail.

" } }, + "GuardrailContextualGroundingFilter": { + "base": "

The details for the guardrails contextual grounding filter.

", + "refs": { + "GuardrailContextualGroundingFilters$member": null + } + }, + "GuardrailContextualGroundingFilterConfig": { + "base": "

The filter configuration details for the guardrails contextual grounding filter.

", + "refs": { + "GuardrailContextualGroundingFiltersConfig$member": null + } + }, + "GuardrailContextualGroundingFilterConfigThresholdDouble": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilterConfig$threshold": "

The threshold details for the guardrails contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingFilterThresholdDouble": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$threshold": "

The threshold details for the guardrails contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingFilterType": { + "base": null, + "refs": { + "GuardrailContextualGroundingFilter$type": "

The filter type details for the guardrails contextual grounding filter.

", + "GuardrailContextualGroundingFilterConfig$type": "

The filter details for the guardrails contextual grounding filter.

" + } + }, + "GuardrailContextualGroundingFilters": { + "base": null, + "refs": { + "GuardrailContextualGroundingPolicy$filters": "

The filter details for the guardrails contextual grounding policy.

" + } + }, + "GuardrailContextualGroundingFiltersConfig": { + "base": null, + "refs": { + "GuardrailContextualGroundingPolicyConfig$filtersConfig": "

The filter configuration details for the guardrails contextual grounding policy.

" + } + }, + "GuardrailContextualGroundingPolicy": { + "base": "

The details for the guardrails contextual grounding policy.

", + "refs": { + "GetGuardrailResponse$contextualGroundingPolicy": "

The contextual grounding policy used in the guardrail.

" + } + }, + "GuardrailContextualGroundingPolicyConfig": { + "base": "

The policy configuration details for the guardrails contextual grounding policy.

", + "refs": { + "CreateGuardrailRequest$contextualGroundingPolicyConfig": "

The contextual grounding policy configuration used to create a guardrail.

", + "UpdateGuardrailRequest$contextualGroundingPolicyConfig": "

The contextual grounding policy configuration used to update a guardrail.

" + } + }, "GuardrailDescription": { "base": null, "refs": { @@ -627,7 +683,7 @@ "GuardrailDraftVersion": { "base": null, "refs": { - "CreateGuardrailResponse$version": "

The version of the guardrail that was created. This value should be 1.

", + "CreateGuardrailResponse$version": "

The version of the guardrail that was created. This value will always be DRAFT.

", "UpdateGuardrailResponse$version": "

The version of the guardrail.

" } }, @@ -665,11 +721,11 @@ "GuardrailIdentifier": { "base": null, "refs": { - "CreateGuardrailVersionRequest$guardrailIdentifier": "

The unique identifier of the guardrail.

", - "DeleteGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail.

", - "GetGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail for which to get details.

", - "ListGuardrailsRequest$guardrailIdentifier": "

The unique identifier of the guardrail.

", - "UpdateGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail

" + "CreateGuardrailVersionRequest$guardrailIdentifier": "

The unique identifier of the guardrail. This can be an ID or the ARN.

", + "DeleteGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail. This can be an ID or the ARN.

", + "GetGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail for which to get details. This can be an ID or the ARN.

", + "ListGuardrailsRequest$guardrailIdentifier": "

The unique identifier of the guardrail. This can be an ID or the ARN.

", + "UpdateGuardrailRequest$guardrailIdentifier": "

The unique identifier of the guardrail. This can be an ID or the ARN.

" } }, "GuardrailManagedWordLists": { @@ -685,7 +741,7 @@ } }, "GuardrailManagedWords": { - "base": "

The managed word list that was configured for the guardrail. (This is a list of words that are pre-defined and managed by Guardrails only.)

", + "base": "

The managed word list that was configured for the guardrail. (This is a list of words that are pre-defined and managed by guardrails only.)

", "refs": { "GuardrailManagedWordLists$member": null } @@ -747,7 +803,7 @@ "base": null, "refs": { "GuardrailPiiEntity$type": "

The type of PII entity. For example, Social Security Number.

", - "GuardrailPiiEntityConfig$type": "

Configure guardrail type when the PII entity is detected.

" + "GuardrailPiiEntityConfig$type": "

Configure guardrail type when the PII entity is detected.

The following PIIs are used to block or mask sensitive information:

" } }, "GuardrailRegex": { @@ -870,7 +926,7 @@ } }, "GuardrailTopicConfig": { - "base": "

Details about topics for the guardrail to identify and deny.

This data type is used in the following API operations:

", + "base": "

Details about topics for the guardrail to identify and deny.

", "refs": { "GuardrailTopicsConfig$member": null } @@ -909,7 +965,7 @@ } }, "GuardrailTopicPolicyConfig": { - "base": "

Contains details about topics that the guardrail should identify and deny.

This data type is used in the following API operations:

", + "base": "

Contains details about topics that the guardrail should identify and deny.

", "refs": { "CreateGuardrailRequest$topicPolicyConfig": "

The topic policies to configure for the guardrail.

", "UpdateGuardrailRequest$topicPolicyConfig": "

The topic policy to configure for the guardrail.

" diff --git a/models/apis/ec2/2016-11-15/api-2.json b/models/apis/ec2/2016-11-15/api-2.json index 3ee66003f4f..878ff1774f5 100755 --- a/models/apis/ec2/2016-11-15/api-2.json +++ b/models/apis/ec2/2016-11-15/api-2.json @@ -11619,7 +11619,8 @@ "TagSpecifications":{ "shape":"TagSpecificationList", "locationName":"TagSpecification" - } + }, + "NetworkBorderGroup":{"shape":"String"} } }, "CreatePublicIpv4PoolResult":{ @@ -13926,7 +13927,8 @@ "required":["PoolId"], "members":{ "DryRun":{"shape":"Boolean"}, - "PoolId":{"shape":"Ipv4PoolEc2Id"} + "PoolId":{"shape":"Ipv4PoolEc2Id"}, + "NetworkBorderGroup":{"shape":"String"} } }, "DeletePublicIpv4PoolResult":{ @@ -29503,9 +29505,17 @@ "shape":"String", "locationName":"vpcId" }, + "NetworkInterfaceAttachmentStatus":{ + "shape":"IpamNetworkInterfaceAttachmentStatus", + "locationName":"networkInterfaceAttachmentStatus" + }, "SampleTime":{ "shape":"MillisecondDateTime", "locationName":"sampleTime" + }, + "AvailabilityZoneId":{ + "shape":"String", + "locationName":"availabilityZoneId" } } }, @@ -29556,6 +29566,13 @@ "max":128, "min":0 }, + "IpamNetworkInterfaceAttachmentStatus":{ + "type":"string", + "enum":[ + "available", + "in-use" + ] + }, "IpamOperatingRegion":{ "type":"structure", "members":{ @@ -30024,6 +30041,10 @@ "VpcId":{ "shape":"String", "locationName":"vpcId" + }, + "AvailabilityZoneId":{ + "shape":"String", + "locationName":"availabilityZoneId" } } }, @@ -37055,7 +37076,8 @@ "DryRun":{"shape":"Boolean"}, "IpamPoolId":{"shape":"IpamPoolId"}, "PoolId":{"shape":"Ipv4PoolEc2Id"}, - "NetmaskLength":{"shape":"Integer"} + "NetmaskLength":{"shape":"Integer"}, + "NetworkBorderGroup":{"shape":"String"} } }, "ProvisionPublicIpv4PoolCidrResult":{ diff --git a/models/apis/ec2/2016-11-15/docs-2.json b/models/apis/ec2/2016-11-15/docs-2.json index 304e5cc1da2..0adea954289 100755 --- a/models/apis/ec2/2016-11-15/docs-2.json +++ b/models/apis/ec2/2016-11-15/docs-2.json @@ -12804,6 +12804,12 @@ "ModifyIpamPoolRequest$AllocationDefaultNetmaskLength": "

The default netmask length for allocations added to this pool. If, for example, the CIDR assigned to this pool is 10.0.0.0/8 and you enter 16 here, new allocations will default to 10.0.0.0/16.

" } }, + "IpamNetworkInterfaceAttachmentStatus": { + "base": null, + "refs": { + "IpamDiscoveredResourceCidr$NetworkInterfaceAttachmentStatus": "

For elastic IP addresses, this is the status of an attached network interface.

" + } + }, "IpamOperatingRegion": { "base": "

The operating Regions for an IPAM. Operating Regions are Amazon Web Services Regions where the IPAM is allowed to manage IP address CIDRs. IPAM only discovers and monitors resources in the Amazon Web Services Regions you select as operating Regions.

For more information about operating Regions, see Create an IPAM in the Amazon VPC IPAM User Guide.

", "refs": { @@ -19666,7 +19672,7 @@ "CreateInstanceConnectEndpointResult$ClientToken": "

Unique, case-sensitive idempotency token provided by the client in the the request.

", "CreateInstanceEventWindowRequest$Name": "

The name of the event window.

", "CreateInstanceExportTaskRequest$Description": "

A description for the conversion task or the resource being exported. The maximum length is 255 characters.

", - "CreateIpamPoolRequest$Locale": "

In IPAM, the locale is the Amazon Web Services Region where you want to make an IPAM pool available for allocations. Only resources in the same Region as the locale of the pool can get IP address allocations from the pool. You can only allocate a CIDR for a VPC, for example, from an IPAM pool that shares a locale with the VPC’s Region. Note that once you choose a Locale for a pool, you cannot modify it. If you do not choose a locale, resources in Regions others than the IPAM's home region cannot use CIDRs from this pool.

Possible values: Any Amazon Web Services Region, such as us-east-1.

", + "CreateIpamPoolRequest$Locale": "

In IPAM, the locale is the Amazon Web Services Region or, for IPAM IPv4 pools in the public scope, the network border group for an Amazon Web Services Local Zone where you want to make an IPAM pool available for allocations (supported Local Zones). If you do not choose a locale, resources in Regions others than the IPAM's home region cannot use CIDRs from this pool.

Possible values: Any Amazon Web Services Region, such as us-east-1.

", "CreateIpamPoolRequest$Description": "

A description for the IPAM pool.

", "CreateIpamPoolRequest$ClientToken": "

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

", "CreateIpamRequest$Description": "

A description for the IPAM.

", @@ -19700,6 +19706,7 @@ "CreateNetworkInterfaceRequest$ClientToken": "

Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

", "CreateNetworkInterfaceResult$ClientToken": "

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

", "CreatePlacementGroupRequest$GroupName": "

A name for the placement group. Must be unique within the scope of your account for the Region.

Constraints: Up to 255 ASCII characters

", + "CreatePublicIpv4PoolRequest$NetworkBorderGroup": "

The Availability Zone (AZ) or Local Zone (LZ) network border group that the resource that the IP address is assigned to is in. Defaults to an AZ network border group. For more information on available Local Zones, see Local Zone availability in the Amazon EC2 User Guide.

", "CreateReplaceRootVolumeTaskRequest$ClientToken": "

Unique, case-sensitive identifier you provide to ensure the idempotency of the request. If you do not specify a client token, a randomly generated token is used for the request to ensure idempotency. For more information, see Ensuring idempotency.

", "CreateReservedInstancesListingRequest$ClientToken": "

Unique, case-sensitive identifier you provide to ensure idempotency of your listings. This helps avoid duplicate listings. For more information, see Ensuring Idempotency.

", "CreateRestoreImageTaskRequest$Bucket": "

The name of the Amazon S3 bucket that contains the stored AMI object.

", @@ -19818,6 +19825,7 @@ "DeleteLaunchTemplateVersionsResponseSuccessItem$LaunchTemplateName": "

The name of the launch template.

", "DeleteLocalGatewayRouteRequest$DestinationCidrBlock": "

The CIDR range for the route. This must match the CIDR for the route exactly.

", "DeleteNatGatewayResult$NatGatewayId": "

The ID of the NAT gateway.

", + "DeletePublicIpv4PoolRequest$NetworkBorderGroup": "

The Availability Zone (AZ) or Local Zone (LZ) network border group that the resource that the IP address is assigned to is in. Defaults to an AZ network border group. For more information on available Local Zones, see Local Zone availability in the Amazon EC2 User Guide.

", "DeleteQueuedReservedInstancesError$Message": "

The error message.

", "DeleteRouteRequest$DestinationCidrBlock": "

The IPv4 CIDR range for the route. The value you specify must match the CIDR for the route exactly.

", "DeleteRouteRequest$DestinationIpv6CidrBlock": "

The IPv6 CIDR range for the route. The value you specify must match the CIDR for the route exactly.

", @@ -20487,17 +20495,18 @@ "IpamDiscoveredPublicAddress$NetworkInterfaceId": "

The network interface ID of the resource with the assigned IP address.

", "IpamDiscoveredPublicAddress$NetworkInterfaceDescription": "

The description of the network interface that IP address is assigned to.

", "IpamDiscoveredPublicAddress$InstanceId": "

The instance ID of the instance the assigned IP address is assigned to.

", - "IpamDiscoveredPublicAddress$NetworkBorderGroup": "

The network border group that the resource that the IP address is assigned to is in.

", + "IpamDiscoveredPublicAddress$NetworkBorderGroup": "

The Availability Zone (AZ) or Local Zone (LZ) network border group that the resource that the IP address is assigned to is in. Defaults to an AZ network border group. For more information on available Local Zones, see Local Zone availability in the Amazon EC2 User Guide.

", "IpamDiscoveredResourceCidr$ResourceRegion": "

The resource Region.

", "IpamDiscoveredResourceCidr$ResourceId": "

The resource ID.

", "IpamDiscoveredResourceCidr$ResourceOwnerId": "

The resource owner ID.

", "IpamDiscoveredResourceCidr$ResourceCidr": "

The resource CIDR.

", "IpamDiscoveredResourceCidr$VpcId": "

The VPC ID.

", + "IpamDiscoveredResourceCidr$AvailabilityZoneId": "

The Availability Zone ID.

", "IpamDiscoveryFailureReason$Message": "

The discovery failure message.

", "IpamOperatingRegion$RegionName": "

The name of the operating Region.

", "IpamPool$OwnerId": "

The Amazon Web Services account ID of the owner of the IPAM pool.

", "IpamPool$IpamRegion": "

The Amazon Web Services Region of the IPAM pool.

", - "IpamPool$Locale": "

The locale of the IPAM pool. In IPAM, the locale is the Amazon Web Services Region where you want to make an IPAM pool available for allocations. Only resources in the same Region as the locale of the pool can get IP address allocations from the pool. You can only allocate a CIDR for a VPC, for example, from an IPAM pool that shares a locale with the VPC’s Region. Note that once you choose a Locale for a pool, you cannot modify it. If you choose an Amazon Web Services Region for locale that has not been configured as an operating Region for the IPAM, you'll get an error.

", + "IpamPool$Locale": "

The locale of the IPAM pool. In IPAM, the locale is the Amazon Web Services Region or, for IPAM IPv4 pools in the public scope, the network border group for an Amazon Web Services Local Zone where you want to make an IPAM pool available for allocations (supported Local Zones). If you choose an Amazon Web Services Region for locale that has not been configured as an operating Region for the IPAM, you'll get an error.

", "IpamPool$StateMessage": "

The state message.

", "IpamPool$Description": "

The description of the IPAM pool.

", "IpamPoolAllocation$Cidr": "

The CIDR for the allocation. A CIDR is a representation of an IP address and its associated network mask (or netmask) and refers to a range of IP addresses. An IPv4 CIDR example is 10.24.34.0/23. An IPv6 CIDR example is 2001:DB8::/32.

", @@ -20525,6 +20534,7 @@ "IpamResourceCidr$ResourceName": "

The name of an IPAM resource.

", "IpamResourceCidr$ResourceCidr": "

The CIDR for an IPAM resource.

", "IpamResourceCidr$VpcId": "

The ID of a VPC.

", + "IpamResourceCidr$AvailabilityZoneId": "

The Availability Zone ID.

", "IpamResourceDiscovery$OwnerId": "

The ID of the owner.

", "IpamResourceDiscovery$IpamResourceDiscoveryArn": "

The resource discovery Amazon Resource Name (ARN).

", "IpamResourceDiscovery$IpamResourceDiscoveryRegion": "

The resource discovery Region.

", @@ -20858,6 +20868,7 @@ "ProvisionIpamByoasnRequest$Asn": "

A public 2-byte or 4-byte ASN.

", "ProvisionIpamPoolCidrRequest$Cidr": "

The CIDR you want to assign to the IPAM pool. Either \"NetmaskLength\" or \"Cidr\" is required. This value will be null if you specify \"NetmaskLength\" and will be filled in during the provisioning process.

", "ProvisionIpamPoolCidrRequest$ClientToken": "

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

", + "ProvisionPublicIpv4PoolCidrRequest$NetworkBorderGroup": "

The Availability Zone (AZ) or Local Zone (LZ) network border group that the resource that the IP address is assigned to is in. Defaults to an AZ network border group. For more information on available Local Zones, see Local Zone availability in the Amazon EC2 User Guide.

", "ProvisionedBandwidth$Provisioned": "

Reserved.

", "ProvisionedBandwidth$Requested": "

Reserved.

", "ProvisionedBandwidth$Status": "

Reserved.

", diff --git a/models/apis/glue/2017-03-31/api-2.json b/models/apis/glue/2017-03-31/api-2.json index 162c1f03e4a..5a87af0cdfb 100644 --- a/models/apis/glue/2017-03-31/api-2.json +++ b/models/apis/glue/2017-03-31/api-2.json @@ -4950,6 +4950,22 @@ }, "exception":true }, + "ConditionExpression":{ + "type":"structure", + "required":[ + "Condition", + "TargetColumn" + ], + "members":{ + "Condition":{"shape":"DatabrewCondition"}, + "Value":{"shape":"DatabrewConditionValue"}, + "TargetColumn":{"shape":"TargetColumn"} + } + }, + "ConditionExpressionList":{ + "type":"list", + "member":{"shape":"ConditionExpression"} + }, "ConditionList":{ "type":"list", "member":{"shape":"Condition"} @@ -6409,6 +6425,16 @@ "member":{"shape":"Database"} }, "DatabaseName":{"type":"string"}, + "DatabrewCondition":{ + "type":"string", + "max":128, + "min":1, + "pattern":"^[A-Z\\_]+$" + }, + "DatabrewConditionValue":{ + "type":"string", + "max":1024 + }, "Datatype":{ "type":"structure", "required":[ @@ -7146,11 +7172,11 @@ }, "EnclosedInStringProperty":{ "type":"string", - "pattern":"([\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF]|[^\\S\\r\\n\"'])*" + "pattern":"([\\u0009\\u000B\\u000C\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF])*" }, "EnclosedInStringPropertyWithQuote":{ "type":"string", - "pattern":"([\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF]|[^\\S\\r\\n])*" + "pattern":"([\\u0009\\u000B\\u000C\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF])*" }, "EncryptionAtRest":{ "type":"structure", @@ -10306,7 +10332,7 @@ }, "NodeName":{ "type":"string", - "pattern":"([\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF]|[^\\r\\n])*" + "pattern":"([^\\r\\n])*" }, "NodeType":{ "type":"string", @@ -10430,6 +10456,12 @@ "IcebergInput":{"shape":"IcebergInput"} } }, + "Operation":{ + "type":"string", + "max":128, + "min":1, + "pattern":"^[A-Z\\_]+$" + }, "OperationNotSupportedException":{ "type":"structure", "members":{ @@ -10609,6 +10641,22 @@ "null" ] }, + "ParameterMap":{ + "type":"map", + "key":{"shape":"ParameterName"}, + "value":{"shape":"ParameterValue"} + }, + "ParameterName":{ + "type":"string", + "max":128, + "min":1, + "pattern":"^[A-Za-z0-9]+$" + }, + "ParameterValue":{ + "type":"string", + "max":32768, + "min":1 + }, "ParametersMap":{ "type":"map", "key":{"shape":"KeyString"}, @@ -11023,13 +11071,21 @@ "type":"structure", "required":[ "Name", - "Inputs", - "RecipeReference" + "Inputs" ], "members":{ "Name":{"shape":"NodeName"}, "Inputs":{"shape":"OneInput"}, - "RecipeReference":{"shape":"RecipeReference"} + "RecipeReference":{"shape":"RecipeReference"}, + "RecipeSteps":{"shape":"RecipeSteps"} + } + }, + "RecipeAction":{ + "type":"structure", + "required":["Operation"], + "members":{ + "Operation":{"shape":"Operation"}, + "Parameters":{"shape":"ParameterMap"} } }, "RecipeReference":{ @@ -11043,6 +11099,18 @@ "RecipeVersion":{"shape":"RecipeVersion"} } }, + "RecipeStep":{ + "type":"structure", + "required":["Action"], + "members":{ + "Action":{"shape":"RecipeAction"}, + "ConditionExpressions":{"shape":"ConditionExpressionList"} + } + }, + "RecipeSteps":{ + "type":"list", + "member":{"shape":"RecipeStep"} + }, "RecipeVersion":{ "type":"string", "max":16, @@ -12807,6 +12875,11 @@ "max":50, "min":0 }, + "TargetColumn":{ + "type":"string", + "max":1024, + "min":1 + }, "TargetFormat":{ "type":"string", "enum":[ diff --git a/models/apis/glue/2017-03-31/docs-2.json b/models/apis/glue/2017-03-31/docs-2.json index 17650c23bb1..37ec30d210f 100644 --- a/models/apis/glue/2017-03-31/docs-2.json +++ b/models/apis/glue/2017-03-31/docs-2.json @@ -1551,6 +1551,18 @@ "refs": { } }, + "ConditionExpression": { + "base": "

Condition expression defined in the Glue Studio data preparation recipe node.

", + "refs": { + "ConditionExpressionList$member": null + } + }, + "ConditionExpressionList": { + "base": null, + "refs": { + "RecipeStep$ConditionExpressions": "

The condition expressions for the recipe step.

" + } + }, "ConditionList": { "base": null, "refs": { @@ -2577,6 +2589,18 @@ "UpdateCrawlerRequest$DatabaseName": "

The Glue database where results are stored, such as: arn:aws:daylight:us-east-1::database/sometable/*.

" } }, + "DatabrewCondition": { + "base": null, + "refs": { + "ConditionExpression$Condition": "

The condition of the condition expression.

" + } + }, + "DatabrewConditionValue": { + "base": null, + "refs": { + "ConditionExpression$Value": "

The value of the condition expression.

" + } + }, "Datatype": { "base": "

A structure representing the datatype of the value.

", "refs": { @@ -6593,6 +6617,12 @@ "CreateTableRequest$OpenTableFormatInput": "

Specifies an OpenTableFormatInput structure when creating an open format table.

" } }, + "Operation": { + "base": null, + "refs": { + "RecipeAction$Operation": "

The operation of the recipe action.

" + } + }, "OperationNotSupportedException": { "base": "

The operation is not available in the region.

", "refs": { @@ -6827,6 +6857,24 @@ "TransformConfigParameter$ListType": "

Specifies the list type of the parameter in the config file of the dynamic transform.

" } }, + "ParameterMap": { + "base": null, + "refs": { + "RecipeAction$Parameters": "

The parameters of the recipe action.

" + } + }, + "ParameterName": { + "base": null, + "refs": { + "ParameterMap$key": null + } + }, + "ParameterValue": { + "base": null, + "refs": { + "ParameterMap$value": null + } + }, "ParametersMap": { "base": null, "refs": { @@ -7212,12 +7260,30 @@ "CodeGenConfigurationNode$Recipe": "

Specifies a Glue DataBrew recipe node.

" } }, + "RecipeAction": { + "base": "

Actions defined in the Glue Studio data preparation recipe node.

", + "refs": { + "RecipeStep$Action": "

The transformation action of the recipe step.

" + } + }, "RecipeReference": { "base": "

A reference to a Glue DataBrew recipe.

", "refs": { "Recipe$RecipeReference": "

A reference to the DataBrew recipe used by the node.

" } }, + "RecipeStep": { + "base": "

A recipe step used in a Glue Studio data preparation recipe node.

", + "refs": { + "RecipeSteps$member": null + } + }, + "RecipeSteps": { + "base": null, + "refs": { + "Recipe$RecipeSteps": "

Transform steps used in the recipe node.

" + } + }, "RecipeVersion": { "base": null, "refs": { @@ -8561,6 +8627,12 @@ "TagResourceRequest$TagsToAdd": "

Tags to add to this resource.

" } }, + "TargetColumn": { + "base": null, + "refs": { + "ConditionExpression$TargetColumn": "

The target column of the condition expressions.

" + } + }, "TargetFormat": { "base": null, "refs": { diff --git a/models/apis/groundstation/2019-05-23/api-2.json b/models/apis/groundstation/2019-05-23/api-2.json index 2634da33f95..16fbc50494d 100644 --- a/models/apis/groundstation/2019-05-23/api-2.json +++ b/models/apis/groundstation/2019-05-23/api-2.json @@ -5,11 +5,13 @@ "endpointPrefix":"groundstation", "jsonVersion":"1.1", "protocol":"rest-json", + "protocols":["rest-json"], "serviceFullName":"AWS Ground Station", "serviceId":"GroundStation", "signatureVersion":"v4", "signingName":"groundstation", - "uid":"groundstation-2019-05-23" + "uid":"groundstation-2019-05-23", + "auth":["aws.auth#sigv4"] }, "operations":{ "CancelContact":{ diff --git a/models/apis/groundstation/2019-05-23/docs-2.json b/models/apis/groundstation/2019-05-23/docs-2.json index 871e59f859d..6480c123ac1 100644 --- a/models/apis/groundstation/2019-05-23/docs-2.json +++ b/models/apis/groundstation/2019-05-23/docs-2.json @@ -934,7 +934,7 @@ } }, "OEMEphemeris": { - "base": "

Ephemeris data in Orbit Ephemeris Message (OEM) format.

", + "base": "

Ephemeris data in Orbit Ephemeris Message (OEM) format.

Position, velocity, and acceleration units must be represented in km, km/s, and km/s**2, respectively, in ephemeris data lines. Covariance matrix line units must be represented in km**2 if computed from two positions, km**2/s if computed from one position and one velocity, and km**2/s**2 if computed from two velocities. Consult section 7.7.2 of The Consultative Committee for Space Data Systems (CCSDS) Recommended Standard for Orbit Data Messages for more information.

", "refs": { "EphemerisData$oem": null } diff --git a/models/apis/license-manager-linux-subscriptions/2018-05-10/api-2.json b/models/apis/license-manager-linux-subscriptions/2018-05-10/api-2.json index 8dcaa007fac..bfa5411db0d 100644 --- a/models/apis/license-manager-linux-subscriptions/2018-05-10/api-2.json +++ b/models/apis/license-manager-linux-subscriptions/2018-05-10/api-2.json @@ -5,13 +5,49 @@ "endpointPrefix":"license-manager-linux-subscriptions", "jsonVersion":"1.1", "protocol":"rest-json", + "protocols":["rest-json"], "serviceFullName":"AWS License Manager Linux Subscriptions", "serviceId":"License Manager Linux Subscriptions", "signatureVersion":"v4", "signingName":"license-manager-linux-subscriptions", - "uid":"license-manager-linux-subscriptions-2018-05-10" + "uid":"license-manager-linux-subscriptions-2018-05-10", + "auth":["aws.auth#sigv4"] }, "operations":{ + "DeregisterSubscriptionProvider":{ + "name":"DeregisterSubscriptionProvider", + "http":{ + "method":"POST", + "requestUri":"/subscription/DeregisterSubscriptionProvider", + "responseCode":200 + }, + "input":{"shape":"DeregisterSubscriptionProviderRequest"}, + "output":{"shape":"DeregisterSubscriptionProviderResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, + "GetRegisteredSubscriptionProvider":{ + "name":"GetRegisteredSubscriptionProvider", + "http":{ + "method":"POST", + "requestUri":"/subscription/GetRegisteredSubscriptionProvider", + "responseCode":200 + }, + "input":{"shape":"GetRegisteredSubscriptionProviderRequest"}, + "output":{"shape":"GetRegisteredSubscriptionProviderResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, "GetServiceSettings":{ "name":"GetServiceSettings", "http":{ @@ -60,6 +96,84 @@ ], "idempotent":true }, + "ListRegisteredSubscriptionProviders":{ + "name":"ListRegisteredSubscriptionProviders", + "http":{ + "method":"POST", + "requestUri":"/subscription/ListRegisteredSubscriptionProviders", + "responseCode":200 + }, + "input":{"shape":"ListRegisteredSubscriptionProvidersRequest"}, + "output":{"shape":"ListRegisteredSubscriptionProvidersResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, + "ListTagsForResource":{ + "name":"ListTagsForResource", + "http":{ + "method":"GET", + "requestUri":"/tags/{resourceArn}", + "responseCode":200 + }, + "input":{"shape":"ListTagsForResourceRequest"}, + "output":{"shape":"ListTagsForResourceResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ValidationException"} + ] + }, + "RegisterSubscriptionProvider":{ + "name":"RegisterSubscriptionProvider", + "http":{ + "method":"POST", + "requestUri":"/subscription/RegisterSubscriptionProvider", + "responseCode":200 + }, + "input":{"shape":"RegisterSubscriptionProviderRequest"}, + "output":{"shape":"RegisterSubscriptionProviderResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, + "TagResource":{ + "name":"TagResource", + "http":{ + "method":"PUT", + "requestUri":"/tags/{resourceArn}", + "responseCode":200 + }, + "input":{"shape":"TagResourceRequest"}, + "output":{"shape":"TagResourceResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, + "UntagResource":{ + "name":"UntagResource", + "http":{ + "method":"DELETE", + "requestUri":"/tags/{resourceArn}", + "responseCode":200 + }, + "input":{"shape":"UntagResourceRequest"}, + "output":{"shape":"UntagResourceResponse"}, + "errors":[ + {"shape":"InternalServerException"}, + {"shape":"ResourceNotFoundException"} + ], + "idempotent":true + }, "UpdateServiceSettings":{ "name":"UpdateServiceSettings", "http":{ @@ -90,6 +204,18 @@ "type":"long", "box":true }, + "DeregisterSubscriptionProviderRequest":{ + "type":"structure", + "required":["SubscriptionProviderArn"], + "members":{ + "SubscriptionProviderArn":{"shape":"SubscriptionProviderArn"} + } + }, + "DeregisterSubscriptionProviderResponse":{ + "type":"structure", + "members":{ + } + }, "Filter":{ "type":"structure", "members":{ @@ -102,6 +228,24 @@ "type":"list", "member":{"shape":"Filter"} }, + "GetRegisteredSubscriptionProviderRequest":{ + "type":"structure", + "required":["SubscriptionProviderArn"], + "members":{ + "SubscriptionProviderArn":{"shape":"SubscriptionProviderArn"} + } + }, + "GetRegisteredSubscriptionProviderResponse":{ + "type":"structure", + "members":{ + "LastSuccessfulDataRetrievalTime":{"shape":"String"}, + "SecretArn":{"shape":"SecretArn"}, + "SubscriptionProviderArn":{"shape":"SubscriptionProviderArn"}, + "SubscriptionProviderSource":{"shape":"SubscriptionProviderSource"}, + "SubscriptionProviderStatus":{"shape":"SubscriptionProviderStatus"}, + "SubscriptionProviderStatusMessage":{"shape":"String"} + } + }, "GetServiceSettingsRequest":{ "type":"structure", "members":{ @@ -122,13 +266,18 @@ "members":{ "AccountID":{"shape":"String"}, "AmiId":{"shape":"String"}, + "DualSubscription":{"shape":"String"}, "InstanceID":{"shape":"String"}, "InstanceType":{"shape":"String"}, "LastUpdatedTime":{"shape":"String"}, + "OsVersion":{"shape":"String"}, "ProductCode":{"shape":"ProductCodeList"}, "Region":{"shape":"String"}, + "RegisteredWithSubscriptionProvider":{"shape":"String"}, "Status":{"shape":"String"}, "SubscriptionName":{"shape":"String"}, + "SubscriptionProviderCreateTime":{"shape":"String"}, + "SubscriptionProviderUpdateTime":{"shape":"String"}, "UsageOperation":{"shape":"String"} } }, @@ -202,6 +351,44 @@ "Subscriptions":{"shape":"SubscriptionList"} } }, + "ListRegisteredSubscriptionProvidersRequest":{ + "type":"structure", + "members":{ + "MaxResults":{"shape":"ListRegisteredSubscriptionProvidersRequestMaxResultsInteger"}, + "NextToken":{"shape":"String"}, + "SubscriptionProviderSources":{"shape":"SubscriptionProviderSourceList"} + } + }, + "ListRegisteredSubscriptionProvidersRequestMaxResultsInteger":{ + "type":"integer", + "box":true, + "max":100, + "min":1 + }, + "ListRegisteredSubscriptionProvidersResponse":{ + "type":"structure", + "members":{ + "NextToken":{"shape":"String"}, + "RegisteredSubscriptionProviders":{"shape":"RegisteredSubscriptionProviderList"} + } + }, + "ListTagsForResourceRequest":{ + "type":"structure", + "required":["resourceArn"], + "members":{ + "resourceArn":{ + "shape":"SubscriptionProviderArn", + "location":"uri", + "locationName":"resourceArn" + } + } + }, + "ListTagsForResourceResponse":{ + "type":"structure", + "members":{ + "tags":{"shape":"Tags"} + } + }, "Operator":{ "type":"string", "enum":[ @@ -223,6 +410,52 @@ "type":"list", "member":{"shape":"String"} }, + "RegisterSubscriptionProviderRequest":{ + "type":"structure", + "required":[ + "SecretArn", + "SubscriptionProviderSource" + ], + "members":{ + "SecretArn":{"shape":"SecretArn"}, + "SubscriptionProviderSource":{"shape":"SubscriptionProviderSource"}, + "Tags":{"shape":"Tags"} + } + }, + "RegisterSubscriptionProviderResponse":{ + "type":"structure", + "members":{ + "SubscriptionProviderArn":{"shape":"String"}, + "SubscriptionProviderSource":{"shape":"SubscriptionProviderSource"}, + "SubscriptionProviderStatus":{"shape":"SubscriptionProviderStatus"} + } + }, + "RegisteredSubscriptionProvider":{ + "type":"structure", + "members":{ + "LastSuccessfulDataRetrievalTime":{"shape":"String"}, + "SecretArn":{"shape":"SecretArn"}, + "SubscriptionProviderArn":{"shape":"SubscriptionProviderArn"}, + "SubscriptionProviderSource":{"shape":"SubscriptionProviderSource"}, + "SubscriptionProviderStatus":{"shape":"SubscriptionProviderStatus"}, + "SubscriptionProviderStatusMessage":{"shape":"String"} + } + }, + "RegisteredSubscriptionProviderList":{ + "type":"list", + "member":{"shape":"RegisteredSubscriptionProvider"} + }, + "ResourceNotFoundException":{ + "type":"structure", + "members":{ + "message":{"shape":"String"} + }, + "exception":true + }, + "SecretArn":{ + "type":"string", + "pattern":"^arn:[a-z0-9-\\.]{1,63}:secretsmanager:[a-z0-9-\\.]{0,63}:[a-z0-9-\\.]{0,63}:secret:[^/]{1,1023}$" + }, "Status":{ "type":"string", "enum":[ @@ -261,6 +494,61 @@ "type":"list", "member":{"shape":"Subscription"} }, + "SubscriptionProviderArn":{ + "type":"string", + "pattern":"^arn:[a-z0-9-\\.]{1,63}:[a-z0-9-\\.]{1,63}:[a-z0-9-\\.]{1,63}:[a-z0-9-\\.]{1,63}:[a-z0-9-\\.]{1,510}/[a-z0-9-\\.]{1,510}$" + }, + "SubscriptionProviderSource":{ + "type":"string", + "enum":["RedHat"] + }, + "SubscriptionProviderSourceList":{ + "type":"list", + "member":{"shape":"SubscriptionProviderSource"} + }, + "SubscriptionProviderStatus":{ + "type":"string", + "enum":[ + "ACTIVE", + "INVALID", + "PENDING" + ] + }, + "TagKeyList":{ + "type":"list", + "member":{"shape":"String"}, + "max":50, + "min":0, + "sensitive":true + }, + "TagResourceRequest":{ + "type":"structure", + "required":[ + "resourceArn", + "tags" + ], + "members":{ + "resourceArn":{ + "shape":"SubscriptionProviderArn", + "location":"uri", + "locationName":"resourceArn" + }, + "tags":{"shape":"Tags"} + } + }, + "TagResourceResponse":{ + "type":"structure", + "members":{ + } + }, + "Tags":{ + "type":"map", + "key":{"shape":"String"}, + "value":{"shape":"String"}, + "max":50, + "min":0, + "sensitive":true + }, "ThrottlingException":{ "type":"structure", "members":{ @@ -268,6 +556,30 @@ }, "exception":true }, + "UntagResourceRequest":{ + "type":"structure", + "required":[ + "resourceArn", + "tagKeys" + ], + "members":{ + "resourceArn":{ + "shape":"SubscriptionProviderArn", + "location":"uri", + "locationName":"resourceArn" + }, + "tagKeys":{ + "shape":"TagKeyList", + "location":"querystring", + "locationName":"tagKeys" + } + } + }, + "UntagResourceResponse":{ + "type":"structure", + "members":{ + } + }, "UpdateServiceSettingsRequest":{ "type":"structure", "required":[ diff --git a/models/apis/license-manager-linux-subscriptions/2018-05-10/docs-2.json b/models/apis/license-manager-linux-subscriptions/2018-05-10/docs-2.json index a855a3be386..0e087602b12 100644 --- a/models/apis/license-manager-linux-subscriptions/2018-05-10/docs-2.json +++ b/models/apis/license-manager-linux-subscriptions/2018-05-10/docs-2.json @@ -2,9 +2,16 @@ "version": "2.0", "service": "

With License Manager, you can discover and track your commercial Linux subscriptions on running Amazon EC2 instances.

", "operations": { - "GetServiceSettings": "

Lists the Linux subscriptions service settings.

", + "DeregisterSubscriptionProvider": "

Remove a third-party subscription provider from the Bring Your Own License (BYOL) subscriptions registered to your account.

", + "GetRegisteredSubscriptionProvider": "

Get details for a Bring Your Own License (BYOL) subscription that's registered to your account.

", + "GetServiceSettings": "

Lists the Linux subscriptions service settings for your account.

", "ListLinuxSubscriptionInstances": "

Lists the running Amazon EC2 instances that were discovered with commercial Linux subscriptions.

", "ListLinuxSubscriptions": "

Lists the Linux subscriptions that have been discovered. If you have linked your organization, the returned results will include data aggregated across your accounts in Organizations.

", + "ListRegisteredSubscriptionProviders": "

List Bring Your Own License (BYOL) subscription registration resources for your account.

", + "ListTagsForResource": "

List the metadata tags that are assigned to the specified Amazon Web Services resource.

", + "RegisterSubscriptionProvider": "

Register the supported third-party subscription provider for your Bring Your Own License (BYOL) subscription.

", + "TagResource": "

Add metadata tags to the specified Amazon Web Services resource.

", + "UntagResource": "

Remove one or more metadata tag from the specified Amazon Web Services resource.

", "UpdateServiceSettings": "

Updates the service settings for Linux subscriptions.

" }, "shapes": { @@ -17,8 +24,8 @@ "BoxInteger": { "base": null, "refs": { - "ListLinuxSubscriptionInstancesRequest$MaxResults": "

Maximum number of results to return in a single call.

", - "ListLinuxSubscriptionsRequest$MaxResults": "

Maximum number of results to return in a single call.

" + "ListLinuxSubscriptionInstancesRequest$MaxResults": "

The maximum items to return in a request.

", + "ListLinuxSubscriptionsRequest$MaxResults": "

The maximum items to return in a request.

" } }, "BoxLong": { @@ -27,6 +34,16 @@ "Subscription$InstanceCount": "

The total amount of running instances using this subscription.

" } }, + "DeregisterSubscriptionProviderRequest": { + "base": null, + "refs": { + } + }, + "DeregisterSubscriptionProviderResponse": { + "base": null, + "refs": { + } + }, "Filter": { "base": "

A filter object that is used to return more specific results from a describe operation. Filters can be used to match a set of resources by specific criteria.

", "refs": { @@ -36,10 +53,20 @@ "FilterList": { "base": null, "refs": { - "ListLinuxSubscriptionInstancesRequest$Filters": "

An array of structures that you can use to filter the results to those that match one or more sets of key-value pairs that you specify. For example, you can filter by the name of AmiID with an optional operator to see subscriptions that match, partially match, or don't match a certain Amazon Machine Image (AMI) ID.

The valid names for this filter are:

The valid Operators for this filter are:

", + "ListLinuxSubscriptionInstancesRequest$Filters": "

An array of structures that you can use to filter the results by your specified criteria. For example, you can specify Region in the Name, with the contains operator to list all subscriptions that match a partial string in the Value, such as us-west.

For each filter, you can specify one of the following values for the Name key to streamline results:

For each filter, you can use one of the following Operator values to define the behavior of the filter:

", "ListLinuxSubscriptionsRequest$Filters": "

An array of structures that you can use to filter the results to those that match one or more sets of key-value pairs that you specify. For example, you can filter by the name of Subscription with an optional operator to see subscriptions that match, partially match, or don't match a certain subscription's name.

The valid names for this filter are:

The valid Operators for this filter are:

" } }, + "GetRegisteredSubscriptionProviderRequest": { + "base": null, + "refs": { + } + }, + "GetRegisteredSubscriptionProviderResponse": { + "base": null, + "refs": { + } + }, "GetServiceSettingsRequest": { "base": null, "refs": { @@ -91,7 +118,7 @@ "ListLinuxSubscriptionInstancesRequestNextTokenString": { "base": null, "refs": { - "ListLinuxSubscriptionInstancesRequest$NextToken": "

Token for the next set of results.

" + "ListLinuxSubscriptionInstancesRequest$NextToken": "

A token to specify where to start paginating. This is the nextToken from a previously truncated response.

" } }, "ListLinuxSubscriptionInstancesResponse": { @@ -107,7 +134,7 @@ "ListLinuxSubscriptionsRequestNextTokenString": { "base": null, "refs": { - "ListLinuxSubscriptionsRequest$NextToken": "

Token for the next set of results.

" + "ListLinuxSubscriptionsRequest$NextToken": "

A token to specify where to start paginating. This is the nextToken from a previously truncated response.

" } }, "ListLinuxSubscriptionsResponse": { @@ -115,6 +142,32 @@ "refs": { } }, + "ListRegisteredSubscriptionProvidersRequest": { + "base": null, + "refs": { + } + }, + "ListRegisteredSubscriptionProvidersRequestMaxResultsInteger": { + "base": null, + "refs": { + "ListRegisteredSubscriptionProvidersRequest$MaxResults": "

The maximum items to return in a request.

" + } + }, + "ListRegisteredSubscriptionProvidersResponse": { + "base": null, + "refs": { + } + }, + "ListTagsForResourceRequest": { + "base": null, + "refs": { + } + }, + "ListTagsForResourceResponse": { + "base": null, + "refs": { + } + }, "Operator": { "base": null, "refs": { @@ -133,6 +186,41 @@ "Instance$ProductCode": "

The product code for the instance. For more information, see Usage operation values in the License Manager User Guide .

" } }, + "RegisterSubscriptionProviderRequest": { + "base": null, + "refs": { + } + }, + "RegisterSubscriptionProviderResponse": { + "base": null, + "refs": { + } + }, + "RegisteredSubscriptionProvider": { + "base": "

A third-party provider for operating system (OS) platform software and license subscriptions, such as Red Hat. When you register a third-party Linux subscription provider, License Manager can get subscription data from the registered provider.

", + "refs": { + "RegisteredSubscriptionProviderList$member": null + } + }, + "RegisteredSubscriptionProviderList": { + "base": null, + "refs": { + "ListRegisteredSubscriptionProvidersResponse$RegisteredSubscriptionProviders": "

The list of BYOL registration resources that fit the criteria you specified in the request.

" + } + }, + "ResourceNotFoundException": { + "base": "

Unable to find the requested Amazon Web Services resource.

", + "refs": { + } + }, + "SecretArn": { + "base": null, + "refs": { + "GetRegisteredSubscriptionProviderResponse$SecretArn": "

The Amazon Resource Name (ARN) of the third-party access secret stored in Secrets Manager for the BYOL registration resource specified in the request.

", + "RegisterSubscriptionProviderRequest$SecretArn": "

The Amazon Resource Name (ARN) of the secret where you've stored your subscription provider's access token. For RHEL subscriptions managed through the Red Hat Subscription Manager (RHSM), the secret contains your Red Hat Offline token.

", + "RegisteredSubscriptionProvider$SecretArn": "

The Amazon Resource Name (ARN) of the Secrets Manager secret that stores your registered Linux subscription provider access token. For RHEL account subscriptions, this is the offline token.

" + } + }, "Status": { "base": null, "refs": { @@ -144,23 +232,39 @@ "base": null, "refs": { "Filter$Name": "

The type of name to filter by.

", + "GetRegisteredSubscriptionProviderResponse$LastSuccessfulDataRetrievalTime": "

The timestamp from the last time License Manager retrieved subscription details from your registered third-party Linux subscription provider.

", + "GetRegisteredSubscriptionProviderResponse$SubscriptionProviderStatusMessage": "

The detailed message from your subscription provider token status.

", "Instance$AccountID": "

The account ID which owns the instance.

", "Instance$AmiId": "

The AMI ID used to launch the instance.

", + "Instance$DualSubscription": "

Indicates that you have two different license subscriptions for the same software on your instance.

", "Instance$InstanceID": "

The instance ID of the resource.

", "Instance$InstanceType": "

The instance type of the resource.

", "Instance$LastUpdatedTime": "

The time in which the last discovery updated the instance details.

", + "Instance$OsVersion": "

The operating system software version that runs on your instance.

", "Instance$Region": "

The Region the instance is running in.

", + "Instance$RegisteredWithSubscriptionProvider": "

Indicates that your instance uses a BYOL license subscription from a third-party Linux subscription provider that you've registered with License Manager.

", "Instance$Status": "

The status of the instance.

", - "Instance$SubscriptionName": "

The name of the subscription being used by the instance.

", + "Instance$SubscriptionName": "

The name of the license subscription that the instance uses.

", + "Instance$SubscriptionProviderCreateTime": "

The timestamp when you registered the third-party Linux subscription provider for the subscription that the instance uses.

", + "Instance$SubscriptionProviderUpdateTime": "

The timestamp from the last time that the instance synced with the registered third-party Linux subscription provider.

", "Instance$UsageOperation": "

The usage operation of the instance. For more information, see For more information, see Usage operation values in the License Manager User Guide.

", "InternalServerException$message": null, - "ListLinuxSubscriptionInstancesResponse$NextToken": "

Token for the next set of results.

", - "ListLinuxSubscriptionsResponse$NextToken": "

Token for the next set of results.

", + "ListLinuxSubscriptionInstancesResponse$NextToken": "

The next token used for paginated responses. When this field isn't empty, there are additional elements that the service hasn't included in this request. Use this token with the next request to retrieve additional objects.

", + "ListLinuxSubscriptionsResponse$NextToken": "

The next token used for paginated responses. When this field isn't empty, there are additional elements that the service hasn't included in this request. Use this token with the next request to retrieve additional objects.

", + "ListRegisteredSubscriptionProvidersRequest$NextToken": "

A token to specify where to start paginating. This is the nextToken from a previously truncated response.

", + "ListRegisteredSubscriptionProvidersResponse$NextToken": "

The next token used for paginated responses. When this field isn't empty, there are additional elements that the service hasn't included in this request. Use this token with the next request to retrieve additional objects.

", "ProductCodeList$member": null, + "RegisterSubscriptionProviderResponse$SubscriptionProviderArn": "

The Amazon Resource Name (ARN) of the Linux subscription provider resource that you registered.

", + "RegisteredSubscriptionProvider$LastSuccessfulDataRetrievalTime": "

The timestamp from the last time that License Manager accessed third-party subscription data for your account from your registered Linux subscription provider.

", + "RegisteredSubscriptionProvider$SubscriptionProviderStatusMessage": "

A detailed message that's associated with your BYOL subscription provider token status.

", + "ResourceNotFoundException$message": null, "StringMap$key": null, "StringMap$value": null, "Subscription$Name": "

The name of the subscription.

", "Subscription$Type": "

The type of subscription. The type can be subscription-included with Amazon EC2, Bring Your Own Subscription model (BYOS), or from the Amazon Web Services Marketplace. Certain subscriptions may use licensing from the Amazon Web Services Marketplace as well as OS licensing from Amazon EC2 or BYOS.

", + "TagKeyList$member": null, + "Tags$key": null, + "Tags$value": null, "ThrottlingException$message": null, "ValidationException$message": null } @@ -199,11 +303,81 @@ "ListLinuxSubscriptionsResponse$Subscriptions": "

An array that contains subscription objects.

" } }, + "SubscriptionProviderArn": { + "base": null, + "refs": { + "DeregisterSubscriptionProviderRequest$SubscriptionProviderArn": "

The Amazon Resource Name (ARN) of the subscription provider resource to deregister.

", + "GetRegisteredSubscriptionProviderRequest$SubscriptionProviderArn": "

The Amazon Resource Name (ARN) of the BYOL registration resource to get details for.

", + "GetRegisteredSubscriptionProviderResponse$SubscriptionProviderArn": "

The Amazon Resource Name (ARN) for the BYOL registration resource specified in the request.

", + "ListTagsForResourceRequest$resourceArn": "

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

", + "RegisteredSubscriptionProvider$SubscriptionProviderArn": "

The Amazon Resource Name (ARN) of the Linux subscription provider resource that you registered.

", + "TagResourceRequest$resourceArn": "

The Amazon Resource Name (ARN) of the Amazon Web Services resource to which to add the specified metadata tags.

", + "UntagResourceRequest$resourceArn": "

The Amazon Resource Name (ARN) of the Amazon Web Services resource to remove the metadata tags from.

" + } + }, + "SubscriptionProviderSource": { + "base": null, + "refs": { + "GetRegisteredSubscriptionProviderResponse$SubscriptionProviderSource": "

The subscription provider for the BYOL registration resource specified in the request.

", + "RegisterSubscriptionProviderRequest$SubscriptionProviderSource": "

The supported Linux subscription provider to register.

", + "RegisterSubscriptionProviderResponse$SubscriptionProviderSource": "

The Linux subscription provider that you registered.

", + "RegisteredSubscriptionProvider$SubscriptionProviderSource": "

A supported third-party Linux subscription provider. License Manager currently supports Red Hat subscriptions.

", + "SubscriptionProviderSourceList$member": null + } + }, + "SubscriptionProviderSourceList": { + "base": null, + "refs": { + "ListRegisteredSubscriptionProvidersRequest$SubscriptionProviderSources": "

To filter your results, specify which subscription providers to return in the list.

" + } + }, + "SubscriptionProviderStatus": { + "base": null, + "refs": { + "GetRegisteredSubscriptionProviderResponse$SubscriptionProviderStatus": "

The status of the Linux subscription provider access token from the last successful subscription data request.

", + "RegisterSubscriptionProviderResponse$SubscriptionProviderStatus": "

Indicates the status of the registration action for the Linux subscription provider that you requested.

", + "RegisteredSubscriptionProvider$SubscriptionProviderStatus": "

Indicates the status of your registered Linux subscription provider access token from the last time License Manager retrieved subscription data. For RHEL account subscriptions, this is the status of the offline token.

" + } + }, + "TagKeyList": { + "base": null, + "refs": { + "UntagResourceRequest$tagKeys": "

A list of metadata tag keys to remove from the requested resource.

" + } + }, + "TagResourceRequest": { + "base": null, + "refs": { + } + }, + "TagResourceResponse": { + "base": null, + "refs": { + } + }, + "Tags": { + "base": null, + "refs": { + "ListTagsForResourceResponse$tags": "

The metadata tags for the requested resource.

", + "RegisterSubscriptionProviderRequest$Tags": "

The metadata tags to assign to your registered Linux subscription provider resource.

", + "TagResourceRequest$tags": "

The metadata tags to assign to the Amazon Web Services resource. Tags are formatted as key value pairs.

" + } + }, "ThrottlingException": { "base": "

The request was denied due to request throttling.

", "refs": { } }, + "UntagResourceRequest": { + "base": null, + "refs": { + } + }, + "UntagResourceResponse": { + "base": null, + "refs": { + } + }, "UpdateServiceSettingsRequest": { "base": null, "refs": { diff --git a/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-rule-set-1.json b/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-rule-set-1.json index c791b57af62..d624f6615f2 100644 --- a/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-rule-set-1.json +++ b/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-rule-set-1.json @@ -3,7 +3,7 @@ "parameters": { "Region": { "builtIn": "AWS::Region", - "required": true, + "required": false, "documentation": "The AWS region used to dispatch the request.", "type": "String" }, @@ -32,29 +32,32 @@ { "conditions": [ { - "fn": "aws.partition", + "fn": "isSet", "argv": [ { - "ref": "Region" + "ref": "Endpoint" } - ], - "assign": "PartitionResult" + ] } ], - "type": "tree", "rules": [ { "conditions": [ { - "fn": "isSet", + "fn": "booleanEquals", "argv": [ { - "ref": "Endpoint" - } + "ref": "UseFIPS" + }, + true ] } ], - "type": "tree", + "error": "Invalid Configuration: FIPS and custom endpoint are not supported", + "type": "error" + }, + { + "conditions": [], "rules": [ { "conditions": [ @@ -62,239 +65,286 @@ "fn": "booleanEquals", "argv": [ { - "ref": "UseFIPS" + "ref": "UseDualStack" }, true ] } ], - "error": "Invalid Configuration: FIPS and custom endpoint are not supported", + "error": "Invalid Configuration: Dualstack and custom endpoint are not supported", "type": "error" }, { "conditions": [], - "type": "tree", - "rules": [ - { - "conditions": [ - { - "fn": "booleanEquals", - "argv": [ - { - "ref": "UseDualStack" - }, - true - ] - } - ], - "error": "Invalid Configuration: Dualstack and custom endpoint are not supported", - "type": "error" + "endpoint": { + "url": { + "ref": "Endpoint" }, - { - "conditions": [], - "endpoint": { - "url": { - "ref": "Endpoint" - }, - "properties": {}, - "headers": {} - }, - "type": "endpoint" - } - ] + "properties": {}, + "headers": {} + }, + "type": "endpoint" } - ] - }, + ], + "type": "tree" + } + ], + "type": "tree" + }, + { + "conditions": [], + "rules": [ { "conditions": [ { - "fn": "booleanEquals", - "argv": [ - { - "ref": "UseFIPS" - }, - true - ] - }, - { - "fn": "booleanEquals", + "fn": "isSet", "argv": [ { - "ref": "UseDualStack" - }, - true + "ref": "Region" + } ] } ], - "type": "tree", "rules": [ { "conditions": [ { - "fn": "booleanEquals", + "fn": "aws.partition", "argv": [ - true, { - "fn": "getAttr", + "ref": "Region" + } + ], + "assign": "PartitionResult" + } + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", "argv": [ { - "ref": "PartitionResult" + "ref": "UseFIPS" }, - "supportsFIPS" + true ] - } - ] - }, - { - "fn": "booleanEquals", - "argv": [ - true, + }, { - "fn": "getAttr", + "fn": "booleanEquals", "argv": [ { - "ref": "PartitionResult" + "ref": "UseDualStack" }, - "supportsDualStack" + true ] } - ] - } - ], - "type": "tree", - "rules": [ - { - "conditions": [], - "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", - "properties": {}, - "headers": {} - }, - "type": "endpoint" - } - ] - }, - { - "conditions": [], - "error": "FIPS and DualStack are enabled, but this partition does not support one or both", - "type": "error" - } - ] - }, - { - "conditions": [ - { - "fn": "booleanEquals", - "argv": [ - { - "ref": "UseFIPS" + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsFIPS" + ] + } + ] + }, + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsDualStack" + ] + } + ] + } + ], + "rules": [ + { + "conditions": [], + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://license-manager-linux-subscriptions-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" + } + ], + "type": "tree" + }, + { + "conditions": [], + "error": "FIPS and DualStack are enabled, but this partition does not support one or both", + "type": "error" + } + ], + "type": "tree" }, - true - ] - } - ], - "type": "tree", - "rules": [ - { - "conditions": [ { - "fn": "booleanEquals", - "argv": [ - true, + "conditions": [ { - "fn": "getAttr", + "fn": "booleanEquals", "argv": [ { - "ref": "PartitionResult" + "ref": "UseFIPS" }, - "supportsFIPS" + true ] } - ] - } - ], - "type": "tree", - "rules": [ - { - "conditions": [], - "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.{Region}.{PartitionResult#dnsSuffix}", - "properties": {}, - "headers": {} - }, - "type": "endpoint" - } - ] - }, - { - "conditions": [], - "error": "FIPS is enabled but this partition does not support FIPS", - "type": "error" - } - ] - }, - { - "conditions": [ - { - "fn": "booleanEquals", - "argv": [ - { - "ref": "UseDualStack" + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsFIPS" + ] + }, + true + ] + } + ], + "rules": [ + { + "conditions": [], + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://license-manager-linux-subscriptions-fips.{Region}.{PartitionResult#dnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" + } + ], + "type": "tree" + }, + { + "conditions": [], + "error": "FIPS is enabled but this partition does not support FIPS", + "type": "error" + } + ], + "type": "tree" }, - true - ] - } - ], - "type": "tree", - "rules": [ - { - "conditions": [ { - "fn": "booleanEquals", - "argv": [ - true, + "conditions": [ { - "fn": "getAttr", + "fn": "booleanEquals", "argv": [ { - "ref": "PartitionResult" + "ref": "UseDualStack" }, - "supportsDualStack" + true ] } - ] - } - ], - "type": "tree", - "rules": [ + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsDualStack" + ] + } + ] + } + ], + "rules": [ + { + "conditions": [], + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://license-manager-linux-subscriptions.{Region}.{PartitionResult#dualStackDnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" + } + ], + "type": "tree" + }, + { + "conditions": [], + "error": "DualStack is enabled but this partition does not support DualStack", + "type": "error" + } + ], + "type": "tree" + }, { "conditions": [], - "endpoint": { - "url": "https://license-manager-linux-subscriptions.{Region}.{PartitionResult#dualStackDnsSuffix}", - "properties": {}, - "headers": {} - }, - "type": "endpoint" + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://license-manager-linux-subscriptions.{Region}.{PartitionResult#dnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" } - ] - }, - { - "conditions": [], - "error": "DualStack is enabled but this partition does not support DualStack", - "type": "error" + ], + "type": "tree" } - ] + ], + "type": "tree" }, { "conditions": [], - "endpoint": { - "url": "https://license-manager-linux-subscriptions.{Region}.{PartitionResult#dnsSuffix}", - "properties": {}, - "headers": {} - }, - "type": "endpoint" + "error": "Invalid Configuration: Missing Region", + "type": "error" } - ] + ], + "type": "tree" } ] } \ No newline at end of file diff --git a/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-tests-1.json b/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-tests-1.json index 7a6d99eeb06..ce540aefdc2 100644 --- a/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-tests-1.json +++ b/models/apis/license-manager-linux-subscriptions/2018-05-10/endpoint-tests-1.json @@ -1,55 +1,55 @@ { "testCases": [ { - "documentation": "For region us-gov-east-1 with FIPS enabled and DualStack enabled", + "documentation": "For region us-east-1 with FIPS enabled and DualStack enabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.us-gov-east-1.api.aws" + "url": "https://license-manager-linux-subscriptions-fips.us-east-1.api.aws" } }, "params": { - "Region": "us-gov-east-1", - "UseDualStack": true, - "UseFIPS": true + "Region": "us-east-1", + "UseFIPS": true, + "UseDualStack": true } }, { - "documentation": "For region us-gov-east-1 with FIPS enabled and DualStack disabled", + "documentation": "For region us-east-1 with FIPS enabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.us-gov-east-1.amazonaws.com" + "url": "https://license-manager-linux-subscriptions-fips.us-east-1.amazonaws.com" } }, "params": { - "Region": "us-gov-east-1", - "UseDualStack": false, - "UseFIPS": true + "Region": "us-east-1", + "UseFIPS": true, + "UseDualStack": false } }, { - "documentation": "For region us-gov-east-1 with FIPS disabled and DualStack enabled", + "documentation": "For region us-east-1 with FIPS disabled and DualStack enabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions.us-gov-east-1.api.aws" + "url": "https://license-manager-linux-subscriptions.us-east-1.api.aws" } }, "params": { - "Region": "us-gov-east-1", - "UseDualStack": true, - "UseFIPS": false + "Region": "us-east-1", + "UseFIPS": false, + "UseDualStack": true } }, { - "documentation": "For region us-gov-east-1 with FIPS disabled and DualStack disabled", + "documentation": "For region us-east-1 with FIPS disabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions.us-gov-east-1.amazonaws.com" + "url": "https://license-manager-linux-subscriptions.us-east-1.amazonaws.com" } }, "params": { - "Region": "us-gov-east-1", - "UseDualStack": false, - "UseFIPS": false + "Region": "us-east-1", + "UseFIPS": false, + "UseDualStack": false } }, { @@ -61,8 +61,8 @@ }, "params": { "Region": "cn-north-1", - "UseDualStack": true, - "UseFIPS": true + "UseFIPS": true, + "UseDualStack": true } }, { @@ -74,8 +74,8 @@ }, "params": { "Region": "cn-north-1", - "UseDualStack": false, - "UseFIPS": true + "UseFIPS": true, + "UseDualStack": false } }, { @@ -87,8 +87,8 @@ }, "params": { "Region": "cn-north-1", - "UseDualStack": true, - "UseFIPS": false + "UseFIPS": false, + "UseDualStack": true } }, { @@ -100,108 +100,108 @@ }, "params": { "Region": "cn-north-1", - "UseDualStack": false, - "UseFIPS": false + "UseFIPS": false, + "UseDualStack": false } }, { - "documentation": "For region us-iso-east-1 with FIPS enabled and DualStack enabled", + "documentation": "For region us-gov-east-1 with FIPS enabled and DualStack enabled", "expect": { - "error": "FIPS and DualStack are enabled, but this partition does not support one or both" + "endpoint": { + "url": "https://license-manager-linux-subscriptions-fips.us-gov-east-1.api.aws" + } }, "params": { - "Region": "us-iso-east-1", - "UseDualStack": true, - "UseFIPS": true + "Region": "us-gov-east-1", + "UseFIPS": true, + "UseDualStack": true } }, { - "documentation": "For region us-iso-east-1 with FIPS enabled and DualStack disabled", + "documentation": "For region us-gov-east-1 with FIPS enabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.us-iso-east-1.c2s.ic.gov" + "url": "https://license-manager-linux-subscriptions-fips.us-gov-east-1.amazonaws.com" } }, "params": { - "Region": "us-iso-east-1", - "UseDualStack": false, - "UseFIPS": true + "Region": "us-gov-east-1", + "UseFIPS": true, + "UseDualStack": false } }, { - "documentation": "For region us-iso-east-1 with FIPS disabled and DualStack enabled", + "documentation": "For region us-gov-east-1 with FIPS disabled and DualStack enabled", "expect": { - "error": "DualStack is enabled but this partition does not support DualStack" + "endpoint": { + "url": "https://license-manager-linux-subscriptions.us-gov-east-1.api.aws" + } }, "params": { - "Region": "us-iso-east-1", - "UseDualStack": true, - "UseFIPS": false + "Region": "us-gov-east-1", + "UseFIPS": false, + "UseDualStack": true } }, { - "documentation": "For region us-iso-east-1 with FIPS disabled and DualStack disabled", + "documentation": "For region us-gov-east-1 with FIPS disabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions.us-iso-east-1.c2s.ic.gov" + "url": "https://license-manager-linux-subscriptions.us-gov-east-1.amazonaws.com" } }, "params": { - "Region": "us-iso-east-1", - "UseDualStack": false, - "UseFIPS": false + "Region": "us-gov-east-1", + "UseFIPS": false, + "UseDualStack": false } }, { - "documentation": "For region us-east-1 with FIPS enabled and DualStack enabled", + "documentation": "For region us-iso-east-1 with FIPS enabled and DualStack enabled", "expect": { - "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.us-east-1.api.aws" - } + "error": "FIPS and DualStack are enabled, but this partition does not support one or both" }, "params": { - "Region": "us-east-1", - "UseDualStack": true, - "UseFIPS": true + "Region": "us-iso-east-1", + "UseFIPS": true, + "UseDualStack": true } }, { - "documentation": "For region us-east-1 with FIPS enabled and DualStack disabled", + "documentation": "For region us-iso-east-1 with FIPS enabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions-fips.us-east-1.amazonaws.com" + "url": "https://license-manager-linux-subscriptions-fips.us-iso-east-1.c2s.ic.gov" } }, "params": { - "Region": "us-east-1", - "UseDualStack": false, - "UseFIPS": true + "Region": "us-iso-east-1", + "UseFIPS": true, + "UseDualStack": false } }, { - "documentation": "For region us-east-1 with FIPS disabled and DualStack enabled", + "documentation": "For region us-iso-east-1 with FIPS disabled and DualStack enabled", "expect": { - "endpoint": { - "url": "https://license-manager-linux-subscriptions.us-east-1.api.aws" - } + "error": "DualStack is enabled but this partition does not support DualStack" }, "params": { - "Region": "us-east-1", - "UseDualStack": true, - "UseFIPS": false + "Region": "us-iso-east-1", + "UseFIPS": false, + "UseDualStack": true } }, { - "documentation": "For region us-east-1 with FIPS disabled and DualStack disabled", + "documentation": "For region us-iso-east-1 with FIPS disabled and DualStack disabled", "expect": { "endpoint": { - "url": "https://license-manager-linux-subscriptions.us-east-1.amazonaws.com" + "url": "https://license-manager-linux-subscriptions.us-iso-east-1.c2s.ic.gov" } }, "params": { - "Region": "us-east-1", - "UseDualStack": false, - "UseFIPS": false + "Region": "us-iso-east-1", + "UseFIPS": false, + "UseDualStack": false } }, { @@ -211,8 +211,8 @@ }, "params": { "Region": "us-isob-east-1", - "UseDualStack": true, - "UseFIPS": true + "UseFIPS": true, + "UseDualStack": true } }, { @@ -224,8 +224,8 @@ }, "params": { "Region": "us-isob-east-1", - "UseDualStack": false, - "UseFIPS": true + "UseFIPS": true, + "UseDualStack": false } }, { @@ -235,8 +235,8 @@ }, "params": { "Region": "us-isob-east-1", - "UseDualStack": true, - "UseFIPS": false + "UseFIPS": false, + "UseDualStack": true } }, { @@ -248,12 +248,12 @@ }, "params": { "Region": "us-isob-east-1", - "UseDualStack": false, - "UseFIPS": false + "UseFIPS": false, + "UseDualStack": false } }, { - "documentation": "For custom endpoint with fips disabled and dualstack disabled", + "documentation": "For custom endpoint with region set and fips disabled and dualstack disabled", "expect": { "endpoint": { "url": "https://example.com" @@ -261,8 +261,21 @@ }, "params": { "Region": "us-east-1", + "UseFIPS": false, "UseDualStack": false, + "Endpoint": "https://example.com" + } + }, + { + "documentation": "For custom endpoint with region not set and fips disabled and dualstack disabled", + "expect": { + "endpoint": { + "url": "https://example.com" + } + }, + "params": { "UseFIPS": false, + "UseDualStack": false, "Endpoint": "https://example.com" } }, @@ -273,8 +286,8 @@ }, "params": { "Region": "us-east-1", - "UseDualStack": false, "UseFIPS": true, + "UseDualStack": false, "Endpoint": "https://example.com" } }, @@ -285,10 +298,16 @@ }, "params": { "Region": "us-east-1", - "UseDualStack": true, "UseFIPS": false, + "UseDualStack": true, "Endpoint": "https://example.com" } + }, + { + "documentation": "Missing region", + "expect": { + "error": "Invalid Configuration: Missing Region" + } } ], "version": "1.0" diff --git a/models/apis/license-manager-linux-subscriptions/2018-05-10/paginators-1.json b/models/apis/license-manager-linux-subscriptions/2018-05-10/paginators-1.json index 1dc8f4d8276..6d74d22e337 100644 --- a/models/apis/license-manager-linux-subscriptions/2018-05-10/paginators-1.json +++ b/models/apis/license-manager-linux-subscriptions/2018-05-10/paginators-1.json @@ -11,6 +11,12 @@ "output_token": "NextToken", "limit_key": "MaxResults", "result_key": "Subscriptions" + }, + "ListRegisteredSubscriptionProviders": { + "input_token": "NextToken", + "output_token": "NextToken", + "limit_key": "MaxResults", + "result_key": "RegisteredSubscriptionProviders" } } } diff --git a/models/apis/mediaconnect/2018-11-14/api-2.json b/models/apis/mediaconnect/2018-11-14/api-2.json index 7eb801064a0..81751141d5d 100644 --- a/models/apis/mediaconnect/2018-11-14/api-2.json +++ b/models/apis/mediaconnect/2018-11-14/api-2.json @@ -8,7 +8,10 @@ "protocol": "rest-json", "jsonVersion": "1.1", "uid": "mediaconnect-2018-11-14", - "signatureVersion": "v4" + "signatureVersion": "v4", + "auth": [ + "aws.auth#sigv4" + ] }, "operations": { "AddBridgeOutputs": { @@ -2199,6 +2202,10 @@ "VpcInterfaceAttachment": { "shape": "VpcInterfaceAttachment", "locationName": "vpcInterfaceAttachment" + }, + "OutputStatus": { + "shape": "OutputStatus", + "locationName": "outputStatus" } }, "required": [ @@ -4427,6 +4434,10 @@ "BridgePorts": { "shape": "__listOf__integer", "locationName": "bridgePorts" + }, + "OutputStatus": { + "shape": "OutputStatus", + "locationName": "outputStatus" } }, "required": [ @@ -4434,6 +4445,13 @@ "Name" ] }, + "OutputStatus": { + "type": "string", + "enum": [ + "ENABLED", + "DISABLED" + ] + }, "PriceUnits": { "type": "string", "enum": [ @@ -5794,6 +5812,10 @@ "VpcInterfaceAttachment": { "shape": "VpcInterfaceAttachment", "locationName": "vpcInterfaceAttachment" + }, + "OutputStatus": { + "shape": "OutputStatus", + "locationName": "outputStatus" } }, "required": [ @@ -6347,4 +6369,4 @@ "timestampFormat": "unixTimestamp" } } -} +} \ No newline at end of file diff --git a/models/apis/mediaconnect/2018-11-14/docs-2.json b/models/apis/mediaconnect/2018-11-14/docs-2.json index dea828ce2fb..4b3f43402ef 100644 --- a/models/apis/mediaconnect/2018-11-14/docs-2.json +++ b/models/apis/mediaconnect/2018-11-14/docs-2.json @@ -730,6 +730,14 @@ "__listOfOutput$member" : null } }, + "OutputStatus": { + "base": null, + "refs": { + "AddOutputRequest$OutputStatus": "An indication of whether the new output should be enabled or disabled as soon as it is created. If you don't specify the outputStatus field in your request, MediaConnect sets it to ENABLED.", + "Output$OutputStatus": "An indication of whether the output is transmitting data or not.", + "UpdateFlowOutputRequest$OutputStatus": "An indication of whether the output should transmit data or not. If you don't specify the outputStatus field in your request, MediaConnect leaves the value unchanged." + } + }, "PriceUnits" : { "base" : null, "refs" : { diff --git a/models/endpoints/endpoints.json b/models/endpoints/endpoints.json index 56460f6da0f..6decd3e23e7 100644 --- a/models/endpoints/endpoints.json +++ b/models/endpoints/endpoints.json @@ -3018,6 +3018,12 @@ "ca-central-1" : { "variants" : [ { "tags" : [ "dualstack" ] + }, { + "hostname" : "cloud9-fips.ca-central-1.amazonaws.com", + "tags" : [ "fips" ] + }, { + "hostname" : "cloud9-fips.ca-central-1.api.aws", + "tags" : [ "dualstack", "fips" ] } ] }, "eu-central-1" : { @@ -3050,6 +3056,41 @@ "tags" : [ "dualstack" ] } ] }, + "fips-ca-central-1" : { + "credentialScope" : { + "region" : "ca-central-1" + }, + "deprecated" : true, + "hostname" : "cloud9-fips.ca-central-1.amazonaws.com" + }, + "fips-us-east-1" : { + "credentialScope" : { + "region" : "us-east-1" + }, + "deprecated" : true, + "hostname" : "cloud9-fips.us-east-1.amazonaws.com" + }, + "fips-us-east-2" : { + "credentialScope" : { + "region" : "us-east-2" + }, + "deprecated" : true, + "hostname" : "cloud9-fips.us-east-2.amazonaws.com" + }, + "fips-us-west-1" : { + "credentialScope" : { + "region" : "us-west-1" + }, + "deprecated" : true, + "hostname" : "cloud9-fips.us-west-1.amazonaws.com" + }, + "fips-us-west-2" : { + "credentialScope" : { + "region" : "us-west-2" + }, + "deprecated" : true, + "hostname" : "cloud9-fips.us-west-2.amazonaws.com" + }, "il-central-1" : { "variants" : [ { "tags" : [ "dualstack" ] @@ -3068,58 +3109,189 @@ "us-east-1" : { "variants" : [ { "tags" : [ "dualstack" ] + }, { + "hostname" : "cloud9-fips.us-east-1.amazonaws.com", + "tags" : [ "fips" ] + }, { + "hostname" : "cloud9-fips.us-east-1.api.aws", + "tags" : [ "dualstack", "fips" ] } ] }, "us-east-2" : { "variants" : [ { "tags" : [ "dualstack" ] + }, { + "hostname" : "cloud9-fips.us-east-2.amazonaws.com", + "tags" : [ "fips" ] + }, { + "hostname" : "cloud9-fips.us-east-2.api.aws", + "tags" : [ "dualstack", "fips" ] } ] }, "us-west-1" : { "variants" : [ { "tags" : [ "dualstack" ] + }, { + "hostname" : "cloud9-fips.us-west-1.amazonaws.com", + "tags" : [ "fips" ] + }, { + "hostname" : "cloud9-fips.us-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] } ] }, "us-west-2" : { "variants" : [ { "tags" : [ "dualstack" ] + }, { + "hostname" : "cloud9-fips.us-west-2.amazonaws.com", + "tags" : [ "fips" ] + }, { + "hostname" : "cloud9-fips.us-west-2.api.aws", + "tags" : [ "dualstack", "fips" ] } ] } } }, "cloudcontrolapi" : { "endpoints" : { - "af-south-1" : { }, - "ap-east-1" : { }, - "ap-northeast-1" : { }, - "ap-northeast-2" : { }, - "ap-northeast-3" : { }, - "ap-south-1" : { }, - "ap-south-2" : { }, - "ap-southeast-1" : { }, - "ap-southeast-2" : { }, - "ap-southeast-3" : { }, - "ap-southeast-4" : { }, + "af-south-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.af-south-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-east-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-east-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-northeast-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-northeast-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-northeast-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-northeast-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-northeast-3" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-northeast-3.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-south-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-south-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-south-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-south-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-southeast-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-southeast-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-3" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-southeast-3.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-4" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.ap-southeast-4.api.aws", + "tags" : [ "dualstack" ] + } ] + }, "ca-central-1" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.ca-central-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.ca-central-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.ca-central-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "ca-west-1" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.ca-west-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.ca-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.ca-west-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-central-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-central-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-central-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-central-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-north-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-north-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-south-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-south-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-south-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-south-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-west-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-2" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-west-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-3" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.eu-west-3.api.aws", + "tags" : [ "dualstack" ] } ] }, - "eu-central-1" : { }, - "eu-central-2" : { }, - "eu-north-1" : { }, - "eu-south-1" : { }, - "eu-south-2" : { }, - "eu-west-1" : { }, - "eu-west-2" : { }, - "eu-west-3" : { }, "fips-ca-central-1" : { "credentialScope" : { "region" : "ca-central-1" @@ -3162,32 +3334,76 @@ "deprecated" : true, "hostname" : "cloudcontrolapi-fips.us-west-2.amazonaws.com" }, - "il-central-1" : { }, - "me-central-1" : { }, - "me-south-1" : { }, - "sa-east-1" : { }, + "il-central-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.il-central-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "me-central-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.me-central-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "me-south-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.me-south-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "sa-east-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.sa-east-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, "us-east-1" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-east-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-east-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-east-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-east-2" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-east-2.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-east-2.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-east-2.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-west-1" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-west-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-west-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-west-2" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-west-2.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-west-2.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-west-2.api.aws", + "tags" : [ "dualstack" ] } ] } } @@ -19376,20 +19592,66 @@ }, "textract" : { "endpoints" : { - "ap-northeast-2" : { }, - "ap-south-1" : { }, - "ap-southeast-1" : { }, - "ap-southeast-2" : { }, + "ap-northeast-2" : { + "variants" : [ { + "hostname" : "textract.ap-northeast-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-south-1" : { + "variants" : [ { + "hostname" : "textract.ap-south-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-1" : { + "variants" : [ { + "hostname" : "textract.ap-southeast-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "ap-southeast-2" : { + "variants" : [ { + "hostname" : "textract.ap-southeast-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, "ca-central-1" : { "variants" : [ { "hostname" : "textract-fips.ca-central-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.ca-central-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.ca-central-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-central-1" : { + "variants" : [ { + "hostname" : "textract.eu-central-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-1" : { + "variants" : [ { + "hostname" : "textract.eu-west-1.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-2" : { + "variants" : [ { + "hostname" : "textract.eu-west-2.api.aws", + "tags" : [ "dualstack" ] + } ] + }, + "eu-west-3" : { + "variants" : [ { + "hostname" : "textract.eu-west-3.api.aws", + "tags" : [ "dualstack" ] } ] }, - "eu-central-1" : { }, - "eu-west-1" : { }, - "eu-west-2" : { }, - "eu-west-3" : { }, "fips-ca-central-1" : { "credentialScope" : { "region" : "ca-central-1" @@ -19429,24 +19691,48 @@ "variants" : [ { "hostname" : "textract-fips.us-east-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-east-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-east-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-east-2" : { "variants" : [ { "hostname" : "textract-fips.us-east-2.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-east-2.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-east-2.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-west-1" : { "variants" : [ { "hostname" : "textract-fips.us-west-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-west-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-west-2" : { "variants" : [ { "hostname" : "textract-fips.us-west-2.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-west-2.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-west-2.api.aws", + "tags" : [ "dualstack" ] } ] } } @@ -21556,8 +21842,18 @@ }, "cloudcontrolapi" : { "endpoints" : { - "cn-north-1" : { }, - "cn-northwest-1" : { } + "cn-north-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.cn-north-1.api.amazonwebservices.com.cn", + "tags" : [ "dualstack" ] + } ] + }, + "cn-northwest-1" : { + "variants" : [ { + "hostname" : "cloudcontrolapi.cn-northwest-1.api.amazonwebservices.com.cn", + "tags" : [ "dualstack" ] + } ] + } } }, "cloudformation" : { @@ -23547,12 +23843,24 @@ "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-gov-east-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-gov-east-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-gov-east-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-gov-west-1" : { "variants" : [ { "hostname" : "cloudcontrolapi-fips.us-gov-west-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "cloudcontrolapi-fips.us-gov-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "cloudcontrolapi.us-gov-west-1.api.aws", + "tags" : [ "dualstack" ] } ] } } @@ -27633,12 +27941,24 @@ "variants" : [ { "hostname" : "textract-fips.us-gov-east-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-gov-east-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-gov-east-1.api.aws", + "tags" : [ "dualstack" ] } ] }, "us-gov-west-1" : { "variants" : [ { "hostname" : "textract-fips.us-gov-west-1.amazonaws.com", "tags" : [ "fips" ] + }, { + "hostname" : "textract-fips.us-gov-west-1.api.aws", + "tags" : [ "dualstack", "fips" ] + }, { + "hostname" : "textract.us-gov-west-1.api.aws", + "tags" : [ "dualstack" ] } ] } } diff --git a/service/batch/api.go b/service/batch/api.go index 585864c5fef..b04fb35b4c7 100644 --- a/service/batch/api.go +++ b/service/batch/api.go @@ -7516,6 +7516,9 @@ type EksAttemptDetail struct { // The details for the final status of the containers for this job attempt. Containers []*EksAttemptContainerDetail `locationName:"containers" type:"list"` + // The Amazon Resource Name (ARN) of the Amazon EKS cluster. + EksClusterArn *string `locationName:"eksClusterArn" type:"string"` + // The details for the init containers. InitContainers []*EksAttemptContainerDetail `locationName:"initContainers" type:"list"` @@ -7563,6 +7566,12 @@ func (s *EksAttemptDetail) SetContainers(v []*EksAttemptContainerDetail) *EksAtt return s } +// SetEksClusterArn sets the EksClusterArn field's value. +func (s *EksAttemptDetail) SetEksClusterArn(v string) *EksAttemptDetail { + s.EksClusterArn = &v + return s +} + // SetInitContainers sets the InitContainers field's value. func (s *EksAttemptDetail) SetInitContainers(v []*EksAttemptContainerDetail) *EksAttemptDetail { s.InitContainers = v @@ -12095,6 +12104,10 @@ type NodePropertyOverride struct { // Amazon ECS resources of a job. EcsPropertiesOverride *EcsPropertiesOverride `locationName:"ecsPropertiesOverride" type:"structure"` + // An object that contains the properties that you want to replace for the existing + // Amazon EKS resources of a job. + EksPropertiesOverride *EksPropertiesOverride `locationName:"eksPropertiesOverride" type:"structure"` + // An object that contains the instance types that you want to replace for the // existing resources of a job. InstanceTypes []*string `locationName:"instanceTypes" type:"list"` @@ -12143,6 +12156,11 @@ func (s *NodePropertyOverride) Validate() error { invalidParams.AddNested("EcsPropertiesOverride", err.(request.ErrInvalidParams)) } } + if s.EksPropertiesOverride != nil { + if err := s.EksPropertiesOverride.Validate(); err != nil { + invalidParams.AddNested("EksPropertiesOverride", err.(request.ErrInvalidParams)) + } + } if invalidParams.Len() > 0 { return invalidParams @@ -12162,6 +12180,12 @@ func (s *NodePropertyOverride) SetEcsPropertiesOverride(v *EcsPropertiesOverride return s } +// SetEksPropertiesOverride sets the EksPropertiesOverride field's value. +func (s *NodePropertyOverride) SetEksPropertiesOverride(v *EksPropertiesOverride) *NodePropertyOverride { + s.EksPropertiesOverride = v + return s +} + // SetInstanceTypes sets the InstanceTypes field's value. func (s *NodePropertyOverride) SetInstanceTypes(v []*string) *NodePropertyOverride { s.InstanceTypes = v @@ -12186,6 +12210,10 @@ type NodeRangeProperty struct { // multi-node parallel job. EcsProperties *EcsProperties `locationName:"ecsProperties" type:"structure"` + // This is an object that represents the properties of the node range for a + // multi-node parallel job. + EksProperties *EksProperties `locationName:"eksProperties" type:"structure"` + // The instance types of the underlying host infrastructure of a multi-node // parallel job. // @@ -12240,6 +12268,11 @@ func (s *NodeRangeProperty) Validate() error { invalidParams.AddNested("EcsProperties", err.(request.ErrInvalidParams)) } } + if s.EksProperties != nil { + if err := s.EksProperties.Validate(); err != nil { + invalidParams.AddNested("EksProperties", err.(request.ErrInvalidParams)) + } + } if invalidParams.Len() > 0 { return invalidParams @@ -12259,6 +12292,12 @@ func (s *NodeRangeProperty) SetEcsProperties(v *EcsProperties) *NodeRangePropert return s } +// SetEksProperties sets the EksProperties field's value. +func (s *NodeRangeProperty) SetEksProperties(v *EksProperties) *NodeRangeProperty { + s.EksProperties = v + return s +} + // SetInstanceTypes sets the InstanceTypes field's value. func (s *NodeRangeProperty) SetInstanceTypes(v []*string) *NodeRangeProperty { s.InstanceTypes = v diff --git a/service/bedrock/api.go b/service/bedrock/api.go index 96b4870ac66..344c15b53ea 100644 --- a/service/bedrock/api.go +++ b/service/bedrock/api.go @@ -157,37 +157,34 @@ func (c *Bedrock) CreateGuardrailRequest(input *CreateGuardrailInput) (req *requ // CreateGuardrail API operation for Amazon Bedrock. // -// Creates a guardrail to block topics and to filter out harmful content. +// Creates a guardrail to block topics and to implement safeguards for your +// generative AI applications. // -// - Specify a name and optional description. +// You can configure the following policies in a guardrail to avoid undesirable +// and harmful content, filter out denied topics and words, and remove sensitive +// information for privacy protection. // -// - Specify messages for when the guardrail successfully blocks a prompt -// or a model response in the blockedInputMessaging and blockedOutputsMessaging -// fields. +// - Content filters - Adjust filter strengths to block input prompts or +// model responses containing harmful content. // -// - Specify topics for the guardrail to deny in the topicPolicyConfig object. -// Each GuardrailTopicConfig (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailTopicConfig.html) -// object in the topicsConfig list pertains to one topic. Give a name and -// description so that the guardrail can properly identify the topic. Specify -// DENY in the type field. (Optional) Provide up to five prompts that you -// would categorize as belonging to the topic in the examples list. +// - Denied topics - Define a set of topics that are undesirable in the context +// of your application. These topics will be blocked if detected in user +// queries or model responses. // -// - Specify filter strengths for the harmful categories defined in Amazon -// Bedrock in the contentPolicyConfig object. Each GuardrailContentFilterConfig -// (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailContentFilterConfig.html) -// object in the filtersConfig list pertains to a harmful category. For more -// information, see Content filters (https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails-filters). -// For more information about the fields in a content filter, see GuardrailContentFilterConfig -// (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailContentFilterConfig.html). -// Specify the category in the type field. Specify the strength of the filter -// for prompts in the inputStrength field and for model responses in the -// strength field of the GuardrailContentFilterConfig (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailContentFilterConfig.html). +// - Word filters - Configure filters to block undesirable words, phrases, +// and profanity. Such words can include offensive terms, competitor names +// etc. // -// - (Optional) For security, include the ARN of a KMS key in the kmsKeyId -// field. +// - Sensitive information filters - Block or mask sensitive information +// such as personally identifiable information (PII) or custom regex in user +// inputs and model responses. +// +// In addition to the above policies, you can also configure the messages to +// be returned to the user if a user input or model response is in violation +// of the policies defined in the guardrail. // -// - (Optional) Attach any tags to the guardrail in the tags object. For -// more information, see Tag resources (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging). +// For more information, see Guardrails for Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -3074,7 +3071,7 @@ func (c *Bedrock) UpdateGuardrailRequest(input *UpdateGuardrailInput) (req *requ // Bedrock in the contentPolicyConfig object. Each GuardrailContentFilterConfig // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailContentFilterConfig.html) // object in the filtersConfig list pertains to a harmful category. For more -// information, see Content filters (https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails-filters). +// information, see Content filters (https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails-content-filters). // For more information about the fields in a content filter, see GuardrailContentFilterConfig // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GuardrailContentFilterConfig.html). // Specify the category in the type field. Specify the strength of the filter @@ -3084,9 +3081,6 @@ func (c *Bedrock) UpdateGuardrailRequest(input *UpdateGuardrailInput) (req *requ // - (Optional) For security, include the ARN of a KMS key in the kmsKeyId // field. // -// - (Optional) Attach any tags to the guardrail in the tags object. For -// more information, see Tag resources (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging). -// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -3758,6 +3752,9 @@ type CreateGuardrailInput struct { // The content filter policies to configure for the guardrail. ContentPolicyConfig *GuardrailContentPolicyConfig `locationName:"contentPolicyConfig" type:"structure"` + // The contextual grounding policy configuration used to create a guardrail. + ContextualGroundingPolicyConfig *GuardrailContextualGroundingPolicyConfig `locationName:"contextualGroundingPolicyConfig" type:"structure"` + // A description of the guardrail. // // Description is a sensitive parameter and its value will be @@ -3843,6 +3840,11 @@ func (s *CreateGuardrailInput) Validate() error { invalidParams.AddNested("ContentPolicyConfig", err.(request.ErrInvalidParams)) } } + if s.ContextualGroundingPolicyConfig != nil { + if err := s.ContextualGroundingPolicyConfig.Validate(); err != nil { + invalidParams.AddNested("ContextualGroundingPolicyConfig", err.(request.ErrInvalidParams)) + } + } if s.SensitiveInformationPolicyConfig != nil { if err := s.SensitiveInformationPolicyConfig.Validate(); err != nil { invalidParams.AddNested("SensitiveInformationPolicyConfig", err.(request.ErrInvalidParams)) @@ -3899,6 +3901,12 @@ func (s *CreateGuardrailInput) SetContentPolicyConfig(v *GuardrailContentPolicyC return s } +// SetContextualGroundingPolicyConfig sets the ContextualGroundingPolicyConfig field's value. +func (s *CreateGuardrailInput) SetContextualGroundingPolicyConfig(v *GuardrailContextualGroundingPolicyConfig) *CreateGuardrailInput { + s.ContextualGroundingPolicyConfig = v + return s +} + // SetDescription sets the Description field's value. func (s *CreateGuardrailInput) SetDescription(v string) *CreateGuardrailInput { s.Description = &v @@ -3949,7 +3957,7 @@ type CreateGuardrailOutput struct { // CreatedAt is a required field CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The ARN of the guardrail that was created. + // The ARN of the guardrail. // // GuardrailArn is a required field GuardrailArn *string `locationName:"guardrailArn" type:"string" required:"true"` @@ -3959,7 +3967,8 @@ type CreateGuardrailOutput struct { // GuardrailId is a required field GuardrailId *string `locationName:"guardrailId" type:"string" required:"true"` - // The version of the guardrail that was created. This value should be 1. + // The version of the guardrail that was created. This value will always be + // DRAFT. // // Version is a required field Version *string `locationName:"version" min:"5" type:"string" required:"true"` @@ -4024,7 +4033,7 @@ type CreateGuardrailVersionInput struct { // String and GoString methods. Description *string `locationName:"description" min:"1" type:"string" sensitive:"true"` - // The unique identifier of the guardrail. + // The unique identifier of the guardrail. This can be an ID or the ARN. // // GuardrailIdentifier is a required field GuardrailIdentifier *string `location:"uri" locationName:"guardrailIdentifier" type:"string" required:"true"` @@ -4767,7 +4776,7 @@ func (s DeleteCustomModelOutput) GoString() string { type DeleteGuardrailInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the guardrail. + // The unique identifier of the guardrail. This can be an ID or the ARN. // // GuardrailIdentifier is a required field GuardrailIdentifier *string `location:"uri" locationName:"guardrailIdentifier" type:"string" required:"true"` @@ -6348,7 +6357,8 @@ func (s *GetFoundationModelOutput) SetModelDetails(v *FoundationModelDetails) *G type GetGuardrailInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the guardrail for which to get details. + // The unique identifier of the guardrail for which to get details. This can + // be an ID or the ARN. // // GuardrailIdentifier is a required field GuardrailIdentifier *string `location:"uri" locationName:"guardrailIdentifier" type:"string" required:"true"` @@ -6428,6 +6438,9 @@ type GetGuardrailOutput struct { // The content policy that was configured for the guardrail. ContentPolicy *GuardrailContentPolicy `locationName:"contentPolicy" type:"structure"` + // The contextual grounding policy used in the guardrail. + ContextualGroundingPolicy *GuardrailContextualGroundingPolicy `locationName:"contextualGroundingPolicy" type:"structure"` + // The date and time at which the guardrail was created. // // CreatedAt is a required field @@ -6444,7 +6457,7 @@ type GetGuardrailOutput struct { // to carry out before retrying the request. FailureRecommendations []*string `locationName:"failureRecommendations" type:"list"` - // The ARN of the guardrail that was created. + // The ARN of the guardrail. // // GuardrailArn is a required field GuardrailArn *string `locationName:"guardrailArn" type:"string" required:"true"` @@ -6531,6 +6544,12 @@ func (s *GetGuardrailOutput) SetContentPolicy(v *GuardrailContentPolicy) *GetGua return s } +// SetContextualGroundingPolicy sets the ContextualGroundingPolicy field's value. +func (s *GetGuardrailOutput) SetContextualGroundingPolicy(v *GuardrailContextualGroundingPolicy) *GetGuardrailOutput { + s.ContextualGroundingPolicy = v + return s +} + // SetCreatedAt sets the CreatedAt field's value. func (s *GetGuardrailOutput) SetCreatedAt(v time.Time) *GetGuardrailOutput { s.CreatedAt = &v @@ -7295,12 +7314,6 @@ func (s *GuardrailContentFilter) SetType(v string) *GuardrailContentFilter { // confidence. // // For more information, see Guardrails content filters (https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails-filters.html). -// -// This data type is used in the following API operations: -// -// - CreateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateGuardrail.html#API_CreateGuardrail_RequestSyntax) -// -// - UpdateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_UpdateGuardrail.html#API_UpdateGuardrail_RequestSyntax) type GuardrailContentFilterConfig struct { _ struct{} `type:"structure"` @@ -7417,12 +7430,6 @@ func (s *GuardrailContentPolicy) SetFilters(v []*GuardrailContentFilter) *Guardr } // Contains details about how to handle harmful content. -// -// This data type is used in the following API operations: -// -// - CreateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateGuardrail.html#API_CreateGuardrail_RequestSyntax) -// -// - UpdateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_UpdateGuardrail.html#API_UpdateGuardrail_RequestSyntax) type GuardrailContentPolicyConfig struct { _ struct{} `type:"structure"` @@ -7483,8 +7490,211 @@ func (s *GuardrailContentPolicyConfig) SetFiltersConfig(v []*GuardrailContentFil return s } +// The details for the guardrails contextual grounding filter. +type GuardrailContextualGroundingFilter struct { + _ struct{} `type:"structure"` + + // The threshold details for the guardrails contextual grounding filter. + // + // Threshold is a required field + Threshold *float64 `locationName:"threshold" type:"double" required:"true"` + + // The filter type details for the guardrails contextual grounding filter. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"GuardrailContextualGroundingFilterType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilter) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilter) GoString() string { + return s.String() +} + +// SetThreshold sets the Threshold field's value. +func (s *GuardrailContextualGroundingFilter) SetThreshold(v float64) *GuardrailContextualGroundingFilter { + s.Threshold = &v + return s +} + +// SetType sets the Type field's value. +func (s *GuardrailContextualGroundingFilter) SetType(v string) *GuardrailContextualGroundingFilter { + s.Type = &v + return s +} + +// The filter configuration details for the guardrails contextual grounding +// filter. +type GuardrailContextualGroundingFilterConfig struct { + _ struct{} `type:"structure"` + + // The threshold details for the guardrails contextual grounding filter. + // + // Threshold is a required field + Threshold *float64 `locationName:"threshold" type:"double" required:"true"` + + // The filter details for the guardrails contextual grounding filter. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"GuardrailContextualGroundingFilterType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilterConfig) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilterConfig) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GuardrailContextualGroundingFilterConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GuardrailContextualGroundingFilterConfig"} + if s.Threshold == nil { + invalidParams.Add(request.NewErrParamRequired("Threshold")) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetThreshold sets the Threshold field's value. +func (s *GuardrailContextualGroundingFilterConfig) SetThreshold(v float64) *GuardrailContextualGroundingFilterConfig { + s.Threshold = &v + return s +} + +// SetType sets the Type field's value. +func (s *GuardrailContextualGroundingFilterConfig) SetType(v string) *GuardrailContextualGroundingFilterConfig { + s.Type = &v + return s +} + +// The details for the guardrails contextual grounding policy. +type GuardrailContextualGroundingPolicy struct { + _ struct{} `type:"structure"` + + // The filter details for the guardrails contextual grounding policy. + // + // Filters is a required field + Filters []*GuardrailContextualGroundingFilter `locationName:"filters" min:"1" type:"list" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicy) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicy) GoString() string { + return s.String() +} + +// SetFilters sets the Filters field's value. +func (s *GuardrailContextualGroundingPolicy) SetFilters(v []*GuardrailContextualGroundingFilter) *GuardrailContextualGroundingPolicy { + s.Filters = v + return s +} + +// The policy configuration details for the guardrails contextual grounding +// policy. +type GuardrailContextualGroundingPolicyConfig struct { + _ struct{} `type:"structure"` + + // The filter configuration details for the guardrails contextual grounding + // policy. + // + // FiltersConfig is a required field + FiltersConfig []*GuardrailContextualGroundingFilterConfig `locationName:"filtersConfig" min:"1" type:"list" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicyConfig) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicyConfig) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GuardrailContextualGroundingPolicyConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GuardrailContextualGroundingPolicyConfig"} + if s.FiltersConfig == nil { + invalidParams.Add(request.NewErrParamRequired("FiltersConfig")) + } + if s.FiltersConfig != nil && len(s.FiltersConfig) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FiltersConfig", 1)) + } + if s.FiltersConfig != nil { + for i, v := range s.FiltersConfig { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "FiltersConfig", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFiltersConfig sets the FiltersConfig field's value. +func (s *GuardrailContextualGroundingPolicyConfig) SetFiltersConfig(v []*GuardrailContextualGroundingFilterConfig) *GuardrailContextualGroundingPolicyConfig { + s.FiltersConfig = v + return s +} + // The managed word list that was configured for the guardrail. (This is a list -// of words that are pre-defined and managed by Guardrails only.) +// of words that are pre-defined and managed by guardrails only.) type GuardrailManagedWords struct { _ struct{} `type:"structure"` @@ -7622,6 +7832,100 @@ type GuardrailPiiEntityConfig struct { // Configure guardrail type when the PII entity is detected. // + // The following PIIs are used to block or mask sensitive information: + // + // * General ADDRESS A physical address, such as "100 Main Street, Anytown, + // USA" or "Suite #12, Building 123". An address can include information + // such as the street, building, location, city, state, country, county, + // zip code, precinct, and neighborhood. AGE An individual's age, including + // the quantity and unit of time. For example, in the phrase "I am 40 years + // old," Guarrails recognizes "40 years" as an age. NAME An individual's + // name. This entity type does not include titles, such as Dr., Mr., Mrs., + // or Miss. guardrails doesn't apply this entity type to names that are part + // of organizations or addresses. For example, guardrails recognizes the + // "John Doe Organization" as an organization, and it recognizes "Jane Doe + // Street" as an address. EMAIL An email address, such as marymajor@email.com. + // PHONE A phone number. This entity type also includes fax and pager numbers. + // USERNAME A user name that identifies an account, such as a login name, + // screen name, nick name, or handle. PASSWORD An alphanumeric string that + // is used as a password, such as "*very20special#pass*". DRIVER_ID The number + // assigned to a driver's license, which is an official document permitting + // an individual to operate one or more motorized vehicles on a public road. + // A driver's license number consists of alphanumeric characters. LICENSE_PLATE + // A license plate for a vehicle is issued by the state or country where + // the vehicle is registered. The format for passenger vehicles is typically + // five to eight digits, consisting of upper-case letters and numbers. The + // format varies depending on the location of the issuing state or country. + // VEHICLE_IDENTIFICATION_NUMBER A Vehicle Identification Number (VIN) uniquely + // identifies a vehicle. VIN content and format are defined in the ISO 3779 + // specification. Each country has specific codes and formats for VINs. + // + // * Finance REDIT_DEBIT_CARD_CVV A three-digit card verification code (CVV) + // that is present on VISA, MasterCard, and Discover credit and debit cards. + // For American Express credit or debit cards, the CVV is a four-digit numeric + // code. CREDIT_DEBIT_CARD_EXPIRY The expiration date for a credit or debit + // card. This number is usually four digits long and is often formatted as + // month/year or MM/YY. Guardrails recognizes expiration dates such as 01/21, + // 01/2021, and Jan 2021. CREDIT_DEBIT_CARD_NUMBER The number for a credit + // or debit card. These numbers can vary from 13 to 16 digits in length. + // However, Amazon Comprehend also recognizes credit or debit card numbers + // when only the last four digits are present. PIN A four-digit personal + // identification number (PIN) with which you can access your bank account. + // INTERNATIONAL_BANK_ACCOUNT_NUMBER An International Bank Account Number + // has specific formats in each country. For more information, see www.iban.com/structure + // (https://www.iban.com/structure). SWIFT_CODE A SWIFT code is a standard + // format of Bank Identifier Code (BIC) used to specify a particular bank + // or branch. Banks use these codes for money transfers such as international + // wire transfers. SWIFT codes consist of eight or 11 characters. The 11-digit + // codes refer to specific branches, while eight-digit codes (or 11-digit + // codes ending in 'XXX') refer to the head or primary office. + // + // * IT IP_ADDRESS An IPv4 address, such as 198.51.100.0. MAC_ADDRESS A media + // access control (MAC) address is a unique identifier assigned to a network + // interface controller (NIC). URL A web address, such as www.example.com. + // AWS_ACCESS_KEY A unique identifier that's associated with a secret access + // key; you use the access key ID and secret access key to sign programmatic + // Amazon Web Services requests cryptographically. AWS_SECRET_KEY A unique + // identifier that's associated with an access key. You use the access key + // ID and secret access key to sign programmatic Amazon Web Services requests + // cryptographically. + // + // * USA specific US_BANK_ACCOUNT_NUMBER A US bank account number, which + // is typically 10 to 12 digits long. US_BANK_ROUTING_NUMBER A US bank account + // routing number. These are typically nine digits long, US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER + // A US Individual Taxpayer Identification Number (ITIN) is a nine-digit + // number that starts with a "9" and contain a "7" or "8" as the fourth digit. + // An ITIN can be formatted with a space or a dash after the third and forth + // digits. US_PASSPORT_NUMBER A US passport number. Passport numbers range + // from six to nine alphanumeric characters. US_SOCIAL_SECURITY_NUMBER A + // US Social Security Number (SSN) is a nine-digit number that is issued + // to US citizens, permanent residents, and temporary working residents. + // + // * Canada specific CA_HEALTH_NUMBER A Canadian Health Service Number is + // a 10-digit unique identifier, required for individuals to access healthcare + // benefits. CA_SOCIAL_INSURANCE_NUMBER A Canadian Social Insurance Number + // (SIN) is a nine-digit unique identifier, required for individuals to access + // government programs and benefits. The SIN is formatted as three groups + // of three digits, such as 123-456-789. A SIN can be validated through a + // simple check-digit process called the Luhn algorithm (https://www.wikipedia.org/wiki/Luhn_algorithm). + // + // * UK Specific UK_NATIONAL_HEALTH_SERVICE_NUMBER A UK National Health Service + // Number is a 10-17 digit number, such as 485 777 3456. The current system + // formats the 10-digit number with spaces after the third and sixth digits. + // The final digit is an error-detecting checksum. UK_NATIONAL_INSURANCE_NUMBER + // A UK National Insurance Number (NINO) provides individuals with access + // to National Insurance (social security) benefits. It is also used for + // some purposes in the UK tax system. The number is nine digits long and + // starts with two letters, followed by six numbers and one letter. A NINO + // can be formatted with a space or a dash after the two letters and after + // the second, forth, and sixth digits. UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER + // A UK Unique Taxpayer Reference (UTR) is a 10-digit number that identifies + // a taxpayer or a business. + // + // * Custom Regex filter - You can use a regular expressions to define patterns + // for a guardrail to recognize and act upon such as serial number, booking + // ID etc.. + // // Type is a required field Type *string `locationName:"type" type:"string" required:"true" enum:"GuardrailPiiEntityType"` } @@ -8148,12 +8452,6 @@ func (s *GuardrailTopic) SetType(v string) *GuardrailTopic { } // Details about topics for the guardrail to identify and deny. -// -// This data type is used in the following API operations: -// -// - CreateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateGuardrail.html#API_CreateGuardrail_RequestSyntax) -// -// - UpdateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_UpdateGuardrail.html#API_UpdateGuardrail_RequestSyntax) type GuardrailTopicConfig struct { _ struct{} `type:"structure"` @@ -8291,12 +8589,6 @@ func (s *GuardrailTopicPolicy) SetTopics(v []*GuardrailTopic) *GuardrailTopicPol } // Contains details about topics that the guardrail should identify and deny. -// -// This data type is used in the following API operations: -// -// - CreateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateGuardrail.html#API_CreateGuardrail_RequestSyntax) -// -// - UpdateGuardrail request body (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_UpdateGuardrail.html#API_UpdateGuardrail_RequestSyntax) type GuardrailTopicPolicyConfig struct { _ struct{} `type:"structure"` @@ -9304,7 +9596,7 @@ func (s *ListFoundationModelsOutput) SetModelSummaries(v []*FoundationModelSumma type ListGuardrailsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the guardrail. + // The unique identifier of the guardrail. This can be an ID or the ARN. GuardrailIdentifier *string `location:"querystring" locationName:"guardrailIdentifier" type:"string"` // The maximum number of results to return in the response. @@ -11137,6 +11429,9 @@ type UpdateGuardrailInput struct { // The content policy to configure for the guardrail. ContentPolicyConfig *GuardrailContentPolicyConfig `locationName:"contentPolicyConfig" type:"structure"` + // The contextual grounding policy configuration used to update a guardrail. + ContextualGroundingPolicyConfig *GuardrailContextualGroundingPolicyConfig `locationName:"contextualGroundingPolicyConfig" type:"structure"` + // A description of the guardrail. // // Description is a sensitive parameter and its value will be @@ -11144,7 +11439,7 @@ type UpdateGuardrailInput struct { // String and GoString methods. Description *string `locationName:"description" min:"1" type:"string" sensitive:"true"` - // The unique identifier of the guardrail + // The unique identifier of the guardrail. This can be an ID or the ARN. // // GuardrailIdentifier is a required field GuardrailIdentifier *string `location:"uri" locationName:"guardrailIdentifier" type:"string" required:"true"` @@ -11227,6 +11522,11 @@ func (s *UpdateGuardrailInput) Validate() error { invalidParams.AddNested("ContentPolicyConfig", err.(request.ErrInvalidParams)) } } + if s.ContextualGroundingPolicyConfig != nil { + if err := s.ContextualGroundingPolicyConfig.Validate(); err != nil { + invalidParams.AddNested("ContextualGroundingPolicyConfig", err.(request.ErrInvalidParams)) + } + } if s.SensitiveInformationPolicyConfig != nil { if err := s.SensitiveInformationPolicyConfig.Validate(); err != nil { invalidParams.AddNested("SensitiveInformationPolicyConfig", err.(request.ErrInvalidParams)) @@ -11267,6 +11567,12 @@ func (s *UpdateGuardrailInput) SetContentPolicyConfig(v *GuardrailContentPolicyC return s } +// SetContextualGroundingPolicyConfig sets the ContextualGroundingPolicyConfig field's value. +func (s *UpdateGuardrailInput) SetContextualGroundingPolicyConfig(v *GuardrailContextualGroundingPolicyConfig) *UpdateGuardrailInput { + s.ContextualGroundingPolicyConfig = v + return s +} + // SetDescription sets the Description field's value. func (s *UpdateGuardrailInput) SetDescription(v string) *UpdateGuardrailInput { s.Description = &v @@ -11312,7 +11618,7 @@ func (s *UpdateGuardrailInput) SetWordPolicyConfig(v *GuardrailWordPolicyConfig) type UpdateGuardrailOutput struct { _ struct{} `type:"structure"` - // The ARN of the guardrail that was created. + // The ARN of the guardrail. // // GuardrailArn is a required field GuardrailArn *string `locationName:"guardrailArn" type:"string" required:"true"` @@ -11930,6 +12236,22 @@ func GuardrailContentFilterType_Values() []string { } } +const ( + // GuardrailContextualGroundingFilterTypeGrounding is a GuardrailContextualGroundingFilterType enum value + GuardrailContextualGroundingFilterTypeGrounding = "GROUNDING" + + // GuardrailContextualGroundingFilterTypeRelevance is a GuardrailContextualGroundingFilterType enum value + GuardrailContextualGroundingFilterTypeRelevance = "RELEVANCE" +) + +// GuardrailContextualGroundingFilterType_Values returns all elements of the GuardrailContextualGroundingFilterType enum +func GuardrailContextualGroundingFilterType_Values() []string { + return []string{ + GuardrailContextualGroundingFilterTypeGrounding, + GuardrailContextualGroundingFilterTypeRelevance, + } +} + const ( // GuardrailFilterStrengthNone is a GuardrailFilterStrength enum value GuardrailFilterStrengthNone = "NONE" diff --git a/service/bedrockagent/api.go b/service/bedrockagent/api.go index d1b808dc92f..d1b89477f9e 100644 --- a/service/bedrockagent/api.go +++ b/service/bedrockagent/api.go @@ -168,6 +168,10 @@ func (c *BedrockAgent) CreateAgentRequest(input *CreateAgentInput) (req *request // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-configure-memory.html). +// // - To override the default prompt behavior for agent orchestration and // to use advanced prompts, include a promptOverrideConfiguration object. // For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). @@ -273,11 +277,17 @@ func (c *BedrockAgent) CreateAgentActionGroupRequest(input *CreateAgentActionGro // // 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. 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) +// 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) // reprompting the user for more information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -474,9 +484,10 @@ func (c *BedrockAgent) CreateDataSourceRequest(input *CreateDataSourceInput) (re // CreateDataSource API operation for Agents for Amazon Bedrock. // -// Sets up a data source to be added to a knowledge base. +// Creates a data source connector for a knowledge base. // -// You can't change the chunkingConfiguration after you create the data source. +// You can't change the chunkingConfiguration after you create the data source +// connector. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -531,84 +542,62 @@ func (c *BedrockAgent) CreateDataSourceWithContext(ctx aws.Context, input *Creat return out, req.Send() } -const opCreateKnowledgeBase = "CreateKnowledgeBase" +const opCreateFlow = "CreateFlow" -// CreateKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the CreateKnowledgeBase operation. The "output" return +// CreateFlowRequest generates a "aws/request.Request" representing the +// client's request for the CreateFlow operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See CreateKnowledgeBase for more information on using the CreateKnowledgeBase +// See CreateFlow for more information on using the CreateFlow // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the CreateKnowledgeBaseRequest method. -// req, resp := client.CreateKnowledgeBaseRequest(params) +// // Example sending a request using the CreateFlowRequest method. +// req, resp := client.CreateFlowRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateKnowledgeBase -func (c *BedrockAgent) CreateKnowledgeBaseRequest(input *CreateKnowledgeBaseInput) (req *request.Request, output *CreateKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlow +func (c *BedrockAgent) CreateFlowRequest(input *CreateFlowInput) (req *request.Request, output *CreateFlowOutput) { op := &request.Operation{ - Name: opCreateKnowledgeBase, - HTTPMethod: "PUT", - HTTPPath: "/knowledgebases/", + Name: opCreateFlow, + HTTPMethod: "POST", + HTTPPath: "/flows/", } if input == nil { - input = &CreateKnowledgeBaseInput{} + input = &CreateFlowInput{} } - output = &CreateKnowledgeBaseOutput{} + output = &CreateFlowOutput{} req = c.newRequest(op, input, output) return } -// CreateKnowledgeBase API operation for Agents for Amazon Bedrock. -// -// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup.html). -// -// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-create). -// -// - Provide the name and an optional description. -// -// - Provide the Amazon Resource Name (ARN) with permissions to create a -// knowledge base in the roleArn field. +// CreateFlow API operation for Agents for Amazon Bedrock. // -// - 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. For an Amazon OpenSearch Service database, use the opensearchServerlessConfiguration -// object. For more information, see Create a vector store in Amazon OpenSearch -// Service (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). -// For an Amazon Aurora database, use the RdsConfiguration object. For more -// information, see Create a vector store in Amazon Aurora (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). -// For a Pinecone database, use the pineconeConfiguration object. For more -// information, see Create a vector store in Pinecone (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-pinecone.html). -// For a Redis Enterprise Cloud database, use the redisEnterpriseCloudConfiguration -// object. For more information, see Create a vector store in Redis Enterprise -// Cloud (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-redis.html). +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-how-it-works.html) +// and Create a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-create.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation CreateKnowledgeBase for usage and error information. +// API operation CreateFlow for usage and error information. // // Returned Error Types: // @@ -630,79 +619,81 @@ func (c *BedrockAgent) CreateKnowledgeBaseRequest(input *CreateKnowledgeBaseInpu // - ServiceQuotaExceededException // The number of requests exceeds the service quota. Resubmit your request later. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateKnowledgeBase -func (c *BedrockAgent) CreateKnowledgeBase(input *CreateKnowledgeBaseInput) (*CreateKnowledgeBaseOutput, error) { - req, out := c.CreateKnowledgeBaseRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlow +func (c *BedrockAgent) CreateFlow(input *CreateFlowInput) (*CreateFlowOutput, error) { + req, out := c.CreateFlowRequest(input) return out, req.Send() } -// CreateKnowledgeBaseWithContext is the same as CreateKnowledgeBase with the addition of +// CreateFlowWithContext is the same as CreateFlow with the addition of // the ability to pass a context and additional request options. // -// See CreateKnowledgeBase for details on how to use this API operation. +// See CreateFlow for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) CreateKnowledgeBaseWithContext(ctx aws.Context, input *CreateKnowledgeBaseInput, opts ...request.Option) (*CreateKnowledgeBaseOutput, error) { - req, out := c.CreateKnowledgeBaseRequest(input) +func (c *BedrockAgent) CreateFlowWithContext(ctx aws.Context, input *CreateFlowInput, opts ...request.Option) (*CreateFlowOutput, error) { + req, out := c.CreateFlowRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteAgent = "DeleteAgent" +const opCreateFlowAlias = "CreateFlowAlias" -// DeleteAgentRequest generates a "aws/request.Request" representing the -// client's request for the DeleteAgent operation. The "output" return +// CreateFlowAliasRequest generates a "aws/request.Request" representing the +// client's request for the CreateFlowAlias operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteAgent for more information on using the DeleteAgent +// See CreateFlowAlias for more information on using the CreateFlowAlias // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteAgentRequest method. -// req, resp := client.DeleteAgentRequest(params) +// // Example sending a request using the CreateFlowAliasRequest method. +// req, resp := client.CreateFlowAliasRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgent -func (c *BedrockAgent) DeleteAgentRequest(input *DeleteAgentInput) (req *request.Request, output *DeleteAgentOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlowAlias +func (c *BedrockAgent) CreateFlowAliasRequest(input *CreateFlowAliasInput) (req *request.Request, output *CreateFlowAliasOutput) { op := &request.Operation{ - Name: opDeleteAgent, - HTTPMethod: "DELETE", - HTTPPath: "/agents/{agentId}/", + Name: opCreateFlowAlias, + HTTPMethod: "POST", + HTTPPath: "/flows/{flowIdentifier}/aliases", } if input == nil { - input = &DeleteAgentInput{} + input = &CreateFlowAliasInput{} } - output = &DeleteAgentOutput{} + output = &CreateFlowAliasOutput{} req = c.newRequest(op, input, output) return } -// DeleteAgent API operation for Agents for Amazon Bedrock. +// CreateFlowAlias API operation for Agents for Amazon Bedrock. // -// Deletes an agent. +// Creates an alias of a flow for deployment. For more information, see Deploy +// a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteAgent for usage and error information. +// API operation CreateFlowAlias for usage and error information. // // Returned Error Types: // @@ -725,80 +716,84 @@ func (c *BedrockAgent) DeleteAgentRequest(input *DeleteAgentInput) (req *request // - ConflictException // There was a conflict performing an operation. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgent -func (c *BedrockAgent) DeleteAgent(input *DeleteAgentInput) (*DeleteAgentOutput, error) { - req, out := c.DeleteAgentRequest(input) +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlowAlias +func (c *BedrockAgent) CreateFlowAlias(input *CreateFlowAliasInput) (*CreateFlowAliasOutput, error) { + req, out := c.CreateFlowAliasRequest(input) return out, req.Send() } -// DeleteAgentWithContext is the same as DeleteAgent with the addition of +// CreateFlowAliasWithContext is the same as CreateFlowAlias with the addition of // the ability to pass a context and additional request options. // -// See DeleteAgent for details on how to use this API operation. +// See CreateFlowAlias for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteAgentWithContext(ctx aws.Context, input *DeleteAgentInput, opts ...request.Option) (*DeleteAgentOutput, error) { - req, out := c.DeleteAgentRequest(input) +func (c *BedrockAgent) CreateFlowAliasWithContext(ctx aws.Context, input *CreateFlowAliasInput, opts ...request.Option) (*CreateFlowAliasOutput, error) { + req, out := c.CreateFlowAliasRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteAgentActionGroup = "DeleteAgentActionGroup" +const opCreateFlowVersion = "CreateFlowVersion" -// DeleteAgentActionGroupRequest generates a "aws/request.Request" representing the -// client's request for the DeleteAgentActionGroup operation. The "output" return +// CreateFlowVersionRequest generates a "aws/request.Request" representing the +// client's request for the CreateFlowVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteAgentActionGroup for more information on using the DeleteAgentActionGroup +// See CreateFlowVersion for more information on using the CreateFlowVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteAgentActionGroupRequest method. -// req, resp := client.DeleteAgentActionGroupRequest(params) +// // Example sending a request using the CreateFlowVersionRequest method. +// req, resp := client.CreateFlowVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentActionGroup -func (c *BedrockAgent) DeleteAgentActionGroupRequest(input *DeleteAgentActionGroupInput) (req *request.Request, output *DeleteAgentActionGroupOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlowVersion +func (c *BedrockAgent) CreateFlowVersionRequest(input *CreateFlowVersionInput) (req *request.Request, output *CreateFlowVersionOutput) { op := &request.Operation{ - Name: opDeleteAgentActionGroup, - HTTPMethod: "DELETE", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", + Name: opCreateFlowVersion, + HTTPMethod: "POST", + HTTPPath: "/flows/{flowIdentifier}/versions", } if input == nil { - input = &DeleteAgentActionGroupInput{} + input = &CreateFlowVersionInput{} } - output = &DeleteAgentActionGroupOutput{} + output = &CreateFlowVersionOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// DeleteAgentActionGroup API operation for Agents for Amazon Bedrock. +// CreateFlowVersion API operation for Agents for Amazon Bedrock. // -// Deletes an action group in an agent. +// Creates a version of the flow that you can deploy. For more information, +// see Deploy a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteAgentActionGroup for usage and error information. +// API operation CreateFlowVersion for usage and error information. // // Returned Error Types: // @@ -821,79 +816,109 @@ func (c *BedrockAgent) DeleteAgentActionGroupRequest(input *DeleteAgentActionGro // - ConflictException // There was a conflict performing an operation. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentActionGroup -func (c *BedrockAgent) DeleteAgentActionGroup(input *DeleteAgentActionGroupInput) (*DeleteAgentActionGroupOutput, error) { - req, out := c.DeleteAgentActionGroupRequest(input) +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateFlowVersion +func (c *BedrockAgent) CreateFlowVersion(input *CreateFlowVersionInput) (*CreateFlowVersionOutput, error) { + req, out := c.CreateFlowVersionRequest(input) return out, req.Send() } -// DeleteAgentActionGroupWithContext is the same as DeleteAgentActionGroup with the addition of +// CreateFlowVersionWithContext is the same as CreateFlowVersion with the addition of // the ability to pass a context and additional request options. // -// See DeleteAgentActionGroup for details on how to use this API operation. +// See CreateFlowVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteAgentActionGroupWithContext(ctx aws.Context, input *DeleteAgentActionGroupInput, opts ...request.Option) (*DeleteAgentActionGroupOutput, error) { - req, out := c.DeleteAgentActionGroupRequest(input) +func (c *BedrockAgent) CreateFlowVersionWithContext(ctx aws.Context, input *CreateFlowVersionInput, opts ...request.Option) (*CreateFlowVersionOutput, error) { + req, out := c.CreateFlowVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteAgentAlias = "DeleteAgentAlias" +const opCreateKnowledgeBase = "CreateKnowledgeBase" -// DeleteAgentAliasRequest generates a "aws/request.Request" representing the -// client's request for the DeleteAgentAlias operation. The "output" return +// CreateKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the CreateKnowledgeBase operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteAgentAlias for more information on using the DeleteAgentAlias +// See CreateKnowledgeBase for more information on using the CreateKnowledgeBase // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteAgentAliasRequest method. -// req, resp := client.DeleteAgentAliasRequest(params) +// // Example sending a request using the CreateKnowledgeBaseRequest method. +// req, resp := client.CreateKnowledgeBaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentAlias -func (c *BedrockAgent) DeleteAgentAliasRequest(input *DeleteAgentAliasInput) (req *request.Request, output *DeleteAgentAliasOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateKnowledgeBase +func (c *BedrockAgent) CreateKnowledgeBaseRequest(input *CreateKnowledgeBaseInput) (req *request.Request, output *CreateKnowledgeBaseOutput) { op := &request.Operation{ - Name: opDeleteAgentAlias, - HTTPMethod: "DELETE", - HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", + Name: opCreateKnowledgeBase, + HTTPMethod: "PUT", + HTTPPath: "/knowledgebases/", } if input == nil { - input = &DeleteAgentAliasInput{} + input = &CreateKnowledgeBaseInput{} } - output = &DeleteAgentAliasOutput{} + output = &CreateKnowledgeBaseOutput{} req = c.newRequest(op, input, output) return } -// DeleteAgentAlias API operation for Agents for Amazon Bedrock. +// CreateKnowledgeBase API operation for Agents for Amazon Bedrock. // -// Deletes an alias of an agent. +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup.html). +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-create). +// +// - 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. For an Amazon OpenSearch Service database, use the opensearchServerlessConfiguration +// object. For more information, see Create a vector store in Amazon OpenSearch +// Service (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). +// For an Amazon Aurora database, use the RdsConfiguration object. For more +// information, see Create a vector store in Amazon Aurora (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). +// For a Pinecone database, use the pineconeConfiguration object. For more +// information, see Create a vector store in Pinecone (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-pinecone.html). +// For a Redis Enterprise Cloud database, use the redisEnterpriseCloudConfiguration +// object. For more information, see Create a vector store in Redis Enterprise +// Cloud (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-redis.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteAgentAlias for usage and error information. +// API operation CreateKnowledgeBase for usage and error information. // // Returned Error Types: // @@ -909,83 +934,89 @@ func (c *BedrockAgent) DeleteAgentAliasRequest(input *DeleteAgentAliasInput) (re // - 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. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentAlias -func (c *BedrockAgent) DeleteAgentAlias(input *DeleteAgentAliasInput) (*DeleteAgentAliasOutput, error) { - req, out := c.DeleteAgentAliasRequest(input) +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateKnowledgeBase +func (c *BedrockAgent) CreateKnowledgeBase(input *CreateKnowledgeBaseInput) (*CreateKnowledgeBaseOutput, error) { + req, out := c.CreateKnowledgeBaseRequest(input) return out, req.Send() } -// DeleteAgentAliasWithContext is the same as DeleteAgentAlias with the addition of +// CreateKnowledgeBaseWithContext is the same as CreateKnowledgeBase with the addition of // the ability to pass a context and additional request options. // -// See DeleteAgentAlias for details on how to use this API operation. +// See CreateKnowledgeBase for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteAgentAliasWithContext(ctx aws.Context, input *DeleteAgentAliasInput, opts ...request.Option) (*DeleteAgentAliasOutput, error) { - req, out := c.DeleteAgentAliasRequest(input) +func (c *BedrockAgent) CreateKnowledgeBaseWithContext(ctx aws.Context, input *CreateKnowledgeBaseInput, opts ...request.Option) (*CreateKnowledgeBaseOutput, error) { + req, out := c.CreateKnowledgeBaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteAgentVersion = "DeleteAgentVersion" +const opCreatePrompt = "CreatePrompt" -// DeleteAgentVersionRequest generates a "aws/request.Request" representing the -// client's request for the DeleteAgentVersion operation. The "output" return +// CreatePromptRequest generates a "aws/request.Request" representing the +// client's request for the CreatePrompt operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteAgentVersion for more information on using the DeleteAgentVersion +// See CreatePrompt for more information on using the CreatePrompt // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteAgentVersionRequest method. -// req, resp := client.DeleteAgentVersionRequest(params) +// // Example sending a request using the CreatePromptRequest method. +// req, resp := client.CreatePromptRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentVersion -func (c *BedrockAgent) DeleteAgentVersionRequest(input *DeleteAgentVersionInput) (req *request.Request, output *DeleteAgentVersionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreatePrompt +func (c *BedrockAgent) CreatePromptRequest(input *CreatePromptInput) (req *request.Request, output *CreatePromptOutput) { op := &request.Operation{ - Name: opDeleteAgentVersion, - HTTPMethod: "DELETE", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/", + Name: opCreatePrompt, + HTTPMethod: "POST", + HTTPPath: "/prompts/", } if input == nil { - input = &DeleteAgentVersionInput{} + input = &CreatePromptInput{} } - output = &DeleteAgentVersionOutput{} + output = &CreatePromptOutput{} req = c.newRequest(op, input, output) return } -// DeleteAgentVersion API operation for Agents for Amazon Bedrock. +// CreatePrompt API operation for Agents for Amazon Bedrock. // -// Deletes a version of an agent. +// Creates a prompt in your prompt library that you can add to a flow. For more +// information, see Prompt management in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management.html), +// Create a prompt using Prompt management (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-create.html) +// and Prompt flows in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteAgentVersion for usage and error information. +// API operation CreatePrompt for usage and error information. // // Returned Error Types: // @@ -1001,86 +1032,88 @@ func (c *BedrockAgent) DeleteAgentVersionRequest(input *DeleteAgentVersionInput) // - 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. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentVersion -func (c *BedrockAgent) DeleteAgentVersion(input *DeleteAgentVersionInput) (*DeleteAgentVersionOutput, error) { - req, out := c.DeleteAgentVersionRequest(input) +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreatePrompt +func (c *BedrockAgent) CreatePrompt(input *CreatePromptInput) (*CreatePromptOutput, error) { + req, out := c.CreatePromptRequest(input) return out, req.Send() } -// DeleteAgentVersionWithContext is the same as DeleteAgentVersion with the addition of +// CreatePromptWithContext is the same as CreatePrompt with the addition of // the ability to pass a context and additional request options. // -// See DeleteAgentVersion for details on how to use this API operation. +// See CreatePrompt for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteAgentVersionWithContext(ctx aws.Context, input *DeleteAgentVersionInput, opts ...request.Option) (*DeleteAgentVersionOutput, error) { - req, out := c.DeleteAgentVersionRequest(input) +func (c *BedrockAgent) CreatePromptWithContext(ctx aws.Context, input *CreatePromptInput, opts ...request.Option) (*CreatePromptOutput, error) { + req, out := c.CreatePromptRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteDataSource = "DeleteDataSource" +const opCreatePromptVersion = "CreatePromptVersion" -// DeleteDataSourceRequest generates a "aws/request.Request" representing the -// client's request for the DeleteDataSource operation. The "output" return +// CreatePromptVersionRequest generates a "aws/request.Request" representing the +// client's request for the CreatePromptVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteDataSource for more information on using the DeleteDataSource +// See CreatePromptVersion for more information on using the CreatePromptVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteDataSourceRequest method. -// req, resp := client.DeleteDataSourceRequest(params) +// // Example sending a request using the CreatePromptVersionRequest method. +// req, resp := client.CreatePromptVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteDataSource -func (c *BedrockAgent) DeleteDataSourceRequest(input *DeleteDataSourceInput) (req *request.Request, output *DeleteDataSourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreatePromptVersion +func (c *BedrockAgent) CreatePromptVersionRequest(input *CreatePromptVersionInput) (req *request.Request, output *CreatePromptVersionOutput) { op := &request.Operation{ - Name: opDeleteDataSource, - HTTPMethod: "DELETE", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", + Name: opCreatePromptVersion, + HTTPMethod: "POST", + HTTPPath: "/prompts/{promptIdentifier}/versions", } if input == nil { - input = &DeleteDataSourceInput{} + input = &CreatePromptVersionInput{} } - output = &DeleteDataSourceOutput{} + output = &CreatePromptVersionOutput{} req = c.newRequest(op, input, output) return } -// DeleteDataSource API operation for Agents for Amazon Bedrock. +// CreatePromptVersion API operation for Agents for Amazon Bedrock. // -// Deletes a data source from a knowledge base. +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-deploy.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteDataSource for usage and error information. +// API operation CreatePromptVersion for usage and error information. // // Returned Error Types: // @@ -1103,82 +1136,82 @@ func (c *BedrockAgent) DeleteDataSourceRequest(input *DeleteDataSourceInput) (re // - ConflictException // There was a conflict performing an operation. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteDataSource -func (c *BedrockAgent) DeleteDataSource(input *DeleteDataSourceInput) (*DeleteDataSourceOutput, error) { - req, out := c.DeleteDataSourceRequest(input) +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreatePromptVersion +func (c *BedrockAgent) CreatePromptVersion(input *CreatePromptVersionInput) (*CreatePromptVersionOutput, error) { + req, out := c.CreatePromptVersionRequest(input) return out, req.Send() } -// DeleteDataSourceWithContext is the same as DeleteDataSource with the addition of +// CreatePromptVersionWithContext is the same as CreatePromptVersion with the addition of // the ability to pass a context and additional request options. // -// See DeleteDataSource for details on how to use this API operation. +// See CreatePromptVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteDataSourceWithContext(ctx aws.Context, input *DeleteDataSourceInput, opts ...request.Option) (*DeleteDataSourceOutput, error) { - req, out := c.DeleteDataSourceRequest(input) +func (c *BedrockAgent) CreatePromptVersionWithContext(ctx aws.Context, input *CreatePromptVersionInput, opts ...request.Option) (*CreatePromptVersionOutput, error) { + req, out := c.CreatePromptVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteKnowledgeBase = "DeleteKnowledgeBase" +const opDeleteAgent = "DeleteAgent" -// DeleteKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the DeleteKnowledgeBase operation. The "output" return +// DeleteAgentRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAgent operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteKnowledgeBase for more information on using the DeleteKnowledgeBase +// See DeleteAgent for more information on using the DeleteAgent // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DeleteKnowledgeBaseRequest method. -// req, resp := client.DeleteKnowledgeBaseRequest(params) +// // Example sending a request using the DeleteAgentRequest method. +// req, resp := client.DeleteAgentRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteKnowledgeBase -func (c *BedrockAgent) DeleteKnowledgeBaseRequest(input *DeleteKnowledgeBaseInput) (req *request.Request, output *DeleteKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgent +func (c *BedrockAgent) DeleteAgentRequest(input *DeleteAgentInput) (req *request.Request, output *DeleteAgentOutput) { op := &request.Operation{ - Name: opDeleteKnowledgeBase, + Name: opDeleteAgent, HTTPMethod: "DELETE", - HTTPPath: "/knowledgebases/{knowledgeBaseId}", + HTTPPath: "/agents/{agentId}/", } if input == nil { - input = &DeleteKnowledgeBaseInput{} + input = &DeleteAgentInput{} } - output = &DeleteKnowledgeBaseOutput{} + output = &DeleteAgentOutput{} req = c.newRequest(op, input, output) return } -// DeleteKnowledgeBase API operation for Agents for Amazon Bedrock. +// DeleteAgent API operation for Agents for Amazon Bedrock. // -// 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_DisassociateAgentKnowledgeBase.html) -// request. +// Deletes an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DeleteKnowledgeBase for usage and error information. +// API operation DeleteAgent for usage and error information. // // Returned Error Types: // @@ -1201,80 +1234,80 @@ func (c *BedrockAgent) DeleteKnowledgeBaseRequest(input *DeleteKnowledgeBaseInpu // - ConflictException // There was a conflict performing an operation. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteKnowledgeBase -func (c *BedrockAgent) DeleteKnowledgeBase(input *DeleteKnowledgeBaseInput) (*DeleteKnowledgeBaseOutput, error) { - req, out := c.DeleteKnowledgeBaseRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgent +func (c *BedrockAgent) DeleteAgent(input *DeleteAgentInput) (*DeleteAgentOutput, error) { + req, out := c.DeleteAgentRequest(input) return out, req.Send() } -// DeleteKnowledgeBaseWithContext is the same as DeleteKnowledgeBase with the addition of +// DeleteAgentWithContext is the same as DeleteAgent with the addition of // the ability to pass a context and additional request options. // -// See DeleteKnowledgeBase for details on how to use this API operation. +// See DeleteAgent for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DeleteKnowledgeBaseWithContext(ctx aws.Context, input *DeleteKnowledgeBaseInput, opts ...request.Option) (*DeleteKnowledgeBaseOutput, error) { - req, out := c.DeleteKnowledgeBaseRequest(input) +func (c *BedrockAgent) DeleteAgentWithContext(ctx aws.Context, input *DeleteAgentInput, opts ...request.Option) (*DeleteAgentOutput, error) { + req, out := c.DeleteAgentRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDisassociateAgentKnowledgeBase = "DisassociateAgentKnowledgeBase" +const opDeleteAgentActionGroup = "DeleteAgentActionGroup" -// DisassociateAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the DisassociateAgentKnowledgeBase operation. The "output" return +// DeleteAgentActionGroupRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAgentActionGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DisassociateAgentKnowledgeBase for more information on using the DisassociateAgentKnowledgeBase +// See DeleteAgentActionGroup for more information on using the DeleteAgentActionGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the DisassociateAgentKnowledgeBaseRequest method. -// req, resp := client.DisassociateAgentKnowledgeBaseRequest(params) +// // Example sending a request using the DeleteAgentActionGroupRequest method. +// req, resp := client.DeleteAgentActionGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DisassociateAgentKnowledgeBase -func (c *BedrockAgent) DisassociateAgentKnowledgeBaseRequest(input *DisassociateAgentKnowledgeBaseInput) (req *request.Request, output *DisassociateAgentKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentActionGroup +func (c *BedrockAgent) DeleteAgentActionGroupRequest(input *DeleteAgentActionGroupInput) (req *request.Request, output *DeleteAgentActionGroupOutput) { op := &request.Operation{ - Name: opDisassociateAgentKnowledgeBase, + Name: opDeleteAgentActionGroup, HTTPMethod: "DELETE", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", } if input == nil { - input = &DisassociateAgentKnowledgeBaseInput{} + input = &DeleteAgentActionGroupInput{} } - output = &DisassociateAgentKnowledgeBaseOutput{} + output = &DeleteAgentActionGroupOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// DisassociateAgentKnowledgeBase API operation for Agents for Amazon Bedrock. +// DeleteAgentActionGroup API operation for Agents for Amazon Bedrock. // -// Disassociates a knowledge base from an agent. +// Deletes an action group in an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation DisassociateAgentKnowledgeBase for usage and error information. +// API operation DeleteAgentActionGroup for usage and error information. // // Returned Error Types: // @@ -1297,79 +1330,79 @@ func (c *BedrockAgent) DisassociateAgentKnowledgeBaseRequest(input *Disassociate // - ConflictException // There was a conflict performing an operation. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DisassociateAgentKnowledgeBase -func (c *BedrockAgent) DisassociateAgentKnowledgeBase(input *DisassociateAgentKnowledgeBaseInput) (*DisassociateAgentKnowledgeBaseOutput, error) { - req, out := c.DisassociateAgentKnowledgeBaseRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentActionGroup +func (c *BedrockAgent) DeleteAgentActionGroup(input *DeleteAgentActionGroupInput) (*DeleteAgentActionGroupOutput, error) { + req, out := c.DeleteAgentActionGroupRequest(input) return out, req.Send() } -// DisassociateAgentKnowledgeBaseWithContext is the same as DisassociateAgentKnowledgeBase with the addition of +// DeleteAgentActionGroupWithContext is the same as DeleteAgentActionGroup with the addition of // the ability to pass a context and additional request options. // -// See DisassociateAgentKnowledgeBase for details on how to use this API operation. +// See DeleteAgentActionGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) DisassociateAgentKnowledgeBaseWithContext(ctx aws.Context, input *DisassociateAgentKnowledgeBaseInput, opts ...request.Option) (*DisassociateAgentKnowledgeBaseOutput, error) { - req, out := c.DisassociateAgentKnowledgeBaseRequest(input) +func (c *BedrockAgent) DeleteAgentActionGroupWithContext(ctx aws.Context, input *DeleteAgentActionGroupInput, opts ...request.Option) (*DeleteAgentActionGroupOutput, error) { + req, out := c.DeleteAgentActionGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetAgent = "GetAgent" +const opDeleteAgentAlias = "DeleteAgentAlias" -// GetAgentRequest generates a "aws/request.Request" representing the -// client's request for the GetAgent operation. The "output" return +// DeleteAgentAliasRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAgentAlias operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAgent for more information on using the GetAgent +// See DeleteAgentAlias for more information on using the DeleteAgentAlias // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAgentRequest method. -// req, resp := client.GetAgentRequest(params) +// // Example sending a request using the DeleteAgentAliasRequest method. +// req, resp := client.DeleteAgentAliasRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgent -func (c *BedrockAgent) GetAgentRequest(input *GetAgentInput) (req *request.Request, output *GetAgentOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentAlias +func (c *BedrockAgent) DeleteAgentAliasRequest(input *DeleteAgentAliasInput) (req *request.Request, output *DeleteAgentAliasOutput) { op := &request.Operation{ - Name: opGetAgent, - HTTPMethod: "GET", - HTTPPath: "/agents/{agentId}/", + Name: opDeleteAgentAlias, + HTTPMethod: "DELETE", + HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", } if input == nil { - input = &GetAgentInput{} + input = &DeleteAgentAliasInput{} } - output = &GetAgentOutput{} + output = &DeleteAgentAliasOutput{} req = c.newRequest(op, input, output) return } -// GetAgent API operation for Agents for Amazon Bedrock. +// DeleteAgentAlias API operation for Agents for Amazon Bedrock. // -// Gets information about an agent. +// Deletes an alias of an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetAgent for usage and error information. +// API operation DeleteAgentAlias for usage and error information. // // Returned Error Types: // @@ -1389,79 +1422,79 @@ func (c *BedrockAgent) GetAgentRequest(input *GetAgentInput) (req *request.Reque // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgent -func (c *BedrockAgent) GetAgent(input *GetAgentInput) (*GetAgentOutput, error) { - req, out := c.GetAgentRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentAlias +func (c *BedrockAgent) DeleteAgentAlias(input *DeleteAgentAliasInput) (*DeleteAgentAliasOutput, error) { + req, out := c.DeleteAgentAliasRequest(input) return out, req.Send() } -// GetAgentWithContext is the same as GetAgent with the addition of +// DeleteAgentAliasWithContext is the same as DeleteAgentAlias with the addition of // the ability to pass a context and additional request options. // -// See GetAgent for details on how to use this API operation. +// See DeleteAgentAlias for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetAgentWithContext(ctx aws.Context, input *GetAgentInput, opts ...request.Option) (*GetAgentOutput, error) { - req, out := c.GetAgentRequest(input) +func (c *BedrockAgent) DeleteAgentAliasWithContext(ctx aws.Context, input *DeleteAgentAliasInput, opts ...request.Option) (*DeleteAgentAliasOutput, error) { + req, out := c.DeleteAgentAliasRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetAgentActionGroup = "GetAgentActionGroup" +const opDeleteAgentVersion = "DeleteAgentVersion" -// GetAgentActionGroupRequest generates a "aws/request.Request" representing the -// client's request for the GetAgentActionGroup operation. The "output" return +// DeleteAgentVersionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAgentVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAgentActionGroup for more information on using the GetAgentActionGroup +// See DeleteAgentVersion for more information on using the DeleteAgentVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAgentActionGroupRequest method. -// req, resp := client.GetAgentActionGroupRequest(params) +// // Example sending a request using the DeleteAgentVersionRequest method. +// req, resp := client.DeleteAgentVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentActionGroup -func (c *BedrockAgent) GetAgentActionGroupRequest(input *GetAgentActionGroupInput) (req *request.Request, output *GetAgentActionGroupOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentVersion +func (c *BedrockAgent) DeleteAgentVersionRequest(input *DeleteAgentVersionInput) (req *request.Request, output *DeleteAgentVersionOutput) { op := &request.Operation{ - Name: opGetAgentActionGroup, - HTTPMethod: "GET", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", + Name: opDeleteAgentVersion, + HTTPMethod: "DELETE", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/", } if input == nil { - input = &GetAgentActionGroupInput{} + input = &DeleteAgentVersionInput{} } - output = &GetAgentActionGroupOutput{} + output = &DeleteAgentVersionOutput{} req = c.newRequest(op, input, output) return } -// GetAgentActionGroup API operation for Agents for Amazon Bedrock. +// DeleteAgentVersion API operation for Agents for Amazon Bedrock. // -// Gets information about an action group for an agent. +// Deletes a version of an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetAgentActionGroup for usage and error information. +// API operation DeleteAgentVersion for usage and error information. // // Returned Error Types: // @@ -1481,79 +1514,82 @@ func (c *BedrockAgent) GetAgentActionGroupRequest(input *GetAgentActionGroupInpu // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentActionGroup -func (c *BedrockAgent) GetAgentActionGroup(input *GetAgentActionGroupInput) (*GetAgentActionGroupOutput, error) { - req, out := c.GetAgentActionGroupRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentVersion +func (c *BedrockAgent) DeleteAgentVersion(input *DeleteAgentVersionInput) (*DeleteAgentVersionOutput, error) { + req, out := c.DeleteAgentVersionRequest(input) return out, req.Send() } -// GetAgentActionGroupWithContext is the same as GetAgentActionGroup with the addition of +// DeleteAgentVersionWithContext is the same as DeleteAgentVersion with the addition of // the ability to pass a context and additional request options. // -// See GetAgentActionGroup for details on how to use this API operation. +// See DeleteAgentVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetAgentActionGroupWithContext(ctx aws.Context, input *GetAgentActionGroupInput, opts ...request.Option) (*GetAgentActionGroupOutput, error) { - req, out := c.GetAgentActionGroupRequest(input) +func (c *BedrockAgent) DeleteAgentVersionWithContext(ctx aws.Context, input *DeleteAgentVersionInput, opts ...request.Option) (*DeleteAgentVersionOutput, error) { + req, out := c.DeleteAgentVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetAgentAlias = "GetAgentAlias" +const opDeleteDataSource = "DeleteDataSource" -// GetAgentAliasRequest generates a "aws/request.Request" representing the -// client's request for the GetAgentAlias operation. The "output" return +// DeleteDataSourceRequest generates a "aws/request.Request" representing the +// client's request for the DeleteDataSource operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAgentAlias for more information on using the GetAgentAlias +// See DeleteDataSource for more information on using the DeleteDataSource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAgentAliasRequest method. -// req, resp := client.GetAgentAliasRequest(params) +// // Example sending a request using the DeleteDataSourceRequest method. +// req, resp := client.DeleteDataSourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentAlias -func (c *BedrockAgent) GetAgentAliasRequest(input *GetAgentAliasInput) (req *request.Request, output *GetAgentAliasOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteDataSource +func (c *BedrockAgent) DeleteDataSourceRequest(input *DeleteDataSourceInput) (req *request.Request, output *DeleteDataSourceOutput) { op := &request.Operation{ - Name: opGetAgentAlias, - HTTPMethod: "GET", - HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", + Name: opDeleteDataSource, + HTTPMethod: "DELETE", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", } if input == nil { - input = &GetAgentAliasInput{} + input = &DeleteDataSourceInput{} } - output = &GetAgentAliasOutput{} + output = &DeleteDataSourceOutput{} req = c.newRequest(op, input, output) return } -// GetAgentAlias API operation for Agents for Amazon Bedrock. +// DeleteDataSource API operation for Agents for Amazon Bedrock. // -// Gets information about an alias of an agent. +// Deletes a data source from a knowledge base. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetAgentAlias for usage and error information. +// API operation DeleteDataSource for usage and error information. // // Returned Error Types: // @@ -1573,79 +1609,82 @@ func (c *BedrockAgent) GetAgentAliasRequest(input *GetAgentAliasInput) (req *req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentAlias -func (c *BedrockAgent) GetAgentAlias(input *GetAgentAliasInput) (*GetAgentAliasOutput, error) { - req, out := c.GetAgentAliasRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteDataSource +func (c *BedrockAgent) DeleteDataSource(input *DeleteDataSourceInput) (*DeleteDataSourceOutput, error) { + req, out := c.DeleteDataSourceRequest(input) return out, req.Send() } -// GetAgentAliasWithContext is the same as GetAgentAlias with the addition of +// DeleteDataSourceWithContext is the same as DeleteDataSource with the addition of // the ability to pass a context and additional request options. // -// See GetAgentAlias for details on how to use this API operation. +// See DeleteDataSource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetAgentAliasWithContext(ctx aws.Context, input *GetAgentAliasInput, opts ...request.Option) (*GetAgentAliasOutput, error) { - req, out := c.GetAgentAliasRequest(input) +func (c *BedrockAgent) DeleteDataSourceWithContext(ctx aws.Context, input *DeleteDataSourceInput, opts ...request.Option) (*DeleteDataSourceOutput, error) { + req, out := c.DeleteDataSourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetAgentKnowledgeBase = "GetAgentKnowledgeBase" +const opDeleteFlow = "DeleteFlow" -// GetAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the GetAgentKnowledgeBase operation. The "output" return +// DeleteFlowRequest generates a "aws/request.Request" representing the +// client's request for the DeleteFlow operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAgentKnowledgeBase for more information on using the GetAgentKnowledgeBase +// See DeleteFlow for more information on using the DeleteFlow // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAgentKnowledgeBaseRequest method. -// req, resp := client.GetAgentKnowledgeBaseRequest(params) +// // Example sending a request using the DeleteFlowRequest method. +// req, resp := client.DeleteFlowRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentKnowledgeBase -func (c *BedrockAgent) GetAgentKnowledgeBaseRequest(input *GetAgentKnowledgeBaseInput) (req *request.Request, output *GetAgentKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlow +func (c *BedrockAgent) DeleteFlowRequest(input *DeleteFlowInput) (req *request.Request, output *DeleteFlowOutput) { op := &request.Operation{ - Name: opGetAgentKnowledgeBase, - HTTPMethod: "GET", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", + Name: opDeleteFlow, + HTTPMethod: "DELETE", + HTTPPath: "/flows/{flowIdentifier}/", } if input == nil { - input = &GetAgentKnowledgeBaseInput{} + input = &DeleteFlowInput{} } - output = &GetAgentKnowledgeBaseOutput{} + output = &DeleteFlowOutput{} req = c.newRequest(op, input, output) return } -// GetAgentKnowledgeBase API operation for Agents for Amazon Bedrock. +// DeleteFlow API operation for Agents for Amazon Bedrock. // -// Gets information about a knowledge base associated with an agent. +// Deletes a flow. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetAgentKnowledgeBase for usage and error information. +// API operation DeleteFlow for usage and error information. // // Returned Error Types: // @@ -1665,79 +1704,82 @@ func (c *BedrockAgent) GetAgentKnowledgeBaseRequest(input *GetAgentKnowledgeBase // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentKnowledgeBase -func (c *BedrockAgent) GetAgentKnowledgeBase(input *GetAgentKnowledgeBaseInput) (*GetAgentKnowledgeBaseOutput, error) { - req, out := c.GetAgentKnowledgeBaseRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlow +func (c *BedrockAgent) DeleteFlow(input *DeleteFlowInput) (*DeleteFlowOutput, error) { + req, out := c.DeleteFlowRequest(input) return out, req.Send() } -// GetAgentKnowledgeBaseWithContext is the same as GetAgentKnowledgeBase with the addition of +// DeleteFlowWithContext is the same as DeleteFlow with the addition of // the ability to pass a context and additional request options. // -// See GetAgentKnowledgeBase for details on how to use this API operation. +// See DeleteFlow for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetAgentKnowledgeBaseWithContext(ctx aws.Context, input *GetAgentKnowledgeBaseInput, opts ...request.Option) (*GetAgentKnowledgeBaseOutput, error) { - req, out := c.GetAgentKnowledgeBaseRequest(input) +func (c *BedrockAgent) DeleteFlowWithContext(ctx aws.Context, input *DeleteFlowInput, opts ...request.Option) (*DeleteFlowOutput, error) { + req, out := c.DeleteFlowRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetAgentVersion = "GetAgentVersion" +const opDeleteFlowAlias = "DeleteFlowAlias" -// GetAgentVersionRequest generates a "aws/request.Request" representing the -// client's request for the GetAgentVersion operation. The "output" return +// DeleteFlowAliasRequest generates a "aws/request.Request" representing the +// client's request for the DeleteFlowAlias operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAgentVersion for more information on using the GetAgentVersion +// See DeleteFlowAlias for more information on using the DeleteFlowAlias // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAgentVersionRequest method. -// req, resp := client.GetAgentVersionRequest(params) +// // Example sending a request using the DeleteFlowAliasRequest method. +// req, resp := client.DeleteFlowAliasRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentVersion -func (c *BedrockAgent) GetAgentVersionRequest(input *GetAgentVersionInput) (req *request.Request, output *GetAgentVersionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlowAlias +func (c *BedrockAgent) DeleteFlowAliasRequest(input *DeleteFlowAliasInput) (req *request.Request, output *DeleteFlowAliasOutput) { op := &request.Operation{ - Name: opGetAgentVersion, - HTTPMethod: "GET", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/", + Name: opDeleteFlowAlias, + HTTPMethod: "DELETE", + HTTPPath: "/flows/{flowIdentifier}/aliases/{aliasIdentifier}", } if input == nil { - input = &GetAgentVersionInput{} + input = &DeleteFlowAliasInput{} } - output = &GetAgentVersionOutput{} + output = &DeleteFlowAliasOutput{} req = c.newRequest(op, input, output) return } -// GetAgentVersion API operation for Agents for Amazon Bedrock. +// DeleteFlowAlias API operation for Agents for Amazon Bedrock. // -// Gets details about a version of an agent. +// Deletes an alias of a flow. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetAgentVersion for usage and error information. +// API operation DeleteFlowAlias for usage and error information. // // Returned Error Types: // @@ -1757,79 +1799,82 @@ func (c *BedrockAgent) GetAgentVersionRequest(input *GetAgentVersionInput) (req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentVersion -func (c *BedrockAgent) GetAgentVersion(input *GetAgentVersionInput) (*GetAgentVersionOutput, error) { - req, out := c.GetAgentVersionRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlowAlias +func (c *BedrockAgent) DeleteFlowAlias(input *DeleteFlowAliasInput) (*DeleteFlowAliasOutput, error) { + req, out := c.DeleteFlowAliasRequest(input) return out, req.Send() } -// GetAgentVersionWithContext is the same as GetAgentVersion with the addition of +// DeleteFlowAliasWithContext is the same as DeleteFlowAlias with the addition of // the ability to pass a context and additional request options. // -// See GetAgentVersion for details on how to use this API operation. +// See DeleteFlowAlias for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetAgentVersionWithContext(ctx aws.Context, input *GetAgentVersionInput, opts ...request.Option) (*GetAgentVersionOutput, error) { - req, out := c.GetAgentVersionRequest(input) +func (c *BedrockAgent) DeleteFlowAliasWithContext(ctx aws.Context, input *DeleteFlowAliasInput, opts ...request.Option) (*DeleteFlowAliasOutput, error) { + req, out := c.DeleteFlowAliasRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetDataSource = "GetDataSource" +const opDeleteFlowVersion = "DeleteFlowVersion" -// GetDataSourceRequest generates a "aws/request.Request" representing the -// client's request for the GetDataSource operation. The "output" return +// DeleteFlowVersionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteFlowVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetDataSource for more information on using the GetDataSource +// See DeleteFlowVersion for more information on using the DeleteFlowVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetDataSourceRequest method. -// req, resp := client.GetDataSourceRequest(params) +// // Example sending a request using the DeleteFlowVersionRequest method. +// req, resp := client.DeleteFlowVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetDataSource -func (c *BedrockAgent) GetDataSourceRequest(input *GetDataSourceInput) (req *request.Request, output *GetDataSourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlowVersion +func (c *BedrockAgent) DeleteFlowVersionRequest(input *DeleteFlowVersionInput) (req *request.Request, output *DeleteFlowVersionOutput) { op := &request.Operation{ - Name: opGetDataSource, - HTTPMethod: "GET", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", + Name: opDeleteFlowVersion, + HTTPMethod: "DELETE", + HTTPPath: "/flows/{flowIdentifier}/versions/{flowVersion}/", } if input == nil { - input = &GetDataSourceInput{} + input = &DeleteFlowVersionInput{} } - output = &GetDataSourceOutput{} + output = &DeleteFlowVersionOutput{} req = c.newRequest(op, input, output) return } -// GetDataSource API operation for Agents for Amazon Bedrock. +// DeleteFlowVersion API operation for Agents for Amazon Bedrock. // -// Gets information about a data source. +// Deletes a version of a flow. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetDataSource for usage and error information. +// API operation DeleteFlowVersion for usage and error information. // // Returned Error Types: // @@ -1849,80 +1894,85 @@ func (c *BedrockAgent) GetDataSourceRequest(input *GetDataSourceInput) (req *req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetDataSource -func (c *BedrockAgent) GetDataSource(input *GetDataSourceInput) (*GetDataSourceOutput, error) { - req, out := c.GetDataSourceRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteFlowVersion +func (c *BedrockAgent) DeleteFlowVersion(input *DeleteFlowVersionInput) (*DeleteFlowVersionOutput, error) { + req, out := c.DeleteFlowVersionRequest(input) return out, req.Send() } -// GetDataSourceWithContext is the same as GetDataSource with the addition of +// DeleteFlowVersionWithContext is the same as DeleteFlowVersion with the addition of // the ability to pass a context and additional request options. // -// See GetDataSource for details on how to use this API operation. +// See DeleteFlowVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetDataSourceWithContext(ctx aws.Context, input *GetDataSourceInput, opts ...request.Option) (*GetDataSourceOutput, error) { - req, out := c.GetDataSourceRequest(input) +func (c *BedrockAgent) DeleteFlowVersionWithContext(ctx aws.Context, input *DeleteFlowVersionInput, opts ...request.Option) (*DeleteFlowVersionOutput, error) { + req, out := c.DeleteFlowVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetIngestionJob = "GetIngestionJob" +const opDeleteKnowledgeBase = "DeleteKnowledgeBase" -// GetIngestionJobRequest generates a "aws/request.Request" representing the -// client's request for the GetIngestionJob operation. The "output" return +// DeleteKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the DeleteKnowledgeBase operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetIngestionJob for more information on using the GetIngestionJob +// See DeleteKnowledgeBase for more information on using the DeleteKnowledgeBase // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetIngestionJobRequest method. -// req, resp := client.GetIngestionJobRequest(params) +// // Example sending a request using the DeleteKnowledgeBaseRequest method. +// req, resp := client.DeleteKnowledgeBaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetIngestionJob -func (c *BedrockAgent) GetIngestionJobRequest(input *GetIngestionJobInput) (req *request.Request, output *GetIngestionJobOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteKnowledgeBase +func (c *BedrockAgent) DeleteKnowledgeBaseRequest(input *DeleteKnowledgeBaseInput) (req *request.Request, output *DeleteKnowledgeBaseOutput) { op := &request.Operation{ - Name: opGetIngestionJob, - HTTPMethod: "GET", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/{ingestionJobId}", + Name: opDeleteKnowledgeBase, + HTTPMethod: "DELETE", + HTTPPath: "/knowledgebases/{knowledgeBaseId}", } if input == nil { - input = &GetIngestionJobInput{} + input = &DeleteKnowledgeBaseInput{} } - output = &GetIngestionJobOutput{} + output = &DeleteKnowledgeBaseOutput{} req = c.newRequest(op, input, output) return } -// GetIngestionJob API operation for Agents for Amazon Bedrock. +// DeleteKnowledgeBase API operation for Agents for Amazon Bedrock. // -// Gets information about a ingestion job, in which a data source is added to -// a knowledge base. +// 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_DisassociateAgentKnowledgeBase.html) +// request. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetIngestionJob for usage and error information. +// API operation DeleteKnowledgeBase for usage and error information. // // Returned Error Types: // @@ -1942,79 +1992,85 @@ func (c *BedrockAgent) GetIngestionJobRequest(input *GetIngestionJobInput) (req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetIngestionJob -func (c *BedrockAgent) GetIngestionJob(input *GetIngestionJobInput) (*GetIngestionJobOutput, error) { - req, out := c.GetIngestionJobRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteKnowledgeBase +func (c *BedrockAgent) DeleteKnowledgeBase(input *DeleteKnowledgeBaseInput) (*DeleteKnowledgeBaseOutput, error) { + req, out := c.DeleteKnowledgeBaseRequest(input) return out, req.Send() } -// GetIngestionJobWithContext is the same as GetIngestionJob with the addition of +// DeleteKnowledgeBaseWithContext is the same as DeleteKnowledgeBase with the addition of // the ability to pass a context and additional request options. // -// See GetIngestionJob for details on how to use this API operation. +// See DeleteKnowledgeBase for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetIngestionJobWithContext(ctx aws.Context, input *GetIngestionJobInput, opts ...request.Option) (*GetIngestionJobOutput, error) { - req, out := c.GetIngestionJobRequest(input) +func (c *BedrockAgent) DeleteKnowledgeBaseWithContext(ctx aws.Context, input *DeleteKnowledgeBaseInput, opts ...request.Option) (*DeleteKnowledgeBaseOutput, error) { + req, out := c.DeleteKnowledgeBaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetKnowledgeBase = "GetKnowledgeBase" +const opDeletePrompt = "DeletePrompt" -// GetKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the GetKnowledgeBase operation. The "output" return +// DeletePromptRequest generates a "aws/request.Request" representing the +// client's request for the DeletePrompt operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetKnowledgeBase for more information on using the GetKnowledgeBase +// See DeletePrompt for more information on using the DeletePrompt // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetKnowledgeBaseRequest method. -// req, resp := client.GetKnowledgeBaseRequest(params) +// // Example sending a request using the DeletePromptRequest method. +// req, resp := client.DeletePromptRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetKnowledgeBase -func (c *BedrockAgent) GetKnowledgeBaseRequest(input *GetKnowledgeBaseInput) (req *request.Request, output *GetKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeletePrompt +func (c *BedrockAgent) DeletePromptRequest(input *DeletePromptInput) (req *request.Request, output *DeletePromptOutput) { op := &request.Operation{ - Name: opGetKnowledgeBase, - HTTPMethod: "GET", - HTTPPath: "/knowledgebases/{knowledgeBaseId}", + Name: opDeletePrompt, + HTTPMethod: "DELETE", + HTTPPath: "/prompts/{promptIdentifier}/", } if input == nil { - input = &GetKnowledgeBaseInput{} + input = &DeletePromptInput{} } - output = &GetKnowledgeBaseOutput{} + output = &DeletePromptOutput{} req = c.newRequest(op, input, output) return } -// GetKnowledgeBase API operation for Agents for Amazon Bedrock. +// DeletePrompt API operation for Agents for Amazon Bedrock. // -// Gets information about a knoweldge base. +// Deletes a prompt or a prompt version from the Prompt management tool. For +// more information, see Delete prompts from the Prompt management tool (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-manage.html#prompt-management-delete.html) +// and Delete a version of a prompt from the Prompt management tool (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-deploy.html#prompt-management-versions-delete.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation GetKnowledgeBase for usage and error information. +// API operation DeletePrompt for usage and error information. // // Returned Error Types: // @@ -2034,85 +2090,83 @@ func (c *BedrockAgent) GetKnowledgeBaseRequest(input *GetKnowledgeBaseInput) (re // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetKnowledgeBase -func (c *BedrockAgent) GetKnowledgeBase(input *GetKnowledgeBaseInput) (*GetKnowledgeBaseOutput, error) { - req, out := c.GetKnowledgeBaseRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeletePrompt +func (c *BedrockAgent) DeletePrompt(input *DeletePromptInput) (*DeletePromptOutput, error) { + req, out := c.DeletePromptRequest(input) return out, req.Send() } -// GetKnowledgeBaseWithContext is the same as GetKnowledgeBase with the addition of +// DeletePromptWithContext is the same as DeletePrompt with the addition of // the ability to pass a context and additional request options. // -// See GetKnowledgeBase for details on how to use this API operation. +// See DeletePrompt for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) GetKnowledgeBaseWithContext(ctx aws.Context, input *GetKnowledgeBaseInput, opts ...request.Option) (*GetKnowledgeBaseOutput, error) { - req, out := c.GetKnowledgeBaseRequest(input) +func (c *BedrockAgent) DeletePromptWithContext(ctx aws.Context, input *DeletePromptInput, opts ...request.Option) (*DeletePromptOutput, error) { + req, out := c.DeletePromptRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opListAgentActionGroups = "ListAgentActionGroups" +const opDisassociateAgentKnowledgeBase = "DisassociateAgentKnowledgeBase" -// ListAgentActionGroupsRequest generates a "aws/request.Request" representing the -// client's request for the ListAgentActionGroups operation. The "output" return +// DisassociateAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the DisassociateAgentKnowledgeBase operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListAgentActionGroups for more information on using the ListAgentActionGroups +// See DisassociateAgentKnowledgeBase for more information on using the DisassociateAgentKnowledgeBase // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListAgentActionGroupsRequest method. -// req, resp := client.ListAgentActionGroupsRequest(params) +// // Example sending a request using the DisassociateAgentKnowledgeBaseRequest method. +// req, resp := client.DisassociateAgentKnowledgeBaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentActionGroups -func (c *BedrockAgent) ListAgentActionGroupsRequest(input *ListAgentActionGroupsInput) (req *request.Request, output *ListAgentActionGroupsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DisassociateAgentKnowledgeBase +func (c *BedrockAgent) DisassociateAgentKnowledgeBaseRequest(input *DisassociateAgentKnowledgeBaseInput) (req *request.Request, output *DisassociateAgentKnowledgeBaseOutput) { op := &request.Operation{ - Name: opListAgentActionGroups, - HTTPMethod: "POST", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opDisassociateAgentKnowledgeBase, + HTTPMethod: "DELETE", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", } if input == nil { - input = &ListAgentActionGroupsInput{} + input = &DisassociateAgentKnowledgeBaseInput{} } - output = &ListAgentActionGroupsOutput{} + output = &DisassociateAgentKnowledgeBaseOutput{} req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// ListAgentActionGroups API operation for Agents for Amazon Bedrock. +// DisassociateAgentKnowledgeBase API operation for Agents for Amazon Bedrock. // -// Lists the action groups for an agent and information about each one. +// Disassociates a knowledge base from an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListAgentActionGroups for usage and error information. +// API operation DisassociateAgentKnowledgeBase for usage and error information. // // Returned Error Types: // @@ -2132,136 +2186,82 @@ func (c *BedrockAgent) ListAgentActionGroupsRequest(input *ListAgentActionGroups // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentActionGroups -func (c *BedrockAgent) ListAgentActionGroups(input *ListAgentActionGroupsInput) (*ListAgentActionGroupsOutput, error) { - req, out := c.ListAgentActionGroupsRequest(input) +// - ConflictException +// There was a conflict performing an operation. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DisassociateAgentKnowledgeBase +func (c *BedrockAgent) DisassociateAgentKnowledgeBase(input *DisassociateAgentKnowledgeBaseInput) (*DisassociateAgentKnowledgeBaseOutput, error) { + req, out := c.DisassociateAgentKnowledgeBaseRequest(input) return out, req.Send() } -// ListAgentActionGroupsWithContext is the same as ListAgentActionGroups with the addition of +// DisassociateAgentKnowledgeBaseWithContext is the same as DisassociateAgentKnowledgeBase with the addition of // the ability to pass a context and additional request options. // -// See ListAgentActionGroups for details on how to use this API operation. +// See DisassociateAgentKnowledgeBase for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListAgentActionGroupsWithContext(ctx aws.Context, input *ListAgentActionGroupsInput, opts ...request.Option) (*ListAgentActionGroupsOutput, error) { - req, out := c.ListAgentActionGroupsRequest(input) +func (c *BedrockAgent) DisassociateAgentKnowledgeBaseWithContext(ctx aws.Context, input *DisassociateAgentKnowledgeBaseInput, opts ...request.Option) (*DisassociateAgentKnowledgeBaseOutput, error) { + req, out := c.DisassociateAgentKnowledgeBaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListAgentActionGroupsPages iterates over the pages of a ListAgentActionGroups operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListAgentActionGroups method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListAgentActionGroups operation. -// pageNum := 0 -// err := client.ListAgentActionGroupsPages(params, -// func(page *bedrockagent.ListAgentActionGroupsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListAgentActionGroupsPages(input *ListAgentActionGroupsInput, fn func(*ListAgentActionGroupsOutput, bool) bool) error { - return c.ListAgentActionGroupsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListAgentActionGroupsPagesWithContext same as ListAgentActionGroupsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListAgentActionGroupsPagesWithContext(ctx aws.Context, input *ListAgentActionGroupsInput, fn func(*ListAgentActionGroupsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListAgentActionGroupsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListAgentActionGroupsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListAgentActionGroupsOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListAgentAliases = "ListAgentAliases" +const opGetAgent = "GetAgent" -// ListAgentAliasesRequest generates a "aws/request.Request" representing the -// client's request for the ListAgentAliases operation. The "output" return +// GetAgentRequest generates a "aws/request.Request" representing the +// client's request for the GetAgent operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListAgentAliases for more information on using the ListAgentAliases +// See GetAgent for more information on using the GetAgent // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListAgentAliasesRequest method. -// req, resp := client.ListAgentAliasesRequest(params) -// +// // Example sending a request using the GetAgentRequest method. +// req, resp := client.GetAgentRequest(params) +// // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentAliases -func (c *BedrockAgent) ListAgentAliasesRequest(input *ListAgentAliasesInput) (req *request.Request, output *ListAgentAliasesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgent +func (c *BedrockAgent) GetAgentRequest(input *GetAgentInput) (req *request.Request, output *GetAgentOutput) { op := &request.Operation{ - Name: opListAgentAliases, - HTTPMethod: "POST", - HTTPPath: "/agents/{agentId}/agentaliases/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetAgent, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/", } if input == nil { - input = &ListAgentAliasesInput{} + input = &GetAgentInput{} } - output = &ListAgentAliasesOutput{} + output = &GetAgentOutput{} req = c.newRequest(op, input, output) return } -// ListAgentAliases API operation for Agents for Amazon Bedrock. +// GetAgent API operation for Agents for Amazon Bedrock. // -// Lists the aliases of an agent and information about each one. +// Gets information about an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListAgentAliases for usage and error information. +// API operation GetAgent for usage and error information. // // Returned Error Types: // @@ -2281,137 +2281,79 @@ func (c *BedrockAgent) ListAgentAliasesRequest(input *ListAgentAliasesInput) (re // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentAliases -func (c *BedrockAgent) ListAgentAliases(input *ListAgentAliasesInput) (*ListAgentAliasesOutput, error) { - req, out := c.ListAgentAliasesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgent +func (c *BedrockAgent) GetAgent(input *GetAgentInput) (*GetAgentOutput, error) { + req, out := c.GetAgentRequest(input) return out, req.Send() } -// ListAgentAliasesWithContext is the same as ListAgentAliases with the addition of +// GetAgentWithContext is the same as GetAgent with the addition of // the ability to pass a context and additional request options. // -// See ListAgentAliases for details on how to use this API operation. +// See GetAgent for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListAgentAliasesWithContext(ctx aws.Context, input *ListAgentAliasesInput, opts ...request.Option) (*ListAgentAliasesOutput, error) { - req, out := c.ListAgentAliasesRequest(input) +func (c *BedrockAgent) GetAgentWithContext(ctx aws.Context, input *GetAgentInput, opts ...request.Option) (*GetAgentOutput, error) { + req, out := c.GetAgentRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListAgentAliasesPages iterates over the pages of a ListAgentAliases operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListAgentAliases method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListAgentAliases operation. -// pageNum := 0 -// err := client.ListAgentAliasesPages(params, -// func(page *bedrockagent.ListAgentAliasesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListAgentAliasesPages(input *ListAgentAliasesInput, fn func(*ListAgentAliasesOutput, bool) bool) error { - return c.ListAgentAliasesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListAgentAliasesPagesWithContext same as ListAgentAliasesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListAgentAliasesPagesWithContext(ctx aws.Context, input *ListAgentAliasesInput, fn func(*ListAgentAliasesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListAgentAliasesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListAgentAliasesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListAgentAliasesOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListAgentKnowledgeBases = "ListAgentKnowledgeBases" +const opGetAgentActionGroup = "GetAgentActionGroup" -// ListAgentKnowledgeBasesRequest generates a "aws/request.Request" representing the -// client's request for the ListAgentKnowledgeBases operation. The "output" return +// GetAgentActionGroupRequest generates a "aws/request.Request" representing the +// client's request for the GetAgentActionGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListAgentKnowledgeBases for more information on using the ListAgentKnowledgeBases +// See GetAgentActionGroup for more information on using the GetAgentActionGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListAgentKnowledgeBasesRequest method. -// req, resp := client.ListAgentKnowledgeBasesRequest(params) +// // Example sending a request using the GetAgentActionGroupRequest method. +// req, resp := client.GetAgentActionGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentKnowledgeBases -func (c *BedrockAgent) ListAgentKnowledgeBasesRequest(input *ListAgentKnowledgeBasesInput) (req *request.Request, output *ListAgentKnowledgeBasesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentActionGroup +func (c *BedrockAgent) GetAgentActionGroupRequest(input *GetAgentActionGroupInput) (req *request.Request, output *GetAgentActionGroupOutput) { op := &request.Operation{ - Name: opListAgentKnowledgeBases, - HTTPMethod: "POST", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetAgentActionGroup, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", } if input == nil { - input = &ListAgentKnowledgeBasesInput{} + input = &GetAgentActionGroupInput{} } - output = &ListAgentKnowledgeBasesOutput{} + output = &GetAgentActionGroupOutput{} req = c.newRequest(op, input, output) return } -// ListAgentKnowledgeBases API operation for Agents for Amazon Bedrock. +// GetAgentActionGroup API operation for Agents for Amazon Bedrock. // -// Lists knowledge bases associated with an agent and information about each -// one. +// Gets information about an action group for an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListAgentKnowledgeBases for usage and error information. +// API operation GetAgentActionGroup for usage and error information. // // Returned Error Types: // @@ -2431,136 +2373,79 @@ func (c *BedrockAgent) ListAgentKnowledgeBasesRequest(input *ListAgentKnowledgeB // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentKnowledgeBases -func (c *BedrockAgent) ListAgentKnowledgeBases(input *ListAgentKnowledgeBasesInput) (*ListAgentKnowledgeBasesOutput, error) { - req, out := c.ListAgentKnowledgeBasesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentActionGroup +func (c *BedrockAgent) GetAgentActionGroup(input *GetAgentActionGroupInput) (*GetAgentActionGroupOutput, error) { + req, out := c.GetAgentActionGroupRequest(input) return out, req.Send() } -// ListAgentKnowledgeBasesWithContext is the same as ListAgentKnowledgeBases with the addition of +// GetAgentActionGroupWithContext is the same as GetAgentActionGroup with the addition of // the ability to pass a context and additional request options. // -// See ListAgentKnowledgeBases for details on how to use this API operation. +// See GetAgentActionGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListAgentKnowledgeBasesWithContext(ctx aws.Context, input *ListAgentKnowledgeBasesInput, opts ...request.Option) (*ListAgentKnowledgeBasesOutput, error) { - req, out := c.ListAgentKnowledgeBasesRequest(input) +func (c *BedrockAgent) GetAgentActionGroupWithContext(ctx aws.Context, input *GetAgentActionGroupInput, opts ...request.Option) (*GetAgentActionGroupOutput, error) { + req, out := c.GetAgentActionGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListAgentKnowledgeBasesPages iterates over the pages of a ListAgentKnowledgeBases operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListAgentKnowledgeBases method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListAgentKnowledgeBases operation. -// pageNum := 0 -// err := client.ListAgentKnowledgeBasesPages(params, -// func(page *bedrockagent.ListAgentKnowledgeBasesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListAgentKnowledgeBasesPages(input *ListAgentKnowledgeBasesInput, fn func(*ListAgentKnowledgeBasesOutput, bool) bool) error { - return c.ListAgentKnowledgeBasesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListAgentKnowledgeBasesPagesWithContext same as ListAgentKnowledgeBasesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListAgentKnowledgeBasesPagesWithContext(ctx aws.Context, input *ListAgentKnowledgeBasesInput, fn func(*ListAgentKnowledgeBasesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListAgentKnowledgeBasesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListAgentKnowledgeBasesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListAgentKnowledgeBasesOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListAgentVersions = "ListAgentVersions" +const opGetAgentAlias = "GetAgentAlias" -// ListAgentVersionsRequest generates a "aws/request.Request" representing the -// client's request for the ListAgentVersions operation. The "output" return +// GetAgentAliasRequest generates a "aws/request.Request" representing the +// client's request for the GetAgentAlias operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListAgentVersions for more information on using the ListAgentVersions +// See GetAgentAlias for more information on using the GetAgentAlias // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListAgentVersionsRequest method. -// req, resp := client.ListAgentVersionsRequest(params) +// // Example sending a request using the GetAgentAliasRequest method. +// req, resp := client.GetAgentAliasRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentVersions -func (c *BedrockAgent) ListAgentVersionsRequest(input *ListAgentVersionsInput) (req *request.Request, output *ListAgentVersionsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentAlias +func (c *BedrockAgent) GetAgentAliasRequest(input *GetAgentAliasInput) (req *request.Request, output *GetAgentAliasOutput) { op := &request.Operation{ - Name: opListAgentVersions, - HTTPMethod: "POST", - HTTPPath: "/agents/{agentId}/agentversions/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetAgentAlias, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", } if input == nil { - input = &ListAgentVersionsInput{} + input = &GetAgentAliasInput{} } - output = &ListAgentVersionsOutput{} + output = &GetAgentAliasOutput{} req = c.newRequest(op, input, output) return } -// ListAgentVersions API operation for Agents for Amazon Bedrock. +// GetAgentAlias API operation for Agents for Amazon Bedrock. // -// Lists the versions of an agent and information about each version. +// Gets information about an alias of an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListAgentVersions for usage and error information. +// API operation GetAgentAlias for usage and error information. // // Returned Error Types: // @@ -2580,136 +2465,79 @@ func (c *BedrockAgent) ListAgentVersionsRequest(input *ListAgentVersionsInput) ( // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentVersions -func (c *BedrockAgent) ListAgentVersions(input *ListAgentVersionsInput) (*ListAgentVersionsOutput, error) { - req, out := c.ListAgentVersionsRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentAlias +func (c *BedrockAgent) GetAgentAlias(input *GetAgentAliasInput) (*GetAgentAliasOutput, error) { + req, out := c.GetAgentAliasRequest(input) return out, req.Send() } -// ListAgentVersionsWithContext is the same as ListAgentVersions with the addition of +// GetAgentAliasWithContext is the same as GetAgentAlias with the addition of // the ability to pass a context and additional request options. // -// See ListAgentVersions for details on how to use this API operation. +// See GetAgentAlias for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListAgentVersionsWithContext(ctx aws.Context, input *ListAgentVersionsInput, opts ...request.Option) (*ListAgentVersionsOutput, error) { - req, out := c.ListAgentVersionsRequest(input) +func (c *BedrockAgent) GetAgentAliasWithContext(ctx aws.Context, input *GetAgentAliasInput, opts ...request.Option) (*GetAgentAliasOutput, error) { + req, out := c.GetAgentAliasRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListAgentVersionsPages iterates over the pages of a ListAgentVersions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListAgentVersions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListAgentVersions operation. -// pageNum := 0 -// err := client.ListAgentVersionsPages(params, -// func(page *bedrockagent.ListAgentVersionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListAgentVersionsPages(input *ListAgentVersionsInput, fn func(*ListAgentVersionsOutput, bool) bool) error { - return c.ListAgentVersionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListAgentVersionsPagesWithContext same as ListAgentVersionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListAgentVersionsPagesWithContext(ctx aws.Context, input *ListAgentVersionsInput, fn func(*ListAgentVersionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListAgentVersionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListAgentVersionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListAgentVersionsOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListAgents = "ListAgents" +const opGetAgentKnowledgeBase = "GetAgentKnowledgeBase" -// ListAgentsRequest generates a "aws/request.Request" representing the -// client's request for the ListAgents operation. The "output" return +// GetAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the GetAgentKnowledgeBase operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListAgents for more information on using the ListAgents +// See GetAgentKnowledgeBase for more information on using the GetAgentKnowledgeBase // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListAgentsRequest method. -// req, resp := client.ListAgentsRequest(params) +// // Example sending a request using the GetAgentKnowledgeBaseRequest method. +// req, resp := client.GetAgentKnowledgeBaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgents -func (c *BedrockAgent) ListAgentsRequest(input *ListAgentsInput) (req *request.Request, output *ListAgentsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentKnowledgeBase +func (c *BedrockAgent) GetAgentKnowledgeBaseRequest(input *GetAgentKnowledgeBaseInput) (req *request.Request, output *GetAgentKnowledgeBaseOutput) { op := &request.Operation{ - Name: opListAgents, - HTTPMethod: "POST", - HTTPPath: "/agents/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetAgentKnowledgeBase, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", } if input == nil { - input = &ListAgentsInput{} + input = &GetAgentKnowledgeBaseInput{} } - output = &ListAgentsOutput{} + output = &GetAgentKnowledgeBaseOutput{} req = c.newRequest(op, input, output) return } -// ListAgents API operation for Agents for Amazon Bedrock. +// GetAgentKnowledgeBase API operation for Agents for Amazon Bedrock. // -// Lists the agents belonging to an account and information about each agent. +// Gets information about a knowledge base associated with an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListAgents for usage and error information. +// API operation GetAgentKnowledgeBase for usage and error information. // // Returned Error Types: // @@ -2725,136 +2553,83 @@ func (c *BedrockAgent) ListAgentsRequest(input *ListAgentsInput) (req *request.R // - InternalServerException // An internal server error occurred. Retry your request. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgents -func (c *BedrockAgent) ListAgents(input *ListAgentsInput) (*ListAgentsOutput, error) { - req, out := c.ListAgentsRequest(input) +// - ResourceNotFoundException +// The specified resource Amazon Resource Name (ARN) was not found. Check the +// Amazon Resource Name (ARN) and try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentKnowledgeBase +func (c *BedrockAgent) GetAgentKnowledgeBase(input *GetAgentKnowledgeBaseInput) (*GetAgentKnowledgeBaseOutput, error) { + req, out := c.GetAgentKnowledgeBaseRequest(input) return out, req.Send() } -// ListAgentsWithContext is the same as ListAgents with the addition of +// GetAgentKnowledgeBaseWithContext is the same as GetAgentKnowledgeBase with the addition of // the ability to pass a context and additional request options. // -// See ListAgents for details on how to use this API operation. +// See GetAgentKnowledgeBase for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListAgentsWithContext(ctx aws.Context, input *ListAgentsInput, opts ...request.Option) (*ListAgentsOutput, error) { - req, out := c.ListAgentsRequest(input) +func (c *BedrockAgent) GetAgentKnowledgeBaseWithContext(ctx aws.Context, input *GetAgentKnowledgeBaseInput, opts ...request.Option) (*GetAgentKnowledgeBaseOutput, error) { + req, out := c.GetAgentKnowledgeBaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListAgentsPages iterates over the pages of a ListAgents operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListAgents method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListAgents operation. -// pageNum := 0 -// err := client.ListAgentsPages(params, -// func(page *bedrockagent.ListAgentsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListAgentsPages(input *ListAgentsInput, fn func(*ListAgentsOutput, bool) bool) error { - return c.ListAgentsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListAgentsPagesWithContext same as ListAgentsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListAgentsPagesWithContext(ctx aws.Context, input *ListAgentsInput, fn func(*ListAgentsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListAgentsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListAgentsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListAgentsOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListDataSources = "ListDataSources" +const opGetAgentVersion = "GetAgentVersion" -// ListDataSourcesRequest generates a "aws/request.Request" representing the -// client's request for the ListDataSources operation. The "output" return +// GetAgentVersionRequest generates a "aws/request.Request" representing the +// client's request for the GetAgentVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListDataSources for more information on using the ListDataSources +// See GetAgentVersion for more information on using the GetAgentVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListDataSourcesRequest method. -// req, resp := client.ListDataSourcesRequest(params) +// // Example sending a request using the GetAgentVersionRequest method. +// req, resp := client.GetAgentVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListDataSources -func (c *BedrockAgent) ListDataSourcesRequest(input *ListDataSourcesInput) (req *request.Request, output *ListDataSourcesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentVersion +func (c *BedrockAgent) GetAgentVersionRequest(input *GetAgentVersionInput) (req *request.Request, output *GetAgentVersionOutput) { op := &request.Operation{ - Name: opListDataSources, - HTTPMethod: "POST", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetAgentVersion, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/", } if input == nil { - input = &ListDataSourcesInput{} + input = &GetAgentVersionInput{} } - output = &ListDataSourcesOutput{} + output = &GetAgentVersionOutput{} req = c.newRequest(op, input, output) return } -// ListDataSources API operation for Agents for Amazon Bedrock. +// GetAgentVersion API operation for Agents for Amazon Bedrock. // -// Lists the data sources in a knowledge base and information about each one. +// Gets details about a version of an agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListDataSources for usage and error information. +// API operation GetAgentVersion for usage and error information. // // Returned Error Types: // @@ -2874,137 +2649,173 @@ func (c *BedrockAgent) ListDataSourcesRequest(input *ListDataSourcesInput) (req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListDataSources -func (c *BedrockAgent) ListDataSources(input *ListDataSourcesInput) (*ListDataSourcesOutput, error) { - req, out := c.ListDataSourcesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentVersion +func (c *BedrockAgent) GetAgentVersion(input *GetAgentVersionInput) (*GetAgentVersionOutput, error) { + req, out := c.GetAgentVersionRequest(input) return out, req.Send() } -// ListDataSourcesWithContext is the same as ListDataSources with the addition of +// GetAgentVersionWithContext is the same as GetAgentVersion with the addition of // the ability to pass a context and additional request options. // -// See ListDataSources for details on how to use this API operation. +// See GetAgentVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListDataSourcesWithContext(ctx aws.Context, input *ListDataSourcesInput, opts ...request.Option) (*ListDataSourcesOutput, error) { - req, out := c.ListDataSourcesRequest(input) +func (c *BedrockAgent) GetAgentVersionWithContext(ctx aws.Context, input *GetAgentVersionInput, opts ...request.Option) (*GetAgentVersionOutput, error) { + req, out := c.GetAgentVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListDataSourcesPages iterates over the pages of a ListDataSources operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. +const opGetDataSource = "GetDataSource" + +// GetDataSourceRequest generates a "aws/request.Request" representing the +// client's request for the GetDataSource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // -// See ListDataSources method for more information on how to use this operation. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// Note: This operation can generate multiple requests to a service. +// See GetDataSource for more information on using the GetDataSource +// API call, and error handling. // -// // Example iterating over at most 3 pages of a ListDataSources operation. -// pageNum := 0 -// err := client.ListDataSourcesPages(params, -// func(page *bedrockagent.ListDataSourcesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListDataSourcesPages(input *ListDataSourcesInput, fn func(*ListDataSourcesOutput, bool) bool) error { - return c.ListDataSourcesPagesWithContext(aws.BackgroundContext(), input, fn) +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the GetDataSourceRequest method. +// req, resp := client.GetDataSourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetDataSource +func (c *BedrockAgent) GetDataSourceRequest(input *GetDataSourceInput) (req *request.Request, output *GetDataSourceOutput) { + op := &request.Operation{ + Name: opGetDataSource, + HTTPMethod: "GET", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", + } + + if input == nil { + input = &GetDataSourceInput{} + } + + output = &GetDataSourceOutput{} + req = c.newRequest(op, input, output) + return } -// ListDataSourcesPagesWithContext same as ListDataSourcesPages except -// it takes a Context and allows setting request options on the pages. +// GetDataSource API operation for Agents for Amazon Bedrock. +// +// Gets information about a data source. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation GetDataSource for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetDataSource +func (c *BedrockAgent) GetDataSource(input *GetDataSourceInput) (*GetDataSourceOutput, error) { + req, out := c.GetDataSourceRequest(input) + return out, req.Send() +} + +// GetDataSourceWithContext is the same as GetDataSource with the addition of +// the ability to pass a context and additional request options. +// +// See GetDataSource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListDataSourcesPagesWithContext(ctx aws.Context, input *ListDataSourcesInput, fn func(*ListDataSourcesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListDataSourcesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListDataSourcesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListDataSourcesOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() +func (c *BedrockAgent) GetDataSourceWithContext(ctx aws.Context, input *GetDataSourceInput, opts ...request.Option) (*GetDataSourceOutput, error) { + req, out := c.GetDataSourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } -const opListIngestionJobs = "ListIngestionJobs" +const opGetFlow = "GetFlow" -// ListIngestionJobsRequest generates a "aws/request.Request" representing the -// client's request for the ListIngestionJobs operation. The "output" return +// GetFlowRequest generates a "aws/request.Request" representing the +// client's request for the GetFlow operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListIngestionJobs for more information on using the ListIngestionJobs +// See GetFlow for more information on using the GetFlow // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListIngestionJobsRequest method. -// req, resp := client.ListIngestionJobsRequest(params) +// // Example sending a request using the GetFlowRequest method. +// req, resp := client.GetFlowRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListIngestionJobs -func (c *BedrockAgent) ListIngestionJobsRequest(input *ListIngestionJobsInput) (req *request.Request, output *ListIngestionJobsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlow +func (c *BedrockAgent) GetFlowRequest(input *GetFlowInput) (req *request.Request, output *GetFlowOutput) { op := &request.Operation{ - Name: opListIngestionJobs, - HTTPMethod: "POST", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetFlow, + HTTPMethod: "GET", + HTTPPath: "/flows/{flowIdentifier}/", } if input == nil { - input = &ListIngestionJobsInput{} + input = &GetFlowInput{} } - output = &ListIngestionJobsOutput{} + output = &GetFlowOutput{} req = c.newRequest(op, input, output) return } -// ListIngestionJobs API operation for Agents for Amazon Bedrock. +// GetFlow API operation for Agents for Amazon Bedrock. // -// Lists the ingestion jobs for a data source and information about each of -// them. +// Retrieves information about a flow. For more information, see Manage a flow +// in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-manage.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListIngestionJobs for usage and error information. +// API operation GetFlow for usage and error information. // // Returned Error Types: // @@ -3024,136 +2835,81 @@ func (c *BedrockAgent) ListIngestionJobsRequest(input *ListIngestionJobsInput) ( // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListIngestionJobs -func (c *BedrockAgent) ListIngestionJobs(input *ListIngestionJobsInput) (*ListIngestionJobsOutput, error) { - req, out := c.ListIngestionJobsRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlow +func (c *BedrockAgent) GetFlow(input *GetFlowInput) (*GetFlowOutput, error) { + req, out := c.GetFlowRequest(input) return out, req.Send() } -// ListIngestionJobsWithContext is the same as ListIngestionJobs with the addition of +// GetFlowWithContext is the same as GetFlow with the addition of // the ability to pass a context and additional request options. // -// See ListIngestionJobs for details on how to use this API operation. +// See GetFlow for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListIngestionJobsWithContext(ctx aws.Context, input *ListIngestionJobsInput, opts ...request.Option) (*ListIngestionJobsOutput, error) { - req, out := c.ListIngestionJobsRequest(input) +func (c *BedrockAgent) GetFlowWithContext(ctx aws.Context, input *GetFlowInput, opts ...request.Option) (*GetFlowOutput, error) { + req, out := c.GetFlowRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListIngestionJobsPages iterates over the pages of a ListIngestionJobs operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListIngestionJobs method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListIngestionJobs operation. -// pageNum := 0 -// err := client.ListIngestionJobsPages(params, -// func(page *bedrockagent.ListIngestionJobsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListIngestionJobsPages(input *ListIngestionJobsInput, fn func(*ListIngestionJobsOutput, bool) bool) error { - return c.ListIngestionJobsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListIngestionJobsPagesWithContext same as ListIngestionJobsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListIngestionJobsPagesWithContext(ctx aws.Context, input *ListIngestionJobsInput, fn func(*ListIngestionJobsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListIngestionJobsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListIngestionJobsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListIngestionJobsOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListKnowledgeBases = "ListKnowledgeBases" +const opGetFlowAlias = "GetFlowAlias" -// ListKnowledgeBasesRequest generates a "aws/request.Request" representing the -// client's request for the ListKnowledgeBases operation. The "output" return +// GetFlowAliasRequest generates a "aws/request.Request" representing the +// client's request for the GetFlowAlias operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListKnowledgeBases for more information on using the ListKnowledgeBases +// See GetFlowAlias for more information on using the GetFlowAlias // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListKnowledgeBasesRequest method. -// req, resp := client.ListKnowledgeBasesRequest(params) +// // Example sending a request using the GetFlowAliasRequest method. +// req, resp := client.GetFlowAliasRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListKnowledgeBases -func (c *BedrockAgent) ListKnowledgeBasesRequest(input *ListKnowledgeBasesInput) (req *request.Request, output *ListKnowledgeBasesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlowAlias +func (c *BedrockAgent) GetFlowAliasRequest(input *GetFlowAliasInput) (req *request.Request, output *GetFlowAliasOutput) { op := &request.Operation{ - Name: opListKnowledgeBases, - HTTPMethod: "POST", - HTTPPath: "/knowledgebases/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + Name: opGetFlowAlias, + HTTPMethod: "GET", + HTTPPath: "/flows/{flowIdentifier}/aliases/{aliasIdentifier}", } if input == nil { - input = &ListKnowledgeBasesInput{} + input = &GetFlowAliasInput{} } - output = &ListKnowledgeBasesOutput{} + output = &GetFlowAliasOutput{} req = c.newRequest(op, input, output) return } -// ListKnowledgeBases API operation for Agents for Amazon Bedrock. +// GetFlowAlias API operation for Agents for Amazon Bedrock. // -// Lists the knowledge bases in an account and information about each of them. +// Retrieves information about a flow. For more information, see Deploy a flow +// in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListKnowledgeBases for usage and error information. +// API operation GetFlowAlias for usage and error information. // // Returned Error Types: // @@ -3169,130 +2925,85 @@ func (c *BedrockAgent) ListKnowledgeBasesRequest(input *ListKnowledgeBasesInput) // - InternalServerException // An internal server error occurred. Retry your request. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListKnowledgeBases -func (c *BedrockAgent) ListKnowledgeBases(input *ListKnowledgeBasesInput) (*ListKnowledgeBasesOutput, error) { - req, out := c.ListKnowledgeBasesRequest(input) +// - ResourceNotFoundException +// The specified resource Amazon Resource Name (ARN) was not found. Check the +// Amazon Resource Name (ARN) and try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlowAlias +func (c *BedrockAgent) GetFlowAlias(input *GetFlowAliasInput) (*GetFlowAliasOutput, error) { + req, out := c.GetFlowAliasRequest(input) return out, req.Send() } -// ListKnowledgeBasesWithContext is the same as ListKnowledgeBases with the addition of +// GetFlowAliasWithContext is the same as GetFlowAlias with the addition of // the ability to pass a context and additional request options. // -// See ListKnowledgeBases for details on how to use this API operation. +// See GetFlowAlias for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListKnowledgeBasesWithContext(ctx aws.Context, input *ListKnowledgeBasesInput, opts ...request.Option) (*ListKnowledgeBasesOutput, error) { - req, out := c.ListKnowledgeBasesRequest(input) +func (c *BedrockAgent) GetFlowAliasWithContext(ctx aws.Context, input *GetFlowAliasInput, opts ...request.Option) (*GetFlowAliasOutput, error) { + req, out := c.GetFlowAliasRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListKnowledgeBasesPages iterates over the pages of a ListKnowledgeBases operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListKnowledgeBases method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListKnowledgeBases operation. -// pageNum := 0 -// err := client.ListKnowledgeBasesPages(params, -// func(page *bedrockagent.ListKnowledgeBasesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *BedrockAgent) ListKnowledgeBasesPages(input *ListKnowledgeBasesInput, fn func(*ListKnowledgeBasesOutput, bool) bool) error { - return c.ListKnowledgeBasesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListKnowledgeBasesPagesWithContext same as ListKnowledgeBasesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *BedrockAgent) ListKnowledgeBasesPagesWithContext(ctx aws.Context, input *ListKnowledgeBasesInput, fn func(*ListKnowledgeBasesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListKnowledgeBasesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListKnowledgeBasesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListKnowledgeBasesOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListTagsForResource = "ListTagsForResource" +const opGetFlowVersion = "GetFlowVersion" -// ListTagsForResourceRequest generates a "aws/request.Request" representing the -// client's request for the ListTagsForResource operation. The "output" return +// GetFlowVersionRequest generates a "aws/request.Request" representing the +// client's request for the GetFlowVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListTagsForResource for more information on using the ListTagsForResource +// See GetFlowVersion for more information on using the GetFlowVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListTagsForResourceRequest method. -// req, resp := client.ListTagsForResourceRequest(params) +// // Example sending a request using the GetFlowVersionRequest method. +// req, resp := client.GetFlowVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListTagsForResource -func (c *BedrockAgent) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlowVersion +func (c *BedrockAgent) GetFlowVersionRequest(input *GetFlowVersionInput) (req *request.Request, output *GetFlowVersionOutput) { op := &request.Operation{ - Name: opListTagsForResource, + Name: opGetFlowVersion, HTTPMethod: "GET", - HTTPPath: "/tags/{resourceArn}", + HTTPPath: "/flows/{flowIdentifier}/versions/{flowVersion}/", } if input == nil { - input = &ListTagsForResourceInput{} + input = &GetFlowVersionInput{} } - output = &ListTagsForResourceOutput{} + output = &GetFlowVersionOutput{} req = c.newRequest(op, input, output) return } -// ListTagsForResource API operation for Agents for Amazon Bedrock. +// GetFlowVersion API operation for Agents for Amazon Bedrock. // -// List all the tags for the resource you specify. +// Retrieves information about a version of a flow. For more information, see +// Deploy a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation ListTagsForResource for usage and error information. +// API operation GetFlowVersion for usage and error information. // // Returned Error Types: // @@ -3312,79 +3023,80 @@ func (c *BedrockAgent) ListTagsForResourceRequest(input *ListTagsForResourceInpu // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListTagsForResource -func (c *BedrockAgent) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetFlowVersion +func (c *BedrockAgent) GetFlowVersion(input *GetFlowVersionInput) (*GetFlowVersionOutput, error) { + req, out := c.GetFlowVersionRequest(input) return out, req.Send() } -// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// GetFlowVersionWithContext is the same as GetFlowVersion with the addition of // the ability to pass a context and additional request options. // -// See ListTagsForResource for details on how to use this API operation. +// See GetFlowVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +func (c *BedrockAgent) GetFlowVersionWithContext(ctx aws.Context, input *GetFlowVersionInput, opts ...request.Option) (*GetFlowVersionOutput, error) { + req, out := c.GetFlowVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPrepareAgent = "PrepareAgent" +const opGetIngestionJob = "GetIngestionJob" -// PrepareAgentRequest generates a "aws/request.Request" representing the -// client's request for the PrepareAgent operation. The "output" return +// GetIngestionJobRequest generates a "aws/request.Request" representing the +// client's request for the GetIngestionJob operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PrepareAgent for more information on using the PrepareAgent +// See GetIngestionJob for more information on using the GetIngestionJob // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the PrepareAgentRequest method. -// req, resp := client.PrepareAgentRequest(params) +// // Example sending a request using the GetIngestionJobRequest method. +// req, resp := client.GetIngestionJobRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareAgent -func (c *BedrockAgent) PrepareAgentRequest(input *PrepareAgentInput) (req *request.Request, output *PrepareAgentOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetIngestionJob +func (c *BedrockAgent) GetIngestionJobRequest(input *GetIngestionJobInput) (req *request.Request, output *GetIngestionJobOutput) { op := &request.Operation{ - Name: opPrepareAgent, - HTTPMethod: "POST", - HTTPPath: "/agents/{agentId}/", + Name: opGetIngestionJob, + HTTPMethod: "GET", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/{ingestionJobId}", } if input == nil { - input = &PrepareAgentInput{} + input = &GetIngestionJobInput{} } - output = &PrepareAgentOutput{} + output = &GetIngestionJobOutput{} req = c.newRequest(op, input, output) return } -// PrepareAgent API operation for Agents for Amazon Bedrock. +// GetIngestionJob API operation for Agents for Amazon Bedrock. // -// Creates a DRAFT version of the agent that can be used for internal testing. +// Gets information about a ingestion job, in which a data source is added to +// a knowledge base. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation PrepareAgent for usage and error information. +// API operation GetIngestionJob for usage and error information. // // Returned Error Types: // @@ -3404,85 +3116,79 @@ func (c *BedrockAgent) PrepareAgentRequest(input *PrepareAgentInput) (req *reque // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareAgent -func (c *BedrockAgent) PrepareAgent(input *PrepareAgentInput) (*PrepareAgentOutput, error) { - req, out := c.PrepareAgentRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetIngestionJob +func (c *BedrockAgent) GetIngestionJob(input *GetIngestionJobInput) (*GetIngestionJobOutput, error) { + req, out := c.GetIngestionJobRequest(input) return out, req.Send() } -// PrepareAgentWithContext is the same as PrepareAgent with the addition of +// GetIngestionJobWithContext is the same as GetIngestionJob with the addition of // the ability to pass a context and additional request options. // -// See PrepareAgent for details on how to use this API operation. +// See GetIngestionJob for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) PrepareAgentWithContext(ctx aws.Context, input *PrepareAgentInput, opts ...request.Option) (*PrepareAgentOutput, error) { - req, out := c.PrepareAgentRequest(input) +func (c *BedrockAgent) GetIngestionJobWithContext(ctx aws.Context, input *GetIngestionJobInput, opts ...request.Option) (*GetIngestionJobOutput, error) { + req, out := c.GetIngestionJobRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opStartIngestionJob = "StartIngestionJob" +const opGetKnowledgeBase = "GetKnowledgeBase" -// StartIngestionJobRequest generates a "aws/request.Request" representing the -// client's request for the StartIngestionJob operation. The "output" return +// GetKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the GetKnowledgeBase operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See StartIngestionJob for more information on using the StartIngestionJob +// See GetKnowledgeBase for more information on using the GetKnowledgeBase // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the StartIngestionJobRequest method. -// req, resp := client.StartIngestionJobRequest(params) +// // Example sending a request using the GetKnowledgeBaseRequest method. +// req, resp := client.GetKnowledgeBaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/StartIngestionJob -func (c *BedrockAgent) StartIngestionJobRequest(input *StartIngestionJobInput) (req *request.Request, output *StartIngestionJobOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetKnowledgeBase +func (c *BedrockAgent) GetKnowledgeBaseRequest(input *GetKnowledgeBaseInput) (req *request.Request, output *GetKnowledgeBaseOutput) { op := &request.Operation{ - Name: opStartIngestionJob, - HTTPMethod: "PUT", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/", + Name: opGetKnowledgeBase, + HTTPMethod: "GET", + HTTPPath: "/knowledgebases/{knowledgeBaseId}", } if input == nil { - input = &StartIngestionJobInput{} + input = &GetKnowledgeBaseInput{} } - output = &StartIngestionJobOutput{} + output = &GetKnowledgeBaseOutput{} req = c.newRequest(op, input, output) return } -// StartIngestionJob API operation for Agents for Amazon Bedrock. +// GetKnowledgeBase API operation for Agents for Amazon Bedrock. // -// Begins an ingestion job, in which a data source is added to a knowledge base. +// Gets information about a knoweldge base. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation StartIngestionJob for usage and error information. +// API operation GetKnowledgeBase for usage and error information. // // Returned Error Types: // @@ -3502,80 +3208,74 @@ func (c *BedrockAgent) StartIngestionJobRequest(input *StartIngestionJobInput) ( // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/StartIngestionJob -func (c *BedrockAgent) StartIngestionJob(input *StartIngestionJobInput) (*StartIngestionJobOutput, error) { - req, out := c.StartIngestionJobRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetKnowledgeBase +func (c *BedrockAgent) GetKnowledgeBase(input *GetKnowledgeBaseInput) (*GetKnowledgeBaseOutput, error) { + req, out := c.GetKnowledgeBaseRequest(input) return out, req.Send() } -// StartIngestionJobWithContext is the same as StartIngestionJob with the addition of +// GetKnowledgeBaseWithContext is the same as GetKnowledgeBase with the addition of // the ability to pass a context and additional request options. // -// See StartIngestionJob for details on how to use this API operation. +// See GetKnowledgeBase for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) StartIngestionJobWithContext(ctx aws.Context, input *StartIngestionJobInput, opts ...request.Option) (*StartIngestionJobOutput, error) { - req, out := c.StartIngestionJobRequest(input) +func (c *BedrockAgent) GetKnowledgeBaseWithContext(ctx aws.Context, input *GetKnowledgeBaseInput, opts ...request.Option) (*GetKnowledgeBaseOutput, error) { + req, out := c.GetKnowledgeBaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opTagResource = "TagResource" +const opGetPrompt = "GetPrompt" -// TagResourceRequest generates a "aws/request.Request" representing the -// client's request for the TagResource operation. The "output" return +// GetPromptRequest generates a "aws/request.Request" representing the +// client's request for the GetPrompt operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See TagResource for more information on using the TagResource +// See GetPrompt for more information on using the GetPrompt // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the TagResourceRequest method. -// req, resp := client.TagResourceRequest(params) +// // Example sending a request using the GetPromptRequest method. +// req, resp := client.GetPromptRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/TagResource -func (c *BedrockAgent) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetPrompt +func (c *BedrockAgent) GetPromptRequest(input *GetPromptInput) (req *request.Request, output *GetPromptOutput) { op := &request.Operation{ - Name: opTagResource, - HTTPMethod: "POST", - HTTPPath: "/tags/{resourceArn}", + Name: opGetPrompt, + HTTPMethod: "GET", + HTTPPath: "/prompts/{promptIdentifier}/", } if input == nil { - input = &TagResourceInput{} + input = &GetPromptInput{} } - output = &TagResourceOutput{} + output = &GetPromptOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// TagResource API operation for Agents for Amazon Bedrock. +// GetPrompt API operation for Agents for Amazon Bedrock. // -// Associate tags with a resource. For more information, see Tagging resources -// (https://docs.aws.amazon.com/bedrock/latest/userguide/what-is-service.html) +// Retrieves information about a prompt or a version of it. For more information, +// see View information about prompts using Prompt management (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-manage.html#prompt-management-view.html) +// and View information about a version of your prompt (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-deploy.html#prompt-management-versions-view.html) // in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3583,7 +3283,7 @@ func (c *BedrockAgent) TagResourceRequest(input *TagResourceInput) (req *request // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation TagResource for usage and error information. +// API operation GetPrompt for usage and error information. // // Returned Error Types: // @@ -3603,83 +3303,85 @@ func (c *BedrockAgent) TagResourceRequest(input *TagResourceInput) (req *request // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/TagResource -func (c *BedrockAgent) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetPrompt +func (c *BedrockAgent) GetPrompt(input *GetPromptInput) (*GetPromptOutput, error) { + req, out := c.GetPromptRequest(input) return out, req.Send() } -// TagResourceWithContext is the same as TagResource with the addition of +// GetPromptWithContext is the same as GetPrompt with the addition of // the ability to pass a context and additional request options. // -// See TagResource for details on how to use this API operation. +// See GetPrompt for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +func (c *BedrockAgent) GetPromptWithContext(ctx aws.Context, input *GetPromptInput, opts ...request.Option) (*GetPromptOutput, error) { + req, out := c.GetPromptRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUntagResource = "UntagResource" +const opListAgentActionGroups = "ListAgentActionGroups" -// UntagResourceRequest generates a "aws/request.Request" representing the -// client's request for the UntagResource operation. The "output" return +// ListAgentActionGroupsRequest generates a "aws/request.Request" representing the +// client's request for the ListAgentActionGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UntagResource for more information on using the UntagResource +// See ListAgentActionGroups for more information on using the ListAgentActionGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UntagResourceRequest method. -// req, resp := client.UntagResourceRequest(params) +// // Example sending a request using the ListAgentActionGroupsRequest method. +// req, resp := client.ListAgentActionGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UntagResource -func (c *BedrockAgent) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentActionGroups +func (c *BedrockAgent) ListAgentActionGroupsRequest(input *ListAgentActionGroupsInput) (req *request.Request, output *ListAgentActionGroupsOutput) { op := &request.Operation{ - Name: opUntagResource, - HTTPMethod: "DELETE", - HTTPPath: "/tags/{resourceArn}", + Name: opListAgentActionGroups, + HTTPMethod: "POST", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UntagResourceInput{} + input = &ListAgentActionGroupsInput{} } - output = &UntagResourceOutput{} + output = &ListAgentActionGroupsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// UntagResource API operation for Agents for Amazon Bedrock. +// ListAgentActionGroups API operation for Agents for Amazon Bedrock. // -// Remove tags from a resource. +// Lists the action groups for an agent and information about each one. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UntagResource for usage and error information. +// API operation ListAgentActionGroups for usage and error information. // // Returned Error Types: // @@ -3699,79 +3401,136 @@ func (c *BedrockAgent) UntagResourceRequest(input *UntagResourceInput) (req *req // The specified resource Amazon Resource Name (ARN) was not found. Check the // Amazon Resource Name (ARN) and try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UntagResource -func (c *BedrockAgent) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentActionGroups +func (c *BedrockAgent) ListAgentActionGroups(input *ListAgentActionGroupsInput) (*ListAgentActionGroupsOutput, error) { + req, out := c.ListAgentActionGroupsRequest(input) return out, req.Send() } -// UntagResourceWithContext is the same as UntagResource with the addition of +// ListAgentActionGroupsWithContext is the same as ListAgentActionGroups with the addition of // the ability to pass a context and additional request options. // -// See UntagResource for details on how to use this API operation. +// See ListAgentActionGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +func (c *BedrockAgent) ListAgentActionGroupsWithContext(ctx aws.Context, input *ListAgentActionGroupsInput, opts ...request.Option) (*ListAgentActionGroupsOutput, error) { + req, out := c.ListAgentActionGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateAgent = "UpdateAgent" +// ListAgentActionGroupsPages iterates over the pages of a ListAgentActionGroups operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAgentActionGroups method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAgentActionGroups operation. +// pageNum := 0 +// err := client.ListAgentActionGroupsPages(params, +// func(page *bedrockagent.ListAgentActionGroupsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListAgentActionGroupsPages(input *ListAgentActionGroupsInput, fn func(*ListAgentActionGroupsOutput, bool) bool) error { + return c.ListAgentActionGroupsPagesWithContext(aws.BackgroundContext(), input, fn) +} -// UpdateAgentRequest generates a "aws/request.Request" representing the -// client's request for the UpdateAgent operation. The "output" return +// ListAgentActionGroupsPagesWithContext same as ListAgentActionGroupsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListAgentActionGroupsPagesWithContext(ctx aws.Context, input *ListAgentActionGroupsInput, fn func(*ListAgentActionGroupsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAgentActionGroupsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAgentActionGroupsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListAgentActionGroupsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListAgentAliases = "ListAgentAliases" + +// ListAgentAliasesRequest generates a "aws/request.Request" representing the +// client's request for the ListAgentAliases operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateAgent for more information on using the UpdateAgent +// See ListAgentAliases for more information on using the ListAgentAliases // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateAgentRequest method. -// req, resp := client.UpdateAgentRequest(params) +// // Example sending a request using the ListAgentAliasesRequest method. +// req, resp := client.ListAgentAliasesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgent -func (c *BedrockAgent) UpdateAgentRequest(input *UpdateAgentInput) (req *request.Request, output *UpdateAgentOutput) { - op := &request.Operation{ - Name: opUpdateAgent, - HTTPMethod: "PUT", - HTTPPath: "/agents/{agentId}/", +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentAliases +func (c *BedrockAgent) ListAgentAliasesRequest(input *ListAgentAliasesInput) (req *request.Request, output *ListAgentAliasesOutput) { + op := &request.Operation{ + Name: opListAgentAliases, + HTTPMethod: "POST", + HTTPPath: "/agents/{agentId}/agentaliases/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateAgentInput{} + input = &ListAgentAliasesInput{} } - output = &UpdateAgentOutput{} + output = &ListAgentAliasesOutput{} req = c.newRequest(op, input, output) return } -// UpdateAgent API operation for Agents for Amazon Bedrock. +// ListAgentAliases API operation for Agents for Amazon Bedrock. // -// Updates the configuration of an agent. +// Lists the aliases of an agent and information about each one. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateAgent for usage and error information. +// API operation ListAgentAliases for usage and error information. // // Returned Error Types: // @@ -3791,85 +3550,137 @@ func (c *BedrockAgent) UpdateAgentRequest(input *UpdateAgentInput) (req *request // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgent -func (c *BedrockAgent) UpdateAgent(input *UpdateAgentInput) (*UpdateAgentOutput, error) { - req, out := c.UpdateAgentRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentAliases +func (c *BedrockAgent) ListAgentAliases(input *ListAgentAliasesInput) (*ListAgentAliasesOutput, error) { + req, out := c.ListAgentAliasesRequest(input) return out, req.Send() } -// UpdateAgentWithContext is the same as UpdateAgent with the addition of +// ListAgentAliasesWithContext is the same as ListAgentAliases with the addition of // the ability to pass a context and additional request options. // -// See UpdateAgent for details on how to use this API operation. +// See ListAgentAliases for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateAgentWithContext(ctx aws.Context, input *UpdateAgentInput, opts ...request.Option) (*UpdateAgentOutput, error) { - req, out := c.UpdateAgentRequest(input) +func (c *BedrockAgent) ListAgentAliasesWithContext(ctx aws.Context, input *ListAgentAliasesInput, opts ...request.Option) (*ListAgentAliasesOutput, error) { + req, out := c.ListAgentAliasesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateAgentActionGroup = "UpdateAgentActionGroup" +// ListAgentAliasesPages iterates over the pages of a ListAgentAliases operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAgentAliases method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAgentAliases operation. +// pageNum := 0 +// err := client.ListAgentAliasesPages(params, +// func(page *bedrockagent.ListAgentAliasesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListAgentAliasesPages(input *ListAgentAliasesInput, fn func(*ListAgentAliasesOutput, bool) bool) error { + return c.ListAgentAliasesPagesWithContext(aws.BackgroundContext(), input, fn) +} -// UpdateAgentActionGroupRequest generates a "aws/request.Request" representing the -// client's request for the UpdateAgentActionGroup operation. The "output" return +// ListAgentAliasesPagesWithContext same as ListAgentAliasesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListAgentAliasesPagesWithContext(ctx aws.Context, input *ListAgentAliasesInput, fn func(*ListAgentAliasesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAgentAliasesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAgentAliasesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListAgentAliasesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListAgentKnowledgeBases = "ListAgentKnowledgeBases" + +// ListAgentKnowledgeBasesRequest generates a "aws/request.Request" representing the +// client's request for the ListAgentKnowledgeBases operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateAgentActionGroup for more information on using the UpdateAgentActionGroup +// See ListAgentKnowledgeBases for more information on using the ListAgentKnowledgeBases // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateAgentActionGroupRequest method. -// req, resp := client.UpdateAgentActionGroupRequest(params) +// // Example sending a request using the ListAgentKnowledgeBasesRequest method. +// req, resp := client.ListAgentKnowledgeBasesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentActionGroup -func (c *BedrockAgent) UpdateAgentActionGroupRequest(input *UpdateAgentActionGroupInput) (req *request.Request, output *UpdateAgentActionGroupOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentKnowledgeBases +func (c *BedrockAgent) ListAgentKnowledgeBasesRequest(input *ListAgentKnowledgeBasesInput) (req *request.Request, output *ListAgentKnowledgeBasesOutput) { op := &request.Operation{ - Name: opUpdateAgentActionGroup, - HTTPMethod: "PUT", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", + Name: opListAgentKnowledgeBases, + HTTPMethod: "POST", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateAgentActionGroupInput{} + input = &ListAgentKnowledgeBasesInput{} } - output = &UpdateAgentActionGroupOutput{} + output = &ListAgentKnowledgeBasesOutput{} req = c.newRequest(op, input, output) return } -// UpdateAgentActionGroup API operation for Agents for Amazon Bedrock. +// ListAgentKnowledgeBases API operation for Agents for Amazon Bedrock. // -// Updates the configuration for an action group for an agent. +// Lists knowledge bases associated with an agent and information about each +// one. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateAgentActionGroup for usage and error information. +// API operation ListAgentKnowledgeBases for usage and error information. // // Returned Error Types: // @@ -3889,85 +3700,136 @@ func (c *BedrockAgent) UpdateAgentActionGroupRequest(input *UpdateAgentActionGro // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentActionGroup -func (c *BedrockAgent) UpdateAgentActionGroup(input *UpdateAgentActionGroupInput) (*UpdateAgentActionGroupOutput, error) { - req, out := c.UpdateAgentActionGroupRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentKnowledgeBases +func (c *BedrockAgent) ListAgentKnowledgeBases(input *ListAgentKnowledgeBasesInput) (*ListAgentKnowledgeBasesOutput, error) { + req, out := c.ListAgentKnowledgeBasesRequest(input) return out, req.Send() } -// UpdateAgentActionGroupWithContext is the same as UpdateAgentActionGroup with the addition of +// ListAgentKnowledgeBasesWithContext is the same as ListAgentKnowledgeBases with the addition of // the ability to pass a context and additional request options. // -// See UpdateAgentActionGroup for details on how to use this API operation. +// See ListAgentKnowledgeBases for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateAgentActionGroupWithContext(ctx aws.Context, input *UpdateAgentActionGroupInput, opts ...request.Option) (*UpdateAgentActionGroupOutput, error) { - req, out := c.UpdateAgentActionGroupRequest(input) +func (c *BedrockAgent) ListAgentKnowledgeBasesWithContext(ctx aws.Context, input *ListAgentKnowledgeBasesInput, opts ...request.Option) (*ListAgentKnowledgeBasesOutput, error) { + req, out := c.ListAgentKnowledgeBasesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateAgentAlias = "UpdateAgentAlias" +// ListAgentKnowledgeBasesPages iterates over the pages of a ListAgentKnowledgeBases operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAgentKnowledgeBases method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAgentKnowledgeBases operation. +// pageNum := 0 +// err := client.ListAgentKnowledgeBasesPages(params, +// func(page *bedrockagent.ListAgentKnowledgeBasesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListAgentKnowledgeBasesPages(input *ListAgentKnowledgeBasesInput, fn func(*ListAgentKnowledgeBasesOutput, bool) bool) error { + return c.ListAgentKnowledgeBasesPagesWithContext(aws.BackgroundContext(), input, fn) +} -// UpdateAgentAliasRequest generates a "aws/request.Request" representing the -// client's request for the UpdateAgentAlias operation. The "output" return +// ListAgentKnowledgeBasesPagesWithContext same as ListAgentKnowledgeBasesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListAgentKnowledgeBasesPagesWithContext(ctx aws.Context, input *ListAgentKnowledgeBasesInput, fn func(*ListAgentKnowledgeBasesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAgentKnowledgeBasesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAgentKnowledgeBasesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListAgentKnowledgeBasesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListAgentVersions = "ListAgentVersions" + +// ListAgentVersionsRequest generates a "aws/request.Request" representing the +// client's request for the ListAgentVersions operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateAgentAlias for more information on using the UpdateAgentAlias +// See ListAgentVersions for more information on using the ListAgentVersions // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateAgentAliasRequest method. -// req, resp := client.UpdateAgentAliasRequest(params) +// // Example sending a request using the ListAgentVersionsRequest method. +// req, resp := client.ListAgentVersionsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentAlias -func (c *BedrockAgent) UpdateAgentAliasRequest(input *UpdateAgentAliasInput) (req *request.Request, output *UpdateAgentAliasOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentVersions +func (c *BedrockAgent) ListAgentVersionsRequest(input *ListAgentVersionsInput) (req *request.Request, output *ListAgentVersionsOutput) { op := &request.Operation{ - Name: opUpdateAgentAlias, - HTTPMethod: "PUT", - HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", + Name: opListAgentVersions, + HTTPMethod: "POST", + HTTPPath: "/agents/{agentId}/agentversions/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateAgentAliasInput{} + input = &ListAgentVersionsInput{} } - output = &UpdateAgentAliasOutput{} + output = &ListAgentVersionsOutput{} req = c.newRequest(op, input, output) return } -// UpdateAgentAlias API operation for Agents for Amazon Bedrock. +// ListAgentVersions API operation for Agents for Amazon Bedrock. // -// Updates configurations for an alias of an agent. +// Lists the versions of an agent and information about each version. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateAgentAlias for usage and error information. +// API operation ListAgentVersions for usage and error information. // // Returned Error Types: // @@ -3987,86 +3849,136 @@ func (c *BedrockAgent) UpdateAgentAliasRequest(input *UpdateAgentAliasInput) (re // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentAlias -func (c *BedrockAgent) UpdateAgentAlias(input *UpdateAgentAliasInput) (*UpdateAgentAliasOutput, error) { - req, out := c.UpdateAgentAliasRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentVersions +func (c *BedrockAgent) ListAgentVersions(input *ListAgentVersionsInput) (*ListAgentVersionsOutput, error) { + req, out := c.ListAgentVersionsRequest(input) return out, req.Send() } -// UpdateAgentAliasWithContext is the same as UpdateAgentAlias with the addition of +// ListAgentVersionsWithContext is the same as ListAgentVersions with the addition of // the ability to pass a context and additional request options. // -// See UpdateAgentAlias for details on how to use this API operation. +// See ListAgentVersions for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateAgentAliasWithContext(ctx aws.Context, input *UpdateAgentAliasInput, opts ...request.Option) (*UpdateAgentAliasOutput, error) { - req, out := c.UpdateAgentAliasRequest(input) +func (c *BedrockAgent) ListAgentVersionsWithContext(ctx aws.Context, input *ListAgentVersionsInput, opts ...request.Option) (*ListAgentVersionsOutput, error) { + req, out := c.ListAgentVersionsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateAgentKnowledgeBase = "UpdateAgentKnowledgeBase" +// ListAgentVersionsPages iterates over the pages of a ListAgentVersions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAgentVersions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAgentVersions operation. +// pageNum := 0 +// err := client.ListAgentVersionsPages(params, +// func(page *bedrockagent.ListAgentVersionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListAgentVersionsPages(input *ListAgentVersionsInput, fn func(*ListAgentVersionsOutput, bool) bool) error { + return c.ListAgentVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +} -// UpdateAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the UpdateAgentKnowledgeBase operation. The "output" return +// ListAgentVersionsPagesWithContext same as ListAgentVersionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListAgentVersionsPagesWithContext(ctx aws.Context, input *ListAgentVersionsInput, fn func(*ListAgentVersionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAgentVersionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAgentVersionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListAgentVersionsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListAgents = "ListAgents" + +// ListAgentsRequest generates a "aws/request.Request" representing the +// client's request for the ListAgents operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateAgentKnowledgeBase for more information on using the UpdateAgentKnowledgeBase +// See ListAgents for more information on using the ListAgents // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateAgentKnowledgeBaseRequest method. -// req, resp := client.UpdateAgentKnowledgeBaseRequest(params) +// // Example sending a request using the ListAgentsRequest method. +// req, resp := client.ListAgentsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentKnowledgeBase -func (c *BedrockAgent) UpdateAgentKnowledgeBaseRequest(input *UpdateAgentKnowledgeBaseInput) (req *request.Request, output *UpdateAgentKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgents +func (c *BedrockAgent) ListAgentsRequest(input *ListAgentsInput) (req *request.Request, output *ListAgentsOutput) { op := &request.Operation{ - Name: opUpdateAgentKnowledgeBase, - HTTPMethod: "PUT", - HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", + Name: opListAgents, + HTTPMethod: "POST", + HTTPPath: "/agents/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateAgentKnowledgeBaseInput{} + input = &ListAgentsInput{} } - output = &UpdateAgentKnowledgeBaseOutput{} + output = &ListAgentsOutput{} req = c.newRequest(op, input, output) return } -// UpdateAgentKnowledgeBase API operation for Agents for Amazon Bedrock. +// ListAgents API operation for Agents for Amazon Bedrock. // -// Updates the configuration for a knowledge base that has been associated with -// an agent. +// Lists the agents belonging to an account and information about each agent. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateAgentKnowledgeBase for usage and error information. +// API operation ListAgents for usage and error information. // // Returned Error Types: // @@ -4082,89 +3994,136 @@ func (c *BedrockAgent) UpdateAgentKnowledgeBaseRequest(input *UpdateAgentKnowled // - 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentKnowledgeBase -func (c *BedrockAgent) UpdateAgentKnowledgeBase(input *UpdateAgentKnowledgeBaseInput) (*UpdateAgentKnowledgeBaseOutput, error) { - req, out := c.UpdateAgentKnowledgeBaseRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgents +func (c *BedrockAgent) ListAgents(input *ListAgentsInput) (*ListAgentsOutput, error) { + req, out := c.ListAgentsRequest(input) return out, req.Send() } -// UpdateAgentKnowledgeBaseWithContext is the same as UpdateAgentKnowledgeBase with the addition of +// ListAgentsWithContext is the same as ListAgents with the addition of // the ability to pass a context and additional request options. // -// See UpdateAgentKnowledgeBase for details on how to use this API operation. +// See ListAgents for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateAgentKnowledgeBaseWithContext(ctx aws.Context, input *UpdateAgentKnowledgeBaseInput, opts ...request.Option) (*UpdateAgentKnowledgeBaseOutput, error) { - req, out := c.UpdateAgentKnowledgeBaseRequest(input) +func (c *BedrockAgent) ListAgentsWithContext(ctx aws.Context, input *ListAgentsInput, opts ...request.Option) (*ListAgentsOutput, error) { + req, out := c.ListAgentsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateDataSource = "UpdateDataSource" +// ListAgentsPages iterates over the pages of a ListAgents operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAgents method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAgents operation. +// pageNum := 0 +// err := client.ListAgentsPages(params, +// func(page *bedrockagent.ListAgentsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListAgentsPages(input *ListAgentsInput, fn func(*ListAgentsOutput, bool) bool) error { + return c.ListAgentsPagesWithContext(aws.BackgroundContext(), input, fn) +} -// UpdateDataSourceRequest generates a "aws/request.Request" representing the -// client's request for the UpdateDataSource operation. The "output" return +// ListAgentsPagesWithContext same as ListAgentsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListAgentsPagesWithContext(ctx aws.Context, input *ListAgentsInput, fn func(*ListAgentsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAgentsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAgentsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListAgentsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListDataSources = "ListDataSources" + +// ListDataSourcesRequest generates a "aws/request.Request" representing the +// client's request for the ListDataSources operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateDataSource for more information on using the UpdateDataSource +// See ListDataSources for more information on using the ListDataSources // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateDataSourceRequest method. -// req, resp := client.UpdateDataSourceRequest(params) +// // Example sending a request using the ListDataSourcesRequest method. +// req, resp := client.ListDataSourcesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateDataSource -func (c *BedrockAgent) UpdateDataSourceRequest(input *UpdateDataSourceInput) (req *request.Request, output *UpdateDataSourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListDataSources +func (c *BedrockAgent) ListDataSourcesRequest(input *ListDataSourcesInput) (req *request.Request, output *ListDataSourcesOutput) { op := &request.Operation{ - Name: opUpdateDataSource, - HTTPMethod: "PUT", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", + Name: opListDataSources, + HTTPMethod: "POST", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateDataSourceInput{} + input = &ListDataSourcesInput{} } - output = &UpdateDataSourceOutput{} + output = &ListDataSourcesOutput{} req = c.newRequest(op, input, output) return } -// UpdateDataSource API operation for Agents for Amazon Bedrock. -// -// Updates configurations for a data source. +// ListDataSources API operation for Agents for Amazon Bedrock. // -// You can't change the chunkingConfiguration after you create the data source. -// Specify the existing chunkingConfiguration. +// Lists the data sources in a knowledge base and information about each one. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateDataSource for usage and error information. +// API operation ListDataSources for usage and error information. // // Returned Error Types: // @@ -4184,97 +4143,136 @@ func (c *BedrockAgent) UpdateDataSourceRequest(input *UpdateDataSourceInput) (re // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateDataSource -func (c *BedrockAgent) UpdateDataSource(input *UpdateDataSourceInput) (*UpdateDataSourceOutput, error) { - req, out := c.UpdateDataSourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListDataSources +func (c *BedrockAgent) ListDataSources(input *ListDataSourcesInput) (*ListDataSourcesOutput, error) { + req, out := c.ListDataSourcesRequest(input) return out, req.Send() } -// UpdateDataSourceWithContext is the same as UpdateDataSource with the addition of +// ListDataSourcesWithContext is the same as ListDataSources with the addition of // the ability to pass a context and additional request options. // -// See UpdateDataSource for details on how to use this API operation. +// See ListDataSources for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateDataSourceWithContext(ctx aws.Context, input *UpdateDataSourceInput, opts ...request.Option) (*UpdateDataSourceOutput, error) { - req, out := c.UpdateDataSourceRequest(input) +func (c *BedrockAgent) ListDataSourcesWithContext(ctx aws.Context, input *ListDataSourcesInput, opts ...request.Option) (*ListDataSourcesOutput, error) { + req, out := c.ListDataSourcesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateKnowledgeBase = "UpdateKnowledgeBase" - -// UpdateKnowledgeBaseRequest generates a "aws/request.Request" representing the -// client's request for the UpdateKnowledgeBase operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. +// ListDataSourcesPages iterates over the pages of a ListDataSources operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. // -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. +// See ListDataSources method for more information on how to use this operation. // -// See UpdateKnowledgeBase for more information on using the UpdateKnowledgeBase -// API call, and error handling. +// Note: This operation can generate multiple requests to a service. // -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// // Example iterating over at most 3 pages of a ListDataSources operation. +// pageNum := 0 +// err := client.ListDataSourcesPages(params, +// func(page *bedrockagent.ListDataSourcesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListDataSourcesPages(input *ListDataSourcesInput, fn func(*ListDataSourcesOutput, bool) bool) error { + return c.ListDataSourcesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListDataSourcesPagesWithContext same as ListDataSourcesPages except +// it takes a Context and allows setting request options on the pages. // -// // Example sending a request using the UpdateKnowledgeBaseRequest method. -// req, resp := client.UpdateKnowledgeBaseRequest(params) +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListDataSourcesPagesWithContext(ctx aws.Context, input *ListDataSourcesInput, fn func(*ListDataSourcesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListDataSourcesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListDataSourcesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListDataSourcesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListFlowAliases = "ListFlowAliases" + +// ListFlowAliasesRequest generates a "aws/request.Request" representing the +// client's request for the ListFlowAliases operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListFlowAliases for more information on using the ListFlowAliases +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListFlowAliasesRequest method. +// req, resp := client.ListFlowAliasesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateKnowledgeBase -func (c *BedrockAgent) UpdateKnowledgeBaseRequest(input *UpdateKnowledgeBaseInput) (req *request.Request, output *UpdateKnowledgeBaseOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlowAliases +func (c *BedrockAgent) ListFlowAliasesRequest(input *ListFlowAliasesInput) (req *request.Request, output *ListFlowAliasesOutput) { op := &request.Operation{ - Name: opUpdateKnowledgeBase, - HTTPMethod: "PUT", - HTTPPath: "/knowledgebases/{knowledgeBaseId}", + Name: opListFlowAliases, + HTTPMethod: "GET", + HTTPPath: "/flows/{flowIdentifier}/aliases", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateKnowledgeBaseInput{} + input = &ListFlowAliasesInput{} } - output = &UpdateKnowledgeBaseOutput{} + output = &ListFlowAliasesOutput{} req = c.newRequest(op, input, output) return } -// UpdateKnowledgeBase API operation for Agents for Amazon Bedrock. -// -// 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 +// ListFlowAliases API operation for Agents for Amazon Bedrock. // -// 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetKnowledgeBase.html) -// request and copy the same configurations. +// Returns a list of aliases for a flow. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock's -// API operation UpdateKnowledgeBase for usage and error information. +// API operation ListFlowAliases for usage and error information. // // Returned Error Types: // @@ -4294,173 +4292,10763 @@ func (c *BedrockAgent) UpdateKnowledgeBaseRequest(input *UpdateKnowledgeBaseInpu // 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. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateKnowledgeBase -func (c *BedrockAgent) UpdateKnowledgeBase(input *UpdateKnowledgeBaseInput) (*UpdateKnowledgeBaseOutput, error) { - req, out := c.UpdateKnowledgeBaseRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlowAliases +func (c *BedrockAgent) ListFlowAliases(input *ListFlowAliasesInput) (*ListFlowAliasesOutput, error) { + req, out := c.ListFlowAliasesRequest(input) return out, req.Send() } -// UpdateKnowledgeBaseWithContext is the same as UpdateKnowledgeBase with the addition of +// ListFlowAliasesWithContext is the same as ListFlowAliases with the addition of // the ability to pass a context and additional request options. // -// See UpdateKnowledgeBase for details on how to use this API operation. +// See ListFlowAliases for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgent) UpdateKnowledgeBaseWithContext(ctx aws.Context, input *UpdateKnowledgeBaseInput, opts ...request.Option) (*UpdateKnowledgeBaseOutput, error) { - req, out := c.UpdateKnowledgeBaseRequest(input) +func (c *BedrockAgent) ListFlowAliasesWithContext(ctx aws.Context, input *ListFlowAliasesInput, opts ...request.Option) (*ListFlowAliasesOutput, error) { + req, out := c.ListFlowAliasesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// Contains details about the OpenAPI schema for the action group. For more -// information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). -// 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. -type APISchema struct { - _ struct{} `type:"structure"` - - // The JSON or YAML-formatted payload defining the OpenAPI schema for the action - // group. For more information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). - // - // Payload is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by APISchema's - // String and GoString methods. - Payload *string `locationName:"payload" type:"string" sensitive:"true"` - - // Contains details about the S3 object containing the OpenAPI schema for the - // action group. For more information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). - S3 *S3Identifier `locationName:"s3" type:"structure"` -} - -// String returns the string representation. +// ListFlowAliasesPages iterates over the pages of a ListFlowAliases operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s APISchema) String() string { - return awsutil.Prettify(s) +// See ListFlowAliases method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListFlowAliases operation. +// pageNum := 0 +// err := client.ListFlowAliasesPages(params, +// func(page *bedrockagent.ListFlowAliasesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListFlowAliasesPages(input *ListFlowAliasesInput, fn func(*ListFlowAliasesOutput, bool) bool) error { + return c.ListFlowAliasesPagesWithContext(aws.BackgroundContext(), input, fn) } -// GoString returns the string representation. +// ListFlowAliasesPagesWithContext same as ListFlowAliasesPages except +// it takes a Context and allows setting request options on the pages. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s APISchema) GoString() string { - return s.String() -} +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListFlowAliasesPagesWithContext(ctx aws.Context, input *ListFlowAliasesInput, fn func(*ListFlowAliasesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListFlowAliasesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListFlowAliasesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } -// Validate inspects the fields of the type to determine if they are valid. -func (s *APISchema) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "APISchema"} - if s.S3 != nil { - if err := s.S3.Validate(); err != nil { - invalidParams.AddNested("S3", err.(request.ErrInvalidParams)) + for p.Next() { + if !fn(p.Page().(*ListFlowAliasesOutput), !p.HasNextPage()) { + break } } - if invalidParams.Len() > 0 { - return invalidParams - } - return nil + return p.Err() } -// SetPayload sets the Payload field's value. -func (s *APISchema) SetPayload(v string) *APISchema { - s.Payload = &v - return s -} +const opListFlowVersions = "ListFlowVersions" -// SetS3 sets the S3 field's value. -func (s *APISchema) SetS3(v *S3Identifier) *APISchema { - s.S3 = v - return s -} +// ListFlowVersionsRequest generates a "aws/request.Request" representing the +// client's request for the ListFlowVersions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListFlowVersions for more information on using the ListFlowVersions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListFlowVersionsRequest method. +// req, resp := client.ListFlowVersionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlowVersions +func (c *BedrockAgent) ListFlowVersionsRequest(input *ListFlowVersionsInput) (req *request.Request, output *ListFlowVersionsOutput) { + op := &request.Operation{ + Name: opListFlowVersions, + HTTPMethod: "GET", + HTTPPath: "/flows/{flowIdentifier}/versions", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } -// The request is denied because of missing access permissions. -type AccessDeniedException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + if input == nil { + input = &ListFlowVersionsInput{} + } - Message_ *string `locationName:"message" type:"string"` + output = &ListFlowVersionsOutput{} + req = c.newRequest(op, input, output) + return } -// String returns the string representation. +// ListFlowVersions API operation for Agents for Amazon Bedrock. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AccessDeniedException) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. +// Returns a list of information about each flow. For more information, see +// Deploy a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AccessDeniedException) GoString() string { - return s.String() +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListFlowVersions for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlowVersions +func (c *BedrockAgent) ListFlowVersions(input *ListFlowVersionsInput) (*ListFlowVersionsOutput, error) { + req, out := c.ListFlowVersionsRequest(input) + return out, req.Send() } -func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { - return &AccessDeniedException{ - RespMetadata: v, - } +// ListFlowVersionsWithContext is the same as ListFlowVersions with the addition of +// the ability to pass a context and additional request options. +// +// See ListFlowVersions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListFlowVersionsWithContext(ctx aws.Context, input *ListFlowVersionsInput, opts ...request.Option) (*ListFlowVersionsOutput, error) { + req, out := c.ListFlowVersionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } -// Code returns the exception type name. +// ListFlowVersionsPages iterates over the pages of a ListFlowVersions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListFlowVersions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListFlowVersions operation. +// pageNum := 0 +// err := client.ListFlowVersionsPages(params, +// func(page *bedrockagent.ListFlowVersionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListFlowVersionsPages(input *ListFlowVersionsInput, fn func(*ListFlowVersionsOutput, bool) bool) error { + return c.ListFlowVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListFlowVersionsPagesWithContext same as ListFlowVersionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListFlowVersionsPagesWithContext(ctx aws.Context, input *ListFlowVersionsInput, fn func(*ListFlowVersionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListFlowVersionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListFlowVersionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListFlowVersionsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListFlows = "ListFlows" + +// ListFlowsRequest generates a "aws/request.Request" representing the +// client's request for the ListFlows operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListFlows for more information on using the ListFlows +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListFlowsRequest method. +// req, resp := client.ListFlowsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlows +func (c *BedrockAgent) ListFlowsRequest(input *ListFlowsInput) (req *request.Request, output *ListFlowsOutput) { + op := &request.Operation{ + Name: opListFlows, + HTTPMethod: "GET", + HTTPPath: "/flows/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListFlowsInput{} + } + + output = &ListFlowsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListFlows API operation for Agents for Amazon Bedrock. +// +// Returns a list of flows and information about each flow. For more information, +// see Manage a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-manage.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListFlows for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListFlows +func (c *BedrockAgent) ListFlows(input *ListFlowsInput) (*ListFlowsOutput, error) { + req, out := c.ListFlowsRequest(input) + return out, req.Send() +} + +// ListFlowsWithContext is the same as ListFlows with the addition of +// the ability to pass a context and additional request options. +// +// See ListFlows for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListFlowsWithContext(ctx aws.Context, input *ListFlowsInput, opts ...request.Option) (*ListFlowsOutput, error) { + req, out := c.ListFlowsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListFlowsPages iterates over the pages of a ListFlows operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListFlows method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListFlows operation. +// pageNum := 0 +// err := client.ListFlowsPages(params, +// func(page *bedrockagent.ListFlowsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListFlowsPages(input *ListFlowsInput, fn func(*ListFlowsOutput, bool) bool) error { + return c.ListFlowsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListFlowsPagesWithContext same as ListFlowsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListFlowsPagesWithContext(ctx aws.Context, input *ListFlowsInput, fn func(*ListFlowsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListFlowsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListFlowsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListFlowsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListIngestionJobs = "ListIngestionJobs" + +// ListIngestionJobsRequest generates a "aws/request.Request" representing the +// client's request for the ListIngestionJobs operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListIngestionJobs for more information on using the ListIngestionJobs +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListIngestionJobsRequest method. +// req, resp := client.ListIngestionJobsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListIngestionJobs +func (c *BedrockAgent) ListIngestionJobsRequest(input *ListIngestionJobsInput) (req *request.Request, output *ListIngestionJobsOutput) { + op := &request.Operation{ + Name: opListIngestionJobs, + HTTPMethod: "POST", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListIngestionJobsInput{} + } + + output = &ListIngestionJobsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListIngestionJobs API operation for Agents for Amazon Bedrock. +// +// Lists the ingestion jobs for a data source and information about each of +// them. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListIngestionJobs for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListIngestionJobs +func (c *BedrockAgent) ListIngestionJobs(input *ListIngestionJobsInput) (*ListIngestionJobsOutput, error) { + req, out := c.ListIngestionJobsRequest(input) + return out, req.Send() +} + +// ListIngestionJobsWithContext is the same as ListIngestionJobs with the addition of +// the ability to pass a context and additional request options. +// +// See ListIngestionJobs for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListIngestionJobsWithContext(ctx aws.Context, input *ListIngestionJobsInput, opts ...request.Option) (*ListIngestionJobsOutput, error) { + req, out := c.ListIngestionJobsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListIngestionJobsPages iterates over the pages of a ListIngestionJobs operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListIngestionJobs method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListIngestionJobs operation. +// pageNum := 0 +// err := client.ListIngestionJobsPages(params, +// func(page *bedrockagent.ListIngestionJobsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListIngestionJobsPages(input *ListIngestionJobsInput, fn func(*ListIngestionJobsOutput, bool) bool) error { + return c.ListIngestionJobsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListIngestionJobsPagesWithContext same as ListIngestionJobsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListIngestionJobsPagesWithContext(ctx aws.Context, input *ListIngestionJobsInput, fn func(*ListIngestionJobsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListIngestionJobsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListIngestionJobsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListIngestionJobsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListKnowledgeBases = "ListKnowledgeBases" + +// ListKnowledgeBasesRequest generates a "aws/request.Request" representing the +// client's request for the ListKnowledgeBases operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListKnowledgeBases for more information on using the ListKnowledgeBases +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListKnowledgeBasesRequest method. +// req, resp := client.ListKnowledgeBasesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListKnowledgeBases +func (c *BedrockAgent) ListKnowledgeBasesRequest(input *ListKnowledgeBasesInput) (req *request.Request, output *ListKnowledgeBasesOutput) { + op := &request.Operation{ + Name: opListKnowledgeBases, + HTTPMethod: "POST", + HTTPPath: "/knowledgebases/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListKnowledgeBasesInput{} + } + + output = &ListKnowledgeBasesOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListKnowledgeBases API operation for Agents for Amazon Bedrock. +// +// Lists the knowledge bases in an account and information about each of them. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListKnowledgeBases for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListKnowledgeBases +func (c *BedrockAgent) ListKnowledgeBases(input *ListKnowledgeBasesInput) (*ListKnowledgeBasesOutput, error) { + req, out := c.ListKnowledgeBasesRequest(input) + return out, req.Send() +} + +// ListKnowledgeBasesWithContext is the same as ListKnowledgeBases with the addition of +// the ability to pass a context and additional request options. +// +// See ListKnowledgeBases for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListKnowledgeBasesWithContext(ctx aws.Context, input *ListKnowledgeBasesInput, opts ...request.Option) (*ListKnowledgeBasesOutput, error) { + req, out := c.ListKnowledgeBasesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListKnowledgeBasesPages iterates over the pages of a ListKnowledgeBases operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListKnowledgeBases method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListKnowledgeBases operation. +// pageNum := 0 +// err := client.ListKnowledgeBasesPages(params, +// func(page *bedrockagent.ListKnowledgeBasesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListKnowledgeBasesPages(input *ListKnowledgeBasesInput, fn func(*ListKnowledgeBasesOutput, bool) bool) error { + return c.ListKnowledgeBasesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListKnowledgeBasesPagesWithContext same as ListKnowledgeBasesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListKnowledgeBasesPagesWithContext(ctx aws.Context, input *ListKnowledgeBasesInput, fn func(*ListKnowledgeBasesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListKnowledgeBasesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListKnowledgeBasesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListKnowledgeBasesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListPrompts = "ListPrompts" + +// ListPromptsRequest generates a "aws/request.Request" representing the +// client's request for the ListPrompts operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListPrompts for more information on using the ListPrompts +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListPromptsRequest method. +// req, resp := client.ListPromptsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListPrompts +func (c *BedrockAgent) ListPromptsRequest(input *ListPromptsInput) (req *request.Request, output *ListPromptsOutput) { + op := &request.Operation{ + Name: opListPrompts, + HTTPMethod: "GET", + HTTPPath: "/prompts/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListPromptsInput{} + } + + output = &ListPromptsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListPrompts API operation for Agents for Amazon Bedrock. +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-manage.html#prompt-management-view.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListPrompts for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListPrompts +func (c *BedrockAgent) ListPrompts(input *ListPromptsInput) (*ListPromptsOutput, error) { + req, out := c.ListPromptsRequest(input) + return out, req.Send() +} + +// ListPromptsWithContext is the same as ListPrompts with the addition of +// the ability to pass a context and additional request options. +// +// See ListPrompts for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListPromptsWithContext(ctx aws.Context, input *ListPromptsInput, opts ...request.Option) (*ListPromptsOutput, error) { + req, out := c.ListPromptsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListPromptsPages iterates over the pages of a ListPrompts operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListPrompts method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListPrompts operation. +// pageNum := 0 +// err := client.ListPromptsPages(params, +// func(page *bedrockagent.ListPromptsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgent) ListPromptsPages(input *ListPromptsInput, fn func(*ListPromptsOutput, bool) bool) error { + return c.ListPromptsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListPromptsPagesWithContext same as ListPromptsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListPromptsPagesWithContext(ctx aws.Context, input *ListPromptsInput, fn func(*ListPromptsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListPromptsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListPromptsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListPromptsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListTagsForResource = "ListTagsForResource" + +// ListTagsForResourceRequest generates a "aws/request.Request" representing the +// client's request for the ListTagsForResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListTagsForResource for more information on using the ListTagsForResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListTagsForResourceRequest method. +// req, resp := client.ListTagsForResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListTagsForResource +func (c *BedrockAgent) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { + op := &request.Operation{ + Name: opListTagsForResource, + HTTPMethod: "GET", + HTTPPath: "/tags/{resourceArn}", + } + + if input == nil { + input = &ListTagsForResourceInput{} + } + + output = &ListTagsForResourceOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListTagsForResource API operation for Agents for Amazon Bedrock. +// +// List all the tags for the resource you specify. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation ListTagsForResource for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListTagsForResource +func (c *BedrockAgent) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + return out, req.Send() +} + +// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// the ability to pass a context and additional request options. +// +// See ListTagsForResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPrepareAgent = "PrepareAgent" + +// PrepareAgentRequest generates a "aws/request.Request" representing the +// client's request for the PrepareAgent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PrepareAgent for more information on using the PrepareAgent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the PrepareAgentRequest method. +// req, resp := client.PrepareAgentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareAgent +func (c *BedrockAgent) PrepareAgentRequest(input *PrepareAgentInput) (req *request.Request, output *PrepareAgentOutput) { + op := &request.Operation{ + Name: opPrepareAgent, + HTTPMethod: "POST", + HTTPPath: "/agents/{agentId}/", + } + + if input == nil { + input = &PrepareAgentInput{} + } + + output = &PrepareAgentOutput{} + req = c.newRequest(op, input, output) + return +} + +// PrepareAgent API operation for Agents for Amazon Bedrock. +// +// Creates a DRAFT version of the agent that can be used for internal testing. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation PrepareAgent for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareAgent +func (c *BedrockAgent) PrepareAgent(input *PrepareAgentInput) (*PrepareAgentOutput, error) { + req, out := c.PrepareAgentRequest(input) + return out, req.Send() +} + +// PrepareAgentWithContext is the same as PrepareAgent with the addition of +// the ability to pass a context and additional request options. +// +// See PrepareAgent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) PrepareAgentWithContext(ctx aws.Context, input *PrepareAgentInput, opts ...request.Option) (*PrepareAgentOutput, error) { + req, out := c.PrepareAgentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPrepareFlow = "PrepareFlow" + +// PrepareFlowRequest generates a "aws/request.Request" representing the +// client's request for the PrepareFlow operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PrepareFlow for more information on using the PrepareFlow +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the PrepareFlowRequest method. +// req, resp := client.PrepareFlowRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareFlow +func (c *BedrockAgent) PrepareFlowRequest(input *PrepareFlowInput) (req *request.Request, output *PrepareFlowOutput) { + op := &request.Operation{ + Name: opPrepareFlow, + HTTPMethod: "POST", + HTTPPath: "/flows/{flowIdentifier}/", + } + + if input == nil { + input = &PrepareFlowInput{} + } + + output = &PrepareFlowOutput{} + req = c.newRequest(op, input, output) + return +} + +// PrepareFlow API operation for Agents for Amazon Bedrock. +// +// Prepares the DRAFT version of a flow so that it can be invoked. For more +// information, see Test a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-test.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation PrepareFlow for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/PrepareFlow +func (c *BedrockAgent) PrepareFlow(input *PrepareFlowInput) (*PrepareFlowOutput, error) { + req, out := c.PrepareFlowRequest(input) + return out, req.Send() +} + +// PrepareFlowWithContext is the same as PrepareFlow with the addition of +// the ability to pass a context and additional request options. +// +// See PrepareFlow for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) PrepareFlowWithContext(ctx aws.Context, input *PrepareFlowInput, opts ...request.Option) (*PrepareFlowOutput, error) { + req, out := c.PrepareFlowRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStartIngestionJob = "StartIngestionJob" + +// StartIngestionJobRequest generates a "aws/request.Request" representing the +// client's request for the StartIngestionJob operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StartIngestionJob for more information on using the StartIngestionJob +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the StartIngestionJobRequest method. +// req, resp := client.StartIngestionJobRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/StartIngestionJob +func (c *BedrockAgent) StartIngestionJobRequest(input *StartIngestionJobInput) (req *request.Request, output *StartIngestionJobOutput) { + op := &request.Operation{ + Name: opStartIngestionJob, + HTTPMethod: "PUT", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}/ingestionjobs/", + } + + if input == nil { + input = &StartIngestionJobInput{} + } + + output = &StartIngestionJobOutput{} + req = c.newRequest(op, input, output) + return +} + +// StartIngestionJob API operation for Agents for Amazon Bedrock. +// +// Begins an ingestion job, in which a data source is added to a knowledge base. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation StartIngestionJob for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/StartIngestionJob +func (c *BedrockAgent) StartIngestionJob(input *StartIngestionJobInput) (*StartIngestionJobOutput, error) { + req, out := c.StartIngestionJobRequest(input) + return out, req.Send() +} + +// StartIngestionJobWithContext is the same as StartIngestionJob with the addition of +// the ability to pass a context and additional request options. +// +// See StartIngestionJob for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) StartIngestionJobWithContext(ctx aws.Context, input *StartIngestionJobInput, opts ...request.Option) (*StartIngestionJobOutput, error) { + req, out := c.StartIngestionJobRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opTagResource = "TagResource" + +// TagResourceRequest generates a "aws/request.Request" representing the +// client's request for the TagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See TagResource for more information on using the TagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the TagResourceRequest method. +// req, resp := client.TagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/TagResource +func (c *BedrockAgent) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { + op := &request.Operation{ + Name: opTagResource, + HTTPMethod: "POST", + HTTPPath: "/tags/{resourceArn}", + } + + if input == nil { + input = &TagResourceInput{} + } + + output = &TagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// TagResource API operation for Agents for Amazon Bedrock. +// +// Associate tags with a resource. For more information, see Tagging resources +// (https://docs.aws.amazon.com/bedrock/latest/userguide/what-is-service.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation TagResource for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/TagResource +func (c *BedrockAgent) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + return out, req.Send() +} + +// TagResourceWithContext is the same as TagResource with the addition of +// the ability to pass a context and additional request options. +// +// See TagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUntagResource = "UntagResource" + +// UntagResourceRequest generates a "aws/request.Request" representing the +// client's request for the UntagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UntagResource for more information on using the UntagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UntagResourceRequest method. +// req, resp := client.UntagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UntagResource +func (c *BedrockAgent) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { + op := &request.Operation{ + Name: opUntagResource, + HTTPMethod: "DELETE", + HTTPPath: "/tags/{resourceArn}", + } + + if input == nil { + input = &UntagResourceInput{} + } + + output = &UntagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// UntagResource API operation for Agents for Amazon Bedrock. +// +// Remove tags from a resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UntagResource for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UntagResource +func (c *BedrockAgent) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + return out, req.Send() +} + +// UntagResourceWithContext is the same as UntagResource with the addition of +// the ability to pass a context and additional request options. +// +// See UntagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateAgent = "UpdateAgent" + +// UpdateAgentRequest generates a "aws/request.Request" representing the +// client's request for the UpdateAgent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateAgent for more information on using the UpdateAgent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateAgentRequest method. +// req, resp := client.UpdateAgentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgent +func (c *BedrockAgent) UpdateAgentRequest(input *UpdateAgentInput) (req *request.Request, output *UpdateAgentOutput) { + op := &request.Operation{ + Name: opUpdateAgent, + HTTPMethod: "PUT", + HTTPPath: "/agents/{agentId}/", + } + + if input == nil { + input = &UpdateAgentInput{} + } + + output = &UpdateAgentOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateAgent API operation for Agents for Amazon Bedrock. +// +// Updates the configuration of an agent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateAgent for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgent +func (c *BedrockAgent) UpdateAgent(input *UpdateAgentInput) (*UpdateAgentOutput, error) { + req, out := c.UpdateAgentRequest(input) + return out, req.Send() +} + +// UpdateAgentWithContext is the same as UpdateAgent with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateAgent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateAgentWithContext(ctx aws.Context, input *UpdateAgentInput, opts ...request.Option) (*UpdateAgentOutput, error) { + req, out := c.UpdateAgentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateAgentActionGroup = "UpdateAgentActionGroup" + +// UpdateAgentActionGroupRequest generates a "aws/request.Request" representing the +// client's request for the UpdateAgentActionGroup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateAgentActionGroup for more information on using the UpdateAgentActionGroup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateAgentActionGroupRequest method. +// req, resp := client.UpdateAgentActionGroupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentActionGroup +func (c *BedrockAgent) UpdateAgentActionGroupRequest(input *UpdateAgentActionGroupInput) (req *request.Request, output *UpdateAgentActionGroupOutput) { + op := &request.Operation{ + Name: opUpdateAgentActionGroup, + HTTPMethod: "PUT", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/actiongroups/{actionGroupId}/", + } + + if input == nil { + input = &UpdateAgentActionGroupInput{} + } + + output = &UpdateAgentActionGroupOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateAgentActionGroup API operation for Agents for Amazon Bedrock. +// +// Updates the configuration for an action group for an agent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateAgentActionGroup for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentActionGroup +func (c *BedrockAgent) UpdateAgentActionGroup(input *UpdateAgentActionGroupInput) (*UpdateAgentActionGroupOutput, error) { + req, out := c.UpdateAgentActionGroupRequest(input) + return out, req.Send() +} + +// UpdateAgentActionGroupWithContext is the same as UpdateAgentActionGroup with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateAgentActionGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateAgentActionGroupWithContext(ctx aws.Context, input *UpdateAgentActionGroupInput, opts ...request.Option) (*UpdateAgentActionGroupOutput, error) { + req, out := c.UpdateAgentActionGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateAgentAlias = "UpdateAgentAlias" + +// UpdateAgentAliasRequest generates a "aws/request.Request" representing the +// client's request for the UpdateAgentAlias operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateAgentAlias for more information on using the UpdateAgentAlias +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateAgentAliasRequest method. +// req, resp := client.UpdateAgentAliasRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentAlias +func (c *BedrockAgent) UpdateAgentAliasRequest(input *UpdateAgentAliasInput) (req *request.Request, output *UpdateAgentAliasOutput) { + op := &request.Operation{ + Name: opUpdateAgentAlias, + HTTPMethod: "PUT", + HTTPPath: "/agents/{agentId}/agentaliases/{agentAliasId}/", + } + + if input == nil { + input = &UpdateAgentAliasInput{} + } + + output = &UpdateAgentAliasOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateAgentAlias API operation for Agents for Amazon Bedrock. +// +// Updates configurations for an alias of an agent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateAgentAlias for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentAlias +func (c *BedrockAgent) UpdateAgentAlias(input *UpdateAgentAliasInput) (*UpdateAgentAliasOutput, error) { + req, out := c.UpdateAgentAliasRequest(input) + return out, req.Send() +} + +// UpdateAgentAliasWithContext is the same as UpdateAgentAlias with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateAgentAlias for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateAgentAliasWithContext(ctx aws.Context, input *UpdateAgentAliasInput, opts ...request.Option) (*UpdateAgentAliasOutput, error) { + req, out := c.UpdateAgentAliasRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateAgentKnowledgeBase = "UpdateAgentKnowledgeBase" + +// UpdateAgentKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the UpdateAgentKnowledgeBase operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateAgentKnowledgeBase for more information on using the UpdateAgentKnowledgeBase +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateAgentKnowledgeBaseRequest method. +// req, resp := client.UpdateAgentKnowledgeBaseRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentKnowledgeBase +func (c *BedrockAgent) UpdateAgentKnowledgeBaseRequest(input *UpdateAgentKnowledgeBaseInput) (req *request.Request, output *UpdateAgentKnowledgeBaseOutput) { + op := &request.Operation{ + Name: opUpdateAgentKnowledgeBase, + HTTPMethod: "PUT", + HTTPPath: "/agents/{agentId}/agentversions/{agentVersion}/knowledgebases/{knowledgeBaseId}/", + } + + if input == nil { + input = &UpdateAgentKnowledgeBaseInput{} + } + + output = &UpdateAgentKnowledgeBaseOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateAgentKnowledgeBase API operation for Agents for Amazon Bedrock. +// +// Updates the configuration for a knowledge base that has been associated with +// an agent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateAgentKnowledgeBase for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentKnowledgeBase +func (c *BedrockAgent) UpdateAgentKnowledgeBase(input *UpdateAgentKnowledgeBaseInput) (*UpdateAgentKnowledgeBaseOutput, error) { + req, out := c.UpdateAgentKnowledgeBaseRequest(input) + return out, req.Send() +} + +// UpdateAgentKnowledgeBaseWithContext is the same as UpdateAgentKnowledgeBase with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateAgentKnowledgeBase for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateAgentKnowledgeBaseWithContext(ctx aws.Context, input *UpdateAgentKnowledgeBaseInput, opts ...request.Option) (*UpdateAgentKnowledgeBaseOutput, error) { + req, out := c.UpdateAgentKnowledgeBaseRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateDataSource = "UpdateDataSource" + +// UpdateDataSourceRequest generates a "aws/request.Request" representing the +// client's request for the UpdateDataSource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateDataSource for more information on using the UpdateDataSource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateDataSourceRequest method. +// req, resp := client.UpdateDataSourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateDataSource +func (c *BedrockAgent) UpdateDataSourceRequest(input *UpdateDataSourceInput) (req *request.Request, output *UpdateDataSourceOutput) { + op := &request.Operation{ + Name: opUpdateDataSource, + HTTPMethod: "PUT", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/datasources/{dataSourceId}", + } + + if input == nil { + input = &UpdateDataSourceInput{} + } + + output = &UpdateDataSourceOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateDataSource API operation for Agents for Amazon Bedrock. +// +// 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. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateDataSource for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateDataSource +func (c *BedrockAgent) UpdateDataSource(input *UpdateDataSourceInput) (*UpdateDataSourceOutput, error) { + req, out := c.UpdateDataSourceRequest(input) + return out, req.Send() +} + +// UpdateDataSourceWithContext is the same as UpdateDataSource with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateDataSource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateDataSourceWithContext(ctx aws.Context, input *UpdateDataSourceInput, opts ...request.Option) (*UpdateDataSourceOutput, error) { + req, out := c.UpdateDataSourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateFlow = "UpdateFlow" + +// UpdateFlowRequest generates a "aws/request.Request" representing the +// client's request for the UpdateFlow operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateFlow for more information on using the UpdateFlow +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateFlowRequest method. +// req, resp := client.UpdateFlowRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateFlow +func (c *BedrockAgent) UpdateFlowRequest(input *UpdateFlowInput) (req *request.Request, output *UpdateFlowOutput) { + op := &request.Operation{ + Name: opUpdateFlow, + HTTPMethod: "PUT", + HTTPPath: "/flows/{flowIdentifier}/", + } + + if input == nil { + input = &UpdateFlowInput{} + } + + output = &UpdateFlowOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateFlow API operation for Agents for Amazon Bedrock. +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-how-it-works.html) +// and Create a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-create.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateFlow for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateFlow +func (c *BedrockAgent) UpdateFlow(input *UpdateFlowInput) (*UpdateFlowOutput, error) { + req, out := c.UpdateFlowRequest(input) + return out, req.Send() +} + +// UpdateFlowWithContext is the same as UpdateFlow with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateFlow for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateFlowWithContext(ctx aws.Context, input *UpdateFlowInput, opts ...request.Option) (*UpdateFlowOutput, error) { + req, out := c.UpdateFlowRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateFlowAlias = "UpdateFlowAlias" + +// UpdateFlowAliasRequest generates a "aws/request.Request" representing the +// client's request for the UpdateFlowAlias operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateFlowAlias for more information on using the UpdateFlowAlias +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateFlowAliasRequest method. +// req, resp := client.UpdateFlowAliasRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateFlowAlias +func (c *BedrockAgent) UpdateFlowAliasRequest(input *UpdateFlowAliasInput) (req *request.Request, output *UpdateFlowAliasOutput) { + op := &request.Operation{ + Name: opUpdateFlowAlias, + HTTPMethod: "PUT", + HTTPPath: "/flows/{flowIdentifier}/aliases/{aliasIdentifier}", + } + + if input == nil { + input = &UpdateFlowAliasInput{} + } + + output = &UpdateFlowAliasOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateFlowAlias API operation for Agents for Amazon Bedrock. +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-deploy.html) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateFlowAlias for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateFlowAlias +func (c *BedrockAgent) UpdateFlowAlias(input *UpdateFlowAliasInput) (*UpdateFlowAliasOutput, error) { + req, out := c.UpdateFlowAliasRequest(input) + return out, req.Send() +} + +// UpdateFlowAliasWithContext is the same as UpdateFlowAlias with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateFlowAlias for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateFlowAliasWithContext(ctx aws.Context, input *UpdateFlowAliasInput, opts ...request.Option) (*UpdateFlowAliasOutput, error) { + req, out := c.UpdateFlowAliasRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateKnowledgeBase = "UpdateKnowledgeBase" + +// UpdateKnowledgeBaseRequest generates a "aws/request.Request" representing the +// client's request for the UpdateKnowledgeBase operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateKnowledgeBase for more information on using the UpdateKnowledgeBase +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateKnowledgeBaseRequest method. +// req, resp := client.UpdateKnowledgeBaseRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateKnowledgeBase +func (c *BedrockAgent) UpdateKnowledgeBaseRequest(input *UpdateKnowledgeBaseInput) (req *request.Request, output *UpdateKnowledgeBaseOutput) { + op := &request.Operation{ + Name: opUpdateKnowledgeBase, + HTTPMethod: "PUT", + HTTPPath: "/knowledgebases/{knowledgeBaseId}", + } + + if input == nil { + input = &UpdateKnowledgeBaseInput{} + } + + output = &UpdateKnowledgeBaseOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateKnowledgeBase API operation for Agents for Amazon Bedrock. +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetKnowledgeBase.html) +// request and copy the same configurations. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdateKnowledgeBase for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateKnowledgeBase +func (c *BedrockAgent) UpdateKnowledgeBase(input *UpdateKnowledgeBaseInput) (*UpdateKnowledgeBaseOutput, error) { + req, out := c.UpdateKnowledgeBaseRequest(input) + return out, req.Send() +} + +// UpdateKnowledgeBaseWithContext is the same as UpdateKnowledgeBase with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateKnowledgeBase for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdateKnowledgeBaseWithContext(ctx aws.Context, input *UpdateKnowledgeBaseInput, opts ...request.Option) (*UpdateKnowledgeBaseOutput, error) { + req, out := c.UpdateKnowledgeBaseRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePrompt = "UpdatePrompt" + +// UpdatePromptRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePrompt operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePrompt for more information on using the UpdatePrompt +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdatePromptRequest method. +// req, resp := client.UpdatePromptRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdatePrompt +func (c *BedrockAgent) UpdatePromptRequest(input *UpdatePromptInput) (req *request.Request, output *UpdatePromptOutput) { + op := &request.Operation{ + Name: opUpdatePrompt, + HTTPMethod: "PUT", + HTTPPath: "/prompts/{promptIdentifier}/", + } + + if input == nil { + input = &UpdatePromptInput{} + } + + output = &UpdatePromptOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePrompt API operation for Agents for Amazon Bedrock. +// +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management.html) +// and Edit prompts in your prompt library (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-manage.html#prompt-management-edit) +// in the Amazon Bedrock User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock's +// API operation UpdatePrompt for usage and error information. +// +// Returned Error Types: +// +// - 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. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdatePrompt +func (c *BedrockAgent) UpdatePrompt(input *UpdatePromptInput) (*UpdatePromptOutput, error) { + req, out := c.UpdatePromptRequest(input) + return out, req.Send() +} + +// UpdatePromptWithContext is the same as UpdatePrompt with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePrompt for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgent) UpdatePromptWithContext(ctx aws.Context, input *UpdatePromptInput, opts ...request.Option) (*UpdatePromptOutput, error) { + req, out := c.UpdatePromptRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// Contains details about the OpenAPI schema for the action group. For more +// information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). +// 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. +type APISchema struct { + _ struct{} `type:"structure"` + + // The JSON or YAML-formatted payload defining the OpenAPI schema for the action + // group. For more information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). + // + // Payload is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by APISchema's + // String and GoString methods. + Payload *string `locationName:"payload" type:"string" sensitive:"true"` + + // Contains details about the S3 object containing the OpenAPI schema for the + // action group. For more information, see Action group OpenAPI schemas (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). + S3 *S3Identifier `locationName:"s3" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s APISchema) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s APISchema) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *APISchema) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "APISchema"} + if s.S3 != nil { + if err := s.S3.Validate(); err != nil { + invalidParams.AddNested("S3", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPayload sets the Payload field's value. +func (s *APISchema) SetPayload(v string) *APISchema { + s.Payload = &v + return s +} + +// SetS3 sets the S3 field's value. +func (s *APISchema) SetS3(v *S3Identifier) *APISchema { + s.S3 = v + return s +} + +// The request is denied because of missing access permissions. +type AccessDeniedException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + Message_ *string `locationName:"message" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AccessDeniedException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AccessDeniedException) GoString() string { + return s.String() +} + +func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { + return &AccessDeniedException{ + RespMetadata: v, + } +} + +// Code returns the exception type name. func (s *AccessDeniedException) Code() string { return "AccessDeniedException" } -// Message returns the exception's message. -func (s *AccessDeniedException) Message() string { - if s.Message_ != nil { - return *s.Message_ +// Message returns the exception's message. +func (s *AccessDeniedException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *AccessDeniedException) OrigErr() error { + return nil +} + +func (s *AccessDeniedException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *AccessDeniedException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *AccessDeniedException) RequestID() string { + return s.RespMetadata.RequestID +} + +// 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. +type ActionGroupExecutor struct { + _ struct{} `type:"structure"` + + // To return the action group invocation results directly in the InvokeAgent + // response, specify RETURN_CONTROL. + CustomControl *string `locationName:"customControl" type:"string" enum:"CustomControlMethod"` + + // The Amazon Resource Name (ARN) of the Lambda function containing the business + // logic that is carried out upon invoking the action. + Lambda *string `locationName:"lambda" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ActionGroupExecutor) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ActionGroupExecutor) GoString() string { + return s.String() +} + +// SetCustomControl sets the CustomControl field's value. +func (s *ActionGroupExecutor) SetCustomControl(v string) *ActionGroupExecutor { + s.CustomControl = &v + return s +} + +// SetLambda sets the Lambda field's value. +func (s *ActionGroupExecutor) SetLambda(v string) *ActionGroupExecutor { + s.Lambda = &v + return s +} + +// Contains details about an action group. +type ActionGroupSummary struct { + _ struct{} `type:"structure"` + + // The unique identifier of the action group. + // + // ActionGroupId is a required field + ActionGroupId *string `locationName:"actionGroupId" type:"string" required:"true"` + + // The name of the action group. + // + // ActionGroupName is a required field + ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + + // Specifies whether the action group is available for the agent to invoke or + // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + // + // ActionGroupState is a required field + ActionGroupState *string `locationName:"actionGroupState" type:"string" required:"true" enum:"ActionGroupState"` + + // The description of the action group. + Description *string `locationName:"description" min:"1" type:"string"` + + // The time at which the action group was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ActionGroupSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ActionGroupSummary) GoString() string { + return s.String() +} + +// SetActionGroupId sets the ActionGroupId field's value. +func (s *ActionGroupSummary) SetActionGroupId(v string) *ActionGroupSummary { + s.ActionGroupId = &v + return s +} + +// SetActionGroupName sets the ActionGroupName field's value. +func (s *ActionGroupSummary) SetActionGroupName(v string) *ActionGroupSummary { + s.ActionGroupName = &v + return s +} + +// SetActionGroupState sets the ActionGroupState field's value. +func (s *ActionGroupSummary) SetActionGroupState(v string) *ActionGroupSummary { + s.ActionGroupState = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *ActionGroupSummary) SetDescription(v string) *ActionGroupSummary { + s.Description = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *ActionGroupSummary) SetUpdatedAt(v time.Time) *ActionGroupSummary { + s.UpdatedAt = &v + return s +} + +// Contains details about an agent. +type Agent struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the agent. + // + // AgentArn is a required field + AgentArn *string `locationName:"agentArn" type:"string" required:"true"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The name of the agent. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the agent. + // + // AgentResourceRoleArn is a required field + AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` + + // 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. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + + // The version of the agent. + // + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" min:"5" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string"` + + // The time at which the agent was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key that encrypts the agent. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The description of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains reasons that the agent-related API that you invoked failed. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // The foundation model used for orchestration by the agent. + FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` + + // Details about the guardrail associated with the agent. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // 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. + // + // IdleSessionTTLInSeconds is a required field + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer" required:"true"` + + // Instructions that tell the agent what it should do and how it should interact + // with users. + // + // Instruction is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by Agent's + // String and GoString methods. + Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + + // Contains memory configuration for the agent. + MemoryConfiguration *MemoryConfiguration `locationName:"memoryConfiguration" type:"structure"` + + // The time at which the agent was last prepared. + PreparedAt *time.Time `locationName:"preparedAt" type:"timestamp" timestampFormat:"iso8601"` + + // Contains configurations to override prompt templates in different parts of + // an agent sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // + // PromptOverrideConfiguration is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by Agent's + // String and GoString methods. + PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + + // Contains recommended actions to take for the agent-related API that you invoked + // to succeed. + RecommendedActions []*string `locationName:"recommendedActions" type:"list"` + + // The time at which the agent was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Agent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Agent) GoString() string { + return s.String() +} + +// SetAgentArn sets the AgentArn field's value. +func (s *Agent) SetAgentArn(v string) *Agent { + s.AgentArn = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *Agent) SetAgentId(v string) *Agent { + s.AgentId = &v + return s +} + +// SetAgentName sets the AgentName field's value. +func (s *Agent) SetAgentName(v string) *Agent { + s.AgentName = &v + return s +} + +// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. +func (s *Agent) SetAgentResourceRoleArn(v string) *Agent { + s.AgentResourceRoleArn = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *Agent) SetAgentStatus(v string) *Agent { + s.AgentStatus = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *Agent) SetAgentVersion(v string) *Agent { + s.AgentVersion = &v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *Agent) SetClientToken(v string) *Agent { + s.ClientToken = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *Agent) SetCreatedAt(v time.Time) *Agent { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *Agent) SetCustomerEncryptionKeyArn(v string) *Agent { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *Agent) SetDescription(v string) *Agent { + s.Description = &v + return s +} + +// SetFailureReasons sets the FailureReasons field's value. +func (s *Agent) SetFailureReasons(v []*string) *Agent { + s.FailureReasons = v + return s +} + +// SetFoundationModel sets the FoundationModel field's value. +func (s *Agent) SetFoundationModel(v string) *Agent { + s.FoundationModel = &v + return s +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *Agent) SetGuardrailConfiguration(v *GuardrailConfiguration) *Agent { + s.GuardrailConfiguration = v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *Agent) SetIdleSessionTTLInSeconds(v int64) *Agent { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetInstruction sets the Instruction field's value. +func (s *Agent) SetInstruction(v string) *Agent { + s.Instruction = &v + return s +} + +// SetMemoryConfiguration sets the MemoryConfiguration field's value. +func (s *Agent) SetMemoryConfiguration(v *MemoryConfiguration) *Agent { + s.MemoryConfiguration = v + return s +} + +// SetPreparedAt sets the PreparedAt field's value. +func (s *Agent) SetPreparedAt(v time.Time) *Agent { + s.PreparedAt = &v + return s +} + +// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. +func (s *Agent) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *Agent { + s.PromptOverrideConfiguration = v + return s +} + +// SetRecommendedActions sets the RecommendedActions field's value. +func (s *Agent) SetRecommendedActions(v []*string) *Agent { + s.RecommendedActions = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *Agent) SetUpdatedAt(v time.Time) *Agent { + s.UpdatedAt = &v + return s +} + +// Contains details about an action group. +type AgentActionGroup struct { + _ struct{} `type:"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. + ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` + + // The unique identifier of the action group. + // + // ActionGroupId is a required field + ActionGroupId *string `locationName:"actionGroupId" type:"string" required:"true"` + + // The name of the action group. + // + // ActionGroupName is a required field + ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + + // Specifies whether the action group is available for the agent to invoke or + // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + // + // ActionGroupState is a required field + ActionGroupState *string `locationName:"actionGroupState" type:"string" required:"true" enum:"ActionGroupState"` + + // The unique identifier of the agent to which the action group belongs. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The version of the agent to which the action group belongs. + // + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). + ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string"` + + // The time at which the action group was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the action group. + Description *string `locationName:"description" min:"1" type:"string"` + + // Defines functions that each define parameters that the agent needs to invoke + // from the user. Each function represents an action in an action group. + FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` + + // 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 + // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) + // reprompting the user for more information. + ParentActionSignature *string `locationName:"parentActionSignature" type:"string" enum:"ActionGroupSignature"` + + // The time at which the action group was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentActionGroup) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentActionGroup) GoString() string { + return s.String() +} + +// SetActionGroupExecutor sets the ActionGroupExecutor field's value. +func (s *AgentActionGroup) SetActionGroupExecutor(v *ActionGroupExecutor) *AgentActionGroup { + s.ActionGroupExecutor = v + return s +} + +// SetActionGroupId sets the ActionGroupId field's value. +func (s *AgentActionGroup) SetActionGroupId(v string) *AgentActionGroup { + s.ActionGroupId = &v + return s +} + +// SetActionGroupName sets the ActionGroupName field's value. +func (s *AgentActionGroup) SetActionGroupName(v string) *AgentActionGroup { + s.ActionGroupName = &v + return s +} + +// SetActionGroupState sets the ActionGroupState field's value. +func (s *AgentActionGroup) SetActionGroupState(v string) *AgentActionGroup { + s.ActionGroupState = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *AgentActionGroup) SetAgentId(v string) *AgentActionGroup { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *AgentActionGroup) SetAgentVersion(v string) *AgentActionGroup { + s.AgentVersion = &v + return s +} + +// SetApiSchema sets the ApiSchema field's value. +func (s *AgentActionGroup) SetApiSchema(v *APISchema) *AgentActionGroup { + s.ApiSchema = v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *AgentActionGroup) SetClientToken(v string) *AgentActionGroup { + s.ClientToken = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentActionGroup) SetCreatedAt(v time.Time) *AgentActionGroup { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentActionGroup) SetDescription(v string) *AgentActionGroup { + s.Description = &v + return s +} + +// SetFunctionSchema sets the FunctionSchema field's value. +func (s *AgentActionGroup) SetFunctionSchema(v *FunctionSchema) *AgentActionGroup { + s.FunctionSchema = v + return s +} + +// SetParentActionSignature sets the ParentActionSignature field's value. +func (s *AgentActionGroup) SetParentActionSignature(v string) *AgentActionGroup { + s.ParentActionSignature = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentActionGroup) SetUpdatedAt(v time.Time) *AgentActionGroup { + s.UpdatedAt = &v + return s +} + +// Contains details about an alias of an agent. +type AgentAlias struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the alias of the agent. + // + // AgentAliasArn is a required field + AgentAliasArn *string `locationName:"agentAliasArn" type:"string" required:"true"` + + // Contains details about the history of the alias. + AgentAliasHistoryEvents []*AgentAliasHistoryEvent `locationName:"agentAliasHistoryEvents" type:"list"` + + // The unique identifier of the alias of the agent. + // + // AgentAliasId is a required field + AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` + + // The name of the alias of the agent. + // + // AgentAliasName is a required field + AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` + + // 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. + // + // AgentAliasStatus is a required field + AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string"` + + // The time at which the alias of the agent was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the alias of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Information on the failure of Provisioned Throughput assigned to an agent + // alias. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // Contains details about the routing configuration of the alias. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list" required:"true"` + + // The time at which the alias was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAlias) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAlias) GoString() string { + return s.String() +} + +// SetAgentAliasArn sets the AgentAliasArn field's value. +func (s *AgentAlias) SetAgentAliasArn(v string) *AgentAlias { + s.AgentAliasArn = &v + return s +} + +// SetAgentAliasHistoryEvents sets the AgentAliasHistoryEvents field's value. +func (s *AgentAlias) SetAgentAliasHistoryEvents(v []*AgentAliasHistoryEvent) *AgentAlias { + s.AgentAliasHistoryEvents = v + return s +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *AgentAlias) SetAgentAliasId(v string) *AgentAlias { + s.AgentAliasId = &v + return s +} + +// SetAgentAliasName sets the AgentAliasName field's value. +func (s *AgentAlias) SetAgentAliasName(v string) *AgentAlias { + s.AgentAliasName = &v + return s +} + +// SetAgentAliasStatus sets the AgentAliasStatus field's value. +func (s *AgentAlias) SetAgentAliasStatus(v string) *AgentAlias { + s.AgentAliasStatus = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *AgentAlias) SetAgentId(v string) *AgentAlias { + s.AgentId = &v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *AgentAlias) SetClientToken(v string) *AgentAlias { + s.ClientToken = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentAlias) SetCreatedAt(v time.Time) *AgentAlias { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentAlias) SetDescription(v string) *AgentAlias { + s.Description = &v + return s +} + +// SetFailureReasons sets the FailureReasons field's value. +func (s *AgentAlias) SetFailureReasons(v []*string) *AgentAlias { + s.FailureReasons = v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *AgentAlias) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAlias { + s.RoutingConfiguration = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentAlias) SetUpdatedAt(v time.Time) *AgentAlias { + s.UpdatedAt = &v + return s +} + +// Contains details about the history of the alias. +type AgentAliasHistoryEvent struct { + _ struct{} `type:"structure"` + + // The date that the alias stopped being associated to the version in the routingConfiguration + // object + EndDate *time.Time `locationName:"endDate" type:"timestamp" timestampFormat:"iso8601"` + + // Contains details about the version of the agent with which the alias is associated. + RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + + // The date that the alias began being associated to the version in the routingConfiguration + // object. + StartDate *time.Time `locationName:"startDate" type:"timestamp" timestampFormat:"iso8601"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasHistoryEvent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasHistoryEvent) GoString() string { + return s.String() +} + +// SetEndDate sets the EndDate field's value. +func (s *AgentAliasHistoryEvent) SetEndDate(v time.Time) *AgentAliasHistoryEvent { + s.EndDate = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *AgentAliasHistoryEvent) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAliasHistoryEvent { + s.RoutingConfiguration = v + return s +} + +// SetStartDate sets the StartDate field's value. +func (s *AgentAliasHistoryEvent) SetStartDate(v time.Time) *AgentAliasHistoryEvent { + s.StartDate = &v + return s +} + +// Contains details about the routing configuration of the alias. +type AgentAliasRoutingConfigurationListItem struct { + _ struct{} `type:"structure"` + + // The version of the agent with which the alias is associated. + AgentVersion *string `locationName:"agentVersion" min:"1" type:"string"` + + // Information on the Provisioned Throughput assigned to an agent alias. + ProvisionedThroughput *string `locationName:"provisionedThroughput" min:"1" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasRoutingConfigurationListItem) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasRoutingConfigurationListItem) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AgentAliasRoutingConfigurationListItem) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AgentAliasRoutingConfigurationListItem"} + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + } + if s.ProvisionedThroughput != nil && len(*s.ProvisionedThroughput) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ProvisionedThroughput", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *AgentAliasRoutingConfigurationListItem) SetAgentVersion(v string) *AgentAliasRoutingConfigurationListItem { + s.AgentVersion = &v + return s +} + +// SetProvisionedThroughput sets the ProvisionedThroughput field's value. +func (s *AgentAliasRoutingConfigurationListItem) SetProvisionedThroughput(v string) *AgentAliasRoutingConfigurationListItem { + s.ProvisionedThroughput = &v + return s +} + +// Contains details about an alias of an agent. +type AgentAliasSummary struct { + _ struct{} `type:"structure"` + + // Contains details about + // + // AgentAliasId is a required field + AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` + + // The name of the alias. + // + // AgentAliasName is a required field + AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` + + // The status of the alias. + // + // AgentAliasStatus is a required field + AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` + + // The time at which the alias of the agent was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the alias. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains details about the version of the agent with which the alias is associated. + RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + + // The time at which the alias was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentAliasSummary) GoString() string { + return s.String() +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *AgentAliasSummary) SetAgentAliasId(v string) *AgentAliasSummary { + s.AgentAliasId = &v + return s +} + +// SetAgentAliasName sets the AgentAliasName field's value. +func (s *AgentAliasSummary) SetAgentAliasName(v string) *AgentAliasSummary { + s.AgentAliasName = &v + return s +} + +// SetAgentAliasStatus sets the AgentAliasStatus field's value. +func (s *AgentAliasSummary) SetAgentAliasStatus(v string) *AgentAliasSummary { + s.AgentAliasStatus = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentAliasSummary) SetCreatedAt(v time.Time) *AgentAliasSummary { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentAliasSummary) SetDescription(v string) *AgentAliasSummary { + s.Description = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *AgentAliasSummary) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAliasSummary { + s.RoutingConfiguration = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentAliasSummary) SetUpdatedAt(v time.Time) *AgentAliasSummary { + s.UpdatedAt = &v + return s +} + +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type AgentFlowNodeConfiguration struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the alias of the agent to invoke. + // + // AgentAliasArn is a required field + AgentAliasArn *string `locationName:"agentAliasArn" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentFlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentFlowNodeConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AgentFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AgentFlowNodeConfiguration"} + if s.AgentAliasArn == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasArn sets the AgentAliasArn field's value. +func (s *AgentFlowNodeConfiguration) SetAgentAliasArn(v string) *AgentFlowNodeConfiguration { + s.AgentAliasArn = &v + return s +} + +// Contains details about a knowledge base that is associated with an agent. +type AgentKnowledgeBase struct { + _ struct{} `type:"structure"` + + // The unique identifier of the agent with which the knowledge base is associated. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The version of the agent with which the knowledge base is associated. + // + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + + // The time at which the association between the agent and the knowledge base + // was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the association between the agent and the knowledge base. + // + // Description is a required field + Description *string `locationName:"description" min:"1" type:"string" required:"true"` + + // The unique identifier of the association between the agent and the knowledge + // base. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // Specifies whether to use the knowledge base or not when sending an InvokeAgent + // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + // + // KnowledgeBaseState is a required field + KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" required:"true" enum:"KnowledgeBaseState"` + + // The time at which the association between the agent and the knowledge base + // was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentKnowledgeBase) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentKnowledgeBase) GoString() string { + return s.String() +} + +// SetAgentId sets the AgentId field's value. +func (s *AgentKnowledgeBase) SetAgentId(v string) *AgentKnowledgeBase { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *AgentKnowledgeBase) SetAgentVersion(v string) *AgentKnowledgeBase { + s.AgentVersion = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentKnowledgeBase) SetCreatedAt(v time.Time) *AgentKnowledgeBase { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentKnowledgeBase) SetDescription(v string) *AgentKnowledgeBase { + s.Description = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *AgentKnowledgeBase) SetKnowledgeBaseId(v string) *AgentKnowledgeBase { + s.KnowledgeBaseId = &v + return s +} + +// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. +func (s *AgentKnowledgeBase) SetKnowledgeBaseState(v string) *AgentKnowledgeBase { + s.KnowledgeBaseState = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentKnowledgeBase) SetUpdatedAt(v time.Time) *AgentKnowledgeBase { + s.UpdatedAt = &v + return s +} + +// Contains details about a knowledge base associated with an agent. +type AgentKnowledgeBaseSummary struct { + _ struct{} `type:"structure"` + + // The description of the knowledge base associated with an agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base associated with an agent. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // Specifies whether the agent uses the knowledge base or not when sending an + // InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + // + // KnowledgeBaseState is a required field + KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" required:"true" enum:"KnowledgeBaseState"` + + // The time at which the knowledge base associated with an agent was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentKnowledgeBaseSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentKnowledgeBaseSummary) GoString() string { + return s.String() +} + +// SetDescription sets the Description field's value. +func (s *AgentKnowledgeBaseSummary) SetDescription(v string) *AgentKnowledgeBaseSummary { + s.Description = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *AgentKnowledgeBaseSummary) SetKnowledgeBaseId(v string) *AgentKnowledgeBaseSummary { + s.KnowledgeBaseId = &v + return s +} + +// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. +func (s *AgentKnowledgeBaseSummary) SetKnowledgeBaseState(v string) *AgentKnowledgeBaseSummary { + s.KnowledgeBaseState = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentKnowledgeBaseSummary) SetUpdatedAt(v time.Time) *AgentKnowledgeBaseSummary { + s.UpdatedAt = &v + return s +} + +// Contains details about an agent. +type AgentSummary struct { + _ struct{} `type:"structure"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The name of the agent. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The status of the agent. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + + // The description of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Details about the guardrail associated with the agent. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // The latest version of the agent. + LatestAgentVersion *string `locationName:"latestAgentVersion" min:"1" type:"string"` + + // The time at which the agent was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentSummary) GoString() string { + return s.String() +} + +// SetAgentId sets the AgentId field's value. +func (s *AgentSummary) SetAgentId(v string) *AgentSummary { + s.AgentId = &v + return s +} + +// SetAgentName sets the AgentName field's value. +func (s *AgentSummary) SetAgentName(v string) *AgentSummary { + s.AgentName = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *AgentSummary) SetAgentStatus(v string) *AgentSummary { + s.AgentStatus = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentSummary) SetDescription(v string) *AgentSummary { + s.Description = &v + return s +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *AgentSummary) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentSummary { + s.GuardrailConfiguration = v + return s +} + +// SetLatestAgentVersion sets the LatestAgentVersion field's value. +func (s *AgentSummary) SetLatestAgentVersion(v string) *AgentSummary { + s.LatestAgentVersion = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentSummary) SetUpdatedAt(v time.Time) *AgentSummary { + s.UpdatedAt = &v + return s +} + +// Contains details about a version of an agent. +type AgentVersion struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the agent that the version belongs to. + // + // AgentArn is a required field + AgentArn *string `locationName:"agentArn" type:"string" required:"true"` + + // The unique identifier of the agent that the version belongs to. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The name of the agent that the version belongs to. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the agent. + // + // AgentResourceRoleArn is a required field + AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` + + // The status of the agent that the version belongs to. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + + // The time at which the version was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key that encrypts the agent. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The description of the version. + Description *string `locationName:"description" min:"1" type:"string"` + + // A list of reasons that the API operation on the version failed. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // The foundation model that the version invokes. + FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` + + // Details about the guardrail associated with the agent. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // 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. + // + // IdleSessionTTLInSeconds is a required field + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer" required:"true"` + + // The instructions provided to the agent. + // + // Instruction is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by AgentVersion's + // String and GoString methods. + Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + + // Contains details of the memory configuration on the version of the agent. + MemoryConfiguration *MemoryConfiguration `locationName:"memoryConfiguration" type:"structure"` + + // Contains configurations to override prompt templates in different parts of + // an agent sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // + // PromptOverrideConfiguration is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by AgentVersion's + // String and GoString methods. + PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + + // A list of recommended actions to take for the failed API operation on the + // version to succeed. + RecommendedActions []*string `locationName:"recommendedActions" type:"list"` + + // The time at which the version was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The version number. + // + // Version is a required field + Version *string `locationName:"version" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentVersion) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentVersion) GoString() string { + return s.String() +} + +// SetAgentArn sets the AgentArn field's value. +func (s *AgentVersion) SetAgentArn(v string) *AgentVersion { + s.AgentArn = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *AgentVersion) SetAgentId(v string) *AgentVersion { + s.AgentId = &v + return s +} + +// SetAgentName sets the AgentName field's value. +func (s *AgentVersion) SetAgentName(v string) *AgentVersion { + s.AgentName = &v + return s +} + +// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. +func (s *AgentVersion) SetAgentResourceRoleArn(v string) *AgentVersion { + s.AgentResourceRoleArn = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *AgentVersion) SetAgentStatus(v string) *AgentVersion { + s.AgentStatus = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentVersion) SetCreatedAt(v time.Time) *AgentVersion { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *AgentVersion) SetCustomerEncryptionKeyArn(v string) *AgentVersion { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentVersion) SetDescription(v string) *AgentVersion { + s.Description = &v + return s +} + +// SetFailureReasons sets the FailureReasons field's value. +func (s *AgentVersion) SetFailureReasons(v []*string) *AgentVersion { + s.FailureReasons = v + return s +} + +// SetFoundationModel sets the FoundationModel field's value. +func (s *AgentVersion) SetFoundationModel(v string) *AgentVersion { + s.FoundationModel = &v + return s +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *AgentVersion) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentVersion { + s.GuardrailConfiguration = v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *AgentVersion) SetIdleSessionTTLInSeconds(v int64) *AgentVersion { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetInstruction sets the Instruction field's value. +func (s *AgentVersion) SetInstruction(v string) *AgentVersion { + s.Instruction = &v + return s +} + +// SetMemoryConfiguration sets the MemoryConfiguration field's value. +func (s *AgentVersion) SetMemoryConfiguration(v *MemoryConfiguration) *AgentVersion { + s.MemoryConfiguration = v + return s +} + +// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. +func (s *AgentVersion) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *AgentVersion { + s.PromptOverrideConfiguration = v + return s +} + +// SetRecommendedActions sets the RecommendedActions field's value. +func (s *AgentVersion) SetRecommendedActions(v []*string) *AgentVersion { + s.RecommendedActions = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentVersion) SetUpdatedAt(v time.Time) *AgentVersion { + s.UpdatedAt = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *AgentVersion) SetVersion(v string) *AgentVersion { + s.Version = &v + return s +} + +// Contains details about a version of an agent. +type AgentVersionSummary struct { + _ struct{} `type:"structure"` + + // The name of the agent to which the version belongs. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The status of the agent to which the version belongs. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + + // The version of the agent. + // + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + + // The time at which the version was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the version of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Details about the guardrail associated with the agent. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // The time at which the version was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentVersionSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AgentVersionSummary) GoString() string { + return s.String() +} + +// SetAgentName sets the AgentName field's value. +func (s *AgentVersionSummary) SetAgentName(v string) *AgentVersionSummary { + s.AgentName = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *AgentVersionSummary) SetAgentStatus(v string) *AgentVersionSummary { + s.AgentStatus = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *AgentVersionSummary) SetAgentVersion(v string) *AgentVersionSummary { + s.AgentVersion = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *AgentVersionSummary) SetCreatedAt(v time.Time) *AgentVersionSummary { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AgentVersionSummary) SetDescription(v string) *AgentVersionSummary { + s.Description = &v + return s +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *AgentVersionSummary) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentVersionSummary { + s.GuardrailConfiguration = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *AgentVersionSummary) SetUpdatedAt(v time.Time) *AgentVersionSummary { + s.UpdatedAt = &v + return s +} + +type AssociateAgentKnowledgeBaseInput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the agent with which you want to associate the knowledge + // base. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent with which you want to associate the knowledge base. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + + // A description of what the agent should use the knowledge base for. + // + // Description is a required field + Description *string `locationName:"description" min:"1" type:"string" required:"true"` + + // The unique identifier of the knowledge base to associate with the agent. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // Specifies whether to use the knowledge base or not when sending an InvokeAgent + // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" enum:"KnowledgeBaseState"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateAgentKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateAgentKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AssociateAgentKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AssociateAgentKnowledgeBaseInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + } + if s.Description == nil { + invalidParams.Add(request.NewErrParamRequired("Description")) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *AssociateAgentKnowledgeBaseInput) SetAgentId(v string) *AssociateAgentKnowledgeBaseInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *AssociateAgentKnowledgeBaseInput) SetAgentVersion(v string) *AssociateAgentKnowledgeBaseInput { + s.AgentVersion = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *AssociateAgentKnowledgeBaseInput) SetDescription(v string) *AssociateAgentKnowledgeBaseInput { + s.Description = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *AssociateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *AssociateAgentKnowledgeBaseInput { + s.KnowledgeBaseId = &v + return s +} + +// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. +func (s *AssociateAgentKnowledgeBaseInput) SetKnowledgeBaseState(v string) *AssociateAgentKnowledgeBaseInput { + s.KnowledgeBaseState = &v + return s +} + +type AssociateAgentKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the knowledge base that has been associated with the + // agent. + // + // AgentKnowledgeBase is a required field + AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateAgentKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateAgentKnowledgeBaseOutput) GoString() string { + return s.String() +} + +// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. +func (s *AssociateAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *AssociateAgentKnowledgeBaseOutput { + s.AgentKnowledgeBase = v + return s +} + +// The vector configuration details for the Bedrock embeddings model. +type BedrockEmbeddingModelConfiguration struct { + _ struct{} `type:"structure"` + + // The dimensions details for the vector configuration used on the Bedrock embeddings + // model. + Dimensions *int64 `locationName:"dimensions" type:"integer"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s BedrockEmbeddingModelConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s BedrockEmbeddingModelConfiguration) GoString() string { + return s.String() +} + +// SetDimensions sets the Dimensions field's value. +func (s *BedrockEmbeddingModelConfiguration) SetDimensions(v int64) *BedrockEmbeddingModelConfiguration { + s.Dimensions = &v + return s +} + +// Settings for a foundation model used to parse documents for a data source. +type BedrockFoundationModelConfiguration struct { + _ struct{} `type:"structure"` + + // The model's ARN. + // + // ModelArn is a required field + ModelArn *string `locationName:"modelArn" min:"1" type:"string" required:"true"` + + // Instructions for interpreting the contents of a document. + ParsingPrompt *ParsingPrompt `locationName:"parsingPrompt" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s BedrockFoundationModelConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s BedrockFoundationModelConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *BedrockFoundationModelConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "BedrockFoundationModelConfiguration"} + if s.ModelArn == nil { + invalidParams.Add(request.NewErrParamRequired("ModelArn")) + } + if s.ModelArn != nil && len(*s.ModelArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ModelArn", 1)) + } + if s.ParsingPrompt != nil { + if err := s.ParsingPrompt.Validate(); err != nil { + invalidParams.AddNested("ParsingPrompt", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetModelArn sets the ModelArn field's value. +func (s *BedrockFoundationModelConfiguration) SetModelArn(v string) *BedrockFoundationModelConfiguration { + s.ModelArn = &v + return s +} + +// SetParsingPrompt sets the ParsingPrompt field's value. +func (s *BedrockFoundationModelConfiguration) SetParsingPrompt(v *ParsingPrompt) *BedrockFoundationModelConfiguration { + s.ParsingPrompt = v + return s +} + +// 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. +type ChunkingConfiguration struct { + _ struct{} `type:"structure"` + + // 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. + // + // ChunkingStrategy is a required field + ChunkingStrategy *string `locationName:"chunkingStrategy" type:"string" required:"true" enum:"ChunkingStrategy"` + + // Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy + // as NONE, exclude this field. + FixedSizeChunkingConfiguration *FixedSizeChunkingConfiguration `locationName:"fixedSizeChunkingConfiguration" type:"structure"` + + // 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. + HierarchicalChunkingConfiguration *HierarchicalChunkingConfiguration `locationName:"hierarchicalChunkingConfiguration" type:"structure"` + + // 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. + SemanticChunkingConfiguration *SemanticChunkingConfiguration `locationName:"semanticChunkingConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ChunkingConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ChunkingConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ChunkingConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ChunkingConfiguration"} + if s.ChunkingStrategy == nil { + invalidParams.Add(request.NewErrParamRequired("ChunkingStrategy")) + } + if s.FixedSizeChunkingConfiguration != nil { + if err := s.FixedSizeChunkingConfiguration.Validate(); err != nil { + invalidParams.AddNested("FixedSizeChunkingConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.HierarchicalChunkingConfiguration != nil { + if err := s.HierarchicalChunkingConfiguration.Validate(); err != nil { + invalidParams.AddNested("HierarchicalChunkingConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SemanticChunkingConfiguration != nil { + if err := s.SemanticChunkingConfiguration.Validate(); err != nil { + invalidParams.AddNested("SemanticChunkingConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChunkingStrategy sets the ChunkingStrategy field's value. +func (s *ChunkingConfiguration) SetChunkingStrategy(v string) *ChunkingConfiguration { + s.ChunkingStrategy = &v + return s +} + +// SetFixedSizeChunkingConfiguration sets the FixedSizeChunkingConfiguration field's value. +func (s *ChunkingConfiguration) SetFixedSizeChunkingConfiguration(v *FixedSizeChunkingConfiguration) *ChunkingConfiguration { + s.FixedSizeChunkingConfiguration = v + return s +} + +// SetHierarchicalChunkingConfiguration sets the HierarchicalChunkingConfiguration field's value. +func (s *ChunkingConfiguration) SetHierarchicalChunkingConfiguration(v *HierarchicalChunkingConfiguration) *ChunkingConfiguration { + s.HierarchicalChunkingConfiguration = v + return s +} + +// SetSemanticChunkingConfiguration sets the SemanticChunkingConfiguration field's value. +func (s *ChunkingConfiguration) SetSemanticChunkingConfiguration(v *SemanticChunkingConfiguration) *ChunkingConfiguration { + s.SemanticChunkingConfiguration = v + return s +} + +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type CollectorFlowNodeConfiguration struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CollectorFlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CollectorFlowNodeConfiguration) GoString() string { + return s.String() +} + +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type ConditionFlowNodeConfiguration struct { + _ struct{} `type:"structure"` + + // An array of conditions. Each member contains the name of a condition and + // an expression that defines the condition. + // + // Conditions is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by ConditionFlowNodeConfiguration's + // String and GoString methods. + // + // Conditions is a required field + Conditions []*FlowCondition `locationName:"conditions" min:"1" type:"list" required:"true" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConditionFlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConditionFlowNodeConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConditionFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConditionFlowNodeConfiguration"} + if s.Conditions == nil { + invalidParams.Add(request.NewErrParamRequired("Conditions")) + } + if s.Conditions != nil && len(s.Conditions) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Conditions", 1)) + } + if s.Conditions != nil { + for i, v := range s.Conditions { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Conditions", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConditions sets the Conditions field's value. +func (s *ConditionFlowNodeConfiguration) SetConditions(v []*FlowCondition) *ConditionFlowNodeConfiguration { + s.Conditions = v + return s +} + +// There was a conflict performing an operation. +type ConflictException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + Message_ *string `locationName:"message" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConflictException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConflictException) GoString() string { + return s.String() +} + +func newErrorConflictException(v protocol.ResponseMetadata) error { + return &ConflictException{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *ConflictException) Code() string { + return "ConflictException" +} + +// Message returns the exception's message. +func (s *ConflictException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ConflictException) OrigErr() error { + return nil +} + +func (s *ConflictException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *ConflictException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *ConflictException) RequestID() string { + return s.RespMetadata.RequestID +} + +// The configuration of the Confluence content. For example, configuring specific +// types of Confluence content. +type ConfluenceCrawlerConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration of filtering the Confluence content. For example, configuring + // regular expression patterns to include or exclude certain content. + FilterConfiguration *CrawlFilterConfiguration `locationName:"filterConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceCrawlerConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceCrawlerConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConfluenceCrawlerConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConfluenceCrawlerConfiguration"} + if s.FilterConfiguration != nil { + if err := s.FilterConfiguration.Validate(); err != nil { + invalidParams.AddNested("FilterConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilterConfiguration sets the FilterConfiguration field's value. +func (s *ConfluenceCrawlerConfiguration) SetFilterConfiguration(v *CrawlFilterConfiguration) *ConfluenceCrawlerConfiguration { + s.FilterConfiguration = v + return s +} + +// The configuration information to connect to Confluence as your data source. +type ConfluenceDataSourceConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration of the Confluence content. For example, configuring specific + // types of Confluence content. + CrawlerConfiguration *ConfluenceCrawlerConfiguration `locationName:"crawlerConfiguration" type:"structure"` + + // The endpoint information to connect to your Confluence data source. + // + // SourceConfiguration is a required field + SourceConfiguration *ConfluenceSourceConfiguration `locationName:"sourceConfiguration" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceDataSourceConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceDataSourceConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConfluenceDataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConfluenceDataSourceConfiguration"} + if s.SourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("SourceConfiguration")) + } + if s.CrawlerConfiguration != nil { + if err := s.CrawlerConfiguration.Validate(); err != nil { + invalidParams.AddNested("CrawlerConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SourceConfiguration != nil { + if err := s.SourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SourceConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCrawlerConfiguration sets the CrawlerConfiguration field's value. +func (s *ConfluenceDataSourceConfiguration) SetCrawlerConfiguration(v *ConfluenceCrawlerConfiguration) *ConfluenceDataSourceConfiguration { + s.CrawlerConfiguration = v + return s +} + +// SetSourceConfiguration sets the SourceConfiguration field's value. +func (s *ConfluenceDataSourceConfiguration) SetSourceConfiguration(v *ConfluenceSourceConfiguration) *ConfluenceDataSourceConfiguration { + s.SourceConfiguration = v + return s +} + +// The endpoint information to connect to your Confluence data source. +type ConfluenceSourceConfiguration struct { + _ struct{} `type:"structure"` + + // The supported authentication type to authenticate and connect to your Confluence + // instance. + // + // AuthType is a required field + AuthType *string `locationName:"authType" type:"string" required:"true" enum:"ConfluenceAuthType"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/confluence-data-source-connector.html#configuration-confluence-connector). + // + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` + + // The supported host type, whether online/cloud or server/on-premises. + // + // HostType is a required field + HostType *string `locationName:"hostType" type:"string" required:"true" enum:"ConfluenceHostType"` + + // The Confluence host URL or instance URL. + // + // HostUrl is a required field + HostUrl *string `locationName:"hostUrl" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceSourceConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConfluenceSourceConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConfluenceSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConfluenceSourceConfiguration"} + if s.AuthType == nil { + invalidParams.Add(request.NewErrParamRequired("AuthType")) + } + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) + } + if s.HostType == nil { + invalidParams.Add(request.NewErrParamRequired("HostType")) + } + if s.HostUrl == nil { + invalidParams.Add(request.NewErrParamRequired("HostUrl")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAuthType sets the AuthType field's value. +func (s *ConfluenceSourceConfiguration) SetAuthType(v string) *ConfluenceSourceConfiguration { + s.AuthType = &v + return s +} + +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *ConfluenceSourceConfiguration) SetCredentialsSecretArn(v string) *ConfluenceSourceConfiguration { + s.CredentialsSecretArn = &v + return s +} + +// SetHostType sets the HostType field's value. +func (s *ConfluenceSourceConfiguration) SetHostType(v string) *ConfluenceSourceConfiguration { + s.HostType = &v + return s +} + +// SetHostUrl sets the HostUrl field's value. +func (s *ConfluenceSourceConfiguration) SetHostUrl(v string) *ConfluenceSourceConfiguration { + s.HostUrl = &v + return s +} + +// The configuration of filtering the data source content. For example, configuring +// regular expression patterns to include or exclude certain content. +type CrawlFilterConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration of filtering certain objects or content types of the data + // source. + PatternObjectFilter *PatternObjectFilterConfiguration `locationName:"patternObjectFilter" type:"structure"` + + // 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. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"CrawlFilterConfigurationType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CrawlFilterConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CrawlFilterConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CrawlFilterConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CrawlFilterConfiguration"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.PatternObjectFilter != nil { + if err := s.PatternObjectFilter.Validate(); err != nil { + invalidParams.AddNested("PatternObjectFilter", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPatternObjectFilter sets the PatternObjectFilter field's value. +func (s *CrawlFilterConfiguration) SetPatternObjectFilter(v *PatternObjectFilterConfiguration) *CrawlFilterConfiguration { + s.PatternObjectFilter = v + return s +} + +// SetType sets the Type field's value. +func (s *CrawlFilterConfiguration) SetType(v string) *CrawlFilterConfiguration { + s.Type = &v + return s +} + +type CreateAgentActionGroupInput struct { + _ struct{} `type:"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. + ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` + + // The name to give the action group. + // + // ActionGroupName is a required field + ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + + // Specifies whether the action group is available for the agent to invoke or + // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + ActionGroupState *string `locationName:"actionGroupState" type:"string" enum:"ActionGroupState"` + + // The unique identifier of the agent for which to create the action group. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent for which to create the action group. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). + ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description of the action group. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains details about the function schema for the action group or the JSON + // or YAML-formatted payload defining the schema. + FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` + + // 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 + // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) + // reprompting the user for more information. + ParentActionGroupSignature *string `locationName:"parentActionGroupSignature" type:"string" enum:"ActionGroupSignature"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentActionGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentActionGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateAgentActionGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateAgentActionGroupInput"} + if s.ActionGroupName == nil { + invalidParams.Add(request.NewErrParamRequired("ActionGroupName")) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + } + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.ApiSchema != nil { + if err := s.ApiSchema.Validate(); err != nil { + invalidParams.AddNested("ApiSchema", err.(request.ErrInvalidParams)) + } + } + if s.FunctionSchema != nil { + if err := s.FunctionSchema.Validate(); err != nil { + invalidParams.AddNested("FunctionSchema", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetActionGroupExecutor sets the ActionGroupExecutor field's value. +func (s *CreateAgentActionGroupInput) SetActionGroupExecutor(v *ActionGroupExecutor) *CreateAgentActionGroupInput { + s.ActionGroupExecutor = v + return s +} + +// SetActionGroupName sets the ActionGroupName field's value. +func (s *CreateAgentActionGroupInput) SetActionGroupName(v string) *CreateAgentActionGroupInput { + s.ActionGroupName = &v + return s +} + +// SetActionGroupState sets the ActionGroupState field's value. +func (s *CreateAgentActionGroupInput) SetActionGroupState(v string) *CreateAgentActionGroupInput { + s.ActionGroupState = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *CreateAgentActionGroupInput) SetAgentId(v string) *CreateAgentActionGroupInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *CreateAgentActionGroupInput) SetAgentVersion(v string) *CreateAgentActionGroupInput { + s.AgentVersion = &v + return s +} + +// SetApiSchema sets the ApiSchema field's value. +func (s *CreateAgentActionGroupInput) SetApiSchema(v *APISchema) *CreateAgentActionGroupInput { + s.ApiSchema = v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateAgentActionGroupInput) SetClientToken(v string) *CreateAgentActionGroupInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateAgentActionGroupInput) SetDescription(v string) *CreateAgentActionGroupInput { + s.Description = &v + return s +} + +// SetFunctionSchema sets the FunctionSchema field's value. +func (s *CreateAgentActionGroupInput) SetFunctionSchema(v *FunctionSchema) *CreateAgentActionGroupInput { + s.FunctionSchema = v + return s +} + +// SetParentActionGroupSignature sets the ParentActionGroupSignature field's value. +func (s *CreateAgentActionGroupInput) SetParentActionGroupSignature(v string) *CreateAgentActionGroupInput { + s.ParentActionGroupSignature = &v + return s +} + +type CreateAgentActionGroupOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the action group that was created. + // + // AgentActionGroup is a required field + AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentActionGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentActionGroupOutput) GoString() string { + return s.String() +} + +// SetAgentActionGroup sets the AgentActionGroup field's value. +func (s *CreateAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *CreateAgentActionGroupOutput { + s.AgentActionGroup = v + return s +} + +type CreateAgentAliasInput struct { + _ struct{} `type:"structure"` + + // The name of the alias. + // + // AgentAliasName is a required field + AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description of the alias of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains details about the routing configuration of the alias. + RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + + // Any tags that you want to attach to the alias of the agent. + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateAgentAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateAgentAliasInput"} + if s.AgentAliasName == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasName")) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.RoutingConfiguration != nil { + for i, v := range s.RoutingConfiguration { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasName sets the AgentAliasName field's value. +func (s *CreateAgentAliasInput) SetAgentAliasName(v string) *CreateAgentAliasInput { + s.AgentAliasName = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *CreateAgentAliasInput) SetAgentId(v string) *CreateAgentAliasInput { + s.AgentId = &v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateAgentAliasInput) SetClientToken(v string) *CreateAgentAliasInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateAgentAliasInput) SetDescription(v string) *CreateAgentAliasInput { + s.Description = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *CreateAgentAliasInput) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *CreateAgentAliasInput { + s.RoutingConfiguration = v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateAgentAliasInput) SetTags(v map[string]*string) *CreateAgentAliasInput { + s.Tags = v + return s +} + +type CreateAgentAliasOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the alias that was created. + // + // AgentAlias is a required field + AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentAliasOutput) GoString() string { + return s.String() +} + +// SetAgentAlias sets the AgentAlias field's value. +func (s *CreateAgentAliasOutput) SetAgentAlias(v *AgentAlias) *CreateAgentAliasOutput { + s.AgentAlias = v + return s +} + +type CreateAgentInput struct { + _ struct{} `type:"structure"` + + // A name for the agent that you create. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the agent. + AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // A description of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // The foundation model to be used for orchestration by the agent you create. + FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` + + // The unique Guardrail configuration assigned to the agent when it is created. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // 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. + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // Instructions that tell the agent what it should do and how it should interact + // with users. + // + // Instruction is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by CreateAgentInput's + // String and GoString methods. + Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + + // Contains the details of the memory configured for the agent. + MemoryConfiguration *MemoryConfiguration `locationName:"memoryConfiguration" type:"structure"` + + // Contains configurations to override prompts in different parts of an agent + // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // + // PromptOverrideConfiguration is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by CreateAgentInput's + // String and GoString methods. + PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + + // Any tags that you want to attach to the agent. + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateAgentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateAgentInput"} + if s.AgentName == nil { + invalidParams.Add(request.NewErrParamRequired("AgentName")) + } + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.FoundationModel != nil && len(*s.FoundationModel) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FoundationModel", 1)) + } + if s.IdleSessionTTLInSeconds != nil && *s.IdleSessionTTLInSeconds < 60 { + invalidParams.Add(request.NewErrParamMinValue("IdleSessionTTLInSeconds", 60)) + } + if s.Instruction != nil && len(*s.Instruction) < 40 { + invalidParams.Add(request.NewErrParamMinLen("Instruction", 40)) + } + if s.MemoryConfiguration != nil { + if err := s.MemoryConfiguration.Validate(); err != nil { + invalidParams.AddNested("MemoryConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.PromptOverrideConfiguration != nil { + if err := s.PromptOverrideConfiguration.Validate(); err != nil { + invalidParams.AddNested("PromptOverrideConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentName sets the AgentName field's value. +func (s *CreateAgentInput) SetAgentName(v string) *CreateAgentInput { + s.AgentName = &v + return s +} + +// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. +func (s *CreateAgentInput) SetAgentResourceRoleArn(v string) *CreateAgentInput { + s.AgentResourceRoleArn = &v + return s +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateAgentInput) SetClientToken(v string) *CreateAgentInput { + s.ClientToken = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreateAgentInput) SetCustomerEncryptionKeyArn(v string) *CreateAgentInput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateAgentInput) SetDescription(v string) *CreateAgentInput { + s.Description = &v + return s +} + +// SetFoundationModel sets the FoundationModel field's value. +func (s *CreateAgentInput) SetFoundationModel(v string) *CreateAgentInput { + s.FoundationModel = &v + return s +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *CreateAgentInput) SetGuardrailConfiguration(v *GuardrailConfiguration) *CreateAgentInput { + s.GuardrailConfiguration = v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *CreateAgentInput) SetIdleSessionTTLInSeconds(v int64) *CreateAgentInput { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetInstruction sets the Instruction field's value. +func (s *CreateAgentInput) SetInstruction(v string) *CreateAgentInput { + s.Instruction = &v + return s +} + +// SetMemoryConfiguration sets the MemoryConfiguration field's value. +func (s *CreateAgentInput) SetMemoryConfiguration(v *MemoryConfiguration) *CreateAgentInput { + s.MemoryConfiguration = v + return s +} + +// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. +func (s *CreateAgentInput) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *CreateAgentInput { + s.PromptOverrideConfiguration = v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateAgentInput) SetTags(v map[string]*string) *CreateAgentInput { + s.Tags = v + return s +} + +type CreateAgentOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the agent created. + // + // Agent is a required field + Agent *Agent `locationName:"agent" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateAgentOutput) GoString() string { + return s.String() +} + +// SetAgent sets the Agent field's value. +func (s *CreateAgentOutput) SetAgent(v *Agent) *CreateAgentOutput { + s.Agent = v + return s +} + +type CreateDataSourceInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // 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. + DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` + + // The connection configuration for the data source. + // + // DataSourceConfiguration is a required field + DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` + + // A description of the data source. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base to which to add the data source. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The name of the data source. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains details about the server-side encryption for the data source. + ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` + + // Contains details about how to ingest the documents in the data source. + VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDataSourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDataSourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateDataSourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateDataSourceInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.DataSourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceConfiguration")) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.DataSourceConfiguration != nil { + if err := s.DataSourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("DataSourceConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.ServerSideEncryptionConfiguration != nil { + if err := s.ServerSideEncryptionConfiguration.Validate(); err != nil { + invalidParams.AddNested("ServerSideEncryptionConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.VectorIngestionConfiguration != nil { + if err := s.VectorIngestionConfiguration.Validate(); err != nil { + invalidParams.AddNested("VectorIngestionConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateDataSourceInput) SetClientToken(v string) *CreateDataSourceInput { + s.ClientToken = &v + return s +} + +// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. +func (s *CreateDataSourceInput) SetDataDeletionPolicy(v string) *CreateDataSourceInput { + s.DataDeletionPolicy = &v + return s +} + +// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. +func (s *CreateDataSourceInput) SetDataSourceConfiguration(v *DataSourceConfiguration) *CreateDataSourceInput { + s.DataSourceConfiguration = v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateDataSourceInput) SetDescription(v string) *CreateDataSourceInput { + s.Description = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *CreateDataSourceInput) SetKnowledgeBaseId(v string) *CreateDataSourceInput { + s.KnowledgeBaseId = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateDataSourceInput) SetName(v string) *CreateDataSourceInput { + s.Name = &v + return s +} + +// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. +func (s *CreateDataSourceInput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *CreateDataSourceInput { + s.ServerSideEncryptionConfiguration = v + return s +} + +// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. +func (s *CreateDataSourceInput) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *CreateDataSourceInput { + s.VectorIngestionConfiguration = v + return s +} + +type CreateDataSourceOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the data source. + // + // DataSource is a required field + DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDataSourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDataSourceOutput) GoString() string { + return s.String() +} + +// SetDataSource sets the DataSource field's value. +func (s *CreateDataSourceOutput) SetDataSource(v *DataSource) *CreateDataSourceOutput { + s.DataSource = v + return s +} + +type CreateFlowAliasInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description for the alias. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow for which to create an alias. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` + + // A name for the alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains information about the version to which to map the alias. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` + + // Any tags that you want to attach to the alias of the flow. For more information, + // see Tagging resources in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging.html). + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateFlowAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateFlowAliasInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.RoutingConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("RoutingConfiguration")) + } + if s.RoutingConfiguration != nil && len(s.RoutingConfiguration) < 1 { + invalidParams.Add(request.NewErrParamMinLen("RoutingConfiguration", 1)) + } + if s.RoutingConfiguration != nil { + for i, v := range s.RoutingConfiguration { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateFlowAliasInput) SetClientToken(v string) *CreateFlowAliasInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowAliasInput) SetDescription(v string) *CreateFlowAliasInput { + s.Description = &v + return s +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *CreateFlowAliasInput) SetFlowIdentifier(v string) *CreateFlowAliasInput { + s.FlowIdentifier = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateFlowAliasInput) SetName(v string) *CreateFlowAliasInput { + s.Name = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *CreateFlowAliasInput) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *CreateFlowAliasInput { + s.RoutingConfiguration = v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateFlowAliasInput) SetTags(v map[string]*string) *CreateFlowAliasInput { + s.Tags = v + return s +} + +type CreateFlowAliasOutput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the alias. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the alias was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the alias. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow that the alias belongs to. + // + // FlowId is a required field + FlowId *string `locationName:"flowId" type:"string" required:"true"` + + // The unique identifier of the alias. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains information about the version that the alias is mapped to. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` + + // The time at which the alias of the flow was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowAliasOutput) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *CreateFlowAliasOutput) SetArn(v string) *CreateFlowAliasOutput { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *CreateFlowAliasOutput) SetCreatedAt(v time.Time) *CreateFlowAliasOutput { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowAliasOutput) SetDescription(v string) *CreateFlowAliasOutput { + s.Description = &v + return s +} + +// SetFlowId sets the FlowId field's value. +func (s *CreateFlowAliasOutput) SetFlowId(v string) *CreateFlowAliasOutput { + s.FlowId = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreateFlowAliasOutput) SetId(v string) *CreateFlowAliasOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateFlowAliasOutput) SetName(v string) *CreateFlowAliasOutput { + s.Name = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *CreateFlowAliasOutput) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *CreateFlowAliasOutput { + s.RoutingConfiguration = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *CreateFlowAliasOutput) SetUpdatedAt(v time.Time) *CreateFlowAliasOutput { + s.UpdatedAt = &v + return s +} + +type CreateFlowInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // The Amazon Resource Name (ARN) of the KMS key to encrypt the flow. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // A definition of the nodes and connections between nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` + + // A description for the flow. + Description *string `locationName:"description" min:"1" 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. + // + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` + + // A name for the flow. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Any tags that you want to attach to the flow. For more information, see Tagging + // resources in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging.html). + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateFlowInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.ExecutionRoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("ExecutionRoleArn")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Definition != nil { + if err := s.Definition.Validate(); err != nil { + invalidParams.AddNested("Definition", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateFlowInput) SetClientToken(v string) *CreateFlowInput { + s.ClientToken = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreateFlowInput) SetCustomerEncryptionKeyArn(v string) *CreateFlowInput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefinition sets the Definition field's value. +func (s *CreateFlowInput) SetDefinition(v *FlowDefinition) *CreateFlowInput { + s.Definition = v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowInput) SetDescription(v string) *CreateFlowInput { + s.Description = &v + return s +} + +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *CreateFlowInput) SetExecutionRoleArn(v string) *CreateFlowInput { + s.ExecutionRoleArn = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateFlowInput) SetName(v string) *CreateFlowInput { + s.Name = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateFlowInput) SetTags(v map[string]*string) *CreateFlowInput { + s.Tags = v + return s +} + +type CreateFlowOutput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the flow. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the flow was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key that you encrypted the flow + // with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // A definition of the nodes and connections between nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` + + // The description of the flow. + Description *string `locationName:"description" min:"1" 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. + // + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the flow. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The status of the flow. When you submit this request, the status will be + // NotPrepared. If creation fails, the status becomes Failed. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` + + // The time at which the flow was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The version of the flow. When you create a flow, the version created is the + // DRAFT version. + // + // Version is a required field + Version *string `locationName:"version" min:"5" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowOutput) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *CreateFlowOutput) SetArn(v string) *CreateFlowOutput { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *CreateFlowOutput) SetCreatedAt(v time.Time) *CreateFlowOutput { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreateFlowOutput) SetCustomerEncryptionKeyArn(v string) *CreateFlowOutput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefinition sets the Definition field's value. +func (s *CreateFlowOutput) SetDefinition(v *FlowDefinition) *CreateFlowOutput { + s.Definition = v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowOutput) SetDescription(v string) *CreateFlowOutput { + s.Description = &v + return s +} + +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *CreateFlowOutput) SetExecutionRoleArn(v string) *CreateFlowOutput { + s.ExecutionRoleArn = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreateFlowOutput) SetId(v string) *CreateFlowOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateFlowOutput) SetName(v string) *CreateFlowOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *CreateFlowOutput) SetStatus(v string) *CreateFlowOutput { + s.Status = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *CreateFlowOutput) SetUpdatedAt(v time.Time) *CreateFlowOutput { + s.UpdatedAt = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreateFlowOutput) SetVersion(v string) *CreateFlowOutput { + s.Version = &v + return s +} + +type CreateFlowVersionInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description of the version of the flow. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow that you want to create a version of. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateFlowVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateFlowVersionInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateFlowVersionInput) SetClientToken(v string) *CreateFlowVersionInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowVersionInput) SetDescription(v string) *CreateFlowVersionInput { + s.Description = &v + return s +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *CreateFlowVersionInput) SetFlowIdentifier(v string) *CreateFlowVersionInput { + s.FlowIdentifier = &v + return s +} + +type CreateFlowVersionOutput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the flow. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the flow was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The KMS key that the flow is encrypted with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // A definition of the nodes and connections in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` + + // The description of the flow version. + Description *string `locationName:"description" min:"1" 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. + // + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the flow version. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The status of the flow. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` + + // The version of the flow that was created. Versions are numbered incrementally, + // starting from 1. + // + // Version is a required field + Version *string `locationName:"version" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateFlowVersionOutput) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *CreateFlowVersionOutput) SetArn(v string) *CreateFlowVersionOutput { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *CreateFlowVersionOutput) SetCreatedAt(v time.Time) *CreateFlowVersionOutput { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreateFlowVersionOutput) SetCustomerEncryptionKeyArn(v string) *CreateFlowVersionOutput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefinition sets the Definition field's value. +func (s *CreateFlowVersionOutput) SetDefinition(v *FlowDefinition) *CreateFlowVersionOutput { + s.Definition = v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateFlowVersionOutput) SetDescription(v string) *CreateFlowVersionOutput { + s.Description = &v + return s +} + +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *CreateFlowVersionOutput) SetExecutionRoleArn(v string) *CreateFlowVersionOutput { + s.ExecutionRoleArn = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreateFlowVersionOutput) SetId(v string) *CreateFlowVersionOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateFlowVersionOutput) SetName(v string) *CreateFlowVersionOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *CreateFlowVersionOutput) SetStatus(v string) *CreateFlowVersionOutput { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreateFlowVersionOutput) SetVersion(v string) *CreateFlowVersionOutput { + s.Version = &v + return s +} + +type CreateKnowledgeBaseInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description of the knowledge base. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains details about the embeddings model used for the knowledge base. + // + // KnowledgeBaseConfiguration is a required field + KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` + + // A name for the knowledge base. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the knowledge base. + // + // RoleArn is a required field + RoleArn *string `locationName:"roleArn" type:"string" required:"true"` + + // Contains details about the configuration of the vector database used for + // the knowledge base. + // + // StorageConfiguration is a required field + StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` + + // Specify the key-value pairs for the tags that you want to attach to your + // knowledge base in this object. + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateKnowledgeBaseInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.KnowledgeBaseConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseConfiguration")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.RoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("RoleArn")) + } + if s.StorageConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("StorageConfiguration")) + } + if s.KnowledgeBaseConfiguration != nil { + if err := s.KnowledgeBaseConfiguration.Validate(); err != nil { + invalidParams.AddNested("KnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.StorageConfiguration != nil { + if err := s.StorageConfiguration.Validate(); err != nil { + invalidParams.AddNested("StorageConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreateKnowledgeBaseInput) SetClientToken(v string) *CreateKnowledgeBaseInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateKnowledgeBaseInput) SetDescription(v string) *CreateKnowledgeBaseInput { + s.Description = &v + return s +} + +// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. +func (s *CreateKnowledgeBaseInput) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *CreateKnowledgeBaseInput { + s.KnowledgeBaseConfiguration = v + return s +} + +// SetName sets the Name field's value. +func (s *CreateKnowledgeBaseInput) SetName(v string) *CreateKnowledgeBaseInput { + s.Name = &v + return s +} + +// SetRoleArn sets the RoleArn field's value. +func (s *CreateKnowledgeBaseInput) SetRoleArn(v string) *CreateKnowledgeBaseInput { + s.RoleArn = &v + return s +} + +// SetStorageConfiguration sets the StorageConfiguration field's value. +func (s *CreateKnowledgeBaseInput) SetStorageConfiguration(v *StorageConfiguration) *CreateKnowledgeBaseInput { + s.StorageConfiguration = v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateKnowledgeBaseInput) SetTags(v map[string]*string) *CreateKnowledgeBaseInput { + s.Tags = v + return s +} + +type CreateKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the knowledge base. + // + // KnowledgeBase is a required field + KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateKnowledgeBaseOutput) GoString() string { + return s.String() +} + +// SetKnowledgeBase sets the KnowledgeBase field's value. +func (s *CreateKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *CreateKnowledgeBaseOutput { + s.KnowledgeBase = v + return s +} + +type CreatePromptInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The name of the default variant for the prompt. This value must match the + // name field in the relevant PromptVariant (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptVariant.html) + // object. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // A description for the prompt. + Description *string `locationName:"description" min:"1" type:"string"` + + // A name for the prompt. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Any tags that you want to attach to the prompt. For more information, see + // Tagging resources in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging.html). + Tags map[string]*string `locationName:"tags" type:"map"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by CreatePromptInput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePromptInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePromptInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Variants != nil { + for i, v := range s.Variants { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Variants", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreatePromptInput) SetClientToken(v string) *CreatePromptInput { + s.ClientToken = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreatePromptInput) SetCustomerEncryptionKeyArn(v string) *CreatePromptInput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *CreatePromptInput) SetDefaultVariant(v string) *CreatePromptInput { + s.DefaultVariant = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePromptInput) SetDescription(v string) *CreatePromptInput { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreatePromptInput) SetName(v string) *CreatePromptInput { + s.Name = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreatePromptInput) SetTags(v map[string]*string) *CreatePromptInput { + s.Tags = v + return s +} + +// SetVariants sets the Variants field's value. +func (s *CreatePromptInput) SetVariants(v []*PromptVariant) *CreatePromptInput { + s.Variants = v + return s +} + +type CreatePromptOutput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the prompt. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the prompt was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key that you encrypted the prompt + // with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The name of the default variant for your prompt. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // The description of the prompt. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the prompt. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the prompt. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The time at which the prompt was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by CreatePromptOutput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` + + // The version of the prompt. When you create a prompt, the version created + // is the DRAFT version. + // + // Version is a required field + Version *string `locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptOutput) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *CreatePromptOutput) SetArn(v string) *CreatePromptOutput { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *CreatePromptOutput) SetCreatedAt(v time.Time) *CreatePromptOutput { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreatePromptOutput) SetCustomerEncryptionKeyArn(v string) *CreatePromptOutput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *CreatePromptOutput) SetDefaultVariant(v string) *CreatePromptOutput { + s.DefaultVariant = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePromptOutput) SetDescription(v string) *CreatePromptOutput { + s.Description = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreatePromptOutput) SetId(v string) *CreatePromptOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreatePromptOutput) SetName(v string) *CreatePromptOutput { + s.Name = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *CreatePromptOutput) SetUpdatedAt(v time.Time) *CreatePromptOutput { + s.UpdatedAt = &v + return s +} + +// SetVariants sets the Variants field's value. +func (s *CreatePromptOutput) SetVariants(v []*PromptVariant) *CreatePromptOutput { + s.Variants = v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreatePromptOutput) SetVersion(v string) *CreatePromptOutput { + s.Version = &v + return s +} + +type CreatePromptVersionInput struct { + _ struct{} `type:"structure"` + + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + + // A description for the version of the prompt. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the prompt that you want to create a version of. + // + // PromptIdentifier is a required field + PromptIdentifier *string `location:"uri" locationName:"promptIdentifier" type:"string" required:"true"` + + // Any tags that you want to attach to the version of the prompt. For more information, + // see Tagging resources in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/tagging.html). + Tags map[string]*string `locationName:"tags" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePromptVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePromptVersionInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.PromptIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("PromptIdentifier")) + } + if s.PromptIdentifier != nil && len(*s.PromptIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PromptIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientToken sets the ClientToken field's value. +func (s *CreatePromptVersionInput) SetClientToken(v string) *CreatePromptVersionInput { + s.ClientToken = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePromptVersionInput) SetDescription(v string) *CreatePromptVersionInput { + s.Description = &v + return s +} + +// SetPromptIdentifier sets the PromptIdentifier field's value. +func (s *CreatePromptVersionInput) SetPromptIdentifier(v string) *CreatePromptVersionInput { + s.PromptIdentifier = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreatePromptVersionInput) SetTags(v map[string]*string) *CreatePromptVersionInput { + s.Tags = v + return s +} + +type CreatePromptVersionOutput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the version of the prompt. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the prompt was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key to encrypt the version of the + // prompt. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The name of the default variant for the prompt. This value must match the + // name field in the relevant PromptVariant (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptVariant.html) + // object. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // A description for the prompt version. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the prompt. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the prompt version. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The time at which the prompt was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by CreatePromptVersionOutput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` + + // The version of the prompt that was created. Versions are numbered incrementally, + // starting from 1. + // + // Version is a required field + Version *string `locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePromptVersionOutput) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *CreatePromptVersionOutput) SetArn(v string) *CreatePromptVersionOutput { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *CreatePromptVersionOutput) SetCreatedAt(v time.Time) *CreatePromptVersionOutput { + s.CreatedAt = &v + return s +} + +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *CreatePromptVersionOutput) SetCustomerEncryptionKeyArn(v string) *CreatePromptVersionOutput { + s.CustomerEncryptionKeyArn = &v + return s +} + +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *CreatePromptVersionOutput) SetDefaultVariant(v string) *CreatePromptVersionOutput { + s.DefaultVariant = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePromptVersionOutput) SetDescription(v string) *CreatePromptVersionOutput { + s.Description = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreatePromptVersionOutput) SetId(v string) *CreatePromptVersionOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreatePromptVersionOutput) SetName(v string) *CreatePromptVersionOutput { + s.Name = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *CreatePromptVersionOutput) SetUpdatedAt(v time.Time) *CreatePromptVersionOutput { + s.UpdatedAt = &v + return s +} + +// SetVariants sets the Variants field's value. +func (s *CreatePromptVersionOutput) SetVariants(v []*PromptVariant) *CreatePromptVersionOutput { + s.Variants = v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreatePromptVersionOutput) SetVersion(v string) *CreatePromptVersionOutput { + s.Version = &v + return s +} + +// 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. +type CustomTransformationConfiguration struct { + _ struct{} `type:"structure"` + + // An S3 bucket path for input and output objects. + // + // IntermediateStorage is a required field + IntermediateStorage *IntermediateStorage `locationName:"intermediateStorage" type:"structure" required:"true"` + + // A Lambda function that processes documents. + // + // Transformations is a required field + Transformations []*Transformation `locationName:"transformations" min:"1" type:"list" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CustomTransformationConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CustomTransformationConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CustomTransformationConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CustomTransformationConfiguration"} + if s.IntermediateStorage == nil { + invalidParams.Add(request.NewErrParamRequired("IntermediateStorage")) + } + if s.Transformations == nil { + invalidParams.Add(request.NewErrParamRequired("Transformations")) + } + if s.Transformations != nil && len(s.Transformations) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Transformations", 1)) + } + if s.IntermediateStorage != nil { + if err := s.IntermediateStorage.Validate(); err != nil { + invalidParams.AddNested("IntermediateStorage", err.(request.ErrInvalidParams)) + } + } + if s.Transformations != nil { + for i, v := range s.Transformations { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Transformations", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetIntermediateStorage sets the IntermediateStorage field's value. +func (s *CustomTransformationConfiguration) SetIntermediateStorage(v *IntermediateStorage) *CustomTransformationConfiguration { + s.IntermediateStorage = v + return s +} + +// SetTransformations sets the Transformations field's value. +func (s *CustomTransformationConfiguration) SetTransformations(v []*Transformation) *CustomTransformationConfiguration { + s.Transformations = v + return s +} + +// Contains details about a data source. +type DataSource struct { + _ struct{} `type:"structure"` + + // The time at which the data source was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The data deletion policy for the data source. + DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` + + // The connection configuration for the data source. + // + // DataSourceConfiguration is a required field + DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` + + // The unique identifier of the data source. + // + // DataSourceId is a required field + DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` + + // The description of the data source. + Description *string `locationName:"description" min:"1" type:"string"` + + // The detailed reasons on the failure to delete a data source. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // The unique identifier of the knowledge base to which the data source belongs. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The name of the data source. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains details about the configuration of the server-side encryption. + ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` + + // 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. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` + + // The time at which the data source was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // Contains details about how to ingest the documents in the data source. + VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSource) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSource) GoString() string { + return s.String() +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *DataSource) SetCreatedAt(v time.Time) *DataSource { + s.CreatedAt = &v + return s +} + +// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. +func (s *DataSource) SetDataDeletionPolicy(v string) *DataSource { + s.DataDeletionPolicy = &v + return s +} + +// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. +func (s *DataSource) SetDataSourceConfiguration(v *DataSourceConfiguration) *DataSource { + s.DataSourceConfiguration = v + return s +} + +// SetDataSourceId sets the DataSourceId field's value. +func (s *DataSource) SetDataSourceId(v string) *DataSource { + s.DataSourceId = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *DataSource) SetDescription(v string) *DataSource { + s.Description = &v + return s +} + +// SetFailureReasons sets the FailureReasons field's value. +func (s *DataSource) SetFailureReasons(v []*string) *DataSource { + s.FailureReasons = v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DataSource) SetKnowledgeBaseId(v string) *DataSource { + s.KnowledgeBaseId = &v + return s +} + +// SetName sets the Name field's value. +func (s *DataSource) SetName(v string) *DataSource { + s.Name = &v + return s +} + +// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. +func (s *DataSource) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *DataSource { + s.ServerSideEncryptionConfiguration = v + return s +} + +// SetStatus sets the Status field's value. +func (s *DataSource) SetStatus(v string) *DataSource { + s.Status = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *DataSource) SetUpdatedAt(v time.Time) *DataSource { + s.UpdatedAt = &v + return s +} + +// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. +func (s *DataSource) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *DataSource { + s.VectorIngestionConfiguration = v + return s +} + +// The connection configuration for the data source. +type DataSourceConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration information to connect to Confluence as your data source. + // + // Confluence data source connector is in preview release and is subject to + // change. + ConfluenceConfiguration *ConfluenceDataSourceConfiguration `locationName:"confluenceConfiguration" type:"structure"` + + // The configuration information to connect to Amazon S3 as your data source. + S3Configuration *S3DataSourceConfiguration `locationName:"s3Configuration" type:"structure"` + + // The configuration information to connect to Salesforce as your data source. + // + // Salesforce data source connector is in preview release and is subject to + // change. + SalesforceConfiguration *SalesforceDataSourceConfiguration `locationName:"salesforceConfiguration" type:"structure"` + + // The configuration information to connect to SharePoint as your data source. + // + // SharePoint data source connector is in preview release and is subject to + // change. + SharePointConfiguration *SharePointDataSourceConfiguration `locationName:"sharePointConfiguration" type:"structure"` + + // The type of data source. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"DataSourceType"` + + // 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. + WebConfiguration *WebDataSourceConfiguration `locationName:"webConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSourceConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSourceConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DataSourceConfiguration"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.ConfluenceConfiguration != nil { + if err := s.ConfluenceConfiguration.Validate(); err != nil { + invalidParams.AddNested("ConfluenceConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.S3Configuration != nil { + if err := s.S3Configuration.Validate(); err != nil { + invalidParams.AddNested("S3Configuration", err.(request.ErrInvalidParams)) + } + } + if s.SalesforceConfiguration != nil { + if err := s.SalesforceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SalesforceConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SharePointConfiguration != nil { + if err := s.SharePointConfiguration.Validate(); err != nil { + invalidParams.AddNested("SharePointConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.WebConfiguration != nil { + if err := s.WebConfiguration.Validate(); err != nil { + invalidParams.AddNested("WebConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfluenceConfiguration sets the ConfluenceConfiguration field's value. +func (s *DataSourceConfiguration) SetConfluenceConfiguration(v *ConfluenceDataSourceConfiguration) *DataSourceConfiguration { + s.ConfluenceConfiguration = v + return s +} + +// SetS3Configuration sets the S3Configuration field's value. +func (s *DataSourceConfiguration) SetS3Configuration(v *S3DataSourceConfiguration) *DataSourceConfiguration { + s.S3Configuration = v + return s +} + +// SetSalesforceConfiguration sets the SalesforceConfiguration field's value. +func (s *DataSourceConfiguration) SetSalesforceConfiguration(v *SalesforceDataSourceConfiguration) *DataSourceConfiguration { + s.SalesforceConfiguration = v + return s +} + +// SetSharePointConfiguration sets the SharePointConfiguration field's value. +func (s *DataSourceConfiguration) SetSharePointConfiguration(v *SharePointDataSourceConfiguration) *DataSourceConfiguration { + s.SharePointConfiguration = v + return s +} + +// SetType sets the Type field's value. +func (s *DataSourceConfiguration) SetType(v string) *DataSourceConfiguration { + s.Type = &v + return s +} + +// SetWebConfiguration sets the WebConfiguration field's value. +func (s *DataSourceConfiguration) SetWebConfiguration(v *WebDataSourceConfiguration) *DataSourceConfiguration { + s.WebConfiguration = v + return s +} + +// Contains details about a data source. +type DataSourceSummary struct { + _ struct{} `type:"structure"` + + // The unique identifier of the data source. + // + // DataSourceId is a required field + DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` + + // The description of the data source. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base to which the data source belongs. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The name of the data source. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The status of the data source. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` + + // The time at which the data source was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSourceSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DataSourceSummary) GoString() string { + return s.String() +} + +// SetDataSourceId sets the DataSourceId field's value. +func (s *DataSourceSummary) SetDataSourceId(v string) *DataSourceSummary { + s.DataSourceId = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *DataSourceSummary) SetDescription(v string) *DataSourceSummary { + s.Description = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DataSourceSummary) SetKnowledgeBaseId(v string) *DataSourceSummary { + s.KnowledgeBaseId = &v + return s +} + +// SetName sets the Name field's value. +func (s *DataSourceSummary) SetName(v string) *DataSourceSummary { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *DataSourceSummary) SetStatus(v string) *DataSourceSummary { + s.Status = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *DataSourceSummary) SetUpdatedAt(v time.Time) *DataSourceSummary { + s.UpdatedAt = &v + return s +} + +type DeleteAgentActionGroupInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the action group to delete. + // + // ActionGroupId is a required field + ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` + + // The unique identifier of the agent that the action group belongs to. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent that the action group belongs to. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + + // 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. + SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentActionGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentActionGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAgentActionGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAgentActionGroupInput"} + if s.ActionGroupId == nil { + invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) + } + if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetActionGroupId sets the ActionGroupId field's value. +func (s *DeleteAgentActionGroupInput) SetActionGroupId(v string) *DeleteAgentActionGroupInput { + s.ActionGroupId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentActionGroupInput) SetAgentId(v string) *DeleteAgentActionGroupInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *DeleteAgentActionGroupInput) SetAgentVersion(v string) *DeleteAgentActionGroupInput { + s.AgentVersion = &v + return s +} + +// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. +func (s *DeleteAgentActionGroupInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentActionGroupInput { + s.SkipResourceInUseCheck = &v + return s +} + +type DeleteAgentActionGroupOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentActionGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentActionGroupOutput) GoString() string { + return s.String() +} + +type DeleteAgentAliasInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the alias to delete. + // + // AgentAliasId is a required field + AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` + + // The unique identifier of the agent that the alias belongs to. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAgentAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAgentAliasInput"} + if s.AgentAliasId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) + } + if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { + invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *DeleteAgentAliasInput) SetAgentAliasId(v string) *DeleteAgentAliasInput { + s.AgentAliasId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentAliasInput) SetAgentId(v string) *DeleteAgentAliasInput { + s.AgentId = &v + return s +} + +type DeleteAgentAliasOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the alias that was deleted. + // + // AgentAliasId is a required field + AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` + + // The status of the alias. + // + // AgentAliasStatus is a required field + AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` + + // The unique identifier of the agent that the alias belongs to. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentAliasOutput) GoString() string { + return s.String() +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *DeleteAgentAliasOutput) SetAgentAliasId(v string) *DeleteAgentAliasOutput { + s.AgentAliasId = &v + return s +} + +// SetAgentAliasStatus sets the AgentAliasStatus field's value. +func (s *DeleteAgentAliasOutput) SetAgentAliasStatus(v string) *DeleteAgentAliasOutput { + s.AgentAliasStatus = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentAliasOutput) SetAgentId(v string) *DeleteAgentAliasOutput { + s.AgentId = &v + return s +} + +type DeleteAgentInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent to delete. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // 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. + SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAgentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAgentInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentInput) SetAgentId(v string) *DeleteAgentInput { + s.AgentId = &v + return s +} + +// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. +func (s *DeleteAgentInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentInput { + s.SkipResourceInUseCheck = &v + return s +} + +type DeleteAgentOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the agent that was deleted. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The status of the agent. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentOutput) GoString() string { + return s.String() +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentOutput) SetAgentId(v string) *DeleteAgentOutput { + s.AgentId = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *DeleteAgentOutput) SetAgentStatus(v string) *DeleteAgentOutput { + s.AgentStatus = &v + return s +} + +type DeleteAgentVersionInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent that the version belongs to. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent to delete. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" type:"string" required:"true"` + + // 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. + SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAgentVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAgentVersionInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentVersionInput) SetAgentId(v string) *DeleteAgentVersionInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *DeleteAgentVersionInput) SetAgentVersion(v string) *DeleteAgentVersionInput { + s.AgentVersion = &v + return s +} + +// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. +func (s *DeleteAgentVersionInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentVersionInput { + s.SkipResourceInUseCheck = &v + return s +} + +type DeleteAgentVersionOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the agent that the version belongs to. + // + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` + + // The status of the agent version. + // + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + + // The version that was deleted. + // + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentVersionOutput) GoString() string { + return s.String() +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentVersionOutput) SetAgentId(v string) *DeleteAgentVersionOutput { + s.AgentId = &v + return s +} + +// SetAgentStatus sets the AgentStatus field's value. +func (s *DeleteAgentVersionOutput) SetAgentStatus(v string) *DeleteAgentVersionOutput { + s.AgentStatus = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *DeleteAgentVersionOutput) SetAgentVersion(v string) *DeleteAgentVersionOutput { + s.AgentVersion = &v + return s +} + +type DeleteDataSourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the data source to delete. + // + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + + // The unique identifier of the knowledge base from which to delete the data + // source. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDataSourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDataSourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteDataSourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteDataSourceInput"} + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) + } + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDataSourceId sets the DataSourceId field's value. +func (s *DeleteDataSourceInput) SetDataSourceId(v string) *DeleteDataSourceInput { + s.DataSourceId = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DeleteDataSourceInput) SetKnowledgeBaseId(v string) *DeleteDataSourceInput { + s.KnowledgeBaseId = &v + return s +} + +type DeleteDataSourceOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the data source that was deleted. + // + // DataSourceId is a required field + DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` + + // The unique identifier of the knowledge base to which the data source that + // was deleted belonged. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The status of the data source. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDataSourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDataSourceOutput) GoString() string { + return s.String() +} + +// SetDataSourceId sets the DataSourceId field's value. +func (s *DeleteDataSourceOutput) SetDataSourceId(v string) *DeleteDataSourceOutput { + s.DataSourceId = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DeleteDataSourceOutput) SetKnowledgeBaseId(v string) *DeleteDataSourceOutput { + s.KnowledgeBaseId = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *DeleteDataSourceOutput) SetStatus(v string) *DeleteDataSourceOutput { + s.Status = &v + return s +} + +type DeleteFlowAliasInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the alias to be deleted. + // + // AliasIdentifier is a required field + AliasIdentifier *string `location:"uri" locationName:"aliasIdentifier" type:"string" required:"true"` + + // The unique identifier of the flow that the alias belongs to. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteFlowAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteFlowAliasInput"} + if s.AliasIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("AliasIdentifier")) + } + if s.AliasIdentifier != nil && len(*s.AliasIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AliasIdentifier", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAliasIdentifier sets the AliasIdentifier field's value. +func (s *DeleteFlowAliasInput) SetAliasIdentifier(v string) *DeleteFlowAliasInput { + s.AliasIdentifier = &v + return s +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *DeleteFlowAliasInput) SetFlowIdentifier(v string) *DeleteFlowAliasInput { + s.FlowIdentifier = &v + return s +} + +type DeleteFlowAliasOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the flow that the alias belongs to. + // + // FlowId is a required field + FlowId *string `locationName:"flowId" type:"string" required:"true"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowAliasOutput) GoString() string { + return s.String() +} + +// SetFlowId sets the FlowId field's value. +func (s *DeleteFlowAliasOutput) SetFlowId(v string) *DeleteFlowAliasOutput { + s.FlowId = &v + return s +} + +// SetId sets the Id field's value. +func (s *DeleteFlowAliasOutput) SetId(v string) *DeleteFlowAliasOutput { + s.Id = &v + return s +} + +type DeleteFlowInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the flow. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` + + // 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. + SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteFlowInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *DeleteFlowInput) SetFlowIdentifier(v string) *DeleteFlowInput { + s.FlowIdentifier = &v + return s +} + +// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. +func (s *DeleteFlowInput) SetSkipResourceInUseCheck(v bool) *DeleteFlowInput { + s.SkipResourceInUseCheck = &v + return s +} + +type DeleteFlowOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowOutput) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *DeleteFlowOutput) SetId(v string) *DeleteFlowOutput { + s.Id = &v + return s +} + +type DeleteFlowVersionInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the flow whose version that you want to delete + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` + + // The version of the flow that you want to delete. + // + // FlowVersion is a required field + FlowVersion *string `location:"uri" locationName:"flowVersion" type:"string" required:"true"` + + // 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. + SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteFlowVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteFlowVersionInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + if s.FlowVersion == nil { + invalidParams.Add(request.NewErrParamRequired("FlowVersion")) + } + if s.FlowVersion != nil && len(*s.FlowVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *DeleteFlowVersionInput) SetFlowIdentifier(v string) *DeleteFlowVersionInput { + s.FlowIdentifier = &v + return s +} + +// SetFlowVersion sets the FlowVersion field's value. +func (s *DeleteFlowVersionInput) SetFlowVersion(v string) *DeleteFlowVersionInput { + s.FlowVersion = &v + return s +} + +// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. +func (s *DeleteFlowVersionInput) SetSkipResourceInUseCheck(v bool) *DeleteFlowVersionInput { + s.SkipResourceInUseCheck = &v + return s +} + +type DeleteFlowVersionOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The version of the flow being deleted. + // + // Version is a required field + Version *string `locationName:"version" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteFlowVersionOutput) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *DeleteFlowVersionOutput) SetId(v string) *DeleteFlowVersionOutput { + s.Id = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *DeleteFlowVersionOutput) SetVersion(v string) *DeleteFlowVersionOutput { + s.Version = &v + return s +} + +type DeleteKnowledgeBaseInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the knowledge base to delete. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteKnowledgeBaseInput"} + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DeleteKnowledgeBaseInput) SetKnowledgeBaseId(v string) *DeleteKnowledgeBaseInput { + s.KnowledgeBaseId = &v + return s +} + +type DeleteKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the knowledge base that was deleted. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The status of the knowledge base and whether it has been successfully deleted. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteKnowledgeBaseOutput) GoString() string { + return s.String() +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DeleteKnowledgeBaseOutput) SetKnowledgeBaseId(v string) *DeleteKnowledgeBaseOutput { + s.KnowledgeBaseId = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *DeleteKnowledgeBaseOutput) SetStatus(v string) *DeleteKnowledgeBaseOutput { + s.Status = &v + return s +} + +type DeletePromptInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the prompt. + // + // PromptIdentifier is a required field + PromptIdentifier *string `location:"uri" locationName:"promptIdentifier" type:"string" required:"true"` + + // The version of the prompt to delete. + PromptVersion *string `location:"querystring" locationName:"promptVersion" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePromptInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePromptInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePromptInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePromptInput"} + if s.PromptIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("PromptIdentifier")) + } + if s.PromptIdentifier != nil && len(*s.PromptIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PromptIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPromptIdentifier sets the PromptIdentifier field's value. +func (s *DeletePromptInput) SetPromptIdentifier(v string) *DeletePromptInput { + s.PromptIdentifier = &v + return s +} + +// SetPromptVersion sets the PromptVersion field's value. +func (s *DeletePromptInput) SetPromptVersion(v string) *DeletePromptInput { + s.PromptVersion = &v + return s +} + +type DeletePromptOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the prompt that was deleted. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The version of the prompt that was deleted. + Version *string `locationName:"version" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePromptOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePromptOutput) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *DeletePromptOutput) SetId(v string) *DeletePromptOutput { + s.Id = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *DeletePromptOutput) SetVersion(v string) *DeletePromptOutput { + s.Version = &v + return s +} + +type DisassociateAgentKnowledgeBaseInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent from which to disassociate the knowledge + // base. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent from which to disassociate the knowledge base. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + + // The unique identifier of the knowledge base to disassociate. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DisassociateAgentKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DisassociateAgentKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DisassociateAgentKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DisassociateAgentKnowledgeBaseInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *DisassociateAgentKnowledgeBaseInput) SetAgentId(v string) *DisassociateAgentKnowledgeBaseInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *DisassociateAgentKnowledgeBaseInput) SetAgentVersion(v string) *DisassociateAgentKnowledgeBaseInput { + s.AgentVersion = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *DisassociateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *DisassociateAgentKnowledgeBaseInput { + s.KnowledgeBaseId = &v + return s +} + +type DisassociateAgentKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DisassociateAgentKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DisassociateAgentKnowledgeBaseOutput) GoString() string { + return s.String() +} + +// The configuration details for the embeddings model. +type EmbeddingModelConfiguration struct { + _ struct{} `type:"structure"` + + // The vector configuration details on the Bedrock embeddings model. + BedrockEmbeddingModelConfiguration *BedrockEmbeddingModelConfiguration `locationName:"bedrockEmbeddingModelConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s EmbeddingModelConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s EmbeddingModelConfiguration) GoString() string { + return s.String() +} + +// SetBedrockEmbeddingModelConfiguration sets the BedrockEmbeddingModelConfiguration field's value. +func (s *EmbeddingModelConfiguration) SetBedrockEmbeddingModelConfiguration(v *BedrockEmbeddingModelConfiguration) *EmbeddingModelConfiguration { + s.BedrockEmbeddingModelConfiguration = v + return s +} + +// Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy +// as NONE, exclude this field. +type FixedSizeChunkingConfiguration struct { + _ struct{} `type:"structure"` + + // The maximum number of tokens to include in a chunk. + // + // MaxTokens is a required field + MaxTokens *int64 `locationName:"maxTokens" min:"1" type:"integer" required:"true"` + + // The percentage of overlap between adjacent chunks of a data source. + // + // OverlapPercentage is a required field + OverlapPercentage *int64 `locationName:"overlapPercentage" min:"1" type:"integer" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FixedSizeChunkingConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FixedSizeChunkingConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FixedSizeChunkingConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FixedSizeChunkingConfiguration"} + if s.MaxTokens == nil { + invalidParams.Add(request.NewErrParamRequired("MaxTokens")) + } + if s.MaxTokens != nil && *s.MaxTokens < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxTokens", 1)) + } + if s.OverlapPercentage == nil { + invalidParams.Add(request.NewErrParamRequired("OverlapPercentage")) + } + if s.OverlapPercentage != nil && *s.OverlapPercentage < 1 { + invalidParams.Add(request.NewErrParamMinValue("OverlapPercentage", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxTokens sets the MaxTokens field's value. +func (s *FixedSizeChunkingConfiguration) SetMaxTokens(v int64) *FixedSizeChunkingConfiguration { + s.MaxTokens = &v + return s +} + +// SetOverlapPercentage sets the OverlapPercentage field's value. +func (s *FixedSizeChunkingConfiguration) SetOverlapPercentage(v int64) *FixedSizeChunkingConfiguration { + s.OverlapPercentage = &v + return s +} + +// Contains information about a version that the alias maps to. +type FlowAliasRoutingConfigurationListItem struct { + _ struct{} `type:"structure"` + + // The version that the alias maps to. + FlowVersion *string `locationName:"flowVersion" min:"1" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowAliasRoutingConfigurationListItem) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowAliasRoutingConfigurationListItem) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowAliasRoutingConfigurationListItem) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowAliasRoutingConfigurationListItem"} + if s.FlowVersion != nil && len(*s.FlowVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFlowVersion sets the FlowVersion field's value. +func (s *FlowAliasRoutingConfigurationListItem) SetFlowVersion(v string) *FlowAliasRoutingConfigurationListItem { + s.FlowVersion = &v + return s +} + +// Contains information about an alias of a flow. +// +// This data type is used in the following API operations: +// +// - ListFlowAliases response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_ListFlowAliases.html#API_agent_ListFlowAliases_ResponseSyntax) +type FlowAliasSummary struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the flow alias. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the alias was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A description of the alias. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow. + // + // FlowId is a required field + FlowId *string `locationName:"flowId" type:"string" required:"true"` + + // The unique identifier of the alias of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // A list of configurations about the versions that the alias maps to. Currently, + // you can only specify one. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` + + // The time at which the alias was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowAliasSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowAliasSummary) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *FlowAliasSummary) SetArn(v string) *FlowAliasSummary { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *FlowAliasSummary) SetCreatedAt(v time.Time) *FlowAliasSummary { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *FlowAliasSummary) SetDescription(v string) *FlowAliasSummary { + s.Description = &v + return s +} + +// SetFlowId sets the FlowId field's value. +func (s *FlowAliasSummary) SetFlowId(v string) *FlowAliasSummary { + s.FlowId = &v + return s +} + +// SetId sets the Id field's value. +func (s *FlowAliasSummary) SetId(v string) *FlowAliasSummary { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *FlowAliasSummary) SetName(v string) *FlowAliasSummary { + s.Name = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *FlowAliasSummary) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *FlowAliasSummary { + s.RoutingConfiguration = v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *FlowAliasSummary) SetUpdatedAt(v time.Time) *FlowAliasSummary { + s.UpdatedAt = &v + return s +} + +// Defines a condition in the condition node. +type FlowCondition struct { + _ struct{} `type:"structure" sensitive:"true"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-how-it-works.html#flows-nodes). + // + // Expression is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by FlowCondition's + // String and GoString methods. + Expression *string `locationName:"expression" min:"1" type:"string" sensitive:"true"` + + // A name for the condition that you can reference. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowCondition) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowCondition) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowCondition) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowCondition"} + if s.Expression != nil && len(*s.Expression) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Expression", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetExpression sets the Expression field's value. +func (s *FlowCondition) SetExpression(v string) *FlowCondition { + s.Expression = &v + return s +} + +// SetName sets the Name field's value. +func (s *FlowCondition) SetName(v string) *FlowCondition { + s.Name = &v + return s +} + +// The configuration of a connection between a condition node and another node. +type FlowConditionalConnectionConfiguration struct { + _ struct{} `type:"structure"` + + // The condition that triggers this connection. For more information about how + // to write conditions, see the Condition node type in the Node types (https://docs.aws.amazon.com/bedrock/latest/userguide/node-types.html) + // topic in the Amazon Bedrock User Guide. + // + // Condition is a required field + Condition *string `locationName:"condition" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConditionalConnectionConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConditionalConnectionConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowConditionalConnectionConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowConditionalConnectionConfiguration"} + if s.Condition == nil { + invalidParams.Add(request.NewErrParamRequired("Condition")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCondition sets the Condition field's value. +func (s *FlowConditionalConnectionConfiguration) SetCondition(v string) *FlowConditionalConnectionConfiguration { + s.Condition = &v + return s +} + +// Contains information about a connection between two nodes in the flow. +type FlowConnection struct { + _ struct{} `type:"structure"` + + // The configuration of the connection. + Configuration *FlowConnectionConfiguration `locationName:"configuration" type:"structure"` + + // A name for the connection that you can reference. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The node that the connection starts at. + // + // Source is a required field + Source *string `locationName:"source" type:"string" required:"true"` + + // The node that the connection ends at. + // + // Target is a required field + Target *string `locationName:"target" type:"string" required:"true"` + + // Whether the source node that the connection begins from is a condition node + // (Conditional) or not (Data). + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"FlowConnectionType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConnection) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConnection) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowConnection) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowConnection"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Source == nil { + invalidParams.Add(request.NewErrParamRequired("Source")) + } + if s.Target == nil { + invalidParams.Add(request.NewErrParamRequired("Target")) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.Configuration != nil { + if err := s.Configuration.Validate(); err != nil { + invalidParams.AddNested("Configuration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfiguration sets the Configuration field's value. +func (s *FlowConnection) SetConfiguration(v *FlowConnectionConfiguration) *FlowConnection { + s.Configuration = v + return s +} + +// SetName sets the Name field's value. +func (s *FlowConnection) SetName(v string) *FlowConnection { + s.Name = &v + return s +} + +// SetSource sets the Source field's value. +func (s *FlowConnection) SetSource(v string) *FlowConnection { + s.Source = &v + return s +} + +// SetTarget sets the Target field's value. +func (s *FlowConnection) SetTarget(v string) *FlowConnection { + s.Target = &v + return s +} + +// SetType sets the Type field's value. +func (s *FlowConnection) SetType(v string) *FlowConnection { + s.Type = &v + return s +} + +// The configuration of the connection. +type FlowConnectionConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration of a connection originating from a Condition node. + Conditional *FlowConditionalConnectionConfiguration `locationName:"conditional" type:"structure"` + + // The configuration of a connection originating from a node that isn't a Condition + // node. + Data *FlowDataConnectionConfiguration `locationName:"data" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConnectionConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowConnectionConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowConnectionConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowConnectionConfiguration"} + if s.Conditional != nil { + if err := s.Conditional.Validate(); err != nil { + invalidParams.AddNested("Conditional", err.(request.ErrInvalidParams)) + } + } + if s.Data != nil { + if err := s.Data.Validate(); err != nil { + invalidParams.AddNested("Data", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConditional sets the Conditional field's value. +func (s *FlowConnectionConfiguration) SetConditional(v *FlowConditionalConnectionConfiguration) *FlowConnectionConfiguration { + s.Conditional = v + return s +} + +// SetData sets the Data field's value. +func (s *FlowConnectionConfiguration) SetData(v *FlowDataConnectionConfiguration) *FlowConnectionConfiguration { + s.Data = v + return s +} + +// The configuration of a connection originating from a node that isn't a Condition +// node. +type FlowDataConnectionConfiguration struct { + _ struct{} `type:"structure"` + + // The name of the output in the source node that the connection begins from. + // + // SourceOutput is a required field + SourceOutput *string `locationName:"sourceOutput" type:"string" required:"true"` + + // The name of the input in the target node that the connection ends at. + // + // TargetInput is a required field + TargetInput *string `locationName:"targetInput" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowDataConnectionConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowDataConnectionConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowDataConnectionConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowDataConnectionConfiguration"} + if s.SourceOutput == nil { + invalidParams.Add(request.NewErrParamRequired("SourceOutput")) + } + if s.TargetInput == nil { + invalidParams.Add(request.NewErrParamRequired("TargetInput")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetSourceOutput sets the SourceOutput field's value. +func (s *FlowDataConnectionConfiguration) SetSourceOutput(v string) *FlowDataConnectionConfiguration { + s.SourceOutput = &v + return s +} + +// SetTargetInput sets the TargetInput field's value. +func (s *FlowDataConnectionConfiguration) SetTargetInput(v string) *FlowDataConnectionConfiguration { + s.TargetInput = &v + return s +} + +// The definition of the nodes and connections between nodes in the flow. +type FlowDefinition struct { + _ struct{} `type:"structure"` + + // An array of connection definitions in the flow. + Connections []*FlowConnection `locationName:"connections" type:"list"` + + // An array of node definitions in the flow. + // + // Nodes is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by FlowDefinition's + // String and GoString methods. + Nodes []*FlowNode `locationName:"nodes" type:"list" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowDefinition) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowDefinition) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowDefinition) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowDefinition"} + if s.Connections != nil { + for i, v := range s.Connections { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Connections", i), err.(request.ErrInvalidParams)) + } + } + } + if s.Nodes != nil { + for i, v := range s.Nodes { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Nodes", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConnections sets the Connections field's value. +func (s *FlowDefinition) SetConnections(v []*FlowConnection) *FlowDefinition { + s.Connections = v + return s +} + +// SetNodes sets the Nodes field's value. +func (s *FlowDefinition) SetNodes(v []*FlowNode) *FlowDefinition { + s.Nodes = v + return s +} + +// Contains configurations about a node in the flow. +type FlowNode struct { + _ struct{} `type:"structure"` + + // Contains configurations for the node. + Configuration *FlowNodeConfiguration `locationName:"configuration" type:"structure"` + + // An array of objects, each of which contains information about an input into + // the node. + Inputs []*FlowNodeInput_ `locationName:"inputs" type:"list"` + + // A name for the node. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // A list of objects, each of which contains information about an output from + // the node. + Outputs []*FlowNodeOutput_ `locationName:"outputs" type:"list"` + + // 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. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"FlowNodeType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNode) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNode) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowNode) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowNode"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.Configuration != nil { + if err := s.Configuration.Validate(); err != nil { + invalidParams.AddNested("Configuration", err.(request.ErrInvalidParams)) + } + } + if s.Inputs != nil { + for i, v := range s.Inputs { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Inputs", i), err.(request.ErrInvalidParams)) + } + } + } + if s.Outputs != nil { + for i, v := range s.Outputs { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Outputs", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfiguration sets the Configuration field's value. +func (s *FlowNode) SetConfiguration(v *FlowNodeConfiguration) *FlowNode { + s.Configuration = v + return s +} + +// SetInputs sets the Inputs field's value. +func (s *FlowNode) SetInputs(v []*FlowNodeInput_) *FlowNode { + s.Inputs = v + return s +} + +// SetName sets the Name field's value. +func (s *FlowNode) SetName(v string) *FlowNode { + s.Name = &v + return s +} + +// SetOutputs sets the Outputs field's value. +func (s *FlowNode) SetOutputs(v []*FlowNodeOutput_) *FlowNode { + s.Outputs = v + return s +} + +// SetType sets the Type field's value. +func (s *FlowNode) SetType(v string) *FlowNode { + s.Type = &v + return s +} + +// Contains configurations for a node in your flow. For more information, see +// Node types in Amazon Bedrock works (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type FlowNodeConfiguration struct { + _ struct{} `type:"structure"` + + // Contains configurations for an agent node in your flow. Invokes an alias + // of an agent and returns the response. + Agent *AgentFlowNodeConfiguration `locationName:"agent" type:"structure"` + + // Contains configurations for a collector node in your flow. Collects an iteration + // of inputs and consolidates them into an array of outputs. + Collector *CollectorFlowNodeConfiguration `locationName:"collector" type:"structure"` + + // Contains configurations for a Condition node in your flow. Defines conditions + // that lead to different branches of the flow. + Condition *ConditionFlowNodeConfiguration `locationName:"condition" type:"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. + Input *InputFlowNodeConfiguration `locationName:"input" type:"structure"` + + // 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. + Iterator *IteratorFlowNodeConfiguration `locationName:"iterator" type:"structure"` + + // Contains configurations for a knowledge base node in your flow. Queries a + // knowledge base and returns the retrieved results or generated response. + KnowledgeBase *KnowledgeBaseFlowNodeConfiguration `locationName:"knowledgeBase" type:"structure"` + + // Contains configurations for a Lambda function node in your flow. Invokes + // an Lambda function. + LambdaFunction *LambdaFunctionFlowNodeConfiguration `locationName:"lambdaFunction" type:"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. + Lex *LexFlowNodeConfiguration `locationName:"lex" type:"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. + Output *OutputFlowNodeConfiguration `locationName:"output" type:"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. + Prompt *PromptFlowNodeConfiguration `locationName:"prompt" type:"structure"` + + // Contains configurations for a Retrieval node in your flow. Retrieves data + // from an Amazon S3 location and returns it as the output. + Retrieval *RetrievalFlowNodeConfiguration `locationName:"retrieval" type:"structure"` + + // Contains configurations for a Storage node in your flow. Stores an input + // in an Amazon S3 location. + Storage *StorageFlowNodeConfiguration `locationName:"storage" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowNodeConfiguration"} + if s.Agent != nil { + if err := s.Agent.Validate(); err != nil { + invalidParams.AddNested("Agent", err.(request.ErrInvalidParams)) + } + } + if s.Condition != nil { + if err := s.Condition.Validate(); err != nil { + invalidParams.AddNested("Condition", err.(request.ErrInvalidParams)) + } + } + if s.KnowledgeBase != nil { + if err := s.KnowledgeBase.Validate(); err != nil { + invalidParams.AddNested("KnowledgeBase", err.(request.ErrInvalidParams)) + } + } + if s.LambdaFunction != nil { + if err := s.LambdaFunction.Validate(); err != nil { + invalidParams.AddNested("LambdaFunction", err.(request.ErrInvalidParams)) + } + } + if s.Lex != nil { + if err := s.Lex.Validate(); err != nil { + invalidParams.AddNested("Lex", err.(request.ErrInvalidParams)) + } + } + if s.Prompt != nil { + if err := s.Prompt.Validate(); err != nil { + invalidParams.AddNested("Prompt", err.(request.ErrInvalidParams)) + } + } + if s.Retrieval != nil { + if err := s.Retrieval.Validate(); err != nil { + invalidParams.AddNested("Retrieval", err.(request.ErrInvalidParams)) + } + } + if s.Storage != nil { + if err := s.Storage.Validate(); err != nil { + invalidParams.AddNested("Storage", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgent sets the Agent field's value. +func (s *FlowNodeConfiguration) SetAgent(v *AgentFlowNodeConfiguration) *FlowNodeConfiguration { + s.Agent = v + return s +} + +// SetCollector sets the Collector field's value. +func (s *FlowNodeConfiguration) SetCollector(v *CollectorFlowNodeConfiguration) *FlowNodeConfiguration { + s.Collector = v + return s +} + +// SetCondition sets the Condition field's value. +func (s *FlowNodeConfiguration) SetCondition(v *ConditionFlowNodeConfiguration) *FlowNodeConfiguration { + s.Condition = v + return s +} + +// SetInput sets the Input field's value. +func (s *FlowNodeConfiguration) SetInput(v *InputFlowNodeConfiguration) *FlowNodeConfiguration { + s.Input = v + return s +} + +// SetIterator sets the Iterator field's value. +func (s *FlowNodeConfiguration) SetIterator(v *IteratorFlowNodeConfiguration) *FlowNodeConfiguration { + s.Iterator = v + return s +} + +// SetKnowledgeBase sets the KnowledgeBase field's value. +func (s *FlowNodeConfiguration) SetKnowledgeBase(v *KnowledgeBaseFlowNodeConfiguration) *FlowNodeConfiguration { + s.KnowledgeBase = v + return s +} + +// SetLambdaFunction sets the LambdaFunction field's value. +func (s *FlowNodeConfiguration) SetLambdaFunction(v *LambdaFunctionFlowNodeConfiguration) *FlowNodeConfiguration { + s.LambdaFunction = v + return s +} + +// SetLex sets the Lex field's value. +func (s *FlowNodeConfiguration) SetLex(v *LexFlowNodeConfiguration) *FlowNodeConfiguration { + s.Lex = v + return s +} + +// SetOutput sets the Output field's value. +func (s *FlowNodeConfiguration) SetOutput(v *OutputFlowNodeConfiguration) *FlowNodeConfiguration { + s.Output = v + return s +} + +// SetPrompt sets the Prompt field's value. +func (s *FlowNodeConfiguration) SetPrompt(v *PromptFlowNodeConfiguration) *FlowNodeConfiguration { + s.Prompt = v + return s +} + +// SetRetrieval sets the Retrieval field's value. +func (s *FlowNodeConfiguration) SetRetrieval(v *RetrievalFlowNodeConfiguration) *FlowNodeConfiguration { + s.Retrieval = v + return s +} + +// SetStorage sets the Storage field's value. +func (s *FlowNodeConfiguration) SetStorage(v *StorageFlowNodeConfiguration) *FlowNodeConfiguration { + s.Storage = v + return s +} + +// Contains configurations for an input to a node. +type FlowNodeInput_ struct { + _ struct{} `type:"structure"` + + // 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 + // (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-expressions.html). + // + // Expression is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by FlowNodeInput_'s + // String and GoString methods. + // + // Expression is a required field + Expression *string `locationName:"expression" min:"1" type:"string" required:"true" sensitive:"true"` + + // A name for the input that you can reference. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The data type of the input. If the input doesn't match this type at runtime, + // a validation error will be thrown. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"FlowNodeIODataType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeInput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeInput_) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowNodeInput_) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowNodeInput_"} + if s.Expression == nil { + invalidParams.Add(request.NewErrParamRequired("Expression")) + } + if s.Expression != nil && len(*s.Expression) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Expression", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetExpression sets the Expression field's value. +func (s *FlowNodeInput_) SetExpression(v string) *FlowNodeInput_ { + s.Expression = &v + return s +} + +// SetName sets the Name field's value. +func (s *FlowNodeInput_) SetName(v string) *FlowNodeInput_ { + s.Name = &v + return s +} + +// SetType sets the Type field's value. +func (s *FlowNodeInput_) SetType(v string) *FlowNodeInput_ { + s.Type = &v + return s +} + +// Contains configurations for an output from a node. +type FlowNodeOutput_ struct { + _ struct{} `type:"structure"` + + // A name for the output that you can reference. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The data type of the output. If the output doesn't match this type at runtime, + // a validation error will be thrown. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"FlowNodeIODataType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeOutput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowNodeOutput_) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowNodeOutput_) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowNodeOutput_"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *FlowNodeOutput_) SetName(v string) *FlowNodeOutput_ { + s.Name = &v + return s +} + +// SetType sets the Type field's value. +func (s *FlowNodeOutput_) SetType(v string) *FlowNodeOutput_ { + s.Type = &v + return s +} + +// Contains the definition of a flow. +type FlowSummary struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the flow. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the flow was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the flow. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PrepareFlow.html) + // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetFlow.html) + // request and check the error message in the validations field. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` + + // The time at which the flow was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The latest version of the flow. + // + // Version is a required field + Version *string `locationName:"version" min:"5" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowSummary) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *FlowSummary) SetArn(v string) *FlowSummary { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *FlowSummary) SetCreatedAt(v time.Time) *FlowSummary { + s.CreatedAt = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *FlowSummary) SetDescription(v string) *FlowSummary { + s.Description = &v + return s +} + +// SetId sets the Id field's value. +func (s *FlowSummary) SetId(v string) *FlowSummary { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *FlowSummary) SetName(v string) *FlowSummary { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *FlowSummary) SetStatus(v string) *FlowSummary { + s.Status = &v + return s +} + +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *FlowSummary) SetUpdatedAt(v time.Time) *FlowSummary { + s.UpdatedAt = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *FlowSummary) SetVersion(v string) *FlowSummary { + s.Version = &v + return s +} + +// Contains information about validation of the flow. +// +// This data type is used in the following API operations: +// +// - GetFlow response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetFlow.html#API_agent_GetFlow_ResponseSyntax) +// +// - GetFlowVersion response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetFlowVersion.html#API_agent_GetFlowVersion_ResponseSyntax) +type FlowValidation struct { + _ struct{} `type:"structure"` + + // A message describing the validation error. + // + // Message is a required field + Message *string `locationName:"message" type:"string" required:"true"` + + // The severity of the issue described in the message. + // + // Severity is a required field + Severity *string `locationName:"severity" type:"string" required:"true" enum:"FlowValidationSeverity"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowValidation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowValidation) GoString() string { + return s.String() +} + +// SetMessage sets the Message field's value. +func (s *FlowValidation) SetMessage(v string) *FlowValidation { + s.Message = &v + return s +} + +// SetSeverity sets the Severity field's value. +func (s *FlowValidation) SetSeverity(v string) *FlowValidation { + s.Severity = &v + return s +} + +// Contains information about the flow version. +// +// This data type is used in the following API operations: +// +// - ListFlowVersions response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_ListFlowVersions.html#API_agent_ListFlowVersions_ResponseSyntax) +type FlowVersionSummary struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the flow that the version belongs to. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at the flow version was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The status of the flow. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` + + // The version of the flow. + // + // Version is a required field + Version *string `locationName:"version" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowVersionSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowVersionSummary) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *FlowVersionSummary) SetArn(v string) *FlowVersionSummary { + s.Arn = &v + return s +} + +// SetCreatedAt sets the CreatedAt field's value. +func (s *FlowVersionSummary) SetCreatedAt(v time.Time) *FlowVersionSummary { + s.CreatedAt = &v + return s +} + +// SetId sets the Id field's value. +func (s *FlowVersionSummary) SetId(v string) *FlowVersionSummary { + s.Id = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *FlowVersionSummary) SetStatus(v string) *FlowVersionSummary { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *FlowVersionSummary) SetVersion(v string) *FlowVersionSummary { + s.Version = &v + return s +} + +// 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: +// +// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) +// +// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) +// +// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) +// +// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) +// +// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) +type Function struct { + _ struct{} `type:"structure"` + + // A description of the function and its purpose. + Description *string `locationName:"description" min:"1" type:"string"` + + // A name for the function. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The parameters that the agent elicits from the user to fulfill the function. + Parameters map[string]*ParameterDetail `locationName:"parameters" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Function) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Function) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Function) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Function"} + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Parameters != nil { + for i, v := range s.Parameters { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Parameters", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDescription sets the Description field's value. +func (s *Function) SetDescription(v string) *Function { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *Function) SetName(v string) *Function { + s.Name = &v + return s +} + +// SetParameters sets the Parameters field's value. +func (s *Function) SetParameters(v map[string]*ParameterDetail) *Function { + s.Parameters = v + return s +} + +// 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: +// +// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) +// +// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) +// +// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) +// +// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) +// +// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) +type FunctionSchema struct { + _ struct{} `type:"structure"` + + // A list of functions that each define an action in the action group. + Functions []*Function `locationName:"functions" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FunctionSchema) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FunctionSchema) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FunctionSchema) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FunctionSchema"} + if s.Functions != nil { + for i, v := range s.Functions { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Functions", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFunctions sets the Functions field's value. +func (s *FunctionSchema) SetFunctions(v []*Function) *FunctionSchema { + s.Functions = v + return s +} + +type GetAgentActionGroupInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the action group for which to get information. + // + // ActionGroupId is a required field + ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` + + // The unique identifier of the agent that the action group belongs to. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent that the action group belongs to. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentActionGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentActionGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentActionGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentActionGroupInput"} + if s.ActionGroupId == nil { + invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) + } + if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetActionGroupId sets the ActionGroupId field's value. +func (s *GetAgentActionGroupInput) SetActionGroupId(v string) *GetAgentActionGroupInput { + s.ActionGroupId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentActionGroupInput) SetAgentId(v string) *GetAgentActionGroupInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *GetAgentActionGroupInput) SetAgentVersion(v string) *GetAgentActionGroupInput { + s.AgentVersion = &v + return s +} + +type GetAgentActionGroupOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the action group. + // + // AgentActionGroup is a required field + AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentActionGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentActionGroupOutput) GoString() string { + return s.String() +} + +// SetAgentActionGroup sets the AgentActionGroup field's value. +func (s *GetAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *GetAgentActionGroupOutput { + s.AgentActionGroup = v + return s +} + +type GetAgentAliasInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the alias for which to get information. + // + // AgentAliasId is a required field + AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` + + // The unique identifier of the agent to which the alias to get information + // belongs. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentAliasInput"} + if s.AgentAliasId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) + } + if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { + invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *GetAgentAliasInput) SetAgentAliasId(v string) *GetAgentAliasInput { + s.AgentAliasId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentAliasInput) SetAgentId(v string) *GetAgentAliasInput { + s.AgentId = &v + return s +} + +type GetAgentAliasOutput struct { + _ struct{} `type:"structure"` + + // Contains information about the alias. + // + // AgentAlias is a required field + AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentAliasOutput) GoString() string { + return s.String() +} + +// SetAgentAlias sets the AgentAlias field's value. +func (s *GetAgentAliasOutput) SetAgentAlias(v *AgentAlias) *GetAgentAliasOutput { + s.AgentAlias = v + return s +} + +type GetAgentInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentInput) SetAgentId(v string) *GetAgentInput { + s.AgentId = &v + return s +} + +type GetAgentKnowledgeBaseInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent with which the knowledge base is associated. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent with which the knowledge base is associated. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` + + // The unique identifier of the knowledge base associated with the agent. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentKnowledgeBaseInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentKnowledgeBaseInput) SetAgentId(v string) *GetAgentKnowledgeBaseInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *GetAgentKnowledgeBaseInput) SetAgentVersion(v string) *GetAgentKnowledgeBaseInput { + s.AgentVersion = &v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *GetAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *GetAgentKnowledgeBaseInput { + s.KnowledgeBaseId = &v + return s +} + +type GetAgentKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` + + // Contains details about a knowledge base attached to an agent. + // + // AgentKnowledgeBase is a required field + AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentKnowledgeBaseOutput) GoString() string { + return s.String() +} + +// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. +func (s *GetAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *GetAgentKnowledgeBaseOutput { + s.AgentKnowledgeBase = v + return s +} + +type GetAgentOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the agent. + // + // Agent is a required field + Agent *Agent `locationName:"agent" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentOutput) GoString() string { + return s.String() +} + +// SetAgent sets the Agent field's value. +func (s *GetAgentOutput) SetAgent(v *Agent) *GetAgentOutput { + s.Agent = v + return s +} + +type GetAgentVersionInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The version of the agent. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentVersionInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentVersionInput) SetAgentId(v string) *GetAgentVersionInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *GetAgentVersionInput) SetAgentVersion(v string) *GetAgentVersionInput { + s.AgentVersion = &v + return s +} + +type GetAgentVersionOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the version of the agent. + // + // AgentVersion is a required field + AgentVersion *AgentVersion `locationName:"agentVersion" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentVersionOutput) GoString() string { + return s.String() +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *GetAgentVersionOutput) SetAgentVersion(v *AgentVersion) *GetAgentVersionOutput { + s.AgentVersion = v + return s +} + +type GetDataSourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the data source. + // + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + + // The unique identifier of the knowledge base that the data source was added + // to. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetDataSourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetDataSourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetDataSourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetDataSourceInput"} + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) + } + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) } - return "" -} -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *AccessDeniedException) OrigErr() error { + if invalidParams.Len() > 0 { + return invalidParams + } return nil } -func (s *AccessDeniedException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +// SetDataSourceId sets the DataSourceId field's value. +func (s *GetDataSourceInput) SetDataSourceId(v string) *GetDataSourceInput { + s.DataSourceId = &v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *AccessDeniedException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *GetDataSourceInput) SetKnowledgeBaseId(v string) *GetDataSourceInput { + s.KnowledgeBaseId = &v + return s } -// RequestID returns the service's response RequestID for request. -func (s *AccessDeniedException) RequestID() string { - return s.RespMetadata.RequestID +type GetDataSourceOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the data source. + // + // DataSource is a required field + DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` } -// 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. -type ActionGroupExecutor struct { - _ struct{} `type:"structure"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetDataSourceOutput) String() string { + return awsutil.Prettify(s) +} - // To return the action group invocation results directly in the InvokeAgent - // response, specify RETURN_CONTROL. - CustomControl *string `locationName:"customControl" type:"string" enum:"CustomControlMethod"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetDataSourceOutput) GoString() string { + return s.String() +} - // The Amazon Resource Name (ARN) of the Lambda function containing the business - // logic that is carried out upon invoking the action. - Lambda *string `locationName:"lambda" type:"string"` +// SetDataSource sets the DataSource field's value. +func (s *GetDataSourceOutput) SetDataSource(v *DataSource) *GetDataSourceOutput { + s.DataSource = v + return s +} + +type GetFlowAliasInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the alias for which to retrieve information. + // + // AliasIdentifier is a required field + AliasIdentifier *string `location:"uri" locationName:"aliasIdentifier" type:"string" required:"true"` + + // The unique identifier of the flow that the alias belongs to. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` } // String returns the string representation. @@ -4468,7 +15056,7 @@ type ActionGroupExecutor struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ActionGroupExecutor) String() string { +func (s GetFlowAliasInput) String() string { return awsutil.Prettify(s) } @@ -4477,47 +15065,81 @@ func (s ActionGroupExecutor) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ActionGroupExecutor) GoString() string { +func (s GetFlowAliasInput) GoString() string { return s.String() } -// SetCustomControl sets the CustomControl field's value. -func (s *ActionGroupExecutor) SetCustomControl(v string) *ActionGroupExecutor { - s.CustomControl = &v +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFlowAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFlowAliasInput"} + if s.AliasIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("AliasIdentifier")) + } + if s.AliasIdentifier != nil && len(*s.AliasIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AliasIdentifier", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAliasIdentifier sets the AliasIdentifier field's value. +func (s *GetFlowAliasInput) SetAliasIdentifier(v string) *GetFlowAliasInput { + s.AliasIdentifier = &v return s } -// SetLambda sets the Lambda field's value. -func (s *ActionGroupExecutor) SetLambda(v string) *ActionGroupExecutor { - s.Lambda = &v +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *GetFlowAliasInput) SetFlowIdentifier(v string) *GetFlowAliasInput { + s.FlowIdentifier = &v return s } -// Contains details about an action group. -type ActionGroupSummary struct { +type GetFlowAliasOutput struct { _ struct{} `type:"structure"` - // The unique identifier of the action group. + // The Amazon Resource Name (ARN) of the flow. // - // ActionGroupId is a required field - ActionGroupId *string `locationName:"actionGroupId" type:"string" required:"true"` + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` - // The name of the action group. + // The time at which the flow was created. // - // ActionGroupName is a required field - ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // Specifies whether the action group is available for the agent to invoke or - // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. + // The description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow that the alias belongs to. // - // ActionGroupState is a required field - ActionGroupState *string `locationName:"actionGroupState" type:"string" required:"true" enum:"ActionGroupState"` + // FlowId is a required field + FlowId *string `locationName:"flowId" type:"string" required:"true"` - // The description of the action group. - Description *string `locationName:"description" min:"1" type:"string"` + // The unique identifier of the alias of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // The time at which the action group was last updated. + // The name of the flow alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains information about the version that the alias is mapped to. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` + + // The time at which the flow alias was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` @@ -4528,7 +15150,7 @@ type ActionGroupSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ActionGroupSummary) String() string { +func (s GetFlowAliasOutput) String() string { return awsutil.Prettify(s) } @@ -4537,153 +15159,181 @@ func (s ActionGroupSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ActionGroupSummary) GoString() string { +func (s GetFlowAliasOutput) GoString() string { return s.String() } -// SetActionGroupId sets the ActionGroupId field's value. -func (s *ActionGroupSummary) SetActionGroupId(v string) *ActionGroupSummary { - s.ActionGroupId = &v +// SetArn sets the Arn field's value. +func (s *GetFlowAliasOutput) SetArn(v string) *GetFlowAliasOutput { + s.Arn = &v return s } -// SetActionGroupName sets the ActionGroupName field's value. -func (s *ActionGroupSummary) SetActionGroupName(v string) *ActionGroupSummary { - s.ActionGroupName = &v +// SetCreatedAt sets the CreatedAt field's value. +func (s *GetFlowAliasOutput) SetCreatedAt(v time.Time) *GetFlowAliasOutput { + s.CreatedAt = &v return s } -// SetActionGroupState sets the ActionGroupState field's value. -func (s *ActionGroupSummary) SetActionGroupState(v string) *ActionGroupSummary { - s.ActionGroupState = &v +// SetDescription sets the Description field's value. +func (s *GetFlowAliasOutput) SetDescription(v string) *GetFlowAliasOutput { + s.Description = &v return s } -// SetDescription sets the Description field's value. -func (s *ActionGroupSummary) SetDescription(v string) *ActionGroupSummary { - s.Description = &v +// SetFlowId sets the FlowId field's value. +func (s *GetFlowAliasOutput) SetFlowId(v string) *GetFlowAliasOutput { + s.FlowId = &v + return s +} + +// SetId sets the Id field's value. +func (s *GetFlowAliasOutput) SetId(v string) *GetFlowAliasOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetFlowAliasOutput) SetName(v string) *GetFlowAliasOutput { + s.Name = &v + return s +} + +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *GetFlowAliasOutput) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *GetFlowAliasOutput { + s.RoutingConfiguration = v return s } // SetUpdatedAt sets the UpdatedAt field's value. -func (s *ActionGroupSummary) SetUpdatedAt(v time.Time) *ActionGroupSummary { +func (s *GetFlowAliasOutput) SetUpdatedAt(v time.Time) *GetFlowAliasOutput { s.UpdatedAt = &v return s } -// Contains details about an agent. -type Agent struct { - _ struct{} `type:"structure"` +type GetFlowInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The Amazon Resource Name (ARN) of the agent. + // The unique identifier of the flow. // - // AgentArn is a required field - AgentArn *string `locationName:"agentArn" type:"string" required:"true"` + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` +} - // The unique identifier of the agent. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowInput) String() string { + return awsutil.Prettify(s) +} - // The name of the agent. - // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowInput) GoString() string { + return s.String() +} - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the agent. - // - // AgentResourceRoleArn is a required field - AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFlowInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } - // 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. - // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // The version of the agent. - // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" min:"5" type:"string" required:"true"` +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *GetFlowInput) SetFlowIdentifier(v string) *GetFlowInput { + s.FlowIdentifier = &v + return s +} - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string"` +type GetFlowOutput struct { + _ struct{} `type:"structure"` - // The time at which the agent was created. + // The Amazon Resource Name (ARN) of the flow. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the flow was created. // // CreatedAt is a required field CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The Amazon Resource Name (ARN) of the KMS key that encrypts the agent. - CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - - // The description of the agent. - Description *string `locationName:"description" min:"1" type:"string"` - - // Contains reasons that the agent-related API that you invoked failed. - FailureReasons []*string `locationName:"failureReasons" type:"list"` - - // The foundation model used for orchestration by the agent. - FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the KMS key that the flow is encrypted + // with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - // The guardrails configuration assigned to the agent. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + // The definition of the nodes and connections between the nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` - // 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. - // - // IdleSessionTTLInSeconds is a required field - IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer" required:"true"` + // The description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` - // Instructions that tell the agent what it should do and how it should interact - // with users. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. // - // Instruction is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by Agent's - // String and GoString methods. - Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` - // The time at which the agent was last prepared. - PreparedAt *time.Time `locationName:"preparedAt" type:"timestamp" timestampFormat:"iso8601"` + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // Contains configurations to override prompt templates in different parts of - // an agent sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // The name of the flow. // - // PromptOverrideConfiguration is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by Agent's - // String and GoString methods. - PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // Contains recommended actions to take for the agent-related API that you invoked - // to succeed. - RecommendedActions []*string `locationName:"recommendedActions" type:"list"` + // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PrepareFlow.html) + // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetFlow.html) + // request and check the error message in the validations field. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` - // The time at which the agent was last updated. + // The time at which the flow was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A list of validation error messages related to the last failed operation + // on the flow. + Validations []*FlowValidation `locationName:"validations" type:"list"` + + // The version of the flow for which information was retrieved. + // + // Version is a required field + Version *string `locationName:"version" min:"5" type:"string" required:"true"` } // String returns the string representation. @@ -4691,7 +15341,7 @@ type Agent struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Agent) String() string { +func (s GetFlowOutput) String() string { return awsutil.Prettify(s) } @@ -4700,367 +15350,295 @@ func (s Agent) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Agent) GoString() string { +func (s GetFlowOutput) GoString() string { return s.String() } -// SetAgentArn sets the AgentArn field's value. -func (s *Agent) SetAgentArn(v string) *Agent { - s.AgentArn = &v +// SetArn sets the Arn field's value. +func (s *GetFlowOutput) SetArn(v string) *GetFlowOutput { + s.Arn = &v return s } -// SetAgentId sets the AgentId field's value. -func (s *Agent) SetAgentId(v string) *Agent { - s.AgentId = &v +// SetCreatedAt sets the CreatedAt field's value. +func (s *GetFlowOutput) SetCreatedAt(v time.Time) *GetFlowOutput { + s.CreatedAt = &v return s } -// SetAgentName sets the AgentName field's value. -func (s *Agent) SetAgentName(v string) *Agent { - s.AgentName = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *GetFlowOutput) SetCustomerEncryptionKeyArn(v string) *GetFlowOutput { + s.CustomerEncryptionKeyArn = &v return s } -// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. -func (s *Agent) SetAgentResourceRoleArn(v string) *Agent { - s.AgentResourceRoleArn = &v +// SetDefinition sets the Definition field's value. +func (s *GetFlowOutput) SetDefinition(v *FlowDefinition) *GetFlowOutput { + s.Definition = v return s } -// SetAgentStatus sets the AgentStatus field's value. -func (s *Agent) SetAgentStatus(v string) *Agent { - s.AgentStatus = &v +// SetDescription sets the Description field's value. +func (s *GetFlowOutput) SetDescription(v string) *GetFlowOutput { + s.Description = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *Agent) SetAgentVersion(v string) *Agent { - s.AgentVersion = &v +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *GetFlowOutput) SetExecutionRoleArn(v string) *GetFlowOutput { + s.ExecutionRoleArn = &v return s } -// SetClientToken sets the ClientToken field's value. -func (s *Agent) SetClientToken(v string) *Agent { - s.ClientToken = &v +// SetId sets the Id field's value. +func (s *GetFlowOutput) SetId(v string) *GetFlowOutput { + s.Id = &v return s } -// SetCreatedAt sets the CreatedAt field's value. -func (s *Agent) SetCreatedAt(v time.Time) *Agent { - s.CreatedAt = &v +// SetName sets the Name field's value. +func (s *GetFlowOutput) SetName(v string) *GetFlowOutput { + s.Name = &v return s } -// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. -func (s *Agent) SetCustomerEncryptionKeyArn(v string) *Agent { - s.CustomerEncryptionKeyArn = &v +// SetStatus sets the Status field's value. +func (s *GetFlowOutput) SetStatus(v string) *GetFlowOutput { + s.Status = &v return s } -// SetDescription sets the Description field's value. -func (s *Agent) SetDescription(v string) *Agent { - s.Description = &v +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *GetFlowOutput) SetUpdatedAt(v time.Time) *GetFlowOutput { + s.UpdatedAt = &v return s } -// SetFailureReasons sets the FailureReasons field's value. -func (s *Agent) SetFailureReasons(v []*string) *Agent { - s.FailureReasons = v +// SetValidations sets the Validations field's value. +func (s *GetFlowOutput) SetValidations(v []*FlowValidation) *GetFlowOutput { + s.Validations = v return s } -// SetFoundationModel sets the FoundationModel field's value. -func (s *Agent) SetFoundationModel(v string) *Agent { - s.FoundationModel = &v +// SetVersion sets the Version field's value. +func (s *GetFlowOutput) SetVersion(v string) *GetFlowOutput { + s.Version = &v return s } -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *Agent) SetGuardrailConfiguration(v *GuardrailConfiguration) *Agent { - s.GuardrailConfiguration = v - return s -} +type GetFlowVersionInput struct { + _ struct{} `type:"structure" nopayload:"true"` -// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. -func (s *Agent) SetIdleSessionTTLInSeconds(v int64) *Agent { - s.IdleSessionTTLInSeconds = &v - return s + // The unique identifier of the flow for which to get information. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` + + // The version of the flow for which to get information. + // + // FlowVersion is a required field + FlowVersion *string `location:"uri" locationName:"flowVersion" type:"string" required:"true"` } -// SetInstruction sets the Instruction field's value. -func (s *Agent) SetInstruction(v string) *Agent { - s.Instruction = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowVersionInput) String() string { + return awsutil.Prettify(s) } -// SetPreparedAt sets the PreparedAt field's value. -func (s *Agent) SetPreparedAt(v time.Time) *Agent { - s.PreparedAt = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowVersionInput) GoString() string { + return s.String() } -// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. -func (s *Agent) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *Agent { - s.PromptOverrideConfiguration = v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFlowVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFlowVersionInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + if s.FlowVersion == nil { + invalidParams.Add(request.NewErrParamRequired("FlowVersion")) + } + if s.FlowVersion != nil && len(*s.FlowVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetRecommendedActions sets the RecommendedActions field's value. -func (s *Agent) SetRecommendedActions(v []*string) *Agent { - s.RecommendedActions = v +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *GetFlowVersionInput) SetFlowIdentifier(v string) *GetFlowVersionInput { + s.FlowIdentifier = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *Agent) SetUpdatedAt(v time.Time) *Agent { - s.UpdatedAt = &v +// SetFlowVersion sets the FlowVersion field's value. +func (s *GetFlowVersionInput) SetFlowVersion(v string) *GetFlowVersionInput { + s.FlowVersion = &v return s } -// Contains details about an action group. -type AgentActionGroup struct { +type GetFlowVersionOutput struct { _ struct{} `type:"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. - ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` - - // The unique identifier of the action group. - // - // ActionGroupId is a required field - ActionGroupId *string `locationName:"actionGroupId" type:"string" required:"true"` - - // The name of the action group. - // - // ActionGroupName is a required field - ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` - - // Specifies whether the action group is available for the agent to invoke or - // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. + // The Amazon Resource Name (ARN) of the flow. // - // ActionGroupState is a required field - ActionGroupState *string `locationName:"actionGroupState" type:"string" required:"true" enum:"ActionGroupState"` + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` - // The unique identifier of the agent to which the action group belongs. + // The time at which the flow was created. // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The version of the agent to which the action group belongs. - // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + // The Amazon Resource Name (ARN) of the KMS key that the version of the flow + // is encrypted with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). - ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` + // The definition of the nodes and connections between nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string"` + // The description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` - // The time at which the action group was created. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` - // The description of the action group. - Description *string `locationName:"description" min:"1" type:"string"` + // The unique identifier of the flow. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // Defines functions that each define parameters that the agent needs to invoke - // from the user. Each function represents an action in an action group. - FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` + // The name of the flow version. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // 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. + // The status of the flow. // - // 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 - // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) - // reprompting the user for more information. - ParentActionSignature *string `locationName:"parentActionSignature" type:"string" enum:"ActionGroupSignature"` + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` - // The time at which the action group was last updated. + // The version of the flow for which information was retrieved. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // Version is a required field + Version *string `locationName:"version" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AgentActionGroup) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AgentActionGroup) GoString() string { - return s.String() -} - -// SetActionGroupExecutor sets the ActionGroupExecutor field's value. -func (s *AgentActionGroup) SetActionGroupExecutor(v *ActionGroupExecutor) *AgentActionGroup { - s.ActionGroupExecutor = v - return s -} - -// SetActionGroupId sets the ActionGroupId field's value. -func (s *AgentActionGroup) SetActionGroupId(v string) *AgentActionGroup { - s.ActionGroupId = &v - return s -} - -// SetActionGroupName sets the ActionGroupName field's value. -func (s *AgentActionGroup) SetActionGroupName(v string) *AgentActionGroup { - s.ActionGroupName = &v - return s -} - -// SetActionGroupState sets the ActionGroupState field's value. -func (s *AgentActionGroup) SetActionGroupState(v string) *AgentActionGroup { - s.ActionGroupState = &v - return s +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowVersionOutput) String() string { + return awsutil.Prettify(s) } -// SetAgentId sets the AgentId field's value. -func (s *AgentActionGroup) SetAgentId(v string) *AgentActionGroup { - s.AgentId = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetFlowVersionOutput) GoString() string { + return s.String() } -// SetAgentVersion sets the AgentVersion field's value. -func (s *AgentActionGroup) SetAgentVersion(v string) *AgentActionGroup { - s.AgentVersion = &v +// SetArn sets the Arn field's value. +func (s *GetFlowVersionOutput) SetArn(v string) *GetFlowVersionOutput { + s.Arn = &v return s } -// SetApiSchema sets the ApiSchema field's value. -func (s *AgentActionGroup) SetApiSchema(v *APISchema) *AgentActionGroup { - s.ApiSchema = v +// SetCreatedAt sets the CreatedAt field's value. +func (s *GetFlowVersionOutput) SetCreatedAt(v time.Time) *GetFlowVersionOutput { + s.CreatedAt = &v return s } -// SetClientToken sets the ClientToken field's value. -func (s *AgentActionGroup) SetClientToken(v string) *AgentActionGroup { - s.ClientToken = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *GetFlowVersionOutput) SetCustomerEncryptionKeyArn(v string) *GetFlowVersionOutput { + s.CustomerEncryptionKeyArn = &v return s } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentActionGroup) SetCreatedAt(v time.Time) *AgentActionGroup { - s.CreatedAt = &v +// SetDefinition sets the Definition field's value. +func (s *GetFlowVersionOutput) SetDefinition(v *FlowDefinition) *GetFlowVersionOutput { + s.Definition = v return s } // SetDescription sets the Description field's value. -func (s *AgentActionGroup) SetDescription(v string) *AgentActionGroup { +func (s *GetFlowVersionOutput) SetDescription(v string) *GetFlowVersionOutput { s.Description = &v return s } -// SetFunctionSchema sets the FunctionSchema field's value. -func (s *AgentActionGroup) SetFunctionSchema(v *FunctionSchema) *AgentActionGroup { - s.FunctionSchema = v +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *GetFlowVersionOutput) SetExecutionRoleArn(v string) *GetFlowVersionOutput { + s.ExecutionRoleArn = &v return s } -// SetParentActionSignature sets the ParentActionSignature field's value. -func (s *AgentActionGroup) SetParentActionSignature(v string) *AgentActionGroup { - s.ParentActionSignature = &v +// SetId sets the Id field's value. +func (s *GetFlowVersionOutput) SetId(v string) *GetFlowVersionOutput { + s.Id = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentActionGroup) SetUpdatedAt(v time.Time) *AgentActionGroup { - s.UpdatedAt = &v +// SetName sets the Name field's value. +func (s *GetFlowVersionOutput) SetName(v string) *GetFlowVersionOutput { + s.Name = &v return s } -// Contains details about an alias of an agent. -type AgentAlias struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the alias of the agent. - // - // AgentAliasArn is a required field - AgentAliasArn *string `locationName:"agentAliasArn" type:"string" required:"true"` - - // Contains details about the history of the alias. - AgentAliasHistoryEvents []*AgentAliasHistoryEvent `locationName:"agentAliasHistoryEvents" type:"list"` - - // The unique identifier of the alias of the agent. - // - // AgentAliasId is a required field - AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` - - // The name of the alias of the agent. - // - // AgentAliasName is a required field - AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` - - // 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. - // - // AgentAliasStatus is a required field - AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` +// SetStatus sets the Status field's value. +func (s *GetFlowVersionOutput) SetStatus(v string) *GetFlowVersionOutput { + s.Status = &v + return s +} - // The unique identifier of the agent. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` +// SetVersion sets the Version field's value. +func (s *GetFlowVersionOutput) SetVersion(v string) *GetFlowVersionOutput { + s.Version = &v + return s +} - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string"` +type GetIngestionJobInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The time at which the alias of the agent was created. + // The unique identifier of the data source in the ingestion job. // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - - // The description of the alias of the agent. - Description *string `locationName:"description" min:"1" type:"string"` - - // Information on the failure of Provisioned Throughput assigned to an agent - // alias. - FailureReasons []*string `locationName:"failureReasons" type:"list"` + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` - // Contains details about the routing configuration of the alias. + // The unique identifier of the ingestion job. // - // RoutingConfiguration is a required field - RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list" required:"true"` + // IngestionJobId is a required field + IngestionJobId *string `location:"uri" locationName:"ingestionJobId" type:"string" required:"true"` - // The time at which the alias was last updated. + // The unique identifier of the knowledge base for which the ingestion job applies. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` } // String returns the string representation. @@ -5068,7 +15646,7 @@ type AgentAlias struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAlias) String() string { +func (s GetIngestionJobInput) String() string { return awsutil.Prettify(s) } @@ -5077,96 +15655,145 @@ func (s AgentAlias) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAlias) GoString() string { +func (s GetIngestionJobInput) GoString() string { return s.String() } -// SetAgentAliasArn sets the AgentAliasArn field's value. -func (s *AgentAlias) SetAgentAliasArn(v string) *AgentAlias { - s.AgentAliasArn = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetIngestionJobInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetIngestionJobInput"} + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) + } + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) + } + if s.IngestionJobId == nil { + invalidParams.Add(request.NewErrParamRequired("IngestionJobId")) + } + if s.IngestionJobId != nil && len(*s.IngestionJobId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("IngestionJobId", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetAgentAliasHistoryEvents sets the AgentAliasHistoryEvents field's value. -func (s *AgentAlias) SetAgentAliasHistoryEvents(v []*AgentAliasHistoryEvent) *AgentAlias { - s.AgentAliasHistoryEvents = v +// SetDataSourceId sets the DataSourceId field's value. +func (s *GetIngestionJobInput) SetDataSourceId(v string) *GetIngestionJobInput { + s.DataSourceId = &v return s } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *AgentAlias) SetAgentAliasId(v string) *AgentAlias { - s.AgentAliasId = &v +// SetIngestionJobId sets the IngestionJobId field's value. +func (s *GetIngestionJobInput) SetIngestionJobId(v string) *GetIngestionJobInput { + s.IngestionJobId = &v return s } -// SetAgentAliasName sets the AgentAliasName field's value. -func (s *AgentAlias) SetAgentAliasName(v string) *AgentAlias { - s.AgentAliasName = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *GetIngestionJobInput) SetKnowledgeBaseId(v string) *GetIngestionJobInput { + s.KnowledgeBaseId = &v return s } -// SetAgentAliasStatus sets the AgentAliasStatus field's value. -func (s *AgentAlias) SetAgentAliasStatus(v string) *AgentAlias { - s.AgentAliasStatus = &v - return s +type GetIngestionJobOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the ingestion job. + // + // IngestionJob is a required field + IngestionJob *IngestionJob `locationName:"ingestionJob" type:"structure" required:"true"` } -// SetAgentId sets the AgentId field's value. -func (s *AgentAlias) SetAgentId(v string) *AgentAlias { - s.AgentId = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetIngestionJobOutput) String() string { + return awsutil.Prettify(s) } -// SetClientToken sets the ClientToken field's value. -func (s *AgentAlias) SetClientToken(v string) *AgentAlias { - s.ClientToken = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetIngestionJobOutput) GoString() string { + return s.String() } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentAlias) SetCreatedAt(v time.Time) *AgentAlias { - s.CreatedAt = &v +// SetIngestionJob sets the IngestionJob field's value. +func (s *GetIngestionJobOutput) SetIngestionJob(v *IngestionJob) *GetIngestionJobOutput { + s.IngestionJob = v return s } -// SetDescription sets the Description field's value. -func (s *AgentAlias) SetDescription(v string) *AgentAlias { - s.Description = &v - return s +type GetKnowledgeBaseInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of the knowledge base for which to get information. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` } -// SetFailureReasons sets the FailureReasons field's value. -func (s *AgentAlias) SetFailureReasons(v []*string) *AgentAlias { - s.FailureReasons = v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetKnowledgeBaseInput) String() string { + return awsutil.Prettify(s) } -// SetRoutingConfiguration sets the RoutingConfiguration field's value. -func (s *AgentAlias) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAlias { - s.RoutingConfiguration = v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetKnowledgeBaseInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetKnowledgeBaseInput"} + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentAlias) SetUpdatedAt(v time.Time) *AgentAlias { - s.UpdatedAt = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *GetKnowledgeBaseInput) SetKnowledgeBaseId(v string) *GetKnowledgeBaseInput { + s.KnowledgeBaseId = &v return s } -// Contains details about the history of the alias. -type AgentAliasHistoryEvent struct { +type GetKnowledgeBaseOutput struct { _ struct{} `type:"structure"` - // The date that the alias stopped being associated to the version in the routingConfiguration - // object - EndDate *time.Time `locationName:"endDate" type:"timestamp" timestampFormat:"iso8601"` - - // Contains details about the version of the agent with which the alias is associated. - RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` - - // The date that the alias began being associated to the version in the routingConfiguration - // object. - StartDate *time.Time `locationName:"startDate" type:"timestamp" timestampFormat:"iso8601"` + // Contains details about the knowledge base. + // + // KnowledgeBase is a required field + KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` } // String returns the string representation. @@ -5174,7 +15801,7 @@ type AgentAliasHistoryEvent struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasHistoryEvent) String() string { +func (s GetKnowledgeBaseOutput) String() string { return awsutil.Prettify(s) } @@ -5183,37 +15810,26 @@ func (s AgentAliasHistoryEvent) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasHistoryEvent) GoString() string { +func (s GetKnowledgeBaseOutput) GoString() string { return s.String() } -// SetEndDate sets the EndDate field's value. -func (s *AgentAliasHistoryEvent) SetEndDate(v time.Time) *AgentAliasHistoryEvent { - s.EndDate = &v - return s -} - -// SetRoutingConfiguration sets the RoutingConfiguration field's value. -func (s *AgentAliasHistoryEvent) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAliasHistoryEvent { - s.RoutingConfiguration = v - return s -} - -// SetStartDate sets the StartDate field's value. -func (s *AgentAliasHistoryEvent) SetStartDate(v time.Time) *AgentAliasHistoryEvent { - s.StartDate = &v +// SetKnowledgeBase sets the KnowledgeBase field's value. +func (s *GetKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *GetKnowledgeBaseOutput { + s.KnowledgeBase = v return s } -// Contains details about the routing configuration of the alias. -type AgentAliasRoutingConfigurationListItem struct { - _ struct{} `type:"structure"` +type GetPromptInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The version of the agent with which the alias is associated. - AgentVersion *string `locationName:"agentVersion" min:"1" type:"string"` + // The unique identifier of the prompt. + // + // PromptIdentifier is a required field + PromptIdentifier *string `location:"uri" locationName:"promptIdentifier" type:"string" required:"true"` - // Information on the Provisioned Throughput assigned to an agent alias. - ProvisionedThroughput *string `locationName:"provisionedThroughput" min:"1" type:"string"` + // The version of the prompt about which you want to retrieve information. + PromptVersion *string `location:"querystring" locationName:"promptVersion" min:"1" type:"string"` } // String returns the string representation. @@ -5221,7 +15837,7 @@ type AgentAliasRoutingConfigurationListItem struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasRoutingConfigurationListItem) String() string { +func (s GetPromptInput) String() string { return awsutil.Prettify(s) } @@ -5230,18 +15846,21 @@ func (s AgentAliasRoutingConfigurationListItem) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasRoutingConfigurationListItem) GoString() string { +func (s GetPromptInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *AgentAliasRoutingConfigurationListItem) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AgentAliasRoutingConfigurationListItem"} - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) +func (s *GetPromptInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPromptInput"} + if s.PromptIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("PromptIdentifier")) } - if s.ProvisionedThroughput != nil && len(*s.ProvisionedThroughput) < 1 { - invalidParams.Add(request.NewErrParamMinLen("ProvisionedThroughput", 1)) + if s.PromptIdentifier != nil && len(*s.PromptIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PromptIdentifier", 1)) + } + if s.PromptVersion != nil && len(*s.PromptVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PromptVersion", 1)) } if invalidParams.Len() > 0 { @@ -5250,52 +15869,69 @@ func (s *AgentAliasRoutingConfigurationListItem) Validate() error { return nil } -// SetAgentVersion sets the AgentVersion field's value. -func (s *AgentAliasRoutingConfigurationListItem) SetAgentVersion(v string) *AgentAliasRoutingConfigurationListItem { - s.AgentVersion = &v +// SetPromptIdentifier sets the PromptIdentifier field's value. +func (s *GetPromptInput) SetPromptIdentifier(v string) *GetPromptInput { + s.PromptIdentifier = &v return s } -// SetProvisionedThroughput sets the ProvisionedThroughput field's value. -func (s *AgentAliasRoutingConfigurationListItem) SetProvisionedThroughput(v string) *AgentAliasRoutingConfigurationListItem { - s.ProvisionedThroughput = &v +// SetPromptVersion sets the PromptVersion field's value. +func (s *GetPromptInput) SetPromptVersion(v string) *GetPromptInput { + s.PromptVersion = &v return s } -// Contains details about an alias of an agent. -type AgentAliasSummary struct { +type GetPromptOutput struct { _ struct{} `type:"structure"` - // Contains details about - // - // AgentAliasId is a required field - AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` - - // The name of the alias. - // - // AgentAliasName is a required field - AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` - - // The status of the alias. + // The Amazon Resource Name (ARN) of the prompt. // - // AgentAliasStatus is a required field - AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` - // The time at which the alias of the agent was created. + // The time at which the prompt was created. // // CreatedAt is a required field CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The description of the alias. + // The Amazon Resource Name (ARN) of the KMS key that the prompt is encrypted + // with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The name of the default variant for the prompt. This value must match the + // name field in the relevant PromptVariant (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptVariant.html) + // object. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // The descriptino of the prompt. Description *string `locationName:"description" min:"1" type:"string"` - // Contains details about the version of the agent with which the alias is associated. - RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + // The unique identifier of the prompt. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // The time at which the alias was last updated. + // The name of the prompt. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The time at which the prompt was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by GetPromptOutput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` + + // The version of the prompt. + // + // Version is a required field + Version *string `locationName:"version" min:"1" type:"string" required:"true"` } // String returns the string representation. @@ -5303,7 +15939,7 @@ type AgentAliasSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasSummary) String() string { +func (s GetPromptOutput) String() string { return awsutil.Prettify(s) } @@ -5312,95 +15948,133 @@ func (s AgentAliasSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentAliasSummary) GoString() string { +func (s GetPromptOutput) GoString() string { return s.String() } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *AgentAliasSummary) SetAgentAliasId(v string) *AgentAliasSummary { - s.AgentAliasId = &v +// SetArn sets the Arn field's value. +func (s *GetPromptOutput) SetArn(v string) *GetPromptOutput { + s.Arn = &v return s } -// SetAgentAliasName sets the AgentAliasName field's value. -func (s *AgentAliasSummary) SetAgentAliasName(v string) *AgentAliasSummary { - s.AgentAliasName = &v +// SetCreatedAt sets the CreatedAt field's value. +func (s *GetPromptOutput) SetCreatedAt(v time.Time) *GetPromptOutput { + s.CreatedAt = &v return s } -// SetAgentAliasStatus sets the AgentAliasStatus field's value. -func (s *AgentAliasSummary) SetAgentAliasStatus(v string) *AgentAliasSummary { - s.AgentAliasStatus = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *GetPromptOutput) SetCustomerEncryptionKeyArn(v string) *GetPromptOutput { + s.CustomerEncryptionKeyArn = &v return s } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentAliasSummary) SetCreatedAt(v time.Time) *AgentAliasSummary { - s.CreatedAt = &v +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *GetPromptOutput) SetDefaultVariant(v string) *GetPromptOutput { + s.DefaultVariant = &v return s } // SetDescription sets the Description field's value. -func (s *AgentAliasSummary) SetDescription(v string) *AgentAliasSummary { +func (s *GetPromptOutput) SetDescription(v string) *GetPromptOutput { s.Description = &v return s } -// SetRoutingConfiguration sets the RoutingConfiguration field's value. -func (s *AgentAliasSummary) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *AgentAliasSummary { - s.RoutingConfiguration = v +// SetId sets the Id field's value. +func (s *GetPromptOutput) SetId(v string) *GetPromptOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetPromptOutput) SetName(v string) *GetPromptOutput { + s.Name = &v return s } // SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentAliasSummary) SetUpdatedAt(v time.Time) *AgentAliasSummary { +func (s *GetPromptOutput) SetUpdatedAt(v time.Time) *GetPromptOutput { s.UpdatedAt = &v return s } -// Contains details about a knowledge base that is associated with an agent. -type AgentKnowledgeBase struct { +// SetVariants sets the Variants field's value. +func (s *GetPromptOutput) SetVariants(v []*PromptVariant) *GetPromptOutput { + s.Variants = v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetPromptOutput) SetVersion(v string) *GetPromptOutput { + s.Version = &v + return s +} + +// Details about the guardrail associated with an agent. +type GuardrailConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the agent with which the knowledge base is associated. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` + // The unique identifier of the guardrail. + GuardrailIdentifier *string `locationName:"guardrailIdentifier" type:"string"` - // The version of the agent with which the knowledge base is associated. - // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + // The version of the guardrail. + GuardrailVersion *string `locationName:"guardrailVersion" type:"string"` +} - // The time at which the association between the agent and the knowledge base - // was created. - // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailConfiguration) String() string { + return awsutil.Prettify(s) +} - // The description of the association between the agent and the knowledge base. - // - // Description is a required field - Description *string `locationName:"description" min:"1" type:"string" required:"true"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailConfiguration) GoString() string { + return s.String() +} - // The unique identifier of the association between the agent and the knowledge - // base. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` +// SetGuardrailIdentifier sets the GuardrailIdentifier field's value. +func (s *GuardrailConfiguration) SetGuardrailIdentifier(v string) *GuardrailConfiguration { + s.GuardrailIdentifier = &v + return s +} - // Specifies whether to use the knowledge base or not when sending an InvokeAgent - // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. +// SetGuardrailVersion sets the GuardrailVersion field's value. +func (s *GuardrailConfiguration) SetGuardrailVersion(v string) *GuardrailConfiguration { + s.GuardrailVersion = &v + return s +} + +// 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. +type HierarchicalChunkingConfiguration struct { + _ struct{} `type:"structure"` + + // Token settings for each layer. // - // KnowledgeBaseState is a required field - KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" required:"true" enum:"KnowledgeBaseState"` + // LevelConfigurations is a required field + LevelConfigurations []*HierarchicalChunkingLevelConfiguration `locationName:"levelConfigurations" min:"2" type:"list" required:"true"` - // The time at which the association between the agent and the knowledge base - // was last updated. + // The number of tokens to repeat across chunks in the same layer. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // OverlapTokens is a required field + OverlapTokens *int64 `locationName:"overlapTokens" min:"1" type:"integer" required:"true"` } // String returns the string representation. @@ -5408,7 +16082,7 @@ type AgentKnowledgeBase struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentKnowledgeBase) String() string { +func (s HierarchicalChunkingConfiguration) String() string { return awsutil.Prettify(s) } @@ -5417,75 +16091,137 @@ func (s AgentKnowledgeBase) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentKnowledgeBase) GoString() string { +func (s HierarchicalChunkingConfiguration) GoString() string { return s.String() } -// SetAgentId sets the AgentId field's value. -func (s *AgentKnowledgeBase) SetAgentId(v string) *AgentKnowledgeBase { - s.AgentId = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *HierarchicalChunkingConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "HierarchicalChunkingConfiguration"} + if s.LevelConfigurations == nil { + invalidParams.Add(request.NewErrParamRequired("LevelConfigurations")) + } + if s.LevelConfigurations != nil && len(s.LevelConfigurations) < 2 { + invalidParams.Add(request.NewErrParamMinLen("LevelConfigurations", 2)) + } + if s.OverlapTokens == nil { + invalidParams.Add(request.NewErrParamRequired("OverlapTokens")) + } + if s.OverlapTokens != nil && *s.OverlapTokens < 1 { + invalidParams.Add(request.NewErrParamMinValue("OverlapTokens", 1)) + } + if s.LevelConfigurations != nil { + for i, v := range s.LevelConfigurations { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "LevelConfigurations", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetAgentVersion sets the AgentVersion field's value. -func (s *AgentKnowledgeBase) SetAgentVersion(v string) *AgentKnowledgeBase { - s.AgentVersion = &v +// SetLevelConfigurations sets the LevelConfigurations field's value. +func (s *HierarchicalChunkingConfiguration) SetLevelConfigurations(v []*HierarchicalChunkingLevelConfiguration) *HierarchicalChunkingConfiguration { + s.LevelConfigurations = v return s } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentKnowledgeBase) SetCreatedAt(v time.Time) *AgentKnowledgeBase { - s.CreatedAt = &v +// SetOverlapTokens sets the OverlapTokens field's value. +func (s *HierarchicalChunkingConfiguration) SetOverlapTokens(v int64) *HierarchicalChunkingConfiguration { + s.OverlapTokens = &v return s } -// SetDescription sets the Description field's value. -func (s *AgentKnowledgeBase) SetDescription(v string) *AgentKnowledgeBase { - s.Description = &v - return s +// Token settings for a layer in a hierarchical chunking configuration. +type HierarchicalChunkingLevelConfiguration struct { + _ struct{} `type:"structure"` + + // The maximum number of tokens that a chunk can contain in this layer. + // + // MaxTokens is a required field + MaxTokens *int64 `locationName:"maxTokens" min:"1" type:"integer" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s HierarchicalChunkingLevelConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s HierarchicalChunkingLevelConfiguration) GoString() string { + return s.String() } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *AgentKnowledgeBase) SetKnowledgeBaseId(v string) *AgentKnowledgeBase { - s.KnowledgeBaseId = &v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *HierarchicalChunkingLevelConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "HierarchicalChunkingLevelConfiguration"} + if s.MaxTokens == nil { + invalidParams.Add(request.NewErrParamRequired("MaxTokens")) + } + if s.MaxTokens != nil && *s.MaxTokens < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxTokens", 1)) + } -// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. -func (s *AgentKnowledgeBase) SetKnowledgeBaseState(v string) *AgentKnowledgeBase { - s.KnowledgeBaseState = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentKnowledgeBase) SetUpdatedAt(v time.Time) *AgentKnowledgeBase { - s.UpdatedAt = &v +// SetMaxTokens sets the MaxTokens field's value. +func (s *HierarchicalChunkingLevelConfiguration) SetMaxTokens(v int64) *HierarchicalChunkingLevelConfiguration { + s.MaxTokens = &v return s } -// Contains details about a knowledge base associated with an agent. -type AgentKnowledgeBaseSummary struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html). +type InferenceConfiguration struct { _ struct{} `type:"structure"` - // The description of the knowledge base associated with an agent. - Description *string `locationName:"description" min:"1" type:"string"` + // The maximum number of tokens to allow in the generated response. + MaximumLength *int64 `locationName:"maximumLength" type:"integer"` - // The unique identifier of the knowledge base associated with an agent. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // A list of stop sequences. A stop sequence is a sequence of characters that + // causes the model to stop generating the response. + StopSequences []*string `locationName:"stopSequences" type:"list"` - // Specifies whether the agent uses the knowledge base or not when sending an - // InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. - // - // KnowledgeBaseState is a required field - KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" required:"true" enum:"KnowledgeBaseState"` + // 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. + Temperature *float64 `locationName:"temperature" type:"float"` - // The time at which the knowledge base associated with an agent was last updated. - // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // 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. + TopK *int64 `locationName:"topK" type:"integer"` + + // 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. + TopP *float64 `locationName:"topP" type:"float"` } // String returns the string representation. @@ -5493,7 +16229,7 @@ type AgentKnowledgeBaseSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentKnowledgeBaseSummary) String() string { +func (s InferenceConfiguration) String() string { return awsutil.Prettify(s) } @@ -5502,63 +16238,89 @@ func (s AgentKnowledgeBaseSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentKnowledgeBaseSummary) GoString() string { +func (s InferenceConfiguration) GoString() string { return s.String() } -// SetDescription sets the Description field's value. -func (s *AgentKnowledgeBaseSummary) SetDescription(v string) *AgentKnowledgeBaseSummary { - s.Description = &v +// SetMaximumLength sets the MaximumLength field's value. +func (s *InferenceConfiguration) SetMaximumLength(v int64) *InferenceConfiguration { + s.MaximumLength = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *AgentKnowledgeBaseSummary) SetKnowledgeBaseId(v string) *AgentKnowledgeBaseSummary { - s.KnowledgeBaseId = &v +// SetStopSequences sets the StopSequences field's value. +func (s *InferenceConfiguration) SetStopSequences(v []*string) *InferenceConfiguration { + s.StopSequences = v return s } -// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. -func (s *AgentKnowledgeBaseSummary) SetKnowledgeBaseState(v string) *AgentKnowledgeBaseSummary { - s.KnowledgeBaseState = &v +// SetTemperature sets the Temperature field's value. +func (s *InferenceConfiguration) SetTemperature(v float64) *InferenceConfiguration { + s.Temperature = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentKnowledgeBaseSummary) SetUpdatedAt(v time.Time) *AgentKnowledgeBaseSummary { - s.UpdatedAt = &v +// SetTopK sets the TopK field's value. +func (s *InferenceConfiguration) SetTopK(v int64) *InferenceConfiguration { + s.TopK = &v return s } -// Contains details about an agent. -type AgentSummary struct { +// SetTopP sets the TopP field's value. +func (s *InferenceConfiguration) SetTopP(v float64) *InferenceConfiguration { + s.TopP = &v + return s +} + +// 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: +// +// - StartIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_StartIngestionJob.html#API_agent_StartIngestionJob_ResponseSyntax) +// +// - GetIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetIngestionJob.html#API_agent_GetIngestionJob_ResponseSyntax) +// +// - ListIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_ListIngestionJobs.html#API_agent_ListIngestionJobs_ResponseSyntax) +type IngestionJob struct { _ struct{} `type:"structure"` - // The unique identifier of the agent. + // The unique identifier of the ingested data source. // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` + // DataSourceId is a required field + DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - // The name of the agent. + // The description of the ingestion job. + Description *string `locationName:"description" min:"1" type:"string"` + + // A list of reasons that the ingestion job failed. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // The unique identifier of the ingestion job. // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` + // IngestionJobId is a required field + IngestionJobId *string `locationName:"ingestionJobId" type:"string" required:"true"` - // The status of the agent. + // The unique identifier of the knowledge base to which the data source is being + // added. // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` - // The description of the agent. - Description *string `locationName:"description" min:"1" type:"string"` + // The time at which the ingestion job started. + // + // StartedAt is a required field + StartedAt *time.Time `locationName:"startedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The details of the guardrails configuration in the agent summary. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + // Contains statistics about the ingestion job. + Statistics *IngestionJobStatistics `locationName:"statistics" type:"structure"` - // The latest version of the agent. - LatestAgentVersion *string `locationName:"latestAgentVersion" min:"1" type:"string"` + // The status of the ingestion job. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"IngestionJobStatus"` - // The time at which the agent was last updated. + // The time at which the ingestion job was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` @@ -5569,7 +16331,7 @@ type AgentSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentSummary) String() string { +func (s IngestionJob) String() string { return awsutil.Prettify(s) } @@ -5578,140 +16340,82 @@ func (s AgentSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentSummary) GoString() string { +func (s IngestionJob) GoString() string { return s.String() } -// SetAgentId sets the AgentId field's value. -func (s *AgentSummary) SetAgentId(v string) *AgentSummary { - s.AgentId = &v - return s -} - -// SetAgentName sets the AgentName field's value. -func (s *AgentSummary) SetAgentName(v string) *AgentSummary { - s.AgentName = &v - return s -} - -// SetAgentStatus sets the AgentStatus field's value. -func (s *AgentSummary) SetAgentStatus(v string) *AgentSummary { - s.AgentStatus = &v +// SetDataSourceId sets the DataSourceId field's value. +func (s *IngestionJob) SetDataSourceId(v string) *IngestionJob { + s.DataSourceId = &v return s } // SetDescription sets the Description field's value. -func (s *AgentSummary) SetDescription(v string) *AgentSummary { +func (s *IngestionJob) SetDescription(v string) *IngestionJob { s.Description = &v return s } -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *AgentSummary) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentSummary { - s.GuardrailConfiguration = v +// SetFailureReasons sets the FailureReasons field's value. +func (s *IngestionJob) SetFailureReasons(v []*string) *IngestionJob { + s.FailureReasons = v return s } -// SetLatestAgentVersion sets the LatestAgentVersion field's value. -func (s *AgentSummary) SetLatestAgentVersion(v string) *AgentSummary { - s.LatestAgentVersion = &v +// SetIngestionJobId sets the IngestionJobId field's value. +func (s *IngestionJob) SetIngestionJobId(v string) *IngestionJob { + s.IngestionJobId = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentSummary) SetUpdatedAt(v time.Time) *AgentSummary { - s.UpdatedAt = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *IngestionJob) SetKnowledgeBaseId(v string) *IngestionJob { + s.KnowledgeBaseId = &v return s -} - -// Contains details about a version of an agent. -type AgentVersion struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the agent that the version belongs to. - // - // AgentArn is a required field - AgentArn *string `locationName:"agentArn" type:"string" required:"true"` - - // The unique identifier of the agent that the version belongs to. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` - - // The name of the agent that the version belongs to. - // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the agent. - // - // AgentResourceRoleArn is a required field - AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` - - // The status of the agent that the version belongs to. - // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` - - // The time at which the version was created. - // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - - // The Amazon Resource Name (ARN) of the KMS key that encrypts the agent. - CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - - // The description of the version. - Description *string `locationName:"description" min:"1" type:"string"` +} - // A list of reasons that the API operation on the version failed. - FailureReasons []*string `locationName:"failureReasons" type:"list"` +// SetStartedAt sets the StartedAt field's value. +func (s *IngestionJob) SetStartedAt(v time.Time) *IngestionJob { + s.StartedAt = &v + return s +} - // The foundation model that the version invokes. - FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` +// SetStatistics sets the Statistics field's value. +func (s *IngestionJob) SetStatistics(v *IngestionJobStatistics) *IngestionJob { + s.Statistics = v + return s +} - // The guardrails configuration assigned to the agent version. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` +// SetStatus sets the Status field's value. +func (s *IngestionJob) SetStatus(v string) *IngestionJob { + s.Status = &v + return s +} - // 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. - // - // IdleSessionTTLInSeconds is a required field - IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer" required:"true"` +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *IngestionJob) SetUpdatedAt(v time.Time) *IngestionJob { + s.UpdatedAt = &v + return s +} - // The instructions provided to the agent. - // - // Instruction is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by AgentVersion's - // String and GoString methods. - Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` +// Defines a filter by which to filter the results. +type IngestionJobFilter struct { + _ struct{} `type:"structure"` - // Contains configurations to override prompt templates in different parts of - // an agent sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // The attribute by which to filter the results. // - // PromptOverrideConfiguration is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by AgentVersion's - // String and GoString methods. - PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` - - // A list of recommended actions to take for the failed API operation on the - // version to succeed. - RecommendedActions []*string `locationName:"recommendedActions" type:"list"` + // Attribute is a required field + Attribute *string `locationName:"attribute" type:"string" required:"true" enum:"IngestionJobFilterAttribute"` - // The time at which the version was last updated. + // The operation to carry out between the attribute and the values. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // Operator is a required field + Operator *string `locationName:"operator" type:"string" required:"true" enum:"IngestionJobFilterOperator"` - // The version number. + // A list of values for the attribute. // - // Version is a required field - Version *string `locationName:"version" type:"string" required:"true"` + // Values is a required field + Values []*string `locationName:"values" type:"list" required:"true"` } // String returns the string representation. @@ -5719,7 +16423,7 @@ type AgentVersion struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentVersion) String() string { +func (s IngestionJobFilter) String() string { return awsutil.Prettify(s) } @@ -5728,143 +16432,234 @@ func (s AgentVersion) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentVersion) GoString() string { +func (s IngestionJobFilter) GoString() string { return s.String() } -// SetAgentArn sets the AgentArn field's value. -func (s *AgentVersion) SetAgentArn(v string) *AgentVersion { - s.AgentArn = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *IngestionJobFilter) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "IngestionJobFilter"} + if s.Attribute == nil { + invalidParams.Add(request.NewErrParamRequired("Attribute")) + } + if s.Operator == nil { + invalidParams.Add(request.NewErrParamRequired("Operator")) + } + if s.Values == nil { + invalidParams.Add(request.NewErrParamRequired("Values")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetAgentId sets the AgentId field's value. -func (s *AgentVersion) SetAgentId(v string) *AgentVersion { - s.AgentId = &v +// SetAttribute sets the Attribute field's value. +func (s *IngestionJobFilter) SetAttribute(v string) *IngestionJobFilter { + s.Attribute = &v return s } -// SetAgentName sets the AgentName field's value. -func (s *AgentVersion) SetAgentName(v string) *AgentVersion { - s.AgentName = &v +// SetOperator sets the Operator field's value. +func (s *IngestionJobFilter) SetOperator(v string) *IngestionJobFilter { + s.Operator = &v return s } -// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. -func (s *AgentVersion) SetAgentResourceRoleArn(v string) *AgentVersion { - s.AgentResourceRoleArn = &v +// SetValues sets the Values field's value. +func (s *IngestionJobFilter) SetValues(v []*string) *IngestionJobFilter { + s.Values = v return s } -// SetAgentStatus sets the AgentStatus field's value. -func (s *AgentVersion) SetAgentStatus(v string) *AgentVersion { - s.AgentStatus = &v - return s +// Parameters by which to sort the results. +type IngestionJobSortBy struct { + _ struct{} `type:"structure"` + + // The attribute by which to sort the results. + // + // Attribute is a required field + Attribute *string `locationName:"attribute" type:"string" required:"true" enum:"IngestionJobSortByAttribute"` + + // The order by which to sort the results. + // + // Order is a required field + Order *string `locationName:"order" type:"string" required:"true" enum:"SortOrder"` } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentVersion) SetCreatedAt(v time.Time) *AgentVersion { - s.CreatedAt = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s IngestionJobSortBy) String() string { + return awsutil.Prettify(s) } -// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. -func (s *AgentVersion) SetCustomerEncryptionKeyArn(v string) *AgentVersion { - s.CustomerEncryptionKeyArn = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s IngestionJobSortBy) GoString() string { + return s.String() } -// SetDescription sets the Description field's value. -func (s *AgentVersion) SetDescription(v string) *AgentVersion { - s.Description = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *IngestionJobSortBy) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "IngestionJobSortBy"} + if s.Attribute == nil { + invalidParams.Add(request.NewErrParamRequired("Attribute")) + } + if s.Order == nil { + invalidParams.Add(request.NewErrParamRequired("Order")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetFailureReasons sets the FailureReasons field's value. -func (s *AgentVersion) SetFailureReasons(v []*string) *AgentVersion { - s.FailureReasons = v +// SetAttribute sets the Attribute field's value. +func (s *IngestionJobSortBy) SetAttribute(v string) *IngestionJobSortBy { + s.Attribute = &v return s } -// SetFoundationModel sets the FoundationModel field's value. -func (s *AgentVersion) SetFoundationModel(v string) *AgentVersion { - s.FoundationModel = &v +// SetOrder sets the Order field's value. +func (s *IngestionJobSortBy) SetOrder(v string) *IngestionJobSortBy { + s.Order = &v return s } -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *AgentVersion) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentVersion { - s.GuardrailConfiguration = v - return s +// Contains the statistics for the ingestion job. +type IngestionJobStatistics struct { + _ struct{} `type:"structure"` + + // The number of source documents that was deleted. + NumberOfDocumentsDeleted *int64 `locationName:"numberOfDocumentsDeleted" type:"long"` + + // The number of source documents that failed to be ingested. + NumberOfDocumentsFailed *int64 `locationName:"numberOfDocumentsFailed" type:"long"` + + // The total number of source documents that were scanned. Includes new, updated, + // and unchanged documents. + NumberOfDocumentsScanned *int64 `locationName:"numberOfDocumentsScanned" type:"long"` + + // The number of metadata files that were updated or deleted. + NumberOfMetadataDocumentsModified *int64 `locationName:"numberOfMetadataDocumentsModified" type:"long"` + + // The total number of metadata files that were scanned. Includes new, updated, + // and unchanged files. + NumberOfMetadataDocumentsScanned *int64 `locationName:"numberOfMetadataDocumentsScanned" type:"long"` + + // The number of modified source documents in the data source that were successfully + // indexed. + NumberOfModifiedDocumentsIndexed *int64 `locationName:"numberOfModifiedDocumentsIndexed" type:"long"` + + // The number of new source documents in the data source that were successfully + // indexed. + NumberOfNewDocumentsIndexed *int64 `locationName:"numberOfNewDocumentsIndexed" type:"long"` } -// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. -func (s *AgentVersion) SetIdleSessionTTLInSeconds(v int64) *AgentVersion { - s.IdleSessionTTLInSeconds = &v +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s IngestionJobStatistics) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s IngestionJobStatistics) GoString() string { + return s.String() +} + +// SetNumberOfDocumentsDeleted sets the NumberOfDocumentsDeleted field's value. +func (s *IngestionJobStatistics) SetNumberOfDocumentsDeleted(v int64) *IngestionJobStatistics { + s.NumberOfDocumentsDeleted = &v return s } -// SetInstruction sets the Instruction field's value. -func (s *AgentVersion) SetInstruction(v string) *AgentVersion { - s.Instruction = &v +// SetNumberOfDocumentsFailed sets the NumberOfDocumentsFailed field's value. +func (s *IngestionJobStatistics) SetNumberOfDocumentsFailed(v int64) *IngestionJobStatistics { + s.NumberOfDocumentsFailed = &v return s } -// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. -func (s *AgentVersion) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *AgentVersion { - s.PromptOverrideConfiguration = v +// SetNumberOfDocumentsScanned sets the NumberOfDocumentsScanned field's value. +func (s *IngestionJobStatistics) SetNumberOfDocumentsScanned(v int64) *IngestionJobStatistics { + s.NumberOfDocumentsScanned = &v return s } -// SetRecommendedActions sets the RecommendedActions field's value. -func (s *AgentVersion) SetRecommendedActions(v []*string) *AgentVersion { - s.RecommendedActions = v +// SetNumberOfMetadataDocumentsModified sets the NumberOfMetadataDocumentsModified field's value. +func (s *IngestionJobStatistics) SetNumberOfMetadataDocumentsModified(v int64) *IngestionJobStatistics { + s.NumberOfMetadataDocumentsModified = &v + return s +} + +// SetNumberOfMetadataDocumentsScanned sets the NumberOfMetadataDocumentsScanned field's value. +func (s *IngestionJobStatistics) SetNumberOfMetadataDocumentsScanned(v int64) *IngestionJobStatistics { + s.NumberOfMetadataDocumentsScanned = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentVersion) SetUpdatedAt(v time.Time) *AgentVersion { - s.UpdatedAt = &v +// SetNumberOfModifiedDocumentsIndexed sets the NumberOfModifiedDocumentsIndexed field's value. +func (s *IngestionJobStatistics) SetNumberOfModifiedDocumentsIndexed(v int64) *IngestionJobStatistics { + s.NumberOfModifiedDocumentsIndexed = &v return s } -// SetVersion sets the Version field's value. -func (s *AgentVersion) SetVersion(v string) *AgentVersion { - s.Version = &v +// SetNumberOfNewDocumentsIndexed sets the NumberOfNewDocumentsIndexed field's value. +func (s *IngestionJobStatistics) SetNumberOfNewDocumentsIndexed(v int64) *IngestionJobStatistics { + s.NumberOfNewDocumentsIndexed = &v return s } -// Contains details about a version of an agent. -type AgentVersionSummary struct { +// Contains details about an ingestion job. +type IngestionJobSummary struct { _ struct{} `type:"structure"` - // The name of the agent to which the version belongs. + // The unique identifier of the data source in the ingestion job. // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` + // DataSourceId is a required field + DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - // The status of the agent to which the version belongs. + // The description of the ingestion job. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the ingestion job. // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + // IngestionJobId is a required field + IngestionJobId *string `locationName:"ingestionJobId" type:"string" required:"true"` - // The version of the agent. + // The unique identifier of the knowledge base to which the data source is added. // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` - // The time at which the version was created. + // The time at which the ingestion job was started. // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // StartedAt is a required field + StartedAt *time.Time `locationName:"startedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The description of the version of the agent. - Description *string `locationName:"description" min:"1" type:"string"` + // Contains statistics for the ingestion job. + Statistics *IngestionJobStatistics `locationName:"statistics" type:"structure"` - // The details of the guardrails configuration in the agent version summary. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + // The status of the ingestion job. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"IngestionJobStatus"` - // The time at which the version was last updated. + // The time at which the ingestion job was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` @@ -5875,7 +16670,7 @@ type AgentVersionSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentVersionSummary) String() string { +func (s IngestionJobSummary) String() string { return awsutil.Prettify(s) } @@ -5884,80 +16679,92 @@ func (s AgentVersionSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AgentVersionSummary) GoString() string { +func (s IngestionJobSummary) GoString() string { return s.String() } -// SetAgentName sets the AgentName field's value. -func (s *AgentVersionSummary) SetAgentName(v string) *AgentVersionSummary { - s.AgentName = &v +// SetDataSourceId sets the DataSourceId field's value. +func (s *IngestionJobSummary) SetDataSourceId(v string) *IngestionJobSummary { + s.DataSourceId = &v return s } -// SetAgentStatus sets the AgentStatus field's value. -func (s *AgentVersionSummary) SetAgentStatus(v string) *AgentVersionSummary { - s.AgentStatus = &v +// SetDescription sets the Description field's value. +func (s *IngestionJobSummary) SetDescription(v string) *IngestionJobSummary { + s.Description = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *AgentVersionSummary) SetAgentVersion(v string) *AgentVersionSummary { - s.AgentVersion = &v +// SetIngestionJobId sets the IngestionJobId field's value. +func (s *IngestionJobSummary) SetIngestionJobId(v string) *IngestionJobSummary { + s.IngestionJobId = &v return s } -// SetCreatedAt sets the CreatedAt field's value. -func (s *AgentVersionSummary) SetCreatedAt(v time.Time) *AgentVersionSummary { - s.CreatedAt = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *IngestionJobSummary) SetKnowledgeBaseId(v string) *IngestionJobSummary { + s.KnowledgeBaseId = &v return s } -// SetDescription sets the Description field's value. -func (s *AgentVersionSummary) SetDescription(v string) *AgentVersionSummary { - s.Description = &v +// SetStartedAt sets the StartedAt field's value. +func (s *IngestionJobSummary) SetStartedAt(v time.Time) *IngestionJobSummary { + s.StartedAt = &v return s } -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *AgentVersionSummary) SetGuardrailConfiguration(v *GuardrailConfiguration) *AgentVersionSummary { - s.GuardrailConfiguration = v +// SetStatistics sets the Statistics field's value. +func (s *IngestionJobSummary) SetStatistics(v *IngestionJobStatistics) *IngestionJobSummary { + s.Statistics = v + return s +} + +// SetStatus sets the Status field's value. +func (s *IngestionJobSummary) SetStatus(v string) *IngestionJobSummary { + s.Status = &v return s } // SetUpdatedAt sets the UpdatedAt field's value. -func (s *AgentVersionSummary) SetUpdatedAt(v time.Time) *AgentVersionSummary { +func (s *IngestionJobSummary) SetUpdatedAt(v time.Time) *IngestionJobSummary { s.UpdatedAt = &v return s } -type AssociateAgentKnowledgeBaseInput struct { +// 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. +type InputFlowNodeConfiguration struct { _ struct{} `type:"structure"` +} - // The unique identifier of the agent with which you want to associate the knowledge - // base. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InputFlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} - // The version of the agent with which you want to associate the knowledge base. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InputFlowNodeConfiguration) GoString() string { + return s.String() +} - // A description of what the agent should use the knowledge base for. - // - // Description is a required field - Description *string `locationName:"description" min:"1" type:"string" required:"true"` +// A location for storing content from data sources temporarily as it is processed +// by custom components in the ingestion pipeline. +type IntermediateStorage struct { + _ struct{} `type:"structure"` - // The unique identifier of the knowledge base to associate with the agent. + // An S3 bucket path. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` - - // Specifies whether to use the knowledge base or not when sending an InvokeAgent - // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. - KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" enum:"KnowledgeBaseState"` + // S3Location is a required field + S3Location *S3Location `locationName:"s3Location" type:"structure" required:"true"` } // String returns the string representation. @@ -5965,7 +16772,7 @@ type AssociateAgentKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateAgentKnowledgeBaseInput) String() string { +func (s IntermediateStorage) String() string { return awsutil.Prettify(s) } @@ -5974,33 +16781,20 @@ func (s AssociateAgentKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateAgentKnowledgeBaseInput) GoString() string { +func (s IntermediateStorage) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *AssociateAgentKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AssociateAgentKnowledgeBaseInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) - } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) - } - if s.Description == nil { - invalidParams.Add(request.NewErrParamRequired("Description")) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +func (s *IntermediateStorage) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "IntermediateStorage"} + if s.S3Location == nil { + invalidParams.Add(request.NewErrParamRequired("S3Location")) + } + if s.S3Location != nil { + if err := s.S3Location.Validate(); err != nil { + invalidParams.AddNested("S3Location", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -6009,44 +16803,18 @@ func (s *AssociateAgentKnowledgeBaseInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *AssociateAgentKnowledgeBaseInput) SetAgentId(v string) *AssociateAgentKnowledgeBaseInput { - s.AgentId = &v - return s -} - -// SetAgentVersion sets the AgentVersion field's value. -func (s *AssociateAgentKnowledgeBaseInput) SetAgentVersion(v string) *AssociateAgentKnowledgeBaseInput { - s.AgentVersion = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *AssociateAgentKnowledgeBaseInput) SetDescription(v string) *AssociateAgentKnowledgeBaseInput { - s.Description = &v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *AssociateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *AssociateAgentKnowledgeBaseInput { - s.KnowledgeBaseId = &v - return s -} - -// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. -func (s *AssociateAgentKnowledgeBaseInput) SetKnowledgeBaseState(v string) *AssociateAgentKnowledgeBaseInput { - s.KnowledgeBaseState = &v +// SetS3Location sets the S3Location field's value. +func (s *IntermediateStorage) SetS3Location(v *S3Location) *IntermediateStorage { + s.S3Location = v return s } -type AssociateAgentKnowledgeBaseOutput struct { - _ struct{} `type:"structure"` +// An internal server error occurred. Retry your request. +type InternalServerException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // Contains details about the knowledge base that has been associated with the - // agent. - // - // AgentKnowledgeBase is a required field - AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -6054,7 +16822,7 @@ type AssociateAgentKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateAgentKnowledgeBaseOutput) String() string { +func (s InternalServerException) String() string { return awsutil.Prettify(s) } @@ -6063,23 +16831,57 @@ func (s AssociateAgentKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateAgentKnowledgeBaseOutput) GoString() string { +func (s InternalServerException) GoString() string { return s.String() } -// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. -func (s *AssociateAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *AssociateAgentKnowledgeBaseOutput { - s.AgentKnowledgeBase = v - return s +func newErrorInternalServerException(v protocol.ResponseMetadata) error { + return &InternalServerException{ + RespMetadata: v, + } } -// The vector configuration details for the Bedrock embeddings model. -type BedrockEmbeddingModelConfiguration struct { +// Code returns the exception type name. +func (s *InternalServerException) Code() string { + return "InternalServerException" +} + +// Message returns the exception's message. +func (s *InternalServerException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InternalServerException) OrigErr() error { + return nil +} + +func (s *InternalServerException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *InternalServerException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *InternalServerException) RequestID() string { + return s.RespMetadata.RequestID +} + +// 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. +type IteratorFlowNodeConfiguration struct { _ struct{} `type:"structure"` - - // The dimensions details for the vector configuration used on the Bedrock embeddings - // model. - Dimensions *int64 `locationName:"dimensions" type:"integer"` } // String returns the string representation. @@ -6087,7 +16889,7 @@ type BedrockEmbeddingModelConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s BedrockEmbeddingModelConfiguration) String() string { +func (s IteratorFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -6096,41 +16898,75 @@ func (s BedrockEmbeddingModelConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s BedrockEmbeddingModelConfiguration) GoString() string { +func (s IteratorFlowNodeConfiguration) GoString() string { return s.String() } -// SetDimensions sets the Dimensions field's value. -func (s *BedrockEmbeddingModelConfiguration) SetDimensions(v int64) *BedrockEmbeddingModelConfiguration { - s.Dimensions = &v - return s -} - -// 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. -type ChunkingConfiguration struct { +// Contains information about a knowledge base. +type KnowledgeBase struct { _ struct{} `type:"structure"` - // 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. + // The time at which the knowledge base was created. // - // * FIXED_SIZE – Amazon Bedrock splits your source data into chunks of - // the approximate size that you set in the fixedSizeChunkingConfiguration. + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the knowledge base. + Description *string `locationName:"description" min:"1" type:"string"` + + // A list of reasons that the API operation on the knowledge base failed. + FailureReasons []*string `locationName:"failureReasons" type:"list"` + + // The Amazon Resource Name (ARN) of the knowledge base. // - // * 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. + // KnowledgeBaseArn is a required field + KnowledgeBaseArn *string `locationName:"knowledgeBaseArn" type:"string" required:"true"` + + // Contains details about the embeddings configuration of the knowledge base. // - // ChunkingStrategy is a required field - ChunkingStrategy *string `locationName:"chunkingStrategy" type:"string" required:"true" enum:"ChunkingStrategy"` + // KnowledgeBaseConfiguration is a required field + KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` - // Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy - // as NONE, exclude this field. - FixedSizeChunkingConfiguration *FixedSizeChunkingConfiguration `locationName:"fixedSizeChunkingConfiguration" type:"structure"` + // The unique identifier of the knowledge base. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The name of the knowledge base. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the knowledge base. + // + // RoleArn is a required field + RoleArn *string `locationName:"roleArn" type:"string" required:"true"` + + // 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. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` + + // Contains details about the storage configuration of the knowledge base. + // + // StorageConfiguration is a required field + StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` + + // The time at which the knowledge base was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` } // String returns the string representation. @@ -6138,7 +16974,7 @@ type ChunkingConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ChunkingConfiguration) String() string { +func (s KnowledgeBase) String() string { return awsutil.Prettify(s) } @@ -6147,161 +16983,156 @@ func (s ChunkingConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ChunkingConfiguration) GoString() string { +func (s KnowledgeBase) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ChunkingConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ChunkingConfiguration"} - if s.ChunkingStrategy == nil { - invalidParams.Add(request.NewErrParamRequired("ChunkingStrategy")) - } - if s.FixedSizeChunkingConfiguration != nil { - if err := s.FixedSizeChunkingConfiguration.Validate(); err != nil { - invalidParams.AddNested("FixedSizeChunkingConfiguration", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetChunkingStrategy sets the ChunkingStrategy field's value. -func (s *ChunkingConfiguration) SetChunkingStrategy(v string) *ChunkingConfiguration { - s.ChunkingStrategy = &v +// SetCreatedAt sets the CreatedAt field's value. +func (s *KnowledgeBase) SetCreatedAt(v time.Time) *KnowledgeBase { + s.CreatedAt = &v return s } -// SetFixedSizeChunkingConfiguration sets the FixedSizeChunkingConfiguration field's value. -func (s *ChunkingConfiguration) SetFixedSizeChunkingConfiguration(v *FixedSizeChunkingConfiguration) *ChunkingConfiguration { - s.FixedSizeChunkingConfiguration = v +// SetDescription sets the Description field's value. +func (s *KnowledgeBase) SetDescription(v string) *KnowledgeBase { + s.Description = &v return s } -// There was a conflict performing an operation. -type ConflictException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - - Message_ *string `locationName:"message" type:"string"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ConflictException) String() string { - return awsutil.Prettify(s) +// SetFailureReasons sets the FailureReasons field's value. +func (s *KnowledgeBase) SetFailureReasons(v []*string) *KnowledgeBase { + s.FailureReasons = v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ConflictException) GoString() string { - return s.String() +// SetKnowledgeBaseArn sets the KnowledgeBaseArn field's value. +func (s *KnowledgeBase) SetKnowledgeBaseArn(v string) *KnowledgeBase { + s.KnowledgeBaseArn = &v + return s } -func newErrorConflictException(v protocol.ResponseMetadata) error { - return &ConflictException{ - RespMetadata: v, - } +// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. +func (s *KnowledgeBase) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *KnowledgeBase { + s.KnowledgeBaseConfiguration = v + return s } -// Code returns the exception type name. -func (s *ConflictException) Code() string { - return "ConflictException" +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *KnowledgeBase) SetKnowledgeBaseId(v string) *KnowledgeBase { + s.KnowledgeBaseId = &v + return s } -// Message returns the exception's message. -func (s *ConflictException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" +// SetName sets the Name field's value. +func (s *KnowledgeBase) SetName(v string) *KnowledgeBase { + s.Name = &v + return s } -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ConflictException) OrigErr() error { - return nil +// SetRoleArn sets the RoleArn field's value. +func (s *KnowledgeBase) SetRoleArn(v string) *KnowledgeBase { + s.RoleArn = &v + return s } -func (s *ConflictException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +// SetStatus sets the Status field's value. +func (s *KnowledgeBase) SetStatus(v string) *KnowledgeBase { + s.Status = &v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *ConflictException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetStorageConfiguration sets the StorageConfiguration field's value. +func (s *KnowledgeBase) SetStorageConfiguration(v *StorageConfiguration) *KnowledgeBase { + s.StorageConfiguration = v + return s } -// RequestID returns the service's response RequestID for request. -func (s *ConflictException) RequestID() string { - return s.RespMetadata.RequestID +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *KnowledgeBase) SetUpdatedAt(v time.Time) *KnowledgeBase { + s.UpdatedAt = &v + return s } -type CreateAgentActionGroupInput struct { +// Contains details about the embeddings configuration of the knowledge base. +type KnowledgeBaseConfiguration struct { _ struct{} `type:"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. - ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` - - // The name to give the action group. + // The type of data that the data source is converted into for the knowledge + // base. // - // ActionGroupName is a required field - ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"KnowledgeBaseType"` - // Specifies whether the action group is available for the agent to invoke or - // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. - ActionGroupState *string `locationName:"actionGroupState" type:"string" enum:"ActionGroupState"` + // Contains details about the embeddings model that'sused to convert the data + // source. + VectorKnowledgeBaseConfiguration *VectorKnowledgeBaseConfiguration `locationName:"vectorKnowledgeBaseConfiguration" type:"structure"` +} - // The unique identifier of the agent for which to create the action group. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s KnowledgeBaseConfiguration) String() string { + return awsutil.Prettify(s) +} - // The version of the agent for which to create the action group. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s KnowledgeBaseConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *KnowledgeBaseConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "KnowledgeBaseConfiguration"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.VectorKnowledgeBaseConfiguration != nil { + if err := s.VectorKnowledgeBaseConfiguration.Validate(); err != nil { + invalidParams.AddNested("VectorKnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) + } + } - // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). - ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` +// SetType sets the Type field's value. +func (s *KnowledgeBaseConfiguration) SetType(v string) *KnowledgeBaseConfiguration { + s.Type = &v + return s +} - // A description of the action group. - Description *string `locationName:"description" min:"1" type:"string"` +// SetVectorKnowledgeBaseConfiguration sets the VectorKnowledgeBaseConfiguration field's value. +func (s *KnowledgeBaseConfiguration) SetVectorKnowledgeBaseConfiguration(v *VectorKnowledgeBaseConfiguration) *KnowledgeBaseConfiguration { + s.VectorKnowledgeBaseConfiguration = v + return s +} - // Contains details about the function schema for the action group or the JSON - // or YAML-formatted payload defining the schema. - FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type KnowledgeBaseFlowNodeConfiguration struct { + _ struct{} `type:"structure"` - // 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. + // The unique identifier of the knowledge base to query. // - // 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 - // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) - // reprompting the user for more information. - ParentActionGroupSignature *string `locationName:"parentActionGroupSignature" type:"string" enum:"ActionGroupSignature"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // 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. + ModelId *string `locationName:"modelId" min:"1" type:"string"` } // String returns the string representation. @@ -6309,7 +17140,7 @@ type CreateAgentActionGroupInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentActionGroupInput) String() string { +func (s KnowledgeBaseFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -6318,43 +17149,18 @@ func (s CreateAgentActionGroupInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentActionGroupInput) GoString() string { +func (s KnowledgeBaseFlowNodeConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateAgentActionGroupInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateAgentActionGroupInput"} - if s.ActionGroupName == nil { - invalidParams.Add(request.NewErrParamRequired("ActionGroupName")) - } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) - } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) - } - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.ApiSchema != nil { - if err := s.ApiSchema.Validate(); err != nil { - invalidParams.AddNested("ApiSchema", err.(request.ErrInvalidParams)) - } +func (s *KnowledgeBaseFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "KnowledgeBaseFlowNodeConfiguration"} + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) } - if s.FunctionSchema != nil { - if err := s.FunctionSchema.Validate(); err != nil { - invalidParams.AddNested("FunctionSchema", err.(request.ErrInvalidParams)) - } + if s.ModelId != nil && len(*s.ModelId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) } if invalidParams.Len() > 0 { @@ -6363,73 +17169,106 @@ func (s *CreateAgentActionGroupInput) Validate() error { return nil } -// SetActionGroupExecutor sets the ActionGroupExecutor field's value. -func (s *CreateAgentActionGroupInput) SetActionGroupExecutor(v *ActionGroupExecutor) *CreateAgentActionGroupInput { - s.ActionGroupExecutor = v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *KnowledgeBaseFlowNodeConfiguration) SetKnowledgeBaseId(v string) *KnowledgeBaseFlowNodeConfiguration { + s.KnowledgeBaseId = &v return s } -// SetActionGroupName sets the ActionGroupName field's value. -func (s *CreateAgentActionGroupInput) SetActionGroupName(v string) *CreateAgentActionGroupInput { - s.ActionGroupName = &v +// SetModelId sets the ModelId field's value. +func (s *KnowledgeBaseFlowNodeConfiguration) SetModelId(v string) *KnowledgeBaseFlowNodeConfiguration { + s.ModelId = &v return s } -// SetActionGroupState sets the ActionGroupState field's value. -func (s *CreateAgentActionGroupInput) SetActionGroupState(v string) *CreateAgentActionGroupInput { - s.ActionGroupState = &v - return s +// Contains details about a knowledge base. +type KnowledgeBaseSummary struct { + _ struct{} `type:"structure"` + + // The description of the knowledge base. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + + // The name of the knowledge base. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The status of the knowledge base. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` + + // The time at which the knowledge base was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` } -// SetAgentId sets the AgentId field's value. -func (s *CreateAgentActionGroupInput) SetAgentId(v string) *CreateAgentActionGroupInput { - s.AgentId = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s KnowledgeBaseSummary) String() string { + return awsutil.Prettify(s) } -// SetAgentVersion sets the AgentVersion field's value. -func (s *CreateAgentActionGroupInput) SetAgentVersion(v string) *CreateAgentActionGroupInput { - s.AgentVersion = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s KnowledgeBaseSummary) GoString() string { + return s.String() } -// SetApiSchema sets the ApiSchema field's value. -func (s *CreateAgentActionGroupInput) SetApiSchema(v *APISchema) *CreateAgentActionGroupInput { - s.ApiSchema = v +// SetDescription sets the Description field's value. +func (s *KnowledgeBaseSummary) SetDescription(v string) *KnowledgeBaseSummary { + s.Description = &v return s } -// SetClientToken sets the ClientToken field's value. -func (s *CreateAgentActionGroupInput) SetClientToken(v string) *CreateAgentActionGroupInput { - s.ClientToken = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *KnowledgeBaseSummary) SetKnowledgeBaseId(v string) *KnowledgeBaseSummary { + s.KnowledgeBaseId = &v return s } -// SetDescription sets the Description field's value. -func (s *CreateAgentActionGroupInput) SetDescription(v string) *CreateAgentActionGroupInput { - s.Description = &v +// SetName sets the Name field's value. +func (s *KnowledgeBaseSummary) SetName(v string) *KnowledgeBaseSummary { + s.Name = &v return s } -// SetFunctionSchema sets the FunctionSchema field's value. -func (s *CreateAgentActionGroupInput) SetFunctionSchema(v *FunctionSchema) *CreateAgentActionGroupInput { - s.FunctionSchema = v +// SetStatus sets the Status field's value. +func (s *KnowledgeBaseSummary) SetStatus(v string) *KnowledgeBaseSummary { + s.Status = &v return s } -// SetParentActionGroupSignature sets the ParentActionGroupSignature field's value. -func (s *CreateAgentActionGroupInput) SetParentActionGroupSignature(v string) *CreateAgentActionGroupInput { - s.ParentActionGroupSignature = &v +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *KnowledgeBaseSummary) SetUpdatedAt(v time.Time) *KnowledgeBaseSummary { + s.UpdatedAt = &v return s } -type CreateAgentActionGroupOutput struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type LambdaFunctionFlowNodeConfiguration struct { _ struct{} `type:"structure"` - // Contains details about the action group that was created. + // The Amazon Resource Name (ARN) of the Lambda function to invoke. // - // AgentActionGroup is a required field - AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` + // LambdaArn is a required field + LambdaArn *string `locationName:"lambdaArn" type:"string" required:"true"` } // String returns the string representation. @@ -6437,7 +17276,7 @@ type CreateAgentActionGroupOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentActionGroupOutput) String() string { +func (s LambdaFunctionFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -6446,43 +17285,120 @@ func (s CreateAgentActionGroupOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentActionGroupOutput) GoString() string { +func (s LambdaFunctionFlowNodeConfiguration) GoString() string { return s.String() } -// SetAgentActionGroup sets the AgentActionGroup field's value. -func (s *CreateAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *CreateAgentActionGroupOutput { - s.AgentActionGroup = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *LambdaFunctionFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LambdaFunctionFlowNodeConfiguration"} + if s.LambdaArn == nil { + invalidParams.Add(request.NewErrParamRequired("LambdaArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetLambdaArn sets the LambdaArn field's value. +func (s *LambdaFunctionFlowNodeConfiguration) SetLambdaArn(v string) *LambdaFunctionFlowNodeConfiguration { + s.LambdaArn = &v return s } -type CreateAgentAliasInput struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type LexFlowNodeConfiguration struct { _ struct{} `type:"structure"` - // The name of the alias. + // The Amazon Resource Name (ARN) of the Amazon Lex bot alias to invoke. // - // AgentAliasName is a required field - AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` + // BotAliasArn is a required field + BotAliasArn *string `locationName:"botAliasArn" type:"string" required:"true"` + + // The Region to invoke the Amazon Lex bot in. + // + // LocaleId is a required field + LocaleId *string `locationName:"localeId" min:"1" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s LexFlowNodeConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s LexFlowNodeConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *LexFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LexFlowNodeConfiguration"} + if s.BotAliasArn == nil { + invalidParams.Add(request.NewErrParamRequired("BotAliasArn")) + } + if s.LocaleId == nil { + invalidParams.Add(request.NewErrParamRequired("LocaleId")) + } + if s.LocaleId != nil && len(*s.LocaleId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("LocaleId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotAliasArn sets the BotAliasArn field's value. +func (s *LexFlowNodeConfiguration) SetBotAliasArn(v string) *LexFlowNodeConfiguration { + s.BotAliasArn = &v + return s +} + +// SetLocaleId sets the LocaleId field's value. +func (s *LexFlowNodeConfiguration) SetLocaleId(v string) *LexFlowNodeConfiguration { + s.LocaleId = &v + return s +} + +type ListAgentActionGroupsInput struct { + _ struct{} `type:"structure"` // The unique identifier of the agent. // // AgentId is a required field AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` - - // A description of the alias of the agent. - Description *string `locationName:"description" min:"1" type:"string"` - - // Contains details about the routing configuration of the alias. - RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + // The version of the agent. + // + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` - // Any tags that you want to attach to the alias of the agent. - Tags map[string]*string `locationName:"tags" type:"map"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6490,7 +17406,7 @@ type CreateAgentAliasInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentAliasInput) String() string { +func (s ListAgentActionGroupsInput) String() string { return awsutil.Prettify(s) } @@ -6499,37 +17415,30 @@ func (s CreateAgentAliasInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentAliasInput) GoString() string { +func (s ListAgentActionGroupsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateAgentAliasInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateAgentAliasInput"} - if s.AgentAliasName == nil { - invalidParams.Add(request.NewErrParamRequired("AgentAliasName")) - } +func (s *ListAgentActionGroupsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAgentActionGroupsInput"} if s.AgentId == nil { invalidParams.Add(request.NewErrParamRequired("AgentId")) } if s.AgentId != nil && len(*s.AgentId) < 1 { invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) } - if s.RoutingConfiguration != nil { - for i, v := range s.RoutingConfiguration { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) - } - } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -6538,49 +17447,42 @@ func (s *CreateAgentAliasInput) Validate() error { return nil } -// SetAgentAliasName sets the AgentAliasName field's value. -func (s *CreateAgentAliasInput) SetAgentAliasName(v string) *CreateAgentAliasInput { - s.AgentAliasName = &v - return s -} - // SetAgentId sets the AgentId field's value. -func (s *CreateAgentAliasInput) SetAgentId(v string) *CreateAgentAliasInput { +func (s *ListAgentActionGroupsInput) SetAgentId(v string) *ListAgentActionGroupsInput { s.AgentId = &v return s } -// SetClientToken sets the ClientToken field's value. -func (s *CreateAgentAliasInput) SetClientToken(v string) *CreateAgentAliasInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateAgentAliasInput) SetDescription(v string) *CreateAgentAliasInput { - s.Description = &v +// SetAgentVersion sets the AgentVersion field's value. +func (s *ListAgentActionGroupsInput) SetAgentVersion(v string) *ListAgentActionGroupsInput { + s.AgentVersion = &v return s } -// SetRoutingConfiguration sets the RoutingConfiguration field's value. -func (s *CreateAgentAliasInput) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *CreateAgentAliasInput { - s.RoutingConfiguration = v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAgentActionGroupsInput) SetMaxResults(v int64) *ListAgentActionGroupsInput { + s.MaxResults = &v return s } -// SetTags sets the Tags field's value. -func (s *CreateAgentAliasInput) SetTags(v map[string]*string) *CreateAgentAliasInput { - s.Tags = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentActionGroupsInput) SetNextToken(v string) *ListAgentActionGroupsInput { + s.NextToken = &v return s } -type CreateAgentAliasOutput struct { +type ListAgentActionGroupsOutput struct { _ struct{} `type:"structure"` - // Contains details about the alias that was created. + // A list of objects, each of which contains information about an action group. // - // AgentAlias is a required field - AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` + // ActionGroupSummaries is a required field + ActionGroupSummaries []*ActionGroupSummary `locationName:"actionGroupSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6588,7 +17490,7 @@ type CreateAgentAliasOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentAliasOutput) String() string { +func (s ListAgentActionGroupsOutput) String() string { return awsutil.Prettify(s) } @@ -6597,72 +17499,40 @@ func (s CreateAgentAliasOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentAliasOutput) GoString() string { +func (s ListAgentActionGroupsOutput) GoString() string { return s.String() } -// SetAgentAlias sets the AgentAlias field's value. -func (s *CreateAgentAliasOutput) SetAgentAlias(v *AgentAlias) *CreateAgentAliasOutput { - s.AgentAlias = v +// SetActionGroupSummaries sets the ActionGroupSummaries field's value. +func (s *ListAgentActionGroupsOutput) SetActionGroupSummaries(v []*ActionGroupSummary) *ListAgentActionGroupsOutput { + s.ActionGroupSummaries = v return s } -type CreateAgentInput struct { - _ struct{} `type:"structure"` - - // A name for the agent that you create. - // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the agent. - AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` - - // The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent. - CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - - // A description of the agent. - Description *string `locationName:"description" min:"1" type:"string"` - - // The foundation model to be used for orchestration by the agent you create. - FoundationModel *string `locationName:"foundationModel" min:"1" type:"string"` - - // The unique Guardrail configuration assigned to the agent when it is created. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` +// SetNextToken sets the NextToken field's value. +func (s *ListAgentActionGroupsOutput) SetNextToken(v string) *ListAgentActionGroupsOutput { + s.NextToken = &v + return s +} - // 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. - IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` +type ListAgentAliasesInput struct { + _ struct{} `type:"structure"` - // Instructions that tell the agent what it should do and how it should interact - // with users. + // The unique identifier of the agent. // - // Instruction is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by CreateAgentInput's - // String and GoString methods. - Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // Contains configurations to override prompts in different parts of an agent - // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). - // - // PromptOverrideConfiguration is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by CreateAgentInput's - // String and GoString methods. - PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - // Any tags that you want to attach to the agent. - Tags map[string]*string `locationName:"tags" type:"map"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6670,7 +17540,7 @@ type CreateAgentInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentInput) String() string { +func (s ListAgentAliasesInput) String() string { return awsutil.Prettify(s) } @@ -6679,119 +17549,63 @@ func (s CreateAgentInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentInput) GoString() string { +func (s ListAgentAliasesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateAgentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateAgentInput"} - if s.AgentName == nil { - invalidParams.Add(request.NewErrParamRequired("AgentName")) - } - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) - } - if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { - invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.FoundationModel != nil && len(*s.FoundationModel) < 1 { - invalidParams.Add(request.NewErrParamMinLen("FoundationModel", 1)) - } - if s.IdleSessionTTLInSeconds != nil && *s.IdleSessionTTLInSeconds < 60 { - invalidParams.Add(request.NewErrParamMinValue("IdleSessionTTLInSeconds", 60)) - } - if s.Instruction != nil && len(*s.Instruction) < 40 { - invalidParams.Add(request.NewErrParamMinLen("Instruction", 40)) +func (s *ListAgentAliasesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAgentAliasesInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) } - if s.PromptOverrideConfiguration != nil { - if err := s.PromptOverrideConfiguration.Validate(); err != nil { - invalidParams.AddNested("PromptOverrideConfiguration", err.(request.ErrInvalidParams)) - } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } - - if invalidParams.Len() > 0 { - return invalidParams + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - return nil -} - -// SetAgentName sets the AgentName field's value. -func (s *CreateAgentInput) SetAgentName(v string) *CreateAgentInput { - s.AgentName = &v - return s -} - -// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. -func (s *CreateAgentInput) SetAgentResourceRoleArn(v string) *CreateAgentInput { - s.AgentResourceRoleArn = &v - return s -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateAgentInput) SetClientToken(v string) *CreateAgentInput { - s.ClientToken = &v - return s -} - -// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. -func (s *CreateAgentInput) SetCustomerEncryptionKeyArn(v string) *CreateAgentInput { - s.CustomerEncryptionKeyArn = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateAgentInput) SetDescription(v string) *CreateAgentInput { - s.Description = &v - return s -} - -// SetFoundationModel sets the FoundationModel field's value. -func (s *CreateAgentInput) SetFoundationModel(v string) *CreateAgentInput { - s.FoundationModel = &v - return s -} - -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *CreateAgentInput) SetGuardrailConfiguration(v *GuardrailConfiguration) *CreateAgentInput { - s.GuardrailConfiguration = v - return s -} -// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. -func (s *CreateAgentInput) SetIdleSessionTTLInSeconds(v int64) *CreateAgentInput { - s.IdleSessionTTLInSeconds = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetInstruction sets the Instruction field's value. -func (s *CreateAgentInput) SetInstruction(v string) *CreateAgentInput { - s.Instruction = &v +// SetAgentId sets the AgentId field's value. +func (s *ListAgentAliasesInput) SetAgentId(v string) *ListAgentAliasesInput { + s.AgentId = &v return s } -// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. -func (s *CreateAgentInput) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *CreateAgentInput { - s.PromptOverrideConfiguration = v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAgentAliasesInput) SetMaxResults(v int64) *ListAgentAliasesInput { + s.MaxResults = &v return s } -// SetTags sets the Tags field's value. -func (s *CreateAgentInput) SetTags(v map[string]*string) *CreateAgentInput { - s.Tags = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentAliasesInput) SetNextToken(v string) *ListAgentAliasesInput { + s.NextToken = &v return s } -type CreateAgentOutput struct { +type ListAgentAliasesOutput struct { _ struct{} `type:"structure"` - // Contains details about the agent created. + // A list of objects, each of which contains information about an alias of the + // agent. // - // Agent is a required field - Agent *Agent `locationName:"agent" type:"structure" required:"true"` + // AgentAliasSummaries is a required field + AgentAliasSummaries []*AgentAliasSummary `locationName:"agentAliasSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6799,7 +17613,7 @@ type CreateAgentOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentOutput) String() string { +func (s ListAgentAliasesOutput) String() string { return awsutil.Prettify(s) } @@ -6808,51 +17622,47 @@ func (s CreateAgentOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateAgentOutput) GoString() string { +func (s ListAgentAliasesOutput) GoString() string { return s.String() } -// SetAgent sets the Agent field's value. -func (s *CreateAgentOutput) SetAgent(v *Agent) *CreateAgentOutput { - s.Agent = v +// SetAgentAliasSummaries sets the AgentAliasSummaries field's value. +func (s *ListAgentAliasesOutput) SetAgentAliasSummaries(v []*AgentAliasSummary) *ListAgentAliasesOutput { + s.AgentAliasSummaries = v return s } -type CreateDataSourceInput struct { - _ struct{} `type:"structure"` - - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` - - // The data deletion policy assigned to the data source. - DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` - - // Contains metadata about where the data source is stored. - // - // DataSourceConfiguration is a required field - DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` +// SetNextToken sets the NextToken field's value. +func (s *ListAgentAliasesOutput) SetNextToken(v string) *ListAgentAliasesOutput { + s.NextToken = &v + return s +} - // A description of the data source. - Description *string `locationName:"description" min:"1" type:"string"` +type ListAgentKnowledgeBasesInput struct { + _ struct{} `type:"structure"` - // The unique identifier of the knowledge base to which to add the data source. + // The unique identifier of the agent for which to return information about + // knowledge bases associated with it. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // The name of the data source. + // The version of the agent for which to return information about knowledge + // bases associated with it. // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` - // Contains details about the server-side encryption for the data source. - ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - // Contains details about how to ingest the documents in the data source. - VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6860,7 +17670,7 @@ type CreateDataSourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDataSourceInput) String() string { +func (s ListAgentKnowledgeBasesInput) String() string { return awsutil.Prettify(s) } @@ -6869,45 +17679,30 @@ func (s CreateDataSourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDataSourceInput) GoString() string { +func (s ListAgentKnowledgeBasesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateDataSourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateDataSourceInput"} - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) - } - if s.DataSourceConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceConfiguration")) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +func (s *ListAgentKnowledgeBasesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAgentKnowledgeBasesInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } - if s.Name == nil { - invalidParams.Add(request.NewErrParamRequired("Name")) + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) } - if s.DataSourceConfiguration != nil { - if err := s.DataSourceConfiguration.Validate(); err != nil { - invalidParams.AddNested("DataSourceConfiguration", err.(request.ErrInvalidParams)) - } + if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) } - if s.ServerSideEncryptionConfiguration != nil { - if err := s.ServerSideEncryptionConfiguration.Validate(); err != nil { - invalidParams.AddNested("ServerSideEncryptionConfiguration", err.(request.ErrInvalidParams)) - } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.VectorIngestionConfiguration != nil { - if err := s.VectorIngestionConfiguration.Validate(); err != nil { - invalidParams.AddNested("VectorIngestionConfiguration", err.(request.ErrInvalidParams)) - } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -6916,61 +17711,43 @@ func (s *CreateDataSourceInput) Validate() error { return nil } -// SetClientToken sets the ClientToken field's value. -func (s *CreateDataSourceInput) SetClientToken(v string) *CreateDataSourceInput { - s.ClientToken = &v - return s -} - -// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. -func (s *CreateDataSourceInput) SetDataDeletionPolicy(v string) *CreateDataSourceInput { - s.DataDeletionPolicy = &v - return s -} - -// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. -func (s *CreateDataSourceInput) SetDataSourceConfiguration(v *DataSourceConfiguration) *CreateDataSourceInput { - s.DataSourceConfiguration = v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateDataSourceInput) SetDescription(v string) *CreateDataSourceInput { - s.Description = &v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *CreateDataSourceInput) SetKnowledgeBaseId(v string) *CreateDataSourceInput { - s.KnowledgeBaseId = &v +// SetAgentId sets the AgentId field's value. +func (s *ListAgentKnowledgeBasesInput) SetAgentId(v string) *ListAgentKnowledgeBasesInput { + s.AgentId = &v return s } -// SetName sets the Name field's value. -func (s *CreateDataSourceInput) SetName(v string) *CreateDataSourceInput { - s.Name = &v +// SetAgentVersion sets the AgentVersion field's value. +func (s *ListAgentKnowledgeBasesInput) SetAgentVersion(v string) *ListAgentKnowledgeBasesInput { + s.AgentVersion = &v return s } -// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. -func (s *CreateDataSourceInput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *CreateDataSourceInput { - s.ServerSideEncryptionConfiguration = v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAgentKnowledgeBasesInput) SetMaxResults(v int64) *ListAgentKnowledgeBasesInput { + s.MaxResults = &v return s } -// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. -func (s *CreateDataSourceInput) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *CreateDataSourceInput { - s.VectorIngestionConfiguration = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentKnowledgeBasesInput) SetNextToken(v string) *ListAgentKnowledgeBasesInput { + s.NextToken = &v return s } -type CreateDataSourceOutput struct { +type ListAgentKnowledgeBasesOutput struct { _ struct{} `type:"structure"` - // Contains details about the data source. + // A list of objects, each of which contains information about a knowledge base + // associated with the agent. // - // DataSource is a required field - DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` + // AgentKnowledgeBaseSummaries is a required field + AgentKnowledgeBaseSummaries []*AgentKnowledgeBaseSummary `locationName:"agentKnowledgeBaseSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -6978,7 +17755,7 @@ type CreateDataSourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDataSourceOutput) String() string { +func (s ListAgentKnowledgeBasesOutput) String() string { return awsutil.Prettify(s) } @@ -6987,53 +17764,40 @@ func (s CreateDataSourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDataSourceOutput) GoString() string { +func (s ListAgentKnowledgeBasesOutput) GoString() string { return s.String() } -// SetDataSource sets the DataSource field's value. -func (s *CreateDataSourceOutput) SetDataSource(v *DataSource) *CreateDataSourceOutput { - s.DataSource = v +// SetAgentKnowledgeBaseSummaries sets the AgentKnowledgeBaseSummaries field's value. +func (s *ListAgentKnowledgeBasesOutput) SetAgentKnowledgeBaseSummaries(v []*AgentKnowledgeBaseSummary) *ListAgentKnowledgeBasesOutput { + s.AgentKnowledgeBaseSummaries = v return s } -type CreateKnowledgeBaseInput struct { - _ struct{} `type:"structure"` - - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` - - // A description of the knowledge base. - Description *string `locationName:"description" min:"1" type:"string"` - - // Contains details about the embeddings model used for the knowledge base. - // - // KnowledgeBaseConfiguration is a required field - KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` - - // A name for the knowledge base. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` +// SetNextToken sets the NextToken field's value. +func (s *ListAgentKnowledgeBasesOutput) SetNextToken(v string) *ListAgentKnowledgeBasesOutput { + s.NextToken = &v + return s +} - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the knowledge base. - // - // RoleArn is a required field - RoleArn *string `locationName:"roleArn" type:"string" required:"true"` +type ListAgentVersionsInput struct { + _ struct{} `type:"structure"` - // Contains details about the configuration of the vector database used for - // the knowledge base. + // The unique identifier of the agent. // - // StorageConfiguration is a required field - StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // Specify the key-value pairs for the tags that you want to attach to your - // knowledge base in this object. - Tags map[string]*string `locationName:"tags" type:"map"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7041,7 +17805,7 @@ type CreateKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateKnowledgeBaseInput) String() string { +func (s ListAgentVersionsInput) String() string { return awsutil.Prettify(s) } @@ -7050,40 +17814,24 @@ func (s CreateKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateKnowledgeBaseInput) GoString() string { +func (s ListAgentVersionsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateKnowledgeBaseInput"} - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.KnowledgeBaseConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseConfiguration")) - } - if s.Name == nil { - invalidParams.Add(request.NewErrParamRequired("Name")) - } - if s.RoleArn == nil { - invalidParams.Add(request.NewErrParamRequired("RoleArn")) +func (s *ListAgentVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAgentVersionsInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) } - if s.StorageConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("StorageConfiguration")) + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } - if s.KnowledgeBaseConfiguration != nil { - if err := s.KnowledgeBaseConfiguration.Validate(); err != nil { - invalidParams.AddNested("KnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) - } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.StorageConfiguration != nil { - if err := s.StorageConfiguration.Validate(); err != nil { - invalidParams.AddNested("StorageConfiguration", err.(request.ErrInvalidParams)) - } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7092,55 +17840,37 @@ func (s *CreateKnowledgeBaseInput) Validate() error { return nil } -// SetClientToken sets the ClientToken field's value. -func (s *CreateKnowledgeBaseInput) SetClientToken(v string) *CreateKnowledgeBaseInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateKnowledgeBaseInput) SetDescription(v string) *CreateKnowledgeBaseInput { - s.Description = &v - return s -} - -// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. -func (s *CreateKnowledgeBaseInput) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *CreateKnowledgeBaseInput { - s.KnowledgeBaseConfiguration = v - return s -} - -// SetName sets the Name field's value. -func (s *CreateKnowledgeBaseInput) SetName(v string) *CreateKnowledgeBaseInput { - s.Name = &v - return s -} - -// SetRoleArn sets the RoleArn field's value. -func (s *CreateKnowledgeBaseInput) SetRoleArn(v string) *CreateKnowledgeBaseInput { - s.RoleArn = &v +// SetAgentId sets the AgentId field's value. +func (s *ListAgentVersionsInput) SetAgentId(v string) *ListAgentVersionsInput { + s.AgentId = &v return s } -// SetStorageConfiguration sets the StorageConfiguration field's value. -func (s *CreateKnowledgeBaseInput) SetStorageConfiguration(v *StorageConfiguration) *CreateKnowledgeBaseInput { - s.StorageConfiguration = v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAgentVersionsInput) SetMaxResults(v int64) *ListAgentVersionsInput { + s.MaxResults = &v return s } -// SetTags sets the Tags field's value. -func (s *CreateKnowledgeBaseInput) SetTags(v map[string]*string) *CreateKnowledgeBaseInput { - s.Tags = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentVersionsInput) SetNextToken(v string) *ListAgentVersionsInput { + s.NextToken = &v return s } -type CreateKnowledgeBaseOutput struct { +type ListAgentVersionsOutput struct { _ struct{} `type:"structure"` - // Contains details about the knowledge base. + // A list of objects, each of which contains information about a version of + // the agent. // - // KnowledgeBase is a required field - KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` + // AgentVersionSummaries is a required field + AgentVersionSummaries []*AgentVersionSummary `locationName:"agentVersionSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7148,7 +17878,7 @@ type CreateKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateKnowledgeBaseOutput) String() string { +func (s ListAgentVersionsOutput) String() string { return awsutil.Prettify(s) } @@ -7157,74 +17887,35 @@ func (s CreateKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateKnowledgeBaseOutput) GoString() string { +func (s ListAgentVersionsOutput) GoString() string { return s.String() } -// SetKnowledgeBase sets the KnowledgeBase field's value. -func (s *CreateKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *CreateKnowledgeBaseOutput { - s.KnowledgeBase = v +// SetAgentVersionSummaries sets the AgentVersionSummaries field's value. +func (s *ListAgentVersionsOutput) SetAgentVersionSummaries(v []*AgentVersionSummary) *ListAgentVersionsOutput { + s.AgentVersionSummaries = v return s } -// Contains details about a data source. -type DataSource struct { - _ struct{} `type:"structure"` - - // The time at which the data source was created. - // - // CreatedAt is a required field - CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - - // The data deletion policy for a data source. - DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` - - // Contains details about how the data source is stored. - // - // DataSourceConfiguration is a required field - DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` - - // The unique identifier of the data source. - // - // DataSourceId is a required field - DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - - // The description of the data source. - Description *string `locationName:"description" min:"1" type:"string"` - - // The detailed reasons on the failure to delete a data source. - FailureReasons []*string `locationName:"failureReasons" type:"list"` - - // The unique identifier of the knowledge base to which the data source belongs. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` - - // The name of the data source. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` - - // Contains details about the configuration of the server-side encryption. - ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` +// SetNextToken sets the NextToken field's value. +func (s *ListAgentVersionsOutput) SetNextToken(v string) *ListAgentVersionsOutput { + s.NextToken = &v + return s +} - // 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. - // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` +type ListAgentsInput struct { + _ struct{} `type:"structure"` - // The time at which the data source was last updated. - // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - // Contains details about how to ingest the documents in the data source. - VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7232,7 +17923,7 @@ type DataSource struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSource) String() string { +func (s ListAgentsInput) String() string { return awsutil.Prettify(s) } @@ -7241,94 +17932,101 @@ func (s DataSource) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSource) GoString() string { +func (s ListAgentsInput) GoString() string { return s.String() } -// SetCreatedAt sets the CreatedAt field's value. -func (s *DataSource) SetCreatedAt(v time.Time) *DataSource { - s.CreatedAt = &v - return s -} - -// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. -func (s *DataSource) SetDataDeletionPolicy(v string) *DataSource { - s.DataDeletionPolicy = &v - return s -} - -// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. -func (s *DataSource) SetDataSourceConfiguration(v *DataSourceConfiguration) *DataSource { - s.DataSourceConfiguration = v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListAgentsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAgentsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } -// SetDataSourceId sets the DataSourceId field's value. -func (s *DataSource) SetDataSourceId(v string) *DataSource { - s.DataSourceId = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetDescription sets the Description field's value. -func (s *DataSource) SetDescription(v string) *DataSource { - s.Description = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAgentsInput) SetMaxResults(v int64) *ListAgentsInput { + s.MaxResults = &v return s } -// SetFailureReasons sets the FailureReasons field's value. -func (s *DataSource) SetFailureReasons(v []*string) *DataSource { - s.FailureReasons = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentsInput) SetNextToken(v string) *ListAgentsInput { + s.NextToken = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DataSource) SetKnowledgeBaseId(v string) *DataSource { - s.KnowledgeBaseId = &v - return s -} +type ListAgentsOutput struct { + _ struct{} `type:"structure"` -// SetName sets the Name field's value. -func (s *DataSource) SetName(v string) *DataSource { - s.Name = &v - return s + // A list of objects, each of which contains information about an agent. + // + // AgentSummaries is a required field + AgentSummaries []*AgentSummary `locationName:"agentSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } -// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. -func (s *DataSource) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *DataSource { - s.ServerSideEncryptionConfiguration = v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListAgentsOutput) String() string { + return awsutil.Prettify(s) } -// SetStatus sets the Status field's value. -func (s *DataSource) SetStatus(v string) *DataSource { - s.Status = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListAgentsOutput) GoString() string { + return s.String() } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *DataSource) SetUpdatedAt(v time.Time) *DataSource { - s.UpdatedAt = &v +// SetAgentSummaries sets the AgentSummaries field's value. +func (s *ListAgentsOutput) SetAgentSummaries(v []*AgentSummary) *ListAgentsOutput { + s.AgentSummaries = v return s } -// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. -func (s *DataSource) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *DataSource { - s.VectorIngestionConfiguration = v +// SetNextToken sets the NextToken field's value. +func (s *ListAgentsOutput) SetNextToken(v string) *ListAgentsOutput { + s.NextToken = &v return s } -// Contains details about how a data source is stored. -type DataSourceConfiguration struct { +type ListDataSourcesInput struct { _ struct{} `type:"structure"` - // Contains details about the configuration of the S3 object containing the - // data source. - S3Configuration *S3DataSourceConfiguration `locationName:"s3Configuration" type:"structure"` - - // The type of storage for the data source. + // The unique identifier of the knowledge base for which to return a list of + // information. // - // Type is a required field - Type *string `locationName:"type" type:"string" required:"true" enum:"DataSourceType"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7336,7 +18034,7 @@ type DataSourceConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSourceConfiguration) String() string { +func (s ListDataSourcesInput) String() string { return awsutil.Prettify(s) } @@ -7345,20 +18043,24 @@ func (s DataSourceConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSourceConfiguration) GoString() string { +func (s ListDataSourcesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DataSourceConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DataSourceConfiguration"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) +func (s *ListDataSourcesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListDataSourcesInput"} + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) } - if s.S3Configuration != nil { - if err := s.S3Configuration.Validate(); err != nil { - invalidParams.AddNested("S3Configuration", err.(request.ErrInvalidParams)) - } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7367,49 +18069,36 @@ func (s *DataSourceConfiguration) Validate() error { return nil } -// SetS3Configuration sets the S3Configuration field's value. -func (s *DataSourceConfiguration) SetS3Configuration(v *S3DataSourceConfiguration) *DataSourceConfiguration { - s.S3Configuration = v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *ListDataSourcesInput) SetKnowledgeBaseId(v string) *ListDataSourcesInput { + s.KnowledgeBaseId = &v return s } -// SetType sets the Type field's value. -func (s *DataSourceConfiguration) SetType(v string) *DataSourceConfiguration { - s.Type = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListDataSourcesInput) SetMaxResults(v int64) *ListDataSourcesInput { + s.MaxResults = &v return s } -// Contains details about a data source. -type DataSourceSummary struct { - _ struct{} `type:"structure"` - - // The unique identifier of the data source. - // - // DataSourceId is a required field - DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - - // The description of the data source. - Description *string `locationName:"description" min:"1" type:"string"` - - // The unique identifier of the knowledge base to which the data source belongs. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` +// SetNextToken sets the NextToken field's value. +func (s *ListDataSourcesInput) SetNextToken(v string) *ListDataSourcesInput { + s.NextToken = &v + return s +} - // The name of the data source. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` +type ListDataSourcesOutput struct { + _ struct{} `type:"structure"` - // The status of the data source. + // A list of objects, each of which contains information about a data source. // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` + // DataSourceSummaries is a required field + DataSourceSummaries []*DataSourceSummary `locationName:"dataSourceSummaries" type:"list" required:"true"` - // The time at which the data source was last updated. - // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7417,7 +18106,7 @@ type DataSourceSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSourceSummary) String() string { +func (s ListDataSourcesOutput) String() string { return awsutil.Prettify(s) } @@ -7426,68 +18115,40 @@ func (s DataSourceSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DataSourceSummary) GoString() string { +func (s ListDataSourcesOutput) GoString() string { return s.String() } -// SetDataSourceId sets the DataSourceId field's value. -func (s *DataSourceSummary) SetDataSourceId(v string) *DataSourceSummary { - s.DataSourceId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *DataSourceSummary) SetDescription(v string) *DataSourceSummary { - s.Description = &v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DataSourceSummary) SetKnowledgeBaseId(v string) *DataSourceSummary { - s.KnowledgeBaseId = &v - return s -} - -// SetName sets the Name field's value. -func (s *DataSourceSummary) SetName(v string) *DataSourceSummary { - s.Name = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *DataSourceSummary) SetStatus(v string) *DataSourceSummary { - s.Status = &v +// SetDataSourceSummaries sets the DataSourceSummaries field's value. +func (s *ListDataSourcesOutput) SetDataSourceSummaries(v []*DataSourceSummary) *ListDataSourcesOutput { + s.DataSourceSummaries = v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *DataSourceSummary) SetUpdatedAt(v time.Time) *DataSourceSummary { - s.UpdatedAt = &v +// SetNextToken sets the NextToken field's value. +func (s *ListDataSourcesOutput) SetNextToken(v string) *ListDataSourcesOutput { + s.NextToken = &v return s } -type DeleteAgentActionGroupInput struct { +type ListFlowAliasesInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the action group to delete. - // - // ActionGroupId is a required field - ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` - - // The unique identifier of the agent that the action group belongs to. + // The unique identifier of the flow for which aliases are being returned. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` - // The version of the agent that the action group belongs to. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + // 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. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` - // 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. - SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` + // 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. + NextToken *string `location:"querystring" locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7495,7 +18156,7 @@ type DeleteAgentActionGroupInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentActionGroupInput) String() string { +func (s ListFlowAliasesInput) String() string { return awsutil.Prettify(s) } @@ -7504,30 +18165,24 @@ func (s DeleteAgentActionGroupInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentActionGroupInput) GoString() string { +func (s ListFlowAliasesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteAgentActionGroupInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteAgentActionGroupInput"} - if s.ActionGroupId == nil { - invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) - } - if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) +func (s *ListFlowAliasesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListFlowAliasesInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7536,32 +18191,36 @@ func (s *DeleteAgentActionGroupInput) Validate() error { return nil } -// SetActionGroupId sets the ActionGroupId field's value. -func (s *DeleteAgentActionGroupInput) SetActionGroupId(v string) *DeleteAgentActionGroupInput { - s.ActionGroupId = &v - return s -} - -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentActionGroupInput) SetAgentId(v string) *DeleteAgentActionGroupInput { - s.AgentId = &v +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *ListFlowAliasesInput) SetFlowIdentifier(v string) *ListFlowAliasesInput { + s.FlowIdentifier = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *DeleteAgentActionGroupInput) SetAgentVersion(v string) *DeleteAgentActionGroupInput { - s.AgentVersion = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListFlowAliasesInput) SetMaxResults(v int64) *ListFlowAliasesInput { + s.MaxResults = &v return s } -// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. -func (s *DeleteAgentActionGroupInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentActionGroupInput { - s.SkipResourceInUseCheck = &v +// SetNextToken sets the NextToken field's value. +func (s *ListFlowAliasesInput) SetNextToken(v string) *ListFlowAliasesInput { + s.NextToken = &v return s } -type DeleteAgentActionGroupOutput struct { +type ListFlowAliasesOutput struct { _ struct{} `type:"structure"` + + // A list, each member of which contains information about a flow alias. + // + // FlowAliasSummaries is a required field + FlowAliasSummaries []*FlowAliasSummary `locationName:"flowAliasSummaries" type:"list" required:"true"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7569,7 +18228,7 @@ type DeleteAgentActionGroupOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentActionGroupOutput) String() string { +func (s ListFlowAliasesOutput) String() string { return awsutil.Prettify(s) } @@ -7578,22 +18237,40 @@ func (s DeleteAgentActionGroupOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentActionGroupOutput) GoString() string { +func (s ListFlowAliasesOutput) GoString() string { return s.String() } -type DeleteAgentAliasInput struct { +// SetFlowAliasSummaries sets the FlowAliasSummaries field's value. +func (s *ListFlowAliasesOutput) SetFlowAliasSummaries(v []*FlowAliasSummary) *ListFlowAliasesOutput { + s.FlowAliasSummaries = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListFlowAliasesOutput) SetNextToken(v string) *ListFlowAliasesOutput { + s.NextToken = &v + return s +} + +type ListFlowVersionsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the alias to delete. + // The unique identifier of the flow. // - // AgentAliasId is a required field - AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` - // The unique identifier of the agent that the alias belongs to. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // 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. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `location:"querystring" locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7601,7 +18278,7 @@ type DeleteAgentAliasInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentAliasInput) String() string { +func (s ListFlowVersionsInput) String() string { return awsutil.Prettify(s) } @@ -7610,24 +18287,24 @@ func (s DeleteAgentAliasInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentAliasInput) GoString() string { +func (s ListFlowVersionsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteAgentAliasInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteAgentAliasInput"} - if s.AgentAliasId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) +func (s *ListFlowVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListFlowVersionsInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) } - if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { - invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7636,35 +18313,36 @@ func (s *DeleteAgentAliasInput) Validate() error { return nil } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *DeleteAgentAliasInput) SetAgentAliasId(v string) *DeleteAgentAliasInput { - s.AgentAliasId = &v +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *ListFlowVersionsInput) SetFlowIdentifier(v string) *ListFlowVersionsInput { + s.FlowIdentifier = &v return s } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentAliasInput) SetAgentId(v string) *DeleteAgentAliasInput { - s.AgentId = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListFlowVersionsInput) SetMaxResults(v int64) *ListFlowVersionsInput { + s.MaxResults = &v return s } -type DeleteAgentAliasOutput struct { - _ struct{} `type:"structure"` +// SetNextToken sets the NextToken field's value. +func (s *ListFlowVersionsInput) SetNextToken(v string) *ListFlowVersionsInput { + s.NextToken = &v + return s +} - // The unique identifier of the alias that was deleted. - // - // AgentAliasId is a required field - AgentAliasId *string `locationName:"agentAliasId" min:"10" type:"string" required:"true"` +type ListFlowVersionsOutput struct { + _ struct{} `type:"structure"` - // The status of the alias. + // A list, each member of which contains information about a flow. // - // AgentAliasStatus is a required field - AgentAliasStatus *string `locationName:"agentAliasStatus" type:"string" required:"true" enum:"AgentAliasStatus"` + // FlowVersionSummaries is a required field + FlowVersionSummaries []*FlowVersionSummary `locationName:"flowVersionSummaries" type:"list" required:"true"` - // The unique identifier of the agent that the alias belongs to. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7672,7 +18350,7 @@ type DeleteAgentAliasOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentAliasOutput) String() string { +func (s ListFlowVersionsOutput) String() string { return awsutil.Prettify(s) } @@ -7681,40 +18359,35 @@ func (s DeleteAgentAliasOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentAliasOutput) GoString() string { +func (s ListFlowVersionsOutput) GoString() string { return s.String() } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *DeleteAgentAliasOutput) SetAgentAliasId(v string) *DeleteAgentAliasOutput { - s.AgentAliasId = &v - return s -} - -// SetAgentAliasStatus sets the AgentAliasStatus field's value. -func (s *DeleteAgentAliasOutput) SetAgentAliasStatus(v string) *DeleteAgentAliasOutput { - s.AgentAliasStatus = &v +// SetFlowVersionSummaries sets the FlowVersionSummaries field's value. +func (s *ListFlowVersionsOutput) SetFlowVersionSummaries(v []*FlowVersionSummary) *ListFlowVersionsOutput { + s.FlowVersionSummaries = v return s } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentAliasOutput) SetAgentId(v string) *DeleteAgentAliasOutput { - s.AgentId = &v +// SetNextToken sets the NextToken field's value. +func (s *ListFlowVersionsOutput) SetNextToken(v string) *ListFlowVersionsOutput { + s.NextToken = &v return s } -type DeleteAgentInput struct { +type ListFlowsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the agent to delete. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // 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. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` - // 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. - SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` + // 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. + NextToken *string `location:"querystring" locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7722,7 +18395,7 @@ type DeleteAgentInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentInput) String() string { +func (s ListFlowsInput) String() string { return awsutil.Prettify(s) } @@ -7731,18 +18404,18 @@ func (s DeleteAgentInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentInput) GoString() string { +func (s ListFlowsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteAgentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteAgentInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *ListFlowsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListFlowsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7751,30 +18424,30 @@ func (s *DeleteAgentInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentInput) SetAgentId(v string) *DeleteAgentInput { - s.AgentId = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListFlowsInput) SetMaxResults(v int64) *ListFlowsInput { + s.MaxResults = &v return s } -// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. -func (s *DeleteAgentInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentInput { - s.SkipResourceInUseCheck = &v +// SetNextToken sets the NextToken field's value. +func (s *ListFlowsInput) SetNextToken(v string) *ListFlowsInput { + s.NextToken = &v return s } -type DeleteAgentOutput struct { +type ListFlowsOutput struct { _ struct{} `type:"structure"` - // The unique identifier of the agent that was deleted. + // A list, each member of which contains information about a flow. // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` + // FlowSummaries is a required field + FlowSummaries []*FlowSummary `locationName:"flowSummaries" type:"list" required:"true"` - // The status of the agent. - // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7782,7 +18455,7 @@ type DeleteAgentOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentOutput) String() string { +func (s ListFlowsOutput) String() string { return awsutil.Prettify(s) } @@ -7791,39 +18464,52 @@ func (s DeleteAgentOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentOutput) GoString() string { +func (s ListFlowsOutput) GoString() string { return s.String() } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentOutput) SetAgentId(v string) *DeleteAgentOutput { - s.AgentId = &v +// SetFlowSummaries sets the FlowSummaries field's value. +func (s *ListFlowsOutput) SetFlowSummaries(v []*FlowSummary) *ListFlowsOutput { + s.FlowSummaries = v return s } -// SetAgentStatus sets the AgentStatus field's value. -func (s *DeleteAgentOutput) SetAgentStatus(v string) *DeleteAgentOutput { - s.AgentStatus = &v +// SetNextToken sets the NextToken field's value. +func (s *ListFlowsOutput) SetNextToken(v string) *ListFlowsOutput { + s.NextToken = &v return s } -type DeleteAgentVersionInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type ListIngestionJobsInput struct { + _ struct{} `type:"structure"` - // The unique identifier of the agent that the version belongs to. + // The unique identifier of the data source for which to return ingestion jobs. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` - // The version of the agent to delete. + // Contains a definition of a filter for which to filter the results. + Filters []*IngestionJobFilter `locationName:"filters" min:"1" type:"list"` + + // The unique identifier of the knowledge base for which to return ingestion + // jobs. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" type:"string" required:"true"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` - // 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. - SkipResourceInUseCheck *bool `location:"querystring" locationName:"skipResourceInUseCheck" type:"boolean"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // Contains details about how to sort the results. + SortBy *IngestionJobSortBy `locationName:"sortBy" type:"structure"` } // String returns the string representation. @@ -7831,7 +18517,7 @@ type DeleteAgentVersionInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentVersionInput) String() string { +func (s ListIngestionJobsInput) String() string { return awsutil.Prettify(s) } @@ -7840,24 +18526,48 @@ func (s DeleteAgentVersionInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentVersionInput) GoString() string { +func (s ListIngestionJobsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteAgentVersionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteAgentVersionInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *ListIngestionJobsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListIngestionJobsInput"} + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + if s.Filters != nil && len(s.Filters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Filters", 1)) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + if s.Filters != nil { + for i, v := range s.Filters { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) + } + } + } + if s.SortBy != nil { + if err := s.SortBy.Validate(); err != nil { + invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -7866,41 +18576,55 @@ func (s *DeleteAgentVersionInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentVersionInput) SetAgentId(v string) *DeleteAgentVersionInput { - s.AgentId = &v +// SetDataSourceId sets the DataSourceId field's value. +func (s *ListIngestionJobsInput) SetDataSourceId(v string) *ListIngestionJobsInput { + s.DataSourceId = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *DeleteAgentVersionInput) SetAgentVersion(v string) *DeleteAgentVersionInput { - s.AgentVersion = &v +// SetFilters sets the Filters field's value. +func (s *ListIngestionJobsInput) SetFilters(v []*IngestionJobFilter) *ListIngestionJobsInput { + s.Filters = v + return s +} + +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *ListIngestionJobsInput) SetKnowledgeBaseId(v string) *ListIngestionJobsInput { + s.KnowledgeBaseId = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListIngestionJobsInput) SetMaxResults(v int64) *ListIngestionJobsInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListIngestionJobsInput) SetNextToken(v string) *ListIngestionJobsInput { + s.NextToken = &v return s } -// SetSkipResourceInUseCheck sets the SkipResourceInUseCheck field's value. -func (s *DeleteAgentVersionInput) SetSkipResourceInUseCheck(v bool) *DeleteAgentVersionInput { - s.SkipResourceInUseCheck = &v +// SetSortBy sets the SortBy field's value. +func (s *ListIngestionJobsInput) SetSortBy(v *IngestionJobSortBy) *ListIngestionJobsInput { + s.SortBy = v return s } -type DeleteAgentVersionOutput struct { +type ListIngestionJobsOutput struct { _ struct{} `type:"structure"` - // The unique identifier of the agent that the version belongs to. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` - - // The status of the agent version. + // A list of objects, each of which contains information about an ingestion + // job. // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` + // IngestionJobSummaries is a required field + IngestionJobSummaries []*IngestionJobSummary `locationName:"ingestionJobSummaries" type:"list" required:"true"` - // The version that was deleted. - // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" type:"string" required:"true"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7908,7 +18632,7 @@ type DeleteAgentVersionOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentVersionOutput) String() string { +func (s ListIngestionJobsOutput) String() string { return awsutil.Prettify(s) } @@ -7917,41 +18641,35 @@ func (s DeleteAgentVersionOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteAgentVersionOutput) GoString() string { +func (s ListIngestionJobsOutput) GoString() string { return s.String() } -// SetAgentId sets the AgentId field's value. -func (s *DeleteAgentVersionOutput) SetAgentId(v string) *DeleteAgentVersionOutput { - s.AgentId = &v - return s -} - -// SetAgentStatus sets the AgentStatus field's value. -func (s *DeleteAgentVersionOutput) SetAgentStatus(v string) *DeleteAgentVersionOutput { - s.AgentStatus = &v +// SetIngestionJobSummaries sets the IngestionJobSummaries field's value. +func (s *ListIngestionJobsOutput) SetIngestionJobSummaries(v []*IngestionJobSummary) *ListIngestionJobsOutput { + s.IngestionJobSummaries = v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *DeleteAgentVersionOutput) SetAgentVersion(v string) *DeleteAgentVersionOutput { - s.AgentVersion = &v +// SetNextToken sets the NextToken field's value. +func (s *ListIngestionJobsOutput) SetNextToken(v string) *ListIngestionJobsOutput { + s.NextToken = &v return s } -type DeleteDataSourceInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type ListKnowledgeBasesInput struct { + _ struct{} `type:"structure"` - // The unique identifier of the data source to delete. - // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + // 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. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - // The unique identifier of the knowledge base from which to delete the data - // source. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7959,7 +18677,7 @@ type DeleteDataSourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDataSourceInput) String() string { +func (s ListKnowledgeBasesInput) String() string { return awsutil.Prettify(s) } @@ -7968,24 +18686,18 @@ func (s DeleteDataSourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDataSourceInput) GoString() string { +func (s ListKnowledgeBasesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteDataSourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteDataSourceInput"} - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) - } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +func (s *ListKnowledgeBasesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListKnowledgeBasesInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7994,36 +18706,30 @@ func (s *DeleteDataSourceInput) Validate() error { return nil } -// SetDataSourceId sets the DataSourceId field's value. -func (s *DeleteDataSourceInput) SetDataSourceId(v string) *DeleteDataSourceInput { - s.DataSourceId = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListKnowledgeBasesInput) SetMaxResults(v int64) *ListKnowledgeBasesInput { + s.MaxResults = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DeleteDataSourceInput) SetKnowledgeBaseId(v string) *DeleteDataSourceInput { - s.KnowledgeBaseId = &v +// SetNextToken sets the NextToken field's value. +func (s *ListKnowledgeBasesInput) SetNextToken(v string) *ListKnowledgeBasesInput { + s.NextToken = &v return s } -type DeleteDataSourceOutput struct { +type ListKnowledgeBasesOutput struct { _ struct{} `type:"structure"` - // The unique identifier of the data source that was deleted. - // - // DataSourceId is a required field - DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - - // The unique identifier of the knowledge base to which the data source that - // was deleted belonged. + // A list of objects, each of which contains information about a knowledge base. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // KnowledgeBaseSummaries is a required field + KnowledgeBaseSummaries []*KnowledgeBaseSummary `locationName:"knowledgeBaseSummaries" type:"list" required:"true"` - // The status of the data source. - // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"DataSourceStatus"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -8031,7 +18737,7 @@ type DeleteDataSourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDataSourceOutput) String() string { +func (s ListKnowledgeBasesOutput) String() string { return awsutil.Prettify(s) } @@ -8040,35 +18746,38 @@ func (s DeleteDataSourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDataSourceOutput) GoString() string { +func (s ListKnowledgeBasesOutput) GoString() string { return s.String() } -// SetDataSourceId sets the DataSourceId field's value. -func (s *DeleteDataSourceOutput) SetDataSourceId(v string) *DeleteDataSourceOutput { - s.DataSourceId = &v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DeleteDataSourceOutput) SetKnowledgeBaseId(v string) *DeleteDataSourceOutput { - s.KnowledgeBaseId = &v +// SetKnowledgeBaseSummaries sets the KnowledgeBaseSummaries field's value. +func (s *ListKnowledgeBasesOutput) SetKnowledgeBaseSummaries(v []*KnowledgeBaseSummary) *ListKnowledgeBasesOutput { + s.KnowledgeBaseSummaries = v return s } -// SetStatus sets the Status field's value. -func (s *DeleteDataSourceOutput) SetStatus(v string) *DeleteDataSourceOutput { - s.Status = &v +// SetNextToken sets the NextToken field's value. +func (s *ListKnowledgeBasesOutput) SetNextToken(v string) *ListKnowledgeBasesOutput { + s.NextToken = &v return s } -type DeleteKnowledgeBaseInput struct { +type ListPromptsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the knowledge base to delete. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // 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. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // 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. + NextToken *string `location:"querystring" locationName:"nextToken" min:"1" type:"string"` + + // The unique identifier of the prompt. + PromptIdentifier *string `location:"querystring" locationName:"promptIdentifier" type:"string"` } // String returns the string representation. @@ -8076,7 +18785,7 @@ type DeleteKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteKnowledgeBaseInput) String() string { +func (s ListPromptsInput) String() string { return awsutil.Prettify(s) } @@ -8085,18 +18794,18 @@ func (s DeleteKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteKnowledgeBaseInput) GoString() string { +func (s ListPromptsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteKnowledgeBaseInput"} - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +func (s *ListPromptsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPromptsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -8105,24 +18814,37 @@ func (s *DeleteKnowledgeBaseInput) Validate() error { return nil } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DeleteKnowledgeBaseInput) SetKnowledgeBaseId(v string) *DeleteKnowledgeBaseInput { - s.KnowledgeBaseId = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListPromptsInput) SetMaxResults(v int64) *ListPromptsInput { + s.MaxResults = &v return s } -type DeleteKnowledgeBaseOutput struct { +// SetNextToken sets the NextToken field's value. +func (s *ListPromptsInput) SetNextToken(v string) *ListPromptsInput { + s.NextToken = &v + return s +} + +// SetPromptIdentifier sets the PromptIdentifier field's value. +func (s *ListPromptsInput) SetPromptIdentifier(v string) *ListPromptsInput { + s.PromptIdentifier = &v + return s +} + +type ListPromptsOutput struct { _ struct{} `type:"structure"` - // The unique identifier of the knowledge base that was deleted. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // 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. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` - // The status of the knowledge base and whether it has been successfully deleted. + // A list, each member of which contains information about a prompt using Prompt + // management. // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` + // PromptSummaries is a required field + PromptSummaries []*PromptSummary `locationName:"promptSummaries" type:"list" required:"true"` } // String returns the string representation. @@ -8130,7 +18852,7 @@ type DeleteKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteKnowledgeBaseOutput) String() string { +func (s ListPromptsOutput) String() string { return awsutil.Prettify(s) } @@ -8139,40 +18861,29 @@ func (s DeleteKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteKnowledgeBaseOutput) GoString() string { +func (s ListPromptsOutput) GoString() string { return s.String() } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DeleteKnowledgeBaseOutput) SetKnowledgeBaseId(v string) *DeleteKnowledgeBaseOutput { - s.KnowledgeBaseId = &v +// SetNextToken sets the NextToken field's value. +func (s *ListPromptsOutput) SetNextToken(v string) *ListPromptsOutput { + s.NextToken = &v return s } -// SetStatus sets the Status field's value. -func (s *DeleteKnowledgeBaseOutput) SetStatus(v string) *DeleteKnowledgeBaseOutput { - s.Status = &v +// SetPromptSummaries sets the PromptSummaries field's value. +func (s *ListPromptsOutput) SetPromptSummaries(v []*PromptSummary) *ListPromptsOutput { + s.PromptSummaries = v return s } -type DisassociateAgentKnowledgeBaseInput struct { +type ListTagsForResourceInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The unique identifier of the agent from which to disassociate the knowledge - // base. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - - // The version of the agent from which to disassociate the knowledge base. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` - - // The unique identifier of the knowledge base to disassociate. + // The Amazon Resource Name (ARN) of the resource for which to list tags. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` } // String returns the string representation. @@ -8180,7 +18891,7 @@ type DisassociateAgentKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateAgentKnowledgeBaseInput) String() string { +func (s ListTagsForResourceInput) String() string { return awsutil.Prettify(s) } @@ -8189,30 +18900,18 @@ func (s DisassociateAgentKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateAgentKnowledgeBaseInput) GoString() string { +func (s ListTagsForResourceInput) GoString() string { return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DisassociateAgentKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisassociateAgentKnowledgeBaseInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) - } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListTagsForResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) } if invalidParams.Len() > 0 { @@ -8221,26 +18920,17 @@ func (s *DisassociateAgentKnowledgeBaseInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *DisassociateAgentKnowledgeBaseInput) SetAgentId(v string) *DisassociateAgentKnowledgeBaseInput { - s.AgentId = &v - return s -} - -// SetAgentVersion sets the AgentVersion field's value. -func (s *DisassociateAgentKnowledgeBaseInput) SetAgentVersion(v string) *DisassociateAgentKnowledgeBaseInput { - s.AgentVersion = &v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *DisassociateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *DisassociateAgentKnowledgeBaseInput { - s.KnowledgeBaseId = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { + s.ResourceArn = &v return s } -type DisassociateAgentKnowledgeBaseOutput struct { +type ListTagsForResourceOutput struct { _ struct{} `type:"structure"` + + // The key-value pairs for the tags associated with the resource. + Tags map[string]*string `locationName:"tags" type:"map"` } // String returns the string representation. @@ -8248,7 +18938,7 @@ type DisassociateAgentKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateAgentKnowledgeBaseOutput) String() string { +func (s ListTagsForResourceOutput) String() string { return awsutil.Prettify(s) } @@ -8257,16 +18947,27 @@ func (s DisassociateAgentKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateAgentKnowledgeBaseOutput) GoString() string { +func (s ListTagsForResourceOutput) GoString() string { return s.String() } -// The configuration details for the embeddings model. -type EmbeddingModelConfiguration struct { +// SetTags sets the Tags field's value. +func (s *ListTagsForResourceOutput) SetTags(v map[string]*string) *ListTagsForResourceOutput { + s.Tags = v + return s +} + +// Details of the memory configuration. +type MemoryConfiguration struct { _ struct{} `type:"structure"` - // The vector configuration details on the Bedrock embeddings model. - BedrockEmbeddingModelConfiguration *BedrockEmbeddingModelConfiguration `locationName:"bedrockEmbeddingModelConfiguration" type:"structure"` + // The type of memory that is stored. + // + // EnabledMemoryTypes is a required field + EnabledMemoryTypes []*string `locationName:"enabledMemoryTypes" min:"1" type:"list" required:"true" enum:"MemoryType"` + + // The number of days the agent is configured to retain the conversational context. + StorageDays *int64 `locationName:"storageDays" type:"integer"` } // String returns the string representation. @@ -8274,7 +18975,7 @@ type EmbeddingModelConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s EmbeddingModelConfiguration) String() string { +func (s MemoryConfiguration) String() string { return awsutil.Prettify(s) } @@ -8283,30 +18984,78 @@ func (s EmbeddingModelConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s EmbeddingModelConfiguration) GoString() string { +func (s MemoryConfiguration) GoString() string { return s.String() } -// SetBedrockEmbeddingModelConfiguration sets the BedrockEmbeddingModelConfiguration field's value. -func (s *EmbeddingModelConfiguration) SetBedrockEmbeddingModelConfiguration(v *BedrockEmbeddingModelConfiguration) *EmbeddingModelConfiguration { - s.BedrockEmbeddingModelConfiguration = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *MemoryConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MemoryConfiguration"} + if s.EnabledMemoryTypes == nil { + invalidParams.Add(request.NewErrParamRequired("EnabledMemoryTypes")) + } + if s.EnabledMemoryTypes != nil && len(s.EnabledMemoryTypes) < 1 { + invalidParams.Add(request.NewErrParamMinLen("EnabledMemoryTypes", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetEnabledMemoryTypes sets the EnabledMemoryTypes field's value. +func (s *MemoryConfiguration) SetEnabledMemoryTypes(v []*string) *MemoryConfiguration { + s.EnabledMemoryTypes = v return s } -// Configurations for when you choose fixed-size chunking. If you set the chunkingStrategy -// as NONE, exclude this field. -type FixedSizeChunkingConfiguration struct { +// SetStorageDays sets the StorageDays field's value. +func (s *MemoryConfiguration) SetStorageDays(v int64) *MemoryConfiguration { + s.StorageDays = &v + return s +} + +// Contains details about the storage configuration of the knowledge base in +// MongoDB Atlas. +type MongoDbAtlasConfiguration struct { _ struct{} `type:"structure"` - // The maximum number of tokens to include in a chunk. + // The collection name of the knowledge base in MongoDB Atlas. // - // MaxTokens is a required field - MaxTokens *int64 `locationName:"maxTokens" min:"1" type:"integer" required:"true"` + // CollectionName is a required field + CollectionName *string `locationName:"collectionName" type:"string" required:"true"` - // The percentage of overlap between adjacent chunks of a data source. + // The Amazon Resource Name (ARN) of the secret that you created in Secrets + // Manager that contains user credentials for your MongoDB Atlas cluster. // - // OverlapPercentage is a required field - OverlapPercentage *int64 `locationName:"overlapPercentage" min:"1" type:"integer" required:"true"` + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` + + // The database name in your MongoDB Atlas cluster for your knowledge base. + // + // DatabaseName is a required field + DatabaseName *string `locationName:"databaseName" type:"string" required:"true"` + + // The endpoint URL of your MongoDB Atlas cluster for your knowledge base. + // + // Endpoint is a required field + Endpoint *string `locationName:"endpoint" type:"string" required:"true"` + + // The name of the VPC endpoint service in your account that is connected to + // your MongoDB Atlas cluster. + EndpointServiceName *string `locationName:"endpointServiceName" min:"1" type:"string"` + + // Contains the names of the fields to which to map information about the vector + // store. + // + // FieldMapping is a required field + FieldMapping *MongoDbAtlasFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + + // The name of the MongoDB Atlas vector search index. + // + // VectorIndexName is a required field + VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` } // String returns the string representation. @@ -8314,7 +19063,7 @@ type FixedSizeChunkingConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FixedSizeChunkingConfiguration) String() string { +func (s MongoDbAtlasConfiguration) String() string { return awsutil.Prettify(s) } @@ -8323,24 +19072,38 @@ func (s FixedSizeChunkingConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FixedSizeChunkingConfiguration) GoString() string { +func (s MongoDbAtlasConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *FixedSizeChunkingConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "FixedSizeChunkingConfiguration"} - if s.MaxTokens == nil { - invalidParams.Add(request.NewErrParamRequired("MaxTokens")) +func (s *MongoDbAtlasConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MongoDbAtlasConfiguration"} + if s.CollectionName == nil { + invalidParams.Add(request.NewErrParamRequired("CollectionName")) } - if s.MaxTokens != nil && *s.MaxTokens < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxTokens", 1)) + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) } - if s.OverlapPercentage == nil { - invalidParams.Add(request.NewErrParamRequired("OverlapPercentage")) + if s.DatabaseName == nil { + invalidParams.Add(request.NewErrParamRequired("DatabaseName")) } - if s.OverlapPercentage != nil && *s.OverlapPercentage < 1 { - invalidParams.Add(request.NewErrParamMinValue("OverlapPercentage", 1)) + if s.Endpoint == nil { + invalidParams.Add(request.NewErrParamRequired("Endpoint")) + } + if s.EndpointServiceName != nil && len(*s.EndpointServiceName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("EndpointServiceName", 1)) + } + if s.FieldMapping == nil { + invalidParams.Add(request.NewErrParamRequired("FieldMapping")) + } + if s.VectorIndexName == nil { + invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) + } + if s.FieldMapping != nil { + if err := s.FieldMapping.Validate(); err != nil { + invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -8349,45 +19112,70 @@ func (s *FixedSizeChunkingConfiguration) Validate() error { return nil } -// SetMaxTokens sets the MaxTokens field's value. -func (s *FixedSizeChunkingConfiguration) SetMaxTokens(v int64) *FixedSizeChunkingConfiguration { - s.MaxTokens = &v +// SetCollectionName sets the CollectionName field's value. +func (s *MongoDbAtlasConfiguration) SetCollectionName(v string) *MongoDbAtlasConfiguration { + s.CollectionName = &v return s } -// SetOverlapPercentage sets the OverlapPercentage field's value. -func (s *FixedSizeChunkingConfiguration) SetOverlapPercentage(v int64) *FixedSizeChunkingConfiguration { - s.OverlapPercentage = &v +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *MongoDbAtlasConfiguration) SetCredentialsSecretArn(v string) *MongoDbAtlasConfiguration { + s.CredentialsSecretArn = &v return s } -// 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: -// -// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) -// -// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) -// -// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) -// -// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) -// -// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) -type Function struct { +// SetDatabaseName sets the DatabaseName field's value. +func (s *MongoDbAtlasConfiguration) SetDatabaseName(v string) *MongoDbAtlasConfiguration { + s.DatabaseName = &v + return s +} + +// SetEndpoint sets the Endpoint field's value. +func (s *MongoDbAtlasConfiguration) SetEndpoint(v string) *MongoDbAtlasConfiguration { + s.Endpoint = &v + return s +} + +// SetEndpointServiceName sets the EndpointServiceName field's value. +func (s *MongoDbAtlasConfiguration) SetEndpointServiceName(v string) *MongoDbAtlasConfiguration { + s.EndpointServiceName = &v + return s +} + +// SetFieldMapping sets the FieldMapping field's value. +func (s *MongoDbAtlasConfiguration) SetFieldMapping(v *MongoDbAtlasFieldMapping) *MongoDbAtlasConfiguration { + s.FieldMapping = v + return s +} + +// SetVectorIndexName sets the VectorIndexName field's value. +func (s *MongoDbAtlasConfiguration) SetVectorIndexName(v string) *MongoDbAtlasConfiguration { + s.VectorIndexName = &v + return s +} + +// Contains the names of the fields to which to map information about the vector +// store. +type MongoDbAtlasFieldMapping struct { _ struct{} `type:"structure"` - // A description of the function and its purpose. - Description *string `locationName:"description" min:"1" type:"string"` + // The name of the field in which Amazon Bedrock stores metadata about the vector + // store. + // + // MetadataField is a required field + MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - // A name for the function. + // 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. // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` + // TextField is a required field + TextField *string `locationName:"textField" type:"string" required:"true"` - // The parameters that the agent elicits from the user to fulfill the function. - Parameters map[string]*ParameterDetail `locationName:"parameters" type:"map"` + // The name of the field in which Amazon Bedrock stores the vector embeddings + // for your data sources. + // + // VectorField is a required field + VectorField *string `locationName:"vectorField" type:"string" required:"true"` } // String returns the string representation. @@ -8395,7 +19183,7 @@ type Function struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Function) String() string { +func (s MongoDbAtlasFieldMapping) String() string { return awsutil.Prettify(s) } @@ -8404,28 +19192,21 @@ func (s Function) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Function) GoString() string { +func (s MongoDbAtlasFieldMapping) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *Function) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Function"} - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.Name == nil { - invalidParams.Add(request.NewErrParamRequired("Name")) +func (s *MongoDbAtlasFieldMapping) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MongoDbAtlasFieldMapping"} + if s.MetadataField == nil { + invalidParams.Add(request.NewErrParamRequired("MetadataField")) } - if s.Parameters != nil { - for i, v := range s.Parameters { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Parameters", i), err.(request.ErrInvalidParams)) - } - } + if s.TextField == nil { + invalidParams.Add(request.NewErrParamRequired("TextField")) + } + if s.VectorField == nil { + invalidParams.Add(request.NewErrParamRequired("VectorField")) } if invalidParams.Len() > 0 { @@ -8434,43 +19215,45 @@ func (s *Function) Validate() error { return nil } -// SetDescription sets the Description field's value. -func (s *Function) SetDescription(v string) *Function { - s.Description = &v +// SetMetadataField sets the MetadataField field's value. +func (s *MongoDbAtlasFieldMapping) SetMetadataField(v string) *MongoDbAtlasFieldMapping { + s.MetadataField = &v return s } -// SetName sets the Name field's value. -func (s *Function) SetName(v string) *Function { - s.Name = &v +// SetTextField sets the TextField field's value. +func (s *MongoDbAtlasFieldMapping) SetTextField(v string) *MongoDbAtlasFieldMapping { + s.TextField = &v return s } -// SetParameters sets the Parameters field's value. -func (s *Function) SetParameters(v map[string]*ParameterDetail) *Function { - s.Parameters = v +// SetVectorField sets the VectorField field's value. +func (s *MongoDbAtlasFieldMapping) SetVectorField(v string) *MongoDbAtlasFieldMapping { + s.VectorField = &v return s } -// 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: -// -// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) -// -// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) -// -// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) -// -// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) -// -// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) -type FunctionSchema struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). +type OpenSearchServerlessConfiguration struct { _ struct{} `type:"structure"` - // A list of functions that each define an action in the action group. - Functions []*Function `locationName:"functions" type:"list"` + // The Amazon Resource Name (ARN) of the OpenSearch Service vector store. + // + // CollectionArn is a required field + CollectionArn *string `locationName:"collectionArn" type:"string" required:"true"` + + // Contains the names of the fields to which to map information about the vector + // store. + // + // FieldMapping is a required field + FieldMapping *OpenSearchServerlessFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + + // The name of the vector store. + // + // VectorIndexName is a required field + VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` } // String returns the string representation. @@ -8478,7 +19261,7 @@ type FunctionSchema struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FunctionSchema) String() string { +func (s OpenSearchServerlessConfiguration) String() string { return awsutil.Prettify(s) } @@ -8487,21 +19270,25 @@ func (s FunctionSchema) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FunctionSchema) GoString() string { +func (s OpenSearchServerlessConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *FunctionSchema) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "FunctionSchema"} - if s.Functions != nil { - for i, v := range s.Functions { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Functions", i), err.(request.ErrInvalidParams)) - } +func (s *OpenSearchServerlessConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OpenSearchServerlessConfiguration"} + if s.CollectionArn == nil { + invalidParams.Add(request.NewErrParamRequired("CollectionArn")) + } + if s.FieldMapping == nil { + invalidParams.Add(request.NewErrParamRequired("FieldMapping")) + } + if s.VectorIndexName == nil { + invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) + } + if s.FieldMapping != nil { + if err := s.FieldMapping.Validate(); err != nil { + invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) } } @@ -8511,29 +19298,46 @@ func (s *FunctionSchema) Validate() error { return nil } -// SetFunctions sets the Functions field's value. -func (s *FunctionSchema) SetFunctions(v []*Function) *FunctionSchema { - s.Functions = v +// SetCollectionArn sets the CollectionArn field's value. +func (s *OpenSearchServerlessConfiguration) SetCollectionArn(v string) *OpenSearchServerlessConfiguration { + s.CollectionArn = &v return s } -type GetAgentActionGroupInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// SetFieldMapping sets the FieldMapping field's value. +func (s *OpenSearchServerlessConfiguration) SetFieldMapping(v *OpenSearchServerlessFieldMapping) *OpenSearchServerlessConfiguration { + s.FieldMapping = v + return s +} - // The unique identifier of the action group for which to get information. +// SetVectorIndexName sets the VectorIndexName field's value. +func (s *OpenSearchServerlessConfiguration) SetVectorIndexName(v string) *OpenSearchServerlessConfiguration { + s.VectorIndexName = &v + return s +} + +// Contains the names of the fields to which to map information about the vector +// store. +type OpenSearchServerlessFieldMapping struct { + _ struct{} `type:"structure"` + + // The name of the field in which Amazon Bedrock stores metadata about the vector + // store. // - // ActionGroupId is a required field - ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` + // MetadataField is a required field + MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - // The unique identifier of the agent that the action group belongs to. + // 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. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // TextField is a required field + TextField *string `locationName:"textField" type:"string" required:"true"` - // The version of the agent that the action group belongs to. + // The name of the field in which Amazon Bedrock stores the vector embeddings + // for your data sources. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` + // VectorField is a required field + VectorField *string `locationName:"vectorField" type:"string" required:"true"` } // String returns the string representation. @@ -8541,7 +19345,7 @@ type GetAgentActionGroupInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentActionGroupInput) String() string { +func (s OpenSearchServerlessFieldMapping) String() string { return awsutil.Prettify(s) } @@ -8550,30 +19354,21 @@ func (s GetAgentActionGroupInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentActionGroupInput) GoString() string { +func (s OpenSearchServerlessFieldMapping) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAgentActionGroupInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAgentActionGroupInput"} - if s.ActionGroupId == nil { - invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) - } - if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) - } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) +func (s *OpenSearchServerlessFieldMapping) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OpenSearchServerlessFieldMapping"} + if s.MetadataField == nil { + invalidParams.Add(request.NewErrParamRequired("MetadataField")) } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + if s.TextField == nil { + invalidParams.Add(request.NewErrParamRequired("TextField")) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + if s.VectorField == nil { + invalidParams.Add(request.NewErrParamRequired("VectorField")) } if invalidParams.Len() > 0 { @@ -8582,31 +19377,29 @@ func (s *GetAgentActionGroupInput) Validate() error { return nil } -// SetActionGroupId sets the ActionGroupId field's value. -func (s *GetAgentActionGroupInput) SetActionGroupId(v string) *GetAgentActionGroupInput { - s.ActionGroupId = &v +// SetMetadataField sets the MetadataField field's value. +func (s *OpenSearchServerlessFieldMapping) SetMetadataField(v string) *OpenSearchServerlessFieldMapping { + s.MetadataField = &v return s } -// SetAgentId sets the AgentId field's value. -func (s *GetAgentActionGroupInput) SetAgentId(v string) *GetAgentActionGroupInput { - s.AgentId = &v +// SetTextField sets the TextField field's value. +func (s *OpenSearchServerlessFieldMapping) SetTextField(v string) *OpenSearchServerlessFieldMapping { + s.TextField = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *GetAgentActionGroupInput) SetAgentVersion(v string) *GetAgentActionGroupInput { - s.AgentVersion = &v +// SetVectorField sets the VectorField field's value. +func (s *OpenSearchServerlessFieldMapping) SetVectorField(v string) *OpenSearchServerlessFieldMapping { + s.VectorField = &v return s } -type GetAgentActionGroupOutput struct { +// 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. +type OutputFlowNodeConfiguration struct { _ struct{} `type:"structure"` - - // Contains details about the action group. - // - // AgentActionGroup is a required field - AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` } // String returns the string representation. @@ -8614,7 +19407,7 @@ type GetAgentActionGroupOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentActionGroupOutput) String() string { +func (s OutputFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -8623,29 +19416,38 @@ func (s GetAgentActionGroupOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentActionGroupOutput) GoString() string { +func (s OutputFlowNodeConfiguration) GoString() string { return s.String() } -// SetAgentActionGroup sets the AgentActionGroup field's value. -func (s *GetAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *GetAgentActionGroupOutput { - s.AgentActionGroup = v - return s -} +// Contains details about a parameter in a function for an action group. +// +// This data type is used in the following API operations: +// +// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) +// +// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) +// +// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) +// +// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) +// +// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) +type ParameterDetail struct { + _ struct{} `type:"structure"` -type GetAgentAliasInput struct { - _ struct{} `type:"structure" nopayload:"true"` + // A description of the parameter. Helps the foundation model determine how + // to elicit the parameters from the user. + Description *string `locationName:"description" min:"1" type:"string"` - // The unique identifier of the alias for which to get information. - // - // AgentAliasId is a required field - AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` + // Whether the parameter is required for the agent to complete the function + // for action group invocation. + Required *bool `locationName:"required" type:"boolean"` - // The unique identifier of the agent to which the alias to get information - // belongs. + // The data type of the parameter. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"Type"` } // String returns the string representation. @@ -8653,7 +19455,7 @@ type GetAgentAliasInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentAliasInput) String() string { +func (s ParameterDetail) String() string { return awsutil.Prettify(s) } @@ -8662,24 +19464,18 @@ func (s GetAgentAliasInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentAliasInput) GoString() string { +func (s ParameterDetail) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAgentAliasInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAgentAliasInput"} - if s.AgentAliasId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) - } - if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { - invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) - } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *ParameterDetail) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ParameterDetail"} + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) } if invalidParams.Len() > 0 { @@ -8688,25 +19484,51 @@ func (s *GetAgentAliasInput) Validate() error { return nil } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *GetAgentAliasInput) SetAgentAliasId(v string) *GetAgentAliasInput { - s.AgentAliasId = &v +// SetDescription sets the Description field's value. +func (s *ParameterDetail) SetDescription(v string) *ParameterDetail { + s.Description = &v + return s +} + +// SetRequired sets the Required field's value. +func (s *ParameterDetail) SetRequired(v bool) *ParameterDetail { + s.Required = &v return s } -// SetAgentId sets the AgentId field's value. -func (s *GetAgentAliasInput) SetAgentId(v string) *GetAgentAliasInput { - s.AgentId = &v +// SetType sets the Type field's value. +func (s *ParameterDetail) SetType(v string) *ParameterDetail { + s.Type = &v return s } -type GetAgentAliasOutput struct { +// 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. +type ParsingConfiguration struct { _ struct{} `type:"structure"` - // Contains information about the alias. + // Settings for a foundation model used to parse documents for a data source. + BedrockFoundationModelConfiguration *BedrockFoundationModelConfiguration `locationName:"bedrockFoundationModelConfiguration" type:"structure"` + + // The parsing strategy for the data source. // - // AgentAlias is a required field - AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` + // ParsingStrategy is a required field + ParsingStrategy *string `locationName:"parsingStrategy" type:"string" required:"true" enum:"ParsingStrategy"` } // String returns the string representation. @@ -8714,7 +19536,7 @@ type GetAgentAliasOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentAliasOutput) String() string { +func (s ParsingConfiguration) String() string { return awsutil.Prettify(s) } @@ -8723,23 +19545,48 @@ func (s GetAgentAliasOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentAliasOutput) GoString() string { +func (s ParsingConfiguration) GoString() string { return s.String() } -// SetAgentAlias sets the AgentAlias field's value. -func (s *GetAgentAliasOutput) SetAgentAlias(v *AgentAlias) *GetAgentAliasOutput { - s.AgentAlias = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *ParsingConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ParsingConfiguration"} + if s.ParsingStrategy == nil { + invalidParams.Add(request.NewErrParamRequired("ParsingStrategy")) + } + if s.BedrockFoundationModelConfiguration != nil { + if err := s.BedrockFoundationModelConfiguration.Validate(); err != nil { + invalidParams.AddNested("BedrockFoundationModelConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBedrockFoundationModelConfiguration sets the BedrockFoundationModelConfiguration field's value. +func (s *ParsingConfiguration) SetBedrockFoundationModelConfiguration(v *BedrockFoundationModelConfiguration) *ParsingConfiguration { + s.BedrockFoundationModelConfiguration = v return s } -type GetAgentInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// SetParsingStrategy sets the ParsingStrategy field's value. +func (s *ParsingConfiguration) SetParsingStrategy(v string) *ParsingConfiguration { + s.ParsingStrategy = &v + return s +} - // The unique identifier of the agent. +// Instructions for interpreting the contents of a document. +type ParsingPrompt struct { + _ struct{} `type:"structure"` + + // Instructions for interpreting the contents of a document. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // ParsingPromptText is a required field + ParsingPromptText *string `locationName:"parsingPromptText" min:"1" type:"string" required:"true"` } // String returns the string representation. @@ -8747,7 +19594,7 @@ type GetAgentInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentInput) String() string { +func (s ParsingPrompt) String() string { return awsutil.Prettify(s) } @@ -8756,18 +19603,18 @@ func (s GetAgentInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentInput) GoString() string { +func (s ParsingPrompt) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAgentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAgentInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *ParsingPrompt) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ParsingPrompt"} + if s.ParsingPromptText == nil { + invalidParams.Add(request.NewErrParamRequired("ParsingPromptText")) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.ParsingPromptText != nil && len(*s.ParsingPromptText) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ParsingPromptText", 1)) } if invalidParams.Len() > 0 { @@ -8776,29 +19623,45 @@ func (s *GetAgentInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *GetAgentInput) SetAgentId(v string) *GetAgentInput { - s.AgentId = &v +// SetParsingPromptText sets the ParsingPromptText field's value. +func (s *ParsingPrompt) SetParsingPromptText(v string) *ParsingPrompt { + s.ParsingPromptText = &v return s } -type GetAgentKnowledgeBaseInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// The specific filters applied to your data source content. You can filter +// out or include certain content. +type PatternObjectFilter struct { + _ struct{} `type:"structure"` - // The unique identifier of the agent with which the knowledge base is associated. + // 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. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // ExclusionFilters is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PatternObjectFilter's + // String and GoString methods. + ExclusionFilters []*string `locationName:"exclusionFilters" min:"1" type:"list" sensitive:"true"` - // The version of the agent with which the knowledge base is associated. + // 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. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` + // InclusionFilters is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PatternObjectFilter's + // String and GoString methods. + InclusionFilters []*string `locationName:"inclusionFilters" min:"1" type:"list" sensitive:"true"` - // The unique identifier of the knowledge base associated with the agent. + // The supported object type or content type of the data source. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // ObjectType is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PatternObjectFilter's + // String and GoString methods. + // + // ObjectType is a required field + ObjectType *string `locationName:"objectType" min:"1" type:"string" required:"true" sensitive:"true"` } // String returns the string representation. @@ -8806,7 +19669,7 @@ type GetAgentKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentKnowledgeBaseInput) String() string { +func (s PatternObjectFilter) String() string { return awsutil.Prettify(s) } @@ -8815,30 +19678,24 @@ func (s GetAgentKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentKnowledgeBaseInput) GoString() string { +func (s PatternObjectFilter) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAgentKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAgentKnowledgeBaseInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) +func (s *PatternObjectFilter) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PatternObjectFilter"} + if s.ExclusionFilters != nil && len(s.ExclusionFilters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ExclusionFilters", 1)) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + if s.InclusionFilters != nil && len(s.InclusionFilters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("InclusionFilters", 1)) } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + if s.ObjectType == nil { + invalidParams.Add(request.NewErrParamRequired("ObjectType")) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.ObjectType != nil && len(*s.ObjectType) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ObjectType", 1)) } if invalidParams.Len() > 0 { @@ -8847,31 +19704,38 @@ func (s *GetAgentKnowledgeBaseInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *GetAgentKnowledgeBaseInput) SetAgentId(v string) *GetAgentKnowledgeBaseInput { - s.AgentId = &v +// SetExclusionFilters sets the ExclusionFilters field's value. +func (s *PatternObjectFilter) SetExclusionFilters(v []*string) *PatternObjectFilter { + s.ExclusionFilters = v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *GetAgentKnowledgeBaseInput) SetAgentVersion(v string) *GetAgentKnowledgeBaseInput { - s.AgentVersion = &v +// SetInclusionFilters sets the InclusionFilters field's value. +func (s *PatternObjectFilter) SetInclusionFilters(v []*string) *PatternObjectFilter { + s.InclusionFilters = v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *GetAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *GetAgentKnowledgeBaseInput { - s.KnowledgeBaseId = &v +// SetObjectType sets the ObjectType field's value. +func (s *PatternObjectFilter) SetObjectType(v string) *PatternObjectFilter { + s.ObjectType = &v return s } -type GetAgentKnowledgeBaseOutput struct { +// The configuration of filtering certain objects or content types of the data +// source. +type PatternObjectFilterConfiguration struct { _ struct{} `type:"structure"` - // Contains details about a knowledge base attached to an agent. + // The configuration of specific filters applied to your data source content. + // You can filter out or include certain content. // - // AgentKnowledgeBase is a required field - AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` + // Filters is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PatternObjectFilterConfiguration's + // String and GoString methods. + // + // Filters is a required field + Filters []*PatternObjectFilter `locationName:"filters" min:"1" type:"list" required:"true" sensitive:"true"` } // String returns the string representation. @@ -8879,7 +19743,7 @@ type GetAgentKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentKnowledgeBaseOutput) String() string { +func (s PatternObjectFilterConfiguration) String() string { return awsutil.Prettify(s) } @@ -8888,61 +19752,66 @@ func (s GetAgentKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentKnowledgeBaseOutput) GoString() string { +func (s PatternObjectFilterConfiguration) GoString() string { return s.String() } -// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. -func (s *GetAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *GetAgentKnowledgeBaseOutput { - s.AgentKnowledgeBase = v - return s -} - -type GetAgentOutput struct { - _ struct{} `type:"structure"` - - // Contains details about the agent. - // - // Agent is a required field - Agent *Agent `locationName:"agent" type:"structure" required:"true"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetAgentOutput) String() string { - return awsutil.Prettify(s) -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *PatternObjectFilterConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PatternObjectFilterConfiguration"} + if s.Filters == nil { + invalidParams.Add(request.NewErrParamRequired("Filters")) + } + if s.Filters != nil && len(s.Filters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Filters", 1)) + } + if s.Filters != nil { + for i, v := range s.Filters { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) + } + } + } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetAgentOutput) GoString() string { - return s.String() + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetAgent sets the Agent field's value. -func (s *GetAgentOutput) SetAgent(v *Agent) *GetAgentOutput { - s.Agent = v +// SetFilters sets the Filters field's value. +func (s *PatternObjectFilterConfiguration) SetFilters(v []*PatternObjectFilter) *PatternObjectFilterConfiguration { + s.Filters = v return s } -type GetAgentVersionInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// Contains details about the storage configuration of the knowledge base in +// Pinecone. For more information, see Create a vector index in Pinecone (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-pinecone.html). +type PineconeConfiguration struct { + _ struct{} `type:"structure"` - // The unique identifier of the agent. + // The endpoint URL for your index management page. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // ConnectionString is a required field + ConnectionString *string `locationName:"connectionString" type:"string" required:"true"` - // The version of the agent. + // The Amazon Resource Name (ARN) of the secret that you created in Secrets + // Manager that is linked to your Pinecone API key. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" type:"string" required:"true"` + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` + + // Contains the names of the fields to which to map information about the vector + // store. + // + // FieldMapping is a required field + FieldMapping *PineconeFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + + // The namespace to be used to write new data to your database. + Namespace *string `locationName:"namespace" type:"string"` } // String returns the string representation. @@ -8950,7 +19819,7 @@ type GetAgentVersionInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentVersionInput) String() string { +func (s PineconeConfiguration) String() string { return awsutil.Prettify(s) } @@ -8959,24 +19828,26 @@ func (s GetAgentVersionInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAgentVersionInput) GoString() string { +func (s PineconeConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAgentVersionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAgentVersionInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *PineconeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PineconeConfiguration"} + if s.ConnectionString == nil { + invalidParams.Add(request.NewErrParamRequired("ConnectionString")) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + if s.FieldMapping == nil { + invalidParams.Add(request.NewErrParamRequired("FieldMapping")) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + if s.FieldMapping != nil { + if err := s.FieldMapping.Validate(); err != nil { + invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -8985,64 +19856,46 @@ func (s *GetAgentVersionInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *GetAgentVersionInput) SetAgentId(v string) *GetAgentVersionInput { - s.AgentId = &v +// SetConnectionString sets the ConnectionString field's value. +func (s *PineconeConfiguration) SetConnectionString(v string) *PineconeConfiguration { + s.ConnectionString = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *GetAgentVersionInput) SetAgentVersion(v string) *GetAgentVersionInput { - s.AgentVersion = &v +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *PineconeConfiguration) SetCredentialsSecretArn(v string) *PineconeConfiguration { + s.CredentialsSecretArn = &v return s } -type GetAgentVersionOutput struct { - _ struct{} `type:"structure"` - - // Contains details about the version of the agent. - // - // AgentVersion is a required field - AgentVersion *AgentVersion `locationName:"agentVersion" type:"structure" required:"true"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetAgentVersionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetAgentVersionOutput) GoString() string { - return s.String() +// SetFieldMapping sets the FieldMapping field's value. +func (s *PineconeConfiguration) SetFieldMapping(v *PineconeFieldMapping) *PineconeConfiguration { + s.FieldMapping = v + return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *GetAgentVersionOutput) SetAgentVersion(v *AgentVersion) *GetAgentVersionOutput { - s.AgentVersion = v +// SetNamespace sets the Namespace field's value. +func (s *PineconeConfiguration) SetNamespace(v string) *PineconeConfiguration { + s.Namespace = &v return s } -type GetDataSourceInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// Contains the names of the fields to which to map information about the vector +// store. +type PineconeFieldMapping struct { + _ struct{} `type:"structure"` - // The unique identifier of the data source. + // The name of the field in which Amazon Bedrock stores metadata about the vector + // store. // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + // MetadataField is a required field + MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - // The unique identifier of the knowledge base that the data source was added - // to. + // 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. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // TextField is a required field + TextField *string `locationName:"textField" type:"string" required:"true"` } // String returns the string representation. @@ -9050,7 +19903,7 @@ type GetDataSourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDataSourceInput) String() string { +func (s PineconeFieldMapping) String() string { return awsutil.Prettify(s) } @@ -9059,24 +19912,18 @@ func (s GetDataSourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDataSourceInput) GoString() string { +func (s PineconeFieldMapping) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetDataSourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetDataSourceInput"} - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) - } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) +func (s *PineconeFieldMapping) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PineconeFieldMapping"} + if s.MetadataField == nil { + invalidParams.Add(request.NewErrParamRequired("MetadataField")) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.TextField == nil { + invalidParams.Add(request.NewErrParamRequired("TextField")) } if invalidParams.Len() > 0 { @@ -9085,25 +19932,25 @@ func (s *GetDataSourceInput) Validate() error { return nil } -// SetDataSourceId sets the DataSourceId field's value. -func (s *GetDataSourceInput) SetDataSourceId(v string) *GetDataSourceInput { - s.DataSourceId = &v +// SetMetadataField sets the MetadataField field's value. +func (s *PineconeFieldMapping) SetMetadataField(v string) *PineconeFieldMapping { + s.MetadataField = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *GetDataSourceInput) SetKnowledgeBaseId(v string) *GetDataSourceInput { - s.KnowledgeBaseId = &v +// SetTextField sets the TextField field's value. +func (s *PineconeFieldMapping) SetTextField(v string) *PineconeFieldMapping { + s.TextField = &v return s } -type GetDataSourceOutput struct { - _ struct{} `type:"structure"` +type PrepareAgentInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // Contains details about the data source. + // The unique identifier of the agent for which to create a DRAFT version. // - // DataSource is a required field - DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` } // String returns the string representation. @@ -9111,7 +19958,7 @@ type GetDataSourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDataSourceOutput) String() string { +func (s PrepareAgentInput) String() string { return awsutil.Prettify(s) } @@ -9120,33 +19967,54 @@ func (s GetDataSourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDataSourceOutput) GoString() string { +func (s PrepareAgentInput) GoString() string { return s.String() } -// SetDataSource sets the DataSource field's value. -func (s *GetDataSourceOutput) SetDataSource(v *DataSource) *GetDataSourceOutput { - s.DataSource = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *PrepareAgentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PrepareAgentInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentId sets the AgentId field's value. +func (s *PrepareAgentInput) SetAgentId(v string) *PrepareAgentInput { + s.AgentId = &v return s } -type GetIngestionJobInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type PrepareAgentOutput struct { + _ struct{} `type:"structure"` - // The unique identifier of the data source in the ingestion job. + // The unique identifier of the agent for which the DRAFT version was created. // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + // AgentId is a required field + AgentId *string `locationName:"agentId" type:"string" required:"true"` - // The unique identifier of the ingestion job. + // The status of the DRAFT version and whether it is ready for use. // - // IngestionJobId is a required field - IngestionJobId *string `location:"uri" locationName:"ingestionJobId" type:"string" required:"true"` + // AgentStatus is a required field + AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` - // The unique identifier of the knowledge base for which the ingestion job applies. + // The version of the agent. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // AgentVersion is a required field + AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` + + // The time at which the DRAFT version of the agent was last prepared. + // + // PreparedAt is a required field + PreparedAt *time.Time `locationName:"preparedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` } // String returns the string representation. @@ -9154,7 +20022,7 @@ type GetIngestionJobInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetIngestionJobInput) String() string { +func (s PrepareAgentOutput) String() string { return awsutil.Prettify(s) } @@ -9163,63 +20031,41 @@ func (s GetIngestionJobInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetIngestionJobInput) GoString() string { +func (s PrepareAgentOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetIngestionJobInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetIngestionJobInput"} - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) - } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) - } - if s.IngestionJobId == nil { - invalidParams.Add(request.NewErrParamRequired("IngestionJobId")) - } - if s.IngestionJobId != nil && len(*s.IngestionJobId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("IngestionJobId", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetAgentId sets the AgentId field's value. +func (s *PrepareAgentOutput) SetAgentId(v string) *PrepareAgentOutput { + s.AgentId = &v + return s } -// SetDataSourceId sets the DataSourceId field's value. -func (s *GetIngestionJobInput) SetDataSourceId(v string) *GetIngestionJobInput { - s.DataSourceId = &v +// SetAgentStatus sets the AgentStatus field's value. +func (s *PrepareAgentOutput) SetAgentStatus(v string) *PrepareAgentOutput { + s.AgentStatus = &v return s } -// SetIngestionJobId sets the IngestionJobId field's value. -func (s *GetIngestionJobInput) SetIngestionJobId(v string) *GetIngestionJobInput { - s.IngestionJobId = &v +// SetAgentVersion sets the AgentVersion field's value. +func (s *PrepareAgentOutput) SetAgentVersion(v string) *PrepareAgentOutput { + s.AgentVersion = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *GetIngestionJobInput) SetKnowledgeBaseId(v string) *GetIngestionJobInput { - s.KnowledgeBaseId = &v +// SetPreparedAt sets the PreparedAt field's value. +func (s *PrepareAgentOutput) SetPreparedAt(v time.Time) *PrepareAgentOutput { + s.PreparedAt = &v return s } -type GetIngestionJobOutput struct { - _ struct{} `type:"structure"` +type PrepareFlowInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // Contains details about the ingestion job. + // The unique identifier of the flow. // - // IngestionJob is a required field - IngestionJob *IngestionJob `locationName:"ingestionJob" type:"structure" required:"true"` + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` } // String returns the string representation. @@ -9227,7 +20073,7 @@ type GetIngestionJobOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetIngestionJobOutput) String() string { +func (s PrepareFlowInput) String() string { return awsutil.Prettify(s) } @@ -9236,23 +20082,46 @@ func (s GetIngestionJobOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetIngestionJobOutput) GoString() string { +func (s PrepareFlowInput) GoString() string { return s.String() } -// SetIngestionJob sets the IngestionJob field's value. -func (s *GetIngestionJobOutput) SetIngestionJob(v *IngestionJob) *GetIngestionJobOutput { - s.IngestionJob = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *PrepareFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PrepareFlowInput"} + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *PrepareFlowInput) SetFlowIdentifier(v string) *PrepareFlowInput { + s.FlowIdentifier = &v return s } -type GetKnowledgeBaseInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type PrepareFlowOutput struct { + _ struct{} `type:"structure"` - // The unique identifier of the knowledge base for which to get information. + // The unique identifier of the flow. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // 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. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` } // String returns the string representation. @@ -9260,7 +20129,7 @@ type GetKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetKnowledgeBaseInput) String() string { +func (s PrepareFlowOutput) String() string { return awsutil.Prettify(s) } @@ -9269,39 +20138,70 @@ func (s GetKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetKnowledgeBaseInput) GoString() string { +func (s PrepareFlowOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetKnowledgeBaseInput"} - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetId sets the Id field's value. +func (s *PrepareFlowOutput) SetId(v string) *PrepareFlowOutput { + s.Id = &v + return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *GetKnowledgeBaseInput) SetKnowledgeBaseId(v string) *GetKnowledgeBaseInput { - s.KnowledgeBaseId = &v +// SetStatus sets the Status field's value. +func (s *PrepareFlowOutput) SetStatus(v string) *PrepareFlowOutput { + s.Status = &v return s } -type GetKnowledgeBaseOutput struct { +// Contains configurations to override a prompt template in one part of an agent +// sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). +type PromptConfiguration struct { _ struct{} `type:"structure"` - // Contains details about the knowledge base. + // 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 + // (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html). + // For more information, see Configure the prompt templates (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts-configure.html). + // + // BasePromptTemplate is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PromptConfiguration's + // String and GoString methods. + BasePromptTemplate *string `locationName:"basePromptTemplate" min:"1" type:"string" sensitive:"true"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html). + InferenceConfiguration *InferenceConfiguration `locationName:"inferenceConfiguration" type:"structure"` + + // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptOverrideConfiguration.html) + // must be specified with the ARN of a Lambda function. + ParserMode *string `locationName:"parserMode" type:"string" enum:"CreationMode"` + + // 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. + PromptCreationMode *string `locationName:"promptCreationMode" type:"string" enum:"CreationMode"` + + // 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. // - // KnowledgeBase is a required field - KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` + // * PRE_PROCESSING – ENABLED + // + // * ORCHESTRATION – ENABLED + // + // * KNOWLEDGE_BASE_RESPONSE_GENERATION – ENABLED + // + // * POST_PROCESSING – DISABLED + PromptState *string `locationName:"promptState" type:"string" enum:"PromptState"` + + // The step in the agent sequence that this prompt configuration applies to. + PromptType *string `locationName:"promptType" type:"string" enum:"PromptType"` } // String returns the string representation. @@ -9309,7 +20209,7 @@ type GetKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetKnowledgeBaseOutput) String() string { +func (s PromptConfiguration) String() string { return awsutil.Prettify(s) } @@ -9318,90 +20218,72 @@ func (s GetKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetKnowledgeBaseOutput) GoString() string { +func (s PromptConfiguration) GoString() string { return s.String() } -// SetKnowledgeBase sets the KnowledgeBase field's value. -func (s *GetKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *GetKnowledgeBaseOutput { - s.KnowledgeBase = v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *PromptConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptConfiguration"} + if s.BasePromptTemplate != nil && len(*s.BasePromptTemplate) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BasePromptTemplate", 1)) + } -// The details of the guardrails configuration. -type GuardrailConfiguration struct { - _ struct{} `type:"structure"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // The guardrails identifier assigned to the guardrails configuration. - GuardrailIdentifier *string `locationName:"guardrailIdentifier" type:"string"` +// SetBasePromptTemplate sets the BasePromptTemplate field's value. +func (s *PromptConfiguration) SetBasePromptTemplate(v string) *PromptConfiguration { + s.BasePromptTemplate = &v + return s +} - // The guardrails version assigned to the guardrails configuration. - GuardrailVersion *string `locationName:"guardrailVersion" type:"string"` +// SetInferenceConfiguration sets the InferenceConfiguration field's value. +func (s *PromptConfiguration) SetInferenceConfiguration(v *InferenceConfiguration) *PromptConfiguration { + s.InferenceConfiguration = v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GuardrailConfiguration) String() string { - return awsutil.Prettify(s) +// SetParserMode sets the ParserMode field's value. +func (s *PromptConfiguration) SetParserMode(v string) *PromptConfiguration { + s.ParserMode = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GuardrailConfiguration) GoString() string { - return s.String() +// SetPromptCreationMode sets the PromptCreationMode field's value. +func (s *PromptConfiguration) SetPromptCreationMode(v string) *PromptConfiguration { + s.PromptCreationMode = &v + return s } -// SetGuardrailIdentifier sets the GuardrailIdentifier field's value. -func (s *GuardrailConfiguration) SetGuardrailIdentifier(v string) *GuardrailConfiguration { - s.GuardrailIdentifier = &v +// SetPromptState sets the PromptState field's value. +func (s *PromptConfiguration) SetPromptState(v string) *PromptConfiguration { + s.PromptState = &v return s } -// SetGuardrailVersion sets the GuardrailVersion field's value. -func (s *GuardrailConfiguration) SetGuardrailVersion(v string) *GuardrailConfiguration { - s.GuardrailVersion = &v +// SetPromptType sets the PromptType field's value. +func (s *PromptConfiguration) SetPromptType(v string) *PromptConfiguration { + s.PromptType = &v return s } -// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html). -type InferenceConfiguration struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-nodes.html) +// in the Amazon Bedrock User Guide. +type PromptFlowNodeConfiguration struct { _ struct{} `type:"structure"` - // The maximum number of tokens to allow in the generated response. - MaximumLength *int64 `locationName:"maximumLength" type:"integer"` - - // A list of stop sequences. A stop sequence is a sequence of characters that - // causes the model to stop generating the response. - StopSequences []*string `locationName:"stopSequences" type:"list"` - - // 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. - Temperature *float64 `locationName:"temperature" 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 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. - TopK *int64 `locationName:"topK" type:"integer"` - - // 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. - TopP *float64 `locationName:"topP" type:"float"` + // Specifies whether the prompt is from Prompt management or defined inline. + // + // SourceConfiguration is a required field + SourceConfiguration *PromptFlowNodeSourceConfiguration `locationName:"sourceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -9409,7 +20291,7 @@ type InferenceConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InferenceConfiguration) String() string { +func (s PromptFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -9418,92 +20300,56 @@ func (s InferenceConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InferenceConfiguration) GoString() string { +func (s PromptFlowNodeConfiguration) GoString() string { return s.String() } -// SetMaximumLength sets the MaximumLength field's value. -func (s *InferenceConfiguration) SetMaximumLength(v int64) *InferenceConfiguration { - s.MaximumLength = &v - return s -} - -// SetStopSequences sets the StopSequences field's value. -func (s *InferenceConfiguration) SetStopSequences(v []*string) *InferenceConfiguration { - s.StopSequences = v - return s -} - -// SetTemperature sets the Temperature field's value. -func (s *InferenceConfiguration) SetTemperature(v float64) *InferenceConfiguration { - s.Temperature = &v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *PromptFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptFlowNodeConfiguration"} + if s.SourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("SourceConfiguration")) + } + if s.SourceConfiguration != nil { + if err := s.SourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SourceConfiguration", err.(request.ErrInvalidParams)) + } + } -// SetTopK sets the TopK field's value. -func (s *InferenceConfiguration) SetTopK(v int64) *InferenceConfiguration { - s.TopK = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetTopP sets the TopP field's value. -func (s *InferenceConfiguration) SetTopP(v float64) *InferenceConfiguration { - s.TopP = &v +// SetSourceConfiguration sets the SourceConfiguration field's value. +func (s *PromptFlowNodeConfiguration) SetSourceConfiguration(v *PromptFlowNodeSourceConfiguration) *PromptFlowNodeConfiguration { + s.SourceConfiguration = v return s } -// 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: -// -// - StartIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_StartIngestionJob.html#API_agent_StartIngestionJob_ResponseSyntax) -// -// - GetIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetIngestionJob.html#API_agent_GetIngestionJob_ResponseSyntax) -// -// - ListIngestionJob response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_ListIngestionJobs.html#API_agent_ListIngestionJobs_ResponseSyntax) -type IngestionJob struct { +// Contains configurations for a prompt defined inline in the node. +type PromptFlowNodeInlineConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the ingested data source. - // - // DataSourceId is a required field - DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - - // The description of the ingestion job. - Description *string `locationName:"description" min:"1" type:"string"` - - // A list of reasons that the ingestion job failed. - FailureReasons []*string `locationName:"failureReasons" type:"list"` - - // The unique identifier of the ingestion job. - // - // IngestionJobId is a required field - IngestionJobId *string `locationName:"ingestionJobId" type:"string" required:"true"` - - // The unique identifier of the knowledge base to which the data source is being - // added. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // Contains inference configurations for the prompt. + InferenceConfiguration *PromptInferenceConfiguration `locationName:"inferenceConfiguration" type:"structure"` - // The time at which the ingestion job started. + // The unique identifier of the model to run inference with. // - // StartedAt is a required field - StartedAt *time.Time `locationName:"startedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - - // Contains statistics about the ingestion job. - Statistics *IngestionJobStatistics `locationName:"statistics" type:"structure"` + // ModelId is a required field + ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` - // The status of the ingestion job. + // Contains a prompt and variables in the prompt that can be replaced with values + // at runtime. // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"IngestionJobStatus"` + // TemplateConfiguration is a required field + TemplateConfiguration *PromptTemplateConfiguration `locationName:"templateConfiguration" type:"structure" required:"true"` - // The time at which the ingestion job was last updated. + // The type of prompt template. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // TemplateType is a required field + TemplateType *string `locationName:"templateType" type:"string" required:"true" enum:"PromptTemplateType"` } // String returns the string representation. @@ -9511,7 +20357,7 @@ type IngestionJob struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJob) String() string { +func (s PromptFlowNodeInlineConfiguration) String() string { return awsutil.Prettify(s) } @@ -9520,82 +20366,69 @@ func (s IngestionJob) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJob) GoString() string { +func (s PromptFlowNodeInlineConfiguration) GoString() string { return s.String() } -// SetDataSourceId sets the DataSourceId field's value. -func (s *IngestionJob) SetDataSourceId(v string) *IngestionJob { - s.DataSourceId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *IngestionJob) SetDescription(v string) *IngestionJob { - s.Description = &v - return s -} - -// SetFailureReasons sets the FailureReasons field's value. -func (s *IngestionJob) SetFailureReasons(v []*string) *IngestionJob { - s.FailureReasons = v - return s -} - -// SetIngestionJobId sets the IngestionJobId field's value. -func (s *IngestionJob) SetIngestionJobId(v string) *IngestionJob { - s.IngestionJobId = &v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *PromptFlowNodeInlineConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptFlowNodeInlineConfiguration"} + if s.ModelId == nil { + invalidParams.Add(request.NewErrParamRequired("ModelId")) + } + if s.ModelId != nil && len(*s.ModelId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) + } + if s.TemplateConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("TemplateConfiguration")) + } + if s.TemplateType == nil { + invalidParams.Add(request.NewErrParamRequired("TemplateType")) + } + if s.TemplateConfiguration != nil { + if err := s.TemplateConfiguration.Validate(); err != nil { + invalidParams.AddNested("TemplateConfiguration", err.(request.ErrInvalidParams)) + } + } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *IngestionJob) SetKnowledgeBaseId(v string) *IngestionJob { - s.KnowledgeBaseId = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetStartedAt sets the StartedAt field's value. -func (s *IngestionJob) SetStartedAt(v time.Time) *IngestionJob { - s.StartedAt = &v +// SetInferenceConfiguration sets the InferenceConfiguration field's value. +func (s *PromptFlowNodeInlineConfiguration) SetInferenceConfiguration(v *PromptInferenceConfiguration) *PromptFlowNodeInlineConfiguration { + s.InferenceConfiguration = v return s } -// SetStatistics sets the Statistics field's value. -func (s *IngestionJob) SetStatistics(v *IngestionJobStatistics) *IngestionJob { - s.Statistics = v +// SetModelId sets the ModelId field's value. +func (s *PromptFlowNodeInlineConfiguration) SetModelId(v string) *PromptFlowNodeInlineConfiguration { + s.ModelId = &v return s } -// SetStatus sets the Status field's value. -func (s *IngestionJob) SetStatus(v string) *IngestionJob { - s.Status = &v +// SetTemplateConfiguration sets the TemplateConfiguration field's value. +func (s *PromptFlowNodeInlineConfiguration) SetTemplateConfiguration(v *PromptTemplateConfiguration) *PromptFlowNodeInlineConfiguration { + s.TemplateConfiguration = v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *IngestionJob) SetUpdatedAt(v time.Time) *IngestionJob { - s.UpdatedAt = &v +// SetTemplateType sets the TemplateType field's value. +func (s *PromptFlowNodeInlineConfiguration) SetTemplateType(v string) *PromptFlowNodeInlineConfiguration { + s.TemplateType = &v return s -} - -// Defines a filter by which to filter the results. -type IngestionJobFilter struct { - _ struct{} `type:"structure"` - - // The attribute by which to filter the results. - // - // Attribute is a required field - Attribute *string `locationName:"attribute" type:"string" required:"true" enum:"IngestionJobFilterAttribute"` +} - // The operation to carry out between the attribute and the values. - // - // Operator is a required field - Operator *string `locationName:"operator" type:"string" required:"true" enum:"IngestionJobFilterOperator"` +// Contains configurations for a prompt from Prompt management to use in a node. +type PromptFlowNodeResourceConfiguration struct { + _ struct{} `type:"structure"` - // A list of values for the attribute. + // The Amazon Resource Name (ARN) of the prompt from Prompt management. // - // Values is a required field - Values []*string `locationName:"values" type:"list" required:"true"` + // PromptArn is a required field + PromptArn *string `locationName:"promptArn" type:"string" required:"true"` } // String returns the string representation. @@ -9603,7 +20436,7 @@ type IngestionJobFilter struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobFilter) String() string { +func (s PromptFlowNodeResourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -9612,21 +20445,15 @@ func (s IngestionJobFilter) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobFilter) GoString() string { +func (s PromptFlowNodeResourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *IngestionJobFilter) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "IngestionJobFilter"} - if s.Attribute == nil { - invalidParams.Add(request.NewErrParamRequired("Attribute")) - } - if s.Operator == nil { - invalidParams.Add(request.NewErrParamRequired("Operator")) - } - if s.Values == nil { - invalidParams.Add(request.NewErrParamRequired("Values")) +func (s *PromptFlowNodeResourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptFlowNodeResourceConfiguration"} + if s.PromptArn == nil { + invalidParams.Add(request.NewErrParamRequired("PromptArn")) } if invalidParams.Len() > 0 { @@ -9635,37 +20462,22 @@ func (s *IngestionJobFilter) Validate() error { return nil } -// SetAttribute sets the Attribute field's value. -func (s *IngestionJobFilter) SetAttribute(v string) *IngestionJobFilter { - s.Attribute = &v - return s -} - -// SetOperator sets the Operator field's value. -func (s *IngestionJobFilter) SetOperator(v string) *IngestionJobFilter { - s.Operator = &v - return s -} - -// SetValues sets the Values field's value. -func (s *IngestionJobFilter) SetValues(v []*string) *IngestionJobFilter { - s.Values = v +// SetPromptArn sets the PromptArn field's value. +func (s *PromptFlowNodeResourceConfiguration) SetPromptArn(v string) *PromptFlowNodeResourceConfiguration { + s.PromptArn = &v return s } -// Parameters by which to sort the results. -type IngestionJobSortBy struct { +// Contains configurations for a prompt and whether it is from Prompt management +// or defined inline. +type PromptFlowNodeSourceConfiguration struct { _ struct{} `type:"structure"` - // The attribute by which to sort the results. - // - // Attribute is a required field - Attribute *string `locationName:"attribute" type:"string" required:"true" enum:"IngestionJobSortByAttribute"` + // Contains configurations for a prompt that is defined inline + Inline *PromptFlowNodeInlineConfiguration `locationName:"inline" type:"structure"` - // The order by which to sort the results. - // - // Order is a required field - Order *string `locationName:"order" type:"string" required:"true" enum:"SortOrder"` + // Contains configurations for a prompt from Prompt management. + Resource *PromptFlowNodeResourceConfiguration `locationName:"resource" type:"structure"` } // String returns the string representation. @@ -9673,7 +20485,7 @@ type IngestionJobSortBy struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobSortBy) String() string { +func (s PromptFlowNodeSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -9682,18 +20494,22 @@ func (s IngestionJobSortBy) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobSortBy) GoString() string { +func (s PromptFlowNodeSourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *IngestionJobSortBy) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "IngestionJobSortBy"} - if s.Attribute == nil { - invalidParams.Add(request.NewErrParamRequired("Attribute")) +func (s *PromptFlowNodeSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptFlowNodeSourceConfiguration"} + if s.Inline != nil { + if err := s.Inline.Validate(); err != nil { + invalidParams.AddNested("Inline", err.(request.ErrInvalidParams)) + } } - if s.Order == nil { - invalidParams.Add(request.NewErrParamRequired("Order")) + if s.Resource != nil { + if err := s.Resource.Validate(); err != nil { + invalidParams.AddNested("Resource", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -9702,46 +20518,24 @@ func (s *IngestionJobSortBy) Validate() error { return nil } -// SetAttribute sets the Attribute field's value. -func (s *IngestionJobSortBy) SetAttribute(v string) *IngestionJobSortBy { - s.Attribute = &v +// SetInline sets the Inline field's value. +func (s *PromptFlowNodeSourceConfiguration) SetInline(v *PromptFlowNodeInlineConfiguration) *PromptFlowNodeSourceConfiguration { + s.Inline = v return s } -// SetOrder sets the Order field's value. -func (s *IngestionJobSortBy) SetOrder(v string) *IngestionJobSortBy { - s.Order = &v +// SetResource sets the Resource field's value. +func (s *PromptFlowNodeSourceConfiguration) SetResource(v *PromptFlowNodeResourceConfiguration) *PromptFlowNodeSourceConfiguration { + s.Resource = v return s } -// Contains the statistics for the ingestion job. -type IngestionJobStatistics struct { +// Contains inference configurations for the prompt. +type PromptInferenceConfiguration struct { _ struct{} `type:"structure"` - // The number of source documents that was deleted. - NumberOfDocumentsDeleted *int64 `locationName:"numberOfDocumentsDeleted" type:"long"` - - // The number of source documents that failed to be ingested. - NumberOfDocumentsFailed *int64 `locationName:"numberOfDocumentsFailed" type:"long"` - - // The total number of source documents that were scanned. Includes new, updated, - // and unchanged documents. - NumberOfDocumentsScanned *int64 `locationName:"numberOfDocumentsScanned" type:"long"` - - // The number of metadata files that were updated or deleted. - NumberOfMetadataDocumentsModified *int64 `locationName:"numberOfMetadataDocumentsModified" type:"long"` - - // The total number of metadata files that were scanned. Includes new, updated, - // and unchanged files. - NumberOfMetadataDocumentsScanned *int64 `locationName:"numberOfMetadataDocumentsScanned" type:"long"` - - // The number of modified source documents in the data source that were successfully - // indexed. - NumberOfModifiedDocumentsIndexed *int64 `locationName:"numberOfModifiedDocumentsIndexed" type:"long"` - - // The number of new source documents in the data source that were successfully - // indexed. - NumberOfNewDocumentsIndexed *int64 `locationName:"numberOfNewDocumentsIndexed" type:"long"` + // Contains inference configurations for a text prompt. + Text *PromptModelInferenceConfiguration `locationName:"text" type:"structure"` } // String returns the string representation. @@ -9749,7 +20543,7 @@ type IngestionJobStatistics struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobStatistics) String() string { +func (s PromptInferenceConfiguration) String() string { return awsutil.Prettify(s) } @@ -9758,91 +20552,70 @@ func (s IngestionJobStatistics) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobStatistics) GoString() string { +func (s PromptInferenceConfiguration) GoString() string { return s.String() } -// SetNumberOfDocumentsDeleted sets the NumberOfDocumentsDeleted field's value. -func (s *IngestionJobStatistics) SetNumberOfDocumentsDeleted(v int64) *IngestionJobStatistics { - s.NumberOfDocumentsDeleted = &v - return s -} - -// SetNumberOfDocumentsFailed sets the NumberOfDocumentsFailed field's value. -func (s *IngestionJobStatistics) SetNumberOfDocumentsFailed(v int64) *IngestionJobStatistics { - s.NumberOfDocumentsFailed = &v +// SetText sets the Text field's value. +func (s *PromptInferenceConfiguration) SetText(v *PromptModelInferenceConfiguration) *PromptInferenceConfiguration { + s.Text = v return s } -// SetNumberOfDocumentsScanned sets the NumberOfDocumentsScanned field's value. -func (s *IngestionJobStatistics) SetNumberOfDocumentsScanned(v int64) *IngestionJobStatistics { - s.NumberOfDocumentsScanned = &v - return s -} +// Contains information about a variable in the prompt. +type PromptInputVariable struct { + _ struct{} `type:"structure"` -// SetNumberOfMetadataDocumentsModified sets the NumberOfMetadataDocumentsModified field's value. -func (s *IngestionJobStatistics) SetNumberOfMetadataDocumentsModified(v int64) *IngestionJobStatistics { - s.NumberOfMetadataDocumentsModified = &v - return s + // The name of the variable. + Name *string `locationName:"name" type:"string"` } -// SetNumberOfMetadataDocumentsScanned sets the NumberOfMetadataDocumentsScanned field's value. -func (s *IngestionJobStatistics) SetNumberOfMetadataDocumentsScanned(v int64) *IngestionJobStatistics { - s.NumberOfMetadataDocumentsScanned = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PromptInputVariable) String() string { + return awsutil.Prettify(s) } -// SetNumberOfModifiedDocumentsIndexed sets the NumberOfModifiedDocumentsIndexed field's value. -func (s *IngestionJobStatistics) SetNumberOfModifiedDocumentsIndexed(v int64) *IngestionJobStatistics { - s.NumberOfModifiedDocumentsIndexed = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PromptInputVariable) GoString() string { + return s.String() } -// SetNumberOfNewDocumentsIndexed sets the NumberOfNewDocumentsIndexed field's value. -func (s *IngestionJobStatistics) SetNumberOfNewDocumentsIndexed(v int64) *IngestionJobStatistics { - s.NumberOfNewDocumentsIndexed = &v +// SetName sets the Name field's value. +func (s *PromptInputVariable) SetName(v string) *PromptInputVariable { + s.Name = &v return s } -// Contains details about an ingestion job. -type IngestionJobSummary struct { +// Contains inference configurations related to model inference for a prompt. +// For more information, see Inference parameters (https://docs.aws.amazon.com/bedrock/latest/userguide/inference-parameters.html). +type PromptModelInferenceConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the data source in the ingestion job. - // - // DataSourceId is a required field - DataSourceId *string `locationName:"dataSourceId" type:"string" required:"true"` - - // The description of the ingestion job. - Description *string `locationName:"description" min:"1" type:"string"` - - // The unique identifier of the ingestion job. - // - // IngestionJobId is a required field - IngestionJobId *string `locationName:"ingestionJobId" type:"string" required:"true"` - - // The unique identifier of the knowledge base to which the data source is added. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // The maximum number of tokens to return in the response. + MaxTokens *int64 `locationName:"maxTokens" type:"integer"` - // The time at which the ingestion job was started. - // - // StartedAt is a required field - StartedAt *time.Time `locationName:"startedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // A list of strings that define sequences after which the model will stop generating. + StopSequences []*string `locationName:"stopSequences" type:"list"` - // Contains statistics for the ingestion job. - Statistics *IngestionJobStatistics `locationName:"statistics" type:"structure"` + // Controls the randomness of the response. Choose a lower value for more predictable + // outputs and a higher value for more surprising outputs. + Temperature *float64 `locationName:"temperature" type:"float"` - // The status of the ingestion job. - // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"IngestionJobStatus"` + // The number of most-likely candidates that the model considers for the next + // token during generation. + TopK *int64 `locationName:"topK" type:"integer"` - // The time at which the ingestion job was last updated. - // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // The percentage of most-likely candidates that the model considers for the + // next token. + TopP *float64 `locationName:"topP" type:"float"` } // String returns the string representation. @@ -9850,7 +20623,7 @@ type IngestionJobSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobSummary) String() string { +func (s PromptModelInferenceConfiguration) String() string { return awsutil.Prettify(s) } @@ -9859,64 +20632,57 @@ func (s IngestionJobSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s IngestionJobSummary) GoString() string { +func (s PromptModelInferenceConfiguration) GoString() string { return s.String() } -// SetDataSourceId sets the DataSourceId field's value. -func (s *IngestionJobSummary) SetDataSourceId(v string) *IngestionJobSummary { - s.DataSourceId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *IngestionJobSummary) SetDescription(v string) *IngestionJobSummary { - s.Description = &v - return s -} - -// SetIngestionJobId sets the IngestionJobId field's value. -func (s *IngestionJobSummary) SetIngestionJobId(v string) *IngestionJobSummary { - s.IngestionJobId = &v +// SetMaxTokens sets the MaxTokens field's value. +func (s *PromptModelInferenceConfiguration) SetMaxTokens(v int64) *PromptModelInferenceConfiguration { + s.MaxTokens = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *IngestionJobSummary) SetKnowledgeBaseId(v string) *IngestionJobSummary { - s.KnowledgeBaseId = &v +// SetStopSequences sets the StopSequences field's value. +func (s *PromptModelInferenceConfiguration) SetStopSequences(v []*string) *PromptModelInferenceConfiguration { + s.StopSequences = v return s } -// SetStartedAt sets the StartedAt field's value. -func (s *IngestionJobSummary) SetStartedAt(v time.Time) *IngestionJobSummary { - s.StartedAt = &v +// SetTemperature sets the Temperature field's value. +func (s *PromptModelInferenceConfiguration) SetTemperature(v float64) *PromptModelInferenceConfiguration { + s.Temperature = &v return s } -// SetStatistics sets the Statistics field's value. -func (s *IngestionJobSummary) SetStatistics(v *IngestionJobStatistics) *IngestionJobSummary { - s.Statistics = v +// SetTopK sets the TopK field's value. +func (s *PromptModelInferenceConfiguration) SetTopK(v int64) *PromptModelInferenceConfiguration { + s.TopK = &v return s } -// SetStatus sets the Status field's value. -func (s *IngestionJobSummary) SetStatus(v string) *IngestionJobSummary { - s.Status = &v +// SetTopP sets the TopP field's value. +func (s *PromptModelInferenceConfiguration) SetTopP(v float64) *PromptModelInferenceConfiguration { + s.TopP = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *IngestionJobSummary) SetUpdatedAt(v time.Time) *IngestionJobSummary { - s.UpdatedAt = &v - return s -} +// Contains configurations to override prompts in different parts of an agent +// sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). +type PromptOverrideConfiguration struct { + _ struct{} `type:"structure" sensitive:"true"` -// An internal server error occurred. Retry your request. -type InternalServerException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/lambda-parser.html). + OverrideLambda *string `locationName:"overrideLambda" type:"string"` - Message_ *string `locationName:"message" type:"string"` + // Contains configurations to override a prompt template in one part of an agent + // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // + // PromptConfigurations is a required field + PromptConfigurations []*PromptConfiguration `locationName:"promptConfigurations" type:"list" required:"true"` } // String returns the string representation. @@ -9924,122 +20690,94 @@ type InternalServerException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InternalServerException) String() string { +func (s PromptOverrideConfiguration) String() string { return awsutil.Prettify(s) } - -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s InternalServerException) GoString() string { - return s.String() -} - -func newErrorInternalServerException(v protocol.ResponseMetadata) error { - return &InternalServerException{ - RespMetadata: v, - } -} - -// Code returns the exception type name. -func (s *InternalServerException) Code() string { - return "InternalServerException" + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PromptOverrideConfiguration) GoString() string { + return s.String() } -// Message returns the exception's message. -func (s *InternalServerException) Message() string { - if s.Message_ != nil { - return *s.Message_ +// Validate inspects the fields of the type to determine if they are valid. +func (s *PromptOverrideConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptOverrideConfiguration"} + if s.PromptConfigurations == nil { + invalidParams.Add(request.NewErrParamRequired("PromptConfigurations")) + } + if s.PromptConfigurations != nil { + for i, v := range s.PromptConfigurations { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PromptConfigurations", i), err.(request.ErrInvalidParams)) + } + } } - return "" -} -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *InternalServerException) OrigErr() error { + if invalidParams.Len() > 0 { + return invalidParams + } return nil } -func (s *InternalServerException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) -} - -// Status code returns the HTTP status code for the request's response error. -func (s *InternalServerException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetOverrideLambda sets the OverrideLambda field's value. +func (s *PromptOverrideConfiguration) SetOverrideLambda(v string) *PromptOverrideConfiguration { + s.OverrideLambda = &v + return s } -// RequestID returns the service's response RequestID for request. -func (s *InternalServerException) RequestID() string { - return s.RespMetadata.RequestID +// SetPromptConfigurations sets the PromptConfigurations field's value. +func (s *PromptOverrideConfiguration) SetPromptConfigurations(v []*PromptConfiguration) *PromptOverrideConfiguration { + s.PromptConfigurations = v + return s } -// Contains information about a knowledge base. -type KnowledgeBase struct { +// Contains information about a prompt in your Prompt management tool. +// +// This data type is used in the following API operations: +// +// - ListPrompts response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_ListPrompts.html#API_agent_ListPrompts_ResponseSyntax) +type PromptSummary struct { _ struct{} `type:"structure"` - // The time at which the knowledge base was created. + // The Amazon Resource Name (ARN) of the prompt. + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the prompt was created. // // CreatedAt is a required field CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The description of the knowledge base. + // The description of the prompt. Description *string `locationName:"description" min:"1" type:"string"` - // A list of reasons that the API operation on the knowledge base failed. - FailureReasons []*string `locationName:"failureReasons" type:"list"` - - // The Amazon Resource Name (ARN) of the knowledge base. - // - // KnowledgeBaseArn is a required field - KnowledgeBaseArn *string `locationName:"knowledgeBaseArn" type:"string" required:"true"` - - // Contains details about the embeddings configuration of the knowledge base. - // - // KnowledgeBaseConfiguration is a required field - KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` - - // The unique identifier of the knowledge base. + // The unique identifier of the prompt. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // The name of the knowledge base. + // The name of the prompt. // // Name is a required field Name *string `locationName:"name" type:"string" required:"true"` - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the knowledge base. - // - // RoleArn is a required field - RoleArn *string `locationName:"roleArn" type:"string" required:"true"` - - // 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. - // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` - - // Contains details about the storage configuration of the knowledge base. - // - // StorageConfiguration is a required field - StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` - - // The time at which the knowledge base was last updated. + // The time at which the prompt was last updated. // // UpdatedAt is a required field UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The version of the prompt that this summary applies to. + // + // Version is a required field + Version *string `locationName:"version" min:"1" type:"string" required:"true"` } // String returns the string representation. @@ -10047,7 +20785,7 @@ type KnowledgeBase struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBase) String() string { +func (s PromptSummary) String() string { return awsutil.Prettify(s) } @@ -10056,89 +20794,126 @@ func (s KnowledgeBase) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBase) GoString() string { +func (s PromptSummary) GoString() string { return s.String() } +// SetArn sets the Arn field's value. +func (s *PromptSummary) SetArn(v string) *PromptSummary { + s.Arn = &v + return s +} + // SetCreatedAt sets the CreatedAt field's value. -func (s *KnowledgeBase) SetCreatedAt(v time.Time) *KnowledgeBase { +func (s *PromptSummary) SetCreatedAt(v time.Time) *PromptSummary { s.CreatedAt = &v return s } // SetDescription sets the Description field's value. -func (s *KnowledgeBase) SetDescription(v string) *KnowledgeBase { +func (s *PromptSummary) SetDescription(v string) *PromptSummary { s.Description = &v return s } -// SetFailureReasons sets the FailureReasons field's value. -func (s *KnowledgeBase) SetFailureReasons(v []*string) *KnowledgeBase { - s.FailureReasons = v +// SetId sets the Id field's value. +func (s *PromptSummary) SetId(v string) *PromptSummary { + s.Id = &v return s } -// SetKnowledgeBaseArn sets the KnowledgeBaseArn field's value. -func (s *KnowledgeBase) SetKnowledgeBaseArn(v string) *KnowledgeBase { - s.KnowledgeBaseArn = &v +// SetName sets the Name field's value. +func (s *PromptSummary) SetName(v string) *PromptSummary { + s.Name = &v return s } -// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. -func (s *KnowledgeBase) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *KnowledgeBase { - s.KnowledgeBaseConfiguration = v +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *PromptSummary) SetUpdatedAt(v time.Time) *PromptSummary { + s.UpdatedAt = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *KnowledgeBase) SetKnowledgeBaseId(v string) *KnowledgeBase { - s.KnowledgeBaseId = &v +// SetVersion sets the Version field's value. +func (s *PromptSummary) SetVersion(v string) *PromptSummary { + s.Version = &v return s } -// SetName sets the Name field's value. -func (s *KnowledgeBase) SetName(v string) *KnowledgeBase { - s.Name = &v - return s +// Contains the message for a prompt. For more information, see Prompt management +// in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management.html). +type PromptTemplateConfiguration struct { + _ struct{} `type:"structure"` + + // Contains configurations for the text in a message for a prompt. + // + // Text is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by PromptTemplateConfiguration's + // String and GoString methods. + Text *TextPromptTemplateConfiguration `locationName:"text" type:"structure" sensitive:"true"` } -// SetRoleArn sets the RoleArn field's value. -func (s *KnowledgeBase) SetRoleArn(v string) *KnowledgeBase { - s.RoleArn = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PromptTemplateConfiguration) String() string { + return awsutil.Prettify(s) } -// SetStatus sets the Status field's value. -func (s *KnowledgeBase) SetStatus(v string) *KnowledgeBase { - s.Status = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PromptTemplateConfiguration) GoString() string { + return s.String() } -// SetStorageConfiguration sets the StorageConfiguration field's value. -func (s *KnowledgeBase) SetStorageConfiguration(v *StorageConfiguration) *KnowledgeBase { - s.StorageConfiguration = v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *PromptTemplateConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptTemplateConfiguration"} + if s.Text != nil { + if err := s.Text.Validate(); err != nil { + invalidParams.AddNested("Text", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *KnowledgeBase) SetUpdatedAt(v time.Time) *KnowledgeBase { - s.UpdatedAt = &v +// SetText sets the Text field's value. +func (s *PromptTemplateConfiguration) SetText(v *TextPromptTemplateConfiguration) *PromptTemplateConfiguration { + s.Text = v return s } -// Contains details about the embeddings configuration of the knowledge base. -type KnowledgeBaseConfiguration struct { - _ struct{} `type:"structure"` +// Contains details about a variant of the prompt. +type PromptVariant struct { + _ struct{} `type:"structure" sensitive:"true"` - // The type of data that the data source is converted into for the knowledge - // base. + // Contains inference configurations for the prompt variant. + InferenceConfiguration *PromptInferenceConfiguration `locationName:"inferenceConfiguration" type:"structure"` + + // The unique identifier of the model with which to run inference on the prompt. + ModelId *string `locationName:"modelId" min:"1" type:"string"` + + // The name of the prompt variant. // - // Type is a required field - Type *string `locationName:"type" type:"string" required:"true" enum:"KnowledgeBaseType"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // Contains details about the embeddings model that'sused to convert the data - // source. - VectorKnowledgeBaseConfiguration *VectorKnowledgeBaseConfiguration `locationName:"vectorKnowledgeBaseConfiguration" type:"structure"` + // Contains configurations for the prompt template. + TemplateConfiguration *PromptTemplateConfiguration `locationName:"templateConfiguration" type:"structure"` + + // The type of prompt template to use. + // + // TemplateType is a required field + TemplateType *string `locationName:"templateType" type:"string" required:"true" enum:"PromptTemplateType"` } // String returns the string representation. @@ -10146,7 +20921,7 @@ type KnowledgeBaseConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBaseConfiguration) String() string { +func (s PromptVariant) String() string { return awsutil.Prettify(s) } @@ -10155,19 +20930,25 @@ func (s KnowledgeBaseConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBaseConfiguration) GoString() string { +func (s PromptVariant) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *KnowledgeBaseConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "KnowledgeBaseConfiguration"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) +func (s *PromptVariant) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PromptVariant"} + if s.ModelId != nil && len(*s.ModelId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) } - if s.VectorKnowledgeBaseConfiguration != nil { - if err := s.VectorKnowledgeBaseConfiguration.Validate(); err != nil { - invalidParams.AddNested("VectorKnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.TemplateType == nil { + invalidParams.Add(request.NewErrParamRequired("TemplateType")) + } + if s.TemplateConfiguration != nil { + if err := s.TemplateConfiguration.Validate(); err != nil { + invalidParams.AddNested("TemplateConfiguration", err.(request.ErrInvalidParams)) } } @@ -10177,44 +20958,68 @@ func (s *KnowledgeBaseConfiguration) Validate() error { return nil } -// SetType sets the Type field's value. -func (s *KnowledgeBaseConfiguration) SetType(v string) *KnowledgeBaseConfiguration { - s.Type = &v +// SetInferenceConfiguration sets the InferenceConfiguration field's value. +func (s *PromptVariant) SetInferenceConfiguration(v *PromptInferenceConfiguration) *PromptVariant { + s.InferenceConfiguration = v return s } -// SetVectorKnowledgeBaseConfiguration sets the VectorKnowledgeBaseConfiguration field's value. -func (s *KnowledgeBaseConfiguration) SetVectorKnowledgeBaseConfiguration(v *VectorKnowledgeBaseConfiguration) *KnowledgeBaseConfiguration { - s.VectorKnowledgeBaseConfiguration = v +// SetModelId sets the ModelId field's value. +func (s *PromptVariant) SetModelId(v string) *PromptVariant { + s.ModelId = &v return s } -// Contains details about a knowledge base. -type KnowledgeBaseSummary struct { +// SetName sets the Name field's value. +func (s *PromptVariant) SetName(v string) *PromptVariant { + s.Name = &v + return s +} + +// SetTemplateConfiguration sets the TemplateConfiguration field's value. +func (s *PromptVariant) SetTemplateConfiguration(v *PromptTemplateConfiguration) *PromptVariant { + s.TemplateConfiguration = v + return s +} + +// SetTemplateType sets the TemplateType field's value. +func (s *PromptVariant) SetTemplateType(v string) *PromptVariant { + s.TemplateType = &v + return s +} + +// Contains details about the storage configuration of the knowledge base in +// Amazon RDS. For more information, see Create a vector index in Amazon RDS +// (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). +type RdsConfiguration struct { _ struct{} `type:"structure"` - // The description of the knowledge base. - Description *string `locationName:"description" min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the secret that you created in Secrets + // Manager that is linked to your Amazon RDS database. + // + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` - // The unique identifier of the knowledge base. + // The name of your Amazon RDS database. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` + // DatabaseName is a required field + DatabaseName *string `locationName:"databaseName" type:"string" required:"true"` - // The name of the knowledge base. + // Contains the names of the fields to which to map information about the vector + // store. // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` + // FieldMapping is a required field + FieldMapping *RdsFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` - // The status of the knowledge base. + // The Amazon Resource Name (ARN) of the vector store. // - // Status is a required field - Status *string `locationName:"status" type:"string" required:"true" enum:"KnowledgeBaseStatus"` + // ResourceArn is a required field + ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"` - // The time at which the knowledge base was last updated. + // The name of the table in the database. // - // UpdatedAt is a required field - UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + // TableName is a required field + TableName *string `locationName:"tableName" type:"string" required:"true"` } // String returns the string representation. @@ -10222,7 +21027,7 @@ type KnowledgeBaseSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBaseSummary) String() string { +func (s RdsConfiguration) String() string { return awsutil.Prettify(s) } @@ -10231,63 +21036,97 @@ func (s KnowledgeBaseSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s KnowledgeBaseSummary) GoString() string { +func (s RdsConfiguration) GoString() string { return s.String() } -// SetDescription sets the Description field's value. -func (s *KnowledgeBaseSummary) SetDescription(v string) *KnowledgeBaseSummary { - s.Description = &v +// Validate inspects the fields of the type to determine if they are valid. +func (s *RdsConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RdsConfiguration"} + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) + } + if s.DatabaseName == nil { + invalidParams.Add(request.NewErrParamRequired("DatabaseName")) + } + if s.FieldMapping == nil { + invalidParams.Add(request.NewErrParamRequired("FieldMapping")) + } + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.TableName == nil { + invalidParams.Add(request.NewErrParamRequired("TableName")) + } + if s.FieldMapping != nil { + if err := s.FieldMapping.Validate(); err != nil { + invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *RdsConfiguration) SetCredentialsSecretArn(v string) *RdsConfiguration { + s.CredentialsSecretArn = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *KnowledgeBaseSummary) SetKnowledgeBaseId(v string) *KnowledgeBaseSummary { - s.KnowledgeBaseId = &v +// SetDatabaseName sets the DatabaseName field's value. +func (s *RdsConfiguration) SetDatabaseName(v string) *RdsConfiguration { + s.DatabaseName = &v return s } -// SetName sets the Name field's value. -func (s *KnowledgeBaseSummary) SetName(v string) *KnowledgeBaseSummary { - s.Name = &v +// SetFieldMapping sets the FieldMapping field's value. +func (s *RdsConfiguration) SetFieldMapping(v *RdsFieldMapping) *RdsConfiguration { + s.FieldMapping = v return s } -// SetStatus sets the Status field's value. -func (s *KnowledgeBaseSummary) SetStatus(v string) *KnowledgeBaseSummary { - s.Status = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *RdsConfiguration) SetResourceArn(v string) *RdsConfiguration { + s.ResourceArn = &v return s } -// SetUpdatedAt sets the UpdatedAt field's value. -func (s *KnowledgeBaseSummary) SetUpdatedAt(v time.Time) *KnowledgeBaseSummary { - s.UpdatedAt = &v +// SetTableName sets the TableName field's value. +func (s *RdsConfiguration) SetTableName(v string) *RdsConfiguration { + s.TableName = &v return s } -type ListAgentActionGroupsInput struct { +// Contains the names of the fields to which to map information about the vector +// store. +type RdsFieldMapping struct { _ struct{} `type:"structure"` - // The unique identifier of the agent. + // The name of the field in which Amazon Bedrock stores metadata about the vector + // store. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // MetadataField is a required field + MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - // The version of the agent. + // The name of the field in which Amazon Bedrock stores the ID for each entry. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` + // PrimaryKeyField is a required field + PrimaryKeyField *string `locationName:"primaryKeyField" type:"string" required:"true"` - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + // 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. + // + // TextField is a required field + TextField *string `locationName:"textField" type:"string" required:"true"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The name of the field in which Amazon Bedrock stores the vector embeddings + // for your data sources. + // + // VectorField is a required field + VectorField *string `locationName:"vectorField" type:"string" required:"true"` } // String returns the string representation. @@ -10295,7 +21134,7 @@ type ListAgentActionGroupsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentActionGroupsInput) String() string { +func (s RdsFieldMapping) String() string { return awsutil.Prettify(s) } @@ -10304,30 +21143,24 @@ func (s ListAgentActionGroupsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentActionGroupsInput) GoString() string { +func (s RdsFieldMapping) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListAgentActionGroupsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListAgentActionGroupsInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) +func (s *RdsFieldMapping) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RdsFieldMapping"} + if s.MetadataField == nil { + invalidParams.Add(request.NewErrParamRequired("MetadataField")) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) + if s.PrimaryKeyField == nil { + invalidParams.Add(request.NewErrParamRequired("PrimaryKeyField")) } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + if s.TextField == nil { + invalidParams.Add(request.NewErrParamRequired("TextField")) } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + if s.VectorField == nil { + invalidParams.Add(request.NewErrParamRequired("VectorField")) } if invalidParams.Len() > 0 { @@ -10336,42 +21169,57 @@ func (s *ListAgentActionGroupsInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *ListAgentActionGroupsInput) SetAgentId(v string) *ListAgentActionGroupsInput { - s.AgentId = &v +// SetMetadataField sets the MetadataField field's value. +func (s *RdsFieldMapping) SetMetadataField(v string) *RdsFieldMapping { + s.MetadataField = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *ListAgentActionGroupsInput) SetAgentVersion(v string) *ListAgentActionGroupsInput { - s.AgentVersion = &v +// SetPrimaryKeyField sets the PrimaryKeyField field's value. +func (s *RdsFieldMapping) SetPrimaryKeyField(v string) *RdsFieldMapping { + s.PrimaryKeyField = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListAgentActionGroupsInput) SetMaxResults(v int64) *ListAgentActionGroupsInput { - s.MaxResults = &v +// SetTextField sets the TextField field's value. +func (s *RdsFieldMapping) SetTextField(v string) *RdsFieldMapping { + s.TextField = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentActionGroupsInput) SetNextToken(v string) *ListAgentActionGroupsInput { - s.NextToken = &v +// SetVectorField sets the VectorField field's value. +func (s *RdsFieldMapping) SetVectorField(v string) *RdsFieldMapping { + s.VectorField = &v return s } -type ListAgentActionGroupsOutput struct { +// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). +type RedisEnterpriseCloudConfiguration struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about an action group. + // The Amazon Resource Name (ARN) of the secret that you created in Secrets + // Manager that is linked to your Redis Enterprise Cloud database. // - // ActionGroupSummaries is a required field - ActionGroupSummaries []*ActionGroupSummary `locationName:"actionGroupSummaries" type:"list" required:"true"` + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The endpoint URL of the Redis Enterprise Cloud database. + // + // Endpoint is a required field + Endpoint *string `locationName:"endpoint" type:"string" required:"true"` + + // Contains the names of the fields to which to map information about the vector + // store. + // + // FieldMapping is a required field + FieldMapping *RedisEnterpriseCloudFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + + // The name of the vector index. + // + // VectorIndexName is a required field + VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` } // String returns the string representation. @@ -10379,7 +21227,7 @@ type ListAgentActionGroupsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentActionGroupsOutput) String() string { +func (s RedisEnterpriseCloudConfiguration) String() string { return awsutil.Prettify(s) } @@ -10388,40 +21236,83 @@ func (s ListAgentActionGroupsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentActionGroupsOutput) GoString() string { +func (s RedisEnterpriseCloudConfiguration) GoString() string { return s.String() } -// SetActionGroupSummaries sets the ActionGroupSummaries field's value. -func (s *ListAgentActionGroupsOutput) SetActionGroupSummaries(v []*ActionGroupSummary) *ListAgentActionGroupsOutput { - s.ActionGroupSummaries = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *RedisEnterpriseCloudConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RedisEnterpriseCloudConfiguration"} + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) + } + if s.Endpoint == nil { + invalidParams.Add(request.NewErrParamRequired("Endpoint")) + } + if s.FieldMapping == nil { + invalidParams.Add(request.NewErrParamRequired("FieldMapping")) + } + if s.VectorIndexName == nil { + invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) + } + if s.FieldMapping != nil { + if err := s.FieldMapping.Validate(); err != nil { + invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *RedisEnterpriseCloudConfiguration) SetCredentialsSecretArn(v string) *RedisEnterpriseCloudConfiguration { + s.CredentialsSecretArn = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentActionGroupsOutput) SetNextToken(v string) *ListAgentActionGroupsOutput { - s.NextToken = &v +// SetEndpoint sets the Endpoint field's value. +func (s *RedisEnterpriseCloudConfiguration) SetEndpoint(v string) *RedisEnterpriseCloudConfiguration { + s.Endpoint = &v return s } -type ListAgentAliasesInput struct { +// SetFieldMapping sets the FieldMapping field's value. +func (s *RedisEnterpriseCloudConfiguration) SetFieldMapping(v *RedisEnterpriseCloudFieldMapping) *RedisEnterpriseCloudConfiguration { + s.FieldMapping = v + return s +} + +// SetVectorIndexName sets the VectorIndexName field's value. +func (s *RedisEnterpriseCloudConfiguration) SetVectorIndexName(v string) *RedisEnterpriseCloudConfiguration { + s.VectorIndexName = &v + return s +} + +// Contains the names of the fields to which to map information about the vector +// store. +type RedisEnterpriseCloudFieldMapping struct { _ struct{} `type:"structure"` - // The unique identifier of the agent. + // The name of the field in which Amazon Bedrock stores metadata about the vector + // store. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // MetadataField is a required field + MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + // 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. + // + // TextField is a required field + TextField *string `locationName:"textField" type:"string" required:"true"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The name of the field in which Amazon Bedrock stores the vector embeddings + // for your data sources. + // + // VectorField is a required field + VectorField *string `locationName:"vectorField" type:"string" required:"true"` } // String returns the string representation. @@ -10429,7 +21320,7 @@ type ListAgentAliasesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentAliasesInput) String() string { +func (s RedisEnterpriseCloudFieldMapping) String() string { return awsutil.Prettify(s) } @@ -10438,24 +21329,21 @@ func (s ListAgentAliasesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentAliasesInput) GoString() string { +func (s RedisEnterpriseCloudFieldMapping) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListAgentAliasesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListAgentAliasesInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) +func (s *RedisEnterpriseCloudFieldMapping) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RedisEnterpriseCloudFieldMapping"} + if s.MetadataField == nil { + invalidParams.Add(request.NewErrParamRequired("MetadataField")) } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + if s.TextField == nil { + invalidParams.Add(request.NewErrParamRequired("TextField")) } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + if s.VectorField == nil { + invalidParams.Add(request.NewErrParamRequired("VectorField")) } if invalidParams.Len() > 0 { @@ -10464,37 +21352,31 @@ func (s *ListAgentAliasesInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *ListAgentAliasesInput) SetAgentId(v string) *ListAgentAliasesInput { - s.AgentId = &v +// SetMetadataField sets the MetadataField field's value. +func (s *RedisEnterpriseCloudFieldMapping) SetMetadataField(v string) *RedisEnterpriseCloudFieldMapping { + s.MetadataField = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListAgentAliasesInput) SetMaxResults(v int64) *ListAgentAliasesInput { - s.MaxResults = &v +// SetTextField sets the TextField field's value. +func (s *RedisEnterpriseCloudFieldMapping) SetTextField(v string) *RedisEnterpriseCloudFieldMapping { + s.TextField = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentAliasesInput) SetNextToken(v string) *ListAgentAliasesInput { - s.NextToken = &v +// SetVectorField sets the VectorField field's value. +func (s *RedisEnterpriseCloudFieldMapping) SetVectorField(v string) *RedisEnterpriseCloudFieldMapping { + s.VectorField = &v return s } -type ListAgentAliasesOutput struct { - _ struct{} `type:"structure"` - - // A list of objects, each of which contains information about an alias of the - // agent. - // - // AgentAliasSummaries is a required field - AgentAliasSummaries []*AgentAliasSummary `locationName:"agentAliasSummaries" type:"list" required:"true"` +// The specified resource Amazon Resource Name (ARN) was not found. Check the +// Amazon Resource Name (ARN) and try your request again. +type ResourceNotFoundException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -10502,7 +21384,7 @@ type ListAgentAliasesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentAliasesOutput) String() string { +func (s ResourceNotFoundException) String() string { return awsutil.Prettify(s) } @@ -10511,47 +21393,58 @@ func (s ListAgentAliasesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentAliasesOutput) GoString() string { +func (s ResourceNotFoundException) GoString() string { return s.String() } -// SetAgentAliasSummaries sets the AgentAliasSummaries field's value. -func (s *ListAgentAliasesOutput) SetAgentAliasSummaries(v []*AgentAliasSummary) *ListAgentAliasesOutput { - s.AgentAliasSummaries = v - return s +func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { + return &ResourceNotFoundException{ + RespMetadata: v, + } } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentAliasesOutput) SetNextToken(v string) *ListAgentAliasesOutput { - s.NextToken = &v - return s +// Code returns the exception type name. +func (s *ResourceNotFoundException) Code() string { + return "ResourceNotFoundException" } -type ListAgentKnowledgeBasesInput struct { - _ struct{} `type:"structure"` +// Message returns the exception's message. +func (s *ResourceNotFoundException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} - // The unique identifier of the agent for which to return information about - // knowledge bases associated with it. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ResourceNotFoundException) OrigErr() error { + return nil +} - // The version of the agent for which to return information about knowledge - // bases associated with it. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"1" type:"string" required:"true"` +func (s *ResourceNotFoundException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` +// Status code returns the HTTP status code for the request's response error. +func (s *ResourceNotFoundException) StatusCode() int { + return s.RespMetadata.StatusCode +} - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` +// RequestID returns the service's response RequestID for request. +func (s *ResourceNotFoundException) RequestID() string { + return s.RespMetadata.RequestID +} + +// 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. +type RetrievalFlowNodeConfiguration struct { + _ struct{} `type:"structure"` + + // Contains configurations for the service to use for retrieving data to return + // as the output from the node. + // + // ServiceConfiguration is a required field + ServiceConfiguration *RetrievalFlowNodeServiceConfiguration `locationName:"serviceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -10559,7 +21452,7 @@ type ListAgentKnowledgeBasesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentKnowledgeBasesInput) String() string { +func (s RetrievalFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -10568,30 +21461,20 @@ func (s ListAgentKnowledgeBasesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentKnowledgeBasesInput) GoString() string { +func (s RetrievalFlowNodeConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListAgentKnowledgeBasesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListAgentKnowledgeBasesInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) - } - if s.AgentVersion != nil && len(*s.AgentVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 1)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +func (s *RetrievalFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RetrievalFlowNodeConfiguration"} + if s.ServiceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("ServiceConfiguration")) + } + if s.ServiceConfiguration != nil { + if err := s.ServiceConfiguration.Validate(); err != nil { + invalidParams.AddNested("ServiceConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -10600,43 +21483,21 @@ func (s *ListAgentKnowledgeBasesInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *ListAgentKnowledgeBasesInput) SetAgentId(v string) *ListAgentKnowledgeBasesInput { - s.AgentId = &v - return s -} - -// SetAgentVersion sets the AgentVersion field's value. -func (s *ListAgentKnowledgeBasesInput) SetAgentVersion(v string) *ListAgentKnowledgeBasesInput { - s.AgentVersion = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListAgentKnowledgeBasesInput) SetMaxResults(v int64) *ListAgentKnowledgeBasesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListAgentKnowledgeBasesInput) SetNextToken(v string) *ListAgentKnowledgeBasesInput { - s.NextToken = &v +// SetServiceConfiguration sets the ServiceConfiguration field's value. +func (s *RetrievalFlowNodeConfiguration) SetServiceConfiguration(v *RetrievalFlowNodeServiceConfiguration) *RetrievalFlowNodeConfiguration { + s.ServiceConfiguration = v return s } -type ListAgentKnowledgeBasesOutput struct { +// Contains configurations for the Amazon S3 location from which to retrieve +// data to return as the output from the node. +type RetrievalFlowNodeS3Configuration struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about a knowledge base - // associated with the agent. + // The name of the Amazon S3 bucket from which to retrieve data. // - // AgentKnowledgeBaseSummaries is a required field - AgentKnowledgeBaseSummaries []*AgentKnowledgeBaseSummary `locationName:"agentKnowledgeBaseSummaries" type:"list" required:"true"` - - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // BucketName is a required field + BucketName *string `locationName:"bucketName" min:"3" type:"string" required:"true"` } // String returns the string representation. @@ -10644,7 +21505,7 @@ type ListAgentKnowledgeBasesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentKnowledgeBasesOutput) String() string { +func (s RetrievalFlowNodeS3Configuration) String() string { return awsutil.Prettify(s) } @@ -10653,40 +21514,40 @@ func (s ListAgentKnowledgeBasesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentKnowledgeBasesOutput) GoString() string { +func (s RetrievalFlowNodeS3Configuration) GoString() string { return s.String() } -// SetAgentKnowledgeBaseSummaries sets the AgentKnowledgeBaseSummaries field's value. -func (s *ListAgentKnowledgeBasesOutput) SetAgentKnowledgeBaseSummaries(v []*AgentKnowledgeBaseSummary) *ListAgentKnowledgeBasesOutput { - s.AgentKnowledgeBaseSummaries = v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *RetrievalFlowNodeS3Configuration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RetrievalFlowNodeS3Configuration"} + if s.BucketName == nil { + invalidParams.Add(request.NewErrParamRequired("BucketName")) + } + if s.BucketName != nil && len(*s.BucketName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("BucketName", 3)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentKnowledgeBasesOutput) SetNextToken(v string) *ListAgentKnowledgeBasesOutput { - s.NextToken = &v +// SetBucketName sets the BucketName field's value. +func (s *RetrievalFlowNodeS3Configuration) SetBucketName(v string) *RetrievalFlowNodeS3Configuration { + s.BucketName = &v return s } -type ListAgentVersionsInput struct { +// Contains configurations for the service to use for retrieving data to return +// as the output from the node. +type RetrievalFlowNodeServiceConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the agent. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // Contains configurations for the Amazon S3 location from which to retrieve + // data to return as the output from the node. + S3 *RetrievalFlowNodeS3Configuration `locationName:"s3" type:"structure"` } // String returns the string representation. @@ -10694,33 +21555,26 @@ type ListAgentVersionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentVersionsInput) String() string { +func (s RetrievalFlowNodeServiceConfiguration) String() string { return awsutil.Prettify(s) } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ListAgentVersionsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListAgentVersionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListAgentVersionsInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalFlowNodeServiceConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *RetrievalFlowNodeServiceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RetrievalFlowNodeServiceConfiguration"} + if s.S3 != nil { + if err := s.S3.Validate(); err != nil { + invalidParams.AddNested("S3", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -10729,37 +21583,27 @@ func (s *ListAgentVersionsInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *ListAgentVersionsInput) SetAgentId(v string) *ListAgentVersionsInput { - s.AgentId = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListAgentVersionsInput) SetMaxResults(v int64) *ListAgentVersionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListAgentVersionsInput) SetNextToken(v string) *ListAgentVersionsInput { - s.NextToken = &v +// SetS3 sets the S3 field's value. +func (s *RetrievalFlowNodeServiceConfiguration) SetS3(v *RetrievalFlowNodeS3Configuration) *RetrievalFlowNodeServiceConfiguration { + s.S3 = v return s } -type ListAgentVersionsOutput struct { +// The configuration information to connect to Amazon S3 as your data source. +type S3DataSourceConfiguration struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about a version of - // the agent. + // The Amazon Resource Name (ARN) of the S3 bucket that contains your data. // - // AgentVersionSummaries is a required field - AgentVersionSummaries []*AgentVersionSummary `locationName:"agentVersionSummaries" type:"list" required:"true"` + // BucketArn is a required field + BucketArn *string `locationName:"bucketArn" min:"1" type:"string" required:"true"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The account ID for the owner of the S3 bucket. + BucketOwnerAccountId *string `locationName:"bucketOwnerAccountId" min:"12" type:"string"` + + // A list of S3 prefixes to include certain files or content. For more information, + // see Organizing objects using prefixes (https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-prefixes.html). + InclusionPrefixes []*string `locationName:"inclusionPrefixes" min:"1" type:"list"` } // String returns the string representation. @@ -10767,7 +21611,7 @@ type ListAgentVersionsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentVersionsOutput) String() string { +func (s S3DataSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -10776,35 +21620,59 @@ func (s ListAgentVersionsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentVersionsOutput) GoString() string { +func (s S3DataSourceConfiguration) GoString() string { return s.String() } -// SetAgentVersionSummaries sets the AgentVersionSummaries field's value. -func (s *ListAgentVersionsOutput) SetAgentVersionSummaries(v []*AgentVersionSummary) *ListAgentVersionsOutput { - s.AgentVersionSummaries = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *S3DataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "S3DataSourceConfiguration"} + if s.BucketArn == nil { + invalidParams.Add(request.NewErrParamRequired("BucketArn")) + } + if s.BucketArn != nil && len(*s.BucketArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BucketArn", 1)) + } + if s.BucketOwnerAccountId != nil && len(*s.BucketOwnerAccountId) < 12 { + invalidParams.Add(request.NewErrParamMinLen("BucketOwnerAccountId", 12)) + } + if s.InclusionPrefixes != nil && len(s.InclusionPrefixes) < 1 { + invalidParams.Add(request.NewErrParamMinLen("InclusionPrefixes", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBucketArn sets the BucketArn field's value. +func (s *S3DataSourceConfiguration) SetBucketArn(v string) *S3DataSourceConfiguration { + s.BucketArn = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentVersionsOutput) SetNextToken(v string) *ListAgentVersionsOutput { - s.NextToken = &v +// SetBucketOwnerAccountId sets the BucketOwnerAccountId field's value. +func (s *S3DataSourceConfiguration) SetBucketOwnerAccountId(v string) *S3DataSourceConfiguration { + s.BucketOwnerAccountId = &v return s } -type ListAgentsInput struct { +// SetInclusionPrefixes sets the InclusionPrefixes field's value. +func (s *S3DataSourceConfiguration) SetInclusionPrefixes(v []*string) *S3DataSourceConfiguration { + s.InclusionPrefixes = v + return s +} + +// The identifier information for an Amazon S3 bucket. +type S3Identifier struct { _ struct{} `type:"structure"` - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + // The name of the S3 bucket. + S3BucketName *string `locationName:"s3BucketName" min:"3" 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The S3 object key for the S3 resource. + S3ObjectKey *string `locationName:"s3ObjectKey" min:"1" type:"string"` } // String returns the string representation. @@ -10812,7 +21680,7 @@ type ListAgentsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentsInput) String() string { +func (s S3Identifier) String() string { return awsutil.Prettify(s) } @@ -10821,18 +21689,18 @@ func (s ListAgentsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentsInput) GoString() string { +func (s S3Identifier) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListAgentsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListAgentsInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) +func (s *S3Identifier) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "S3Identifier"} + if s.S3BucketName != nil && len(*s.S3BucketName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("S3BucketName", 3)) } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + if s.S3ObjectKey != nil && len(*s.S3ObjectKey) < 1 { + invalidParams.Add(request.NewErrParamMinLen("S3ObjectKey", 1)) } if invalidParams.Len() > 0 { @@ -10841,30 +21709,26 @@ func (s *ListAgentsInput) Validate() error { return nil } -// SetMaxResults sets the MaxResults field's value. -func (s *ListAgentsInput) SetMaxResults(v int64) *ListAgentsInput { - s.MaxResults = &v +// SetS3BucketName sets the S3BucketName field's value. +func (s *S3Identifier) SetS3BucketName(v string) *S3Identifier { + s.S3BucketName = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentsInput) SetNextToken(v string) *ListAgentsInput { - s.NextToken = &v +// SetS3ObjectKey sets the S3ObjectKey field's value. +func (s *S3Identifier) SetS3ObjectKey(v string) *S3Identifier { + s.S3ObjectKey = &v return s } -type ListAgentsOutput struct { +// An Amazon S3 location. +type S3Location struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about an agent. + // The location's URI. For example, s3://my-bucket/chunk-processor/. // - // AgentSummaries is a required field - AgentSummaries []*AgentSummary `locationName:"agentSummaries" type:"list" required:"true"` - - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // Uri is a required field + Uri *string `locationName:"uri" min:"1" type:"string" required:"true"` } // String returns the string representation. @@ -10872,7 +21736,7 @@ type ListAgentsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentsOutput) String() string { +func (s S3Location) String() string { return awsutil.Prettify(s) } @@ -10881,41 +21745,40 @@ func (s ListAgentsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListAgentsOutput) GoString() string { +func (s S3Location) GoString() string { return s.String() } -// SetAgentSummaries sets the AgentSummaries field's value. -func (s *ListAgentsOutput) SetAgentSummaries(v []*AgentSummary) *ListAgentsOutput { - s.AgentSummaries = v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *S3Location) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "S3Location"} + if s.Uri == nil { + invalidParams.Add(request.NewErrParamRequired("Uri")) + } + if s.Uri != nil && len(*s.Uri) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Uri", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetNextToken sets the NextToken field's value. -func (s *ListAgentsOutput) SetNextToken(v string) *ListAgentsOutput { - s.NextToken = &v +// SetUri sets the Uri field's value. +func (s *S3Location) SetUri(v string) *S3Location { + s.Uri = &v return s } -type ListDataSourcesInput struct { +// The configuration of the Salesforce content. For example, configuring specific +// types of Salesforce content. +type SalesforceCrawlerConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the knowledge base for which to return a list of - // information. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` - - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The configuration of filtering the Salesforce content. For example, configuring + // regular expression patterns to include or exclude certain content. + FilterConfiguration *CrawlFilterConfiguration `locationName:"filterConfiguration" type:"structure"` } // String returns the string representation. @@ -10923,7 +21786,7 @@ type ListDataSourcesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDataSourcesInput) String() string { +func (s SalesforceCrawlerConfiguration) String() string { return awsutil.Prettify(s) } @@ -10932,24 +21795,17 @@ func (s ListDataSourcesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDataSourcesInput) GoString() string { +func (s SalesforceCrawlerConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListDataSourcesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListDataSourcesInput"} - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +func (s *SalesforceCrawlerConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SalesforceCrawlerConfiguration"} + if s.FilterConfiguration != nil { + if err := s.FilterConfiguration.Validate(); err != nil { + invalidParams.AddNested("FilterConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -10958,36 +21814,24 @@ func (s *ListDataSourcesInput) Validate() error { return nil } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *ListDataSourcesInput) SetKnowledgeBaseId(v string) *ListDataSourcesInput { - s.KnowledgeBaseId = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListDataSourcesInput) SetMaxResults(v int64) *ListDataSourcesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListDataSourcesInput) SetNextToken(v string) *ListDataSourcesInput { - s.NextToken = &v +// SetFilterConfiguration sets the FilterConfiguration field's value. +func (s *SalesforceCrawlerConfiguration) SetFilterConfiguration(v *CrawlFilterConfiguration) *SalesforceCrawlerConfiguration { + s.FilterConfiguration = v return s } -type ListDataSourcesOutput struct { +// The configuration information to connect to Salesforce as your data source. +type SalesforceDataSourceConfiguration struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about a data source. - // - // DataSourceSummaries is a required field - DataSourceSummaries []*DataSourceSummary `locationName:"dataSourceSummaries" type:"list" required:"true"` + // The configuration of the Salesforce content. For example, configuring specific + // types of Salesforce content. + CrawlerConfiguration *SalesforceCrawlerConfiguration `locationName:"crawlerConfiguration" type:"structure"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The endpoint information to connect to your Salesforce data source. + // + // SourceConfiguration is a required field + SourceConfiguration *SalesforceSourceConfiguration `locationName:"sourceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -10995,7 +21839,7 @@ type ListDataSourcesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDataSourcesOutput) String() string { +func (s SalesforceDataSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -11004,52 +21848,67 @@ func (s ListDataSourcesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDataSourcesOutput) GoString() string { +func (s SalesforceDataSourceConfiguration) GoString() string { return s.String() } -// SetDataSourceSummaries sets the DataSourceSummaries field's value. -func (s *ListDataSourcesOutput) SetDataSourceSummaries(v []*DataSourceSummary) *ListDataSourcesOutput { - s.DataSourceSummaries = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *SalesforceDataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SalesforceDataSourceConfiguration"} + if s.SourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("SourceConfiguration")) + } + if s.CrawlerConfiguration != nil { + if err := s.CrawlerConfiguration.Validate(); err != nil { + invalidParams.AddNested("CrawlerConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SourceConfiguration != nil { + if err := s.SourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SourceConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCrawlerConfiguration sets the CrawlerConfiguration field's value. +func (s *SalesforceDataSourceConfiguration) SetCrawlerConfiguration(v *SalesforceCrawlerConfiguration) *SalesforceDataSourceConfiguration { + s.CrawlerConfiguration = v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListDataSourcesOutput) SetNextToken(v string) *ListDataSourcesOutput { - s.NextToken = &v +// SetSourceConfiguration sets the SourceConfiguration field's value. +func (s *SalesforceDataSourceConfiguration) SetSourceConfiguration(v *SalesforceSourceConfiguration) *SalesforceDataSourceConfiguration { + s.SourceConfiguration = v return s } -type ListIngestionJobsInput struct { +// The endpoint information to connect to your Salesforce data source. +type SalesforceSourceConfiguration struct { _ struct{} `type:"structure"` - // The unique identifier of the data source for which to return ingestion jobs. - // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` - - // Contains a definition of a filter for which to filter the results. - Filters []*IngestionJobFilter `locationName:"filters" min:"1" type:"list"` - - // The unique identifier of the knowledge base for which to return ingestion - // jobs. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` - - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The supported authentication type to authenticate and connect to your Salesforce + // instance. + // + // AuthType is a required field + AuthType *string `locationName:"authType" type:"string" required:"true" enum:"SalesforceAuthType"` - // Contains details about how to sort the results. - SortBy *IngestionJobSortBy `locationName:"sortBy" type:"structure"` + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/salesforce-data-source-connector.html#configuration-salesforce-connector). + // + // CredentialsSecretArn is a required field + CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` + + // The Salesforce host URL or instance URL. + // + // HostUrl is a required field + HostUrl *string `locationName:"hostUrl" type:"string" required:"true"` } // String returns the string representation. @@ -11057,7 +21916,7 @@ type ListIngestionJobsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListIngestionJobsInput) String() string { +func (s SalesforceSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -11066,48 +21925,21 @@ func (s ListIngestionJobsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListIngestionJobsInput) GoString() string { +func (s SalesforceSourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListIngestionJobsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListIngestionJobsInput"} - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) - } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) - } - if s.Filters != nil && len(s.Filters) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Filters", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +func (s *SalesforceSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SalesforceSourceConfiguration"} + if s.AuthType == nil { + invalidParams.Add(request.NewErrParamRequired("AuthType")) } - if s.Filters != nil { - for i, v := range s.Filters { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) - } - } + if s.CredentialsSecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) } - if s.SortBy != nil { - if err := s.SortBy.Validate(); err != nil { - invalidParams.AddNested("SortBy", err.(request.ErrInvalidParams)) - } + if s.HostUrl == nil { + invalidParams.Add(request.NewErrParamRequired("HostUrl")) } if invalidParams.Len() > 0 { @@ -11116,55 +21948,91 @@ func (s *ListIngestionJobsInput) Validate() error { return nil } -// SetDataSourceId sets the DataSourceId field's value. -func (s *ListIngestionJobsInput) SetDataSourceId(v string) *ListIngestionJobsInput { - s.DataSourceId = &v +// SetAuthType sets the AuthType field's value. +func (s *SalesforceSourceConfiguration) SetAuthType(v string) *SalesforceSourceConfiguration { + s.AuthType = &v return s } -// SetFilters sets the Filters field's value. -func (s *ListIngestionJobsInput) SetFilters(v []*IngestionJobFilter) *ListIngestionJobsInput { - s.Filters = v +// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. +func (s *SalesforceSourceConfiguration) SetCredentialsSecretArn(v string) *SalesforceSourceConfiguration { + s.CredentialsSecretArn = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *ListIngestionJobsInput) SetKnowledgeBaseId(v string) *ListIngestionJobsInput { - s.KnowledgeBaseId = &v +// SetHostUrl sets the HostUrl field's value. +func (s *SalesforceSourceConfiguration) SetHostUrl(v string) *SalesforceSourceConfiguration { + s.HostUrl = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListIngestionJobsInput) SetMaxResults(v int64) *ListIngestionJobsInput { - s.MaxResults = &v - return s +// The seed or starting point URL. You should be authorized to crawl the URL. +type SeedUrl struct { + _ struct{} `type:"structure"` + + // A seed or starting point URL. + Url *string `locationName:"url" type:"string"` } -// SetNextToken sets the NextToken field's value. -func (s *ListIngestionJobsInput) SetNextToken(v string) *ListIngestionJobsInput { - s.NextToken = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s SeedUrl) String() string { + return awsutil.Prettify(s) } -// SetSortBy sets the SortBy field's value. -func (s *ListIngestionJobsInput) SetSortBy(v *IngestionJobSortBy) *ListIngestionJobsInput { - s.SortBy = v +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s SeedUrl) GoString() string { + return s.String() +} + +// SetUrl sets the Url field's value. +func (s *SeedUrl) SetUrl(v string) *SeedUrl { + s.Url = &v return s } -type ListIngestionJobsOutput struct { +// 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. +type SemanticChunkingConfiguration struct { _ struct{} `type:"structure"` - // A list of objects, each of which contains information about an ingestion - // job. + // The dissimilarity threshold for splitting chunks. // - // IngestionJobSummaries is a required field - IngestionJobSummaries []*IngestionJobSummary `locationName:"ingestionJobSummaries" type:"list" required:"true"` + // BreakpointPercentileThreshold is a required field + BreakpointPercentileThreshold *int64 `locationName:"breakpointPercentileThreshold" min:"50" type:"integer" required:"true"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The buffer size. + // + // BufferSize is a required field + BufferSize *int64 `locationName:"bufferSize" type:"integer" required:"true"` + + // The maximum number of tokens that a chunk can contain. + // + // MaxTokens is a required field + MaxTokens *int64 `locationName:"maxTokens" min:"1" type:"integer" required:"true"` } // String returns the string representation. @@ -11172,7 +22040,7 @@ type ListIngestionJobsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListIngestionJobsOutput) String() string { +func (s SemanticChunkingConfiguration) String() string { return awsutil.Prettify(s) } @@ -11181,35 +22049,59 @@ func (s ListIngestionJobsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListIngestionJobsOutput) GoString() string { +func (s SemanticChunkingConfiguration) GoString() string { return s.String() } -// SetIngestionJobSummaries sets the IngestionJobSummaries field's value. -func (s *ListIngestionJobsOutput) SetIngestionJobSummaries(v []*IngestionJobSummary) *ListIngestionJobsOutput { - s.IngestionJobSummaries = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *SemanticChunkingConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SemanticChunkingConfiguration"} + if s.BreakpointPercentileThreshold == nil { + invalidParams.Add(request.NewErrParamRequired("BreakpointPercentileThreshold")) + } + if s.BreakpointPercentileThreshold != nil && *s.BreakpointPercentileThreshold < 50 { + invalidParams.Add(request.NewErrParamMinValue("BreakpointPercentileThreshold", 50)) + } + if s.BufferSize == nil { + invalidParams.Add(request.NewErrParamRequired("BufferSize")) + } + if s.MaxTokens == nil { + invalidParams.Add(request.NewErrParamRequired("MaxTokens")) + } + if s.MaxTokens != nil && *s.MaxTokens < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxTokens", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBreakpointPercentileThreshold sets the BreakpointPercentileThreshold field's value. +func (s *SemanticChunkingConfiguration) SetBreakpointPercentileThreshold(v int64) *SemanticChunkingConfiguration { + s.BreakpointPercentileThreshold = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListIngestionJobsOutput) SetNextToken(v string) *ListIngestionJobsOutput { - s.NextToken = &v +// SetBufferSize sets the BufferSize field's value. +func (s *SemanticChunkingConfiguration) SetBufferSize(v int64) *SemanticChunkingConfiguration { + s.BufferSize = &v return s } -type ListKnowledgeBasesInput struct { - _ struct{} `type:"structure"` +// SetMaxTokens sets the MaxTokens field's value. +func (s *SemanticChunkingConfiguration) SetMaxTokens(v int64) *SemanticChunkingConfiguration { + s.MaxTokens = &v + return s +} - // 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. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` +// Contains the configuration for server-side encryption. +type ServerSideEncryptionConfiguration struct { + _ struct{} `type:"structure"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the KMS key used to encrypt the resource. + KmsKeyArn *string `locationName:"kmsKeyArn" min:"1" type:"string"` } // String returns the string representation. @@ -11217,7 +22109,7 @@ type ListKnowledgeBasesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListKnowledgeBasesInput) String() string { +func (s ServerSideEncryptionConfiguration) String() string { return awsutil.Prettify(s) } @@ -11226,18 +22118,15 @@ func (s ListKnowledgeBasesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListKnowledgeBasesInput) GoString() string { +func (s ServerSideEncryptionConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListKnowledgeBasesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListKnowledgeBasesInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +func (s *ServerSideEncryptionConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ServerSideEncryptionConfiguration"} + if s.KmsKeyArn != nil && len(*s.KmsKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KmsKeyArn", 1)) } if invalidParams.Len() > 0 { @@ -11246,30 +22135,18 @@ func (s *ListKnowledgeBasesInput) Validate() error { return nil } -// SetMaxResults sets the MaxResults field's value. -func (s *ListKnowledgeBasesInput) SetMaxResults(v int64) *ListKnowledgeBasesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListKnowledgeBasesInput) SetNextToken(v string) *ListKnowledgeBasesInput { - s.NextToken = &v +// SetKmsKeyArn sets the KmsKeyArn field's value. +func (s *ServerSideEncryptionConfiguration) SetKmsKeyArn(v string) *ServerSideEncryptionConfiguration { + s.KmsKeyArn = &v return s } -type ListKnowledgeBasesOutput struct { - _ struct{} `type:"structure"` - - // A list of objects, each of which contains information about a knowledge base. - // - // KnowledgeBaseSummaries is a required field - KnowledgeBaseSummaries []*KnowledgeBaseSummary `locationName:"knowledgeBaseSummaries" type:"list" required:"true"` +// The number of requests exceeds the service quota. Resubmit your request later. +type ServiceQuotaExceededException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // 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. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -11277,7 +22154,7 @@ type ListKnowledgeBasesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListKnowledgeBasesOutput) String() string { +func (s ServiceQuotaExceededException) String() string { return awsutil.Prettify(s) } @@ -11286,29 +22163,56 @@ func (s ListKnowledgeBasesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListKnowledgeBasesOutput) GoString() string { +func (s ServiceQuotaExceededException) GoString() string { return s.String() } -// SetKnowledgeBaseSummaries sets the KnowledgeBaseSummaries field's value. -func (s *ListKnowledgeBasesOutput) SetKnowledgeBaseSummaries(v []*KnowledgeBaseSummary) *ListKnowledgeBasesOutput { - s.KnowledgeBaseSummaries = v - return s +func newErrorServiceQuotaExceededException(v protocol.ResponseMetadata) error { + return &ServiceQuotaExceededException{ + RespMetadata: v, + } } -// SetNextToken sets the NextToken field's value. -func (s *ListKnowledgeBasesOutput) SetNextToken(v string) *ListKnowledgeBasesOutput { - s.NextToken = &v - return s +// Code returns the exception type name. +func (s *ServiceQuotaExceededException) Code() string { + return "ServiceQuotaExceededException" } -type ListTagsForResourceInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// Message returns the exception's message. +func (s *ServiceQuotaExceededException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} - // The Amazon Resource Name (ARN) of the resource for which to list tags. - // - // ResourceArn is a required field - ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ServiceQuotaExceededException) OrigErr() error { + return nil +} + +func (s *ServiceQuotaExceededException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *ServiceQuotaExceededException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *ServiceQuotaExceededException) RequestID() string { + return s.RespMetadata.RequestID +} + +// The configuration of the SharePoint content. For example, configuring specific +// types of SharePoint content. +type SharePointCrawlerConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration of filtering the SharePoint content. For example, configuring + // regular expression patterns to include or exclude certain content. + FilterConfiguration *CrawlFilterConfiguration `locationName:"filterConfiguration" type:"structure"` } // String returns the string representation. @@ -11316,7 +22220,7 @@ type ListTagsForResourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceInput) String() string { +func (s SharePointCrawlerConfiguration) String() string { return awsutil.Prettify(s) } @@ -11325,18 +22229,17 @@ func (s ListTagsForResourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceInput) GoString() string { +func (s SharePointCrawlerConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListTagsForResourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} - if s.ResourceArn == nil { - invalidParams.Add(request.NewErrParamRequired("ResourceArn")) - } - if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { - invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) +func (s *SharePointCrawlerConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SharePointCrawlerConfiguration"} + if s.FilterConfiguration != nil { + if err := s.FilterConfiguration.Validate(); err != nil { + invalidParams.AddNested("FilterConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -11345,17 +22248,24 @@ func (s *ListTagsForResourceInput) Validate() error { return nil } -// SetResourceArn sets the ResourceArn field's value. -func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { - s.ResourceArn = &v +// SetFilterConfiguration sets the FilterConfiguration field's value. +func (s *SharePointCrawlerConfiguration) SetFilterConfiguration(v *CrawlFilterConfiguration) *SharePointCrawlerConfiguration { + s.FilterConfiguration = v return s } -type ListTagsForResourceOutput struct { +// The configuration information to connect to SharePoint as your data source. +type SharePointDataSourceConfiguration struct { _ struct{} `type:"structure"` - // The key-value pairs for the tags associated with the resource. - Tags map[string]*string `locationName:"tags" type:"map"` + // The configuration of the SharePoint content. For example, configuring specific + // types of SharePoint content. + CrawlerConfiguration *SharePointCrawlerConfiguration `locationName:"crawlerConfiguration" type:"structure"` + + // The endpoint information to connect to your SharePoint data source. + // + // SourceConfiguration is a required field + SourceConfiguration *SharePointSourceConfiguration `locationName:"sourceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -11363,7 +22273,7 @@ type ListTagsForResourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceOutput) String() string { +func (s SharePointDataSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -11372,56 +22282,80 @@ func (s ListTagsForResourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceOutput) GoString() string { +func (s SharePointDataSourceConfiguration) GoString() string { return s.String() } -// SetTags sets the Tags field's value. -func (s *ListTagsForResourceOutput) SetTags(v map[string]*string) *ListTagsForResourceOutput { - s.Tags = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *SharePointDataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SharePointDataSourceConfiguration"} + if s.SourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("SourceConfiguration")) + } + if s.CrawlerConfiguration != nil { + if err := s.CrawlerConfiguration.Validate(); err != nil { + invalidParams.AddNested("CrawlerConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SourceConfiguration != nil { + if err := s.SourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SourceConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCrawlerConfiguration sets the CrawlerConfiguration field's value. +func (s *SharePointDataSourceConfiguration) SetCrawlerConfiguration(v *SharePointCrawlerConfiguration) *SharePointDataSourceConfiguration { + s.CrawlerConfiguration = v return s } -// Contains details about the storage configuration of the knowledge base in -// MongoDB Atlas. -type MongoDbAtlasConfiguration struct { +// SetSourceConfiguration sets the SourceConfiguration field's value. +func (s *SharePointDataSourceConfiguration) SetSourceConfiguration(v *SharePointSourceConfiguration) *SharePointDataSourceConfiguration { + s.SourceConfiguration = v + return s +} + +// The endpoint information to connect to your SharePoint data source. +type SharePointSourceConfiguration struct { _ struct{} `type:"structure"` - // The collection name of the knowledge base in MongoDB Atlas. + // The supported authentication type to authenticate and connect to your SharePoint + // site/sites. // - // CollectionName is a required field - CollectionName *string `locationName:"collectionName" type:"string" required:"true"` + // AuthType is a required field + AuthType *string `locationName:"authType" type:"string" required:"true" enum:"SharePointAuthType"` - // The Amazon Resource Name (ARN) of the secret that you created in Secrets - // Manager that contains user credentials for your MongoDB Atlas cluster. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/sharepoint-data-source-connector.html#configuration-sharepoint-connector). // // CredentialsSecretArn is a required field CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` - // The database name in your MongoDB Atlas cluster for your knowledge base. + // The domain of your SharePoint instance or site URL/URLs. // - // DatabaseName is a required field - DatabaseName *string `locationName:"databaseName" type:"string" required:"true"` + // Domain is a required field + Domain *string `locationName:"domain" min:"1" type:"string" required:"true"` - // The endpoint URL of your MongoDB Atlas cluster for your knowledge base. + // The supported host type, whether online/cloud or server/on-premises. // - // Endpoint is a required field - Endpoint *string `locationName:"endpoint" type:"string" required:"true"` - - // The name of the VPC endpoint service in your account that is connected to - // your MongoDB Atlas cluster. - EndpointServiceName *string `locationName:"endpointServiceName" min:"1" type:"string"` + // HostType is a required field + HostType *string `locationName:"hostType" type:"string" required:"true" enum:"SharePointHostType"` - // Contains the names of the fields to which to map information about the vector - // store. + // A list of one or more SharePoint site URLs. // - // FieldMapping is a required field - FieldMapping *MongoDbAtlasFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + // SiteUrls is a required field + SiteUrls []*string `locationName:"siteUrls" min:"1" type:"list" required:"true"` - // The name of the MongoDB Atlas vector search index. - // - // VectorIndexName is a required field - VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` + // The identifier of your Microsoft 365 tenant. + TenantId *string `locationName:"tenantId" min:"36" type:"string"` } // String returns the string representation. @@ -11429,7 +22363,7 @@ type MongoDbAtlasConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s MongoDbAtlasConfiguration) String() string { +func (s SharePointSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -11438,38 +22372,36 @@ func (s MongoDbAtlasConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s MongoDbAtlasConfiguration) GoString() string { +func (s SharePointSourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *MongoDbAtlasConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "MongoDbAtlasConfiguration"} - if s.CollectionName == nil { - invalidParams.Add(request.NewErrParamRequired("CollectionName")) +func (s *SharePointSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "SharePointSourceConfiguration"} + if s.AuthType == nil { + invalidParams.Add(request.NewErrParamRequired("AuthType")) } if s.CredentialsSecretArn == nil { invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) } - if s.DatabaseName == nil { - invalidParams.Add(request.NewErrParamRequired("DatabaseName")) + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) } - if s.Endpoint == nil { - invalidParams.Add(request.NewErrParamRequired("Endpoint")) + if s.Domain != nil && len(*s.Domain) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 1)) } - if s.EndpointServiceName != nil && len(*s.EndpointServiceName) < 1 { - invalidParams.Add(request.NewErrParamMinLen("EndpointServiceName", 1)) + if s.HostType == nil { + invalidParams.Add(request.NewErrParamRequired("HostType")) } - if s.FieldMapping == nil { - invalidParams.Add(request.NewErrParamRequired("FieldMapping")) + if s.SiteUrls == nil { + invalidParams.Add(request.NewErrParamRequired("SiteUrls")) } - if s.VectorIndexName == nil { - invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) + if s.SiteUrls != nil && len(s.SiteUrls) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SiteUrls", 1)) } - if s.FieldMapping != nil { - if err := s.FieldMapping.Validate(); err != nil { - invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) - } + if s.TenantId != nil && len(*s.TenantId) < 36 { + invalidParams.Add(request.NewErrParamMinLen("TenantId", 36)) } if invalidParams.Len() > 0 { @@ -11478,70 +22410,63 @@ func (s *MongoDbAtlasConfiguration) Validate() error { return nil } -// SetCollectionName sets the CollectionName field's value. -func (s *MongoDbAtlasConfiguration) SetCollectionName(v string) *MongoDbAtlasConfiguration { - s.CollectionName = &v +// SetAuthType sets the AuthType field's value. +func (s *SharePointSourceConfiguration) SetAuthType(v string) *SharePointSourceConfiguration { + s.AuthType = &v return s } // SetCredentialsSecretArn sets the CredentialsSecretArn field's value. -func (s *MongoDbAtlasConfiguration) SetCredentialsSecretArn(v string) *MongoDbAtlasConfiguration { +func (s *SharePointSourceConfiguration) SetCredentialsSecretArn(v string) *SharePointSourceConfiguration { s.CredentialsSecretArn = &v return s } -// SetDatabaseName sets the DatabaseName field's value. -func (s *MongoDbAtlasConfiguration) SetDatabaseName(v string) *MongoDbAtlasConfiguration { - s.DatabaseName = &v - return s -} - -// SetEndpoint sets the Endpoint field's value. -func (s *MongoDbAtlasConfiguration) SetEndpoint(v string) *MongoDbAtlasConfiguration { - s.Endpoint = &v +// SetDomain sets the Domain field's value. +func (s *SharePointSourceConfiguration) SetDomain(v string) *SharePointSourceConfiguration { + s.Domain = &v return s } -// SetEndpointServiceName sets the EndpointServiceName field's value. -func (s *MongoDbAtlasConfiguration) SetEndpointServiceName(v string) *MongoDbAtlasConfiguration { - s.EndpointServiceName = &v +// SetHostType sets the HostType field's value. +func (s *SharePointSourceConfiguration) SetHostType(v string) *SharePointSourceConfiguration { + s.HostType = &v return s } -// SetFieldMapping sets the FieldMapping field's value. -func (s *MongoDbAtlasConfiguration) SetFieldMapping(v *MongoDbAtlasFieldMapping) *MongoDbAtlasConfiguration { - s.FieldMapping = v +// SetSiteUrls sets the SiteUrls field's value. +func (s *SharePointSourceConfiguration) SetSiteUrls(v []*string) *SharePointSourceConfiguration { + s.SiteUrls = v return s } -// SetVectorIndexName sets the VectorIndexName field's value. -func (s *MongoDbAtlasConfiguration) SetVectorIndexName(v string) *MongoDbAtlasConfiguration { - s.VectorIndexName = &v +// SetTenantId sets the TenantId field's value. +func (s *SharePointSourceConfiguration) SetTenantId(v string) *SharePointSourceConfiguration { + s.TenantId = &v return s } -// Contains the names of the fields to which to map information about the vector -// store. -type MongoDbAtlasFieldMapping struct { +type StartIngestionJobInput struct { _ struct{} `type:"structure"` - // The name of the field in which Amazon Bedrock stores metadata about the vector - // store. - // - // MetadataField is a required field - MetadataField *string `locationName:"metadataField" type:"string" required:"true"` + // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` - // 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. + // The unique identifier of the data source to ingest. // - // TextField is a required field - TextField *string `locationName:"textField" type:"string" required:"true"` + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` - // The name of the field in which Amazon Bedrock stores the vector embeddings - // for your data sources. + // A description of the ingestion job. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base to which to add the data source. // - // VectorField is a required field - VectorField *string `locationName:"vectorField" type:"string" required:"true"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` } // String returns the string representation. @@ -11549,7 +22474,7 @@ type MongoDbAtlasFieldMapping struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s MongoDbAtlasFieldMapping) String() string { +func (s StartIngestionJobInput) String() string { return awsutil.Prettify(s) } @@ -11558,21 +22483,30 @@ func (s MongoDbAtlasFieldMapping) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s MongoDbAtlasFieldMapping) GoString() string { +func (s StartIngestionJobInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *MongoDbAtlasFieldMapping) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "MongoDbAtlasFieldMapping"} - if s.MetadataField == nil { - invalidParams.Add(request.NewErrParamRequired("MetadataField")) +func (s *StartIngestionJobInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StartIngestionJobInput"} + if s.ClientToken != nil && len(*s.ClientToken) < 33 { + invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) } - if s.TextField == nil { - invalidParams.Add(request.NewErrParamRequired("TextField")) + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) } - if s.VectorField == nil { - invalidParams.Add(request.NewErrParamRequired("VectorField")) + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) } if invalidParams.Len() > 0 { @@ -11581,45 +22515,37 @@ func (s *MongoDbAtlasFieldMapping) Validate() error { return nil } -// SetMetadataField sets the MetadataField field's value. -func (s *MongoDbAtlasFieldMapping) SetMetadataField(v string) *MongoDbAtlasFieldMapping { - s.MetadataField = &v +// SetClientToken sets the ClientToken field's value. +func (s *StartIngestionJobInput) SetClientToken(v string) *StartIngestionJobInput { + s.ClientToken = &v return s } -// SetTextField sets the TextField field's value. -func (s *MongoDbAtlasFieldMapping) SetTextField(v string) *MongoDbAtlasFieldMapping { - s.TextField = &v +// SetDataSourceId sets the DataSourceId field's value. +func (s *StartIngestionJobInput) SetDataSourceId(v string) *StartIngestionJobInput { + s.DataSourceId = &v return s } -// SetVectorField sets the VectorField field's value. -func (s *MongoDbAtlasFieldMapping) SetVectorField(v string) *MongoDbAtlasFieldMapping { - s.VectorField = &v +// SetDescription sets the Description field's value. +func (s *StartIngestionJobInput) SetDescription(v string) *StartIngestionJobInput { + s.Description = &v return s } -// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). -type OpenSearchServerlessConfiguration struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the OpenSearch Service vector store. - // - // CollectionArn is a required field - CollectionArn *string `locationName:"collectionArn" type:"string" required:"true"` +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *StartIngestionJobInput) SetKnowledgeBaseId(v string) *StartIngestionJobInput { + s.KnowledgeBaseId = &v + return s +} - // Contains the names of the fields to which to map information about the vector - // store. - // - // FieldMapping is a required field - FieldMapping *OpenSearchServerlessFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` +type StartIngestionJobOutput struct { + _ struct{} `type:"structure"` - // The name of the vector store. + // An object containing information about the ingestion job. // - // VectorIndexName is a required field - VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` + // IngestionJob is a required field + IngestionJob *IngestionJob `locationName:"ingestionJob" type:"structure" required:"true"` } // String returns the string representation. @@ -11627,7 +22553,7 @@ type OpenSearchServerlessConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s OpenSearchServerlessConfiguration) String() string { +func (s StartIngestionJobOutput) String() string { return awsutil.Prettify(s) } @@ -11636,74 +22562,43 @@ func (s OpenSearchServerlessConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s OpenSearchServerlessConfiguration) GoString() string { +func (s StartIngestionJobOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *OpenSearchServerlessConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "OpenSearchServerlessConfiguration"} - if s.CollectionArn == nil { - invalidParams.Add(request.NewErrParamRequired("CollectionArn")) - } - if s.FieldMapping == nil { - invalidParams.Add(request.NewErrParamRequired("FieldMapping")) - } - if s.VectorIndexName == nil { - invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) - } - if s.FieldMapping != nil { - if err := s.FieldMapping.Validate(); err != nil { - invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCollectionArn sets the CollectionArn field's value. -func (s *OpenSearchServerlessConfiguration) SetCollectionArn(v string) *OpenSearchServerlessConfiguration { - s.CollectionArn = &v +// SetIngestionJob sets the IngestionJob field's value. +func (s *StartIngestionJobOutput) SetIngestionJob(v *IngestionJob) *StartIngestionJobOutput { + s.IngestionJob = v return s } -// SetFieldMapping sets the FieldMapping field's value. -func (s *OpenSearchServerlessConfiguration) SetFieldMapping(v *OpenSearchServerlessFieldMapping) *OpenSearchServerlessConfiguration { - s.FieldMapping = v - return s -} +// Contains the storage configuration of the knowledge base. +type StorageConfiguration struct { + _ struct{} `type:"structure"` -// SetVectorIndexName sets the VectorIndexName field's value. -func (s *OpenSearchServerlessConfiguration) SetVectorIndexName(v string) *OpenSearchServerlessConfiguration { - s.VectorIndexName = &v - return s -} + // Contains the storage configuration of the knowledge base in MongoDB Atlas. + MongoDbAtlasConfiguration *MongoDbAtlasConfiguration `locationName:"mongoDbAtlasConfiguration" type:"structure"` -// Contains the names of the fields to which to map information about the vector -// store. -type OpenSearchServerlessFieldMapping struct { - _ struct{} `type:"structure"` + // Contains the storage configuration of the knowledge base in Amazon OpenSearch + // Service. + OpensearchServerlessConfiguration *OpenSearchServerlessConfiguration `locationName:"opensearchServerlessConfiguration" type:"structure"` - // The name of the field in which Amazon Bedrock stores metadata about the vector - // store. - // - // MetadataField is a required field - MetadataField *string `locationName:"metadataField" type:"string" required:"true"` + // Contains the storage configuration of the knowledge base in Pinecone. + PineconeConfiguration *PineconeConfiguration `locationName:"pineconeConfiguration" type:"structure"` - // 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. - // - // TextField is a required field - TextField *string `locationName:"textField" type:"string" required:"true"` + // Contains details about the storage configuration of the knowledge base in + // Amazon RDS. For more information, see Create a vector index in Amazon RDS + // (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). + RdsConfiguration *RdsConfiguration `locationName:"rdsConfiguration" type:"structure"` - // The name of the field in which Amazon Bedrock stores the vector embeddings - // for your data sources. + // Contains the storage configuration of the knowledge base in Redis Enterprise + // Cloud. + RedisEnterpriseCloudConfiguration *RedisEnterpriseCloudConfiguration `locationName:"redisEnterpriseCloudConfiguration" type:"structure"` + + // The vector store service in which the knowledge base is stored. // - // VectorField is a required field - VectorField *string `locationName:"vectorField" type:"string" required:"true"` + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"KnowledgeBaseStorageType"` } // String returns the string representation. @@ -11711,7 +22606,7 @@ type OpenSearchServerlessFieldMapping struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s OpenSearchServerlessFieldMapping) String() string { +func (s StorageConfiguration) String() string { return awsutil.Prettify(s) } @@ -11720,21 +22615,40 @@ func (s OpenSearchServerlessFieldMapping) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s OpenSearchServerlessFieldMapping) GoString() string { +func (s StorageConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *OpenSearchServerlessFieldMapping) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "OpenSearchServerlessFieldMapping"} - if s.MetadataField == nil { - invalidParams.Add(request.NewErrParamRequired("MetadataField")) +func (s *StorageConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StorageConfiguration"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) } - if s.TextField == nil { - invalidParams.Add(request.NewErrParamRequired("TextField")) + if s.MongoDbAtlasConfiguration != nil { + if err := s.MongoDbAtlasConfiguration.Validate(); err != nil { + invalidParams.AddNested("MongoDbAtlasConfiguration", err.(request.ErrInvalidParams)) + } } - if s.VectorField == nil { - invalidParams.Add(request.NewErrParamRequired("VectorField")) + if s.OpensearchServerlessConfiguration != nil { + if err := s.OpensearchServerlessConfiguration.Validate(); err != nil { + invalidParams.AddNested("OpensearchServerlessConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.PineconeConfiguration != nil { + if err := s.PineconeConfiguration.Validate(); err != nil { + invalidParams.AddNested("PineconeConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.RdsConfiguration != nil { + if err := s.RdsConfiguration.Validate(); err != nil { + invalidParams.AddNested("RdsConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.RedisEnterpriseCloudConfiguration != nil { + if err := s.RedisEnterpriseCloudConfiguration.Validate(); err != nil { + invalidParams.AddNested("RedisEnterpriseCloudConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -11743,52 +22657,52 @@ func (s *OpenSearchServerlessFieldMapping) Validate() error { return nil } -// SetMetadataField sets the MetadataField field's value. -func (s *OpenSearchServerlessFieldMapping) SetMetadataField(v string) *OpenSearchServerlessFieldMapping { - s.MetadataField = &v +// SetMongoDbAtlasConfiguration sets the MongoDbAtlasConfiguration field's value. +func (s *StorageConfiguration) SetMongoDbAtlasConfiguration(v *MongoDbAtlasConfiguration) *StorageConfiguration { + s.MongoDbAtlasConfiguration = v return s } -// SetTextField sets the TextField field's value. -func (s *OpenSearchServerlessFieldMapping) SetTextField(v string) *OpenSearchServerlessFieldMapping { - s.TextField = &v +// SetOpensearchServerlessConfiguration sets the OpensearchServerlessConfiguration field's value. +func (s *StorageConfiguration) SetOpensearchServerlessConfiguration(v *OpenSearchServerlessConfiguration) *StorageConfiguration { + s.OpensearchServerlessConfiguration = v return s } -// SetVectorField sets the VectorField field's value. -func (s *OpenSearchServerlessFieldMapping) SetVectorField(v string) *OpenSearchServerlessFieldMapping { - s.VectorField = &v +// SetPineconeConfiguration sets the PineconeConfiguration field's value. +func (s *StorageConfiguration) SetPineconeConfiguration(v *PineconeConfiguration) *StorageConfiguration { + s.PineconeConfiguration = v return s } -// Contains details about a parameter in a function for an action group. -// -// This data type is used in the following API operations: -// -// - CreateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_RequestSyntax) -// -// - CreateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_CreateAgentActionGroup.html#API_agent_CreateAgentActionGroup_ResponseSyntax) -// -// - UpdateAgentActionGroup request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_RequestSyntax) -// -// - UpdateAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_UpdateAgentActionGroup.html#API_agent_UpdateAgentActionGroup_ResponseSyntax) -// -// - GetAgentActionGroup response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetAgentActionGroup.html#API_agent_GetAgentActionGroup_ResponseSyntax) -type ParameterDetail struct { - _ struct{} `type:"structure"` +// SetRdsConfiguration sets the RdsConfiguration field's value. +func (s *StorageConfiguration) SetRdsConfiguration(v *RdsConfiguration) *StorageConfiguration { + s.RdsConfiguration = v + return s +} - // A description of the parameter. Helps the foundation model determine how - // to elicit the parameters from the user. - Description *string `locationName:"description" min:"1" type:"string"` +// SetRedisEnterpriseCloudConfiguration sets the RedisEnterpriseCloudConfiguration field's value. +func (s *StorageConfiguration) SetRedisEnterpriseCloudConfiguration(v *RedisEnterpriseCloudConfiguration) *StorageConfiguration { + s.RedisEnterpriseCloudConfiguration = v + return s +} - // Whether the parameter is required for the agent to complete the function - // for action group invocation. - Required *bool `locationName:"required" type:"boolean"` +// SetType sets the Type field's value. +func (s *StorageConfiguration) SetType(v string) *StorageConfiguration { + s.Type = &v + return s +} - // The data type of the parameter. +// Contains configurations for a Storage node in a flow. This node stores the +// input in an Amazon S3 location that you specify. +type StorageFlowNodeConfiguration struct { + _ struct{} `type:"structure"` + + // Contains configurations for the service to use for storing the input into + // the node. // - // Type is a required field - Type *string `locationName:"type" type:"string" required:"true" enum:"Type"` + // ServiceConfiguration is a required field + ServiceConfiguration *StorageFlowNodeServiceConfiguration `locationName:"serviceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -11796,7 +22710,7 @@ type ParameterDetail struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ParameterDetail) String() string { +func (s StorageFlowNodeConfiguration) String() string { return awsutil.Prettify(s) } @@ -11805,18 +22719,20 @@ func (s ParameterDetail) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ParameterDetail) GoString() string { +func (s StorageFlowNodeConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ParameterDetail) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ParameterDetail"} - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) +func (s *StorageFlowNodeConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StorageFlowNodeConfiguration"} + if s.ServiceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("ServiceConfiguration")) + } + if s.ServiceConfiguration != nil { + if err := s.ServiceConfiguration.Validate(); err != nil { + invalidParams.AddNested("ServiceConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -11825,48 +22741,21 @@ func (s *ParameterDetail) Validate() error { return nil } -// SetDescription sets the Description field's value. -func (s *ParameterDetail) SetDescription(v string) *ParameterDetail { - s.Description = &v - return s -} - -// SetRequired sets the Required field's value. -func (s *ParameterDetail) SetRequired(v bool) *ParameterDetail { - s.Required = &v - return s -} - -// SetType sets the Type field's value. -func (s *ParameterDetail) SetType(v string) *ParameterDetail { - s.Type = &v +// SetServiceConfiguration sets the ServiceConfiguration field's value. +func (s *StorageFlowNodeConfiguration) SetServiceConfiguration(v *StorageFlowNodeServiceConfiguration) *StorageFlowNodeConfiguration { + s.ServiceConfiguration = v return s } -// Contains details about the storage configuration of the knowledge base in -// Pinecone. For more information, see Create a vector index in Pinecone (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-pinecone.html). -type PineconeConfiguration struct { +// Contains configurations for the Amazon S3 location in which to store the +// input into the node. +type StorageFlowNodeS3Configuration struct { _ struct{} `type:"structure"` - // The endpoint URL for your index management page. - // - // ConnectionString is a required field - ConnectionString *string `locationName:"connectionString" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the secret that you created in Secrets - // Manager that is linked to your Pinecone API key. - // - // CredentialsSecretArn is a required field - CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` - - // Contains the names of the fields to which to map information about the vector - // store. + // The name of the Amazon S3 bucket in which to store the input into the node. // - // FieldMapping is a required field - FieldMapping *PineconeFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` - - // The namespace to be used to write new data to your database. - Namespace *string `locationName:"namespace" type:"string"` + // BucketName is a required field + BucketName *string `locationName:"bucketName" min:"3" type:"string" required:"true"` } // String returns the string representation. @@ -11874,7 +22763,7 @@ type PineconeConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PineconeConfiguration) String() string { +func (s StorageFlowNodeS3Configuration) String() string { return awsutil.Prettify(s) } @@ -11883,26 +22772,18 @@ func (s PineconeConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PineconeConfiguration) GoString() string { +func (s StorageFlowNodeS3Configuration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *PineconeConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PineconeConfiguration"} - if s.ConnectionString == nil { - invalidParams.Add(request.NewErrParamRequired("ConnectionString")) - } - if s.CredentialsSecretArn == nil { - invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) - } - if s.FieldMapping == nil { - invalidParams.Add(request.NewErrParamRequired("FieldMapping")) +func (s *StorageFlowNodeS3Configuration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StorageFlowNodeS3Configuration"} + if s.BucketName == nil { + invalidParams.Add(request.NewErrParamRequired("BucketName")) } - if s.FieldMapping != nil { - if err := s.FieldMapping.Validate(); err != nil { - invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) - } + if s.BucketName != nil && len(*s.BucketName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("BucketName", 3)) } if invalidParams.Len() > 0 { @@ -11911,46 +22792,20 @@ func (s *PineconeConfiguration) Validate() error { return nil } -// SetConnectionString sets the ConnectionString field's value. -func (s *PineconeConfiguration) SetConnectionString(v string) *PineconeConfiguration { - s.ConnectionString = &v - return s -} - -// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. -func (s *PineconeConfiguration) SetCredentialsSecretArn(v string) *PineconeConfiguration { - s.CredentialsSecretArn = &v - return s -} - -// SetFieldMapping sets the FieldMapping field's value. -func (s *PineconeConfiguration) SetFieldMapping(v *PineconeFieldMapping) *PineconeConfiguration { - s.FieldMapping = v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *PineconeConfiguration) SetNamespace(v string) *PineconeConfiguration { - s.Namespace = &v +// SetBucketName sets the BucketName field's value. +func (s *StorageFlowNodeS3Configuration) SetBucketName(v string) *StorageFlowNodeS3Configuration { + s.BucketName = &v return s } -// Contains the names of the fields to which to map information about the vector -// store. -type PineconeFieldMapping struct { +// Contains configurations for the service to use for storing the input into +// the node. +type StorageFlowNodeServiceConfiguration struct { _ struct{} `type:"structure"` - // The name of the field in which Amazon Bedrock stores metadata about the vector - // store. - // - // MetadataField is a required field - MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - - // 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. - // - // TextField is a required field - TextField *string `locationName:"textField" type:"string" required:"true"` + // Contains configurations for the Amazon S3 location in which to store the + // input into the node. + S3 *StorageFlowNodeS3Configuration `locationName:"s3" type:"structure"` } // String returns the string representation. @@ -11958,7 +22813,7 @@ type PineconeFieldMapping struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PineconeFieldMapping) String() string { +func (s StorageFlowNodeServiceConfiguration) String() string { return awsutil.Prettify(s) } @@ -11967,18 +22822,17 @@ func (s PineconeFieldMapping) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PineconeFieldMapping) GoString() string { +func (s StorageFlowNodeServiceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *PineconeFieldMapping) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PineconeFieldMapping"} - if s.MetadataField == nil { - invalidParams.Add(request.NewErrParamRequired("MetadataField")) - } - if s.TextField == nil { - invalidParams.Add(request.NewErrParamRequired("TextField")) +func (s *StorageFlowNodeServiceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StorageFlowNodeServiceConfiguration"} + if s.S3 != nil { + if err := s.S3.Validate(); err != nil { + invalidParams.AddNested("S3", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -11987,25 +22841,25 @@ func (s *PineconeFieldMapping) Validate() error { return nil } -// SetMetadataField sets the MetadataField field's value. -func (s *PineconeFieldMapping) SetMetadataField(v string) *PineconeFieldMapping { - s.MetadataField = &v +// SetS3 sets the S3 field's value. +func (s *StorageFlowNodeServiceConfiguration) SetS3(v *StorageFlowNodeS3Configuration) *StorageFlowNodeServiceConfiguration { + s.S3 = v return s } -// SetTextField sets the TextField field's value. -func (s *PineconeFieldMapping) SetTextField(v string) *PineconeFieldMapping { - s.TextField = &v - return s -} +type TagResourceInput struct { + _ struct{} `type:"structure"` -type PrepareAgentInput struct { - _ struct{} `type:"structure" nopayload:"true"` + // The Amazon Resource Name (ARN) of the resource to tag. + // + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` - // The unique identifier of the agent for which to create a DRAFT version. + // An object containing key-value pairs that define the tags to attach to the + // resource. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // Tags is a required field + Tags map[string]*string `locationName:"tags" type:"map" required:"true"` } // String returns the string representation. @@ -12013,7 +22867,7 @@ type PrepareAgentInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PrepareAgentInput) String() string { +func (s TagResourceInput) String() string { return awsutil.Prettify(s) } @@ -12022,18 +22876,21 @@ func (s PrepareAgentInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PrepareAgentInput) GoString() string { +func (s TagResourceInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *PrepareAgentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PrepareAgentInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *TagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) + } + if s.Tags == nil { + invalidParams.Add(request.NewErrParamRequired("Tags")) } if invalidParams.Len() > 0 { @@ -12042,34 +22899,20 @@ func (s *PrepareAgentInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *PrepareAgentInput) SetAgentId(v string) *PrepareAgentInput { - s.AgentId = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput { + s.ResourceArn = &v return s } -type PrepareAgentOutput struct { - _ struct{} `type:"structure"` - - // The unique identifier of the agent for which the DRAFT version was created. - // - // AgentId is a required field - AgentId *string `locationName:"agentId" type:"string" required:"true"` - - // The status of the DRAFT version and whether it is ready for use. - // - // AgentStatus is a required field - AgentStatus *string `locationName:"agentStatus" type:"string" required:"true" enum:"AgentStatus"` - - // The version of the agent. - // - // AgentVersion is a required field - AgentVersion *string `locationName:"agentVersion" min:"1" type:"string" required:"true"` +// SetTags sets the Tags field's value. +func (s *TagResourceInput) SetTags(v map[string]*string) *TagResourceInput { + s.Tags = v + return s +} - // The time at which the DRAFT version of the agent was last prepared. - // - // PreparedAt is a required field - PreparedAt *time.Time `locationName:"preparedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` +type TagResourceOutput struct { + _ struct{} `type:"structure"` } // String returns the string representation. @@ -12077,7 +22920,7 @@ type PrepareAgentOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PrepareAgentOutput) String() string { +func (s TagResourceOutput) String() string { return awsutil.Prettify(s) } @@ -12086,78 +22929,30 @@ func (s PrepareAgentOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PrepareAgentOutput) GoString() string { +func (s TagResourceOutput) GoString() string { return s.String() } -// SetAgentId sets the AgentId field's value. -func (s *PrepareAgentOutput) SetAgentId(v string) *PrepareAgentOutput { - s.AgentId = &v - return s -} - -// SetAgentStatus sets the AgentStatus field's value. -func (s *PrepareAgentOutput) SetAgentStatus(v string) *PrepareAgentOutput { - s.AgentStatus = &v - return s -} - -// SetAgentVersion sets the AgentVersion field's value. -func (s *PrepareAgentOutput) SetAgentVersion(v string) *PrepareAgentOutput { - s.AgentVersion = &v - return s -} - -// SetPreparedAt sets the PreparedAt field's value. -func (s *PrepareAgentOutput) SetPreparedAt(v time.Time) *PrepareAgentOutput { - s.PreparedAt = &v - return s -} - -// Contains configurations to override a prompt template in one part of an agent -// sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). -type PromptConfiguration struct { - _ struct{} `type:"structure"` - - // 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 - // (https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html). - // For more information, see Configure the prompt templates (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts-configure.html). - BasePromptTemplate *string `locationName:"basePromptTemplate" min:"1" type:"string"` - - // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html). - InferenceConfiguration *InferenceConfiguration `locationName:"inferenceConfiguration" type:"structure"` - - // 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 (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptOverrideConfiguration.html) - // must be specified with the ARN of a Lambda function. - ParserMode *string `locationName:"parserMode" type:"string" enum:"CreationMode"` - - // 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. - PromptCreationMode *string `locationName:"promptCreationMode" type:"string" enum:"CreationMode"` +// Contains configurations for a text prompt template. To include a variable, +// enclose a word in double curly braces as in {{variable}}. +type TextPromptTemplateConfiguration struct { + _ struct{} `type:"structure" sensitive:"true"` - // 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_PROCESSING – ENABLED + // An array of the variables in the prompt template. // - // * ORCHESTRATION – ENABLED + // InputVariables is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by TextPromptTemplateConfiguration's + // String and GoString methods. + InputVariables []*PromptInputVariable `locationName:"inputVariables" type:"list" sensitive:"true"` + + // The message for the prompt. // - // * KNOWLEDGE_BASE_RESPONSE_GENERATION – ENABLED + // Text is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by TextPromptTemplateConfiguration's + // String and GoString methods. // - // * POST_PROCESSING – DISABLED - PromptState *string `locationName:"promptState" type:"string" enum:"PromptState"` - - // The step in the agent sequence that this prompt configuration applies to. - PromptType *string `locationName:"promptType" type:"string" enum:"PromptType"` + // Text is a required field + Text *string `locationName:"text" min:"1" type:"string" required:"true" sensitive:"true"` } // String returns the string representation. @@ -12165,7 +22960,7 @@ type PromptConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PromptConfiguration) String() string { +func (s TextPromptTemplateConfiguration) String() string { return awsutil.Prettify(s) } @@ -12174,15 +22969,18 @@ func (s PromptConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PromptConfiguration) GoString() string { +func (s TextPromptTemplateConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *PromptConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PromptConfiguration"} - if s.BasePromptTemplate != nil && len(*s.BasePromptTemplate) < 1 { - invalidParams.Add(request.NewErrParamMinLen("BasePromptTemplate", 1)) +func (s *TextPromptTemplateConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TextPromptTemplateConfiguration"} + if s.Text == nil { + invalidParams.Add(request.NewErrParamRequired("Text")) + } + if s.Text != nil && len(*s.Text) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Text", 1)) } if invalidParams.Len() > 0 { @@ -12191,59 +22989,24 @@ func (s *PromptConfiguration) Validate() error { return nil } -// SetBasePromptTemplate sets the BasePromptTemplate field's value. -func (s *PromptConfiguration) SetBasePromptTemplate(v string) *PromptConfiguration { - s.BasePromptTemplate = &v - return s -} - -// SetInferenceConfiguration sets the InferenceConfiguration field's value. -func (s *PromptConfiguration) SetInferenceConfiguration(v *InferenceConfiguration) *PromptConfiguration { - s.InferenceConfiguration = v - return s -} - -// SetParserMode sets the ParserMode field's value. -func (s *PromptConfiguration) SetParserMode(v string) *PromptConfiguration { - s.ParserMode = &v - return s -} - -// SetPromptCreationMode sets the PromptCreationMode field's value. -func (s *PromptConfiguration) SetPromptCreationMode(v string) *PromptConfiguration { - s.PromptCreationMode = &v - return s -} - -// SetPromptState sets the PromptState field's value. -func (s *PromptConfiguration) SetPromptState(v string) *PromptConfiguration { - s.PromptState = &v +// SetInputVariables sets the InputVariables field's value. +func (s *TextPromptTemplateConfiguration) SetInputVariables(v []*PromptInputVariable) *TextPromptTemplateConfiguration { + s.InputVariables = v return s } -// SetPromptType sets the PromptType field's value. -func (s *PromptConfiguration) SetPromptType(v string) *PromptConfiguration { - s.PromptType = &v +// SetText sets the Text field's value. +func (s *TextPromptTemplateConfiguration) SetText(v string) *TextPromptTemplateConfiguration { + s.Text = &v return s } -// Contains configurations to override prompts in different parts of an agent -// sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). -type PromptOverrideConfiguration struct { - _ struct{} `type:"structure" sensitive:"true"` - - // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/lambda-parser.html). - OverrideLambda *string `locationName:"overrideLambda" type:"string"` +// The number of requests exceeds the limit. Resubmit your request later. +type ThrottlingException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // Contains configurations to override a prompt template in one part of an agent - // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). - // - // PromptConfigurations is a required field - PromptConfigurations []*PromptConfiguration `locationName:"promptConfigurations" type:"list" required:"true"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -12251,7 +23014,7 @@ type PromptOverrideConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PromptOverrideConfiguration) String() string { +func (s ThrottlingException) String() string { return awsutil.Prettify(s) } @@ -12260,77 +23023,63 @@ func (s PromptOverrideConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PromptOverrideConfiguration) GoString() string { +func (s ThrottlingException) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *PromptOverrideConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PromptOverrideConfiguration"} - if s.PromptConfigurations == nil { - invalidParams.Add(request.NewErrParamRequired("PromptConfigurations")) - } - if s.PromptConfigurations != nil { - for i, v := range s.PromptConfigurations { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PromptConfigurations", i), err.(request.ErrInvalidParams)) - } - } - } - - if invalidParams.Len() > 0 { - return invalidParams +func newErrorThrottlingException(v protocol.ResponseMetadata) error { + return &ThrottlingException{ + RespMetadata: v, } - return nil } -// SetOverrideLambda sets the OverrideLambda field's value. -func (s *PromptOverrideConfiguration) SetOverrideLambda(v string) *PromptOverrideConfiguration { - s.OverrideLambda = &v - return s +// Code returns the exception type name. +func (s *ThrottlingException) Code() string { + return "ThrottlingException" } -// SetPromptConfigurations sets the PromptConfigurations field's value. -func (s *PromptOverrideConfiguration) SetPromptConfigurations(v []*PromptConfiguration) *PromptOverrideConfiguration { - s.PromptConfigurations = v - return s +// Message returns the exception's message. +func (s *ThrottlingException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" } -// Contains details about the storage configuration of the knowledge base in -// Amazon RDS. For more information, see Create a vector index in Amazon RDS -// (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). -type RdsConfiguration struct { - _ struct{} `type:"structure"` +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ThrottlingException) OrigErr() error { + return nil +} - // The Amazon Resource Name (ARN) of the secret that you created in Secrets - // Manager that is linked to your Amazon RDS database. - // - // CredentialsSecretArn is a required field - CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` +func (s *ThrottlingException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} - // The name of your Amazon RDS database. - // - // DatabaseName is a required field - DatabaseName *string `locationName:"databaseName" type:"string" required:"true"` +// Status code returns the HTTP status code for the request's response error. +func (s *ThrottlingException) StatusCode() int { + return s.RespMetadata.StatusCode +} - // Contains the names of the fields to which to map information about the vector - // store. - // - // FieldMapping is a required field - FieldMapping *RdsFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` +// RequestID returns the service's response RequestID for request. +func (s *ThrottlingException) RequestID() string { + return s.RespMetadata.RequestID +} - // The Amazon Resource Name (ARN) of the vector store. +// 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. +type Transformation struct { + _ struct{} `type:"structure"` + + // When the service applies the transformation. // - // ResourceArn is a required field - ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"` + // StepToApply is a required field + StepToApply *string `locationName:"stepToApply" type:"string" required:"true" enum:"StepType"` - // The name of the table in the database. + // A Lambda function that processes documents. // - // TableName is a required field - TableName *string `locationName:"tableName" type:"string" required:"true"` + // TransformationFunction is a required field + TransformationFunction *TransformationFunction `locationName:"transformationFunction" type:"structure" required:"true"` } // String returns the string representation. @@ -12338,7 +23087,7 @@ type RdsConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RdsConfiguration) String() string { +func (s Transformation) String() string { return awsutil.Prettify(s) } @@ -12347,31 +23096,22 @@ func (s RdsConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RdsConfiguration) GoString() string { +func (s Transformation) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *RdsConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RdsConfiguration"} - if s.CredentialsSecretArn == nil { - invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) - } - if s.DatabaseName == nil { - invalidParams.Add(request.NewErrParamRequired("DatabaseName")) - } - if s.FieldMapping == nil { - invalidParams.Add(request.NewErrParamRequired("FieldMapping")) - } - if s.ResourceArn == nil { - invalidParams.Add(request.NewErrParamRequired("ResourceArn")) +func (s *Transformation) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Transformation"} + if s.StepToApply == nil { + invalidParams.Add(request.NewErrParamRequired("StepToApply")) } - if s.TableName == nil { - invalidParams.Add(request.NewErrParamRequired("TableName")) + if s.TransformationFunction == nil { + invalidParams.Add(request.NewErrParamRequired("TransformationFunction")) } - if s.FieldMapping != nil { - if err := s.FieldMapping.Validate(); err != nil { - invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) + if s.TransformationFunction != nil { + if err := s.TransformationFunction.Validate(); err != nil { + invalidParams.AddNested("TransformationFunction", err.(request.ErrInvalidParams)) } } @@ -12381,63 +23121,26 @@ func (s *RdsConfiguration) Validate() error { return nil } -// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. -func (s *RdsConfiguration) SetCredentialsSecretArn(v string) *RdsConfiguration { - s.CredentialsSecretArn = &v - return s -} - -// SetDatabaseName sets the DatabaseName field's value. -func (s *RdsConfiguration) SetDatabaseName(v string) *RdsConfiguration { - s.DatabaseName = &v - return s -} - -// SetFieldMapping sets the FieldMapping field's value. -func (s *RdsConfiguration) SetFieldMapping(v *RdsFieldMapping) *RdsConfiguration { - s.FieldMapping = v - return s -} - -// SetResourceArn sets the ResourceArn field's value. -func (s *RdsConfiguration) SetResourceArn(v string) *RdsConfiguration { - s.ResourceArn = &v +// SetStepToApply sets the StepToApply field's value. +func (s *Transformation) SetStepToApply(v string) *Transformation { + s.StepToApply = &v return s } -// SetTableName sets the TableName field's value. -func (s *RdsConfiguration) SetTableName(v string) *RdsConfiguration { - s.TableName = &v +// SetTransformationFunction sets the TransformationFunction field's value. +func (s *Transformation) SetTransformationFunction(v *TransformationFunction) *Transformation { + s.TransformationFunction = v return s } -// Contains the names of the fields to which to map information about the vector -// store. -type RdsFieldMapping struct { +// A Lambda function that processes documents. +type TransformationFunction struct { _ struct{} `type:"structure"` - // The name of the field in which Amazon Bedrock stores metadata about the vector - // store. - // - // MetadataField is a required field - MetadataField *string `locationName:"metadataField" type:"string" required:"true"` - - // The name of the field in which Amazon Bedrock stores the ID for each entry. - // - // PrimaryKeyField is a required field - PrimaryKeyField *string `locationName:"primaryKeyField" type:"string" required:"true"` - - // 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. - // - // TextField is a required field - TextField *string `locationName:"textField" type:"string" required:"true"` - - // The name of the field in which Amazon Bedrock stores the vector embeddings - // for your data sources. + // The Lambda function. // - // VectorField is a required field - VectorField *string `locationName:"vectorField" type:"string" required:"true"` + // TransformationLambdaConfiguration is a required field + TransformationLambdaConfiguration *TransformationLambdaConfiguration `locationName:"transformationLambdaConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -12445,7 +23148,7 @@ type RdsFieldMapping struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RdsFieldMapping) String() string { +func (s TransformationFunction) String() string { return awsutil.Prettify(s) } @@ -12454,24 +23157,20 @@ func (s RdsFieldMapping) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RdsFieldMapping) GoString() string { +func (s TransformationFunction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *RdsFieldMapping) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RdsFieldMapping"} - if s.MetadataField == nil { - invalidParams.Add(request.NewErrParamRequired("MetadataField")) - } - if s.PrimaryKeyField == nil { - invalidParams.Add(request.NewErrParamRequired("PrimaryKeyField")) - } - if s.TextField == nil { - invalidParams.Add(request.NewErrParamRequired("TextField")) - } - if s.VectorField == nil { - invalidParams.Add(request.NewErrParamRequired("VectorField")) +func (s *TransformationFunction) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TransformationFunction"} + if s.TransformationLambdaConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("TransformationLambdaConfiguration")) + } + if s.TransformationLambdaConfiguration != nil { + if err := s.TransformationLambdaConfiguration.Validate(); err != nil { + invalidParams.AddNested("TransformationLambdaConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -12480,57 +23179,71 @@ func (s *RdsFieldMapping) Validate() error { return nil } -// SetMetadataField sets the MetadataField field's value. -func (s *RdsFieldMapping) SetMetadataField(v string) *RdsFieldMapping { - s.MetadataField = &v +// SetTransformationLambdaConfiguration sets the TransformationLambdaConfiguration field's value. +func (s *TransformationFunction) SetTransformationLambdaConfiguration(v *TransformationLambdaConfiguration) *TransformationFunction { + s.TransformationLambdaConfiguration = v return s } -// SetPrimaryKeyField sets the PrimaryKeyField field's value. -func (s *RdsFieldMapping) SetPrimaryKeyField(v string) *RdsFieldMapping { - s.PrimaryKeyField = &v - return s +// A Lambda function that processes documents. +type TransformationLambdaConfiguration struct { + _ struct{} `type:"structure"` + + // The function's ARN identifier. + // + // LambdaArn is a required field + LambdaArn *string `locationName:"lambdaArn" type:"string" required:"true"` } -// SetTextField sets the TextField field's value. -func (s *RdsFieldMapping) SetTextField(v string) *RdsFieldMapping { - s.TextField = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TransformationLambdaConfiguration) String() string { + return awsutil.Prettify(s) } -// SetVectorField sets the VectorField field's value. -func (s *RdsFieldMapping) SetVectorField(v string) *RdsFieldMapping { - s.VectorField = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TransformationLambdaConfiguration) GoString() string { + return s.String() } -// 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html). -type RedisEnterpriseCloudConfiguration struct { - _ struct{} `type:"structure"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *TransformationLambdaConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TransformationLambdaConfiguration"} + if s.LambdaArn == nil { + invalidParams.Add(request.NewErrParamRequired("LambdaArn")) + } - // The Amazon Resource Name (ARN) of the secret that you created in Secrets - // Manager that is linked to your Redis Enterprise Cloud database. - // - // CredentialsSecretArn is a required field - CredentialsSecretArn *string `locationName:"credentialsSecretArn" type:"string" required:"true"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // The endpoint URL of the Redis Enterprise Cloud database. - // - // Endpoint is a required field - Endpoint *string `locationName:"endpoint" type:"string" required:"true"` +// SetLambdaArn sets the LambdaArn field's value. +func (s *TransformationLambdaConfiguration) SetLambdaArn(v string) *TransformationLambdaConfiguration { + s.LambdaArn = &v + return s +} - // Contains the names of the fields to which to map information about the vector - // store. +type UntagResourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The Amazon Resource Name (ARN) of the resource from which to remove tags. // - // FieldMapping is a required field - FieldMapping *RedisEnterpriseCloudFieldMapping `locationName:"fieldMapping" type:"structure" required:"true"` + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` - // The name of the vector index. + // A list of keys of the tags to remove from the resource. // - // VectorIndexName is a required field - VectorIndexName *string `locationName:"vectorIndexName" type:"string" required:"true"` + // TagKeys is a required field + TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true"` } // String returns the string representation. @@ -12538,7 +23251,7 @@ type RedisEnterpriseCloudConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RedisEnterpriseCloudConfiguration) String() string { +func (s UntagResourceInput) String() string { return awsutil.Prettify(s) } @@ -12547,29 +23260,21 @@ func (s RedisEnterpriseCloudConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RedisEnterpriseCloudConfiguration) GoString() string { +func (s UntagResourceInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *RedisEnterpriseCloudConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RedisEnterpriseCloudConfiguration"} - if s.CredentialsSecretArn == nil { - invalidParams.Add(request.NewErrParamRequired("CredentialsSecretArn")) - } - if s.Endpoint == nil { - invalidParams.Add(request.NewErrParamRequired("Endpoint")) - } - if s.FieldMapping == nil { - invalidParams.Add(request.NewErrParamRequired("FieldMapping")) +func (s *UntagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } - if s.VectorIndexName == nil { - invalidParams.Add(request.NewErrParamRequired("VectorIndexName")) + if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) } - if s.FieldMapping != nil { - if err := s.FieldMapping.Validate(); err != nil { - invalidParams.AddNested("FieldMapping", err.(request.ErrInvalidParams)) - } + if s.TagKeys == nil { + invalidParams.Add(request.NewErrParamRequired("TagKeys")) } if invalidParams.Len() > 0 { @@ -12578,52 +23283,96 @@ func (s *RedisEnterpriseCloudConfiguration) Validate() error { return nil } -// SetCredentialsSecretArn sets the CredentialsSecretArn field's value. -func (s *RedisEnterpriseCloudConfiguration) SetCredentialsSecretArn(v string) *RedisEnterpriseCloudConfiguration { - s.CredentialsSecretArn = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput { + s.ResourceArn = &v return s } -// SetEndpoint sets the Endpoint field's value. -func (s *RedisEnterpriseCloudConfiguration) SetEndpoint(v string) *RedisEnterpriseCloudConfiguration { - s.Endpoint = &v +// SetTagKeys sets the TagKeys field's value. +func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { + s.TagKeys = v return s } -// SetFieldMapping sets the FieldMapping field's value. -func (s *RedisEnterpriseCloudConfiguration) SetFieldMapping(v *RedisEnterpriseCloudFieldMapping) *RedisEnterpriseCloudConfiguration { - s.FieldMapping = v - return s +type UntagResourceOutput struct { + _ struct{} `type:"structure"` } -// SetVectorIndexName sets the VectorIndexName field's value. -func (s *RedisEnterpriseCloudConfiguration) SetVectorIndexName(v string) *RedisEnterpriseCloudConfiguration { - s.VectorIndexName = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceOutput) String() string { + return awsutil.Prettify(s) } -// Contains the names of the fields to which to map information about the vector -// store. -type RedisEnterpriseCloudFieldMapping struct { +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceOutput) GoString() string { + return s.String() +} + +type UpdateAgentActionGroupInput struct { _ struct{} `type:"structure"` - // The name of the field in which Amazon Bedrock stores metadata about the vector - // store. + // The Amazon Resource Name (ARN) of the Lambda function containing the business + // logic that is carried out upon invoking the action. + ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` + + // The unique identifier of the action group. + // + // ActionGroupId is a required field + ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` + + // Specifies a new name for the action group. + // + // ActionGroupName is a required field + ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + + // Specifies whether the action group is available for the agent to invoke or + // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + ActionGroupState *string `locationName:"actionGroupState" type:"string" enum:"ActionGroupState"` + + // The unique identifier of the agent for which to update the action group. // - // MetadataField is a required field - MetadataField *string `locationName:"metadataField" type:"string" required:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // 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. + // The unique identifier of the agent version for which to update the action + // group. // - // TextField is a required field - TextField *string `locationName:"textField" type:"string" required:"true"` + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` - // The name of the field in which Amazon Bedrock stores the vector embeddings - // for your data sources. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). + ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` + + // Specifies a new name for the action group. + Description *string `locationName:"description" min:"1" type:"string"` + + // Contains details about the function schema for the action group or the JSON + // or YAML-formatted payload defining the schema. + FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` + + // 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. // - // VectorField is a required field - VectorField *string `locationName:"vectorField" type:"string" required:"true"` + // 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 + // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) + // reprompting the user for more information. + ParentActionGroupSignature *string `locationName:"parentActionGroupSignature" type:"string" enum:"ActionGroupSignature"` } // String returns the string representation. @@ -12631,7 +23380,7 @@ type RedisEnterpriseCloudFieldMapping struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RedisEnterpriseCloudFieldMapping) String() string { +func (s UpdateAgentActionGroupInput) String() string { return awsutil.Prettify(s) } @@ -12640,21 +23389,46 @@ func (s RedisEnterpriseCloudFieldMapping) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s RedisEnterpriseCloudFieldMapping) GoString() string { +func (s UpdateAgentActionGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *RedisEnterpriseCloudFieldMapping) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RedisEnterpriseCloudFieldMapping"} - if s.MetadataField == nil { - invalidParams.Add(request.NewErrParamRequired("MetadataField")) +func (s *UpdateAgentActionGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateAgentActionGroupInput"} + if s.ActionGroupId == nil { + invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) } - if s.TextField == nil { - invalidParams.Add(request.NewErrParamRequired("TextField")) + if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) } - if s.VectorField == nil { - invalidParams.Add(request.NewErrParamRequired("VectorField")) + if s.ActionGroupName == nil { + invalidParams.Add(request.NewErrParamRequired("ActionGroupName")) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.ApiSchema != nil { + if err := s.ApiSchema.Validate(); err != nil { + invalidParams.AddNested("ApiSchema", err.(request.ErrInvalidParams)) + } + } + if s.FunctionSchema != nil { + if err := s.FunctionSchema.Validate(); err != nil { + invalidParams.AddNested("FunctionSchema", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -12663,31 +23437,73 @@ func (s *RedisEnterpriseCloudFieldMapping) Validate() error { return nil } -// SetMetadataField sets the MetadataField field's value. -func (s *RedisEnterpriseCloudFieldMapping) SetMetadataField(v string) *RedisEnterpriseCloudFieldMapping { - s.MetadataField = &v +// SetActionGroupExecutor sets the ActionGroupExecutor field's value. +func (s *UpdateAgentActionGroupInput) SetActionGroupExecutor(v *ActionGroupExecutor) *UpdateAgentActionGroupInput { + s.ActionGroupExecutor = v return s } -// SetTextField sets the TextField field's value. -func (s *RedisEnterpriseCloudFieldMapping) SetTextField(v string) *RedisEnterpriseCloudFieldMapping { - s.TextField = &v +// SetActionGroupId sets the ActionGroupId field's value. +func (s *UpdateAgentActionGroupInput) SetActionGroupId(v string) *UpdateAgentActionGroupInput { + s.ActionGroupId = &v return s } -// SetVectorField sets the VectorField field's value. -func (s *RedisEnterpriseCloudFieldMapping) SetVectorField(v string) *RedisEnterpriseCloudFieldMapping { - s.VectorField = &v +// SetActionGroupName sets the ActionGroupName field's value. +func (s *UpdateAgentActionGroupInput) SetActionGroupName(v string) *UpdateAgentActionGroupInput { + s.ActionGroupName = &v return s } -// The specified resource Amazon Resource Name (ARN) was not found. Check the -// Amazon Resource Name (ARN) and try your request again. -type ResourceNotFoundException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` +// SetActionGroupState sets the ActionGroupState field's value. +func (s *UpdateAgentActionGroupInput) SetActionGroupState(v string) *UpdateAgentActionGroupInput { + s.ActionGroupState = &v + return s +} - Message_ *string `locationName:"message" type:"string"` +// SetAgentId sets the AgentId field's value. +func (s *UpdateAgentActionGroupInput) SetAgentId(v string) *UpdateAgentActionGroupInput { + s.AgentId = &v + return s +} + +// SetAgentVersion sets the AgentVersion field's value. +func (s *UpdateAgentActionGroupInput) SetAgentVersion(v string) *UpdateAgentActionGroupInput { + s.AgentVersion = &v + return s +} + +// SetApiSchema sets the ApiSchema field's value. +func (s *UpdateAgentActionGroupInput) SetApiSchema(v *APISchema) *UpdateAgentActionGroupInput { + s.ApiSchema = v + return s +} + +// SetDescription sets the Description field's value. +func (s *UpdateAgentActionGroupInput) SetDescription(v string) *UpdateAgentActionGroupInput { + s.Description = &v + return s +} + +// SetFunctionSchema sets the FunctionSchema field's value. +func (s *UpdateAgentActionGroupInput) SetFunctionSchema(v *FunctionSchema) *UpdateAgentActionGroupInput { + s.FunctionSchema = v + return s +} + +// SetParentActionGroupSignature sets the ParentActionGroupSignature field's value. +func (s *UpdateAgentActionGroupInput) SetParentActionGroupSignature(v string) *UpdateAgentActionGroupInput { + s.ParentActionGroupSignature = &v + return s +} + +type UpdateAgentActionGroupOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the action group that was updated. + // + // AgentActionGroup is a required field + AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` } // String returns the string representation. @@ -12695,7 +23511,7 @@ type ResourceNotFoundException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ResourceNotFoundException) String() string { +func (s UpdateAgentActionGroupOutput) String() string { return awsutil.Prettify(s) } @@ -12704,63 +23520,39 @@ func (s ResourceNotFoundException) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ResourceNotFoundException) GoString() string { +func (s UpdateAgentActionGroupOutput) GoString() string { return s.String() } -func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { - return &ResourceNotFoundException{ - RespMetadata: v, - } -} - -// Code returns the exception type name. -func (s *ResourceNotFoundException) Code() string { - return "ResourceNotFoundException" -} - -// Message returns the exception's message. -func (s *ResourceNotFoundException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" -} - -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ResourceNotFoundException) OrigErr() error { - return nil -} - -func (s *ResourceNotFoundException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +// SetAgentActionGroup sets the AgentActionGroup field's value. +func (s *UpdateAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *UpdateAgentActionGroupOutput { + s.AgentActionGroup = v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *ResourceNotFoundException) StatusCode() int { - return s.RespMetadata.StatusCode -} +type UpdateAgentAliasInput struct { + _ struct{} `type:"structure"` -// RequestID returns the service's response RequestID for request. -func (s *ResourceNotFoundException) RequestID() string { - return s.RespMetadata.RequestID -} + // The unique identifier of the alias. + // + // AgentAliasId is a required field + AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` -// Contains information about the S3 configuration of the data source. -type S3DataSourceConfiguration struct { - _ struct{} `type:"structure"` + // Specifies a new name for the alias. + // + // AgentAliasName is a required field + AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` - // The Amazon Resource Name (ARN) of the bucket that contains the data source. + // The unique identifier of the agent. // - // BucketArn is a required field - BucketArn *string `locationName:"bucketArn" min:"1" type:"string" required:"true"` + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // The bucket account owner ID for the S3 bucket. - BucketOwnerAccountId *string `locationName:"bucketOwnerAccountId" min:"12" type:"string"` + // Specifies a new description for the alias. + Description *string `locationName:"description" min:"1" type:"string"` - // A list of S3 prefixes that define the object containing the data sources. - // For more information, see Organizing objects using prefixes (https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-prefixes.html). - InclusionPrefixes []*string `locationName:"inclusionPrefixes" min:"1" type:"list"` + // Contains details about the routing configuration of the alias. + RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` } // String returns the string representation. @@ -12768,7 +23560,7 @@ type S3DataSourceConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s S3DataSourceConfiguration) String() string { +func (s UpdateAgentAliasInput) String() string { return awsutil.Prettify(s) } @@ -12777,24 +23569,40 @@ func (s S3DataSourceConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s S3DataSourceConfiguration) GoString() string { +func (s UpdateAgentAliasInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *S3DataSourceConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "S3DataSourceConfiguration"} - if s.BucketArn == nil { - invalidParams.Add(request.NewErrParamRequired("BucketArn")) +func (s *UpdateAgentAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateAgentAliasInput"} + if s.AgentAliasId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) } - if s.BucketArn != nil && len(*s.BucketArn) < 1 { - invalidParams.Add(request.NewErrParamMinLen("BucketArn", 1)) + if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { + invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) } - if s.BucketOwnerAccountId != nil && len(*s.BucketOwnerAccountId) < 12 { - invalidParams.Add(request.NewErrParamMinLen("BucketOwnerAccountId", 12)) + if s.AgentAliasName == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasName")) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } - if s.InclusionPrefixes != nil && len(s.InclusionPrefixes) < 1 { - invalidParams.Add(request.NewErrParamMinLen("InclusionPrefixes", 1)) + if s.RoutingConfiguration != nil { + for i, v := range s.RoutingConfiguration { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) + } + } } if invalidParams.Len() > 0 { @@ -12803,33 +23611,43 @@ func (s *S3DataSourceConfiguration) Validate() error { return nil } -// SetBucketArn sets the BucketArn field's value. -func (s *S3DataSourceConfiguration) SetBucketArn(v string) *S3DataSourceConfiguration { - s.BucketArn = &v +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *UpdateAgentAliasInput) SetAgentAliasId(v string) *UpdateAgentAliasInput { + s.AgentAliasId = &v return s } -// SetBucketOwnerAccountId sets the BucketOwnerAccountId field's value. -func (s *S3DataSourceConfiguration) SetBucketOwnerAccountId(v string) *S3DataSourceConfiguration { - s.BucketOwnerAccountId = &v +// SetAgentAliasName sets the AgentAliasName field's value. +func (s *UpdateAgentAliasInput) SetAgentAliasName(v string) *UpdateAgentAliasInput { + s.AgentAliasName = &v return s } -// SetInclusionPrefixes sets the InclusionPrefixes field's value. -func (s *S3DataSourceConfiguration) SetInclusionPrefixes(v []*string) *S3DataSourceConfiguration { - s.InclusionPrefixes = v +// SetAgentId sets the AgentId field's value. +func (s *UpdateAgentAliasInput) SetAgentId(v string) *UpdateAgentAliasInput { + s.AgentId = &v return s } -// Contains information about the S3 object containing the resource. -type S3Identifier struct { - _ struct{} `type:"structure"` +// SetDescription sets the Description field's value. +func (s *UpdateAgentAliasInput) SetDescription(v string) *UpdateAgentAliasInput { + s.Description = &v + return s +} - // The name of the S3 bucket. - S3BucketName *string `locationName:"s3BucketName" min:"3" type:"string"` +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *UpdateAgentAliasInput) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *UpdateAgentAliasInput { + s.RoutingConfiguration = v + return s +} - // The S3 object key containing the resource. - S3ObjectKey *string `locationName:"s3ObjectKey" min:"1" type:"string"` +type UpdateAgentAliasOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the alias that was updated. + // + // AgentAlias is a required field + AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` } // String returns the string representation. @@ -12837,7 +23655,7 @@ type S3Identifier struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s S3Identifier) String() string { +func (s UpdateAgentAliasOutput) String() string { return awsutil.Prettify(s) } @@ -12846,44 +23664,75 @@ func (s S3Identifier) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s S3Identifier) GoString() string { +func (s UpdateAgentAliasOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *S3Identifier) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "S3Identifier"} - if s.S3BucketName != nil && len(*s.S3BucketName) < 3 { - invalidParams.Add(request.NewErrParamMinLen("S3BucketName", 3)) - } - if s.S3ObjectKey != nil && len(*s.S3ObjectKey) < 1 { - invalidParams.Add(request.NewErrParamMinLen("S3ObjectKey", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetS3BucketName sets the S3BucketName field's value. -func (s *S3Identifier) SetS3BucketName(v string) *S3Identifier { - s.S3BucketName = &v - return s -} - -// SetS3ObjectKey sets the S3ObjectKey field's value. -func (s *S3Identifier) SetS3ObjectKey(v string) *S3Identifier { - s.S3ObjectKey = &v +// SetAgentAlias sets the AgentAlias field's value. +func (s *UpdateAgentAliasOutput) SetAgentAlias(v *AgentAlias) *UpdateAgentAliasOutput { + s.AgentAlias = v return s } -// Contains the configuration for server-side encryption. -type ServerSideEncryptionConfiguration struct { +type UpdateAgentInput struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the KMS key used to encrypt the resource. - KmsKeyArn *string `locationName:"kmsKeyArn" min:"1" type:"string"` + // The unique identifier of the agent. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // Specifies a new name for the agent. + // + // AgentName is a required field + AgentName *string `locationName:"agentName" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke + // API operations on the agent. + // + // AgentResourceRoleArn is a required field + AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // Specifies a new description of the agent. + Description *string `locationName:"description" min:"1" type:"string"` + + // Specifies a new foundation model to be used for orchestration by the agent. + // + // FoundationModel is a required field + FoundationModel *string `locationName:"foundationModel" min:"1" type:"string" required:"true"` + + // The unique Guardrail configuration assigned to the agent when it is updated. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // 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. + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // Specifies new instructions that tell the agent what it should do and how + // it should interact with users. + // + // Instruction is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by UpdateAgentInput's + // String and GoString methods. + Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + + // Specifies the new memory configuration for the agent. + MemoryConfiguration *MemoryConfiguration `locationName:"memoryConfiguration" type:"structure"` + + // Contains configurations to override prompts in different parts of an agent + // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // + // PromptOverrideConfiguration is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by UpdateAgentInput's + // String and GoString methods. + PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` } // String returns the string representation. @@ -12891,7 +23740,7 @@ type ServerSideEncryptionConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ServerSideEncryptionConfiguration) String() string { +func (s UpdateAgentInput) String() string { return awsutil.Prettify(s) } @@ -12900,15 +23749,52 @@ func (s ServerSideEncryptionConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ServerSideEncryptionConfiguration) GoString() string { +func (s UpdateAgentInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ServerSideEncryptionConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ServerSideEncryptionConfiguration"} - if s.KmsKeyArn != nil && len(*s.KmsKeyArn) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KmsKeyArn", 1)) +func (s *UpdateAgentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateAgentInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.AgentName == nil { + invalidParams.Add(request.NewErrParamRequired("AgentName")) + } + if s.AgentResourceRoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("AgentResourceRoleArn")) + } + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.FoundationModel == nil { + invalidParams.Add(request.NewErrParamRequired("FoundationModel")) + } + if s.FoundationModel != nil && len(*s.FoundationModel) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FoundationModel", 1)) + } + if s.IdleSessionTTLInSeconds != nil && *s.IdleSessionTTLInSeconds < 60 { + invalidParams.Add(request.NewErrParamMinValue("IdleSessionTTLInSeconds", 60)) + } + if s.Instruction != nil && len(*s.Instruction) < 40 { + invalidParams.Add(request.NewErrParamMinLen("Instruction", 40)) + } + if s.MemoryConfiguration != nil { + if err := s.MemoryConfiguration.Validate(); err != nil { + invalidParams.AddNested("MemoryConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.PromptOverrideConfiguration != nil { + if err := s.PromptOverrideConfiguration.Validate(); err != nil { + invalidParams.AddNested("PromptOverrideConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -12917,97 +23803,100 @@ func (s *ServerSideEncryptionConfiguration) Validate() error { return nil } -// SetKmsKeyArn sets the KmsKeyArn field's value. -func (s *ServerSideEncryptionConfiguration) SetKmsKeyArn(v string) *ServerSideEncryptionConfiguration { - s.KmsKeyArn = &v +// SetAgentId sets the AgentId field's value. +func (s *UpdateAgentInput) SetAgentId(v string) *UpdateAgentInput { + s.AgentId = &v return s } -// The number of requests exceeds the service quota. Resubmit your request later. -type ServiceQuotaExceededException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - - Message_ *string `locationName:"message" type:"string"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ServiceQuotaExceededException) String() string { - return awsutil.Prettify(s) +// SetAgentName sets the AgentName field's value. +func (s *UpdateAgentInput) SetAgentName(v string) *UpdateAgentInput { + s.AgentName = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ServiceQuotaExceededException) GoString() string { - return s.String() +// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. +func (s *UpdateAgentInput) SetAgentResourceRoleArn(v string) *UpdateAgentInput { + s.AgentResourceRoleArn = &v + return s } -func newErrorServiceQuotaExceededException(v protocol.ResponseMetadata) error { - return &ServiceQuotaExceededException{ - RespMetadata: v, - } +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *UpdateAgentInput) SetCustomerEncryptionKeyArn(v string) *UpdateAgentInput { + s.CustomerEncryptionKeyArn = &v + return s } -// Code returns the exception type name. -func (s *ServiceQuotaExceededException) Code() string { - return "ServiceQuotaExceededException" +// SetDescription sets the Description field's value. +func (s *UpdateAgentInput) SetDescription(v string) *UpdateAgentInput { + s.Description = &v + return s } -// Message returns the exception's message. -func (s *ServiceQuotaExceededException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" +// SetFoundationModel sets the FoundationModel field's value. +func (s *UpdateAgentInput) SetFoundationModel(v string) *UpdateAgentInput { + s.FoundationModel = &v + return s } -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ServiceQuotaExceededException) OrigErr() error { - return nil +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *UpdateAgentInput) SetGuardrailConfiguration(v *GuardrailConfiguration) *UpdateAgentInput { + s.GuardrailConfiguration = v + return s } -func (s *ServiceQuotaExceededException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *UpdateAgentInput) SetIdleSessionTTLInSeconds(v int64) *UpdateAgentInput { + s.IdleSessionTTLInSeconds = &v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *ServiceQuotaExceededException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetInstruction sets the Instruction field's value. +func (s *UpdateAgentInput) SetInstruction(v string) *UpdateAgentInput { + s.Instruction = &v + return s } -// RequestID returns the service's response RequestID for request. -func (s *ServiceQuotaExceededException) RequestID() string { - return s.RespMetadata.RequestID +// SetMemoryConfiguration sets the MemoryConfiguration field's value. +func (s *UpdateAgentInput) SetMemoryConfiguration(v *MemoryConfiguration) *UpdateAgentInput { + s.MemoryConfiguration = v + return s } -type StartIngestionJobInput struct { +// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. +func (s *UpdateAgentInput) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *UpdateAgentInput { + s.PromptOverrideConfiguration = v + return s +} + +type UpdateAgentKnowledgeBaseInput struct { _ struct{} `type:"structure"` - // 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 (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" min:"33" type:"string" idempotencyToken:"true"` + // The unique identifier of the agent associated with the knowledge base that + // you want to update. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - // The unique identifier of the data source to ingest. + // The version of the agent associated with the knowledge base that you want + // to update. // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + // AgentVersion is a required field + AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` - // A description of the ingestion job. + // Specifies a new description for the knowledge base associated with an agent. Description *string `locationName:"description" min:"1" type:"string"` - // The unique identifier of the knowledge base to which to add the data source. + // The unique identifier of the knowledge base that has been associated with + // an agent. // // KnowledgeBaseId is a required field KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + + // Specifies whether the agent uses the knowledge base or not when sending an + // InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) + // request. + KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" enum:"KnowledgeBaseState"` } // String returns the string representation. @@ -13015,7 +23904,7 @@ type StartIngestionJobInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StartIngestionJobInput) String() string { +func (s UpdateAgentKnowledgeBaseInput) String() string { return awsutil.Prettify(s) } @@ -13024,21 +23913,24 @@ func (s StartIngestionJobInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StartIngestionJobInput) GoString() string { +func (s UpdateAgentKnowledgeBaseInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *StartIngestionJobInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "StartIngestionJobInput"} - if s.ClientToken != nil && len(*s.ClientToken) < 33 { - invalidParams.Add(request.NewErrParamMinLen("ClientToken", 33)) +func (s *UpdateAgentKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateAgentKnowledgeBaseInput"} + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) } - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) + if s.AgentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + } + if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { + invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) @@ -13056,37 +23948,44 @@ func (s *StartIngestionJobInput) Validate() error { return nil } -// SetClientToken sets the ClientToken field's value. -func (s *StartIngestionJobInput) SetClientToken(v string) *StartIngestionJobInput { - s.ClientToken = &v +// SetAgentId sets the AgentId field's value. +func (s *UpdateAgentKnowledgeBaseInput) SetAgentId(v string) *UpdateAgentKnowledgeBaseInput { + s.AgentId = &v return s } -// SetDataSourceId sets the DataSourceId field's value. -func (s *StartIngestionJobInput) SetDataSourceId(v string) *StartIngestionJobInput { - s.DataSourceId = &v +// SetAgentVersion sets the AgentVersion field's value. +func (s *UpdateAgentKnowledgeBaseInput) SetAgentVersion(v string) *UpdateAgentKnowledgeBaseInput { + s.AgentVersion = &v return s } // SetDescription sets the Description field's value. -func (s *StartIngestionJobInput) SetDescription(v string) *StartIngestionJobInput { +func (s *UpdateAgentKnowledgeBaseInput) SetDescription(v string) *UpdateAgentKnowledgeBaseInput { s.Description = &v return s } // SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *StartIngestionJobInput) SetKnowledgeBaseId(v string) *StartIngestionJobInput { +func (s *UpdateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *UpdateAgentKnowledgeBaseInput { s.KnowledgeBaseId = &v return s } -type StartIngestionJobOutput struct { +// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. +func (s *UpdateAgentKnowledgeBaseInput) SetKnowledgeBaseState(v string) *UpdateAgentKnowledgeBaseInput { + s.KnowledgeBaseState = &v + return s +} + +type UpdateAgentKnowledgeBaseOutput struct { _ struct{} `type:"structure"` - // An object containing information about the ingestion job. + // Contains details about the knowledge base that has been associated with an + // agent. // - // IngestionJob is a required field - IngestionJob *IngestionJob `locationName:"ingestionJob" type:"structure" required:"true"` + // AgentKnowledgeBase is a required field + AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` } // String returns the string representation. @@ -13094,7 +23993,7 @@ type StartIngestionJobOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StartIngestionJobOutput) String() string { +func (s UpdateAgentKnowledgeBaseOutput) String() string { return awsutil.Prettify(s) } @@ -13103,43 +24002,83 @@ func (s StartIngestionJobOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StartIngestionJobOutput) GoString() string { +func (s UpdateAgentKnowledgeBaseOutput) GoString() string { return s.String() } -// SetIngestionJob sets the IngestionJob field's value. -func (s *StartIngestionJobOutput) SetIngestionJob(v *IngestionJob) *StartIngestionJobOutput { - s.IngestionJob = v +// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. +func (s *UpdateAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *UpdateAgentKnowledgeBaseOutput { + s.AgentKnowledgeBase = v return s } -// Contains the storage configuration of the knowledge base. -type StorageConfiguration struct { +type UpdateAgentOutput struct { _ struct{} `type:"structure"` - // Contains the storage configuration of the knowledge base in MongoDB Atlas. - MongoDbAtlasConfiguration *MongoDbAtlasConfiguration `locationName:"mongoDbAtlasConfiguration" type:"structure"` + // Contains details about the agent that was updated. + // + // Agent is a required field + Agent *Agent `locationName:"agent" type:"structure" required:"true"` +} - // Contains the storage configuration of the knowledge base in Amazon OpenSearch - // Service. - OpensearchServerlessConfiguration *OpenSearchServerlessConfiguration `locationName:"opensearchServerlessConfiguration" type:"structure"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdateAgentOutput) String() string { + return awsutil.Prettify(s) +} - // Contains the storage configuration of the knowledge base in Pinecone. - PineconeConfiguration *PineconeConfiguration `locationName:"pineconeConfiguration" type:"structure"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdateAgentOutput) GoString() string { + return s.String() +} - // Contains details about the storage configuration of the knowledge base in - // Amazon RDS. For more information, see Create a vector index in Amazon RDS - // (https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html). - RdsConfiguration *RdsConfiguration `locationName:"rdsConfiguration" type:"structure"` +// SetAgent sets the Agent field's value. +func (s *UpdateAgentOutput) SetAgent(v *Agent) *UpdateAgentOutput { + s.Agent = v + return s +} - // Contains the storage configuration of the knowledge base in Redis Enterprise - // Cloud. - RedisEnterpriseCloudConfiguration *RedisEnterpriseCloudConfiguration `locationName:"redisEnterpriseCloudConfiguration" type:"structure"` +type UpdateDataSourceInput struct { + _ struct{} `type:"structure"` - // The vector store service in which the knowledge base is stored. + // The data deletion policy for the data source that you want to update. + DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` + + // The connection configuration for the data source that you want to update. // - // Type is a required field - Type *string `locationName:"type" type:"string" required:"true" enum:"KnowledgeBaseStorageType"` + // DataSourceConfiguration is a required field + DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` + + // The unique identifier of the data source. + // + // DataSourceId is a required field + DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` + + // Specifies a new description for the data source. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the knowledge base for the data source. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + + // Specifies a new name for the data source. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains details about server-side encryption of the data source. + ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` + + // Contains details about how to ingest the documents in the data source. + VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` } // String returns the string representation. @@ -13147,7 +24086,7 @@ type StorageConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StorageConfiguration) String() string { +func (s UpdateDataSourceInput) String() string { return awsutil.Prettify(s) } @@ -13156,97 +24095,111 @@ func (s StorageConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s StorageConfiguration) GoString() string { +func (s UpdateDataSourceInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *StorageConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "StorageConfiguration"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) +func (s *UpdateDataSourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateDataSourceInput"} + if s.DataSourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceConfiguration")) } - if s.MongoDbAtlasConfiguration != nil { - if err := s.MongoDbAtlasConfiguration.Validate(); err != nil { - invalidParams.AddNested("MongoDbAtlasConfiguration", err.(request.ErrInvalidParams)) - } + if s.DataSourceId == nil { + invalidParams.Add(request.NewErrParamRequired("DataSourceId")) } - if s.OpensearchServerlessConfiguration != nil { - if err := s.OpensearchServerlessConfiguration.Validate(); err != nil { - invalidParams.AddNested("OpensearchServerlessConfiguration", err.(request.ErrInvalidParams)) - } + if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) } - if s.PineconeConfiguration != nil { - if err := s.PineconeConfiguration.Validate(); err != nil { - invalidParams.AddNested("PineconeConfiguration", err.(request.ErrInvalidParams)) + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.DataSourceConfiguration != nil { + if err := s.DataSourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("DataSourceConfiguration", err.(request.ErrInvalidParams)) } } - if s.RdsConfiguration != nil { - if err := s.RdsConfiguration.Validate(); err != nil { - invalidParams.AddNested("RdsConfiguration", err.(request.ErrInvalidParams)) + if s.ServerSideEncryptionConfiguration != nil { + if err := s.ServerSideEncryptionConfiguration.Validate(); err != nil { + invalidParams.AddNested("ServerSideEncryptionConfiguration", err.(request.ErrInvalidParams)) } } - if s.RedisEnterpriseCloudConfiguration != nil { - if err := s.RedisEnterpriseCloudConfiguration.Validate(); err != nil { - invalidParams.AddNested("RedisEnterpriseCloudConfiguration", err.(request.ErrInvalidParams)) + if s.VectorIngestionConfiguration != nil { + if err := s.VectorIngestionConfiguration.Validate(); err != nil { + invalidParams.AddNested("VectorIngestionConfiguration", err.(request.ErrInvalidParams)) } } - if invalidParams.Len() > 0 { - return invalidParams - } - return nil + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. +func (s *UpdateDataSourceInput) SetDataDeletionPolicy(v string) *UpdateDataSourceInput { + s.DataDeletionPolicy = &v + return s +} + +// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. +func (s *UpdateDataSourceInput) SetDataSourceConfiguration(v *DataSourceConfiguration) *UpdateDataSourceInput { + s.DataSourceConfiguration = v + return s } -// SetMongoDbAtlasConfiguration sets the MongoDbAtlasConfiguration field's value. -func (s *StorageConfiguration) SetMongoDbAtlasConfiguration(v *MongoDbAtlasConfiguration) *StorageConfiguration { - s.MongoDbAtlasConfiguration = v +// SetDataSourceId sets the DataSourceId field's value. +func (s *UpdateDataSourceInput) SetDataSourceId(v string) *UpdateDataSourceInput { + s.DataSourceId = &v return s } -// SetOpensearchServerlessConfiguration sets the OpensearchServerlessConfiguration field's value. -func (s *StorageConfiguration) SetOpensearchServerlessConfiguration(v *OpenSearchServerlessConfiguration) *StorageConfiguration { - s.OpensearchServerlessConfiguration = v +// SetDescription sets the Description field's value. +func (s *UpdateDataSourceInput) SetDescription(v string) *UpdateDataSourceInput { + s.Description = &v return s } -// SetPineconeConfiguration sets the PineconeConfiguration field's value. -func (s *StorageConfiguration) SetPineconeConfiguration(v *PineconeConfiguration) *StorageConfiguration { - s.PineconeConfiguration = v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *UpdateDataSourceInput) SetKnowledgeBaseId(v string) *UpdateDataSourceInput { + s.KnowledgeBaseId = &v return s } -// SetRdsConfiguration sets the RdsConfiguration field's value. -func (s *StorageConfiguration) SetRdsConfiguration(v *RdsConfiguration) *StorageConfiguration { - s.RdsConfiguration = v +// SetName sets the Name field's value. +func (s *UpdateDataSourceInput) SetName(v string) *UpdateDataSourceInput { + s.Name = &v return s } -// SetRedisEnterpriseCloudConfiguration sets the RedisEnterpriseCloudConfiguration field's value. -func (s *StorageConfiguration) SetRedisEnterpriseCloudConfiguration(v *RedisEnterpriseCloudConfiguration) *StorageConfiguration { - s.RedisEnterpriseCloudConfiguration = v +// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. +func (s *UpdateDataSourceInput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *UpdateDataSourceInput { + s.ServerSideEncryptionConfiguration = v return s } -// SetType sets the Type field's value. -func (s *StorageConfiguration) SetType(v string) *StorageConfiguration { - s.Type = &v +// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. +func (s *UpdateDataSourceInput) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *UpdateDataSourceInput { + s.VectorIngestionConfiguration = v return s } -type TagResourceInput struct { +type UpdateDataSourceOutput struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the resource to tag. - // - // ResourceArn is a required field - ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` - - // An object containing key-value pairs that define the tags to attach to the - // resource. + // Contains details about the data source. // - // Tags is a required field - Tags map[string]*string `locationName:"tags" type:"map" required:"true"` + // DataSource is a required field + DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` } // String returns the string representation. @@ -13254,7 +24207,7 @@ type TagResourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s TagResourceInput) String() string { +func (s UpdateDataSourceOutput) String() string { return awsutil.Prettify(s) } @@ -13263,69 +24216,41 @@ func (s TagResourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s TagResourceInput) GoString() string { +func (s UpdateDataSourceOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *TagResourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} - if s.ResourceArn == nil { - invalidParams.Add(request.NewErrParamRequired("ResourceArn")) - } - if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { - invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) - } - if s.Tags == nil { - invalidParams.Add(request.NewErrParamRequired("Tags")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetResourceArn sets the ResourceArn field's value. -func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput { - s.ResourceArn = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TagResourceInput) SetTags(v map[string]*string) *TagResourceInput { - s.Tags = v +// SetDataSource sets the DataSource field's value. +func (s *UpdateDataSourceOutput) SetDataSource(v *DataSource) *UpdateDataSourceOutput { + s.DataSource = v return s } -type TagResourceOutput struct { +type UpdateFlowAliasInput struct { _ struct{} `type:"structure"` -} -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s TagResourceOutput) String() string { - return awsutil.Prettify(s) -} + // The unique identifier of the alias. + // + // AliasIdentifier is a required field + AliasIdentifier *string `location:"uri" locationName:"aliasIdentifier" type:"string" required:"true"` -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s TagResourceOutput) GoString() string { - return s.String() -} + // A description for the flow alias. + Description *string `locationName:"description" min:"1" type:"string"` -// The number of requests exceeds the limit. Resubmit your request later. -type ThrottlingException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + // The unique identifier of the flow. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` - Message_ *string `locationName:"message" type:"string"` + // The name of the flow alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains information about the version to which to map the alias. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` } // String returns the string representation. @@ -13333,7 +24258,7 @@ type ThrottlingException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ThrottlingException) String() string { +func (s UpdateFlowAliasInput) String() string { return awsutil.Prettify(s) } @@ -13342,60 +24267,124 @@ func (s ThrottlingException) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ThrottlingException) GoString() string { +func (s UpdateFlowAliasInput) GoString() string { return s.String() } -func newErrorThrottlingException(v protocol.ResponseMetadata) error { - return &ThrottlingException{ - RespMetadata: v, +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateFlowAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateFlowAliasInput"} + if s.AliasIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("AliasIdentifier")) + } + if s.AliasIdentifier != nil && len(*s.AliasIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AliasIdentifier", 1)) + } + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.RoutingConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("RoutingConfiguration")) + } + if s.RoutingConfiguration != nil && len(s.RoutingConfiguration) < 1 { + invalidParams.Add(request.NewErrParamMinLen("RoutingConfiguration", 1)) + } + if s.RoutingConfiguration != nil { + for i, v := range s.RoutingConfiguration { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) + } + } } -} -// Code returns the exception type name. -func (s *ThrottlingException) Code() string { - return "ThrottlingException" + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// Message returns the exception's message. -func (s *ThrottlingException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" +// SetAliasIdentifier sets the AliasIdentifier field's value. +func (s *UpdateFlowAliasInput) SetAliasIdentifier(v string) *UpdateFlowAliasInput { + s.AliasIdentifier = &v + return s } -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ThrottlingException) OrigErr() error { - return nil +// SetDescription sets the Description field's value. +func (s *UpdateFlowAliasInput) SetDescription(v string) *UpdateFlowAliasInput { + s.Description = &v + return s } -func (s *ThrottlingException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *UpdateFlowAliasInput) SetFlowIdentifier(v string) *UpdateFlowAliasInput { + s.FlowIdentifier = &v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *ThrottlingException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetName sets the Name field's value. +func (s *UpdateFlowAliasInput) SetName(v string) *UpdateFlowAliasInput { + s.Name = &v + return s } -// RequestID returns the service's response RequestID for request. -func (s *ThrottlingException) RequestID() string { - return s.RespMetadata.RequestID +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *UpdateFlowAliasInput) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *UpdateFlowAliasInput { + s.RoutingConfiguration = v + return s } -type UntagResourceInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type UpdateFlowAliasOutput struct { + _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the resource from which to remove tags. + // The Amazon Resource Name (ARN) of the flow. // - // ResourceArn is a required field - ResourceArn *string `location:"uri" locationName:"resourceArn" min:"20" type:"string" required:"true"` + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` - // A list of keys of the tags to remove from the resource. + // The time at which the flow was created. // - // TagKeys is a required field - TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true"` + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the flow. + // + // FlowId is a required field + FlowId *string `locationName:"flowId" type:"string" required:"true"` + + // The unique identifier of the alias. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the flow alias. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Contains information about the version that the alias is mapped to. + // + // RoutingConfiguration is a required field + RoutingConfiguration []*FlowAliasRoutingConfigurationListItem `locationName:"routingConfiguration" min:"1" type:"list" required:"true"` + + // The time at which the flow alias was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` } // String returns the string representation. @@ -13403,7 +24392,7 @@ type UntagResourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UntagResourceInput) String() string { +func (s UpdateFlowAliasOutput) String() string { return awsutil.Prettify(s) } @@ -13412,119 +24401,87 @@ func (s UntagResourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UntagResourceInput) GoString() string { +func (s UpdateFlowAliasOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *UntagResourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} - if s.ResourceArn == nil { - invalidParams.Add(request.NewErrParamRequired("ResourceArn")) - } - if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { - invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) - } - if s.TagKeys == nil { - invalidParams.Add(request.NewErrParamRequired("TagKeys")) - } +// SetArn sets the Arn field's value. +func (s *UpdateFlowAliasOutput) SetArn(v string) *UpdateFlowAliasOutput { + s.Arn = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetCreatedAt sets the CreatedAt field's value. +func (s *UpdateFlowAliasOutput) SetCreatedAt(v time.Time) *UpdateFlowAliasOutput { + s.CreatedAt = &v + return s } -// SetResourceArn sets the ResourceArn field's value. -func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput { - s.ResourceArn = &v +// SetDescription sets the Description field's value. +func (s *UpdateFlowAliasOutput) SetDescription(v string) *UpdateFlowAliasOutput { + s.Description = &v return s } -// SetTagKeys sets the TagKeys field's value. -func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { - s.TagKeys = v +// SetFlowId sets the FlowId field's value. +func (s *UpdateFlowAliasOutput) SetFlowId(v string) *UpdateFlowAliasOutput { + s.FlowId = &v return s } -type UntagResourceOutput struct { - _ struct{} `type:"structure"` +// SetId sets the Id field's value. +func (s *UpdateFlowAliasOutput) SetId(v string) *UpdateFlowAliasOutput { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *UpdateFlowAliasOutput) SetName(v string) *UpdateFlowAliasOutput { + s.Name = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UntagResourceOutput) String() string { - return awsutil.Prettify(s) +// SetRoutingConfiguration sets the RoutingConfiguration field's value. +func (s *UpdateFlowAliasOutput) SetRoutingConfiguration(v []*FlowAliasRoutingConfigurationListItem) *UpdateFlowAliasOutput { + s.RoutingConfiguration = v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UntagResourceOutput) GoString() string { - return s.String() +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *UpdateFlowAliasOutput) SetUpdatedAt(v time.Time) *UpdateFlowAliasOutput { + s.UpdatedAt = &v + return s } -type UpdateAgentActionGroupInput struct { +type UpdateFlowInput struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the Lambda function containing the business - // logic that is carried out upon invoking the action. - ActionGroupExecutor *ActionGroupExecutor `locationName:"actionGroupExecutor" type:"structure"` - - // The unique identifier of the action group. - // - // ActionGroupId is a required field - ActionGroupId *string `location:"uri" locationName:"actionGroupId" type:"string" required:"true"` + // The Amazon Resource Name (ARN) of the KMS key to encrypt the flow. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - // Specifies a new name for the action group. - // - // ActionGroupName is a required field - ActionGroupName *string `locationName:"actionGroupName" type:"string" required:"true"` + // A definition of the nodes and the connections between the nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` - // Specifies whether the action group is available for the agent to invoke or - // not when sending an InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. - ActionGroupState *string `locationName:"actionGroupState" type:"string" enum:"ActionGroupState"` + // A description for the flow. + Description *string `locationName:"description" min:"1" type:"string"` - // The unique identifier of the agent for which to update the action group. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` - // The unique identifier of the agent version for which to update the action - // group. + // The unique identifier of the flow. // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` - // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html). - ApiSchema *APISchema `locationName:"apiSchema" type:"structure"` - - // Specifies a new name for the action group. - Description *string `locationName:"description" min:"1" type:"string"` - - // Contains details about the function schema for the action group or the JSON - // or YAML-formatted payload defining the schema. - FunctionSchema *FunctionSchema `locationName:"functionSchema" type:"structure"` - - // 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. + // A name for the flow. // - // 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 - // (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html) - // reprompting the user for more information. - ParentActionGroupSignature *string `locationName:"parentActionGroupSignature" type:"string" enum:"ActionGroupSignature"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` } // String returns the string representation. @@ -13532,7 +24489,7 @@ type UpdateAgentActionGroupInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentActionGroupInput) String() string { +func (s UpdateFlowInput) String() string { return awsutil.Prettify(s) } @@ -13541,45 +24498,34 @@ func (s UpdateAgentActionGroupInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentActionGroupInput) GoString() string { +func (s UpdateFlowInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateAgentActionGroupInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateAgentActionGroupInput"} - if s.ActionGroupId == nil { - invalidParams.Add(request.NewErrParamRequired("ActionGroupId")) - } - if s.ActionGroupId != nil && len(*s.ActionGroupId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("ActionGroupId", 1)) - } - if s.ActionGroupName == nil { - invalidParams.Add(request.NewErrParamRequired("ActionGroupName")) - } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) +func (s *UpdateFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateFlowInput"} + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) + if s.ExecutionRoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("ExecutionRoleArn")) } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) } - if s.ApiSchema != nil { - if err := s.ApiSchema.Validate(); err != nil { - invalidParams.AddNested("ApiSchema", err.(request.ErrInvalidParams)) - } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) } - if s.FunctionSchema != nil { - if err := s.FunctionSchema.Validate(); err != nil { - invalidParams.AddNested("FunctionSchema", err.(request.ErrInvalidParams)) + if s.Definition != nil { + if err := s.Definition.Validate(); err != nil { + invalidParams.AddNested("Definition", err.(request.ErrInvalidParams)) } } @@ -13589,122 +24535,99 @@ func (s *UpdateAgentActionGroupInput) Validate() error { return nil } -// SetActionGroupExecutor sets the ActionGroupExecutor field's value. -func (s *UpdateAgentActionGroupInput) SetActionGroupExecutor(v *ActionGroupExecutor) *UpdateAgentActionGroupInput { - s.ActionGroupExecutor = v - return s -} - -// SetActionGroupId sets the ActionGroupId field's value. -func (s *UpdateAgentActionGroupInput) SetActionGroupId(v string) *UpdateAgentActionGroupInput { - s.ActionGroupId = &v - return s -} - -// SetActionGroupName sets the ActionGroupName field's value. -func (s *UpdateAgentActionGroupInput) SetActionGroupName(v string) *UpdateAgentActionGroupInput { - s.ActionGroupName = &v - return s -} - -// SetActionGroupState sets the ActionGroupState field's value. -func (s *UpdateAgentActionGroupInput) SetActionGroupState(v string) *UpdateAgentActionGroupInput { - s.ActionGroupState = &v - return s -} - -// SetAgentId sets the AgentId field's value. -func (s *UpdateAgentActionGroupInput) SetAgentId(v string) *UpdateAgentActionGroupInput { - s.AgentId = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *UpdateFlowInput) SetCustomerEncryptionKeyArn(v string) *UpdateFlowInput { + s.CustomerEncryptionKeyArn = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *UpdateAgentActionGroupInput) SetAgentVersion(v string) *UpdateAgentActionGroupInput { - s.AgentVersion = &v +// SetDefinition sets the Definition field's value. +func (s *UpdateFlowInput) SetDefinition(v *FlowDefinition) *UpdateFlowInput { + s.Definition = v return s } -// SetApiSchema sets the ApiSchema field's value. -func (s *UpdateAgentActionGroupInput) SetApiSchema(v *APISchema) *UpdateAgentActionGroupInput { - s.ApiSchema = v +// SetDescription sets the Description field's value. +func (s *UpdateFlowInput) SetDescription(v string) *UpdateFlowInput { + s.Description = &v return s } -// SetDescription sets the Description field's value. -func (s *UpdateAgentActionGroupInput) SetDescription(v string) *UpdateAgentActionGroupInput { - s.Description = &v +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *UpdateFlowInput) SetExecutionRoleArn(v string) *UpdateFlowInput { + s.ExecutionRoleArn = &v return s } -// SetFunctionSchema sets the FunctionSchema field's value. -func (s *UpdateAgentActionGroupInput) SetFunctionSchema(v *FunctionSchema) *UpdateAgentActionGroupInput { - s.FunctionSchema = v +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *UpdateFlowInput) SetFlowIdentifier(v string) *UpdateFlowInput { + s.FlowIdentifier = &v return s } -// SetParentActionGroupSignature sets the ParentActionGroupSignature field's value. -func (s *UpdateAgentActionGroupInput) SetParentActionGroupSignature(v string) *UpdateAgentActionGroupInput { - s.ParentActionGroupSignature = &v +// SetName sets the Name field's value. +func (s *UpdateFlowInput) SetName(v string) *UpdateFlowInput { + s.Name = &v return s } -type UpdateAgentActionGroupOutput struct { +type UpdateFlowOutput struct { _ struct{} `type:"structure"` - // Contains details about the action group that was updated. + // The Amazon Resource Name (ARN) of the flow. // - // AgentActionGroup is a required field - AgentActionGroup *AgentActionGroup `locationName:"agentActionGroup" type:"structure" required:"true"` -} + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentActionGroupOutput) String() string { - return awsutil.Prettify(s) -} + // The time at which the flow was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentActionGroupOutput) GoString() string { - return s.String() -} + // The Amazon Resource Name (ARN) of the KMS key that the flow was encrypted + // with. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` -// SetAgentActionGroup sets the AgentActionGroup field's value. -func (s *UpdateAgentActionGroupOutput) SetAgentActionGroup(v *AgentActionGroup) *UpdateAgentActionGroupOutput { - s.AgentActionGroup = v - return s -} + // A definition of the nodes and the connections between nodes in the flow. + Definition *FlowDefinition `locationName:"definition" type:"structure"` -type UpdateAgentAliasInput struct { - _ struct{} `type:"structure"` + // The description of the flow. + Description *string `locationName:"description" min:"1" type:"string"` - // The unique identifier of the alias. + // 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 (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-permissions.html) + // in the Amazon Bedrock User Guide. // - // AgentAliasId is a required field - AgentAliasId *string `location:"uri" locationName:"agentAliasId" min:"10" type:"string" required:"true"` + // ExecutionRoleArn is a required field + ExecutionRoleArn *string `locationName:"executionRoleArn" type:"string" required:"true"` - // Specifies a new name for the alias. + // The unique identifier of the flow. // - // AgentAliasName is a required field - AgentAliasName *string `locationName:"agentAliasName" type:"string" required:"true"` + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` - // The unique identifier of the agent. + // The name of the flow. // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // Specifies a new description for the alias. - Description *string `locationName:"description" min:"1" type:"string"` + // The status of the flow. When you submit this request, the status will be + // NotPrepared. If updating fails, the status becomes Failed. + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true" enum:"FlowStatus"` - // Contains details about the routing configuration of the alias. - RoutingConfiguration []*AgentAliasRoutingConfigurationListItem `locationName:"routingConfiguration" type:"list"` + // The time at which the flow was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The version of the flow. When you update a flow, the version updated is the + // DRAFT version. + // + // Version is a required field + Version *string `locationName:"version" min:"5" type:"string" required:"true"` } // String returns the string representation. @@ -13712,7 +24635,7 @@ type UpdateAgentAliasInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentAliasInput) String() string { +func (s UpdateFlowOutput) String() string { return awsutil.Prettify(s) } @@ -13721,167 +24644,110 @@ func (s UpdateAgentAliasInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentAliasInput) GoString() string { +func (s UpdateFlowOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateAgentAliasInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateAgentAliasInput"} - if s.AgentAliasId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) - } - if s.AgentAliasId != nil && len(*s.AgentAliasId) < 10 { - invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 10)) - } - if s.AgentAliasName == nil { - invalidParams.Add(request.NewErrParamRequired("AgentAliasName")) - } - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.RoutingConfiguration != nil { - for i, v := range s.RoutingConfiguration { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingConfiguration", i), err.(request.ErrInvalidParams)) - } - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetArn sets the Arn field's value. +func (s *UpdateFlowOutput) SetArn(v string) *UpdateFlowOutput { + s.Arn = &v + return s } -// SetAgentAliasId sets the AgentAliasId field's value. -func (s *UpdateAgentAliasInput) SetAgentAliasId(v string) *UpdateAgentAliasInput { - s.AgentAliasId = &v +// SetCreatedAt sets the CreatedAt field's value. +func (s *UpdateFlowOutput) SetCreatedAt(v time.Time) *UpdateFlowOutput { + s.CreatedAt = &v return s } -// SetAgentAliasName sets the AgentAliasName field's value. -func (s *UpdateAgentAliasInput) SetAgentAliasName(v string) *UpdateAgentAliasInput { - s.AgentAliasName = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *UpdateFlowOutput) SetCustomerEncryptionKeyArn(v string) *UpdateFlowOutput { + s.CustomerEncryptionKeyArn = &v return s } -// SetAgentId sets the AgentId field's value. -func (s *UpdateAgentAliasInput) SetAgentId(v string) *UpdateAgentAliasInput { - s.AgentId = &v +// SetDefinition sets the Definition field's value. +func (s *UpdateFlowOutput) SetDefinition(v *FlowDefinition) *UpdateFlowOutput { + s.Definition = v return s } // SetDescription sets the Description field's value. -func (s *UpdateAgentAliasInput) SetDescription(v string) *UpdateAgentAliasInput { +func (s *UpdateFlowOutput) SetDescription(v string) *UpdateFlowOutput { s.Description = &v return s } -// SetRoutingConfiguration sets the RoutingConfiguration field's value. -func (s *UpdateAgentAliasInput) SetRoutingConfiguration(v []*AgentAliasRoutingConfigurationListItem) *UpdateAgentAliasInput { - s.RoutingConfiguration = v +// SetExecutionRoleArn sets the ExecutionRoleArn field's value. +func (s *UpdateFlowOutput) SetExecutionRoleArn(v string) *UpdateFlowOutput { + s.ExecutionRoleArn = &v return s } -type UpdateAgentAliasOutput struct { - _ struct{} `type:"structure"` +// SetId sets the Id field's value. +func (s *UpdateFlowOutput) SetId(v string) *UpdateFlowOutput { + s.Id = &v + return s +} - // Contains details about the alias that was updated. - // - // AgentAlias is a required field - AgentAlias *AgentAlias `locationName:"agentAlias" type:"structure" required:"true"` +// SetName sets the Name field's value. +func (s *UpdateFlowOutput) SetName(v string) *UpdateFlowOutput { + s.Name = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentAliasOutput) String() string { - return awsutil.Prettify(s) +// SetStatus sets the Status field's value. +func (s *UpdateFlowOutput) SetStatus(v string) *UpdateFlowOutput { + s.Status = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentAliasOutput) GoString() string { - return s.String() +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *UpdateFlowOutput) SetUpdatedAt(v time.Time) *UpdateFlowOutput { + s.UpdatedAt = &v + return s } -// SetAgentAlias sets the AgentAlias field's value. -func (s *UpdateAgentAliasOutput) SetAgentAlias(v *AgentAlias) *UpdateAgentAliasOutput { - s.AgentAlias = v +// SetVersion sets the Version field's value. +func (s *UpdateFlowOutput) SetVersion(v string) *UpdateFlowOutput { + s.Version = &v return s } -type UpdateAgentInput struct { +type UpdateKnowledgeBaseInput struct { _ struct{} `type:"structure"` - // The unique identifier of the agent. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - - // Specifies a new name for the agent. - // - // AgentName is a required field - AgentName *string `locationName:"agentName" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the IAM role with permissions to invoke - // API operations on the agent. - // - // AgentResourceRoleArn is a required field - AgentResourceRoleArn *string `locationName:"agentResourceRoleArn" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the KMS key with which to encrypt the agent. - CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - - // Specifies a new description of the agent. + // Specifies a new description for the knowledge base. Description *string `locationName:"description" min:"1" type:"string"` - // Specifies a new foundation model to be used for orchestration by the agent. + // 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. // - // FoundationModel is a required field - FoundationModel *string `locationName:"foundationModel" min:"1" type:"string" required:"true"` + // KnowledgeBaseConfiguration is a required field + KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` - // The unique Guardrail configuration assigned to the agent when it is updated. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + // The unique identifier of the knowledge base to update. + // + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` - // The number of seconds for which Amazon Bedrock keeps information about a - // user's conversation with the agent. + // Specifies a new name for the knowledge base. // - // 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. - IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // Specifies new instructions that tell the agent what it should do and how - // it should interact with users. + // Specifies a different Amazon Resource Name (ARN) of the IAM role with permissions + // to invoke API operations on the knowledge base. // - // Instruction is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by UpdateAgentInput's - // String and GoString methods. - Instruction *string `locationName:"instruction" min:"40" type:"string" sensitive:"true"` + // RoleArn is a required field + RoleArn *string `locationName:"roleArn" type:"string" required:"true"` - // Contains configurations to override prompts in different parts of an agent - // sequence. For more information, see Advanced prompts (https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html). + // 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. // - // PromptOverrideConfiguration is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by UpdateAgentInput's - // String and GoString methods. - PromptOverrideConfiguration *PromptOverrideConfiguration `locationName:"promptOverrideConfiguration" type:"structure" sensitive:"true"` + // StorageConfiguration is a required field + StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -13889,7 +24755,7 @@ type UpdateAgentInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentInput) String() string { +func (s UpdateKnowledgeBaseInput) String() string { return awsutil.Prettify(s) } @@ -13898,46 +24764,42 @@ func (s UpdateAgentInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentInput) GoString() string { +func (s UpdateKnowledgeBaseInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateAgentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateAgentInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentName == nil { - invalidParams.Add(request.NewErrParamRequired("AgentName")) +func (s *UpdateKnowledgeBaseInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateKnowledgeBaseInput"} + if s.Description != nil && len(*s.Description) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } - if s.AgentResourceRoleArn == nil { - invalidParams.Add(request.NewErrParamRequired("AgentResourceRoleArn")) + if s.KnowledgeBaseConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseConfiguration")) } - if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { - invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) + if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) } - if s.FoundationModel == nil { - invalidParams.Add(request.NewErrParamRequired("FoundationModel")) + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) } - if s.FoundationModel != nil && len(*s.FoundationModel) < 1 { - invalidParams.Add(request.NewErrParamMinLen("FoundationModel", 1)) + if s.RoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("RoleArn")) } - if s.IdleSessionTTLInSeconds != nil && *s.IdleSessionTTLInSeconds < 60 { - invalidParams.Add(request.NewErrParamMinValue("IdleSessionTTLInSeconds", 60)) + if s.StorageConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("StorageConfiguration")) } - if s.Instruction != nil && len(*s.Instruction) < 40 { - invalidParams.Add(request.NewErrParamMinLen("Instruction", 40)) + if s.KnowledgeBaseConfiguration != nil { + if err := s.KnowledgeBaseConfiguration.Validate(); err != nil { + invalidParams.AddNested("KnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) + } } - if s.PromptOverrideConfiguration != nil { - if err := s.PromptOverrideConfiguration.Validate(); err != nil { - invalidParams.AddNested("PromptOverrideConfiguration", err.(request.ErrInvalidParams)) + if s.StorageConfiguration != nil { + if err := s.StorageConfiguration.Validate(); err != nil { + invalidParams.AddNested("StorageConfiguration", err.(request.ErrInvalidParams)) } } @@ -13947,94 +24809,105 @@ func (s *UpdateAgentInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *UpdateAgentInput) SetAgentId(v string) *UpdateAgentInput { - s.AgentId = &v +// SetDescription sets the Description field's value. +func (s *UpdateKnowledgeBaseInput) SetDescription(v string) *UpdateKnowledgeBaseInput { + s.Description = &v return s } -// SetAgentName sets the AgentName field's value. -func (s *UpdateAgentInput) SetAgentName(v string) *UpdateAgentInput { - s.AgentName = &v +// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. +func (s *UpdateKnowledgeBaseInput) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *UpdateKnowledgeBaseInput { + s.KnowledgeBaseConfiguration = v return s } -// SetAgentResourceRoleArn sets the AgentResourceRoleArn field's value. -func (s *UpdateAgentInput) SetAgentResourceRoleArn(v string) *UpdateAgentInput { - s.AgentResourceRoleArn = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *UpdateKnowledgeBaseInput) SetKnowledgeBaseId(v string) *UpdateKnowledgeBaseInput { + s.KnowledgeBaseId = &v return s } -// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. -func (s *UpdateAgentInput) SetCustomerEncryptionKeyArn(v string) *UpdateAgentInput { - s.CustomerEncryptionKeyArn = &v +// SetName sets the Name field's value. +func (s *UpdateKnowledgeBaseInput) SetName(v string) *UpdateKnowledgeBaseInput { + s.Name = &v return s } -// SetDescription sets the Description field's value. -func (s *UpdateAgentInput) SetDescription(v string) *UpdateAgentInput { - s.Description = &v +// SetRoleArn sets the RoleArn field's value. +func (s *UpdateKnowledgeBaseInput) SetRoleArn(v string) *UpdateKnowledgeBaseInput { + s.RoleArn = &v return s } -// SetFoundationModel sets the FoundationModel field's value. -func (s *UpdateAgentInput) SetFoundationModel(v string) *UpdateAgentInput { - s.FoundationModel = &v +// SetStorageConfiguration sets the StorageConfiguration field's value. +func (s *UpdateKnowledgeBaseInput) SetStorageConfiguration(v *StorageConfiguration) *UpdateKnowledgeBaseInput { + s.StorageConfiguration = v return s } -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *UpdateAgentInput) SetGuardrailConfiguration(v *GuardrailConfiguration) *UpdateAgentInput { - s.GuardrailConfiguration = v - return s +type UpdateKnowledgeBaseOutput struct { + _ struct{} `type:"structure"` + + // Contains details about the knowledge base. + // + // KnowledgeBase is a required field + KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` } -// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. -func (s *UpdateAgentInput) SetIdleSessionTTLInSeconds(v int64) *UpdateAgentInput { - s.IdleSessionTTLInSeconds = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdateKnowledgeBaseOutput) String() string { + return awsutil.Prettify(s) } -// SetInstruction sets the Instruction field's value. -func (s *UpdateAgentInput) SetInstruction(v string) *UpdateAgentInput { - s.Instruction = &v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdateKnowledgeBaseOutput) GoString() string { + return s.String() } -// SetPromptOverrideConfiguration sets the PromptOverrideConfiguration field's value. -func (s *UpdateAgentInput) SetPromptOverrideConfiguration(v *PromptOverrideConfiguration) *UpdateAgentInput { - s.PromptOverrideConfiguration = v +// SetKnowledgeBase sets the KnowledgeBase field's value. +func (s *UpdateKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *UpdateKnowledgeBaseOutput { + s.KnowledgeBase = v return s } -type UpdateAgentKnowledgeBaseInput struct { +type UpdatePromptInput struct { _ struct{} `type:"structure"` - // The unique identifier of the agent associated with the knowledge base that - // you want to update. - // - // AgentId is a required field - AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` - - // The version of the agent associated with the knowledge base that you want - // to update. - // - // AgentVersion is a required field - AgentVersion *string `location:"uri" locationName:"agentVersion" min:"5" type:"string" required:"true"` + // The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` - // Specifies a new description for the knowledge base associated with an agent. + // The name of the default variant for the prompt. This value must match the + // name field in the relevant PromptVariant (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptVariant.html) + // object. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // A description for the prompt. Description *string `locationName:"description" min:"1" type:"string"` - // The unique identifier of the knowledge base that has been associated with - // an agent. + // A name for the prompt. // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` - // Specifies whether the agent uses the knowledge base or not when sending an - // InvokeAgent (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html) - // request. - KnowledgeBaseState *string `locationName:"knowledgeBaseState" type:"string" enum:"KnowledgeBaseState"` + // The unique identifier of the prompt. + // + // PromptIdentifier is a required field + PromptIdentifier *string `location:"uri" locationName:"promptIdentifier" type:"string" required:"true"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by UpdatePromptInput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` } // String returns the string representation. @@ -14042,7 +24915,7 @@ type UpdateAgentKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentKnowledgeBaseInput) String() string { +func (s UpdatePromptInput) String() string { return awsutil.Prettify(s) } @@ -14051,33 +24924,37 @@ func (s UpdateAgentKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentKnowledgeBaseInput) GoString() string { +func (s UpdatePromptInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateAgentKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateAgentKnowledgeBaseInput"} - if s.AgentId == nil { - invalidParams.Add(request.NewErrParamRequired("AgentId")) - } - if s.AgentId != nil && len(*s.AgentId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) - } - if s.AgentVersion == nil { - invalidParams.Add(request.NewErrParamRequired("AgentVersion")) - } - if s.AgentVersion != nil && len(*s.AgentVersion) < 5 { - invalidParams.Add(request.NewErrParamMinLen("AgentVersion", 5)) +func (s *UpdatePromptInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdatePromptInput"} + if s.CustomerEncryptionKeyArn != nil && len(*s.CustomerEncryptionKeyArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("CustomerEncryptionKeyArn", 1)) } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) + if s.PromptIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("PromptIdentifier")) + } + if s.PromptIdentifier != nil && len(*s.PromptIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PromptIdentifier", 1)) + } + if s.Variants != nil { + for i, v := range s.Variants { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Variants", i), err.(request.ErrInvalidParams)) + } + } } if invalidParams.Len() > 0 { @@ -14086,44 +24963,93 @@ func (s *UpdateAgentKnowledgeBaseInput) Validate() error { return nil } -// SetAgentId sets the AgentId field's value. -func (s *UpdateAgentKnowledgeBaseInput) SetAgentId(v string) *UpdateAgentKnowledgeBaseInput { - s.AgentId = &v +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *UpdatePromptInput) SetCustomerEncryptionKeyArn(v string) *UpdatePromptInput { + s.CustomerEncryptionKeyArn = &v return s } -// SetAgentVersion sets the AgentVersion field's value. -func (s *UpdateAgentKnowledgeBaseInput) SetAgentVersion(v string) *UpdateAgentKnowledgeBaseInput { - s.AgentVersion = &v +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *UpdatePromptInput) SetDefaultVariant(v string) *UpdatePromptInput { + s.DefaultVariant = &v return s } // SetDescription sets the Description field's value. -func (s *UpdateAgentKnowledgeBaseInput) SetDescription(v string) *UpdateAgentKnowledgeBaseInput { +func (s *UpdatePromptInput) SetDescription(v string) *UpdatePromptInput { s.Description = &v return s } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *UpdateAgentKnowledgeBaseInput) SetKnowledgeBaseId(v string) *UpdateAgentKnowledgeBaseInput { - s.KnowledgeBaseId = &v +// SetName sets the Name field's value. +func (s *UpdatePromptInput) SetName(v string) *UpdatePromptInput { + s.Name = &v return s } -// SetKnowledgeBaseState sets the KnowledgeBaseState field's value. -func (s *UpdateAgentKnowledgeBaseInput) SetKnowledgeBaseState(v string) *UpdateAgentKnowledgeBaseInput { - s.KnowledgeBaseState = &v +// SetPromptIdentifier sets the PromptIdentifier field's value. +func (s *UpdatePromptInput) SetPromptIdentifier(v string) *UpdatePromptInput { + s.PromptIdentifier = &v return s } -type UpdateAgentKnowledgeBaseOutput struct { +// SetVariants sets the Variants field's value. +func (s *UpdatePromptInput) SetVariants(v []*PromptVariant) *UpdatePromptInput { + s.Variants = v + return s +} + +type UpdatePromptOutput struct { _ struct{} `type:"structure"` - // Contains details about the knowledge base that has been associated with an - // agent. + // The Amazon Resource Name (ARN) of the prompt. // - // AgentKnowledgeBase is a required field - AgentKnowledgeBase *AgentKnowledgeBase `locationName:"agentKnowledgeBase" type:"structure" required:"true"` + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` + + // The time at which the prompt was created. + // + // CreatedAt is a required field + CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt. + CustomerEncryptionKeyArn *string `locationName:"customerEncryptionKeyArn" min:"1" type:"string"` + + // The name of the default variant for the prompt. This value must match the + // name field in the relevant PromptVariant (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptVariant.html) + // object. + DefaultVariant *string `locationName:"defaultVariant" type:"string"` + + // The description of the prompt. + Description *string `locationName:"description" min:"1" type:"string"` + + // The unique identifier of the prompt. + // + // Id is a required field + Id *string `locationName:"id" type:"string" required:"true"` + + // The name of the prompt. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // The time at which the prompt was last updated. + // + // UpdatedAt is a required field + UpdatedAt *time.Time `locationName:"updatedAt" type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // A list of objects, each containing details about a variant of the prompt. + // + // Variants is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by UpdatePromptOutput's + // String and GoString methods. + Variants []*PromptVariant `locationName:"variants" type:"list" sensitive:"true"` + + // The version of the prompt. When you update a prompt, the version updated + // is the DRAFT version. + // + // Version is a required field + Version *string `locationName:"version" min:"1" type:"string" required:"true"` } // String returns the string representation. @@ -14131,7 +25057,7 @@ type UpdateAgentKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentKnowledgeBaseOutput) String() string { +func (s UpdatePromptOutput) String() string { return awsutil.Prettify(s) } @@ -14140,83 +25066,77 @@ func (s UpdateAgentKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateAgentKnowledgeBaseOutput) GoString() string { +func (s UpdatePromptOutput) GoString() string { return s.String() } -// SetAgentKnowledgeBase sets the AgentKnowledgeBase field's value. -func (s *UpdateAgentKnowledgeBaseOutput) SetAgentKnowledgeBase(v *AgentKnowledgeBase) *UpdateAgentKnowledgeBaseOutput { - s.AgentKnowledgeBase = v +// SetArn sets the Arn field's value. +func (s *UpdatePromptOutput) SetArn(v string) *UpdatePromptOutput { + s.Arn = &v return s } -type UpdateAgentOutput struct { - _ struct{} `type:"structure"` - - // Contains details about the agent that was updated. - // - // Agent is a required field - Agent *Agent `locationName:"agent" type:"structure" required:"true"` +// SetCreatedAt sets the CreatedAt field's value. +func (s *UpdatePromptOutput) SetCreatedAt(v time.Time) *UpdatePromptOutput { + s.CreatedAt = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentOutput) String() string { - return awsutil.Prettify(s) +// SetCustomerEncryptionKeyArn sets the CustomerEncryptionKeyArn field's value. +func (s *UpdatePromptOutput) SetCustomerEncryptionKeyArn(v string) *UpdatePromptOutput { + s.CustomerEncryptionKeyArn = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s UpdateAgentOutput) GoString() string { - return s.String() +// SetDefaultVariant sets the DefaultVariant field's value. +func (s *UpdatePromptOutput) SetDefaultVariant(v string) *UpdatePromptOutput { + s.DefaultVariant = &v + return s } -// SetAgent sets the Agent field's value. -func (s *UpdateAgentOutput) SetAgent(v *Agent) *UpdateAgentOutput { - s.Agent = v +// SetDescription sets the Description field's value. +func (s *UpdatePromptOutput) SetDescription(v string) *UpdatePromptOutput { + s.Description = &v return s } -type UpdateDataSourceInput struct { - _ struct{} `type:"structure"` - - // The data deletion policy of the updated data source. - DataDeletionPolicy *string `locationName:"dataDeletionPolicy" type:"string" enum:"DataDeletionPolicy"` - - // Contains details about the storage configuration of the data source. - // - // DataSourceConfiguration is a required field - DataSourceConfiguration *DataSourceConfiguration `locationName:"dataSourceConfiguration" type:"structure" required:"true"` +// SetId sets the Id field's value. +func (s *UpdatePromptOutput) SetId(v string) *UpdatePromptOutput { + s.Id = &v + return s +} - // The unique identifier of the data source. - // - // DataSourceId is a required field - DataSourceId *string `location:"uri" locationName:"dataSourceId" type:"string" required:"true"` +// SetName sets the Name field's value. +func (s *UpdatePromptOutput) SetName(v string) *UpdatePromptOutput { + s.Name = &v + return s +} - // Specifies a new description for the data source. - Description *string `locationName:"description" min:"1" type:"string"` +// SetUpdatedAt sets the UpdatedAt field's value. +func (s *UpdatePromptOutput) SetUpdatedAt(v time.Time) *UpdatePromptOutput { + s.UpdatedAt = &v + return s +} - // The unique identifier of the knowledge base to which the data source belongs. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +// SetVariants sets the Variants field's value. +func (s *UpdatePromptOutput) SetVariants(v []*PromptVariant) *UpdatePromptOutput { + s.Variants = v + return s +} - // Specifies a new name for the data source. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` +// SetVersion sets the Version field's value. +func (s *UpdatePromptOutput) SetVersion(v string) *UpdatePromptOutput { + s.Version = &v + return s +} - // Contains details about server-side encryption of the data source. - ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"serverSideEncryptionConfiguration" type:"structure"` +// The configuration of web URLs that you want to crawl. You should be authorized +// to crawl the URLs. +type UrlConfiguration struct { + _ struct{} `type:"structure"` - // Contains details about how to ingest the documents in the data source. - VectorIngestionConfiguration *VectorIngestionConfiguration `locationName:"vectorIngestionConfiguration" type:"structure"` + // One or more seed or starting point URLs. + SeedUrls []*SeedUrl `locationName:"seedUrls" min:"1" type:"list"` } // String returns the string representation. @@ -14224,7 +25144,7 @@ type UpdateDataSourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateDataSourceInput) String() string { +func (s UrlConfiguration) String() string { return awsutil.Prettify(s) } @@ -14233,48 +25153,15 @@ func (s UpdateDataSourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateDataSourceInput) GoString() string { +func (s UrlConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateDataSourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateDataSourceInput"} - if s.DataSourceConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceConfiguration")) - } - if s.DataSourceId == nil { - invalidParams.Add(request.NewErrParamRequired("DataSourceId")) - } - if s.DataSourceId != nil && len(*s.DataSourceId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("DataSourceId", 1)) - } - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - if s.Name == nil { - invalidParams.Add(request.NewErrParamRequired("Name")) - } - if s.DataSourceConfiguration != nil { - if err := s.DataSourceConfiguration.Validate(); err != nil { - invalidParams.AddNested("DataSourceConfiguration", err.(request.ErrInvalidParams)) - } - } - if s.ServerSideEncryptionConfiguration != nil { - if err := s.ServerSideEncryptionConfiguration.Validate(); err != nil { - invalidParams.AddNested("ServerSideEncryptionConfiguration", err.(request.ErrInvalidParams)) - } - } - if s.VectorIngestionConfiguration != nil { - if err := s.VectorIngestionConfiguration.Validate(); err != nil { - invalidParams.AddNested("VectorIngestionConfiguration", err.(request.ErrInvalidParams)) - } +func (s *UrlConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UrlConfiguration"} + if s.SeedUrls != nil && len(s.SeedUrls) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SeedUrls", 1)) } if invalidParams.Len() > 0 { @@ -14283,61 +25170,94 @@ func (s *UpdateDataSourceInput) Validate() error { return nil } -// SetDataDeletionPolicy sets the DataDeletionPolicy field's value. -func (s *UpdateDataSourceInput) SetDataDeletionPolicy(v string) *UpdateDataSourceInput { - s.DataDeletionPolicy = &v +// SetSeedUrls sets the SeedUrls field's value. +func (s *UrlConfiguration) SetSeedUrls(v []*SeedUrl) *UrlConfiguration { + s.SeedUrls = v return s } -// SetDataSourceConfiguration sets the DataSourceConfiguration field's value. -func (s *UpdateDataSourceInput) SetDataSourceConfiguration(v *DataSourceConfiguration) *UpdateDataSourceInput { - s.DataSourceConfiguration = v - return s +// Input validation failed. Check your request parameters and retry the request. +type ValidationException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // A list of objects containing fields that caused validation errors and their + // corresponding validation error messages. + FieldList []*ValidationExceptionField `locationName:"fieldList" type:"list"` + + Message_ *string `locationName:"message" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ValidationException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ValidationException) GoString() string { + return s.String() +} + +func newErrorValidationException(v protocol.ResponseMetadata) error { + return &ValidationException{ + RespMetadata: v, + } } -// SetDataSourceId sets the DataSourceId field's value. -func (s *UpdateDataSourceInput) SetDataSourceId(v string) *UpdateDataSourceInput { - s.DataSourceId = &v - return s +// Code returns the exception type name. +func (s *ValidationException) Code() string { + return "ValidationException" } -// SetDescription sets the Description field's value. -func (s *UpdateDataSourceInput) SetDescription(v string) *UpdateDataSourceInput { - s.Description = &v - return s +// Message returns the exception's message. +func (s *ValidationException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" } -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *UpdateDataSourceInput) SetKnowledgeBaseId(v string) *UpdateDataSourceInput { - s.KnowledgeBaseId = &v - return s +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ValidationException) OrigErr() error { + return nil } -// SetName sets the Name field's value. -func (s *UpdateDataSourceInput) SetName(v string) *UpdateDataSourceInput { - s.Name = &v - return s +func (s *ValidationException) Error() string { + return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) } -// SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value. -func (s *UpdateDataSourceInput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *UpdateDataSourceInput { - s.ServerSideEncryptionConfiguration = v - return s +// Status code returns the HTTP status code for the request's response error. +func (s *ValidationException) StatusCode() int { + return s.RespMetadata.StatusCode } -// SetVectorIngestionConfiguration sets the VectorIngestionConfiguration field's value. -func (s *UpdateDataSourceInput) SetVectorIngestionConfiguration(v *VectorIngestionConfiguration) *UpdateDataSourceInput { - s.VectorIngestionConfiguration = v - return s +// RequestID returns the service's response RequestID for request. +func (s *ValidationException) RequestID() string { + return s.RespMetadata.RequestID } -type UpdateDataSourceOutput struct { +// Stores information about a field passed inside a request that resulted in +// an validation error. +type ValidationExceptionField struct { _ struct{} `type:"structure"` - // Contains details about the data source. + // A message describing why this field failed validation. // - // DataSource is a required field - DataSource *DataSource `locationName:"dataSource" type:"structure" required:"true"` + // Message is a required field + Message *string `locationName:"message" type:"string" required:"true"` + + // The name of the field. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` } // String returns the string representation. @@ -14345,7 +25265,7 @@ type UpdateDataSourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateDataSourceOutput) String() string { +func (s ValidationExceptionField) String() string { return awsutil.Prettify(s) } @@ -14354,50 +25274,36 @@ func (s UpdateDataSourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateDataSourceOutput) GoString() string { +func (s ValidationExceptionField) GoString() string { return s.String() } -// SetDataSource sets the DataSource field's value. -func (s *UpdateDataSourceOutput) SetDataSource(v *DataSource) *UpdateDataSourceOutput { - s.DataSource = v +// SetMessage sets the Message field's value. +func (s *ValidationExceptionField) SetMessage(v string) *ValidationExceptionField { + s.Message = &v return s } -type UpdateKnowledgeBaseInput struct { - _ struct{} `type:"structure"` - - // Specifies a new description for the knowledge base. - Description *string `locationName:"description" min:"1" type:"string"` - - // 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. - // - // KnowledgeBaseConfiguration is a required field - KnowledgeBaseConfiguration *KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfiguration" type:"structure" required:"true"` +// SetName sets the Name field's value. +func (s *ValidationExceptionField) SetName(v string) *ValidationExceptionField { + s.Name = &v + return s +} - // The unique identifier of the knowledge base to update. - // - // KnowledgeBaseId is a required field - KnowledgeBaseId *string `location:"uri" locationName:"knowledgeBaseId" type:"string" required:"true"` +// Contains details about how to ingest the documents in a data source. +type VectorIngestionConfiguration struct { + _ struct{} `type:"structure"` - // Specifies a new name for the knowledge base. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` + // 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. + ChunkingConfiguration *ChunkingConfiguration `locationName:"chunkingConfiguration" type:"structure"` - // Specifies a different Amazon Resource Name (ARN) of the IAM role with permissions - // to invoke API operations on the knowledge base. - // - // RoleArn is a required field - RoleArn *string `locationName:"roleArn" type:"string" required:"true"` + // A custom document transformer for parsed data source documents. + CustomTransformationConfiguration *CustomTransformationConfiguration `locationName:"customTransformationConfiguration" type:"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. - // - // StorageConfiguration is a required field - StorageConfiguration *StorageConfiguration `locationName:"storageConfiguration" type:"structure" required:"true"` + // A custom parser for data source documents. + ParsingConfiguration *ParsingConfiguration `locationName:"parsingConfiguration" type:"structure"` } // String returns the string representation. @@ -14405,7 +25311,7 @@ type UpdateKnowledgeBaseInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateKnowledgeBaseInput) String() string { +func (s VectorIngestionConfiguration) String() string { return awsutil.Prettify(s) } @@ -14414,42 +25320,26 @@ func (s UpdateKnowledgeBaseInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateKnowledgeBaseInput) GoString() string { +func (s VectorIngestionConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateKnowledgeBaseInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateKnowledgeBaseInput"} - if s.Description != nil && len(*s.Description) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Description", 1)) - } - if s.KnowledgeBaseConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseConfiguration")) - } - if s.KnowledgeBaseId == nil { - invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) - } - if s.KnowledgeBaseId != nil && len(*s.KnowledgeBaseId) < 1 { - invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseId", 1)) - } - if s.Name == nil { - invalidParams.Add(request.NewErrParamRequired("Name")) - } - if s.RoleArn == nil { - invalidParams.Add(request.NewErrParamRequired("RoleArn")) - } - if s.StorageConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("StorageConfiguration")) +func (s *VectorIngestionConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "VectorIngestionConfiguration"} + if s.ChunkingConfiguration != nil { + if err := s.ChunkingConfiguration.Validate(); err != nil { + invalidParams.AddNested("ChunkingConfiguration", err.(request.ErrInvalidParams)) + } } - if s.KnowledgeBaseConfiguration != nil { - if err := s.KnowledgeBaseConfiguration.Validate(); err != nil { - invalidParams.AddNested("KnowledgeBaseConfiguration", err.(request.ErrInvalidParams)) + if s.CustomTransformationConfiguration != nil { + if err := s.CustomTransformationConfiguration.Validate(); err != nil { + invalidParams.AddNested("CustomTransformationConfiguration", err.(request.ErrInvalidParams)) } } - if s.StorageConfiguration != nil { - if err := s.StorageConfiguration.Validate(); err != nil { - invalidParams.AddNested("StorageConfiguration", err.(request.ErrInvalidParams)) + if s.ParsingConfiguration != nil { + if err := s.ParsingConfiguration.Validate(); err != nil { + invalidParams.AddNested("ParsingConfiguration", err.(request.ErrInvalidParams)) } } @@ -14459,49 +25349,38 @@ func (s *UpdateKnowledgeBaseInput) Validate() error { return nil } -// SetDescription sets the Description field's value. -func (s *UpdateKnowledgeBaseInput) SetDescription(v string) *UpdateKnowledgeBaseInput { - s.Description = &v - return s -} - -// SetKnowledgeBaseConfiguration sets the KnowledgeBaseConfiguration field's value. -func (s *UpdateKnowledgeBaseInput) SetKnowledgeBaseConfiguration(v *KnowledgeBaseConfiguration) *UpdateKnowledgeBaseInput { - s.KnowledgeBaseConfiguration = v - return s -} - -// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. -func (s *UpdateKnowledgeBaseInput) SetKnowledgeBaseId(v string) *UpdateKnowledgeBaseInput { - s.KnowledgeBaseId = &v - return s -} - -// SetName sets the Name field's value. -func (s *UpdateKnowledgeBaseInput) SetName(v string) *UpdateKnowledgeBaseInput { - s.Name = &v +// SetChunkingConfiguration sets the ChunkingConfiguration field's value. +func (s *VectorIngestionConfiguration) SetChunkingConfiguration(v *ChunkingConfiguration) *VectorIngestionConfiguration { + s.ChunkingConfiguration = v return s } -// SetRoleArn sets the RoleArn field's value. -func (s *UpdateKnowledgeBaseInput) SetRoleArn(v string) *UpdateKnowledgeBaseInput { - s.RoleArn = &v +// SetCustomTransformationConfiguration sets the CustomTransformationConfiguration field's value. +func (s *VectorIngestionConfiguration) SetCustomTransformationConfiguration(v *CustomTransformationConfiguration) *VectorIngestionConfiguration { + s.CustomTransformationConfiguration = v return s } -// SetStorageConfiguration sets the StorageConfiguration field's value. -func (s *UpdateKnowledgeBaseInput) SetStorageConfiguration(v *StorageConfiguration) *UpdateKnowledgeBaseInput { - s.StorageConfiguration = v +// SetParsingConfiguration sets the ParsingConfiguration field's value. +func (s *VectorIngestionConfiguration) SetParsingConfiguration(v *ParsingConfiguration) *VectorIngestionConfiguration { + s.ParsingConfiguration = v return s } -type UpdateKnowledgeBaseOutput struct { +// Contains details about the model used to create vector embeddings for the +// knowledge base. +type VectorKnowledgeBaseConfiguration struct { _ struct{} `type:"structure"` - // Contains details about the knowledge base. + // The Amazon Resource Name (ARN) of the model used to create vector embeddings + // for the knowledge base. // - // KnowledgeBase is a required field - KnowledgeBase *KnowledgeBase `locationName:"knowledgeBase" type:"structure" required:"true"` + // EmbeddingModelArn is a required field + EmbeddingModelArn *string `locationName:"embeddingModelArn" min:"20" type:"string" required:"true"` + + // The embeddings model configuration details for the vector model used in Knowledge + // Base. + EmbeddingModelConfiguration *EmbeddingModelConfiguration `locationName:"embeddingModelConfiguration" type:"structure"` } // String returns the string representation. @@ -14509,7 +25388,7 @@ type UpdateKnowledgeBaseOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateKnowledgeBaseOutput) String() string { +func (s VectorKnowledgeBaseConfiguration) String() string { return awsutil.Prettify(s) } @@ -14518,26 +25397,74 @@ func (s UpdateKnowledgeBaseOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s UpdateKnowledgeBaseOutput) GoString() string { +func (s VectorKnowledgeBaseConfiguration) GoString() string { return s.String() } -// SetKnowledgeBase sets the KnowledgeBase field's value. -func (s *UpdateKnowledgeBaseOutput) SetKnowledgeBase(v *KnowledgeBase) *UpdateKnowledgeBaseOutput { - s.KnowledgeBase = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *VectorKnowledgeBaseConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "VectorKnowledgeBaseConfiguration"} + if s.EmbeddingModelArn == nil { + invalidParams.Add(request.NewErrParamRequired("EmbeddingModelArn")) + } + if s.EmbeddingModelArn != nil && len(*s.EmbeddingModelArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("EmbeddingModelArn", 20)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetEmbeddingModelArn sets the EmbeddingModelArn field's value. +func (s *VectorKnowledgeBaseConfiguration) SetEmbeddingModelArn(v string) *VectorKnowledgeBaseConfiguration { + s.EmbeddingModelArn = &v return s } -// Input validation failed. Check your request parameters and retry the request. -type ValidationException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` +// SetEmbeddingModelConfiguration sets the EmbeddingModelConfiguration field's value. +func (s *VectorKnowledgeBaseConfiguration) SetEmbeddingModelConfiguration(v *EmbeddingModelConfiguration) *VectorKnowledgeBaseConfiguration { + s.EmbeddingModelConfiguration = v + return s +} - // A list of objects containing fields that caused validation errors and their - // corresponding validation error messages. - FieldList []*ValidationExceptionField `locationName:"fieldList" type:"list"` +// The configuration of web URLs that you want to crawl. You should be authorized +// to crawl the URLs. +type WebCrawlerConfiguration struct { + _ struct{} `type:"structure"` - Message_ *string `locationName:"message" type:"string"` + // The configuration of crawl limits for the web URLs. + CrawlerLimits *WebCrawlerLimits `locationName:"crawlerLimits" type:"structure"` + + // 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. + // + // ExclusionFilters is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by WebCrawlerConfiguration's + // String and GoString methods. + ExclusionFilters []*string `locationName:"exclusionFilters" min:"1" type:"list" sensitive:"true"` + + // 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. + // + // InclusionFilters is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by WebCrawlerConfiguration's + // String and GoString methods. + InclusionFilters []*string `locationName:"inclusionFilters" min:"1" type:"list" sensitive:"true"` + + // 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". + Scope *string `locationName:"scope" type:"string" enum:"WebScopeType"` } // String returns the string representation. @@ -14545,7 +25472,7 @@ type ValidationException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ValidationException) String() string { +func (s WebCrawlerConfiguration) String() string { return awsutil.Prettify(s) } @@ -14553,63 +25480,63 @@ func (s ValidationException) String() string { // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ValidationException) GoString() string { - return s.String() -} - -func newErrorValidationException(v protocol.ResponseMetadata) error { - return &ValidationException{ - RespMetadata: v, - } +// value will be replaced with "sensitive". +func (s WebCrawlerConfiguration) GoString() string { + return s.String() } -// Code returns the exception type name. -func (s *ValidationException) Code() string { - return "ValidationException" -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *WebCrawlerConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "WebCrawlerConfiguration"} + if s.ExclusionFilters != nil && len(s.ExclusionFilters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ExclusionFilters", 1)) + } + if s.InclusionFilters != nil && len(s.InclusionFilters) < 1 { + invalidParams.Add(request.NewErrParamMinLen("InclusionFilters", 1)) + } + if s.CrawlerLimits != nil { + if err := s.CrawlerLimits.Validate(); err != nil { + invalidParams.AddNested("CrawlerLimits", err.(request.ErrInvalidParams)) + } + } -// Message returns the exception's message. -func (s *ValidationException) Message() string { - if s.Message_ != nil { - return *s.Message_ + if invalidParams.Len() > 0 { + return invalidParams } - return "" + return nil } -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ValidationException) OrigErr() error { - return nil +// SetCrawlerLimits sets the CrawlerLimits field's value. +func (s *WebCrawlerConfiguration) SetCrawlerLimits(v *WebCrawlerLimits) *WebCrawlerConfiguration { + s.CrawlerLimits = v + return s } -func (s *ValidationException) Error() string { - return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) +// SetExclusionFilters sets the ExclusionFilters field's value. +func (s *WebCrawlerConfiguration) SetExclusionFilters(v []*string) *WebCrawlerConfiguration { + s.ExclusionFilters = v + return s } -// Status code returns the HTTP status code for the request's response error. -func (s *ValidationException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetInclusionFilters sets the InclusionFilters field's value. +func (s *WebCrawlerConfiguration) SetInclusionFilters(v []*string) *WebCrawlerConfiguration { + s.InclusionFilters = v + return s } -// RequestID returns the service's response RequestID for request. -func (s *ValidationException) RequestID() string { - return s.RespMetadata.RequestID +// SetScope sets the Scope field's value. +func (s *WebCrawlerConfiguration) SetScope(v string) *WebCrawlerConfiguration { + s.Scope = &v + return s } -// Stores information about a field passed inside a request that resulted in -// an validation error. -type ValidationExceptionField struct { +// The rate limits for the URLs that you want to crawl. You should be authorized +// to crawl the URLs. +type WebCrawlerLimits struct { _ struct{} `type:"structure"` - // A message describing why this field failed validation. - // - // Message is a required field - Message *string `locationName:"message" type:"string" required:"true"` - - // The name of the field. - // - // Name is a required field - Name *string `locationName:"name" type:"string" required:"true"` + // The max rate at which pages are crawled, up to 300 per minute per host. + RateLimit *int64 `locationName:"rateLimit" min:"1" type:"integer"` } // String returns the string representation. @@ -14617,7 +25544,7 @@ type ValidationExceptionField struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ValidationExceptionField) String() string { +func (s WebCrawlerLimits) String() string { return awsutil.Prettify(s) } @@ -14626,30 +25553,40 @@ func (s ValidationExceptionField) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ValidationExceptionField) GoString() string { +func (s WebCrawlerLimits) GoString() string { return s.String() } -// SetMessage sets the Message field's value. -func (s *ValidationExceptionField) SetMessage(v string) *ValidationExceptionField { - s.Message = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *WebCrawlerLimits) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "WebCrawlerLimits"} + if s.RateLimit != nil && *s.RateLimit < 1 { + invalidParams.Add(request.NewErrParamMinValue("RateLimit", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetName sets the Name field's value. -func (s *ValidationExceptionField) SetName(v string) *ValidationExceptionField { - s.Name = &v +// SetRateLimit sets the RateLimit field's value. +func (s *WebCrawlerLimits) SetRateLimit(v int64) *WebCrawlerLimits { + s.RateLimit = &v return s } -// Contains details about how to ingest the documents in a data source. -type VectorIngestionConfiguration struct { +// The configuration details for the web data source. +type WebDataSourceConfiguration struct { _ struct{} `type:"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. - ChunkingConfiguration *ChunkingConfiguration `locationName:"chunkingConfiguration" type:"structure"` + // The Web Crawler configuration details for the web data source. + CrawlerConfiguration *WebCrawlerConfiguration `locationName:"crawlerConfiguration" type:"structure"` + + // The source configuration details for the web data source. + // + // SourceConfiguration is a required field + SourceConfiguration *WebSourceConfiguration `locationName:"sourceConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -14657,7 +25594,7 @@ type VectorIngestionConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s VectorIngestionConfiguration) String() string { +func (s WebDataSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -14666,16 +25603,24 @@ func (s VectorIngestionConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s VectorIngestionConfiguration) GoString() string { +func (s WebDataSourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *VectorIngestionConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "VectorIngestionConfiguration"} - if s.ChunkingConfiguration != nil { - if err := s.ChunkingConfiguration.Validate(); err != nil { - invalidParams.AddNested("ChunkingConfiguration", err.(request.ErrInvalidParams)) +func (s *WebDataSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "WebDataSourceConfiguration"} + if s.SourceConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("SourceConfiguration")) + } + if s.CrawlerConfiguration != nil { + if err := s.CrawlerConfiguration.Validate(); err != nil { + invalidParams.AddNested("CrawlerConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.SourceConfiguration != nil { + if err := s.SourceConfiguration.Validate(); err != nil { + invalidParams.AddNested("SourceConfiguration", err.(request.ErrInvalidParams)) } } @@ -14685,26 +25630,27 @@ func (s *VectorIngestionConfiguration) Validate() error { return nil } -// SetChunkingConfiguration sets the ChunkingConfiguration field's value. -func (s *VectorIngestionConfiguration) SetChunkingConfiguration(v *ChunkingConfiguration) *VectorIngestionConfiguration { - s.ChunkingConfiguration = v +// SetCrawlerConfiguration sets the CrawlerConfiguration field's value. +func (s *WebDataSourceConfiguration) SetCrawlerConfiguration(v *WebCrawlerConfiguration) *WebDataSourceConfiguration { + s.CrawlerConfiguration = v return s } -// Contains details about the model used to create vector embeddings for the -// knowledge base. -type VectorKnowledgeBaseConfiguration struct { +// SetSourceConfiguration sets the SourceConfiguration field's value. +func (s *WebDataSourceConfiguration) SetSourceConfiguration(v *WebSourceConfiguration) *WebDataSourceConfiguration { + s.SourceConfiguration = v + return s +} + +// The configuration of the URL/URLs for the web content that you want to crawl. +// You should be authorized to crawl the URLs. +type WebSourceConfiguration struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the model used to create vector embeddings - // for the knowledge base. + // The configuration of the URL/URLs. // - // EmbeddingModelArn is a required field - EmbeddingModelArn *string `locationName:"embeddingModelArn" min:"20" type:"string" required:"true"` - - // The embeddings model configuration details for the vector model used in Knowledge - // Base. - EmbeddingModelConfiguration *EmbeddingModelConfiguration `locationName:"embeddingModelConfiguration" type:"structure"` + // UrlConfiguration is a required field + UrlConfiguration *UrlConfiguration `locationName:"urlConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -14712,7 +25658,7 @@ type VectorKnowledgeBaseConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s VectorKnowledgeBaseConfiguration) String() string { +func (s WebSourceConfiguration) String() string { return awsutil.Prettify(s) } @@ -14721,18 +25667,20 @@ func (s VectorKnowledgeBaseConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s VectorKnowledgeBaseConfiguration) GoString() string { +func (s WebSourceConfiguration) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *VectorKnowledgeBaseConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "VectorKnowledgeBaseConfiguration"} - if s.EmbeddingModelArn == nil { - invalidParams.Add(request.NewErrParamRequired("EmbeddingModelArn")) - } - if s.EmbeddingModelArn != nil && len(*s.EmbeddingModelArn) < 20 { - invalidParams.Add(request.NewErrParamMinLen("EmbeddingModelArn", 20)) +func (s *WebSourceConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "WebSourceConfiguration"} + if s.UrlConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("UrlConfiguration")) + } + if s.UrlConfiguration != nil { + if err := s.UrlConfiguration.Validate(); err != nil { + invalidParams.AddNested("UrlConfiguration", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -14741,27 +25689,25 @@ func (s *VectorKnowledgeBaseConfiguration) Validate() error { return nil } -// SetEmbeddingModelArn sets the EmbeddingModelArn field's value. -func (s *VectorKnowledgeBaseConfiguration) SetEmbeddingModelArn(v string) *VectorKnowledgeBaseConfiguration { - s.EmbeddingModelArn = &v - return s -} - -// SetEmbeddingModelConfiguration sets the EmbeddingModelConfiguration field's value. -func (s *VectorKnowledgeBaseConfiguration) SetEmbeddingModelConfiguration(v *EmbeddingModelConfiguration) *VectorKnowledgeBaseConfiguration { - s.EmbeddingModelConfiguration = v +// SetUrlConfiguration sets the UrlConfiguration field's value. +func (s *WebSourceConfiguration) SetUrlConfiguration(v *UrlConfiguration) *WebSourceConfiguration { + s.UrlConfiguration = v return s } const ( // ActionGroupSignatureAmazonUserInput is a ActionGroupSignature enum value ActionGroupSignatureAmazonUserInput = "AMAZON.UserInput" + + // ActionGroupSignatureAmazonCodeInterpreter is a ActionGroupSignature enum value + ActionGroupSignatureAmazonCodeInterpreter = "AMAZON.CodeInterpreter" ) // ActionGroupSignature_Values returns all elements of the ActionGroupSignature enum func ActionGroupSignature_Values() []string { return []string{ ActionGroupSignatureAmazonUserInput, + ActionGroupSignatureAmazonCodeInterpreter, } } @@ -14855,6 +25801,12 @@ const ( // ChunkingStrategyNone is a ChunkingStrategy enum value ChunkingStrategyNone = "NONE" + + // ChunkingStrategyHierarchical is a ChunkingStrategy enum value + ChunkingStrategyHierarchical = "HIERARCHICAL" + + // ChunkingStrategySemantic is a ChunkingStrategy enum value + ChunkingStrategySemantic = "SEMANTIC" ) // ChunkingStrategy_Values returns all elements of the ChunkingStrategy enum @@ -14862,6 +25814,48 @@ func ChunkingStrategy_Values() []string { return []string{ ChunkingStrategyFixedSize, ChunkingStrategyNone, + ChunkingStrategyHierarchical, + ChunkingStrategySemantic, + } +} + +const ( + // ConfluenceAuthTypeBasic is a ConfluenceAuthType enum value + ConfluenceAuthTypeBasic = "BASIC" + + // ConfluenceAuthTypeOauth2ClientCredentials is a ConfluenceAuthType enum value + ConfluenceAuthTypeOauth2ClientCredentials = "OAUTH2_CLIENT_CREDENTIALS" +) + +// ConfluenceAuthType_Values returns all elements of the ConfluenceAuthType enum +func ConfluenceAuthType_Values() []string { + return []string{ + ConfluenceAuthTypeBasic, + ConfluenceAuthTypeOauth2ClientCredentials, + } +} + +const ( + // ConfluenceHostTypeSaas is a ConfluenceHostType enum value + ConfluenceHostTypeSaas = "SAAS" +) + +// ConfluenceHostType_Values returns all elements of the ConfluenceHostType enum +func ConfluenceHostType_Values() []string { + return []string{ + ConfluenceHostTypeSaas, + } +} + +const ( + // CrawlFilterConfigurationTypePattern is a CrawlFilterConfigurationType enum value + CrawlFilterConfigurationTypePattern = "PATTERN" +) + +// CrawlFilterConfigurationType_Values returns all elements of the CrawlFilterConfigurationType enum +func CrawlFilterConfigurationType_Values() []string { + return []string{ + CrawlFilterConfigurationTypePattern, } } @@ -14932,12 +25926,168 @@ func DataSourceStatus_Values() []string { const ( // DataSourceTypeS3 is a DataSourceType enum value DataSourceTypeS3 = "S3" + + // DataSourceTypeWeb is a DataSourceType enum value + DataSourceTypeWeb = "WEB" + + // DataSourceTypeConfluence is a DataSourceType enum value + DataSourceTypeConfluence = "CONFLUENCE" + + // DataSourceTypeSalesforce is a DataSourceType enum value + DataSourceTypeSalesforce = "SALESFORCE" + + // DataSourceTypeSharepoint is a DataSourceType enum value + DataSourceTypeSharepoint = "SHAREPOINT" ) // DataSourceType_Values returns all elements of the DataSourceType enum func DataSourceType_Values() []string { return []string{ DataSourceTypeS3, + DataSourceTypeWeb, + DataSourceTypeConfluence, + DataSourceTypeSalesforce, + DataSourceTypeSharepoint, + } +} + +const ( + // FlowConnectionTypeData is a FlowConnectionType enum value + FlowConnectionTypeData = "Data" + + // FlowConnectionTypeConditional is a FlowConnectionType enum value + FlowConnectionTypeConditional = "Conditional" +) + +// FlowConnectionType_Values returns all elements of the FlowConnectionType enum +func FlowConnectionType_Values() []string { + return []string{ + FlowConnectionTypeData, + FlowConnectionTypeConditional, + } +} + +const ( + // FlowNodeIODataTypeString is a FlowNodeIODataType enum value + FlowNodeIODataTypeString = "String" + + // FlowNodeIODataTypeNumber is a FlowNodeIODataType enum value + FlowNodeIODataTypeNumber = "Number" + + // FlowNodeIODataTypeBoolean is a FlowNodeIODataType enum value + FlowNodeIODataTypeBoolean = "Boolean" + + // FlowNodeIODataTypeObject is a FlowNodeIODataType enum value + FlowNodeIODataTypeObject = "Object" + + // FlowNodeIODataTypeArray is a FlowNodeIODataType enum value + FlowNodeIODataTypeArray = "Array" +) + +// FlowNodeIODataType_Values returns all elements of the FlowNodeIODataType enum +func FlowNodeIODataType_Values() []string { + return []string{ + FlowNodeIODataTypeString, + FlowNodeIODataTypeNumber, + FlowNodeIODataTypeBoolean, + FlowNodeIODataTypeObject, + FlowNodeIODataTypeArray, + } +} + +const ( + // FlowNodeTypeInput is a FlowNodeType enum value + FlowNodeTypeInput = "Input" + + // FlowNodeTypeOutput is a FlowNodeType enum value + FlowNodeTypeOutput = "Output" + + // FlowNodeTypeKnowledgeBase is a FlowNodeType enum value + FlowNodeTypeKnowledgeBase = "KnowledgeBase" + + // FlowNodeTypeCondition is a FlowNodeType enum value + FlowNodeTypeCondition = "Condition" + + // FlowNodeTypeLex is a FlowNodeType enum value + FlowNodeTypeLex = "Lex" + + // FlowNodeTypePrompt is a FlowNodeType enum value + FlowNodeTypePrompt = "Prompt" + + // FlowNodeTypeLambdaFunction is a FlowNodeType enum value + FlowNodeTypeLambdaFunction = "LambdaFunction" + + // FlowNodeTypeStorage is a FlowNodeType enum value + FlowNodeTypeStorage = "Storage" + + // FlowNodeTypeAgent is a FlowNodeType enum value + FlowNodeTypeAgent = "Agent" + + // FlowNodeTypeRetrieval is a FlowNodeType enum value + FlowNodeTypeRetrieval = "Retrieval" + + // FlowNodeTypeIterator is a FlowNodeType enum value + FlowNodeTypeIterator = "Iterator" + + // FlowNodeTypeCollector is a FlowNodeType enum value + FlowNodeTypeCollector = "Collector" +) + +// FlowNodeType_Values returns all elements of the FlowNodeType enum +func FlowNodeType_Values() []string { + return []string{ + FlowNodeTypeInput, + FlowNodeTypeOutput, + FlowNodeTypeKnowledgeBase, + FlowNodeTypeCondition, + FlowNodeTypeLex, + FlowNodeTypePrompt, + FlowNodeTypeLambdaFunction, + FlowNodeTypeStorage, + FlowNodeTypeAgent, + FlowNodeTypeRetrieval, + FlowNodeTypeIterator, + FlowNodeTypeCollector, + } +} + +const ( + // FlowStatusFailed is a FlowStatus enum value + FlowStatusFailed = "Failed" + + // FlowStatusPrepared is a FlowStatus enum value + FlowStatusPrepared = "Prepared" + + // FlowStatusPreparing is a FlowStatus enum value + FlowStatusPreparing = "Preparing" + + // FlowStatusNotPrepared is a FlowStatus enum value + FlowStatusNotPrepared = "NotPrepared" +) + +// FlowStatus_Values returns all elements of the FlowStatus enum +func FlowStatus_Values() []string { + return []string{ + FlowStatusFailed, + FlowStatusPrepared, + FlowStatusPreparing, + FlowStatusNotPrepared, + } +} + +const ( + // FlowValidationSeverityWarning is a FlowValidationSeverity enum value + FlowValidationSeverityWarning = "Warning" + + // FlowValidationSeverityError is a FlowValidationSeverity enum value + FlowValidationSeverityError = "Error" +) + +// FlowValidationSeverity_Values returns all elements of the FlowValidationSeverity enum +func FlowValidationSeverity_Values() []string { + return []string{ + FlowValidationSeverityWarning, + FlowValidationSeverityError, } } @@ -15093,6 +26243,30 @@ func KnowledgeBaseType_Values() []string { } } +const ( + // MemoryTypeSessionSummary is a MemoryType enum value + MemoryTypeSessionSummary = "SESSION_SUMMARY" +) + +// MemoryType_Values returns all elements of the MemoryType enum +func MemoryType_Values() []string { + return []string{ + MemoryTypeSessionSummary, + } +} + +const ( + // ParsingStrategyBedrockFoundationModel is a ParsingStrategy enum value + ParsingStrategyBedrockFoundationModel = "BEDROCK_FOUNDATION_MODEL" +) + +// ParsingStrategy_Values returns all elements of the ParsingStrategy enum +func ParsingStrategy_Values() []string { + return []string{ + ParsingStrategyBedrockFoundationModel, + } +} + const ( // PromptStateEnabled is a PromptState enum value PromptStateEnabled = "ENABLED" @@ -15109,6 +26283,18 @@ func PromptState_Values() []string { } } +const ( + // PromptTemplateTypeText is a PromptTemplateType enum value + PromptTemplateTypeText = "TEXT" +) + +// PromptTemplateType_Values returns all elements of the PromptTemplateType enum +func PromptTemplateType_Values() []string { + return []string{ + PromptTemplateTypeText, + } +} + const ( // PromptTypePreProcessing is a PromptType enum value PromptTypePreProcessing = "PRE_PROCESSING" @@ -15133,6 +26319,42 @@ func PromptType_Values() []string { } } +const ( + // SalesforceAuthTypeOauth2ClientCredentials is a SalesforceAuthType enum value + SalesforceAuthTypeOauth2ClientCredentials = "OAUTH2_CLIENT_CREDENTIALS" +) + +// SalesforceAuthType_Values returns all elements of the SalesforceAuthType enum +func SalesforceAuthType_Values() []string { + return []string{ + SalesforceAuthTypeOauth2ClientCredentials, + } +} + +const ( + // SharePointAuthTypeOauth2ClientCredentials is a SharePointAuthType enum value + SharePointAuthTypeOauth2ClientCredentials = "OAUTH2_CLIENT_CREDENTIALS" +) + +// SharePointAuthType_Values returns all elements of the SharePointAuthType enum +func SharePointAuthType_Values() []string { + return []string{ + SharePointAuthTypeOauth2ClientCredentials, + } +} + +const ( + // SharePointHostTypeOnline is a SharePointHostType enum value + SharePointHostTypeOnline = "ONLINE" +) + +// SharePointHostType_Values returns all elements of the SharePointHostType enum +func SharePointHostType_Values() []string { + return []string{ + SharePointHostTypeOnline, + } +} + const ( // SortOrderAscending is a SortOrder enum value SortOrderAscending = "ASCENDING" @@ -15149,6 +26371,18 @@ func SortOrder_Values() []string { } } +const ( + // StepTypePostChunking is a StepType enum value + StepTypePostChunking = "POST_CHUNKING" +) + +// StepType_Values returns all elements of the StepType enum +func StepType_Values() []string { + return []string{ + StepTypePostChunking, + } +} + const ( // TypeString is a Type enum value TypeString = "string" @@ -15176,3 +26410,19 @@ func Type_Values() []string { TypeArray, } } + +const ( + // WebScopeTypeHostOnly is a WebScopeType enum value + WebScopeTypeHostOnly = "HOST_ONLY" + + // WebScopeTypeSubdomains is a WebScopeType enum value + WebScopeTypeSubdomains = "SUBDOMAINS" +) + +// WebScopeType_Values returns all elements of the WebScopeType enum +func WebScopeType_Values() []string { + return []string{ + WebScopeTypeHostOnly, + WebScopeTypeSubdomains, + } +} diff --git a/service/bedrockagent/bedrockagentiface/interface.go b/service/bedrockagent/bedrockagentiface/interface.go index 675ac884018..f5eef43a753 100644 --- a/service/bedrockagent/bedrockagentiface/interface.go +++ b/service/bedrockagent/bedrockagentiface/interface.go @@ -80,10 +80,30 @@ type BedrockAgentAPI interface { CreateDataSourceWithContext(aws.Context, *bedrockagent.CreateDataSourceInput, ...request.Option) (*bedrockagent.CreateDataSourceOutput, error) CreateDataSourceRequest(*bedrockagent.CreateDataSourceInput) (*request.Request, *bedrockagent.CreateDataSourceOutput) + CreateFlow(*bedrockagent.CreateFlowInput) (*bedrockagent.CreateFlowOutput, error) + CreateFlowWithContext(aws.Context, *bedrockagent.CreateFlowInput, ...request.Option) (*bedrockagent.CreateFlowOutput, error) + CreateFlowRequest(*bedrockagent.CreateFlowInput) (*request.Request, *bedrockagent.CreateFlowOutput) + + CreateFlowAlias(*bedrockagent.CreateFlowAliasInput) (*bedrockagent.CreateFlowAliasOutput, error) + CreateFlowAliasWithContext(aws.Context, *bedrockagent.CreateFlowAliasInput, ...request.Option) (*bedrockagent.CreateFlowAliasOutput, error) + CreateFlowAliasRequest(*bedrockagent.CreateFlowAliasInput) (*request.Request, *bedrockagent.CreateFlowAliasOutput) + + CreateFlowVersion(*bedrockagent.CreateFlowVersionInput) (*bedrockagent.CreateFlowVersionOutput, error) + CreateFlowVersionWithContext(aws.Context, *bedrockagent.CreateFlowVersionInput, ...request.Option) (*bedrockagent.CreateFlowVersionOutput, error) + CreateFlowVersionRequest(*bedrockagent.CreateFlowVersionInput) (*request.Request, *bedrockagent.CreateFlowVersionOutput) + CreateKnowledgeBase(*bedrockagent.CreateKnowledgeBaseInput) (*bedrockagent.CreateKnowledgeBaseOutput, error) CreateKnowledgeBaseWithContext(aws.Context, *bedrockagent.CreateKnowledgeBaseInput, ...request.Option) (*bedrockagent.CreateKnowledgeBaseOutput, error) CreateKnowledgeBaseRequest(*bedrockagent.CreateKnowledgeBaseInput) (*request.Request, *bedrockagent.CreateKnowledgeBaseOutput) + CreatePrompt(*bedrockagent.CreatePromptInput) (*bedrockagent.CreatePromptOutput, error) + CreatePromptWithContext(aws.Context, *bedrockagent.CreatePromptInput, ...request.Option) (*bedrockagent.CreatePromptOutput, error) + CreatePromptRequest(*bedrockagent.CreatePromptInput) (*request.Request, *bedrockagent.CreatePromptOutput) + + CreatePromptVersion(*bedrockagent.CreatePromptVersionInput) (*bedrockagent.CreatePromptVersionOutput, error) + CreatePromptVersionWithContext(aws.Context, *bedrockagent.CreatePromptVersionInput, ...request.Option) (*bedrockagent.CreatePromptVersionOutput, error) + CreatePromptVersionRequest(*bedrockagent.CreatePromptVersionInput) (*request.Request, *bedrockagent.CreatePromptVersionOutput) + DeleteAgent(*bedrockagent.DeleteAgentInput) (*bedrockagent.DeleteAgentOutput, error) DeleteAgentWithContext(aws.Context, *bedrockagent.DeleteAgentInput, ...request.Option) (*bedrockagent.DeleteAgentOutput, error) DeleteAgentRequest(*bedrockagent.DeleteAgentInput) (*request.Request, *bedrockagent.DeleteAgentOutput) @@ -104,10 +124,26 @@ type BedrockAgentAPI interface { DeleteDataSourceWithContext(aws.Context, *bedrockagent.DeleteDataSourceInput, ...request.Option) (*bedrockagent.DeleteDataSourceOutput, error) DeleteDataSourceRequest(*bedrockagent.DeleteDataSourceInput) (*request.Request, *bedrockagent.DeleteDataSourceOutput) + DeleteFlow(*bedrockagent.DeleteFlowInput) (*bedrockagent.DeleteFlowOutput, error) + DeleteFlowWithContext(aws.Context, *bedrockagent.DeleteFlowInput, ...request.Option) (*bedrockagent.DeleteFlowOutput, error) + DeleteFlowRequest(*bedrockagent.DeleteFlowInput) (*request.Request, *bedrockagent.DeleteFlowOutput) + + DeleteFlowAlias(*bedrockagent.DeleteFlowAliasInput) (*bedrockagent.DeleteFlowAliasOutput, error) + DeleteFlowAliasWithContext(aws.Context, *bedrockagent.DeleteFlowAliasInput, ...request.Option) (*bedrockagent.DeleteFlowAliasOutput, error) + DeleteFlowAliasRequest(*bedrockagent.DeleteFlowAliasInput) (*request.Request, *bedrockagent.DeleteFlowAliasOutput) + + DeleteFlowVersion(*bedrockagent.DeleteFlowVersionInput) (*bedrockagent.DeleteFlowVersionOutput, error) + DeleteFlowVersionWithContext(aws.Context, *bedrockagent.DeleteFlowVersionInput, ...request.Option) (*bedrockagent.DeleteFlowVersionOutput, error) + DeleteFlowVersionRequest(*bedrockagent.DeleteFlowVersionInput) (*request.Request, *bedrockagent.DeleteFlowVersionOutput) + DeleteKnowledgeBase(*bedrockagent.DeleteKnowledgeBaseInput) (*bedrockagent.DeleteKnowledgeBaseOutput, error) DeleteKnowledgeBaseWithContext(aws.Context, *bedrockagent.DeleteKnowledgeBaseInput, ...request.Option) (*bedrockagent.DeleteKnowledgeBaseOutput, error) DeleteKnowledgeBaseRequest(*bedrockagent.DeleteKnowledgeBaseInput) (*request.Request, *bedrockagent.DeleteKnowledgeBaseOutput) + DeletePrompt(*bedrockagent.DeletePromptInput) (*bedrockagent.DeletePromptOutput, error) + DeletePromptWithContext(aws.Context, *bedrockagent.DeletePromptInput, ...request.Option) (*bedrockagent.DeletePromptOutput, error) + DeletePromptRequest(*bedrockagent.DeletePromptInput) (*request.Request, *bedrockagent.DeletePromptOutput) + DisassociateAgentKnowledgeBase(*bedrockagent.DisassociateAgentKnowledgeBaseInput) (*bedrockagent.DisassociateAgentKnowledgeBaseOutput, error) DisassociateAgentKnowledgeBaseWithContext(aws.Context, *bedrockagent.DisassociateAgentKnowledgeBaseInput, ...request.Option) (*bedrockagent.DisassociateAgentKnowledgeBaseOutput, error) DisassociateAgentKnowledgeBaseRequest(*bedrockagent.DisassociateAgentKnowledgeBaseInput) (*request.Request, *bedrockagent.DisassociateAgentKnowledgeBaseOutput) @@ -136,6 +172,18 @@ type BedrockAgentAPI interface { GetDataSourceWithContext(aws.Context, *bedrockagent.GetDataSourceInput, ...request.Option) (*bedrockagent.GetDataSourceOutput, error) GetDataSourceRequest(*bedrockagent.GetDataSourceInput) (*request.Request, *bedrockagent.GetDataSourceOutput) + GetFlow(*bedrockagent.GetFlowInput) (*bedrockagent.GetFlowOutput, error) + GetFlowWithContext(aws.Context, *bedrockagent.GetFlowInput, ...request.Option) (*bedrockagent.GetFlowOutput, error) + GetFlowRequest(*bedrockagent.GetFlowInput) (*request.Request, *bedrockagent.GetFlowOutput) + + GetFlowAlias(*bedrockagent.GetFlowAliasInput) (*bedrockagent.GetFlowAliasOutput, error) + GetFlowAliasWithContext(aws.Context, *bedrockagent.GetFlowAliasInput, ...request.Option) (*bedrockagent.GetFlowAliasOutput, error) + GetFlowAliasRequest(*bedrockagent.GetFlowAliasInput) (*request.Request, *bedrockagent.GetFlowAliasOutput) + + GetFlowVersion(*bedrockagent.GetFlowVersionInput) (*bedrockagent.GetFlowVersionOutput, error) + GetFlowVersionWithContext(aws.Context, *bedrockagent.GetFlowVersionInput, ...request.Option) (*bedrockagent.GetFlowVersionOutput, error) + GetFlowVersionRequest(*bedrockagent.GetFlowVersionInput) (*request.Request, *bedrockagent.GetFlowVersionOutput) + GetIngestionJob(*bedrockagent.GetIngestionJobInput) (*bedrockagent.GetIngestionJobOutput, error) GetIngestionJobWithContext(aws.Context, *bedrockagent.GetIngestionJobInput, ...request.Option) (*bedrockagent.GetIngestionJobOutput, error) GetIngestionJobRequest(*bedrockagent.GetIngestionJobInput) (*request.Request, *bedrockagent.GetIngestionJobOutput) @@ -144,6 +192,10 @@ type BedrockAgentAPI interface { GetKnowledgeBaseWithContext(aws.Context, *bedrockagent.GetKnowledgeBaseInput, ...request.Option) (*bedrockagent.GetKnowledgeBaseOutput, error) GetKnowledgeBaseRequest(*bedrockagent.GetKnowledgeBaseInput) (*request.Request, *bedrockagent.GetKnowledgeBaseOutput) + GetPrompt(*bedrockagent.GetPromptInput) (*bedrockagent.GetPromptOutput, error) + GetPromptWithContext(aws.Context, *bedrockagent.GetPromptInput, ...request.Option) (*bedrockagent.GetPromptOutput, error) + GetPromptRequest(*bedrockagent.GetPromptInput) (*request.Request, *bedrockagent.GetPromptOutput) + ListAgentActionGroups(*bedrockagent.ListAgentActionGroupsInput) (*bedrockagent.ListAgentActionGroupsOutput, error) ListAgentActionGroupsWithContext(aws.Context, *bedrockagent.ListAgentActionGroupsInput, ...request.Option) (*bedrockagent.ListAgentActionGroupsOutput, error) ListAgentActionGroupsRequest(*bedrockagent.ListAgentActionGroupsInput) (*request.Request, *bedrockagent.ListAgentActionGroupsOutput) @@ -186,6 +238,27 @@ type BedrockAgentAPI interface { ListDataSourcesPages(*bedrockagent.ListDataSourcesInput, func(*bedrockagent.ListDataSourcesOutput, bool) bool) error ListDataSourcesPagesWithContext(aws.Context, *bedrockagent.ListDataSourcesInput, func(*bedrockagent.ListDataSourcesOutput, bool) bool, ...request.Option) error + ListFlowAliases(*bedrockagent.ListFlowAliasesInput) (*bedrockagent.ListFlowAliasesOutput, error) + ListFlowAliasesWithContext(aws.Context, *bedrockagent.ListFlowAliasesInput, ...request.Option) (*bedrockagent.ListFlowAliasesOutput, error) + ListFlowAliasesRequest(*bedrockagent.ListFlowAliasesInput) (*request.Request, *bedrockagent.ListFlowAliasesOutput) + + ListFlowAliasesPages(*bedrockagent.ListFlowAliasesInput, func(*bedrockagent.ListFlowAliasesOutput, bool) bool) error + ListFlowAliasesPagesWithContext(aws.Context, *bedrockagent.ListFlowAliasesInput, func(*bedrockagent.ListFlowAliasesOutput, bool) bool, ...request.Option) error + + ListFlowVersions(*bedrockagent.ListFlowVersionsInput) (*bedrockagent.ListFlowVersionsOutput, error) + ListFlowVersionsWithContext(aws.Context, *bedrockagent.ListFlowVersionsInput, ...request.Option) (*bedrockagent.ListFlowVersionsOutput, error) + ListFlowVersionsRequest(*bedrockagent.ListFlowVersionsInput) (*request.Request, *bedrockagent.ListFlowVersionsOutput) + + ListFlowVersionsPages(*bedrockagent.ListFlowVersionsInput, func(*bedrockagent.ListFlowVersionsOutput, bool) bool) error + ListFlowVersionsPagesWithContext(aws.Context, *bedrockagent.ListFlowVersionsInput, func(*bedrockagent.ListFlowVersionsOutput, bool) bool, ...request.Option) error + + ListFlows(*bedrockagent.ListFlowsInput) (*bedrockagent.ListFlowsOutput, error) + ListFlowsWithContext(aws.Context, *bedrockagent.ListFlowsInput, ...request.Option) (*bedrockagent.ListFlowsOutput, error) + ListFlowsRequest(*bedrockagent.ListFlowsInput) (*request.Request, *bedrockagent.ListFlowsOutput) + + ListFlowsPages(*bedrockagent.ListFlowsInput, func(*bedrockagent.ListFlowsOutput, bool) bool) error + ListFlowsPagesWithContext(aws.Context, *bedrockagent.ListFlowsInput, func(*bedrockagent.ListFlowsOutput, bool) bool, ...request.Option) error + ListIngestionJobs(*bedrockagent.ListIngestionJobsInput) (*bedrockagent.ListIngestionJobsOutput, error) ListIngestionJobsWithContext(aws.Context, *bedrockagent.ListIngestionJobsInput, ...request.Option) (*bedrockagent.ListIngestionJobsOutput, error) ListIngestionJobsRequest(*bedrockagent.ListIngestionJobsInput) (*request.Request, *bedrockagent.ListIngestionJobsOutput) @@ -200,6 +273,13 @@ type BedrockAgentAPI interface { ListKnowledgeBasesPages(*bedrockagent.ListKnowledgeBasesInput, func(*bedrockagent.ListKnowledgeBasesOutput, bool) bool) error ListKnowledgeBasesPagesWithContext(aws.Context, *bedrockagent.ListKnowledgeBasesInput, func(*bedrockagent.ListKnowledgeBasesOutput, bool) bool, ...request.Option) error + ListPrompts(*bedrockagent.ListPromptsInput) (*bedrockagent.ListPromptsOutput, error) + ListPromptsWithContext(aws.Context, *bedrockagent.ListPromptsInput, ...request.Option) (*bedrockagent.ListPromptsOutput, error) + ListPromptsRequest(*bedrockagent.ListPromptsInput) (*request.Request, *bedrockagent.ListPromptsOutput) + + ListPromptsPages(*bedrockagent.ListPromptsInput, func(*bedrockagent.ListPromptsOutput, bool) bool) error + ListPromptsPagesWithContext(aws.Context, *bedrockagent.ListPromptsInput, func(*bedrockagent.ListPromptsOutput, bool) bool, ...request.Option) error + ListTagsForResource(*bedrockagent.ListTagsForResourceInput) (*bedrockagent.ListTagsForResourceOutput, error) ListTagsForResourceWithContext(aws.Context, *bedrockagent.ListTagsForResourceInput, ...request.Option) (*bedrockagent.ListTagsForResourceOutput, error) ListTagsForResourceRequest(*bedrockagent.ListTagsForResourceInput) (*request.Request, *bedrockagent.ListTagsForResourceOutput) @@ -208,6 +288,10 @@ type BedrockAgentAPI interface { PrepareAgentWithContext(aws.Context, *bedrockagent.PrepareAgentInput, ...request.Option) (*bedrockagent.PrepareAgentOutput, error) PrepareAgentRequest(*bedrockagent.PrepareAgentInput) (*request.Request, *bedrockagent.PrepareAgentOutput) + PrepareFlow(*bedrockagent.PrepareFlowInput) (*bedrockagent.PrepareFlowOutput, error) + PrepareFlowWithContext(aws.Context, *bedrockagent.PrepareFlowInput, ...request.Option) (*bedrockagent.PrepareFlowOutput, error) + PrepareFlowRequest(*bedrockagent.PrepareFlowInput) (*request.Request, *bedrockagent.PrepareFlowOutput) + StartIngestionJob(*bedrockagent.StartIngestionJobInput) (*bedrockagent.StartIngestionJobOutput, error) StartIngestionJobWithContext(aws.Context, *bedrockagent.StartIngestionJobInput, ...request.Option) (*bedrockagent.StartIngestionJobOutput, error) StartIngestionJobRequest(*bedrockagent.StartIngestionJobInput) (*request.Request, *bedrockagent.StartIngestionJobOutput) @@ -240,9 +324,21 @@ type BedrockAgentAPI interface { UpdateDataSourceWithContext(aws.Context, *bedrockagent.UpdateDataSourceInput, ...request.Option) (*bedrockagent.UpdateDataSourceOutput, error) UpdateDataSourceRequest(*bedrockagent.UpdateDataSourceInput) (*request.Request, *bedrockagent.UpdateDataSourceOutput) + UpdateFlow(*bedrockagent.UpdateFlowInput) (*bedrockagent.UpdateFlowOutput, error) + UpdateFlowWithContext(aws.Context, *bedrockagent.UpdateFlowInput, ...request.Option) (*bedrockagent.UpdateFlowOutput, error) + UpdateFlowRequest(*bedrockagent.UpdateFlowInput) (*request.Request, *bedrockagent.UpdateFlowOutput) + + UpdateFlowAlias(*bedrockagent.UpdateFlowAliasInput) (*bedrockagent.UpdateFlowAliasOutput, error) + UpdateFlowAliasWithContext(aws.Context, *bedrockagent.UpdateFlowAliasInput, ...request.Option) (*bedrockagent.UpdateFlowAliasOutput, error) + UpdateFlowAliasRequest(*bedrockagent.UpdateFlowAliasInput) (*request.Request, *bedrockagent.UpdateFlowAliasOutput) + UpdateKnowledgeBase(*bedrockagent.UpdateKnowledgeBaseInput) (*bedrockagent.UpdateKnowledgeBaseOutput, error) UpdateKnowledgeBaseWithContext(aws.Context, *bedrockagent.UpdateKnowledgeBaseInput, ...request.Option) (*bedrockagent.UpdateKnowledgeBaseOutput, error) UpdateKnowledgeBaseRequest(*bedrockagent.UpdateKnowledgeBaseInput) (*request.Request, *bedrockagent.UpdateKnowledgeBaseOutput) + + UpdatePrompt(*bedrockagent.UpdatePromptInput) (*bedrockagent.UpdatePromptOutput, error) + UpdatePromptWithContext(aws.Context, *bedrockagent.UpdatePromptInput, ...request.Option) (*bedrockagent.UpdatePromptOutput, error) + UpdatePromptRequest(*bedrockagent.UpdatePromptInput) (*request.Request, *bedrockagent.UpdatePromptOutput) } var _ BedrockAgentAPI = (*bedrockagent.BedrockAgent)(nil) diff --git a/service/bedrockagentruntime/api.go b/service/bedrockagentruntime/api.go index 6118e76043a..faab8461ed9 100644 --- a/service/bedrockagentruntime/api.go +++ b/service/bedrockagentruntime/api.go @@ -21,6 +21,278 @@ import ( "github.com/aws/aws-sdk-go/private/protocol/restjson" ) +const opDeleteAgentMemory = "DeleteAgentMemory" + +// DeleteAgentMemoryRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAgentMemory operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteAgentMemory for more information on using the DeleteAgentMemory +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the DeleteAgentMemoryRequest method. +// req, resp := client.DeleteAgentMemoryRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/DeleteAgentMemory +func (c *BedrockAgentRuntime) DeleteAgentMemoryRequest(input *DeleteAgentMemoryInput) (req *request.Request, output *DeleteAgentMemoryOutput) { + op := &request.Operation{ + Name: opDeleteAgentMemory, + HTTPMethod: "DELETE", + HTTPPath: "/agents/{agentId}/agentAliases/{agentAliasId}/memories", + } + + if input == nil { + input = &DeleteAgentMemoryInput{} + } + + output = &DeleteAgentMemoryOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteAgentMemory API operation for Agents for Amazon Bedrock Runtime. +// +// Deletes memory from the specified memory identifier. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock Runtime's +// API operation DeleteAgentMemory for usage and error information. +// +// Returned Error Types: +// +// - ConflictException +// There was a conflict performing an operation. Resolve the conflict and 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. +// +// - ValidationException +// Input validation failed. Check your request parameters and retry the request. +// +// - InternalServerException +// An internal server error occurred. Retry your request. +// +// - DependencyFailedException +// There was an issue with a dependency. Check the resource configurations and +// retry the request. +// +// - BadGatewayException +// There was an issue with a dependency due to a server issue. Retry your request. +// +// - ThrottlingException +// The number of requests exceeds the limit. Resubmit your request later. +// +// - AccessDeniedException +// The request is denied because of missing access permissions. Check your permissions +// and retry your request. +// +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/DeleteAgentMemory +func (c *BedrockAgentRuntime) DeleteAgentMemory(input *DeleteAgentMemoryInput) (*DeleteAgentMemoryOutput, error) { + req, out := c.DeleteAgentMemoryRequest(input) + return out, req.Send() +} + +// DeleteAgentMemoryWithContext is the same as DeleteAgentMemory with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteAgentMemory for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgentRuntime) DeleteAgentMemoryWithContext(ctx aws.Context, input *DeleteAgentMemoryInput, opts ...request.Option) (*DeleteAgentMemoryOutput, error) { + req, out := c.DeleteAgentMemoryRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetAgentMemory = "GetAgentMemory" + +// GetAgentMemoryRequest generates a "aws/request.Request" representing the +// client's request for the GetAgentMemory operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetAgentMemory for more information on using the GetAgentMemory +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the GetAgentMemoryRequest method. +// req, resp := client.GetAgentMemoryRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/GetAgentMemory +func (c *BedrockAgentRuntime) GetAgentMemoryRequest(input *GetAgentMemoryInput) (req *request.Request, output *GetAgentMemoryOutput) { + op := &request.Operation{ + Name: opGetAgentMemory, + HTTPMethod: "GET", + HTTPPath: "/agents/{agentId}/agentAliases/{agentAliasId}/memories", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxItems", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetAgentMemoryInput{} + } + + output = &GetAgentMemoryOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetAgentMemory API operation for Agents for Amazon Bedrock Runtime. +// +// Gets the sessions stored in the memory of the agent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock Runtime's +// API operation GetAgentMemory for usage and error information. +// +// Returned Error Types: +// +// - ConflictException +// There was a conflict performing an operation. Resolve the conflict and 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. +// +// - ValidationException +// Input validation failed. Check your request parameters and retry the request. +// +// - InternalServerException +// An internal server error occurred. Retry your request. +// +// - DependencyFailedException +// There was an issue with a dependency. Check the resource configurations and +// retry the request. +// +// - BadGatewayException +// There was an issue with a dependency due to a server issue. Retry your request. +// +// - ThrottlingException +// The number of requests exceeds the limit. Resubmit your request later. +// +// - AccessDeniedException +// The request is denied because of missing access permissions. Check your permissions +// and retry your request. +// +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/GetAgentMemory +func (c *BedrockAgentRuntime) GetAgentMemory(input *GetAgentMemoryInput) (*GetAgentMemoryOutput, error) { + req, out := c.GetAgentMemoryRequest(input) + return out, req.Send() +} + +// GetAgentMemoryWithContext is the same as GetAgentMemory with the addition of +// the ability to pass a context and additional request options. +// +// See GetAgentMemory for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgentRuntime) GetAgentMemoryWithContext(ctx aws.Context, input *GetAgentMemoryInput, opts ...request.Option) (*GetAgentMemoryOutput, error) { + req, out := c.GetAgentMemoryRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetAgentMemoryPages iterates over the pages of a GetAgentMemory operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetAgentMemory method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetAgentMemory operation. +// pageNum := 0 +// err := client.GetAgentMemoryPages(params, +// func(page *bedrockagentruntime.GetAgentMemoryOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *BedrockAgentRuntime) GetAgentMemoryPages(input *GetAgentMemoryInput, fn func(*GetAgentMemoryOutput, bool) bool) error { + return c.GetAgentMemoryPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetAgentMemoryPagesWithContext same as GetAgentMemoryPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgentRuntime) GetAgentMemoryPagesWithContext(ctx aws.Context, input *GetAgentMemoryInput, fn func(*GetAgentMemoryOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetAgentMemoryInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetAgentMemoryRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*GetAgentMemoryOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + const opInvokeAgent = "InvokeAgent" // InvokeAgentRequest generates a "aws/request.Request" representing the @@ -72,7 +344,8 @@ func (c *BedrockAgentRuntime) InvokeAgentRequest(input *InvokeAgentInput) (req * // InvokeAgent API operation for Agents for Amazon Bedrock Runtime. // -// The CLI doesn't support InvokeAgent. +// The CLI doesn't support streaming operations in Amazon Bedrock, including +// InvokeAgent. // // Sends a prompt for the agent to process and respond to. Note the following // fields for the request: @@ -249,6 +522,7 @@ func (es *InvokeAgentEventStream) waitStreamPartClose() { // These events are: // // - PayloadPart +// - FilePart // - ReturnControlPayload // - TracePart // - ResponseStreamUnknownEvent @@ -316,63 +590,68 @@ func (es *InvokeAgentEventStream) Err() error { return nil } -const opRetrieve = "Retrieve" +const opInvokeFlow = "InvokeFlow" -// RetrieveRequest generates a "aws/request.Request" representing the -// client's request for the Retrieve operation. The "output" return +// InvokeFlowRequest generates a "aws/request.Request" representing the +// client's request for the InvokeFlow operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See Retrieve for more information on using the Retrieve +// See InvokeFlow for more information on using the InvokeFlow // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the RetrieveRequest method. -// req, resp := client.RetrieveRequest(params) +// // Example sending a request using the InvokeFlowRequest method. +// req, resp := client.InvokeFlowRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/Retrieve -func (c *BedrockAgentRuntime) RetrieveRequest(input *RetrieveInput) (req *request.Request, output *RetrieveOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeFlow +func (c *BedrockAgentRuntime) InvokeFlowRequest(input *InvokeFlowInput) (req *request.Request, output *InvokeFlowOutput) { op := &request.Operation{ - Name: opRetrieve, + Name: opInvokeFlow, HTTPMethod: "POST", - HTTPPath: "/knowledgebases/{knowledgeBaseId}/retrieve", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "", - TruncationToken: "", - }, + HTTPPath: "/flows/{flowIdentifier}/aliases/{flowAliasIdentifier}", } if input == nil { - input = &RetrieveInput{} + input = &InvokeFlowInput{} } - output = &RetrieveOutput{} + output = &InvokeFlowOutput{} req = c.newRequest(op, input, output) + + es := NewInvokeFlowEventStream() + output.eventStream = es + + req.Handlers.Send.Swap(client.LogHTTPResponseHandler.Name, client.LogHTTPResponseHeaderHandler) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, rest.UnmarshalHandler) + req.Handlers.Unmarshal.PushBack(es.runOutputStream) + req.Handlers.Unmarshal.PushBack(es.runOnStreamPartClose) return } -// Retrieve API operation for Agents for Amazon Bedrock Runtime. +// InvokeFlow API operation for Agents for Amazon Bedrock Runtime. // -// Queries a knowledge base and retrieves information from it. +// Invokes an alias of a flow to run the inputs that you specify and return +// the output of each node as a stream. If there's an error, the error is returned. +// For more information, see Test a flow in Amazon Bedrock (https://docs.aws.amazon.com/bedrock/latest/userguide/flows-test.html) +// in the Amazon Bedrock User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Agents for Amazon Bedrock Runtime's -// API operation Retrieve for usage and error information. +// API operation InvokeFlow for usage and error information. // // Returned Error Types: // @@ -407,33 +686,295 @@ func (c *BedrockAgentRuntime) RetrieveRequest(input *RetrieveInput) (req *reques // - ServiceQuotaExceededException // The number of requests exceeds the service quota. Resubmit your request later. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/Retrieve -func (c *BedrockAgentRuntime) Retrieve(input *RetrieveInput) (*RetrieveOutput, error) { - req, out := c.RetrieveRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeFlow +func (c *BedrockAgentRuntime) InvokeFlow(input *InvokeFlowInput) (*InvokeFlowOutput, error) { + req, out := c.InvokeFlowRequest(input) return out, req.Send() } -// RetrieveWithContext is the same as Retrieve with the addition of +// InvokeFlowWithContext is the same as InvokeFlow with the addition of // the ability to pass a context and additional request options. // -// See Retrieve for details on how to use this API operation. +// See InvokeFlow for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *BedrockAgentRuntime) RetrieveWithContext(ctx aws.Context, input *RetrieveInput, opts ...request.Option) (*RetrieveOutput, error) { - req, out := c.RetrieveRequest(input) +func (c *BedrockAgentRuntime) InvokeFlowWithContext(ctx aws.Context, input *InvokeFlowInput, opts ...request.Option) (*InvokeFlowOutput, error) { + req, out := c.InvokeFlowRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// RetrievePages iterates over the pages of a Retrieve operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See Retrieve method for more information on how to use this operation. +var _ awserr.Error +var _ time.Time + +// InvokeFlowEventStream provides the event stream handling for the InvokeFlow. +// +// For testing and mocking the event stream this type should be initialized via +// the NewInvokeFlowEventStream constructor function. Using the functional options +// to pass in nested mock behavior. +type InvokeFlowEventStream struct { + + // Reader is the EventStream reader for the FlowResponseStream + // events. This value is automatically set by the SDK when the API call is made + // Use this member when unit testing your code with the SDK to mock out the + // EventStream Reader. + // + // Must not be nil. + Reader FlowResponseStreamReader + + outputReader io.ReadCloser + + done chan struct{} + closeOnce sync.Once + err *eventstreamapi.OnceError +} + +// NewInvokeFlowEventStream initializes an InvokeFlowEventStream. +// This function should only be used for testing and mocking the InvokeFlowEventStream +// stream within your application. +// +// The Reader member must be set before reading events from the stream. +// +// es := NewInvokeFlowEventStream(func(o *InvokeFlowEventStream){ +// es.Reader = myMockStreamReader +// }) +func NewInvokeFlowEventStream(opts ...func(*InvokeFlowEventStream)) *InvokeFlowEventStream { + es := &InvokeFlowEventStream{ + done: make(chan struct{}), + err: eventstreamapi.NewOnceError(), + } + + for _, fn := range opts { + fn(es) + } + + return es +} + +func (es *InvokeFlowEventStream) runOnStreamPartClose(r *request.Request) { + if es.done == nil { + return + } + go es.waitStreamPartClose() + +} + +func (es *InvokeFlowEventStream) waitStreamPartClose() { + var outputErrCh <-chan struct{} + if v, ok := es.Reader.(interface{ ErrorSet() <-chan struct{} }); ok { + outputErrCh = v.ErrorSet() + } + var outputClosedCh <-chan struct{} + if v, ok := es.Reader.(interface{ Closed() <-chan struct{} }); ok { + outputClosedCh = v.Closed() + } + + select { + case <-es.done: + case <-outputErrCh: + es.err.SetError(es.Reader.Err()) + es.Close() + case <-outputClosedCh: + if err := es.Reader.Err(); err != nil { + es.err.SetError(es.Reader.Err()) + } + es.Close() + } +} + +// Events returns a channel to read events from. +// +// These events are: +// +// - FlowCompletionEvent +// - FlowOutputEvent +// - FlowResponseStreamUnknownEvent +func (es *InvokeFlowEventStream) Events() <-chan FlowResponseStreamEvent { + return es.Reader.Events() +} + +func (es *InvokeFlowEventStream) runOutputStream(r *request.Request) { + var opts []func(*eventstream.Decoder) + if r.Config.Logger != nil && r.Config.LogLevel.Matches(aws.LogDebugWithEventStreamBody) { + opts = append(opts, eventstream.DecodeWithLogger(r.Config.Logger)) + } + + unmarshalerForEvent := unmarshalerForFlowResponseStreamEvent{ + metadata: protocol.ResponseMetadata{ + StatusCode: r.HTTPResponse.StatusCode, + RequestID: r.RequestID, + }, + }.UnmarshalerForEventName + + decoder := eventstream.NewDecoder(r.HTTPResponse.Body, opts...) + eventReader := eventstreamapi.NewEventReader(decoder, + protocol.HandlerPayloadUnmarshal{ + Unmarshalers: r.Handlers.UnmarshalStream, + }, + unmarshalerForEvent, + ) + + es.outputReader = r.HTTPResponse.Body + es.Reader = newReadFlowResponseStream(eventReader) +} + +// Close closes the stream. This will also cause the stream to be closed. +// Close must be called when done using the stream API. Not calling Close +// may result in resource leaks. +// +// You can use the closing of the Reader's Events channel to terminate your +// application's read from the API's stream. +func (es *InvokeFlowEventStream) Close() (err error) { + es.closeOnce.Do(es.safeClose) + return es.Err() +} + +func (es *InvokeFlowEventStream) safeClose() { + if es.done != nil { + close(es.done) + } + + es.Reader.Close() + if es.outputReader != nil { + es.outputReader.Close() + } +} + +// Err returns any error that occurred while reading or writing EventStream +// Events from the service API's response. Returns nil if there were no errors. +func (es *InvokeFlowEventStream) Err() error { + if err := es.err.Err(); err != nil { + return err + } + if err := es.Reader.Err(); err != nil { + return err + } + + return nil +} + +const opRetrieve = "Retrieve" + +// RetrieveRequest generates a "aws/request.Request" representing the +// client's request for the Retrieve operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See Retrieve for more information on using the Retrieve +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the RetrieveRequest method. +// req, resp := client.RetrieveRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/Retrieve +func (c *BedrockAgentRuntime) RetrieveRequest(input *RetrieveInput) (req *request.Request, output *RetrieveOutput) { + op := &request.Operation{ + Name: opRetrieve, + HTTPMethod: "POST", + HTTPPath: "/knowledgebases/{knowledgeBaseId}/retrieve", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "", + TruncationToken: "", + }, + } + + if input == nil { + input = &RetrieveInput{} + } + + output = &RetrieveOutput{} + req = c.newRequest(op, input, output) + return +} + +// Retrieve API operation for Agents for Amazon Bedrock Runtime. +// +// Queries a knowledge base and retrieves information from it. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Agents for Amazon Bedrock Runtime's +// API operation Retrieve for usage and error information. +// +// Returned Error Types: +// +// - ConflictException +// There was a conflict performing an operation. Resolve the conflict and 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. +// +// - ValidationException +// Input validation failed. Check your request parameters and retry the request. +// +// - InternalServerException +// An internal server error occurred. Retry your request. +// +// - DependencyFailedException +// There was an issue with a dependency. Check the resource configurations and +// retry the request. +// +// - BadGatewayException +// There was an issue with a dependency due to a server issue. Retry your request. +// +// - ThrottlingException +// The number of requests exceeds the limit. Resubmit your request later. +// +// - AccessDeniedException +// The request is denied because of missing access permissions. Check your permissions +// and retry your request. +// +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/Retrieve +func (c *BedrockAgentRuntime) Retrieve(input *RetrieveInput) (*RetrieveOutput, error) { + req, out := c.RetrieveRequest(input) + return out, req.Send() +} + +// RetrieveWithContext is the same as Retrieve with the addition of +// the ability to pass a context and additional request options. +// +// See Retrieve for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockAgentRuntime) RetrieveWithContext(ctx aws.Context, input *RetrieveInput, opts ...request.Option) (*RetrieveOutput, error) { + req, out := c.RetrieveRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// RetrievePages iterates over the pages of a Retrieve operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See Retrieve method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // @@ -615,6 +1156,9 @@ func (s AccessDeniedException) GoString() string { return s.String() } +// The AccessDeniedException is and event in the FlowResponseStream group of events. +func (s *AccessDeniedException) eventFlowResponseStream() {} + // The AccessDeniedException is and event in the ResponseStream group of events. func (s *AccessDeniedException) eventResponseStream() {} @@ -703,6 +1247,10 @@ type ActionGroupInvocationInput_ struct { // String and GoString methods. ApiPath *string `locationName:"apiPath" type:"string" sensitive:"true"` + // How fulfillment of the action is handled. For more information, see Handling + // fulfillment of the action (https://docs.aws.amazon.com/bedrock/latest/userguide/action-handle.html). + ExecutionType *string `locationName:"executionType" type:"string" enum:"ExecutionType"` + // The function in the action group to call. // // Function is a sensitive parameter and its value will be @@ -710,6 +1258,10 @@ type ActionGroupInvocationInput_ struct { // String and GoString methods. Function *string `locationName:"function" type:"string" sensitive:"true"` + // The unique identifier of the invocation. Only returned if the executionType + // is RETURN_CONTROL. + InvocationId *string `locationName:"invocationId" type:"string"` + // The parameters in the Lambda input event. Parameters []*Parameter `locationName:"parameters" type:"list"` @@ -754,12 +1306,24 @@ func (s *ActionGroupInvocationInput_) SetApiPath(v string) *ActionGroupInvocatio return s } +// SetExecutionType sets the ExecutionType field's value. +func (s *ActionGroupInvocationInput_) SetExecutionType(v string) *ActionGroupInvocationInput_ { + s.ExecutionType = &v + return s +} + // SetFunction sets the Function field's value. func (s *ActionGroupInvocationInput_) SetFunction(v string) *ActionGroupInvocationInput_ { s.Function = &v return s } +// SetInvocationId sets the InvocationId field's value. +func (s *ActionGroupInvocationInput_) SetInvocationId(v string) *ActionGroupInvocationInput_ { + s.InvocationId = &v + return s +} + // SetParameters sets the Parameters field's value. func (s *ActionGroupInvocationInput_) SetParameters(v []*Parameter) *ActionGroupInvocationInput_ { s.Parameters = v @@ -1156,6 +1720,9 @@ func (s BadGatewayException) GoString() string { return s.String() } +// The BadGatewayException is and event in the FlowResponseStream group of events. +func (s *BadGatewayException) eventFlowResponseStream() {} + // The BadGatewayException is and event in the ResponseStream group of events. func (s *BadGatewayException) eventResponseStream() {} @@ -1314,7 +1881,79 @@ func (s *ByteContentDoc) SetIdentifier(v string) *ByteContentDoc { return s } -// An object containing a segment of the generated response that is based on +// The property contains the file to chat with, along with its attributes. +type ByteContentFile struct { + _ struct{} `type:"structure"` + + // The byte value of the file to attach, encoded as Base-64 string. The maximum + // size of all files that is attached is 10MB. You can attach a maximum of 5 + // files. + // + // Data is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by ByteContentFile's + // String and GoString methods. + // + // Data is automatically base64 encoded/decoded by the SDK. + // + // Data is a required field + Data []byte `locationName:"data" min:"1" type:"blob" required:"true" sensitive:"true"` + + // The MIME type of data contained in the file used for chat. + // + // MediaType is a required field + MediaType *string `locationName:"mediaType" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ByteContentFile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ByteContentFile) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ByteContentFile) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ByteContentFile"} + if s.Data == nil { + invalidParams.Add(request.NewErrParamRequired("Data")) + } + if s.Data != nil && len(s.Data) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Data", 1)) + } + if s.MediaType == nil { + invalidParams.Add(request.NewErrParamRequired("MediaType")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetData sets the Data field's value. +func (s *ByteContentFile) SetData(v []byte) *ByteContentFile { + s.Data = v + return s +} + +// SetMediaType sets the MediaType field's value. +func (s *ByteContentFile) SetMediaType(v string) *ByteContentFile { + s.MediaType = &v + return s +} + +// An object containing a segment of the generated response that is based on // a source in the knowledge base, alongside information about the source. // // This data type is used in the following API operations: @@ -1364,6 +2003,107 @@ func (s *Citation) SetRetrievedReferences(v []*RetrievedReference) *Citation { return s } +// Contains information about the code interpreter being invoked. +type CodeInterpreterInvocationInput_ struct { + _ struct{} `type:"structure"` + + // The code for the code interpreter to use. + Code *string `locationName:"code" type:"string"` + + // Files that are uploaded for code interpreter to use. + Files []*string `locationName:"files" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CodeInterpreterInvocationInput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CodeInterpreterInvocationInput_) GoString() string { + return s.String() +} + +// SetCode sets the Code field's value. +func (s *CodeInterpreterInvocationInput_) SetCode(v string) *CodeInterpreterInvocationInput_ { + s.Code = &v + return s +} + +// SetFiles sets the Files field's value. +func (s *CodeInterpreterInvocationInput_) SetFiles(v []*string) *CodeInterpreterInvocationInput_ { + s.Files = v + return s +} + +// Contains the JSON-formatted string returned by the API invoked by the code +// interpreter. +type CodeInterpreterInvocationOutput_ struct { + _ struct{} `type:"structure"` + + // Contains the error returned from code execution. + ExecutionError *string `locationName:"executionError" type:"string"` + + // Contains the successful output returned from code execution + ExecutionOutput *string `locationName:"executionOutput" type:"string"` + + // Indicates if the execution of the code timed out. + ExecutionTimeout *bool `locationName:"executionTimeout" type:"boolean"` + + // Contains output files, if generated by code execution. + Files []*string `locationName:"files" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CodeInterpreterInvocationOutput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CodeInterpreterInvocationOutput_) GoString() string { + return s.String() +} + +// SetExecutionError sets the ExecutionError field's value. +func (s *CodeInterpreterInvocationOutput_) SetExecutionError(v string) *CodeInterpreterInvocationOutput_ { + s.ExecutionError = &v + return s +} + +// SetExecutionOutput sets the ExecutionOutput field's value. +func (s *CodeInterpreterInvocationOutput_) SetExecutionOutput(v string) *CodeInterpreterInvocationOutput_ { + s.ExecutionOutput = &v + return s +} + +// SetExecutionTimeout sets the ExecutionTimeout field's value. +func (s *CodeInterpreterInvocationOutput_) SetExecutionTimeout(v bool) *CodeInterpreterInvocationOutput_ { + s.ExecutionTimeout = &v + return s +} + +// SetFiles sets the Files field's value. +func (s *CodeInterpreterInvocationOutput_) SetFiles(v []*string) *CodeInterpreterInvocationOutput_ { + s.Files = v + return s +} + // There was a conflict performing an operation. Resolve the conflict and retry // your request. type ConflictException struct { @@ -1391,6 +2131,9 @@ func (s ConflictException) GoString() string { return s.String() } +// The ConflictException is and event in the FlowResponseStream group of events. +func (s *ConflictException) eventFlowResponseStream() {} + // The ConflictException is and event in the ResponseStream group of events. func (s *ConflictException) eventResponseStream() {} @@ -1495,6 +2238,106 @@ func (s *ContentBody) SetBody(v string) *ContentBody { return s } +type DeleteAgentMemoryInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of an alias of an agent. + // + // AgentAliasId is a required field + AgentAliasId *string `location:"uri" locationName:"agentAliasId" type:"string" required:"true"` + + // The unique identifier of the agent to which the alias belongs. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The unique identifier of the memory. + MemoryId *string `location:"querystring" locationName:"memoryId" min:"2" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentMemoryInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentMemoryInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAgentMemoryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAgentMemoryInput"} + if s.AgentAliasId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) + } + if s.AgentAliasId != nil && len(*s.AgentAliasId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 1)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.MemoryId != nil && len(*s.MemoryId) < 2 { + invalidParams.Add(request.NewErrParamMinLen("MemoryId", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *DeleteAgentMemoryInput) SetAgentAliasId(v string) *DeleteAgentMemoryInput { + s.AgentAliasId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *DeleteAgentMemoryInput) SetAgentId(v string) *DeleteAgentMemoryInput { + s.AgentId = &v + return s +} + +// SetMemoryId sets the MemoryId field's value. +func (s *DeleteAgentMemoryInput) SetMemoryId(v string) *DeleteAgentMemoryInput { + s.MemoryId = &v + return s +} + +type DeleteAgentMemoryOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentMemoryOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteAgentMemoryOutput) GoString() string { + return s.String() +} + // There was an issue with a dependency. Check the resource configurations and // retry the request. type DependencyFailedException struct { @@ -1526,6 +2369,9 @@ func (s DependencyFailedException) GoString() string { return s.String() } +// The DependencyFailedException is and event in the FlowResponseStream group of events. +func (s *DependencyFailedException) eventFlowResponseStream() {} + // The DependencyFailedException is and event in the ResponseStream group of events. func (s *DependencyFailedException) eventResponseStream() {} @@ -1879,16 +2725,13 @@ func (s *FailureTrace) SetTraceId(v string) *FailureTrace { return s } -// Contains details about the response to the user. -type FinalResponse struct { +// Contains intermediate response for code interpreter if any files have been +// generated. +type FilePart struct { _ struct{} `type:"structure"` - // The text in the response to the user. - // - // Text is a sensitive parameter and its value will be - // replaced with "sensitive" in string returned by FinalResponse's - // String and GoString methods. - Text *string `locationName:"text" type:"string" sensitive:"true"` + // Files containing intermediate response for the user. + Files []*OutputFile `locationName:"files" type:"list"` } // String returns the string representation. @@ -1896,7 +2739,7 @@ type FinalResponse struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FinalResponse) String() string { +func (s FilePart) String() string { return awsutil.Prettify(s) } @@ -1905,35 +2748,59 @@ func (s FinalResponse) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FinalResponse) GoString() string { +func (s FilePart) GoString() string { return s.String() } -// SetText sets the Text field's value. -func (s *FinalResponse) SetText(v string) *FinalResponse { - s.Text = &v +// SetFiles sets the Files field's value. +func (s *FilePart) SetFiles(v []*OutputFile) *FilePart { + s.Files = v return s } -// Contains information about the function that the agent predicts should be -// called. -// -// This data type is used in the following API operations: -// -// - In the returnControl field of the InvokeAgent response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html#API_agent-runtime_InvokeAgent_ResponseSyntax) -type FunctionInvocationInput_ struct { +// The FilePart is and event in the ResponseStream group of events. +func (s *FilePart) eventResponseStream() {} + +// UnmarshalEvent unmarshals the EventStream Message into the FilePart value. +// This method is only used internally within the SDK's EventStream handling. +func (s *FilePart) UnmarshalEvent( + payloadUnmarshaler protocol.PayloadUnmarshaler, + msg eventstream.Message, +) error { + if err := payloadUnmarshaler.UnmarshalPayload( + bytes.NewReader(msg.Payload), s, + ); err != nil { + return err + } + return nil +} + +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. +func (s *FilePart) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { + msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) + var buf bytes.Buffer + if err = pm.MarshalPayload(&buf, s); err != nil { + return eventstream.Message{}, err + } + msg.Payload = buf.Bytes() + return msg, err +} + +// The source file of the content contained in the wrapper object. +type FileSource struct { _ struct{} `type:"structure"` - // The action group that the function belongs to. - // - // ActionGroup is a required field - ActionGroup *string `locationName:"actionGroup" type:"string" required:"true"` + // The data and the text of the attached files. + ByteContent *ByteContentFile `locationName:"byteContent" type:"structure"` - // The name of the function. - Function *string `locationName:"function" type:"string"` + // The s3 location of the files to attach. + S3Location *S3ObjectFile `locationName:"s3Location" type:"structure"` - // A list of parameters of the function. - Parameters []*FunctionParameter `locationName:"parameters" type:"list"` + // The source type of the files to attach. + // + // SourceType is a required field + SourceType *string `locationName:"sourceType" type:"string" required:"true" enum:"FileSourceType"` } // String returns the string representation. @@ -1941,7 +2808,7 @@ type FunctionInvocationInput_ struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FunctionInvocationInput_) String() string { +func (s FileSource) String() string { return awsutil.Prettify(s) } @@ -1950,12 +2817,595 @@ func (s FunctionInvocationInput_) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s FunctionInvocationInput_) GoString() string { +func (s FileSource) GoString() string { return s.String() } -// SetActionGroup sets the ActionGroup field's value. -func (s *FunctionInvocationInput_) SetActionGroup(v string) *FunctionInvocationInput_ { +// Validate inspects the fields of the type to determine if they are valid. +func (s *FileSource) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FileSource"} + if s.SourceType == nil { + invalidParams.Add(request.NewErrParamRequired("SourceType")) + } + if s.ByteContent != nil { + if err := s.ByteContent.Validate(); err != nil { + invalidParams.AddNested("ByteContent", err.(request.ErrInvalidParams)) + } + } + if s.S3Location != nil { + if err := s.S3Location.Validate(); err != nil { + invalidParams.AddNested("S3Location", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetByteContent sets the ByteContent field's value. +func (s *FileSource) SetByteContent(v *ByteContentFile) *FileSource { + s.ByteContent = v + return s +} + +// SetS3Location sets the S3Location field's value. +func (s *FileSource) SetS3Location(v *S3ObjectFile) *FileSource { + s.S3Location = v + return s +} + +// SetSourceType sets the SourceType field's value. +func (s *FileSource) SetSourceType(v string) *FileSource { + s.SourceType = &v + return s +} + +// Contains details about the response to the user. +type FinalResponse struct { + _ struct{} `type:"structure"` + + // The text in the response to the user. + // + // Text is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by FinalResponse's + // String and GoString methods. + Text *string `locationName:"text" type:"string" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FinalResponse) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FinalResponse) GoString() string { + return s.String() +} + +// SetText sets the Text field's value. +func (s *FinalResponse) SetText(v string) *FinalResponse { + s.Text = &v + return s +} + +// Contains information about why a flow completed. +// +// This data type is used in the following API operations: +// +// - InvokeFlow response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeFlow.html#API_agent_InvokeFlow_ResponseSyntax) +type FlowCompletionEvent struct { + _ struct{} `type:"structure" sensitive:"true"` + + // The reason that the flow completed. + // + // CompletionReason is a required field + CompletionReason *string `locationName:"completionReason" type:"string" required:"true" enum:"FlowCompletionReason"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowCompletionEvent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowCompletionEvent) GoString() string { + return s.String() +} + +// SetCompletionReason sets the CompletionReason field's value. +func (s *FlowCompletionEvent) SetCompletionReason(v string) *FlowCompletionEvent { + s.CompletionReason = &v + return s +} + +// The FlowCompletionEvent is and event in the FlowResponseStream group of events. +func (s *FlowCompletionEvent) eventFlowResponseStream() {} + +// UnmarshalEvent unmarshals the EventStream Message into the FlowCompletionEvent value. +// This method is only used internally within the SDK's EventStream handling. +func (s *FlowCompletionEvent) UnmarshalEvent( + payloadUnmarshaler protocol.PayloadUnmarshaler, + msg eventstream.Message, +) error { + if err := payloadUnmarshaler.UnmarshalPayload( + bytes.NewReader(msg.Payload), s, + ); err != nil { + return err + } + return nil +} + +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. +func (s *FlowCompletionEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { + msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) + var buf bytes.Buffer + if err = pm.MarshalPayload(&buf, s); err != nil { + return eventstream.Message{}, err + } + msg.Payload = buf.Bytes() + return msg, err +} + +// Contains information about an input into the flow. +// +// This data type is used in the following API operations: +// +// - InvokeFlow request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeFlow.html#API_agent_InvokeFlow_RequestSyntax) +type FlowInputContent struct { + _ struct{} `type:"structure" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowInputContent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowInputContent) GoString() string { + return s.String() +} + +// Contains information about an input into the flow and what to do with it. +// +// This data type is used in the following API operations: +// +// - InvokeFlow request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeFlow.html#API_agent_InvokeFlow_RequestSyntax) +type FlowInput_ struct { + _ struct{} `type:"structure"` + + // Contains information about an input into the flow. + // + // Content is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by FlowInput_'s + // String and GoString methods. + // + // Content is a required field + Content *FlowInputContent `locationName:"content" type:"structure" required:"true" sensitive:"true"` + + // A name for the input of the flow input node. + // + // NodeName is a required field + NodeName *string `locationName:"nodeName" type:"string" required:"true"` + + // A name for the output of the flow input node. + // + // NodeOutputName is a required field + NodeOutputName *string `locationName:"nodeOutputName" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowInput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowInput_) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FlowInput_) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FlowInput_"} + if s.Content == nil { + invalidParams.Add(request.NewErrParamRequired("Content")) + } + if s.NodeName == nil { + invalidParams.Add(request.NewErrParamRequired("NodeName")) + } + if s.NodeOutputName == nil { + invalidParams.Add(request.NewErrParamRequired("NodeOutputName")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContent sets the Content field's value. +func (s *FlowInput_) SetContent(v *FlowInputContent) *FlowInput_ { + s.Content = v + return s +} + +// SetNodeName sets the NodeName field's value. +func (s *FlowInput_) SetNodeName(v string) *FlowInput_ { + s.NodeName = &v + return s +} + +// SetNodeOutputName sets the NodeOutputName field's value. +func (s *FlowInput_) SetNodeOutputName(v string) *FlowInput_ { + s.NodeOutputName = &v + return s +} + +// Contains information about the output node. +// +// This data type is used in the following API operations: +// +// - InvokeFlow request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeFlow.html#API_agent_InvokeFlow_RequestSyntax) +type FlowOutputContent struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowOutputContent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowOutputContent) GoString() string { + return s.String() +} + +// Contains information about an output from flow invoction. +// +// This data type is used in the following API operations: +// +// - InvokeFlow response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeFlow.html#API_agent_InvokeFlow_ResponseSyntax) +type FlowOutputEvent struct { + _ struct{} `type:"structure" sensitive:"true"` + + // The output of the node. + // + // Content is a required field + Content *FlowOutputContent `locationName:"content" type:"structure" required:"true"` + + // The name of the node to which input was provided. + // + // NodeName is a required field + NodeName *string `locationName:"nodeName" type:"string" required:"true"` + + // The type of node to which input was provided. + // + // NodeType is a required field + NodeType *string `locationName:"nodeType" type:"string" required:"true" enum:"NodeType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowOutputEvent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FlowOutputEvent) GoString() string { + return s.String() +} + +// SetContent sets the Content field's value. +func (s *FlowOutputEvent) SetContent(v *FlowOutputContent) *FlowOutputEvent { + s.Content = v + return s +} + +// SetNodeName sets the NodeName field's value. +func (s *FlowOutputEvent) SetNodeName(v string) *FlowOutputEvent { + s.NodeName = &v + return s +} + +// SetNodeType sets the NodeType field's value. +func (s *FlowOutputEvent) SetNodeType(v string) *FlowOutputEvent { + s.NodeType = &v + return s +} + +// The FlowOutputEvent is and event in the FlowResponseStream group of events. +func (s *FlowOutputEvent) eventFlowResponseStream() {} + +// UnmarshalEvent unmarshals the EventStream Message into the FlowOutputEvent value. +// This method is only used internally within the SDK's EventStream handling. +func (s *FlowOutputEvent) UnmarshalEvent( + payloadUnmarshaler protocol.PayloadUnmarshaler, + msg eventstream.Message, +) error { + if err := payloadUnmarshaler.UnmarshalPayload( + bytes.NewReader(msg.Payload), s, + ); err != nil { + return err + } + return nil +} + +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. +func (s *FlowOutputEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { + msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) + var buf bytes.Buffer + if err = pm.MarshalPayload(&buf, s); err != nil { + return eventstream.Message{}, err + } + msg.Payload = buf.Bytes() + return msg, err +} + +// FlowResponseStreamEvent groups together all EventStream +// events writes for FlowResponseStream. +// +// These events are: +// +// - FlowCompletionEvent +// - FlowOutputEvent +type FlowResponseStreamEvent interface { + eventFlowResponseStream() + eventstreamapi.Marshaler + eventstreamapi.Unmarshaler +} + +// FlowResponseStreamReader provides the interface for reading to the stream. The +// default implementation for this interface will be FlowResponseStream. +// +// The reader's Close method must allow multiple concurrent calls. +// +// These events are: +// +// - FlowCompletionEvent +// - FlowOutputEvent +// - FlowResponseStreamUnknownEvent +type FlowResponseStreamReader interface { + // Returns a channel of events as they are read from the event stream. + Events() <-chan FlowResponseStreamEvent + + // Close will stop the reader reading events from the stream. + Close() error + + // Returns any error that has occurred while reading from the event stream. + Err() error +} + +type readFlowResponseStream struct { + eventReader *eventstreamapi.EventReader + stream chan FlowResponseStreamEvent + err *eventstreamapi.OnceError + + done chan struct{} + closeOnce sync.Once +} + +func newReadFlowResponseStream(eventReader *eventstreamapi.EventReader) *readFlowResponseStream { + r := &readFlowResponseStream{ + eventReader: eventReader, + stream: make(chan FlowResponseStreamEvent), + done: make(chan struct{}), + err: eventstreamapi.NewOnceError(), + } + go r.readEventStream() + + return r +} + +// Close will close the underlying event stream reader. +func (r *readFlowResponseStream) Close() error { + r.closeOnce.Do(r.safeClose) + return r.Err() +} + +func (r *readFlowResponseStream) ErrorSet() <-chan struct{} { + return r.err.ErrorSet() +} + +func (r *readFlowResponseStream) Closed() <-chan struct{} { + return r.done +} + +func (r *readFlowResponseStream) safeClose() { + close(r.done) +} + +func (r *readFlowResponseStream) Err() error { + return r.err.Err() +} + +func (r *readFlowResponseStream) Events() <-chan FlowResponseStreamEvent { + return r.stream +} + +func (r *readFlowResponseStream) readEventStream() { + defer r.Close() + defer close(r.stream) + + for { + event, err := r.eventReader.ReadEvent() + if err != nil { + if err == io.EOF { + return + } + select { + case <-r.done: + // If closed already ignore the error + return + default: + } + if _, ok := err.(*eventstreamapi.UnknownMessageTypeError); ok { + continue + } + r.err.SetError(err) + return + } + + select { + case r.stream <- event.(FlowResponseStreamEvent): + case <-r.done: + return + } + } +} + +type unmarshalerForFlowResponseStreamEvent struct { + metadata protocol.ResponseMetadata +} + +func (u unmarshalerForFlowResponseStreamEvent) UnmarshalerForEventName(eventType string) (eventstreamapi.Unmarshaler, error) { + switch eventType { + case "flowCompletionEvent": + return &FlowCompletionEvent{}, nil + case "flowOutputEvent": + return &FlowOutputEvent{}, nil + case "accessDeniedException": + return newErrorAccessDeniedException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "badGatewayException": + return newErrorBadGatewayException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "conflictException": + return newErrorConflictException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "dependencyFailedException": + return newErrorDependencyFailedException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "internalServerException": + return newErrorInternalServerException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "resourceNotFoundException": + return newErrorResourceNotFoundException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "serviceQuotaExceededException": + return newErrorServiceQuotaExceededException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "throttlingException": + return newErrorThrottlingException(u.metadata).(eventstreamapi.Unmarshaler), nil + case "validationException": + return newErrorValidationException(u.metadata).(eventstreamapi.Unmarshaler), nil + default: + return &FlowResponseStreamUnknownEvent{Type: eventType}, nil + } +} + +// FlowResponseStreamUnknownEvent provides a failsafe event for the +// FlowResponseStream group of events when an unknown event is received. +type FlowResponseStreamUnknownEvent struct { + Type string + Message eventstream.Message +} + +// The FlowResponseStreamUnknownEvent is and event in the FlowResponseStream +// group of events. +func (s *FlowResponseStreamUnknownEvent) eventFlowResponseStream() {} + +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. +func (e *FlowResponseStreamUnknownEvent) MarshalEvent(pm protocol.PayloadMarshaler) ( + msg eventstream.Message, err error, +) { + return e.Message.Clone(), nil +} + +// UnmarshalEvent unmarshals the EventStream Message into the FlowResponseStream value. +// This method is only used internally within the SDK's EventStream handling. +func (e *FlowResponseStreamUnknownEvent) UnmarshalEvent( + payloadUnmarshaler protocol.PayloadUnmarshaler, + msg eventstream.Message, +) error { + e.Message = msg.Clone() + return nil +} + +// Contains information about the function that the agent predicts should be +// called. +// +// This data type is used in the following API operations: +// +// - In the returnControl field of the InvokeAgent response (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html#API_agent-runtime_InvokeAgent_ResponseSyntax) +type FunctionInvocationInput_ struct { + _ struct{} `type:"structure"` + + // The action group that the function belongs to. + // + // ActionGroup is a required field + ActionGroup *string `locationName:"actionGroup" type:"string" required:"true"` + + // The name of the function. + Function *string `locationName:"function" type:"string"` + + // A list of parameters of the function. + Parameters []*FunctionParameter `locationName:"parameters" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FunctionInvocationInput_) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s FunctionInvocationInput_) GoString() string { + return s.String() +} + +// SetActionGroup sets the ActionGroup field's value. +func (s *FunctionInvocationInput_) SetActionGroup(v string) *FunctionInvocationInput_ { s.ActionGroup = &v return s } @@ -2132,49 +3582,243 @@ type GeneratedResponsePart struct { TextResponsePart *TextResponsePart `locationName:"textResponsePart" type:"structure" sensitive:"true"` } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GeneratedResponsePart) String() string { - return awsutil.Prettify(s) +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GeneratedResponsePart) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GeneratedResponsePart) GoString() string { + return s.String() +} + +// SetTextResponsePart sets the TextResponsePart field's value. +func (s *GeneratedResponsePart) SetTextResponsePart(v *TextResponsePart) *GeneratedResponsePart { + s.TextResponsePart = v + return s +} + +// Contains configurations for response generation based on the knowledge base +// query results. +// +// This data type is used in the following API operations: +// +// - RetrieveAndGenerate request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax) +type GenerationConfiguration struct { + _ struct{} `type:"structure"` + + // The configuration details for the guardrail. + GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` + + // Configuration settings for inference when using RetrieveAndGenerate to generate + // responses while using a knowledge base as a source. + InferenceConfig *InferenceConfig `locationName:"inferenceConfig" type:"structure"` + + // Contains the template for the prompt that's sent to the model for response + // generation. + PromptTemplate *PromptTemplate `locationName:"promptTemplate" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GenerationConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GenerationConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GenerationConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GenerationConfiguration"} + if s.GuardrailConfiguration != nil { + if err := s.GuardrailConfiguration.Validate(); err != nil { + invalidParams.AddNested("GuardrailConfiguration", err.(request.ErrInvalidParams)) + } + } + if s.PromptTemplate != nil { + if err := s.PromptTemplate.Validate(); err != nil { + invalidParams.AddNested("PromptTemplate", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. +func (s *GenerationConfiguration) SetGuardrailConfiguration(v *GuardrailConfiguration) *GenerationConfiguration { + s.GuardrailConfiguration = v + return s +} + +// SetInferenceConfig sets the InferenceConfig field's value. +func (s *GenerationConfiguration) SetInferenceConfig(v *InferenceConfig) *GenerationConfiguration { + s.InferenceConfig = v + return s +} + +// SetPromptTemplate sets the PromptTemplate field's value. +func (s *GenerationConfiguration) SetPromptTemplate(v *PromptTemplate) *GenerationConfiguration { + s.PromptTemplate = v + return s +} + +type GetAgentMemoryInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The unique identifier of an alias of an agent. + // + // AgentAliasId is a required field + AgentAliasId *string `location:"uri" locationName:"agentAliasId" type:"string" required:"true"` + + // The unique identifier of the agent to which the alias belongs. + // + // AgentId is a required field + AgentId *string `location:"uri" locationName:"agentId" type:"string" required:"true"` + + // The maximum number of items 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. + MaxItems *int64 `location:"querystring" locationName:"maxItems" min:"1" type:"integer"` + + // The unique identifier of the memory. + // + // MemoryId is a required field + MemoryId *string `location:"querystring" locationName:"memoryId" min:"2" type:"string" required:"true"` + + // The type of memory. + // + // MemoryType is a required field + MemoryType *string `location:"querystring" locationName:"memoryType" type:"string" required:"true" enum:"MemoryType"` + + // If the total number of results is greater than the maxItems 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. + NextToken *string `location:"querystring" locationName:"nextToken" min:"1" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentMemoryInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetAgentMemoryInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAgentMemoryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAgentMemoryInput"} + if s.AgentAliasId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentAliasId")) + } + if s.AgentAliasId != nil && len(*s.AgentAliasId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentAliasId", 1)) + } + if s.AgentId == nil { + invalidParams.Add(request.NewErrParamRequired("AgentId")) + } + if s.AgentId != nil && len(*s.AgentId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) + } + if s.MaxItems != nil && *s.MaxItems < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxItems", 1)) + } + if s.MemoryId == nil { + invalidParams.Add(request.NewErrParamRequired("MemoryId")) + } + if s.MemoryId != nil && len(*s.MemoryId) < 2 { + invalidParams.Add(request.NewErrParamMinLen("MemoryId", 2)) + } + if s.MemoryType == nil { + invalidParams.Add(request.NewErrParamRequired("MemoryType")) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAgentAliasId sets the AgentAliasId field's value. +func (s *GetAgentMemoryInput) SetAgentAliasId(v string) *GetAgentMemoryInput { + s.AgentAliasId = &v + return s +} + +// SetAgentId sets the AgentId field's value. +func (s *GetAgentMemoryInput) SetAgentId(v string) *GetAgentMemoryInput { + s.AgentId = &v + return s +} + +// SetMaxItems sets the MaxItems field's value. +func (s *GetAgentMemoryInput) SetMaxItems(v int64) *GetAgentMemoryInput { + s.MaxItems = &v + return s +} + +// SetMemoryId sets the MemoryId field's value. +func (s *GetAgentMemoryInput) SetMemoryId(v string) *GetAgentMemoryInput { + s.MemoryId = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GeneratedResponsePart) GoString() string { - return s.String() +// SetMemoryType sets the MemoryType field's value. +func (s *GetAgentMemoryInput) SetMemoryType(v string) *GetAgentMemoryInput { + s.MemoryType = &v + return s } -// SetTextResponsePart sets the TextResponsePart field's value. -func (s *GeneratedResponsePart) SetTextResponsePart(v *TextResponsePart) *GeneratedResponsePart { - s.TextResponsePart = v +// SetNextToken sets the NextToken field's value. +func (s *GetAgentMemoryInput) SetNextToken(v string) *GetAgentMemoryInput { + s.NextToken = &v return s } -// Contains configurations for response generation based on the knowledge base -// query results. -// -// This data type is used in the following API operations: -// -// - RetrieveAndGenerate request (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax) -type GenerationConfiguration struct { +type GetAgentMemoryOutput struct { _ struct{} `type:"structure"` - // The configuration details for the guardrail. - GuardrailConfiguration *GuardrailConfiguration `locationName:"guardrailConfiguration" type:"structure"` - - // Configuration settings for inference when using RetrieveAndGenerate to generate - // responses while using a knowledge base as a source. - InferenceConfig *InferenceConfig `locationName:"inferenceConfig" type:"structure"` + // Contains details of the sessions stored in the memory + MemoryContents []*Memory `locationName:"memoryContents" type:"list"` - // Contains the template for the prompt that's sent to the model for response - // generation. - PromptTemplate *PromptTemplate `locationName:"promptTemplate" type:"structure"` + // If the total number of results is greater than the maxItems value provided + // in the request, use this token when making another request in the nextToken + // field to return the next batch of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -2182,7 +3826,7 @@ type GenerationConfiguration struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GenerationConfiguration) String() string { +func (s GetAgentMemoryOutput) String() string { return awsutil.Prettify(s) } @@ -2191,45 +3835,19 @@ func (s GenerationConfiguration) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GenerationConfiguration) GoString() string { +func (s GetAgentMemoryOutput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GenerationConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GenerationConfiguration"} - if s.GuardrailConfiguration != nil { - if err := s.GuardrailConfiguration.Validate(); err != nil { - invalidParams.AddNested("GuardrailConfiguration", err.(request.ErrInvalidParams)) - } - } - if s.PromptTemplate != nil { - if err := s.PromptTemplate.Validate(); err != nil { - invalidParams.AddNested("PromptTemplate", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetGuardrailConfiguration sets the GuardrailConfiguration field's value. -func (s *GenerationConfiguration) SetGuardrailConfiguration(v *GuardrailConfiguration) *GenerationConfiguration { - s.GuardrailConfiguration = v - return s -} - -// SetInferenceConfig sets the InferenceConfig field's value. -func (s *GenerationConfiguration) SetInferenceConfig(v *InferenceConfig) *GenerationConfiguration { - s.InferenceConfig = v +// SetMemoryContents sets the MemoryContents field's value. +func (s *GetAgentMemoryOutput) SetMemoryContents(v []*Memory) *GetAgentMemoryOutput { + s.MemoryContents = v return s } -// SetPromptTemplate sets the PromptTemplate field's value. -func (s *GenerationConfiguration) SetPromptTemplate(v *PromptTemplate) *GenerationConfiguration { - s.PromptTemplate = v +// SetNextToken sets the NextToken field's value. +func (s *GetAgentMemoryOutput) SetNextToken(v string) *GetAgentMemoryOutput { + s.NextToken = &v return s } @@ -3023,6 +4641,86 @@ func (s *InferenceConfiguration) SetTopP(v float64) *InferenceConfiguration { return s } +// Contains details of the source files. +type InputFile struct { + _ struct{} `type:"structure"` + + // The name of the source file. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // Specifies where the files are located. + // + // Source is a required field + Source *FileSource `locationName:"source" type:"structure" required:"true"` + + // Specifies how the source files will be used by the code interpreter. + // + // UseCase is a required field + UseCase *string `locationName:"useCase" type:"string" required:"true" enum:"FileUseCase"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InputFile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InputFile) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *InputFile) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "InputFile"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Source == nil { + invalidParams.Add(request.NewErrParamRequired("Source")) + } + if s.UseCase == nil { + invalidParams.Add(request.NewErrParamRequired("UseCase")) + } + if s.Source != nil { + if err := s.Source.Validate(); err != nil { + invalidParams.AddNested("Source", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *InputFile) SetName(v string) *InputFile { + s.Name = &v + return s +} + +// SetSource sets the Source field's value. +func (s *InputFile) SetSource(v *FileSource) *InputFile { + s.Source = v + return s +} + +// SetUseCase sets the UseCase field's value. +func (s *InputFile) SetUseCase(v string) *InputFile { + s.UseCase = &v + return s +} + // An internal server error occurred. Retry your request. type InternalServerException struct { _ struct{} `type:"structure"` @@ -3049,6 +4747,9 @@ func (s InternalServerException) GoString() string { return s.String() } +// The InternalServerException is and event in the FlowResponseStream group of events. +func (s *InternalServerException) eventFlowResponseStream() {} + // The InternalServerException is and event in the ResponseStream group of events. func (s *InternalServerException) eventResponseStream() {} @@ -3172,6 +4873,9 @@ type InvocationInput_ struct { // Contains information about the action group to be invoked. ActionGroupInvocationInput *ActionGroupInvocationInput_ `locationName:"actionGroupInvocationInput" type:"structure"` + // Contains information about the code interpreter to be invoked. + CodeInterpreterInvocationInput *CodeInterpreterInvocationInput_ `locationName:"codeInterpreterInvocationInput" type:"structure"` + // Specifies whether the agent is invoking an action group or a knowledge base. InvocationType *string `locationName:"invocationType" type:"string" enum:"InvocationType"` @@ -3207,6 +4911,12 @@ func (s *InvocationInput_) SetActionGroupInvocationInput(v *ActionGroupInvocatio return s } +// SetCodeInterpreterInvocationInput sets the CodeInterpreterInvocationInput field's value. +func (s *InvocationInput_) SetCodeInterpreterInvocationInput(v *CodeInterpreterInvocationInput_) *InvocationInput_ { + s.CodeInterpreterInvocationInput = v + return s +} + // SetInvocationType sets the InvocationType field's value. func (s *InvocationInput_) SetInvocationType(v string) *InvocationInput_ { s.InvocationType = &v @@ -3322,6 +5032,9 @@ type InvokeAgentInput struct { // String and GoString methods. InputText *string `locationName:"inputText" type:"string" sensitive:"true"` + // The unique identifier of the agent memory. + MemoryId *string `locationName:"memoryId" min:"2" type:"string"` + // The unique identifier of the session. Use the same value across requests // to continue the same conversation. // @@ -3369,6 +5082,9 @@ func (s *InvokeAgentInput) Validate() error { if s.AgentId != nil && len(*s.AgentId) < 1 { invalidParams.Add(request.NewErrParamMinLen("AgentId", 1)) } + if s.MemoryId != nil && len(*s.MemoryId) < 2 { + invalidParams.Add(request.NewErrParamMinLen("MemoryId", 2)) + } if s.SessionId == nil { invalidParams.Add(request.NewErrParamRequired("SessionId")) } @@ -3411,38 +5127,228 @@ func (s *InvokeAgentInput) SetEndSession(v bool) *InvokeAgentInput { return s } -// SetInputText sets the InputText field's value. -func (s *InvokeAgentInput) SetInputText(v string) *InvokeAgentInput { - s.InputText = &v +// SetInputText sets the InputText field's value. +func (s *InvokeAgentInput) SetInputText(v string) *InvokeAgentInput { + s.InputText = &v + return s +} + +// SetMemoryId sets the MemoryId field's value. +func (s *InvokeAgentInput) SetMemoryId(v string) *InvokeAgentInput { + s.MemoryId = &v + return s +} + +// SetSessionId sets the SessionId field's value. +func (s *InvokeAgentInput) SetSessionId(v string) *InvokeAgentInput { + s.SessionId = &v + return s +} + +// SetSessionState sets the SessionState field's value. +func (s *InvokeAgentInput) SetSessionState(v *SessionState) *InvokeAgentInput { + s.SessionState = v + return s +} + +type InvokeAgentOutput struct { + _ struct{} `type:"structure" payload:"Completion"` + + eventStream *InvokeAgentEventStream + + // The MIME type of the input data in the request. The default value is application/json. + // + // ContentType is a required field + ContentType *string `location:"header" locationName:"x-amzn-bedrock-agent-content-type" type:"string" required:"true"` + + // The unique identifier of the agent memory. + MemoryId *string `location:"header" locationName:"x-amz-bedrock-agent-memory-id" min:"2" type:"string"` + + // The unique identifier of the session with the agent. + // + // SessionId is a required field + SessionId *string `location:"header" locationName:"x-amz-bedrock-agent-session-id" min:"2" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeAgentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeAgentOutput) GoString() string { + return s.String() +} + +// SetContentType sets the ContentType field's value. +func (s *InvokeAgentOutput) SetContentType(v string) *InvokeAgentOutput { + s.ContentType = &v + return s +} + +// SetMemoryId sets the MemoryId field's value. +func (s *InvokeAgentOutput) SetMemoryId(v string) *InvokeAgentOutput { + s.MemoryId = &v + return s +} + +// SetSessionId sets the SessionId field's value. +func (s *InvokeAgentOutput) SetSessionId(v string) *InvokeAgentOutput { + s.SessionId = &v + return s +} + +// GetStream returns the type to interact with the event stream. +func (s *InvokeAgentOutput) GetStream() *InvokeAgentEventStream { + return s.eventStream +} + +type InvokeFlowInput struct { + _ struct{} `type:"structure"` + + // The unique identifier of the flow alias. + // + // FlowAliasIdentifier is a required field + FlowAliasIdentifier *string `location:"uri" locationName:"flowAliasIdentifier" type:"string" required:"true"` + + // The unique identifier of the flow. + // + // FlowIdentifier is a required field + FlowIdentifier *string `location:"uri" locationName:"flowIdentifier" type:"string" required:"true"` + + // A list of objects, each containing information about an input into the flow. + // + // Inputs is a required field + Inputs []*FlowInput_ `locationName:"inputs" min:"1" type:"list" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeFlowInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeFlowInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *InvokeFlowInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "InvokeFlowInput"} + if s.FlowAliasIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowAliasIdentifier")) + } + if s.FlowAliasIdentifier != nil && len(*s.FlowAliasIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowAliasIdentifier", 1)) + } + if s.FlowIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("FlowIdentifier")) + } + if s.FlowIdentifier != nil && len(*s.FlowIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("FlowIdentifier", 1)) + } + if s.Inputs == nil { + invalidParams.Add(request.NewErrParamRequired("Inputs")) + } + if s.Inputs != nil && len(s.Inputs) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Inputs", 1)) + } + if s.Inputs != nil { + for i, v := range s.Inputs { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Inputs", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFlowAliasIdentifier sets the FlowAliasIdentifier field's value. +func (s *InvokeFlowInput) SetFlowAliasIdentifier(v string) *InvokeFlowInput { + s.FlowAliasIdentifier = &v + return s +} + +// SetFlowIdentifier sets the FlowIdentifier field's value. +func (s *InvokeFlowInput) SetFlowIdentifier(v string) *InvokeFlowInput { + s.FlowIdentifier = &v return s } -// SetSessionId sets the SessionId field's value. -func (s *InvokeAgentInput) SetSessionId(v string) *InvokeAgentInput { - s.SessionId = &v +// SetInputs sets the Inputs field's value. +func (s *InvokeFlowInput) SetInputs(v []*FlowInput_) *InvokeFlowInput { + s.Inputs = v return s } -// SetSessionState sets the SessionState field's value. -func (s *InvokeAgentInput) SetSessionState(v *SessionState) *InvokeAgentInput { - s.SessionState = v - return s +type InvokeFlowOutput struct { + _ struct{} `type:"structure" payload:"ResponseStream"` + + eventStream *InvokeFlowEventStream } -type InvokeAgentOutput struct { - _ struct{} `type:"structure" payload:"Completion"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeFlowOutput) String() string { + return awsutil.Prettify(s) +} - eventStream *InvokeAgentEventStream +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InvokeFlowOutput) GoString() string { + return s.String() +} - // The MIME type of the input data in the request. The default value is application/json. +// GetStream returns the type to interact with the event stream. +func (s *InvokeFlowOutput) GetStream() *InvokeFlowEventStream { + return s.eventStream +} + +// Configurations to apply to a knowledge base attached to the agent during +// query. For more information, see Knowledge base retrieval configurations +// (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html#session-state-kb). +type KnowledgeBaseConfiguration struct { + _ struct{} `type:"structure"` + + // The unique identifier for a knowledge base attached to the agent. // - // ContentType is a required field - ContentType *string `location:"header" locationName:"x-amzn-bedrock-agent-content-type" type:"string" required:"true"` + // KnowledgeBaseId is a required field + KnowledgeBaseId *string `locationName:"knowledgeBaseId" type:"string" required:"true"` - // The unique identifier of the session with the agent. + // The configurations to apply to the knowledge base during query. For more + // information, see Query configurations (https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html). // - // SessionId is a required field - SessionId *string `location:"header" locationName:"x-amz-bedrock-agent-session-id" min:"2" type:"string" required:"true"` + // RetrievalConfiguration is a required field + RetrievalConfiguration *KnowledgeBaseRetrievalConfiguration `locationName:"retrievalConfiguration" type:"structure" required:"true"` } // String returns the string representation. @@ -3450,7 +5356,7 @@ type InvokeAgentOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InvokeAgentOutput) String() string { +func (s KnowledgeBaseConfiguration) String() string { return awsutil.Prettify(s) } @@ -3459,25 +5365,41 @@ func (s InvokeAgentOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InvokeAgentOutput) GoString() string { +func (s KnowledgeBaseConfiguration) GoString() string { return s.String() } -// SetContentType sets the ContentType field's value. -func (s *InvokeAgentOutput) SetContentType(v string) *InvokeAgentOutput { - s.ContentType = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *KnowledgeBaseConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "KnowledgeBaseConfiguration"} + if s.KnowledgeBaseId == nil { + invalidParams.Add(request.NewErrParamRequired("KnowledgeBaseId")) + } + if s.RetrievalConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("RetrievalConfiguration")) + } + if s.RetrievalConfiguration != nil { + if err := s.RetrievalConfiguration.Validate(); err != nil { + invalidParams.AddNested("RetrievalConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetSessionId sets the SessionId field's value. -func (s *InvokeAgentOutput) SetSessionId(v string) *InvokeAgentOutput { - s.SessionId = &v +// SetKnowledgeBaseId sets the KnowledgeBaseId field's value. +func (s *KnowledgeBaseConfiguration) SetKnowledgeBaseId(v string) *KnowledgeBaseConfiguration { + s.KnowledgeBaseId = &v return s } -// GetStream returns the type to interact with the event stream. -func (s *InvokeAgentOutput) GetStream() *InvokeAgentEventStream { - return s.eventStream +// SetRetrievalConfiguration sets the RetrievalConfiguration field's value. +func (s *KnowledgeBaseConfiguration) SetRetrievalConfiguration(v *KnowledgeBaseRetrievalConfiguration) *KnowledgeBaseConfiguration { + s.RetrievalConfiguration = v + return s } // Contains details about the knowledge base to look up and the query to be @@ -3614,8 +5536,8 @@ func (s *KnowledgeBaseQuery) SetText(v string) *KnowledgeBaseQuery { return s } -// Contains configurations for the knowledge base query and retrieval process. -// For more information, see Query configurations (https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html). +// Contains configurations for knowledge base query. For more information, see +// Query configurations (https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html). // // This data type is used in the following API operations: // @@ -3753,7 +5675,7 @@ func (s *KnowledgeBaseRetrievalResult) SetScore(v float64) *KnowledgeBaseRetriev type KnowledgeBaseRetrieveAndGenerateConfiguration struct { _ struct{} `type:"structure"` - // Contains configurations for response generation based on the knowwledge base + // Contains configurations for response generation based on the knowledge base // query results. GenerationConfiguration *GenerationConfiguration `locationName:"generationConfiguration" type:"structure"` @@ -3768,6 +5690,9 @@ type KnowledgeBaseRetrieveAndGenerateConfiguration struct { // ModelArn is a required field ModelArn *string `locationName:"modelArn" min:"20" type:"string" required:"true"` + // Settings for how the model processes the prompt prior to retrieval and generation. + OrchestrationConfiguration *OrchestrationConfiguration `locationName:"orchestrationConfiguration" type:"structure"` + // Contains configurations for how to retrieve and return the knowledge base // query. RetrievalConfiguration *KnowledgeBaseRetrievalConfiguration `locationName:"retrievalConfiguration" type:"structure"` @@ -3808,6 +5733,11 @@ func (s *KnowledgeBaseRetrieveAndGenerateConfiguration) Validate() error { invalidParams.AddNested("GenerationConfiguration", err.(request.ErrInvalidParams)) } } + if s.OrchestrationConfiguration != nil { + if err := s.OrchestrationConfiguration.Validate(); err != nil { + invalidParams.AddNested("OrchestrationConfiguration", err.(request.ErrInvalidParams)) + } + } if s.RetrievalConfiguration != nil { if err := s.RetrievalConfiguration.Validate(); err != nil { invalidParams.AddNested("RetrievalConfiguration", err.(request.ErrInvalidParams)) @@ -3838,6 +5768,12 @@ func (s *KnowledgeBaseRetrieveAndGenerateConfiguration) SetModelArn(v string) *K return s } +// SetOrchestrationConfiguration sets the OrchestrationConfiguration field's value. +func (s *KnowledgeBaseRetrieveAndGenerateConfiguration) SetOrchestrationConfiguration(v *OrchestrationConfiguration) *KnowledgeBaseRetrieveAndGenerateConfiguration { + s.OrchestrationConfiguration = v + return s +} + // SetRetrievalConfiguration sets the RetrievalConfiguration field's value. func (s *KnowledgeBaseRetrieveAndGenerateConfiguration) SetRetrievalConfiguration(v *KnowledgeBaseRetrievalConfiguration) *KnowledgeBaseRetrieveAndGenerateConfiguration { s.RetrievalConfiguration = v @@ -3932,6 +5868,106 @@ func (s *KnowledgeBaseVectorSearchConfiguration) SetOverrideSearchType(v string) return s } +// Contains sessions summaries. +type Memory struct { + _ struct{} `type:"structure"` + + // Contains summary of a session. + SessionSummary *MemorySessionSummary `locationName:"sessionSummary" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Memory) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Memory) GoString() string { + return s.String() +} + +// SetSessionSummary sets the SessionSummary field's value. +func (s *Memory) SetSessionSummary(v *MemorySessionSummary) *Memory { + s.SessionSummary = v + return s +} + +// Contains details of a session summary. +type MemorySessionSummary struct { + _ struct{} `type:"structure"` + + // The unique identifier of the memory where the session summary is stored. + MemoryId *string `locationName:"memoryId" min:"2" type:"string"` + + // The time when the memory duration for the session is set to end. + SessionExpiryTime *time.Time `locationName:"sessionExpiryTime" type:"timestamp" timestampFormat:"iso8601"` + + // The identifier for this session. + SessionId *string `locationName:"sessionId" min:"2" type:"string"` + + // The start time for this session. + SessionStartTime *time.Time `locationName:"sessionStartTime" type:"timestamp" timestampFormat:"iso8601"` + + // The summarized text for this session. + SummaryText *string `locationName:"summaryText" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s MemorySessionSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s MemorySessionSummary) GoString() string { + return s.String() +} + +// SetMemoryId sets the MemoryId field's value. +func (s *MemorySessionSummary) SetMemoryId(v string) *MemorySessionSummary { + s.MemoryId = &v + return s +} + +// SetSessionExpiryTime sets the SessionExpiryTime field's value. +func (s *MemorySessionSummary) SetSessionExpiryTime(v time.Time) *MemorySessionSummary { + s.SessionExpiryTime = &v + return s +} + +// SetSessionId sets the SessionId field's value. +func (s *MemorySessionSummary) SetSessionId(v string) *MemorySessionSummary { + s.SessionId = &v + return s +} + +// SetSessionStartTime sets the SessionStartTime field's value. +func (s *MemorySessionSummary) SetSessionStartTime(v time.Time) *MemorySessionSummary { + s.SessionStartTime = &v + return s +} + +// SetSummaryText sets the SummaryText field's value. +func (s *MemorySessionSummary) SetSummaryText(v string) *MemorySessionSummary { + s.SummaryText = &v + return s +} + // The input for the pre-processing step. // // - The type matches the agent step. @@ -4047,6 +6083,10 @@ type Observation struct { // group. ActionGroupInvocationOutput *ActionGroupInvocationOutput_ `locationName:"actionGroupInvocationOutput" type:"structure"` + // Contains the JSON-formatted string returned by the API invoked by the code + // interpreter. + CodeInterpreterInvocationOutput *CodeInterpreterInvocationOutput_ `locationName:"codeInterpreterInvocationOutput" type:"structure"` + // Contains details about the response to the user. FinalResponse *FinalResponse `locationName:"finalResponse" type:"structure"` @@ -4102,6 +6142,12 @@ func (s *Observation) SetActionGroupInvocationOutput(v *ActionGroupInvocationOut return s } +// SetCodeInterpreterInvocationOutput sets the CodeInterpreterInvocationOutput field's value. +func (s *Observation) SetCodeInterpreterInvocationOutput(v *CodeInterpreterInvocationOutput_) *Observation { + s.CodeInterpreterInvocationOutput = v + return s +} + // SetFinalResponse sets the FinalResponse field's value. func (s *Observation) SetFinalResponse(v *FinalResponse) *Observation { s.FinalResponse = v @@ -4132,6 +6178,59 @@ func (s *Observation) SetType(v string) *Observation { return s } +// Settings for how the model processes the prompt prior to retrieval and generation. +type OrchestrationConfiguration struct { + _ struct{} `type:"structure"` + + // To split up the prompt and retrieve multiple sources, set the transformation + // type to QUERY_DECOMPOSITION. + // + // QueryTransformationConfiguration is a required field + QueryTransformationConfiguration *QueryTransformationConfiguration `locationName:"queryTransformationConfiguration" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s OrchestrationConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s OrchestrationConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *OrchestrationConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OrchestrationConfiguration"} + if s.QueryTransformationConfiguration == nil { + invalidParams.Add(request.NewErrParamRequired("QueryTransformationConfiguration")) + } + if s.QueryTransformationConfiguration != nil { + if err := s.QueryTransformationConfiguration.Validate(); err != nil { + invalidParams.AddNested("QueryTransformationConfiguration", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetQueryTransformationConfiguration sets the QueryTransformationConfiguration field's value. +func (s *OrchestrationConfiguration) SetQueryTransformationConfiguration(v *QueryTransformationConfiguration) *OrchestrationConfiguration { + s.QueryTransformationConfiguration = v + return s +} + // Details about the orchestration step, in which the agent determines the order // in which actions are executed and which knowledge bases are retrieved. type OrchestrationTrace struct { @@ -4219,6 +6318,62 @@ func (s *OrchestrationTrace) SetRationale(v *Rationale) *OrchestrationTrace { return s } +// Contains details of the response from code interpreter. +type OutputFile struct { + _ struct{} `type:"structure" sensitive:"true"` + + // The byte count of files that contains response from code interpreter. + // + // Bytes is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by OutputFile's + // String and GoString methods. + // + // Bytes is automatically base64 encoded/decoded by the SDK. + Bytes []byte `locationName:"bytes" type:"blob" sensitive:"true"` + + // The name of the file containing response from code interpreter. + Name *string `locationName:"name" type:"string"` + + // The type of file that contains response from the code interpreter. + Type *string `locationName:"type" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s OutputFile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s OutputFile) GoString() string { + return s.String() +} + +// SetBytes sets the Bytes field's value. +func (s *OutputFile) SetBytes(v []byte) *OutputFile { + s.Bytes = v + return s +} + +// SetName sets the Name field's value. +func (s *OutputFile) SetName(v string) *OutputFile { + s.Name = &v + return s +} + +// SetType sets the Type field's value. +func (s *OutputFile) SetType(v string) *OutputFile { + s.Type = &v + return s +} + // A parameter for the API request or function. type Parameter struct { _ struct{} `type:"structure"` @@ -4729,9 +6884,57 @@ func (s PropertyParameters) GoString() string { return s.String() } -// SetProperties sets the Properties field's value. -func (s *PropertyParameters) SetProperties(v []*Parameter) *PropertyParameters { - s.Properties = v +// SetProperties sets the Properties field's value. +func (s *PropertyParameters) SetProperties(v []*Parameter) *PropertyParameters { + s.Properties = v + return s +} + +// To split up the prompt and retrieve multiple sources, set the transformation +// type to QUERY_DECOMPOSITION. +type QueryTransformationConfiguration struct { + _ struct{} `type:"structure"` + + // The type of transformation to apply to the prompt. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"QueryTransformationType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s QueryTransformationConfiguration) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s QueryTransformationConfiguration) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *QueryTransformationConfiguration) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "QueryTransformationConfiguration"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetType sets the Type field's value. +func (s *QueryTransformationConfiguration) SetType(v string) *QueryTransformationConfiguration { + s.Type = &v return s } @@ -4885,6 +7088,9 @@ func (s ResourceNotFoundException) GoString() string { return s.String() } +// The ResourceNotFoundException is and event in the FlowResponseStream group of events. +func (s *ResourceNotFoundException) eventFlowResponseStream() {} + // The ResourceNotFoundException is and event in the ResponseStream group of events. func (s *ResourceNotFoundException) eventResponseStream() {} @@ -4958,6 +7164,7 @@ func (s *ResourceNotFoundException) RequestID() string { // These events are: // // - PayloadPart +// - FilePart // - ReturnControlPayload // - TracePart type ResponseStreamEvent interface { @@ -4974,6 +7181,7 @@ type ResponseStreamEvent interface { // These events are: // // - PayloadPart +// - FilePart // - ReturnControlPayload // - TracePart // - ResponseStreamUnknownEvent @@ -5074,6 +7282,8 @@ func (u unmarshalerForResponseStreamEvent) UnmarshalerForEventName(eventType str switch eventType { case "chunk": return &PayloadPart{}, nil + case "files": + return &FilePart{}, nil case "returnControl": return &ReturnControlPayload{}, nil case "trace": @@ -5220,6 +7430,38 @@ func (s *RetrievalFilter) SetOrAll(v []*RetrievalFilter) *RetrievalFilter { return s } +// The Confluence data source location. +type RetrievalResultConfluenceLocation struct { + _ struct{} `type:"structure"` + + // The Confluence host URL for the data source location. + Url *string `locationName:"url" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultConfluenceLocation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultConfluenceLocation) GoString() string { + return s.String() +} + +// SetUrl sets the Url field's value. +func (s *RetrievalResultConfluenceLocation) SetUrl(v string) *RetrievalResultConfluenceLocation { + s.Url = &v + return s +} + // Contains the cited text from the data source. // // This data type is used in the following API operations: @@ -5265,7 +7507,7 @@ func (s *RetrievalResultContent) SetText(v string) *RetrievalResultContent { return s } -// Contains information about the location of the data source. +// Contains information about the data source location. // // This data type is used in the following API operations: // @@ -5280,13 +7522,25 @@ func (s *RetrievalResultContent) SetText(v string) *RetrievalResultContent { type RetrievalResultLocation struct { _ struct{} `type:"structure" sensitive:"true"` - // Contains the S3 location of the data source. + // The Confluence data source location. + ConfluenceLocation *RetrievalResultConfluenceLocation `locationName:"confluenceLocation" type:"structure"` + + // The S3 data source location. S3Location *RetrievalResultS3Location `locationName:"s3Location" type:"structure"` - // The type of the location of the data source. + // The Salesforce data source location. + SalesforceLocation *RetrievalResultSalesforceLocation `locationName:"salesforceLocation" type:"structure"` + + // The SharePoint data source location. + SharePointLocation *RetrievalResultSharePointLocation `locationName:"sharePointLocation" type:"structure"` + + // The type of data source location. // // Type is a required field Type *string `locationName:"type" type:"string" required:"true" enum:"RetrievalResultLocationType"` + + // The web URL/URLs data source location. + WebLocation *RetrievalResultWebLocation `locationName:"webLocation" type:"structure"` } // String returns the string representation. @@ -5307,19 +7561,43 @@ func (s RetrievalResultLocation) GoString() string { return s.String() } +// SetConfluenceLocation sets the ConfluenceLocation field's value. +func (s *RetrievalResultLocation) SetConfluenceLocation(v *RetrievalResultConfluenceLocation) *RetrievalResultLocation { + s.ConfluenceLocation = v + return s +} + // SetS3Location sets the S3Location field's value. func (s *RetrievalResultLocation) SetS3Location(v *RetrievalResultS3Location) *RetrievalResultLocation { s.S3Location = v return s } +// SetSalesforceLocation sets the SalesforceLocation field's value. +func (s *RetrievalResultLocation) SetSalesforceLocation(v *RetrievalResultSalesforceLocation) *RetrievalResultLocation { + s.SalesforceLocation = v + return s +} + +// SetSharePointLocation sets the SharePointLocation field's value. +func (s *RetrievalResultLocation) SetSharePointLocation(v *RetrievalResultSharePointLocation) *RetrievalResultLocation { + s.SharePointLocation = v + return s +} + // SetType sets the Type field's value. func (s *RetrievalResultLocation) SetType(v string) *RetrievalResultLocation { s.Type = &v return s } -// Contains the S3 location of the data source. +// SetWebLocation sets the WebLocation field's value. +func (s *RetrievalResultLocation) SetWebLocation(v *RetrievalResultWebLocation) *RetrievalResultLocation { + s.WebLocation = v + return s +} + +// The S3 data source location. // // This data type is used in the following API operations: // @@ -5334,7 +7612,7 @@ func (s *RetrievalResultLocation) SetType(v string) *RetrievalResultLocation { type RetrievalResultS3Location struct { _ struct{} `type:"structure"` - // The S3 URI of the data source. + // The S3 URI for the data source location. Uri *string `locationName:"uri" type:"string"` } @@ -5362,6 +7640,102 @@ func (s *RetrievalResultS3Location) SetUri(v string) *RetrievalResultS3Location return s } +// The Salesforce data source location. +type RetrievalResultSalesforceLocation struct { + _ struct{} `type:"structure"` + + // The Salesforce host URL for the data source location. + Url *string `locationName:"url" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultSalesforceLocation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultSalesforceLocation) GoString() string { + return s.String() +} + +// SetUrl sets the Url field's value. +func (s *RetrievalResultSalesforceLocation) SetUrl(v string) *RetrievalResultSalesforceLocation { + s.Url = &v + return s +} + +// The SharePoint data source location. +type RetrievalResultSharePointLocation struct { + _ struct{} `type:"structure"` + + // The SharePoint site URL for the data source location. + Url *string `locationName:"url" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultSharePointLocation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultSharePointLocation) GoString() string { + return s.String() +} + +// SetUrl sets the Url field's value. +func (s *RetrievalResultSharePointLocation) SetUrl(v string) *RetrievalResultSharePointLocation { + s.Url = &v + return s +} + +// The web URL/URLs data source location. +type RetrievalResultWebLocation struct { + _ struct{} `type:"structure"` + + // The web URL/URLs for the data source location. + Url *string `locationName:"url" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultWebLocation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RetrievalResultWebLocation) GoString() string { + return s.String() +} + +// SetUrl sets the Url field's value. +func (s *RetrievalResultWebLocation) SetUrl(v string) *RetrievalResultWebLocation { + s.Url = &v + return s +} + // Contains details about the resource being queried. // // This data type is used in the following API operations: @@ -5462,8 +7836,11 @@ type RetrieveAndGenerateInput struct { // Contains details about the session with the knowledge base. SessionConfiguration *RetrieveAndGenerateSessionConfiguration `locationName:"sessionConfiguration" type:"structure"` - // The unique identifier of the session. Reuse the same value to continue the - // same session with the knowledge base. + // The unique identifier of the session. When you first make a RetrieveAndGenerate + // request, Amazon Bedrock automatically generates this value. You must reuse + // this value for all subsequent requests in the same conversational session. + // This value allows Amazon Bedrock to maintain context and knowledge from previous + // interactions. You can't explicitly set the sessionId yourself. SessionId *string `locationName:"sessionId" min:"2" type:"string"` } @@ -5611,8 +7988,11 @@ type RetrieveAndGenerateOutput struct { // Output is a required field Output *RetrieveAndGenerateOutput_ `locationName:"output" type:"structure" required:"true" sensitive:"true"` - // The unique identifier of the session. Reuse the same value to continue the - // same session with the knowledge base. + // The unique identifier of the session. When you first make a RetrieveAndGenerate + // request, Amazon Bedrock automatically generates this value. You must reuse + // this value for all subsequent requests in the same conversational session. + // This value allows Amazon Bedrock to maintain context and knowledge from previous + // interactions. You can't explicitly set the sessionId yourself. // // SessionId is a required field SessionId *string `locationName:"sessionId" min:"2" type:"string" required:"true"` @@ -6087,6 +8467,56 @@ func (s *S3ObjectDoc) SetUri(v string) *S3ObjectDoc { return s } +// Contains details of the s3 object where the source file is located. +type S3ObjectFile struct { + _ struct{} `type:"structure"` + + // The uri of the s3 object. + // + // Uri is a required field + Uri *string `locationName:"uri" min:"1" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s S3ObjectFile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s S3ObjectFile) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *S3ObjectFile) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "S3ObjectFile"} + if s.Uri == nil { + invalidParams.Add(request.NewErrParamRequired("Uri")) + } + if s.Uri != nil && len(*s.Uri) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Uri", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetUri sets the Uri field's value. +func (s *S3ObjectFile) SetUri(v string) *S3ObjectFile { + s.Uri = &v + return s +} + // The number of requests exceeds the service quota. Resubmit your request later. type ServiceQuotaExceededException struct { _ struct{} `type:"structure"` @@ -6113,6 +8543,9 @@ func (s ServiceQuotaExceededException) GoString() string { return s.String() } +// The ServiceQuotaExceededException is and event in the FlowResponseStream group of events. +func (s *ServiceQuotaExceededException) eventFlowResponseStream() {} + // The ServiceQuotaExceededException is and event in the ResponseStream group of events. func (s *ServiceQuotaExceededException) eventResponseStream() {} @@ -6190,6 +8623,9 @@ func (s *ServiceQuotaExceededException) RequestID() string { type SessionState struct { _ struct{} `type:"structure"` + // Contains information about the files used by code interpreter. + Files []*InputFile `locationName:"files" type:"list"` + // The identifier of the invocation of an action. This value must match the // invocationId returned in the InvokeAgent response for the action whose results // are provided in the returnControlInvocationResults field. For more information, @@ -6197,6 +8633,10 @@ type SessionState struct { // and Control session context (https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html). InvocationId *string `locationName:"invocationId" type:"string"` + // An array of configurations, each of which applies to a knowledge base attached + // to the agent. + KnowledgeBaseConfigurations []*KnowledgeBaseConfiguration `locationName:"knowledgeBaseConfigurations" min:"1" type:"list"` + // Contains attributes that persist across a prompt and the values of those // attributes. These attributes replace the $prompt_session_attributes$ placeholder // variable in the orchestration prompt template. For more information, see @@ -6236,9 +8676,32 @@ func (s SessionState) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *SessionState) Validate() error { invalidParams := request.ErrInvalidParams{Context: "SessionState"} + if s.KnowledgeBaseConfigurations != nil && len(s.KnowledgeBaseConfigurations) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KnowledgeBaseConfigurations", 1)) + } if s.ReturnControlInvocationResults != nil && len(s.ReturnControlInvocationResults) < 1 { invalidParams.Add(request.NewErrParamMinLen("ReturnControlInvocationResults", 1)) } + if s.Files != nil { + for i, v := range s.Files { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Files", i), err.(request.ErrInvalidParams)) + } + } + } + if s.KnowledgeBaseConfigurations != nil { + for i, v := range s.KnowledgeBaseConfigurations { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "KnowledgeBaseConfigurations", i), err.(request.ErrInvalidParams)) + } + } + } if s.ReturnControlInvocationResults != nil { for i, v := range s.ReturnControlInvocationResults { if v == nil { @@ -6256,12 +8719,24 @@ func (s *SessionState) Validate() error { return nil } +// SetFiles sets the Files field's value. +func (s *SessionState) SetFiles(v []*InputFile) *SessionState { + s.Files = v + return s +} + // SetInvocationId sets the InvocationId field's value. func (s *SessionState) SetInvocationId(v string) *SessionState { s.InvocationId = &v return s } +// SetKnowledgeBaseConfigurations sets the KnowledgeBaseConfigurations field's value. +func (s *SessionState) SetKnowledgeBaseConfigurations(v []*KnowledgeBaseConfiguration) *SessionState { + s.KnowledgeBaseConfigurations = v + return s +} + // SetPromptSessionAttributes sets the PromptSessionAttributes field's value. func (s *SessionState) SetPromptSessionAttributes(v map[string]*string) *SessionState { s.PromptSessionAttributes = v @@ -6484,6 +8959,9 @@ func (s ThrottlingException) GoString() string { return s.String() } +// The ThrottlingException is and event in the FlowResponseStream group of events. +func (s *ThrottlingException) eventFlowResponseStream() {} + // The ThrottlingException is and event in the ResponseStream group of events. func (s *ThrottlingException) eventResponseStream() {} @@ -6778,6 +9256,9 @@ func (s ValidationException) GoString() string { return s.String() } +// The ValidationException is and event in the FlowResponseStream group of events. +func (s *ValidationException) eventFlowResponseStream() {} + // The ValidationException is and event in the ResponseStream group of events. func (s *ValidationException) eventResponseStream() {} @@ -6861,6 +9342,22 @@ func CreationMode_Values() []string { } } +const ( + // ExecutionTypeLambda is a ExecutionType enum value + ExecutionTypeLambda = "LAMBDA" + + // ExecutionTypeReturnControl is a ExecutionType enum value + ExecutionTypeReturnControl = "RETURN_CONTROL" +) + +// ExecutionType_Values returns all elements of the ExecutionType enum +func ExecutionType_Values() []string { + return []string{ + ExecutionTypeLambda, + ExecutionTypeReturnControl, + } +} + const ( // ExternalSourceTypeS3 is a ExternalSourceType enum value ExternalSourceTypeS3 = "S3" @@ -6877,6 +9374,50 @@ func ExternalSourceType_Values() []string { } } +const ( + // FileSourceTypeS3 is a FileSourceType enum value + FileSourceTypeS3 = "S3" + + // FileSourceTypeByteContent is a FileSourceType enum value + FileSourceTypeByteContent = "BYTE_CONTENT" +) + +// FileSourceType_Values returns all elements of the FileSourceType enum +func FileSourceType_Values() []string { + return []string{ + FileSourceTypeS3, + FileSourceTypeByteContent, + } +} + +const ( + // FileUseCaseCodeInterpreter is a FileUseCase enum value + FileUseCaseCodeInterpreter = "CODE_INTERPRETER" + + // FileUseCaseChat is a FileUseCase enum value + FileUseCaseChat = "CHAT" +) + +// FileUseCase_Values returns all elements of the FileUseCase enum +func FileUseCase_Values() []string { + return []string{ + FileUseCaseCodeInterpreter, + FileUseCaseChat, + } +} + +const ( + // FlowCompletionReasonSuccess is a FlowCompletionReason enum value + FlowCompletionReasonSuccess = "SUCCESS" +) + +// FlowCompletionReason_Values returns all elements of the FlowCompletionReason enum +func FlowCompletionReason_Values() []string { + return []string{ + FlowCompletionReasonSuccess, + } +} + const ( // GuadrailActionIntervened is a GuadrailAction enum value GuadrailActionIntervened = "INTERVENED" @@ -7182,6 +9723,9 @@ const ( // InvocationTypeFinish is a InvocationType enum value InvocationTypeFinish = "FINISH" + + // InvocationTypeActionGroupCodeInterpreter is a InvocationType enum value + InvocationTypeActionGroupCodeInterpreter = "ACTION_GROUP_CODE_INTERPRETER" ) // InvocationType_Values returns all elements of the InvocationType enum @@ -7190,6 +9734,55 @@ func InvocationType_Values() []string { InvocationTypeActionGroup, InvocationTypeKnowledgeBase, InvocationTypeFinish, + InvocationTypeActionGroupCodeInterpreter, + } +} + +const ( + // MemoryTypeSessionSummary is a MemoryType enum value + MemoryTypeSessionSummary = "SESSION_SUMMARY" +) + +// MemoryType_Values returns all elements of the MemoryType enum +func MemoryType_Values() []string { + return []string{ + MemoryTypeSessionSummary, + } +} + +const ( + // NodeTypeFlowInputNode is a NodeType enum value + NodeTypeFlowInputNode = "FlowInputNode" + + // NodeTypeFlowOutputNode is a NodeType enum value + NodeTypeFlowOutputNode = "FlowOutputNode" + + // NodeTypeLambdaFunctionNode is a NodeType enum value + NodeTypeLambdaFunctionNode = "LambdaFunctionNode" + + // NodeTypeKnowledgeBaseNode is a NodeType enum value + NodeTypeKnowledgeBaseNode = "KnowledgeBaseNode" + + // NodeTypePromptNode is a NodeType enum value + NodeTypePromptNode = "PromptNode" + + // NodeTypeConditionNode is a NodeType enum value + NodeTypeConditionNode = "ConditionNode" + + // NodeTypeLexNode is a NodeType enum value + NodeTypeLexNode = "LexNode" +) + +// NodeType_Values returns all elements of the NodeType enum +func NodeType_Values() []string { + return []string{ + NodeTypeFlowInputNode, + NodeTypeFlowOutputNode, + NodeTypeLambdaFunctionNode, + NodeTypeKnowledgeBaseNode, + NodeTypePromptNode, + NodeTypeConditionNode, + NodeTypeLexNode, } } @@ -7217,6 +9810,18 @@ func PromptType_Values() []string { } } +const ( + // QueryTransformationTypeQueryDecomposition is a QueryTransformationType enum value + QueryTransformationTypeQueryDecomposition = "QUERY_DECOMPOSITION" +) + +// QueryTransformationType_Values returns all elements of the QueryTransformationType enum +func QueryTransformationType_Values() []string { + return []string{ + QueryTransformationTypeQueryDecomposition, + } +} + const ( // ResponseStateFailure is a ResponseState enum value ResponseStateFailure = "FAILURE" @@ -7236,12 +9841,28 @@ func ResponseState_Values() []string { const ( // RetrievalResultLocationTypeS3 is a RetrievalResultLocationType enum value RetrievalResultLocationTypeS3 = "S3" + + // RetrievalResultLocationTypeWeb is a RetrievalResultLocationType enum value + RetrievalResultLocationTypeWeb = "WEB" + + // RetrievalResultLocationTypeConfluence is a RetrievalResultLocationType enum value + RetrievalResultLocationTypeConfluence = "CONFLUENCE" + + // RetrievalResultLocationTypeSalesforce is a RetrievalResultLocationType enum value + RetrievalResultLocationTypeSalesforce = "SALESFORCE" + + // RetrievalResultLocationTypeSharepoint is a RetrievalResultLocationType enum value + RetrievalResultLocationTypeSharepoint = "SHAREPOINT" ) // RetrievalResultLocationType_Values returns all elements of the RetrievalResultLocationType enum func RetrievalResultLocationType_Values() []string { return []string{ RetrievalResultLocationTypeS3, + RetrievalResultLocationTypeWeb, + RetrievalResultLocationTypeConfluence, + RetrievalResultLocationTypeSalesforce, + RetrievalResultLocationTypeSharepoint, } } diff --git a/service/bedrockagentruntime/bedrockagentruntimeiface/interface.go b/service/bedrockagentruntime/bedrockagentruntimeiface/interface.go index e224cf10c28..e79f203c5b5 100644 --- a/service/bedrockagentruntime/bedrockagentruntimeiface/interface.go +++ b/service/bedrockagentruntime/bedrockagentruntimeiface/interface.go @@ -26,7 +26,7 @@ import ( // // myFunc uses an SDK service client to make a request to // // Agents for Amazon Bedrock Runtime. // func myFunc(svc bedrockagentruntimeiface.BedrockAgentRuntimeAPI) bool { -// // Make svc.InvokeAgent request +// // Make svc.DeleteAgentMemory request // } // // func main() { @@ -42,7 +42,7 @@ import ( // type mockBedrockAgentRuntimeClient struct { // bedrockagentruntimeiface.BedrockAgentRuntimeAPI // } -// func (m *mockBedrockAgentRuntimeClient) InvokeAgent(input *bedrockagentruntime.InvokeAgentInput) (*bedrockagentruntime.InvokeAgentOutput, error) { +// func (m *mockBedrockAgentRuntimeClient) DeleteAgentMemory(input *bedrockagentruntime.DeleteAgentMemoryInput) (*bedrockagentruntime.DeleteAgentMemoryOutput, error) { // // mock response/functionality // } // @@ -60,10 +60,25 @@ import ( // and waiters. Its suggested to use the pattern above for testing, or using // tooling to generate mocks to satisfy the interfaces. type BedrockAgentRuntimeAPI interface { + DeleteAgentMemory(*bedrockagentruntime.DeleteAgentMemoryInput) (*bedrockagentruntime.DeleteAgentMemoryOutput, error) + DeleteAgentMemoryWithContext(aws.Context, *bedrockagentruntime.DeleteAgentMemoryInput, ...request.Option) (*bedrockagentruntime.DeleteAgentMemoryOutput, error) + DeleteAgentMemoryRequest(*bedrockagentruntime.DeleteAgentMemoryInput) (*request.Request, *bedrockagentruntime.DeleteAgentMemoryOutput) + + GetAgentMemory(*bedrockagentruntime.GetAgentMemoryInput) (*bedrockagentruntime.GetAgentMemoryOutput, error) + GetAgentMemoryWithContext(aws.Context, *bedrockagentruntime.GetAgentMemoryInput, ...request.Option) (*bedrockagentruntime.GetAgentMemoryOutput, error) + GetAgentMemoryRequest(*bedrockagentruntime.GetAgentMemoryInput) (*request.Request, *bedrockagentruntime.GetAgentMemoryOutput) + + GetAgentMemoryPages(*bedrockagentruntime.GetAgentMemoryInput, func(*bedrockagentruntime.GetAgentMemoryOutput, bool) bool) error + GetAgentMemoryPagesWithContext(aws.Context, *bedrockagentruntime.GetAgentMemoryInput, func(*bedrockagentruntime.GetAgentMemoryOutput, bool) bool, ...request.Option) error + InvokeAgent(*bedrockagentruntime.InvokeAgentInput) (*bedrockagentruntime.InvokeAgentOutput, error) InvokeAgentWithContext(aws.Context, *bedrockagentruntime.InvokeAgentInput, ...request.Option) (*bedrockagentruntime.InvokeAgentOutput, error) InvokeAgentRequest(*bedrockagentruntime.InvokeAgentInput) (*request.Request, *bedrockagentruntime.InvokeAgentOutput) + InvokeFlow(*bedrockagentruntime.InvokeFlowInput) (*bedrockagentruntime.InvokeFlowOutput, error) + InvokeFlowWithContext(aws.Context, *bedrockagentruntime.InvokeFlowInput, ...request.Option) (*bedrockagentruntime.InvokeFlowOutput, error) + InvokeFlowRequest(*bedrockagentruntime.InvokeFlowInput) (*request.Request, *bedrockagentruntime.InvokeFlowOutput) + Retrieve(*bedrockagentruntime.RetrieveInput) (*bedrockagentruntime.RetrieveOutput, error) RetrieveWithContext(aws.Context, *bedrockagentruntime.RetrieveInput, ...request.Option) (*bedrockagentruntime.RetrieveOutput, error) RetrieveRequest(*bedrockagentruntime.RetrieveInput) (*request.Request, *bedrockagentruntime.RetrieveOutput) diff --git a/service/bedrockagentruntime/eventstream_test.go b/service/bedrockagentruntime/eventstream_test.go index 12527f9bd71..b61c97c511c 100644 --- a/service/bedrockagentruntime/eventstream_test.go +++ b/service/bedrockagentruntime/eventstream_test.go @@ -242,10 +242,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -253,10 +265,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -264,10 +288,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, }, @@ -288,10 +324,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -299,10 +347,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -310,10 +370,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, }, @@ -334,10 +406,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -345,10 +429,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -356,10 +452,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, }, @@ -368,6 +476,25 @@ func mockInvokeAgentReadEvents() ( }, Bytes: []byte("blob value goes here"), }, + &FilePart{ + Files: []*OutputFile{ + { + Bytes: []byte("blob value goes here"), + Name: aws.String("string value goes here"), + Type: aws.String("string value goes here"), + }, + { + Bytes: []byte("blob value goes here"), + Name: aws.String("string value goes here"), + Type: aws.String("string value goes here"), + }, + { + Bytes: []byte("blob value goes here"), + Name: aws.String("string value goes here"), + Type: aws.String("string value goes here"), + }, + }, + }, &ReturnControlPayload{ InvocationId: aws.String("string value goes here"), InvocationInputs: []*InvocationInputMember{ @@ -1386,7 +1513,9 @@ func mockInvokeAgentReadEvents() ( ActionGroupInvocationInput: &ActionGroupInvocationInput_{ ActionGroupName: aws.String("string value goes here"), ApiPath: aws.String("string value goes here"), + ExecutionType: aws.String("string value goes here"), Function: aws.String("string value goes here"), + InvocationId: aws.String("string value goes here"), Parameters: []*Parameter{ { Name: aws.String("string value goes here"), @@ -1461,6 +1590,14 @@ func mockInvokeAgentReadEvents() ( }, Verb: aws.String("string value goes here"), }, + CodeInterpreterInvocationInput: &CodeInterpreterInvocationInput_{ + Code: aws.String("string value goes here"), + Files: []*string{ + aws.String("string value goes here"), + aws.String("string value goes here"), + aws.String("string value goes here"), + }, + }, InvocationType: aws.String("string value goes here"), KnowledgeBaseLookupInput: &KnowledgeBaseLookupInput_{ KnowledgeBaseId: aws.String("string value goes here"), @@ -1491,6 +1628,16 @@ func mockInvokeAgentReadEvents() ( ActionGroupInvocationOutput: &ActionGroupInvocationOutput_{ Text: aws.String("string value goes here"), }, + CodeInterpreterInvocationOutput: &CodeInterpreterInvocationOutput_{ + ExecutionError: aws.String("string value goes here"), + ExecutionOutput: aws.String("string value goes here"), + ExecutionTimeout: aws.Bool(true), + Files: []*string{ + aws.String("string value goes here"), + aws.String("string value goes here"), + aws.String("string value goes here"), + }, + }, FinalResponse: &FinalResponse{ Text: aws.String("string value goes here"), }, @@ -1501,10 +1648,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -1512,10 +1671,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, { @@ -1523,10 +1694,22 @@ func mockInvokeAgentReadEvents() ( Text: aws.String("string value goes here"), }, Location: &RetrievalResultLocation{ + ConfluenceLocation: &RetrievalResultConfluenceLocation{ + Url: aws.String("string value goes here"), + }, S3Location: &RetrievalResultS3Location{ Uri: aws.String("string value goes here"), }, + SalesforceLocation: &RetrievalResultSalesforceLocation{ + Url: aws.String("string value goes here"), + }, + SharePointLocation: &RetrievalResultSharePointLocation{ + Url: aws.String("string value goes here"), + }, Type: aws.String("string value goes here"), + WebLocation: &RetrievalResultWebLocation{ + Url: aws.String("string value goes here"), + }, }, }, }, @@ -1625,7 +1808,7 @@ func mockInvokeAgentReadEvents() ( eventstreamtest.EventMessageTypeHeader, { Name: eventstreamapi.EventTypeHeader, - Value: eventstream.StringValue("returnControl"), + Value: eventstream.StringValue("files"), }, }, Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[1]), @@ -1635,11 +1818,21 @@ func mockInvokeAgentReadEvents() ( eventstreamtest.EventMessageTypeHeader, { Name: eventstreamapi.EventTypeHeader, - Value: eventstream.StringValue("trace"), + Value: eventstream.StringValue("returnControl"), }, }, Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[2]), }, + { + Headers: eventstream.Headers{ + eventstreamtest.EventMessageTypeHeader, + { + Name: eventstreamapi.EventTypeHeader, + Value: eventstream.StringValue("trace"), + }, + }, + Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[3]), + }, } return expectEvents, eventMsgs @@ -1732,6 +1925,325 @@ var _ awserr.Error = (*ServiceQuotaExceededException)(nil) var _ awserr.Error = (*ThrottlingException)(nil) var _ awserr.Error = (*ValidationException)(nil) +func TestInvokeFlow_Read(t *testing.T) { + expectEvents, eventMsgs := mockInvokeFlowReadEvents() + sess, cleanupFn, err := eventstreamtest.SetupEventStreamSession(t, + eventstreamtest.ServeEventStream{ + T: t, + Events: eventMsgs, + }, + true, + ) + if err != nil { + t.Fatalf("expect no error, %v", err) + } + defer cleanupFn() + + svc := New(sess) + resp, err := svc.InvokeFlow(nil) + if err != nil { + t.Fatalf("expect no error got, %v", err) + } + defer resp.GetStream().Close() + + var i int + for event := range resp.GetStream().Events() { + if event == nil { + t.Errorf("%d, expect event, got nil", i) + } + if e, a := expectEvents[i], event; !reflect.DeepEqual(e, a) { + t.Errorf("%d, expect %T %v, got %T %v", i, e, e, a, a) + } + i++ + } + + if err := resp.GetStream().Err(); err != nil { + t.Errorf("expect no error, %v", err) + } +} + +func TestInvokeFlow_ReadClose(t *testing.T) { + _, eventMsgs := mockInvokeFlowReadEvents() + sess, cleanupFn, err := eventstreamtest.SetupEventStreamSession(t, + eventstreamtest.ServeEventStream{ + T: t, + Events: eventMsgs, + }, + true, + ) + if err != nil { + t.Fatalf("expect no error, %v", err) + } + defer cleanupFn() + + svc := New(sess) + resp, err := svc.InvokeFlow(nil) + if err != nil { + t.Fatalf("expect no error got, %v", err) + } + + // Assert calling Err before close does not close the stream. + resp.GetStream().Err() + select { + case _, ok := <-resp.GetStream().Events(): + if !ok { + t.Fatalf("expect stream not to be closed, but was") + } + default: + } + + resp.GetStream().Close() + <-resp.GetStream().Events() + + if err := resp.GetStream().Err(); err != nil { + t.Errorf("expect no error, %v", err) + } +} + +func TestInvokeFlow_ReadUnknownEvent(t *testing.T) { + expectEvents, eventMsgs := mockInvokeFlowReadEvents() + var eventOffset int + + unknownEvent := eventstream.Message{ + Headers: eventstream.Headers{ + eventstreamtest.EventMessageTypeHeader, + { + Name: eventstreamapi.EventTypeHeader, + Value: eventstream.StringValue("UnknownEventName"), + }, + }, + Payload: []byte("some unknown event"), + } + + eventMsgs = append(eventMsgs[:eventOffset], + append([]eventstream.Message{unknownEvent}, eventMsgs[eventOffset:]...)...) + + expectEvents = append(expectEvents[:eventOffset], + append([]FlowResponseStreamEvent{ + &FlowResponseStreamUnknownEvent{ + Type: "UnknownEventName", + Message: unknownEvent, + }, + }, + expectEvents[eventOffset:]...)...) + + sess, cleanupFn, err := eventstreamtest.SetupEventStreamSession(t, + eventstreamtest.ServeEventStream{ + T: t, + Events: eventMsgs, + }, + true, + ) + if err != nil { + t.Fatalf("expect no error, %v", err) + } + defer cleanupFn() + + svc := New(sess) + resp, err := svc.InvokeFlow(nil) + if err != nil { + t.Fatalf("expect no error got, %v", err) + } + defer resp.GetStream().Close() + + var i int + for event := range resp.GetStream().Events() { + if event == nil { + t.Errorf("%d, expect event, got nil", i) + } + if e, a := expectEvents[i], event; !reflect.DeepEqual(e, a) { + t.Errorf("%d, expect %T %v, got %T %v", i, e, e, a, a) + } + i++ + } + + if err := resp.GetStream().Err(); err != nil { + t.Errorf("expect no error, %v", err) + } +} + +func BenchmarkInvokeFlow_Read(b *testing.B) { + _, eventMsgs := mockInvokeFlowReadEvents() + var buf bytes.Buffer + encoder := eventstream.NewEncoder(&buf) + for _, msg := range eventMsgs { + if err := encoder.Encode(msg); err != nil { + b.Fatalf("failed to encode message, %v", err) + } + } + stream := &loopReader{source: bytes.NewReader(buf.Bytes())} + + sess := unit.Session + svc := New(sess, &aws.Config{ + Endpoint: aws.String("https://example.com"), + DisableParamValidation: aws.Bool(true), + }) + svc.Handlers.Send.Swap(corehandlers.SendHandler.Name, + request.NamedHandler{Name: "mockSend", + Fn: func(r *request.Request) { + r.HTTPResponse = &http.Response{ + Status: "200 OK", + StatusCode: 200, + Header: http.Header{}, + Body: ioutil.NopCloser(stream), + } + }, + }, + ) + + resp, err := svc.InvokeFlow(nil) + if err != nil { + b.Fatalf("failed to create request, %v", err) + } + defer resp.GetStream().Close() + b.ResetTimer() + + for i := 0; i < b.N; i++ { + if err = resp.GetStream().Err(); err != nil { + b.Fatalf("expect no error, got %v", err) + } + event := <-resp.GetStream().Events() + if event == nil { + b.Fatalf("expect event, got nil, %v, %d", resp.GetStream().Err(), i) + } + } +} + +func mockInvokeFlowReadEvents() ( + []FlowResponseStreamEvent, + []eventstream.Message, +) { + expectEvents := []FlowResponseStreamEvent{ + &FlowCompletionEvent{ + CompletionReason: aws.String("string value goes here"), + }, + &FlowOutputEvent{ + Content: &FlowOutputContent{}, + NodeName: aws.String("string value goes here"), + NodeType: aws.String("string value goes here"), + }, + } + + var marshalers request.HandlerList + marshalers.PushBackNamed(restjson.BuildHandler) + payloadMarshaler := protocol.HandlerPayloadMarshal{ + Marshalers: marshalers, + } + _ = payloadMarshaler + + eventMsgs := []eventstream.Message{ + { + Headers: eventstream.Headers{ + eventstreamtest.EventMessageTypeHeader, + { + Name: eventstreamapi.EventTypeHeader, + Value: eventstream.StringValue("flowCompletionEvent"), + }, + }, + Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[0]), + }, + { + Headers: eventstream.Headers{ + eventstreamtest.EventMessageTypeHeader, + { + Name: eventstreamapi.EventTypeHeader, + Value: eventstream.StringValue("flowOutputEvent"), + }, + }, + Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[1]), + }, + } + + return expectEvents, eventMsgs +} +func TestInvokeFlow_ReadException(t *testing.T) { + expectEvents := []FlowResponseStreamEvent{ + &AccessDeniedException{ + RespMetadata: protocol.ResponseMetadata{ + StatusCode: 200, + }, + Message_: aws.String("string value goes here"), + }, + } + + var marshalers request.HandlerList + marshalers.PushBackNamed(restjson.BuildHandler) + payloadMarshaler := protocol.HandlerPayloadMarshal{ + Marshalers: marshalers, + } + + eventMsgs := []eventstream.Message{ + { + Headers: eventstream.Headers{ + eventstreamtest.EventExceptionTypeHeader, + { + Name: eventstreamapi.ExceptionTypeHeader, + Value: eventstream.StringValue("accessDeniedException"), + }, + }, + Payload: eventstreamtest.MarshalEventPayload(payloadMarshaler, expectEvents[0]), + }, + } + + sess, cleanupFn, err := eventstreamtest.SetupEventStreamSession(t, + eventstreamtest.ServeEventStream{ + T: t, + Events: eventMsgs, + }, + true, + ) + if err != nil { + t.Fatalf("expect no error, %v", err) + } + defer cleanupFn() + + svc := New(sess) + resp, err := svc.InvokeFlow(nil) + if err != nil { + t.Fatalf("expect no error got, %v", err) + } + + defer resp.GetStream().Close() + + <-resp.GetStream().Events() + + err = resp.GetStream().Err() + if err == nil { + t.Fatalf("expect err, got none") + } + + expectErr := &AccessDeniedException{ + RespMetadata: protocol.ResponseMetadata{ + StatusCode: 200, + }, + Message_: aws.String("string value goes here"), + } + aerr, ok := err.(awserr.Error) + if !ok { + t.Errorf("expect exception, got %T, %#v", err, err) + } + if e, a := expectErr.Code(), aerr.Code(); e != a { + t.Errorf("expect %v, got %v", e, a) + } + if e, a := expectErr.Message(), aerr.Message(); e != a { + t.Errorf("expect %v, got %v", e, a) + } + + if e, a := expectErr, aerr; !reflect.DeepEqual(e, a) { + t.Errorf("expect error %+#v, got %+#v", e, a) + } +} + +var _ awserr.Error = (*AccessDeniedException)(nil) +var _ awserr.Error = (*BadGatewayException)(nil) +var _ awserr.Error = (*ConflictException)(nil) +var _ awserr.Error = (*DependencyFailedException)(nil) +var _ awserr.Error = (*InternalServerException)(nil) +var _ awserr.Error = (*ResourceNotFoundException)(nil) +var _ awserr.Error = (*ServiceQuotaExceededException)(nil) +var _ awserr.Error = (*ThrottlingException)(nil) +var _ awserr.Error = (*ValidationException)(nil) + type loopReader struct { source *bytes.Reader } diff --git a/service/bedrockruntime/api.go b/service/bedrockruntime/api.go index 496499e52aa..c408d4567eb 100644 --- a/service/bedrockruntime/api.go +++ b/service/bedrockruntime/api.go @@ -21,6 +21,101 @@ import ( "github.com/aws/aws-sdk-go/private/protocol/restjson" ) +const opApplyGuardrail = "ApplyGuardrail" + +// ApplyGuardrailRequest generates a "aws/request.Request" representing the +// client's request for the ApplyGuardrail operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ApplyGuardrail for more information on using the ApplyGuardrail +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ApplyGuardrailRequest method. +// req, resp := client.ApplyGuardrailRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/ApplyGuardrail +func (c *BedrockRuntime) ApplyGuardrailRequest(input *ApplyGuardrailInput) (req *request.Request, output *ApplyGuardrailOutput) { + op := &request.Operation{ + Name: opApplyGuardrail, + HTTPMethod: "POST", + HTTPPath: "/guardrail/{guardrailIdentifier}/version/{guardrailVersion}/apply", + } + + if input == nil { + input = &ApplyGuardrailInput{} + } + + output = &ApplyGuardrailOutput{} + req = c.newRequest(op, input, output) + return +} + +// ApplyGuardrail API operation for Amazon Bedrock Runtime. +// +// The action to apply a guardrail. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Bedrock Runtime's +// API operation ApplyGuardrail for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The request is denied because of missing access permissions. +// +// - ResourceNotFoundException +// The specified resource ARN was not found. Check the ARN and try your request +// again. +// +// - ThrottlingException +// The number of requests exceeds the limit. Resubmit your request later. +// +// - InternalServerException +// An internal server error occurred. Retry your request. +// +// - ValidationException +// Input validation failed. Check your request parameters and retry the request. +// +// - ServiceQuotaExceededException +// The number of requests exceeds the service quota. Resubmit your request later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/ApplyGuardrail +func (c *BedrockRuntime) ApplyGuardrail(input *ApplyGuardrailInput) (*ApplyGuardrailOutput, error) { + req, out := c.ApplyGuardrailRequest(input) + return out, req.Send() +} + +// ApplyGuardrailWithContext is the same as ApplyGuardrail with the addition of +// the ability to pass a context and additional request options. +// +// See ApplyGuardrail for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *BedrockRuntime) ApplyGuardrailWithContext(ctx aws.Context, input *ApplyGuardrailInput, opts ...request.Option) (*ApplyGuardrailOutput, error) { + req, out := c.ApplyGuardrailRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opConverse = "Converse" // ConverseRequest generates a "aws/request.Request" representing the @@ -894,6 +989,176 @@ func (s AnyToolChoice) GoString() string { return s.String() } +type ApplyGuardrailInput struct { + _ struct{} `type:"structure"` + + // The content details used in the request to apply the guardrail. + // + // Content is a required field + Content []*GuardrailContentBlock `locationName:"content" type:"list" required:"true"` + + // The guardrail identifier used in the request to apply the guardrail. + // + // GuardrailIdentifier is a required field + GuardrailIdentifier *string `location:"uri" locationName:"guardrailIdentifier" type:"string" required:"true"` + + // The guardrail version used in the request to apply the guardrail. + // + // GuardrailVersion is a required field + GuardrailVersion *string `location:"uri" locationName:"guardrailVersion" type:"string" required:"true"` + + // The source of data used in the request to apply the guardrail. + // + // Source is a required field + Source *string `locationName:"source" type:"string" required:"true" enum:"GuardrailContentSource"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ApplyGuardrailInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ApplyGuardrailInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ApplyGuardrailInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ApplyGuardrailInput"} + if s.Content == nil { + invalidParams.Add(request.NewErrParamRequired("Content")) + } + if s.GuardrailIdentifier == nil { + invalidParams.Add(request.NewErrParamRequired("GuardrailIdentifier")) + } + if s.GuardrailIdentifier != nil && len(*s.GuardrailIdentifier) < 1 { + invalidParams.Add(request.NewErrParamMinLen("GuardrailIdentifier", 1)) + } + if s.GuardrailVersion == nil { + invalidParams.Add(request.NewErrParamRequired("GuardrailVersion")) + } + if s.GuardrailVersion != nil && len(*s.GuardrailVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("GuardrailVersion", 1)) + } + if s.Source == nil { + invalidParams.Add(request.NewErrParamRequired("Source")) + } + if s.Content != nil { + for i, v := range s.Content { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Content", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContent sets the Content field's value. +func (s *ApplyGuardrailInput) SetContent(v []*GuardrailContentBlock) *ApplyGuardrailInput { + s.Content = v + return s +} + +// SetGuardrailIdentifier sets the GuardrailIdentifier field's value. +func (s *ApplyGuardrailInput) SetGuardrailIdentifier(v string) *ApplyGuardrailInput { + s.GuardrailIdentifier = &v + return s +} + +// SetGuardrailVersion sets the GuardrailVersion field's value. +func (s *ApplyGuardrailInput) SetGuardrailVersion(v string) *ApplyGuardrailInput { + s.GuardrailVersion = &v + return s +} + +// SetSource sets the Source field's value. +func (s *ApplyGuardrailInput) SetSource(v string) *ApplyGuardrailInput { + s.Source = &v + return s +} + +type ApplyGuardrailOutput struct { + _ struct{} `type:"structure"` + + // The action taken in the response from the guardrail. + // + // Action is a required field + Action *string `locationName:"action" type:"string" required:"true" enum:"GuardrailAction"` + + // The assessment details in the response from the guardrail. + // + // Assessments is a required field + Assessments []*GuardrailAssessment `locationName:"assessments" type:"list" required:"true"` + + // The output details in the response from the guardrail. + // + // Outputs is a required field + Outputs []*GuardrailOutputContent `locationName:"outputs" type:"list" required:"true"` + + // The usage details in the response from the guardrail. + // + // Usage is a required field + Usage *GuardrailUsage `locationName:"usage" type:"structure" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ApplyGuardrailOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ApplyGuardrailOutput) GoString() string { + return s.String() +} + +// SetAction sets the Action field's value. +func (s *ApplyGuardrailOutput) SetAction(v string) *ApplyGuardrailOutput { + s.Action = &v + return s +} + +// SetAssessments sets the Assessments field's value. +func (s *ApplyGuardrailOutput) SetAssessments(v []*GuardrailAssessment) *ApplyGuardrailOutput { + s.Assessments = v + return s +} + +// SetOutputs sets the Outputs field's value. +func (s *ApplyGuardrailOutput) SetOutputs(v []*GuardrailOutputContent) *ApplyGuardrailOutput { + s.Outputs = v + return s +} + +// SetUsage sets the Usage field's value. +func (s *ApplyGuardrailOutput) SetUsage(v *GuardrailUsage) *ApplyGuardrailOutput { + s.Usage = v + return s +} + // The Model automatically decides if a tool should be called or whether to // generate text instead. For example, {"auto" : {}}. type AutoToolChoice struct { @@ -919,7 +1184,9 @@ func (s AutoToolChoice) GoString() string { } // A block of content for a message that you pass to, or receive from, a model -// with the Converse API (Converse and ConverseStream). +// with the Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) +// or ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) +// API operations. type ContentBlock struct { _ struct{} `type:"structure"` @@ -1809,8 +2076,8 @@ type ConverseStreamMetadataEvent struct { // Metrics is a required field Metrics *ConverseStreamMetrics `locationName:"metrics" type:"structure" required:"true"` - // The trace object in the response from ConverseStream that contains information - // about the guardrail behavior. + // The trace object in the response from ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) + // that contains information about the guardrail behavior. Trace *ConverseStreamTrace `locationName:"trace" type:"structure"` // Usage information for the conversation stream event. @@ -2127,8 +2394,8 @@ func (e *ConverseStreamOutput_UnknownEvent) UnmarshalEvent( return nil } -// The trace object in a response from ConverseStream. Currently, you can only -// trace guardrails. +// The trace object in a response from ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html). +// Currently, you can only trace guardrails. type ConverseStreamTrace struct { _ struct{} `type:"structure"` @@ -2160,8 +2427,8 @@ func (s *ConverseStreamTrace) SetGuardrail(v *GuardrailTraceAssessment) *Convers return s } -// The trace object in a response from Converse. Currently, you can only trace -// guardrails. +// The trace object in a response from Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html). +// Currently, you can only trace guardrails. type ConverseTrace struct { _ struct{} `type:"structure"` @@ -2193,10 +2460,7 @@ func (s *ConverseTrace) SetGuardrail(v *GuardrailTraceAssessment) *ConverseTrace return s } -// A document to include in a message when sending a Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) -// or ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) -// request. You can include up to 5 documents in a request. The maximum document -// size is 50 MB. +// A document to include in a message. type DocumentBlock struct { _ struct{} `type:"structure"` @@ -2205,7 +2469,21 @@ type DocumentBlock struct { // Format is a required field Format *string `locationName:"format" type:"string" required:"true" enum:"DocumentFormat"` - // A name for the document. + // A name for the document. The name can only contain the following characters: + // + // * Alphanumeric characters + // + // * Whitespace characters (no more than one in a row) + // + // * Hyphens + // + // * Parentheses + // + // * Square brackets + // + // This field is vulnerable to prompt injections, because the model might inadvertently + // interpret it as instructions. Therefore, we recommend that you specify a + // neutral name. // // Name is a required field Name *string `locationName:"name" min:"1" type:"string" required:"true"` @@ -2279,15 +2557,12 @@ func (s *DocumentBlock) SetSource(v *DocumentSource) *DocumentBlock { return s } -// Contains the content of the document included in a message when sending a -// Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) -// or ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) -// request or in the response. +// Contains the content of a document. type DocumentSource struct { _ struct{} `type:"structure"` - // A base64-encoded string of a UTF-8 encoded file, that is the document to - // include in the message. + // The raw bytes for the document. If you use an Amazon Web Services SDK, you + // don't need to encode the bytes in base64. // Bytes is automatically base64 encoded/decoded by the SDK. Bytes []byte `locationName:"bytes" min:"1" type:"blob"` } @@ -2337,6 +2612,9 @@ type GuardrailAssessment struct { // The content policy. ContentPolicy *GuardrailContentPolicyAssessment `locationName:"contentPolicy" type:"structure"` + // The contextual grounding policy used for the guardrail assessment. + ContextualGroundingPolicy *GuardrailContextualGroundingPolicyAssessment `locationName:"contextualGroundingPolicy" type:"structure"` + // The sensitive information policy. SensitiveInformationPolicy *GuardrailSensitiveInformationPolicyAssessment `locationName:"sensitiveInformationPolicy" type:"structure"` @@ -2371,6 +2649,12 @@ func (s *GuardrailAssessment) SetContentPolicy(v *GuardrailContentPolicyAssessme return s } +// SetContextualGroundingPolicy sets the ContextualGroundingPolicy field's value. +func (s *GuardrailAssessment) SetContextualGroundingPolicy(v *GuardrailContextualGroundingPolicyAssessment) *GuardrailAssessment { + s.ContextualGroundingPolicy = v + return s +} + // SetSensitiveInformationPolicy sets the SensitiveInformationPolicy field's value. func (s *GuardrailAssessment) SetSensitiveInformationPolicy(v *GuardrailSensitiveInformationPolicyAssessment) *GuardrailAssessment { s.SensitiveInformationPolicy = v @@ -2390,7 +2674,8 @@ func (s *GuardrailAssessment) SetWordPolicy(v *GuardrailWordPolicyAssessment) *G } // Configuration information for a guardrail that you use with the Converse -// action. +// (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) +// operation. type GuardrailConfiguration struct { _ struct{} `type:"structure"` @@ -2460,6 +2745,53 @@ func (s *GuardrailConfiguration) SetTrace(v string) *GuardrailConfiguration { return s } +// The content block to be evaluated by the guardrail. +type GuardrailContentBlock struct { + _ struct{} `type:"structure"` + + // Text within content block to be evaluated by the guardrail. + Text *GuardrailTextBlock `locationName:"text" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContentBlock) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContentBlock) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GuardrailContentBlock) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GuardrailContentBlock"} + if s.Text != nil { + if err := s.Text.Validate(); err != nil { + invalidParams.AddNested("Text", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetText sets the Text field's value. +func (s *GuardrailContentBlock) SetText(v *GuardrailTextBlock) *GuardrailContentBlock { + s.Text = v + return s +} + // The content filter for a guardrail. type GuardrailContentFilter struct { _ struct{} `type:"structure"` @@ -2550,8 +2882,109 @@ func (s *GuardrailContentPolicyAssessment) SetFilters(v []*GuardrailContentFilte return s } -// A content block for selective guarding with the Converse API (Converse and -// ConverseStream). +// The details for the guardrails contextual grounding filter. +type GuardrailContextualGroundingFilter struct { + _ struct{} `type:"structure"` + + // The action performed by the guardrails contextual grounding filter. + // + // Action is a required field + Action *string `locationName:"action" type:"string" required:"true" enum:"GuardrailContextualGroundingPolicyAction"` + + // The score generated by contextual grounding filter. + // + // Score is a required field + Score *float64 `locationName:"score" type:"double" required:"true"` + + // The threshold used by contextual grounding filter to determine whether the + // content is grounded or not. + // + // Threshold is a required field + Threshold *float64 `locationName:"threshold" type:"double" required:"true"` + + // The contextual grounding filter type. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"GuardrailContextualGroundingFilterType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilter) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingFilter) GoString() string { + return s.String() +} + +// SetAction sets the Action field's value. +func (s *GuardrailContextualGroundingFilter) SetAction(v string) *GuardrailContextualGroundingFilter { + s.Action = &v + return s +} + +// SetScore sets the Score field's value. +func (s *GuardrailContextualGroundingFilter) SetScore(v float64) *GuardrailContextualGroundingFilter { + s.Score = &v + return s +} + +// SetThreshold sets the Threshold field's value. +func (s *GuardrailContextualGroundingFilter) SetThreshold(v float64) *GuardrailContextualGroundingFilter { + s.Threshold = &v + return s +} + +// SetType sets the Type field's value. +func (s *GuardrailContextualGroundingFilter) SetType(v string) *GuardrailContextualGroundingFilter { + s.Type = &v + return s +} + +// The policy assessment details for the guardrails contextual grounding filter. +type GuardrailContextualGroundingPolicyAssessment struct { + _ struct{} `type:"structure"` + + // The filter details for the guardrails contextual grounding filter. + Filters []*GuardrailContextualGroundingFilter `locationName:"filters" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicyAssessment) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailContextualGroundingPolicyAssessment) GoString() string { + return s.String() +} + +// SetFilters sets the Filters field's value. +func (s *GuardrailContextualGroundingPolicyAssessment) SetFilters(v []*GuardrailContextualGroundingFilter) *GuardrailContextualGroundingPolicyAssessment { + s.Filters = v + return s +} + +// A content block for selective guarding with the Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) +// or ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) +// API operations. type GuardrailConverseContentBlock struct { _ struct{} `type:"structure"` @@ -2603,6 +3036,9 @@ func (s *GuardrailConverseContentBlock) SetText(v *GuardrailConverseTextBlock) * type GuardrailConverseTextBlock struct { _ struct{} `type:"structure"` + // The qualifier details for the guardrails contextual grounding filter. + Qualifiers []*string `locationName:"qualifiers" type:"list" enum:"GuardrailConverseContentQualifier"` + // The text that you want to guard. // // Text is a required field @@ -2640,6 +3076,12 @@ func (s *GuardrailConverseTextBlock) Validate() error { return nil } +// SetQualifiers sets the Qualifiers field's value. +func (s *GuardrailConverseTextBlock) SetQualifiers(v []*string) *GuardrailConverseTextBlock { + s.Qualifiers = v + return s +} + // SetText sets the Text field's value. func (s *GuardrailConverseTextBlock) SetText(v string) *GuardrailConverseTextBlock { s.Text = &v @@ -2747,6 +3189,38 @@ func (s *GuardrailManagedWord) SetType(v string) *GuardrailManagedWord { return s } +// The output content produced by the guardrail. +type GuardrailOutputContent struct { + _ struct{} `type:"structure"` + + // The specific text for the output content produced by the guardrail. + Text *string `locationName:"text" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailOutputContent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailOutputContent) GoString() string { + return s.String() +} + +// SetText sets the Text field's value. +func (s *GuardrailOutputContent) SetText(v string) *GuardrailOutputContent { + s.Text = &v + return s +} + // A Personally Identifiable Information (PII) entity configured in a guardrail. type GuardrailPiiEntityFilter struct { _ struct{} `type:"structure"` @@ -2992,6 +3466,62 @@ func (s *GuardrailStreamConfiguration) SetTrace(v string) *GuardrailStreamConfig return s } +// The text block to be evaluated by the guardrail. +type GuardrailTextBlock struct { + _ struct{} `type:"structure"` + + // The qualifiers describing the text block. + Qualifiers []*string `locationName:"qualifiers" type:"list" enum:"GuardrailContentQualifier"` + + // The input text details to be evaluated by the guardrail. + // + // Text is a required field + Text *string `locationName:"text" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailTextBlock) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailTextBlock) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GuardrailTextBlock) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GuardrailTextBlock"} + if s.Text == nil { + invalidParams.Add(request.NewErrParamRequired("Text")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetQualifiers sets the Qualifiers field's value. +func (s *GuardrailTextBlock) SetQualifiers(v []*string) *GuardrailTextBlock { + s.Qualifiers = v + return s +} + +// SetText sets the Text field's value. +func (s *GuardrailTextBlock) SetText(v string) *GuardrailTextBlock { + s.Text = &v + return s +} + // Information about a topic guardrail. type GuardrailTopic struct { _ struct{} `type:"structure"` @@ -3133,6 +3663,95 @@ func (s *GuardrailTraceAssessment) SetOutputAssessments(v map[string][]*Guardrai return s } +// The details on the use of the guardrail. +type GuardrailUsage struct { + _ struct{} `type:"structure"` + + // The content policy units processed by the guardrail. + // + // ContentPolicyUnits is a required field + ContentPolicyUnits *int64 `locationName:"contentPolicyUnits" type:"integer" required:"true"` + + // The contextual grounding policy units processed by the guardrail. + // + // ContextualGroundingPolicyUnits is a required field + ContextualGroundingPolicyUnits *int64 `locationName:"contextualGroundingPolicyUnits" type:"integer" required:"true"` + + // The sensitive information policy free units processed by the guardrail. + // + // SensitiveInformationPolicyFreeUnits is a required field + SensitiveInformationPolicyFreeUnits *int64 `locationName:"sensitiveInformationPolicyFreeUnits" type:"integer" required:"true"` + + // The sensitive information policy units processed by the guardrail. + // + // SensitiveInformationPolicyUnits is a required field + SensitiveInformationPolicyUnits *int64 `locationName:"sensitiveInformationPolicyUnits" type:"integer" required:"true"` + + // The topic policy units processed by the guardrail. + // + // TopicPolicyUnits is a required field + TopicPolicyUnits *int64 `locationName:"topicPolicyUnits" type:"integer" required:"true"` + + // The word policy units processed by the guardrail. + // + // WordPolicyUnits is a required field + WordPolicyUnits *int64 `locationName:"wordPolicyUnits" type:"integer" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailUsage) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GuardrailUsage) GoString() string { + return s.String() +} + +// SetContentPolicyUnits sets the ContentPolicyUnits field's value. +func (s *GuardrailUsage) SetContentPolicyUnits(v int64) *GuardrailUsage { + s.ContentPolicyUnits = &v + return s +} + +// SetContextualGroundingPolicyUnits sets the ContextualGroundingPolicyUnits field's value. +func (s *GuardrailUsage) SetContextualGroundingPolicyUnits(v int64) *GuardrailUsage { + s.ContextualGroundingPolicyUnits = &v + return s +} + +// SetSensitiveInformationPolicyFreeUnits sets the SensitiveInformationPolicyFreeUnits field's value. +func (s *GuardrailUsage) SetSensitiveInformationPolicyFreeUnits(v int64) *GuardrailUsage { + s.SensitiveInformationPolicyFreeUnits = &v + return s +} + +// SetSensitiveInformationPolicyUnits sets the SensitiveInformationPolicyUnits field's value. +func (s *GuardrailUsage) SetSensitiveInformationPolicyUnits(v int64) *GuardrailUsage { + s.SensitiveInformationPolicyUnits = &v + return s +} + +// SetTopicPolicyUnits sets the TopicPolicyUnits field's value. +func (s *GuardrailUsage) SetTopicPolicyUnits(v int64) *GuardrailUsage { + s.TopicPolicyUnits = &v + return s +} + +// SetWordPolicyUnits sets the WordPolicyUnits field's value. +func (s *GuardrailUsage) SetWordPolicyUnits(v int64) *GuardrailUsage { + s.WordPolicyUnits = &v + return s +} + // The word policy assessment. type GuardrailWordPolicyAssessment struct { _ struct{} `type:"structure"` @@ -3249,7 +3868,7 @@ type ImageSource struct { _ struct{} `type:"structure"` // The raw image bytes for the image. If you use an AWS SDK, you don't need - // to base64 encode the image bytes. + // to encode the image bytes in base64. // Bytes is automatically base64 encoded/decoded by the SDK. Bytes []byte `locationName:"bytes" min:"1" type:"blob"` } @@ -3867,7 +4486,18 @@ func (s *InvokeModelWithResponseStreamOutput) GetStream() *InvokeModelWithRespon type Message struct { _ struct{} `type:"structure"` - // The message content. + // The message content. Note the following restrictions: + // + // * You can include up to 20 images. Each image's size, height, and width + // must be no more than 3.75 MB, 8000 px, and 8000 px, respectively. + // + // * You can include up to five documents. Each document's size must be no + // more than 4.5 MB. + // + // * If you include a ContentBlock with a document field in the array, you + // must also include a ContentBlock with a text field. + // + // * You can only include images and documents if the role is user. // // Content is a required field Content []*ContentBlock `locationName:"content" type:"list" required:"true"` @@ -4805,8 +5435,9 @@ func (s *SpecificToolChoice) SetName(v string) *SpecificToolChoice { type SystemContentBlock struct { _ struct{} `type:"structure"` - // A content block to assess with the guardrail. Use with the Converse API (Converse - // and ConverseStream). + // A content block to assess with the guardrail. Use with the Converse (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html) + // or ConverseStream (https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html) + // API operations. // // For more information, see Use a guardrail with the Converse API in the Amazon // Bedrock User Guide. @@ -5016,7 +5647,9 @@ func (s *TokenUsage) SetTotalTokens(v int64) *TokenUsage { return s } -// Information about a tool that you can use with the Converse API. +// Information about a tool that you can use with the Converse API. For more +// information, see Tool use (function calling) (https://docs.aws.amazon.com/bedrock/latest/userguide/tool-use.html) +// in the Amazon Bedrock User Guide. type Tool struct { _ struct{} `type:"structure"` @@ -5132,7 +5765,9 @@ func (s *ToolChoice) SetTool(v *SpecificToolChoice) *ToolChoice { return s } -// Configuration information for the tools that you pass to a model. +// Configuration information for the tools that you pass to a model. For more +// information, see Tool use (function calling) (https://docs.aws.amazon.com/bedrock/latest/userguide/tool-use.html) +// in the Amazon Bedrock User Guide. // // This field is only supported by Anthropic Claude 3, Cohere Command R, Cohere // Command R+, and Mistral Large models. @@ -5701,6 +6336,22 @@ func DocumentFormat_Values() []string { } } +const ( + // GuardrailActionNone is a GuardrailAction enum value + GuardrailActionNone = "NONE" + + // GuardrailActionGuardrailIntervened is a GuardrailAction enum value + GuardrailActionGuardrailIntervened = "GUARDRAIL_INTERVENED" +) + +// GuardrailAction_Values returns all elements of the GuardrailAction enum +func GuardrailAction_Values() []string { + return []string{ + GuardrailActionNone, + GuardrailActionGuardrailIntervened, + } +} + const ( // GuardrailContentFilterConfidenceNone is a GuardrailContentFilterConfidence enum value GuardrailContentFilterConfidenceNone = "NONE" @@ -5769,6 +6420,94 @@ func GuardrailContentPolicyAction_Values() []string { } } +const ( + // GuardrailContentQualifierGroundingSource is a GuardrailContentQualifier enum value + GuardrailContentQualifierGroundingSource = "grounding_source" + + // GuardrailContentQualifierQuery is a GuardrailContentQualifier enum value + GuardrailContentQualifierQuery = "query" + + // GuardrailContentQualifierGuardContent is a GuardrailContentQualifier enum value + GuardrailContentQualifierGuardContent = "guard_content" +) + +// GuardrailContentQualifier_Values returns all elements of the GuardrailContentQualifier enum +func GuardrailContentQualifier_Values() []string { + return []string{ + GuardrailContentQualifierGroundingSource, + GuardrailContentQualifierQuery, + GuardrailContentQualifierGuardContent, + } +} + +const ( + // GuardrailContentSourceInput is a GuardrailContentSource enum value + GuardrailContentSourceInput = "INPUT" + + // GuardrailContentSourceOutput is a GuardrailContentSource enum value + GuardrailContentSourceOutput = "OUTPUT" +) + +// GuardrailContentSource_Values returns all elements of the GuardrailContentSource enum +func GuardrailContentSource_Values() []string { + return []string{ + GuardrailContentSourceInput, + GuardrailContentSourceOutput, + } +} + +const ( + // GuardrailContextualGroundingFilterTypeGrounding is a GuardrailContextualGroundingFilterType enum value + GuardrailContextualGroundingFilterTypeGrounding = "GROUNDING" + + // GuardrailContextualGroundingFilterTypeRelevance is a GuardrailContextualGroundingFilterType enum value + GuardrailContextualGroundingFilterTypeRelevance = "RELEVANCE" +) + +// GuardrailContextualGroundingFilterType_Values returns all elements of the GuardrailContextualGroundingFilterType enum +func GuardrailContextualGroundingFilterType_Values() []string { + return []string{ + GuardrailContextualGroundingFilterTypeGrounding, + GuardrailContextualGroundingFilterTypeRelevance, + } +} + +const ( + // GuardrailContextualGroundingPolicyActionBlocked is a GuardrailContextualGroundingPolicyAction enum value + GuardrailContextualGroundingPolicyActionBlocked = "BLOCKED" + + // GuardrailContextualGroundingPolicyActionNone is a GuardrailContextualGroundingPolicyAction enum value + GuardrailContextualGroundingPolicyActionNone = "NONE" +) + +// GuardrailContextualGroundingPolicyAction_Values returns all elements of the GuardrailContextualGroundingPolicyAction enum +func GuardrailContextualGroundingPolicyAction_Values() []string { + return []string{ + GuardrailContextualGroundingPolicyActionBlocked, + GuardrailContextualGroundingPolicyActionNone, + } +} + +const ( + // GuardrailConverseContentQualifierGroundingSource is a GuardrailConverseContentQualifier enum value + GuardrailConverseContentQualifierGroundingSource = "grounding_source" + + // GuardrailConverseContentQualifierQuery is a GuardrailConverseContentQualifier enum value + GuardrailConverseContentQualifierQuery = "query" + + // GuardrailConverseContentQualifierGuardContent is a GuardrailConverseContentQualifier enum value + GuardrailConverseContentQualifierGuardContent = "guard_content" +) + +// GuardrailConverseContentQualifier_Values returns all elements of the GuardrailConverseContentQualifier enum +func GuardrailConverseContentQualifier_Values() []string { + return []string{ + GuardrailConverseContentQualifierGroundingSource, + GuardrailConverseContentQualifierQuery, + GuardrailConverseContentQualifierGuardContent, + } +} + const ( // GuardrailManagedWordTypeProfanity is a GuardrailManagedWordType enum value GuardrailManagedWordTypeProfanity = "PROFANITY" diff --git a/service/bedrockruntime/bedrockruntimeiface/interface.go b/service/bedrockruntime/bedrockruntimeiface/interface.go index 4583579101a..b4b32b9bb55 100644 --- a/service/bedrockruntime/bedrockruntimeiface/interface.go +++ b/service/bedrockruntime/bedrockruntimeiface/interface.go @@ -26,7 +26,7 @@ import ( // // myFunc uses an SDK service client to make a request to // // Amazon Bedrock Runtime. // func myFunc(svc bedrockruntimeiface.BedrockRuntimeAPI) bool { -// // Make svc.Converse request +// // Make svc.ApplyGuardrail request // } // // func main() { @@ -42,7 +42,7 @@ import ( // type mockBedrockRuntimeClient struct { // bedrockruntimeiface.BedrockRuntimeAPI // } -// func (m *mockBedrockRuntimeClient) Converse(input *bedrockruntime.ConverseInput) (*bedrockruntime.ConverseOutput, error) { +// func (m *mockBedrockRuntimeClient) ApplyGuardrail(input *bedrockruntime.ApplyGuardrailInput) (*bedrockruntime.ApplyGuardrailOutput, error) { // // mock response/functionality // } // @@ -60,6 +60,10 @@ import ( // and waiters. Its suggested to use the pattern above for testing, or using // tooling to generate mocks to satisfy the interfaces. type BedrockRuntimeAPI interface { + ApplyGuardrail(*bedrockruntime.ApplyGuardrailInput) (*bedrockruntime.ApplyGuardrailOutput, error) + ApplyGuardrailWithContext(aws.Context, *bedrockruntime.ApplyGuardrailInput, ...request.Option) (*bedrockruntime.ApplyGuardrailOutput, error) + ApplyGuardrailRequest(*bedrockruntime.ApplyGuardrailInput) (*request.Request, *bedrockruntime.ApplyGuardrailOutput) + Converse(*bedrockruntime.ConverseInput) (*bedrockruntime.ConverseOutput, error) ConverseWithContext(aws.Context, *bedrockruntime.ConverseInput, ...request.Option) (*bedrockruntime.ConverseOutput, error) ConverseRequest(*bedrockruntime.ConverseInput) (*request.Request, *bedrockruntime.ConverseOutput) diff --git a/service/bedrockruntime/eventstream_test.go b/service/bedrockruntime/eventstream_test.go index d7625162cc5..b00292c9afb 100644 --- a/service/bedrockruntime/eventstream_test.go +++ b/service/bedrockruntime/eventstream_test.go @@ -277,6 +277,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -389,6 +411,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -501,6 +545,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -621,6 +687,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -733,6 +821,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -845,6 +955,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -959,6 +1091,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -1071,6 +1225,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -1183,6 +1359,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -1297,6 +1495,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -1409,6 +1629,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { @@ -1521,6 +1763,28 @@ func mockConverseStreamReadEvents() ( }, }, }, + ContextualGroundingPolicy: &GuardrailContextualGroundingPolicyAssessment{ + Filters: []*GuardrailContextualGroundingFilter{ + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + { + Action: aws.String("string value goes here"), + Score: aws.Float64(123.45), + Threshold: aws.Float64(123.45), + Type: aws.String("string value goes here"), + }, + }, + }, SensitiveInformationPolicy: &GuardrailSensitiveInformationPolicyAssessment{ PiiEntities: []*GuardrailPiiEntityFilter{ { diff --git a/service/ec2/api.go b/service/ec2/api.go index 5d51566f953..813b1c058b7 100644 --- a/service/ec2/api.go +++ b/service/ec2/api.go @@ -73993,13 +73993,12 @@ type CreateIpamPoolInput struct { // IpamScopeId is a required field IpamScopeId *string `type:"string" required:"true"` - // In IPAM, the locale is the Amazon Web Services Region where you want to make - // an IPAM pool available for allocations. Only resources in the same Region - // as the locale of the pool can get IP address allocations from the pool. You - // can only allocate a CIDR for a VPC, for example, from an IPAM pool that shares - // a locale with the VPC’s Region. Note that once you choose a Locale for - // a pool, you cannot modify it. If you do not choose a locale, resources in - // Regions others than the IPAM's home region cannot use CIDRs from this pool. + // In IPAM, the locale is the Amazon Web Services Region or, for IPAM IPv4 pools + // in the public scope, the network border group for an Amazon Web Services + // Local Zone where you want to make an IPAM pool available for allocations + // (supported Local Zones (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail)). + // If you do not choose a locale, resources in Regions others than the IPAM's + // home region cannot use CIDRs from this pool. // // Possible values: Any Amazon Web Services Region, such as us-east-1. Locale *string `type:"string"` @@ -76894,6 +76893,13 @@ type CreatePublicIpv4PoolInput struct { // is UnauthorizedOperation. DryRun *bool `type:"boolean"` + // The Availability Zone (AZ) or Local Zone (LZ) network border group that the + // resource that the IP address is assigned to is in. Defaults to an AZ network + // border group. For more information on available Local Zones, see Local Zone + // availability (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail) + // in the Amazon EC2 User Guide. + NetworkBorderGroup *string `type:"string"` + // The key/value combination of a tag assigned to the resource. Use the tag // key in the filter name and the tag value as the filter value. For example, // to find all resources that have a tag with the key Owner and the value TeamA, @@ -76925,6 +76931,12 @@ func (s *CreatePublicIpv4PoolInput) SetDryRun(v bool) *CreatePublicIpv4PoolInput return s } +// SetNetworkBorderGroup sets the NetworkBorderGroup field's value. +func (s *CreatePublicIpv4PoolInput) SetNetworkBorderGroup(v string) *CreatePublicIpv4PoolInput { + s.NetworkBorderGroup = &v + return s +} + // SetTagSpecifications sets the TagSpecifications field's value. func (s *CreatePublicIpv4PoolInput) SetTagSpecifications(v []*TagSpecification) *CreatePublicIpv4PoolInput { s.TagSpecifications = v @@ -87407,6 +87419,13 @@ type DeletePublicIpv4PoolInput struct { // is UnauthorizedOperation. DryRun *bool `type:"boolean"` + // The Availability Zone (AZ) or Local Zone (LZ) network border group that the + // resource that the IP address is assigned to is in. Defaults to an AZ network + // border group. For more information on available Local Zones, see Local Zone + // availability (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail) + // in the Amazon EC2 User Guide. + NetworkBorderGroup *string `type:"string"` + // The ID of the public IPv4 pool you want to delete. // // PoolId is a required field @@ -87450,6 +87469,12 @@ func (s *DeletePublicIpv4PoolInput) SetDryRun(v bool) *DeletePublicIpv4PoolInput return s } +// SetNetworkBorderGroup sets the NetworkBorderGroup field's value. +func (s *DeletePublicIpv4PoolInput) SetNetworkBorderGroup(v string) *DeletePublicIpv4PoolInput { + s.NetworkBorderGroup = &v + return s +} + // SetPoolId sets the PoolId field's value. func (s *DeletePublicIpv4PoolInput) SetPoolId(v string) *DeletePublicIpv4PoolInput { s.PoolId = &v @@ -140706,8 +140731,11 @@ type IpamDiscoveredPublicAddress struct { // The resource discovery ID. IpamResourceDiscoveryId *string `locationName:"ipamResourceDiscoveryId" type:"string"` - // The network border group that the resource that the IP address is assigned - // to is in. + // The Availability Zone (AZ) or Local Zone (LZ) network border group that the + // resource that the IP address is assigned to is in. Defaults to an AZ network + // border group. For more information on available Local Zones, see Local Zone + // availability (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail) + // in the Amazon EC2 User Guide. NetworkBorderGroup *string `locationName:"networkBorderGroup" type:"string"` // The description of the network interface that IP address is assigned to. @@ -140883,6 +140911,9 @@ func (s *IpamDiscoveredPublicAddress) SetVpcId(v string) *IpamDiscoveredPublicAd type IpamDiscoveredResourceCidr struct { _ struct{} `type:"structure"` + // The Availability Zone ID. + AvailabilityZoneId *string `locationName:"availabilityZoneId" type:"string"` + // The percentage of IP address space in use. To convert the decimal to a percentage, // multiply the decimal by 100. Note the following: // @@ -140903,6 +140934,9 @@ type IpamDiscoveredResourceCidr struct { // The resource discovery ID. IpamResourceDiscoveryId *string `locationName:"ipamResourceDiscoveryId" type:"string"` + // For elastic IP addresses, this is the status of an attached network interface. + NetworkInterfaceAttachmentStatus *string `locationName:"networkInterfaceAttachmentStatus" type:"string" enum:"IpamNetworkInterfaceAttachmentStatus"` + // The resource CIDR. ResourceCidr *string `locationName:"resourceCidr" type:"string"` @@ -140946,6 +140980,12 @@ func (s IpamDiscoveredResourceCidr) GoString() string { return s.String() } +// SetAvailabilityZoneId sets the AvailabilityZoneId field's value. +func (s *IpamDiscoveredResourceCidr) SetAvailabilityZoneId(v string) *IpamDiscoveredResourceCidr { + s.AvailabilityZoneId = &v + return s +} + // SetIpUsage sets the IpUsage field's value. func (s *IpamDiscoveredResourceCidr) SetIpUsage(v float64) *IpamDiscoveredResourceCidr { s.IpUsage = &v @@ -140958,6 +140998,12 @@ func (s *IpamDiscoveredResourceCidr) SetIpamResourceDiscoveryId(v string) *IpamD return s } +// SetNetworkInterfaceAttachmentStatus sets the NetworkInterfaceAttachmentStatus field's value. +func (s *IpamDiscoveredResourceCidr) SetNetworkInterfaceAttachmentStatus(v string) *IpamDiscoveredResourceCidr { + s.NetworkInterfaceAttachmentStatus = &v + return s +} + // SetResourceCidr sets the ResourceCidr field's value. func (s *IpamDiscoveredResourceCidr) SetResourceCidr(v string) *IpamDiscoveredResourceCidr { s.ResourceCidr = &v @@ -141178,13 +141224,11 @@ type IpamPool struct { IpamScopeType *string `locationName:"ipamScopeType" type:"string" enum:"IpamScopeType"` // The locale of the IPAM pool. In IPAM, the locale is the Amazon Web Services - // Region where you want to make an IPAM pool available for allocations. Only - // resources in the same Region as the locale of the pool can get IP address - // allocations from the pool. You can only allocate a CIDR for a VPC, for example, - // from an IPAM pool that shares a locale with the VPC’s Region. Note that - // once you choose a Locale for a pool, you cannot modify it. If you choose - // an Amazon Web Services Region for locale that has not been configured as - // an operating Region for the IPAM, you'll get an error. + // Region or, for IPAM IPv4 pools in the public scope, the network border group + // for an Amazon Web Services Local Zone where you want to make an IPAM pool + // available for allocations (supported Local Zones (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail)). + // If you choose an Amazon Web Services Region for locale that has not been + // configured as an operating Region for the IPAM, you'll get an error. Locale *string `locationName:"locale" type:"string"` // The Amazon Web Services account ID of the owner of the IPAM pool. @@ -141831,6 +141875,9 @@ func (s *IpamPublicAddressTags) SetEipTags(v []*IpamPublicAddressTag) *IpamPubli type IpamResourceCidr struct { _ struct{} `type:"structure"` + // The Availability Zone ID. + AvailabilityZoneId *string `locationName:"availabilityZoneId" type:"string"` + // The compliance status of the IPAM resource. For more information on compliance // statuses, see Monitor CIDR usage by resource (https://docs.aws.amazon.com/vpc/latest/ipam/monitor-cidr-compliance-ipam.html) // in the Amazon VPC IPAM User Guide. @@ -141916,6 +141963,12 @@ func (s IpamResourceCidr) GoString() string { return s.String() } +// SetAvailabilityZoneId sets the AvailabilityZoneId field's value. +func (s *IpamResourceCidr) SetAvailabilityZoneId(v string) *IpamResourceCidr { + s.AvailabilityZoneId = &v + return s +} + // SetComplianceStatus sets the ComplianceStatus field's value. func (s *IpamResourceCidr) SetComplianceStatus(v string) *IpamResourceCidr { s.ComplianceStatus = &v @@ -163933,6 +163986,13 @@ type ProvisionPublicIpv4PoolCidrInput struct { // NetmaskLength is a required field NetmaskLength *int64 `type:"integer" required:"true"` + // The Availability Zone (AZ) or Local Zone (LZ) network border group that the + // resource that the IP address is assigned to is in. Defaults to an AZ network + // border group. For more information on available Local Zones, see Local Zone + // availability (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#byoip-zone-avail) + // in the Amazon EC2 User Guide. + NetworkBorderGroup *string `type:"string"` + // The ID of the public IPv4 pool you would like to use for this CIDR. // // PoolId is a required field @@ -163994,6 +164054,12 @@ func (s *ProvisionPublicIpv4PoolCidrInput) SetNetmaskLength(v int64) *ProvisionP return s } +// SetNetworkBorderGroup sets the NetworkBorderGroup field's value. +func (s *ProvisionPublicIpv4PoolCidrInput) SetNetworkBorderGroup(v string) *ProvisionPublicIpv4PoolCidrInput { + s.NetworkBorderGroup = &v + return s +} + // SetPoolId sets the PoolId field's value. func (s *ProvisionPublicIpv4PoolCidrInput) SetPoolId(v string) *ProvisionPublicIpv4PoolCidrInput { s.PoolId = &v @@ -197995,6 +198061,22 @@ func IpamManagementState_Values() []string { } } +const ( + // IpamNetworkInterfaceAttachmentStatusAvailable is a IpamNetworkInterfaceAttachmentStatus enum value + IpamNetworkInterfaceAttachmentStatusAvailable = "available" + + // IpamNetworkInterfaceAttachmentStatusInUse is a IpamNetworkInterfaceAttachmentStatus enum value + IpamNetworkInterfaceAttachmentStatusInUse = "in-use" +) + +// IpamNetworkInterfaceAttachmentStatus_Values returns all elements of the IpamNetworkInterfaceAttachmentStatus enum +func IpamNetworkInterfaceAttachmentStatus_Values() []string { + return []string{ + IpamNetworkInterfaceAttachmentStatusAvailable, + IpamNetworkInterfaceAttachmentStatusInUse, + } +} + const ( // IpamOverlapStatusOverlapping is a IpamOverlapStatus enum value IpamOverlapStatusOverlapping = "overlapping" diff --git a/service/glue/api.go b/service/glue/api.go index 777856bd32a..084505f523b 100644 --- a/service/glue/api.go +++ b/service/glue/api.go @@ -30296,6 +30296,82 @@ func (s *ConditionCheckFailureException) RequestID() string { return s.RespMetadata.RequestID } +// Condition expression defined in the Glue Studio data preparation recipe node. +type ConditionExpression struct { + _ struct{} `type:"structure"` + + // The condition of the condition expression. + // + // Condition is a required field + Condition *string `min:"1" type:"string" required:"true"` + + // The target column of the condition expressions. + // + // TargetColumn is a required field + TargetColumn *string `min:"1" type:"string" required:"true"` + + // The value of the condition expression. + Value *string `type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConditionExpression) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConditionExpression) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConditionExpression) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConditionExpression"} + if s.Condition == nil { + invalidParams.Add(request.NewErrParamRequired("Condition")) + } + if s.Condition != nil && len(*s.Condition) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Condition", 1)) + } + if s.TargetColumn == nil { + invalidParams.Add(request.NewErrParamRequired("TargetColumn")) + } + if s.TargetColumn != nil && len(*s.TargetColumn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("TargetColumn", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCondition sets the Condition field's value. +func (s *ConditionExpression) SetCondition(v string) *ConditionExpression { + s.Condition = &v + return s +} + +// SetTargetColumn sets the TargetColumn field's value. +func (s *ConditionExpression) SetTargetColumn(v string) *ConditionExpression { + s.TargetColumn = &v + return s +} + +// SetValue sets the Value field's value. +func (s *ConditionExpression) SetValue(v string) *ConditionExpression { + s.Value = &v + return s +} + // Specifies the values that an admin sets for each job or session parameter // configured in a Glue usage profile. type ConfigurationObject struct { @@ -64325,9 +64401,10 @@ type Recipe struct { Name *string `type:"string" required:"true"` // A reference to the DataBrew recipe used by the node. - // - // RecipeReference is a required field - RecipeReference *RecipeReference `type:"structure" required:"true"` + RecipeReference *RecipeReference `type:"structure"` + + // Transform steps used in the recipe node. + RecipeSteps []*RecipeStep `type:"list"` } // String returns the string representation. @@ -64360,14 +64437,21 @@ func (s *Recipe) Validate() error { if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } - if s.RecipeReference == nil { - invalidParams.Add(request.NewErrParamRequired("RecipeReference")) - } if s.RecipeReference != nil { if err := s.RecipeReference.Validate(); err != nil { invalidParams.AddNested("RecipeReference", err.(request.ErrInvalidParams)) } } + if s.RecipeSteps != nil { + for i, v := range s.RecipeSteps { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RecipeSteps", i), err.(request.ErrInvalidParams)) + } + } + } if invalidParams.Len() > 0 { return invalidParams @@ -64393,6 +64477,71 @@ func (s *Recipe) SetRecipeReference(v *RecipeReference) *Recipe { return s } +// SetRecipeSteps sets the RecipeSteps field's value. +func (s *Recipe) SetRecipeSteps(v []*RecipeStep) *Recipe { + s.RecipeSteps = v + return s +} + +// Actions defined in the Glue Studio data preparation recipe node. +type RecipeAction struct { + _ struct{} `type:"structure"` + + // The operation of the recipe action. + // + // Operation is a required field + Operation *string `min:"1" type:"string" required:"true"` + + // The parameters of the recipe action. + Parameters map[string]*string `type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RecipeAction) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RecipeAction) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *RecipeAction) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RecipeAction"} + if s.Operation == nil { + invalidParams.Add(request.NewErrParamRequired("Operation")) + } + if s.Operation != nil && len(*s.Operation) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Operation", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetOperation sets the Operation field's value. +func (s *RecipeAction) SetOperation(v string) *RecipeAction { + s.Operation = &v + return s +} + +// SetParameters sets the Parameters field's value. +func (s *RecipeAction) SetParameters(v map[string]*string) *RecipeAction { + s.Parameters = v + return s +} + // A reference to a Glue DataBrew recipe. type RecipeReference struct { _ struct{} `type:"structure"` @@ -64457,6 +64606,77 @@ func (s *RecipeReference) SetRecipeVersion(v string) *RecipeReference { return s } +// A recipe step used in a Glue Studio data preparation recipe node. +type RecipeStep struct { + _ struct{} `type:"structure"` + + // The transformation action of the recipe step. + // + // Action is a required field + Action *RecipeAction `type:"structure" required:"true"` + + // The condition expressions for the recipe step. + ConditionExpressions []*ConditionExpression `type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RecipeStep) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s RecipeStep) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *RecipeStep) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RecipeStep"} + if s.Action == nil { + invalidParams.Add(request.NewErrParamRequired("Action")) + } + if s.Action != nil { + if err := s.Action.Validate(); err != nil { + invalidParams.AddNested("Action", err.(request.ErrInvalidParams)) + } + } + if s.ConditionExpressions != nil { + for i, v := range s.ConditionExpressions { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ConditionExpressions", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAction sets the Action field's value. +func (s *RecipeStep) SetAction(v *RecipeAction) *RecipeStep { + s.Action = v + return s +} + +// SetConditionExpressions sets the ConditionExpressions field's value. +func (s *RecipeStep) SetConditionExpressions(v []*ConditionExpression) *RecipeStep { + s.ConditionExpressions = v + return s +} + // When crawling an Amazon S3 data source after the first crawl is complete, // specifies whether to crawl the entire dataset again or to crawl only folders // that were added since the last crawler run. For more information, see Incremental diff --git a/service/groundstation/api.go b/service/groundstation/api.go index abe0a36ddc1..7713d96c627 100644 --- a/service/groundstation/api.go +++ b/service/groundstation/api.go @@ -6685,6 +6685,14 @@ type EphemerisData struct { _ struct{} `type:"structure"` // Ephemeris data in Orbit Ephemeris Message (OEM) format. + // + // Position, velocity, and acceleration units must be represented in km, km/s, + // and km/s**2, respectively, in ephemeris data lines. Covariance matrix line + // units must be represented in km**2 if computed from two positions, km**2/s + // if computed from one position and one velocity, and km**2/s**2 if computed + // from two velocities. Consult section 7.7.2 of The Consultative Committee + // for Space Data Systems (CCSDS) Recommended Standard for Orbit Data Messages + // (https://public.ccsds.org/Pubs/502x0b3e1.pdf) for more information. Oem *OEMEphemeris `locationName:"oem" type:"structure"` // Two-line element set (TLE) ephemeris. @@ -9057,6 +9065,14 @@ func (s *MissionProfileListItem) SetRegion(v string) *MissionProfileListItem { } // Ephemeris data in Orbit Ephemeris Message (OEM) format. +// +// Position, velocity, and acceleration units must be represented in km, km/s, +// and km/s**2, respectively, in ephemeris data lines. Covariance matrix line +// units must be represented in km**2 if computed from two positions, km**2/s +// if computed from one position and one velocity, and km**2/s**2 if computed +// from two velocities. Consult section 7.7.2 of The Consultative Committee +// for Space Data Systems (CCSDS) Recommended Standard for Orbit Data Messages +// (https://public.ccsds.org/Pubs/502x0b3e1.pdf) for more information. type OEMEphemeris struct { _ struct{} `type:"structure"` diff --git a/service/licensemanagerlinuxsubscriptions/api.go b/service/licensemanagerlinuxsubscriptions/api.go index 42622813313..de01503750a 100644 --- a/service/licensemanagerlinuxsubscriptions/api.go +++ b/service/licensemanagerlinuxsubscriptions/api.go @@ -9,8 +9,188 @@ import ( "github.com/aws/aws-sdk-go/aws/awsutil" "github.com/aws/aws-sdk-go/aws/request" "github.com/aws/aws-sdk-go/private/protocol" + "github.com/aws/aws-sdk-go/private/protocol/restjson" ) +const opDeregisterSubscriptionProvider = "DeregisterSubscriptionProvider" + +// DeregisterSubscriptionProviderRequest generates a "aws/request.Request" representing the +// client's request for the DeregisterSubscriptionProvider operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeregisterSubscriptionProvider for more information on using the DeregisterSubscriptionProvider +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the DeregisterSubscriptionProviderRequest method. +// req, resp := client.DeregisterSubscriptionProviderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/DeregisterSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) DeregisterSubscriptionProviderRequest(input *DeregisterSubscriptionProviderInput) (req *request.Request, output *DeregisterSubscriptionProviderOutput) { + op := &request.Operation{ + Name: opDeregisterSubscriptionProvider, + HTTPMethod: "POST", + HTTPPath: "/subscription/DeregisterSubscriptionProvider", + } + + if input == nil { + input = &DeregisterSubscriptionProviderInput{} + } + + output = &DeregisterSubscriptionProviderOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeregisterSubscriptionProvider API operation for AWS License Manager Linux Subscriptions. +// +// Remove a third-party subscription provider from the Bring Your Own License +// (BYOL) subscriptions registered to your account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation DeregisterSubscriptionProvider for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ResourceNotFoundException +// Unable to find the requested Amazon Web Services resource. +// +// - ThrottlingException +// The request was denied due to request throttling. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/DeregisterSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) DeregisterSubscriptionProvider(input *DeregisterSubscriptionProviderInput) (*DeregisterSubscriptionProviderOutput, error) { + req, out := c.DeregisterSubscriptionProviderRequest(input) + return out, req.Send() +} + +// DeregisterSubscriptionProviderWithContext is the same as DeregisterSubscriptionProvider with the addition of +// the ability to pass a context and additional request options. +// +// See DeregisterSubscriptionProvider for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) DeregisterSubscriptionProviderWithContext(ctx aws.Context, input *DeregisterSubscriptionProviderInput, opts ...request.Option) (*DeregisterSubscriptionProviderOutput, error) { + req, out := c.DeregisterSubscriptionProviderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetRegisteredSubscriptionProvider = "GetRegisteredSubscriptionProvider" + +// GetRegisteredSubscriptionProviderRequest generates a "aws/request.Request" representing the +// client's request for the GetRegisteredSubscriptionProvider operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetRegisteredSubscriptionProvider for more information on using the GetRegisteredSubscriptionProvider +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the GetRegisteredSubscriptionProviderRequest method. +// req, resp := client.GetRegisteredSubscriptionProviderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/GetRegisteredSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) GetRegisteredSubscriptionProviderRequest(input *GetRegisteredSubscriptionProviderInput) (req *request.Request, output *GetRegisteredSubscriptionProviderOutput) { + op := &request.Operation{ + Name: opGetRegisteredSubscriptionProvider, + HTTPMethod: "POST", + HTTPPath: "/subscription/GetRegisteredSubscriptionProvider", + } + + if input == nil { + input = &GetRegisteredSubscriptionProviderInput{} + } + + output = &GetRegisteredSubscriptionProviderOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetRegisteredSubscriptionProvider API operation for AWS License Manager Linux Subscriptions. +// +// Get details for a Bring Your Own License (BYOL) subscription that's registered +// to your account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation GetRegisteredSubscriptionProvider for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ResourceNotFoundException +// Unable to find the requested Amazon Web Services resource. +// +// - ThrottlingException +// The request was denied due to request throttling. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/GetRegisteredSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) GetRegisteredSubscriptionProvider(input *GetRegisteredSubscriptionProviderInput) (*GetRegisteredSubscriptionProviderOutput, error) { + req, out := c.GetRegisteredSubscriptionProviderRequest(input) + return out, req.Send() +} + +// GetRegisteredSubscriptionProviderWithContext is the same as GetRegisteredSubscriptionProvider with the addition of +// the ability to pass a context and additional request options. +// +// See GetRegisteredSubscriptionProvider for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) GetRegisteredSubscriptionProviderWithContext(ctx aws.Context, input *GetRegisteredSubscriptionProviderInput, opts ...request.Option) (*GetRegisteredSubscriptionProviderOutput, error) { + req, out := c.GetRegisteredSubscriptionProviderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetServiceSettings = "GetServiceSettings" // GetServiceSettingsRequest generates a "aws/request.Request" representing the @@ -54,7 +234,7 @@ func (c *LicenseManagerLinuxSubscriptions) GetServiceSettingsRequest(input *GetS // GetServiceSettings API operation for AWS License Manager Linux Subscriptions. // -// Lists the Linux subscriptions service settings. +// Lists the Linux subscriptions service settings for your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -383,57 +563,64 @@ func (c *LicenseManagerLinuxSubscriptions) ListLinuxSubscriptionsPagesWithContex return p.Err() } -const opUpdateServiceSettings = "UpdateServiceSettings" +const opListRegisteredSubscriptionProviders = "ListRegisteredSubscriptionProviders" -// UpdateServiceSettingsRequest generates a "aws/request.Request" representing the -// client's request for the UpdateServiceSettings operation. The "output" return +// ListRegisteredSubscriptionProvidersRequest generates a "aws/request.Request" representing the +// client's request for the ListRegisteredSubscriptionProviders operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateServiceSettings for more information on using the UpdateServiceSettings +// See ListRegisteredSubscriptionProviders for more information on using the ListRegisteredSubscriptionProviders // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateServiceSettingsRequest method. -// req, resp := client.UpdateServiceSettingsRequest(params) +// // Example sending a request using the ListRegisteredSubscriptionProvidersRequest method. +// req, resp := client.ListRegisteredSubscriptionProvidersRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UpdateServiceSettings -func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettingsRequest(input *UpdateServiceSettingsInput) (req *request.Request, output *UpdateServiceSettingsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/ListRegisteredSubscriptionProviders +func (c *LicenseManagerLinuxSubscriptions) ListRegisteredSubscriptionProvidersRequest(input *ListRegisteredSubscriptionProvidersInput) (req *request.Request, output *ListRegisteredSubscriptionProvidersOutput) { op := &request.Operation{ - Name: opUpdateServiceSettings, + Name: opListRegisteredSubscriptionProviders, HTTPMethod: "POST", - HTTPPath: "/subscription/UpdateServiceSettings", + HTTPPath: "/subscription/ListRegisteredSubscriptionProviders", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, } if input == nil { - input = &UpdateServiceSettingsInput{} + input = &ListRegisteredSubscriptionProvidersInput{} } - output = &UpdateServiceSettingsOutput{} + output = &ListRegisteredSubscriptionProvidersOutput{} req = c.newRequest(op, input, output) return } -// UpdateServiceSettings API operation for AWS License Manager Linux Subscriptions. +// ListRegisteredSubscriptionProviders API operation for AWS License Manager Linux Subscriptions. // -// Updates the service settings for Linux subscriptions. +// List Bring Your Own License (BYOL) subscription registration resources for +// your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS License Manager Linux Subscriptions's -// API operation UpdateServiceSettings for usage and error information. +// API operation ListRegisteredSubscriptionProviders for usage and error information. // // Returned Error Types: // @@ -446,97 +633,1104 @@ func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettingsRequest(input *U // - ValidationException // The provided input is not valid. Try your request again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UpdateServiceSettings -func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettings(input *UpdateServiceSettingsInput) (*UpdateServiceSettingsOutput, error) { - req, out := c.UpdateServiceSettingsRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/ListRegisteredSubscriptionProviders +func (c *LicenseManagerLinuxSubscriptions) ListRegisteredSubscriptionProviders(input *ListRegisteredSubscriptionProvidersInput) (*ListRegisteredSubscriptionProvidersOutput, error) { + req, out := c.ListRegisteredSubscriptionProvidersRequest(input) return out, req.Send() } -// UpdateServiceSettingsWithContext is the same as UpdateServiceSettings with the addition of +// ListRegisteredSubscriptionProvidersWithContext is the same as ListRegisteredSubscriptionProviders with the addition of // the ability to pass a context and additional request options. // -// See UpdateServiceSettings for details on how to use this API operation. +// See ListRegisteredSubscriptionProviders for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettingsWithContext(ctx aws.Context, input *UpdateServiceSettingsInput, opts ...request.Option) (*UpdateServiceSettingsOutput, error) { - req, out := c.UpdateServiceSettingsRequest(input) +func (c *LicenseManagerLinuxSubscriptions) ListRegisteredSubscriptionProvidersWithContext(ctx aws.Context, input *ListRegisteredSubscriptionProvidersInput, opts ...request.Option) (*ListRegisteredSubscriptionProvidersOutput, error) { + req, out := c.ListRegisteredSubscriptionProvidersRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// A filter object that is used to return more specific results from a describe -// operation. Filters can be used to match a set of resources by specific criteria. -type Filter struct { - _ struct{} `type:"structure"` +// ListRegisteredSubscriptionProvidersPages iterates over the pages of a ListRegisteredSubscriptionProviders operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListRegisteredSubscriptionProviders method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListRegisteredSubscriptionProviders operation. +// pageNum := 0 +// err := client.ListRegisteredSubscriptionProvidersPages(params, +// func(page *licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *LicenseManagerLinuxSubscriptions) ListRegisteredSubscriptionProvidersPages(input *ListRegisteredSubscriptionProvidersInput, fn func(*ListRegisteredSubscriptionProvidersOutput, bool) bool) error { + return c.ListRegisteredSubscriptionProvidersPagesWithContext(aws.BackgroundContext(), input, fn) +} - // The type of name to filter by. - Name *string `type:"string"` +// ListRegisteredSubscriptionProvidersPagesWithContext same as ListRegisteredSubscriptionProvidersPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) ListRegisteredSubscriptionProvidersPagesWithContext(ctx aws.Context, input *ListRegisteredSubscriptionProvidersInput, fn func(*ListRegisteredSubscriptionProvidersOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListRegisteredSubscriptionProvidersInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListRegisteredSubscriptionProvidersRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } - // An operator for filtering results. - Operator *string `min:"1" type:"string" enum:"Operator"` + for p.Next() { + if !fn(p.Page().(*ListRegisteredSubscriptionProvidersOutput), !p.HasNextPage()) { + break + } + } - // One or more values for the name to filter by. - Values []*string `min:"1" type:"list"` + return p.Err() } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s Filter) String() string { - return awsutil.Prettify(s) -} +const opListTagsForResource = "ListTagsForResource" -// GoString returns the string representation. +// ListTagsForResourceRequest generates a "aws/request.Request" representing the +// client's request for the ListTagsForResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s Filter) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *Filter) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Filter"} - if s.Operator != nil && len(*s.Operator) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Operator", 1)) - } - if s.Values != nil && len(s.Values) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Values", 1)) +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListTagsForResource for more information on using the ListTagsForResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the ListTagsForResourceRequest method. +// req, resp := client.ListTagsForResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/ListTagsForResource +func (c *LicenseManagerLinuxSubscriptions) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { + op := &request.Operation{ + Name: opListTagsForResource, + HTTPMethod: "GET", + HTTPPath: "/tags/{resourceArn}", } - if invalidParams.Len() > 0 { - return invalidParams + if input == nil { + input = &ListTagsForResourceInput{} } - return nil -} -// SetName sets the Name field's value. -func (s *Filter) SetName(v string) *Filter { - s.Name = &v - return s + output = &ListTagsForResourceOutput{} + req = c.newRequest(op, input, output) + return } -// SetOperator sets the Operator field's value. -func (s *Filter) SetOperator(v string) *Filter { - s.Operator = &v - return s +// ListTagsForResource API operation for AWS License Manager Linux Subscriptions. +// +// List the metadata tags that are assigned to the specified Amazon Web Services +// resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation ListTagsForResource for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ResourceNotFoundException +// Unable to find the requested Amazon Web Services resource. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/ListTagsForResource +func (c *LicenseManagerLinuxSubscriptions) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + return out, req.Send() +} + +// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// the ability to pass a context and additional request options. +// +// See ListTagsForResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opRegisterSubscriptionProvider = "RegisterSubscriptionProvider" + +// RegisterSubscriptionProviderRequest generates a "aws/request.Request" representing the +// client's request for the RegisterSubscriptionProvider operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See RegisterSubscriptionProvider for more information on using the RegisterSubscriptionProvider +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the RegisterSubscriptionProviderRequest method. +// req, resp := client.RegisterSubscriptionProviderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/RegisterSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) RegisterSubscriptionProviderRequest(input *RegisterSubscriptionProviderInput) (req *request.Request, output *RegisterSubscriptionProviderOutput) { + op := &request.Operation{ + Name: opRegisterSubscriptionProvider, + HTTPMethod: "POST", + HTTPPath: "/subscription/RegisterSubscriptionProvider", + } + + if input == nil { + input = &RegisterSubscriptionProviderInput{} + } + + output = &RegisterSubscriptionProviderOutput{} + req = c.newRequest(op, input, output) + return +} + +// RegisterSubscriptionProvider API operation for AWS License Manager Linux Subscriptions. +// +// Register the supported third-party subscription provider for your Bring Your +// Own License (BYOL) subscription. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation RegisterSubscriptionProvider for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ThrottlingException +// The request was denied due to request throttling. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/RegisterSubscriptionProvider +func (c *LicenseManagerLinuxSubscriptions) RegisterSubscriptionProvider(input *RegisterSubscriptionProviderInput) (*RegisterSubscriptionProviderOutput, error) { + req, out := c.RegisterSubscriptionProviderRequest(input) + return out, req.Send() +} + +// RegisterSubscriptionProviderWithContext is the same as RegisterSubscriptionProvider with the addition of +// the ability to pass a context and additional request options. +// +// See RegisterSubscriptionProvider for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) RegisterSubscriptionProviderWithContext(ctx aws.Context, input *RegisterSubscriptionProviderInput, opts ...request.Option) (*RegisterSubscriptionProviderOutput, error) { + req, out := c.RegisterSubscriptionProviderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opTagResource = "TagResource" + +// TagResourceRequest generates a "aws/request.Request" representing the +// client's request for the TagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See TagResource for more information on using the TagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the TagResourceRequest method. +// req, resp := client.TagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/TagResource +func (c *LicenseManagerLinuxSubscriptions) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { + op := &request.Operation{ + Name: opTagResource, + HTTPMethod: "PUT", + HTTPPath: "/tags/{resourceArn}", + } + + if input == nil { + input = &TagResourceInput{} + } + + output = &TagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// TagResource API operation for AWS License Manager Linux Subscriptions. +// +// Add metadata tags to the specified Amazon Web Services resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation TagResource for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ResourceNotFoundException +// Unable to find the requested Amazon Web Services resource. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/TagResource +func (c *LicenseManagerLinuxSubscriptions) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + return out, req.Send() +} + +// TagResourceWithContext is the same as TagResource with the addition of +// the ability to pass a context and additional request options. +// +// See TagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUntagResource = "UntagResource" + +// UntagResourceRequest generates a "aws/request.Request" representing the +// client's request for the UntagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UntagResource for more information on using the UntagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UntagResourceRequest method. +// req, resp := client.UntagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UntagResource +func (c *LicenseManagerLinuxSubscriptions) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { + op := &request.Operation{ + Name: opUntagResource, + HTTPMethod: "DELETE", + HTTPPath: "/tags/{resourceArn}", + } + + if input == nil { + input = &UntagResourceInput{} + } + + output = &UntagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// UntagResource API operation for AWS License Manager Linux Subscriptions. +// +// Remove one or more metadata tag from the specified Amazon Web Services resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation UntagResource for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ResourceNotFoundException +// Unable to find the requested Amazon Web Services resource. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UntagResource +func (c *LicenseManagerLinuxSubscriptions) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + return out, req.Send() +} + +// UntagResourceWithContext is the same as UntagResource with the addition of +// the ability to pass a context and additional request options. +// +// See UntagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateServiceSettings = "UpdateServiceSettings" + +// UpdateServiceSettingsRequest generates a "aws/request.Request" representing the +// client's request for the UpdateServiceSettings operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateServiceSettings for more information on using the UpdateServiceSettings +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateServiceSettingsRequest method. +// req, resp := client.UpdateServiceSettingsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UpdateServiceSettings +func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettingsRequest(input *UpdateServiceSettingsInput) (req *request.Request, output *UpdateServiceSettingsOutput) { + op := &request.Operation{ + Name: opUpdateServiceSettings, + HTTPMethod: "POST", + HTTPPath: "/subscription/UpdateServiceSettings", + } + + if input == nil { + input = &UpdateServiceSettingsInput{} + } + + output = &UpdateServiceSettingsOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateServiceSettings API operation for AWS License Manager Linux Subscriptions. +// +// Updates the service settings for Linux subscriptions. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS License Manager Linux Subscriptions's +// API operation UpdateServiceSettings for usage and error information. +// +// Returned Error Types: +// +// - InternalServerException +// An exception occurred with the service. +// +// - ThrottlingException +// The request was denied due to request throttling. +// +// - ValidationException +// The provided input is not valid. Try your request again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/license-manager-linux-subscriptions-2018-05-10/UpdateServiceSettings +func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettings(input *UpdateServiceSettingsInput) (*UpdateServiceSettingsOutput, error) { + req, out := c.UpdateServiceSettingsRequest(input) + return out, req.Send() +} + +// UpdateServiceSettingsWithContext is the same as UpdateServiceSettings with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateServiceSettings for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LicenseManagerLinuxSubscriptions) UpdateServiceSettingsWithContext(ctx aws.Context, input *UpdateServiceSettingsInput, opts ...request.Option) (*UpdateServiceSettingsOutput, error) { + req, out := c.UpdateServiceSettingsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +type DeregisterSubscriptionProviderInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the subscription provider resource to deregister. + // + // SubscriptionProviderArn is a required field + SubscriptionProviderArn *string `type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeregisterSubscriptionProviderInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeregisterSubscriptionProviderInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeregisterSubscriptionProviderInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeregisterSubscriptionProviderInput"} + if s.SubscriptionProviderArn == nil { + invalidParams.Add(request.NewErrParamRequired("SubscriptionProviderArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetSubscriptionProviderArn sets the SubscriptionProviderArn field's value. +func (s *DeregisterSubscriptionProviderInput) SetSubscriptionProviderArn(v string) *DeregisterSubscriptionProviderInput { + s.SubscriptionProviderArn = &v + return s +} + +type DeregisterSubscriptionProviderOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeregisterSubscriptionProviderOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeregisterSubscriptionProviderOutput) GoString() string { + return s.String() +} + +// A filter object that is used to return more specific results from a describe +// operation. Filters can be used to match a set of resources by specific criteria. +type Filter struct { + _ struct{} `type:"structure"` + + // The type of name to filter by. + Name *string `type:"string"` + + // An operator for filtering results. + Operator *string `min:"1" type:"string" enum:"Operator"` + + // One or more values for the name to filter by. + Values []*string `min:"1" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Filter) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Filter) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Filter) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Filter"} + if s.Operator != nil && len(*s.Operator) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Operator", 1)) + } + if s.Values != nil && len(s.Values) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Values", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *Filter) SetName(v string) *Filter { + s.Name = &v + return s +} + +// SetOperator sets the Operator field's value. +func (s *Filter) SetOperator(v string) *Filter { + s.Operator = &v + return s +} + +// SetValues sets the Values field's value. +func (s *Filter) SetValues(v []*string) *Filter { + s.Values = v + return s +} + +type GetRegisteredSubscriptionProviderInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the BYOL registration resource to get details + // for. + // + // SubscriptionProviderArn is a required field + SubscriptionProviderArn *string `type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetRegisteredSubscriptionProviderInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetRegisteredSubscriptionProviderInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetRegisteredSubscriptionProviderInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetRegisteredSubscriptionProviderInput"} + if s.SubscriptionProviderArn == nil { + invalidParams.Add(request.NewErrParamRequired("SubscriptionProviderArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetSubscriptionProviderArn sets the SubscriptionProviderArn field's value. +func (s *GetRegisteredSubscriptionProviderInput) SetSubscriptionProviderArn(v string) *GetRegisteredSubscriptionProviderInput { + s.SubscriptionProviderArn = &v + return s +} + +type GetRegisteredSubscriptionProviderOutput struct { + _ struct{} `type:"structure"` + + // The timestamp from the last time License Manager retrieved subscription details + // from your registered third-party Linux subscription provider. + LastSuccessfulDataRetrievalTime *string `type:"string"` + + // The Amazon Resource Name (ARN) of the third-party access secret stored in + // Secrets Manager for the BYOL registration resource specified in the request. + SecretArn *string `type:"string"` + + // The Amazon Resource Name (ARN) for the BYOL registration resource specified + // in the request. + SubscriptionProviderArn *string `type:"string"` + + // The subscription provider for the BYOL registration resource specified in + // the request. + SubscriptionProviderSource *string `type:"string" enum:"SubscriptionProviderSource"` + + // The status of the Linux subscription provider access token from the last + // successful subscription data request. + SubscriptionProviderStatus *string `type:"string" enum:"SubscriptionProviderStatus"` + + // The detailed message from your subscription provider token status. + SubscriptionProviderStatusMessage *string `type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetRegisteredSubscriptionProviderOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetRegisteredSubscriptionProviderOutput) GoString() string { + return s.String() +} + +// SetLastSuccessfulDataRetrievalTime sets the LastSuccessfulDataRetrievalTime field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetLastSuccessfulDataRetrievalTime(v string) *GetRegisteredSubscriptionProviderOutput { + s.LastSuccessfulDataRetrievalTime = &v + return s +} + +// SetSecretArn sets the SecretArn field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetSecretArn(v string) *GetRegisteredSubscriptionProviderOutput { + s.SecretArn = &v + return s +} + +// SetSubscriptionProviderArn sets the SubscriptionProviderArn field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetSubscriptionProviderArn(v string) *GetRegisteredSubscriptionProviderOutput { + s.SubscriptionProviderArn = &v + return s +} + +// SetSubscriptionProviderSource sets the SubscriptionProviderSource field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetSubscriptionProviderSource(v string) *GetRegisteredSubscriptionProviderOutput { + s.SubscriptionProviderSource = &v + return s +} + +// SetSubscriptionProviderStatus sets the SubscriptionProviderStatus field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetSubscriptionProviderStatus(v string) *GetRegisteredSubscriptionProviderOutput { + s.SubscriptionProviderStatus = &v + return s +} + +// SetSubscriptionProviderStatusMessage sets the SubscriptionProviderStatusMessage field's value. +func (s *GetRegisteredSubscriptionProviderOutput) SetSubscriptionProviderStatusMessage(v string) *GetRegisteredSubscriptionProviderOutput { + s.SubscriptionProviderStatusMessage = &v + return s +} + +type GetServiceSettingsInput struct { + _ struct{} `type:"structure" nopayload:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetServiceSettingsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetServiceSettingsInput) GoString() string { + return s.String() +} + +type GetServiceSettingsOutput struct { + _ struct{} `type:"structure"` + + // The Region in which License Manager displays the aggregated data for Linux + // subscriptions. + HomeRegions []*string `min:"1" type:"list"` + + // Lists if discovery has been enabled for Linux subscriptions. + LinuxSubscriptionsDiscovery *string `type:"string" enum:"LinuxSubscriptionsDiscovery"` + + // Lists the settings defined for Linux subscriptions discovery. The settings + // include if Organizations integration has been enabled, and which Regions + // data will be aggregated from. + LinuxSubscriptionsDiscoverySettings *LinuxSubscriptionsDiscoverySettings `type:"structure"` + + // Indicates the status of Linux subscriptions settings being applied. + Status *string `type:"string" enum:"Status"` + + // A message which details the Linux subscriptions service settings current + // status. + StatusMessage map[string]*string `type:"map"` } -// SetValues sets the Values field's value. -func (s *Filter) SetValues(v []*string) *Filter { - s.Values = v +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetServiceSettingsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s GetServiceSettingsOutput) GoString() string { + return s.String() +} + +// SetHomeRegions sets the HomeRegions field's value. +func (s *GetServiceSettingsOutput) SetHomeRegions(v []*string) *GetServiceSettingsOutput { + s.HomeRegions = v + return s +} + +// SetLinuxSubscriptionsDiscovery sets the LinuxSubscriptionsDiscovery field's value. +func (s *GetServiceSettingsOutput) SetLinuxSubscriptionsDiscovery(v string) *GetServiceSettingsOutput { + s.LinuxSubscriptionsDiscovery = &v + return s +} + +// SetLinuxSubscriptionsDiscoverySettings sets the LinuxSubscriptionsDiscoverySettings field's value. +func (s *GetServiceSettingsOutput) SetLinuxSubscriptionsDiscoverySettings(v *LinuxSubscriptionsDiscoverySettings) *GetServiceSettingsOutput { + s.LinuxSubscriptionsDiscoverySettings = v + return s +} + +// SetStatus sets the Status field's value. +func (s *GetServiceSettingsOutput) SetStatus(v string) *GetServiceSettingsOutput { + s.Status = &v + return s +} + +// SetStatusMessage sets the StatusMessage field's value. +func (s *GetServiceSettingsOutput) SetStatusMessage(v map[string]*string) *GetServiceSettingsOutput { + s.StatusMessage = v + return s +} + +// Details discovered information about a running instance using Linux subscriptions. +type Instance struct { + _ struct{} `type:"structure"` + + // The account ID which owns the instance. + AccountID *string `type:"string"` + + // The AMI ID used to launch the instance. + AmiId *string `type:"string"` + + // Indicates that you have two different license subscriptions for the same + // software on your instance. + DualSubscription *string `type:"string"` + + // The instance ID of the resource. + InstanceID *string `type:"string"` + + // The instance type of the resource. + InstanceType *string `type:"string"` + + // The time in which the last discovery updated the instance details. + LastUpdatedTime *string `type:"string"` + + // The operating system software version that runs on your instance. + OsVersion *string `type:"string"` + + // The product code for the instance. For more information, see Usage operation + // values (https://docs.aws.amazon.com/license-manager/latest/userguide/linux-subscriptions-usage-operation.html) + // in the License Manager User Guide . + ProductCode []*string `type:"list"` + + // The Region the instance is running in. + Region *string `type:"string"` + + // Indicates that your instance uses a BYOL license subscription from a third-party + // Linux subscription provider that you've registered with License Manager. + RegisteredWithSubscriptionProvider *string `type:"string"` + + // The status of the instance. + Status *string `type:"string"` + + // The name of the license subscription that the instance uses. + SubscriptionName *string `type:"string"` + + // The timestamp when you registered the third-party Linux subscription provider + // for the subscription that the instance uses. + SubscriptionProviderCreateTime *string `type:"string"` + + // The timestamp from the last time that the instance synced with the registered + // third-party Linux subscription provider. + SubscriptionProviderUpdateTime *string `type:"string"` + + // The usage operation of the instance. For more information, see For more information, + // see Usage operation values (https://docs.aws.amazon.com/license-manager/latest/userguide/linux-subscriptions-usage-operation.html) + // in the License Manager User Guide. + UsageOperation *string `type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Instance) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s Instance) GoString() string { + return s.String() +} + +// SetAccountID sets the AccountID field's value. +func (s *Instance) SetAccountID(v string) *Instance { + s.AccountID = &v + return s +} + +// SetAmiId sets the AmiId field's value. +func (s *Instance) SetAmiId(v string) *Instance { + s.AmiId = &v + return s +} + +// SetDualSubscription sets the DualSubscription field's value. +func (s *Instance) SetDualSubscription(v string) *Instance { + s.DualSubscription = &v + return s +} + +// SetInstanceID sets the InstanceID field's value. +func (s *Instance) SetInstanceID(v string) *Instance { + s.InstanceID = &v + return s +} + +// SetInstanceType sets the InstanceType field's value. +func (s *Instance) SetInstanceType(v string) *Instance { + s.InstanceType = &v + return s +} + +// SetLastUpdatedTime sets the LastUpdatedTime field's value. +func (s *Instance) SetLastUpdatedTime(v string) *Instance { + s.LastUpdatedTime = &v + return s +} + +// SetOsVersion sets the OsVersion field's value. +func (s *Instance) SetOsVersion(v string) *Instance { + s.OsVersion = &v + return s +} + +// SetProductCode sets the ProductCode field's value. +func (s *Instance) SetProductCode(v []*string) *Instance { + s.ProductCode = v + return s +} + +// SetRegion sets the Region field's value. +func (s *Instance) SetRegion(v string) *Instance { + s.Region = &v + return s +} + +// SetRegisteredWithSubscriptionProvider sets the RegisteredWithSubscriptionProvider field's value. +func (s *Instance) SetRegisteredWithSubscriptionProvider(v string) *Instance { + s.RegisteredWithSubscriptionProvider = &v return s } -type GetServiceSettingsInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// SetStatus sets the Status field's value. +func (s *Instance) SetStatus(v string) *Instance { + s.Status = &v + return s +} + +// SetSubscriptionName sets the SubscriptionName field's value. +func (s *Instance) SetSubscriptionName(v string) *Instance { + s.SubscriptionName = &v + return s +} + +// SetSubscriptionProviderCreateTime sets the SubscriptionProviderCreateTime field's value. +func (s *Instance) SetSubscriptionProviderCreateTime(v string) *Instance { + s.SubscriptionProviderCreateTime = &v + return s +} + +// SetSubscriptionProviderUpdateTime sets the SubscriptionProviderUpdateTime field's value. +func (s *Instance) SetSubscriptionProviderUpdateTime(v string) *Instance { + s.SubscriptionProviderUpdateTime = &v + return s +} + +// SetUsageOperation sets the UsageOperation field's value. +func (s *Instance) SetUsageOperation(v string) *Instance { + s.UsageOperation = &v + return s +} + +// An exception occurred with the service. +type InternalServerException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + Message_ *string `locationName:"message" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InternalServerException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s InternalServerException) GoString() string { + return s.String() +} + +func newErrorInternalServerException(v protocol.ResponseMetadata) error { + return &InternalServerException{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *InternalServerException) Code() string { + return "InternalServerException" +} + +// Message returns the exception's message. +func (s *InternalServerException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InternalServerException) OrigErr() error { + return nil +} + +func (s *InternalServerException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *InternalServerException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *InternalServerException) RequestID() string { + return s.RespMetadata.RequestID +} + +// Lists the settings defined for discovering Linux subscriptions. +type LinuxSubscriptionsDiscoverySettings struct { + _ struct{} `type:"structure"` + + // Details if you have enabled resource discovery across your accounts in Organizations. + // + // OrganizationIntegration is a required field + OrganizationIntegration *string `type:"string" required:"true" enum:"OrganizationIntegration"` + + // The Regions in which to discover data for Linux subscriptions. + // + // SourceRegions is a required field + SourceRegions []*string `min:"1" type:"list" required:"true"` } // String returns the string representation. @@ -544,7 +1738,7 @@ type GetServiceSettingsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetServiceSettingsInput) String() string { +func (s LinuxSubscriptionsDiscoverySettings) String() string { return awsutil.Prettify(s) } @@ -553,31 +1747,88 @@ func (s GetServiceSettingsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetServiceSettingsInput) GoString() string { +func (s LinuxSubscriptionsDiscoverySettings) GoString() string { return s.String() } -type GetServiceSettingsOutput struct { - _ struct{} `type:"structure"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *LinuxSubscriptionsDiscoverySettings) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LinuxSubscriptionsDiscoverySettings"} + if s.OrganizationIntegration == nil { + invalidParams.Add(request.NewErrParamRequired("OrganizationIntegration")) + } + if s.SourceRegions == nil { + invalidParams.Add(request.NewErrParamRequired("SourceRegions")) + } + if s.SourceRegions != nil && len(s.SourceRegions) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SourceRegions", 1)) + } - // The Region in which License Manager displays the aggregated data for Linux - // subscriptions. - HomeRegions []*string `min:"1" type:"list"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // Lists if discovery has been enabled for Linux subscriptions. - LinuxSubscriptionsDiscovery *string `type:"string" enum:"LinuxSubscriptionsDiscovery"` +// SetOrganizationIntegration sets the OrganizationIntegration field's value. +func (s *LinuxSubscriptionsDiscoverySettings) SetOrganizationIntegration(v string) *LinuxSubscriptionsDiscoverySettings { + s.OrganizationIntegration = &v + return s +} - // Lists the settings defined for Linux subscriptions discovery. The settings - // include if Organizations integration has been enabled, and which Regions - // data will be aggregated from. - LinuxSubscriptionsDiscoverySettings *LinuxSubscriptionsDiscoverySettings `type:"structure"` +// SetSourceRegions sets the SourceRegions field's value. +func (s *LinuxSubscriptionsDiscoverySettings) SetSourceRegions(v []*string) *LinuxSubscriptionsDiscoverySettings { + s.SourceRegions = v + return s +} - // Indicates the status of Linux subscriptions settings being applied. - Status *string `type:"string" enum:"Status"` +// NextToken length limit is half of ddb accepted limit. Increase this limit +// if parameters in request increases. +type ListLinuxSubscriptionInstancesInput struct { + _ struct{} `type:"structure"` - // A message which details the Linux subscriptions service settings current - // status. - StatusMessage map[string]*string `type:"map"` + // An array of structures that you can use to filter the results by your specified + // criteria. For example, you can specify Region in the Name, with the contains + // operator to list all subscriptions that match a partial string in the Value, + // such as us-west. + // + // For each filter, you can specify one of the following values for the Name + // key to streamline results: + // + // * AccountID + // + // * AmiID + // + // * DualSubscription + // + // * InstanceID + // + // * InstanceType + // + // * ProductCode + // + // * Region + // + // * Status + // + // * UsageOperation + // + // For each filter, you can use one of the following Operator values to define + // the behavior of the filter: + // + // * contains + // + // * equals + // + // * Notequal + Filters []*Filter `type:"list"` + + // The maximum items to return in a request. + MaxResults *int64 `type:"integer"` + + // A token to specify where to start paginating. This is the nextToken from + // a previously truncated response. + NextToken *string `min:"1" type:"string"` } // String returns the string representation. @@ -585,7 +1836,7 @@ type GetServiceSettingsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetServiceSettingsOutput) String() string { +func (s ListLinuxSubscriptionInstancesInput) String() string { return awsutil.Prettify(s) } @@ -594,77 +1845,194 @@ func (s GetServiceSettingsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetServiceSettingsOutput) GoString() string { +func (s ListLinuxSubscriptionInstancesInput) GoString() string { return s.String() } -// SetHomeRegions sets the HomeRegions field's value. -func (s *GetServiceSettingsOutput) SetHomeRegions(v []*string) *GetServiceSettingsOutput { - s.HomeRegions = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListLinuxSubscriptionInstancesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListLinuxSubscriptionInstancesInput"} + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + if s.Filters != nil { + for i, v := range s.Filters { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilters sets the Filters field's value. +func (s *ListLinuxSubscriptionInstancesInput) SetFilters(v []*Filter) *ListLinuxSubscriptionInstancesInput { + s.Filters = v return s } -// SetLinuxSubscriptionsDiscovery sets the LinuxSubscriptionsDiscovery field's value. -func (s *GetServiceSettingsOutput) SetLinuxSubscriptionsDiscovery(v string) *GetServiceSettingsOutput { - s.LinuxSubscriptionsDiscovery = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListLinuxSubscriptionInstancesInput) SetMaxResults(v int64) *ListLinuxSubscriptionInstancesInput { + s.MaxResults = &v return s } -// SetLinuxSubscriptionsDiscoverySettings sets the LinuxSubscriptionsDiscoverySettings field's value. -func (s *GetServiceSettingsOutput) SetLinuxSubscriptionsDiscoverySettings(v *LinuxSubscriptionsDiscoverySettings) *GetServiceSettingsOutput { - s.LinuxSubscriptionsDiscoverySettings = v +// SetNextToken sets the NextToken field's value. +func (s *ListLinuxSubscriptionInstancesInput) SetNextToken(v string) *ListLinuxSubscriptionInstancesInput { + s.NextToken = &v return s } -// SetStatus sets the Status field's value. -func (s *GetServiceSettingsOutput) SetStatus(v string) *GetServiceSettingsOutput { - s.Status = &v +type ListLinuxSubscriptionInstancesOutput struct { + _ struct{} `type:"structure"` + + // An array that contains instance objects. + Instances []*Instance `type:"list"` + + // The next token used for paginated responses. When this field isn't empty, + // there are additional elements that the service hasn't included in this request. + // Use this token with the next request to retrieve additional objects. + NextToken *string `type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListLinuxSubscriptionInstancesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListLinuxSubscriptionInstancesOutput) GoString() string { + return s.String() +} + +// SetInstances sets the Instances field's value. +func (s *ListLinuxSubscriptionInstancesOutput) SetInstances(v []*Instance) *ListLinuxSubscriptionInstancesOutput { + s.Instances = v return s } -// SetStatusMessage sets the StatusMessage field's value. -func (s *GetServiceSettingsOutput) SetStatusMessage(v map[string]*string) *GetServiceSettingsOutput { - s.StatusMessage = v +// SetNextToken sets the NextToken field's value. +func (s *ListLinuxSubscriptionInstancesOutput) SetNextToken(v string) *ListLinuxSubscriptionInstancesOutput { + s.NextToken = &v return s } -// Details discovered information about a running instance using Linux subscriptions. -type Instance struct { +// NextToken length limit is half of ddb accepted limit. Increase this limit +// if parameters in request increases. +type ListLinuxSubscriptionsInput struct { _ struct{} `type:"structure"` - // The account ID which owns the instance. - AccountID *string `type:"string"` + // An array of structures that you can use to filter the results to those that + // match one or more sets of key-value pairs that you specify. For example, + // you can filter by the name of Subscription with an optional operator to see + // subscriptions that match, partially match, or don't match a certain subscription's + // name. + // + // The valid names for this filter are: + // + // * Subscription + // + // The valid Operators for this filter are: + // + // * contains + // + // * equals + // + // * Notequal + Filters []*Filter `type:"list"` - // The AMI ID used to launch the instance. - AmiId *string `type:"string"` + // The maximum items to return in a request. + MaxResults *int64 `type:"integer"` - // The instance ID of the resource. - InstanceID *string `type:"string"` + // A token to specify where to start paginating. This is the nextToken from + // a previously truncated response. + NextToken *string `min:"1" type:"string"` +} - // The instance type of the resource. - InstanceType *string `type:"string"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListLinuxSubscriptionsInput) String() string { + return awsutil.Prettify(s) +} - // The time in which the last discovery updated the instance details. - LastUpdatedTime *string `type:"string"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListLinuxSubscriptionsInput) GoString() string { + return s.String() +} - // The product code for the instance. For more information, see Usage operation - // values (https://docs.aws.amazon.com/license-manager/latest/userguide/linux-subscriptions-usage-operation.html) - // in the License Manager User Guide . - ProductCode []*string `type:"list"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListLinuxSubscriptionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListLinuxSubscriptionsInput"} + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + if s.Filters != nil { + for i, v := range s.Filters { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilters sets the Filters field's value. +func (s *ListLinuxSubscriptionsInput) SetFilters(v []*Filter) *ListLinuxSubscriptionsInput { + s.Filters = v + return s +} - // The Region the instance is running in. - Region *string `type:"string"` +// SetMaxResults sets the MaxResults field's value. +func (s *ListLinuxSubscriptionsInput) SetMaxResults(v int64) *ListLinuxSubscriptionsInput { + s.MaxResults = &v + return s +} - // The status of the instance. - Status *string `type:"string"` +// SetNextToken sets the NextToken field's value. +func (s *ListLinuxSubscriptionsInput) SetNextToken(v string) *ListLinuxSubscriptionsInput { + s.NextToken = &v + return s +} - // The name of the subscription being used by the instance. - SubscriptionName *string `type:"string"` +type ListLinuxSubscriptionsOutput struct { + _ struct{} `type:"structure"` - // The usage operation of the instance. For more information, see For more information, - // see Usage operation values (https://docs.aws.amazon.com/license-manager/latest/userguide/linux-subscriptions-usage-operation.html) - // in the License Manager User Guide. - UsageOperation *string `type:"string"` + // The next token used for paginated responses. When this field isn't empty, + // there are additional elements that the service hasn't included in this request. + // Use this token with the next request to retrieve additional objects. + NextToken *string `type:"string"` + + // An array that contains subscription objects. + Subscriptions []*Subscription `type:"list"` } // String returns the string representation. @@ -672,7 +2040,7 @@ type Instance struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Instance) String() string { +func (s ListLinuxSubscriptionsOutput) String() string { return awsutil.Prettify(s) } @@ -681,76 +2049,97 @@ func (s Instance) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s Instance) GoString() string { +func (s ListLinuxSubscriptionsOutput) GoString() string { return s.String() } -// SetAccountID sets the AccountID field's value. -func (s *Instance) SetAccountID(v string) *Instance { - s.AccountID = &v +// SetNextToken sets the NextToken field's value. +func (s *ListLinuxSubscriptionsOutput) SetNextToken(v string) *ListLinuxSubscriptionsOutput { + s.NextToken = &v return s } -// SetAmiId sets the AmiId field's value. -func (s *Instance) SetAmiId(v string) *Instance { - s.AmiId = &v +// SetSubscriptions sets the Subscriptions field's value. +func (s *ListLinuxSubscriptionsOutput) SetSubscriptions(v []*Subscription) *ListLinuxSubscriptionsOutput { + s.Subscriptions = v return s } -// SetInstanceID sets the InstanceID field's value. -func (s *Instance) SetInstanceID(v string) *Instance { - s.InstanceID = &v - return s -} +type ListRegisteredSubscriptionProvidersInput struct { + _ struct{} `type:"structure"` -// SetInstanceType sets the InstanceType field's value. -func (s *Instance) SetInstanceType(v string) *Instance { - s.InstanceType = &v - return s + // The maximum items to return in a request. + MaxResults *int64 `min:"1" type:"integer"` + + // A token to specify where to start paginating. This is the nextToken from + // a previously truncated response. + NextToken *string `type:"string"` + + // To filter your results, specify which subscription providers to return in + // the list. + SubscriptionProviderSources []*string `type:"list" enum:"SubscriptionProviderSource"` } -// SetLastUpdatedTime sets the LastUpdatedTime field's value. -func (s *Instance) SetLastUpdatedTime(v string) *Instance { - s.LastUpdatedTime = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRegisteredSubscriptionProvidersInput) String() string { + return awsutil.Prettify(s) } -// SetProductCode sets the ProductCode field's value. -func (s *Instance) SetProductCode(v []*string) *Instance { - s.ProductCode = v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRegisteredSubscriptionProvidersInput) GoString() string { + return s.String() } -// SetRegion sets the Region field's value. -func (s *Instance) SetRegion(v string) *Instance { - s.Region = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListRegisteredSubscriptionProvidersInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListRegisteredSubscriptionProvidersInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetStatus sets the Status field's value. -func (s *Instance) SetStatus(v string) *Instance { - s.Status = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListRegisteredSubscriptionProvidersInput) SetMaxResults(v int64) *ListRegisteredSubscriptionProvidersInput { + s.MaxResults = &v return s } -// SetSubscriptionName sets the SubscriptionName field's value. -func (s *Instance) SetSubscriptionName(v string) *Instance { - s.SubscriptionName = &v +// SetNextToken sets the NextToken field's value. +func (s *ListRegisteredSubscriptionProvidersInput) SetNextToken(v string) *ListRegisteredSubscriptionProvidersInput { + s.NextToken = &v return s } -// SetUsageOperation sets the UsageOperation field's value. -func (s *Instance) SetUsageOperation(v string) *Instance { - s.UsageOperation = &v +// SetSubscriptionProviderSources sets the SubscriptionProviderSources field's value. +func (s *ListRegisteredSubscriptionProvidersInput) SetSubscriptionProviderSources(v []*string) *ListRegisteredSubscriptionProvidersInput { + s.SubscriptionProviderSources = v return s } -// An exception occurred with the service. -type InternalServerException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` +type ListRegisteredSubscriptionProvidersOutput struct { + _ struct{} `type:"structure"` - Message_ *string `locationName:"message" type:"string"` + // The next token used for paginated responses. When this field isn't empty, + // there are additional elements that the service hasn't included in this request. + // Use this token with the next request to retrieve additional objects. + NextToken *string `type:"string"` + + // The list of BYOL registration resources that fit the criteria you specified + // in the request. + RegisteredSubscriptionProviders []*RegisteredSubscriptionProvider `type:"list"` } // String returns the string representation. @@ -758,7 +2147,7 @@ type InternalServerException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InternalServerException) String() string { +func (s ListRegisteredSubscriptionProvidersOutput) String() string { return awsutil.Prettify(s) } @@ -767,61 +2156,30 @@ func (s InternalServerException) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s InternalServerException) GoString() string { +func (s ListRegisteredSubscriptionProvidersOutput) GoString() string { return s.String() } -func newErrorInternalServerException(v protocol.ResponseMetadata) error { - return &InternalServerException{ - RespMetadata: v, - } -} - -// Code returns the exception type name. -func (s *InternalServerException) Code() string { - return "InternalServerException" -} - -// Message returns the exception's message. -func (s *InternalServerException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" -} - -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *InternalServerException) OrigErr() error { - return nil -} - -func (s *InternalServerException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) -} - -// Status code returns the HTTP status code for the request's response error. -func (s *InternalServerException) StatusCode() int { - return s.RespMetadata.StatusCode +// SetNextToken sets the NextToken field's value. +func (s *ListRegisteredSubscriptionProvidersOutput) SetNextToken(v string) *ListRegisteredSubscriptionProvidersOutput { + s.NextToken = &v + return s } -// RequestID returns the service's response RequestID for request. -func (s *InternalServerException) RequestID() string { - return s.RespMetadata.RequestID +// SetRegisteredSubscriptionProviders sets the RegisteredSubscriptionProviders field's value. +func (s *ListRegisteredSubscriptionProvidersOutput) SetRegisteredSubscriptionProviders(v []*RegisteredSubscriptionProvider) *ListRegisteredSubscriptionProvidersOutput { + s.RegisteredSubscriptionProviders = v + return s } -// Lists the settings defined for discovering Linux subscriptions. -type LinuxSubscriptionsDiscoverySettings struct { - _ struct{} `type:"structure"` - - // Details if you have enabled resource discovery across your accounts in Organizations. - // - // OrganizationIntegration is a required field - OrganizationIntegration *string `type:"string" required:"true" enum:"OrganizationIntegration"` +type ListTagsForResourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The Regions in which to discover data for Linux subscriptions. + // The Amazon Resource Name (ARN) of the resource for which to list metadata + // tags. // - // SourceRegions is a required field - SourceRegions []*string `min:"1" type:"list" required:"true"` + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` } // String returns the string representation. @@ -829,7 +2187,7 @@ type LinuxSubscriptionsDiscoverySettings struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s LinuxSubscriptionsDiscoverySettings) String() string { +func (s ListTagsForResourceInput) String() string { return awsutil.Prettify(s) } @@ -838,21 +2196,18 @@ func (s LinuxSubscriptionsDiscoverySettings) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s LinuxSubscriptionsDiscoverySettings) GoString() string { +func (s ListTagsForResourceInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *LinuxSubscriptionsDiscoverySettings) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "LinuxSubscriptionsDiscoverySettings"} - if s.OrganizationIntegration == nil { - invalidParams.Add(request.NewErrParamRequired("OrganizationIntegration")) +func (s *ListTagsForResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } - if s.SourceRegions == nil { - invalidParams.Add(request.NewErrParamRequired("SourceRegions")) - } - if s.SourceRegions != nil && len(s.SourceRegions) < 1 { - invalidParams.Add(request.NewErrParamMinLen("SourceRegions", 1)) + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) } if invalidParams.Len() > 0 { @@ -861,61 +2216,69 @@ func (s *LinuxSubscriptionsDiscoverySettings) Validate() error { return nil } -// SetOrganizationIntegration sets the OrganizationIntegration field's value. -func (s *LinuxSubscriptionsDiscoverySettings) SetOrganizationIntegration(v string) *LinuxSubscriptionsDiscoverySettings { - s.OrganizationIntegration = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { + s.ResourceArn = &v return s } -// SetSourceRegions sets the SourceRegions field's value. -func (s *LinuxSubscriptionsDiscoverySettings) SetSourceRegions(v []*string) *LinuxSubscriptionsDiscoverySettings { - s.SourceRegions = v +type ListTagsForResourceOutput struct { + _ struct{} `type:"structure"` + + // The metadata tags for the requested resource. + // + // Tags is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by ListTagsForResourceOutput's + // String and GoString methods. + Tags map[string]*string `locationName:"tags" type:"map" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListTagsForResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListTagsForResourceOutput) GoString() string { + return s.String() +} + +// SetTags sets the Tags field's value. +func (s *ListTagsForResourceOutput) SetTags(v map[string]*string) *ListTagsForResourceOutput { + s.Tags = v return s } -// NextToken length limit is half of ddb accepted limit. Increase this limit -// if parameters in request increases. -type ListLinuxSubscriptionInstancesInput struct { +type RegisterSubscriptionProviderInput struct { _ struct{} `type:"structure"` - // An array of structures that you can use to filter the results to those that - // match one or more sets of key-value pairs that you specify. For example, - // you can filter by the name of AmiID with an optional operator to see subscriptions - // that match, partially match, or don't match a certain Amazon Machine Image - // (AMI) ID. - // - // The valid names for this filter are: - // - // * AmiID - // - // * InstanceID - // - // * AccountID - // - // * Status - // - // * Region - // - // * UsageOperation - // - // * ProductCode - // - // * InstanceType - // - // The valid Operators for this filter are: - // - // * contains - // - // * equals + // The Amazon Resource Name (ARN) of the secret where you've stored your subscription + // provider's access token. For RHEL subscriptions managed through the Red Hat + // Subscription Manager (RHSM), the secret contains your Red Hat Offline token. // - // * Notequal - Filters []*Filter `type:"list"` + // SecretArn is a required field + SecretArn *string `type:"string" required:"true"` - // Maximum number of results to return in a single call. - MaxResults *int64 `type:"integer"` + // The supported Linux subscription provider to register. + // + // SubscriptionProviderSource is a required field + SubscriptionProviderSource *string `type:"string" required:"true" enum:"SubscriptionProviderSource"` - // Token for the next set of results. - NextToken *string `min:"1" type:"string"` + // The metadata tags to assign to your registered Linux subscription provider + // resource. + // + // Tags is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by RegisterSubscriptionProviderInput's + // String and GoString methods. + Tags map[string]*string `type:"map" sensitive:"true"` } // String returns the string representation. @@ -923,7 +2286,7 @@ type ListLinuxSubscriptionInstancesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionInstancesInput) String() string { +func (s RegisterSubscriptionProviderInput) String() string { return awsutil.Prettify(s) } @@ -932,25 +2295,18 @@ func (s ListLinuxSubscriptionInstancesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionInstancesInput) GoString() string { +func (s RegisterSubscriptionProviderInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListLinuxSubscriptionInstancesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListLinuxSubscriptionInstancesInput"} - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) +func (s *RegisterSubscriptionProviderInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RegisterSubscriptionProviderInput"} + if s.SecretArn == nil { + invalidParams.Add(request.NewErrParamRequired("SecretArn")) } - if s.Filters != nil { - for i, v := range s.Filters { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) - } - } + if s.SubscriptionProviderSource == nil { + invalidParams.Add(request.NewErrParamRequired("SubscriptionProviderSource")) } if invalidParams.Len() > 0 { @@ -959,32 +2315,37 @@ func (s *ListLinuxSubscriptionInstancesInput) Validate() error { return nil } -// SetFilters sets the Filters field's value. -func (s *ListLinuxSubscriptionInstancesInput) SetFilters(v []*Filter) *ListLinuxSubscriptionInstancesInput { - s.Filters = v +// SetSecretArn sets the SecretArn field's value. +func (s *RegisterSubscriptionProviderInput) SetSecretArn(v string) *RegisterSubscriptionProviderInput { + s.SecretArn = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListLinuxSubscriptionInstancesInput) SetMaxResults(v int64) *ListLinuxSubscriptionInstancesInput { - s.MaxResults = &v +// SetSubscriptionProviderSource sets the SubscriptionProviderSource field's value. +func (s *RegisterSubscriptionProviderInput) SetSubscriptionProviderSource(v string) *RegisterSubscriptionProviderInput { + s.SubscriptionProviderSource = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListLinuxSubscriptionInstancesInput) SetNextToken(v string) *ListLinuxSubscriptionInstancesInput { - s.NextToken = &v +// SetTags sets the Tags field's value. +func (s *RegisterSubscriptionProviderInput) SetTags(v map[string]*string) *RegisterSubscriptionProviderInput { + s.Tags = v return s } -type ListLinuxSubscriptionInstancesOutput struct { +type RegisterSubscriptionProviderOutput struct { _ struct{} `type:"structure"` - // An array that contains instance objects. - Instances []*Instance `type:"list"` + // The Amazon Resource Name (ARN) of the Linux subscription provider resource + // that you registered. + SubscriptionProviderArn *string `type:"string"` - // Token for the next set of results. - NextToken *string `type:"string"` + // The Linux subscription provider that you registered. + SubscriptionProviderSource *string `type:"string" enum:"SubscriptionProviderSource"` + + // Indicates the status of the registration action for the Linux subscription + // provider that you requested. + SubscriptionProviderStatus *string `type:"string" enum:"SubscriptionProviderStatus"` } // String returns the string representation. @@ -992,7 +2353,7 @@ type ListLinuxSubscriptionInstancesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionInstancesOutput) String() string { +func (s RegisterSubscriptionProviderOutput) String() string { return awsutil.Prettify(s) } @@ -1001,51 +2362,60 @@ func (s ListLinuxSubscriptionInstancesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionInstancesOutput) GoString() string { +func (s RegisterSubscriptionProviderOutput) GoString() string { return s.String() } -// SetInstances sets the Instances field's value. -func (s *ListLinuxSubscriptionInstancesOutput) SetInstances(v []*Instance) *ListLinuxSubscriptionInstancesOutput { - s.Instances = v +// SetSubscriptionProviderArn sets the SubscriptionProviderArn field's value. +func (s *RegisterSubscriptionProviderOutput) SetSubscriptionProviderArn(v string) *RegisterSubscriptionProviderOutput { + s.SubscriptionProviderArn = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListLinuxSubscriptionInstancesOutput) SetNextToken(v string) *ListLinuxSubscriptionInstancesOutput { - s.NextToken = &v +// SetSubscriptionProviderSource sets the SubscriptionProviderSource field's value. +func (s *RegisterSubscriptionProviderOutput) SetSubscriptionProviderSource(v string) *RegisterSubscriptionProviderOutput { + s.SubscriptionProviderSource = &v return s } -// NextToken length limit is half of ddb accepted limit. Increase this limit -// if parameters in request increases. -type ListLinuxSubscriptionsInput struct { +// SetSubscriptionProviderStatus sets the SubscriptionProviderStatus field's value. +func (s *RegisterSubscriptionProviderOutput) SetSubscriptionProviderStatus(v string) *RegisterSubscriptionProviderOutput { + s.SubscriptionProviderStatus = &v + return s +} + +// A third-party provider for operating system (OS) platform software and license +// subscriptions, such as Red Hat. When you register a third-party Linux subscription +// provider, License Manager can get subscription data from the registered provider. +type RegisteredSubscriptionProvider struct { _ struct{} `type:"structure"` - // An array of structures that you can use to filter the results to those that - // match one or more sets of key-value pairs that you specify. For example, - // you can filter by the name of Subscription with an optional operator to see - // subscriptions that match, partially match, or don't match a certain subscription's - // name. - // - // The valid names for this filter are: - // - // * Subscription - // - // The valid Operators for this filter are: - // - // * contains - // - // * equals - // - // * Notequal - Filters []*Filter `type:"list"` + // The timestamp from the last time that License Manager accessed third-party + // subscription data for your account from your registered Linux subscription + // provider. + LastSuccessfulDataRetrievalTime *string `type:"string"` - // Maximum number of results to return in a single call. - MaxResults *int64 `type:"integer"` + // The Amazon Resource Name (ARN) of the Secrets Manager secret that stores + // your registered Linux subscription provider access token. For RHEL account + // subscriptions, this is the offline token. + SecretArn *string `type:"string"` - // Token for the next set of results. - NextToken *string `min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the Linux subscription provider resource + // that you registered. + SubscriptionProviderArn *string `type:"string"` + + // A supported third-party Linux subscription provider. License Manager currently + // supports Red Hat subscriptions. + SubscriptionProviderSource *string `type:"string" enum:"SubscriptionProviderSource"` + + // Indicates the status of your registered Linux subscription provider access + // token from the last time License Manager retrieved subscription data. For + // RHEL account subscriptions, this is the status of the offline token. + SubscriptionProviderStatus *string `type:"string" enum:"SubscriptionProviderStatus"` + + // A detailed message that's associated with your BYOL subscription provider + // token status. + SubscriptionProviderStatusMessage *string `type:"string"` } // String returns the string representation. @@ -1053,7 +2423,7 @@ type ListLinuxSubscriptionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionsInput) String() string { +func (s RegisteredSubscriptionProvider) String() string { return awsutil.Prettify(s) } @@ -1062,59 +2432,52 @@ func (s ListLinuxSubscriptionsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionsInput) GoString() string { +func (s RegisteredSubscriptionProvider) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListLinuxSubscriptionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListLinuxSubscriptionsInput"} - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - if s.Filters != nil { - for i, v := range s.Filters { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) - } - } - } +// SetLastSuccessfulDataRetrievalTime sets the LastSuccessfulDataRetrievalTime field's value. +func (s *RegisteredSubscriptionProvider) SetLastSuccessfulDataRetrievalTime(v string) *RegisteredSubscriptionProvider { + s.LastSuccessfulDataRetrievalTime = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetSecretArn sets the SecretArn field's value. +func (s *RegisteredSubscriptionProvider) SetSecretArn(v string) *RegisteredSubscriptionProvider { + s.SecretArn = &v + return s } -// SetFilters sets the Filters field's value. -func (s *ListLinuxSubscriptionsInput) SetFilters(v []*Filter) *ListLinuxSubscriptionsInput { - s.Filters = v +// SetSubscriptionProviderArn sets the SubscriptionProviderArn field's value. +func (s *RegisteredSubscriptionProvider) SetSubscriptionProviderArn(v string) *RegisteredSubscriptionProvider { + s.SubscriptionProviderArn = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListLinuxSubscriptionsInput) SetMaxResults(v int64) *ListLinuxSubscriptionsInput { - s.MaxResults = &v +// SetSubscriptionProviderSource sets the SubscriptionProviderSource field's value. +func (s *RegisteredSubscriptionProvider) SetSubscriptionProviderSource(v string) *RegisteredSubscriptionProvider { + s.SubscriptionProviderSource = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListLinuxSubscriptionsInput) SetNextToken(v string) *ListLinuxSubscriptionsInput { - s.NextToken = &v +// SetSubscriptionProviderStatus sets the SubscriptionProviderStatus field's value. +func (s *RegisteredSubscriptionProvider) SetSubscriptionProviderStatus(v string) *RegisteredSubscriptionProvider { + s.SubscriptionProviderStatus = &v return s } -type ListLinuxSubscriptionsOutput struct { - _ struct{} `type:"structure"` +// SetSubscriptionProviderStatusMessage sets the SubscriptionProviderStatusMessage field's value. +func (s *RegisteredSubscriptionProvider) SetSubscriptionProviderStatusMessage(v string) *RegisteredSubscriptionProvider { + s.SubscriptionProviderStatusMessage = &v + return s +} - // Token for the next set of results. - NextToken *string `type:"string"` +// Unable to find the requested Amazon Web Services resource. +type ResourceNotFoundException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // An array that contains subscription objects. - Subscriptions []*Subscription `type:"list"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -1122,7 +2485,7 @@ type ListLinuxSubscriptionsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionsOutput) String() string { +func (s ResourceNotFoundException) String() string { return awsutil.Prettify(s) } @@ -1131,20 +2494,46 @@ func (s ListLinuxSubscriptionsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListLinuxSubscriptionsOutput) GoString() string { +func (s ResourceNotFoundException) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *ListLinuxSubscriptionsOutput) SetNextToken(v string) *ListLinuxSubscriptionsOutput { - s.NextToken = &v - return s +func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { + return &ResourceNotFoundException{ + RespMetadata: v, + } } -// SetSubscriptions sets the Subscriptions field's value. -func (s *ListLinuxSubscriptionsOutput) SetSubscriptions(v []*Subscription) *ListLinuxSubscriptionsOutput { - s.Subscriptions = v - return s +// Code returns the exception type name. +func (s *ResourceNotFoundException) Code() string { + return "ResourceNotFoundException" +} + +// Message returns the exception's message. +func (s *ResourceNotFoundException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ResourceNotFoundException) OrigErr() error { + return nil +} + +func (s *ResourceNotFoundException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *ResourceNotFoundException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *ResourceNotFoundException) RequestID() string { + return s.RespMetadata.RequestID } // An object which details a discovered Linux subscription. @@ -1200,6 +2589,97 @@ func (s *Subscription) SetType(v string) *Subscription { return s } +type TagResourceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the Amazon Web Services resource to which + // to add the specified metadata tags. + // + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` + + // The metadata tags to assign to the Amazon Web Services resource. Tags are + // formatted as key value pairs. + // + // Tags is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by TagResourceInput's + // String and GoString methods. + // + // Tags is a required field + Tags map[string]*string `locationName:"tags" type:"map" required:"true" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TagResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TagResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *TagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + if s.Tags == nil { + invalidParams.Add(request.NewErrParamRequired("Tags")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput { + s.ResourceArn = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *TagResourceInput) SetTags(v map[string]*string) *TagResourceInput { + s.Tags = v + return s +} + +type TagResourceOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TagResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s TagResourceOutput) GoString() string { + return s.String() +} + // The request was denied due to request throttling. type ThrottlingException struct { _ struct{} `type:"structure"` @@ -1264,6 +2744,96 @@ func (s *ThrottlingException) RequestID() string { return s.RespMetadata.RequestID } +type UntagResourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The Amazon Resource Name (ARN) of the Amazon Web Services resource to remove + // the metadata tags from. + // + // ResourceArn is a required field + ResourceArn *string `location:"uri" locationName:"resourceArn" type:"string" required:"true"` + + // A list of metadata tag keys to remove from the requested resource. + // + // TagKeys is a sensitive parameter and its value will be + // replaced with "sensitive" in string returned by UntagResourceInput's + // String and GoString methods. + // + // TagKeys is a required field + TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true" sensitive:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UntagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + if s.TagKeys == nil { + invalidParams.Add(request.NewErrParamRequired("TagKeys")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput { + s.ResourceArn = &v + return s +} + +// SetTagKeys sets the TagKeys field's value. +func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { + s.TagKeys = v + return s +} + +type UntagResourceOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UntagResourceOutput) GoString() string { + return s.String() +} + type UpdateServiceSettingsInput struct { _ struct{} `type:"structure"` @@ -1552,3 +3122,35 @@ func Status_Values() []string { StatusFailed, } } + +const ( + // SubscriptionProviderSourceRedHat is a SubscriptionProviderSource enum value + SubscriptionProviderSourceRedHat = "RedHat" +) + +// SubscriptionProviderSource_Values returns all elements of the SubscriptionProviderSource enum +func SubscriptionProviderSource_Values() []string { + return []string{ + SubscriptionProviderSourceRedHat, + } +} + +const ( + // SubscriptionProviderStatusActive is a SubscriptionProviderStatus enum value + SubscriptionProviderStatusActive = "ACTIVE" + + // SubscriptionProviderStatusInvalid is a SubscriptionProviderStatus enum value + SubscriptionProviderStatusInvalid = "INVALID" + + // SubscriptionProviderStatusPending is a SubscriptionProviderStatus enum value + SubscriptionProviderStatusPending = "PENDING" +) + +// SubscriptionProviderStatus_Values returns all elements of the SubscriptionProviderStatus enum +func SubscriptionProviderStatus_Values() []string { + return []string{ + SubscriptionProviderStatusActive, + SubscriptionProviderStatusInvalid, + SubscriptionProviderStatusPending, + } +} diff --git a/service/licensemanagerlinuxsubscriptions/errors.go b/service/licensemanagerlinuxsubscriptions/errors.go index 3265ade0241..3e81ecc22cb 100644 --- a/service/licensemanagerlinuxsubscriptions/errors.go +++ b/service/licensemanagerlinuxsubscriptions/errors.go @@ -14,6 +14,12 @@ const ( // An exception occurred with the service. ErrCodeInternalServerException = "InternalServerException" + // ErrCodeResourceNotFoundException for service response error code + // "ResourceNotFoundException". + // + // Unable to find the requested Amazon Web Services resource. + ErrCodeResourceNotFoundException = "ResourceNotFoundException" + // ErrCodeThrottlingException for service response error code // "ThrottlingException". // @@ -28,7 +34,8 @@ const ( ) var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{ - "InternalServerException": newErrorInternalServerException, - "ThrottlingException": newErrorThrottlingException, - "ValidationException": newErrorValidationException, + "InternalServerException": newErrorInternalServerException, + "ResourceNotFoundException": newErrorResourceNotFoundException, + "ThrottlingException": newErrorThrottlingException, + "ValidationException": newErrorValidationException, } diff --git a/service/licensemanagerlinuxsubscriptions/licensemanagerlinuxsubscriptionsiface/interface.go b/service/licensemanagerlinuxsubscriptions/licensemanagerlinuxsubscriptionsiface/interface.go index 30fd6fff7f1..71c2b73534a 100644 --- a/service/licensemanagerlinuxsubscriptions/licensemanagerlinuxsubscriptionsiface/interface.go +++ b/service/licensemanagerlinuxsubscriptions/licensemanagerlinuxsubscriptionsiface/interface.go @@ -26,7 +26,7 @@ import ( // // myFunc uses an SDK service client to make a request to // // AWS License Manager Linux Subscriptions. // func myFunc(svc licensemanagerlinuxsubscriptionsiface.LicenseManagerLinuxSubscriptionsAPI) bool { -// // Make svc.GetServiceSettings request +// // Make svc.DeregisterSubscriptionProvider request // } // // func main() { @@ -42,7 +42,7 @@ import ( // type mockLicenseManagerLinuxSubscriptionsClient struct { // licensemanagerlinuxsubscriptionsiface.LicenseManagerLinuxSubscriptionsAPI // } -// func (m *mockLicenseManagerLinuxSubscriptionsClient) GetServiceSettings(input *licensemanagerlinuxsubscriptions.GetServiceSettingsInput) (*licensemanagerlinuxsubscriptions.GetServiceSettingsOutput, error) { +// func (m *mockLicenseManagerLinuxSubscriptionsClient) DeregisterSubscriptionProvider(input *licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderInput) (*licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderOutput, error) { // // mock response/functionality // } // @@ -60,6 +60,14 @@ import ( // and waiters. Its suggested to use the pattern above for testing, or using // tooling to generate mocks to satisfy the interfaces. type LicenseManagerLinuxSubscriptionsAPI interface { + DeregisterSubscriptionProvider(*licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderInput) (*licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderOutput, error) + DeregisterSubscriptionProviderWithContext(aws.Context, *licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderInput, ...request.Option) (*licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderOutput, error) + DeregisterSubscriptionProviderRequest(*licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderInput) (*request.Request, *licensemanagerlinuxsubscriptions.DeregisterSubscriptionProviderOutput) + + GetRegisteredSubscriptionProvider(*licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderInput) (*licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderOutput, error) + GetRegisteredSubscriptionProviderWithContext(aws.Context, *licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderInput, ...request.Option) (*licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderOutput, error) + GetRegisteredSubscriptionProviderRequest(*licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderInput) (*request.Request, *licensemanagerlinuxsubscriptions.GetRegisteredSubscriptionProviderOutput) + GetServiceSettings(*licensemanagerlinuxsubscriptions.GetServiceSettingsInput) (*licensemanagerlinuxsubscriptions.GetServiceSettingsOutput, error) GetServiceSettingsWithContext(aws.Context, *licensemanagerlinuxsubscriptions.GetServiceSettingsInput, ...request.Option) (*licensemanagerlinuxsubscriptions.GetServiceSettingsOutput, error) GetServiceSettingsRequest(*licensemanagerlinuxsubscriptions.GetServiceSettingsInput) (*request.Request, *licensemanagerlinuxsubscriptions.GetServiceSettingsOutput) @@ -78,6 +86,29 @@ type LicenseManagerLinuxSubscriptionsAPI interface { ListLinuxSubscriptionsPages(*licensemanagerlinuxsubscriptions.ListLinuxSubscriptionsInput, func(*licensemanagerlinuxsubscriptions.ListLinuxSubscriptionsOutput, bool) bool) error ListLinuxSubscriptionsPagesWithContext(aws.Context, *licensemanagerlinuxsubscriptions.ListLinuxSubscriptionsInput, func(*licensemanagerlinuxsubscriptions.ListLinuxSubscriptionsOutput, bool) bool, ...request.Option) error + ListRegisteredSubscriptionProviders(*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersInput) (*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput, error) + ListRegisteredSubscriptionProvidersWithContext(aws.Context, *licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersInput, ...request.Option) (*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput, error) + ListRegisteredSubscriptionProvidersRequest(*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersInput) (*request.Request, *licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput) + + ListRegisteredSubscriptionProvidersPages(*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersInput, func(*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput, bool) bool) error + ListRegisteredSubscriptionProvidersPagesWithContext(aws.Context, *licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersInput, func(*licensemanagerlinuxsubscriptions.ListRegisteredSubscriptionProvidersOutput, bool) bool, ...request.Option) error + + ListTagsForResource(*licensemanagerlinuxsubscriptions.ListTagsForResourceInput) (*licensemanagerlinuxsubscriptions.ListTagsForResourceOutput, error) + ListTagsForResourceWithContext(aws.Context, *licensemanagerlinuxsubscriptions.ListTagsForResourceInput, ...request.Option) (*licensemanagerlinuxsubscriptions.ListTagsForResourceOutput, error) + ListTagsForResourceRequest(*licensemanagerlinuxsubscriptions.ListTagsForResourceInput) (*request.Request, *licensemanagerlinuxsubscriptions.ListTagsForResourceOutput) + + RegisterSubscriptionProvider(*licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderInput) (*licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderOutput, error) + RegisterSubscriptionProviderWithContext(aws.Context, *licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderInput, ...request.Option) (*licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderOutput, error) + RegisterSubscriptionProviderRequest(*licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderInput) (*request.Request, *licensemanagerlinuxsubscriptions.RegisterSubscriptionProviderOutput) + + TagResource(*licensemanagerlinuxsubscriptions.TagResourceInput) (*licensemanagerlinuxsubscriptions.TagResourceOutput, error) + TagResourceWithContext(aws.Context, *licensemanagerlinuxsubscriptions.TagResourceInput, ...request.Option) (*licensemanagerlinuxsubscriptions.TagResourceOutput, error) + TagResourceRequest(*licensemanagerlinuxsubscriptions.TagResourceInput) (*request.Request, *licensemanagerlinuxsubscriptions.TagResourceOutput) + + UntagResource(*licensemanagerlinuxsubscriptions.UntagResourceInput) (*licensemanagerlinuxsubscriptions.UntagResourceOutput, error) + UntagResourceWithContext(aws.Context, *licensemanagerlinuxsubscriptions.UntagResourceInput, ...request.Option) (*licensemanagerlinuxsubscriptions.UntagResourceOutput, error) + UntagResourceRequest(*licensemanagerlinuxsubscriptions.UntagResourceInput) (*request.Request, *licensemanagerlinuxsubscriptions.UntagResourceOutput) + UpdateServiceSettings(*licensemanagerlinuxsubscriptions.UpdateServiceSettingsInput) (*licensemanagerlinuxsubscriptions.UpdateServiceSettingsOutput, error) UpdateServiceSettingsWithContext(aws.Context, *licensemanagerlinuxsubscriptions.UpdateServiceSettingsInput, ...request.Option) (*licensemanagerlinuxsubscriptions.UpdateServiceSettingsOutput, error) UpdateServiceSettingsRequest(*licensemanagerlinuxsubscriptions.UpdateServiceSettingsInput) (*request.Request, *licensemanagerlinuxsubscriptions.UpdateServiceSettingsOutput) diff --git a/service/mediaconnect/api.go b/service/mediaconnect/api.go index de7ddfef83e..d1135718400 100644 --- a/service/mediaconnect/api.go +++ b/service/mediaconnect/api.go @@ -7317,6 +7317,11 @@ type AddOutputRequest struct { // The name of the output. This value must be unique within the current flow. Name *string `locationName:"name" type:"string"` + // An indication of whether the new output should be enabled or disabled as + // soon as it is created. If you don't specify the outputStatus field in your + // request, MediaConnect sets it to ENABLED. + OutputStatus *string `locationName:"outputStatus" type:"string" enum:"OutputStatus"` + // The port to use when content is distributed to this output. Port *int64 `locationName:"port" type:"integer"` @@ -7437,6 +7442,12 @@ func (s *AddOutputRequest) SetName(v string) *AddOutputRequest { return s } +// SetOutputStatus sets the OutputStatus field's value. +func (s *AddOutputRequest) SetOutputStatus(v string) *AddOutputRequest { + s.OutputStatus = &v + return s +} + // SetPort sets the Port field's value. func (s *AddOutputRequest) SetPort(v int64) *AddOutputRequest { s.Port = &v @@ -13756,6 +13767,9 @@ type Output struct { // OutputArn is a required field OutputArn *string `locationName:"outputArn" type:"string" required:"true"` + // An indication of whether the output is transmitting data or not. + OutputStatus *string `locationName:"outputStatus" type:"string" enum:"OutputStatus"` + // The port to use when content is distributed to this output. Port *int64 `locationName:"port" type:"integer"` @@ -13856,6 +13870,12 @@ func (s *Output) SetOutputArn(v string) *Output { return s } +// SetOutputStatus sets the OutputStatus field's value. +func (s *Output) SetOutputStatus(v string) *Output { + s.OutputStatus = &v + return s +} + // SetPort sets the Port field's value. func (s *Output) SetPort(v int64) *Output { s.Port = &v @@ -17549,6 +17569,11 @@ type UpdateFlowOutputInput struct { // OutputArn is a required field OutputArn *string `location:"uri" locationName:"outputArn" type:"string" required:"true"` + // An indication of whether the output should transmit data or not. If you don't + // specify the outputStatus field in your request, MediaConnect leaves the value + // unchanged. + OutputStatus *string `locationName:"outputStatus" type:"string" enum:"OutputStatus"` + // The port to use when content is distributed to this output. Port *int64 `locationName:"port" type:"integer"` @@ -17681,6 +17706,12 @@ func (s *UpdateFlowOutputInput) SetOutputArn(v string) *UpdateFlowOutputInput { return s } +// SetOutputStatus sets the OutputStatus field's value. +func (s *UpdateFlowOutputInput) SetOutputStatus(v string) *UpdateFlowOutputInput { + s.OutputStatus = &v + return s +} + // SetPort sets the Port field's value. func (s *UpdateFlowOutputInput) SetPort(v int64) *UpdateFlowOutputInput { s.Port = &v @@ -18925,6 +18956,22 @@ func NetworkInterfaceType_Values() []string { } } +const ( + // OutputStatusEnabled is a OutputStatus enum value + OutputStatusEnabled = "ENABLED" + + // OutputStatusDisabled is a OutputStatus enum value + OutputStatusDisabled = "DISABLED" +) + +// OutputStatus_Values returns all elements of the OutputStatus enum +func OutputStatus_Values() []string { + return []string{ + OutputStatusEnabled, + OutputStatusDisabled, + } +} + const ( // PriceUnitsHourly is a PriceUnits enum value PriceUnitsHourly = "HOURLY"