Class AssetToolSchema

java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.bedrockagentcore.ToolSchema
software.amazon.awscdk.services.bedrockagentcore.AssetToolSchema
All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable

@Generated(value="jsii-pacmak/1.129.0 (build eaca441)", date="2026-05-19T08:18:44.222Z") @Stability(Stable) public class AssetToolSchema extends ToolSchema
Tool Schema from a local asset.

The asset is uploaded to an S3 staging bucket, then moved to its final location by CloudFormation during deployment.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.*;
 import software.amazon.awscdk.services.bedrockagentcore.*;
 import software.amazon.awscdk.services.iam.*;
 import software.amazon.awscdk.interfaces.kms.*;
 DockerImage dockerImage;
 IGrantable grantable;
 IKeyRef keyRef;
 ILocalBundling localBundling;
 AssetToolSchema assetToolSchema = AssetToolSchema.Builder.create("path")
         .assetHash("assetHash")
         .assetHashType(AssetHashType.SOURCE)
         .bundling(BundlingOptions.builder()
                 .image(dockerImage)
                 // the properties below are optional
                 .bundlingFileAccess(BundlingFileAccess.VOLUME_COPY)
                 .command(List.of("command"))
                 .entrypoint(List.of("entrypoint"))
                 .environment(Map.of(
                         "environmentKey", "environment"))
                 .local(localBundling)
                 .network("network")
                 .outputType(BundlingOutput.ARCHIVED)
                 .platform("platform")
                 .securityOpt("securityOpt")
                 .user("user")
                 .volumes(List.of(DockerVolume.builder()
                         .containerPath("containerPath")
                         .hostPath("hostPath")
                         // the properties below are optional
                         .consistency(DockerVolumeConsistency.CONSISTENT)
                         .build()))
                 .volumesFrom(List.of("volumesFrom"))
                 .workingDirectory("workingDirectory")
                 .build())
         .deployTime(false)
         .displayName("displayName")
         .exclude(List.of("exclude"))
         .followSymlinks(SymlinkFollowMode.NEVER)
         .ignoreMode(IgnoreMode.GLOB)
         .readers(List.of(grantable))
         .sourceKMSKey(keyRef)
         .build();
 
  • Constructor Details

    • AssetToolSchema

      protected AssetToolSchema(software.amazon.jsii.JsiiObjectRef objRef)
    • AssetToolSchema

      protected AssetToolSchema(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • AssetToolSchema

      @Stability(Stable) public AssetToolSchema(@NotNull String path, @Nullable AssetOptions options)
      Parameters:
      path - This parameter is required.
      options -
    • AssetToolSchema

      @Stability(Stable) public AssetToolSchema(@NotNull String path)
      Parameters:
      path - This parameter is required.
  • Method Details

    • bind

      @Stability(Stable) public void bind(@NotNull software.constructs.Construct scope)
      Binds this tool schema to a construct scope.

      This method initializes the S3 asset if it hasn't been initialized yet. Must be called before rendering the schema as CFN properties.

      Specified by:
      bind in class ToolSchema
      Parameters:
      scope -
      • The construct scope to bind to.
      This parameter is required.
    • grantPermissionsToRole

      @Stability(Stable) public void grantPermissionsToRole(@NotNull IRole role)
      Grant permissions to the role.

      Specified by:
      grantPermissionsToRole in class ToolSchema
      Parameters:
      role - This parameter is required.