Interface ToolDefinition

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
ToolDefinition.Jsii$Proxy

@Generated(value="jsii-pacmak/1.129.0 (build eaca441)", date="2026-05-19T08:18:44.508Z") @Stability(Stable) public interface ToolDefinition extends software.amazon.jsii.JsiiSerializable
Tool definition for inline payload.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.bedrockagentcore.*;
 SchemaDefinition schemaDefinition_;
 SchemaDefinitionType schemaDefinitionType;
 ToolDefinition toolDefinition = ToolDefinition.builder()
         .description("description")
         .inputSchema(SchemaDefinition.builder()
                 .type(schemaDefinitionType)
                 // the properties below are optional
                 .description("description")
                 .items(schemaDefinition_)
                 .properties(Map.of(
                         "propertiesKey", schemaDefinition_))
                 .required(List.of("required"))
                 .build())
         .name("name")
         // the properties below are optional
         .outputSchema(SchemaDefinition.builder()
                 .type(schemaDefinitionType)
                 // the properties below are optional
                 .description("description")
                 .items(schemaDefinition_)
                 .properties(Map.of(
                         "propertiesKey", schemaDefinition_))
                 .required(List.of("required"))
                 .build())
         .build();
 
  • Method Details

    • getDescription

      @Stability(Stable) @NotNull String getDescription()
      The description of the tool.

      This description provides information about the purpose and usage of the tool.

    • getInputSchema

      @Stability(Stable) @NotNull SchemaDefinition getInputSchema()
      The input schema for the tool.

      This schema defines the structure of the input that the tool accepts.

    • getName

      @Stability(Stable) @NotNull String getName()
      The name of the tool.

      This name identifies the tool in the Model Context Protocol.

    • getOutputSchema

      @Stability(Stable) @Nullable default SchemaDefinition getOutputSchema()
      The output schema for the tool.

      This schema defines the structure of the output that the tool produces.

      Default: - No output schema

    • builder

      @Stability(Stable) static ToolDefinition.Builder builder()
      Returns:
      a ToolDefinition.Builder of ToolDefinition