Interface GatewayTargetProps
- All Superinterfaces:
GatewayTargetCommonProps,software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
GatewayTargetProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.129.0 (build eaca441)",
date="2026-05-19T08:18:44.417Z")
@Stability(Stable)
public interface GatewayTargetProps
extends software.amazon.jsii.JsiiSerializable, GatewayTargetCommonProps
Properties for creating a Gateway Target resource.
Example:
Gateway gateway = Gateway.Builder.create(this, "MyGateway")
.gatewayName("my-gateway")
.build();
Function myLambdaFunction = Function.Builder.create(this, "MyFunction")
.runtime(Runtime.NODEJS_22_X)
.handler("index.handler")
.code(Code.fromInline("\n exports.handler = async (event) => ({ statusCode: 200 });\n "))
.build();
InlineToolSchema myToolSchema = ToolSchema.fromInline(List.of(ToolDefinition.builder()
.name("my_tool")
.description("My custom tool")
.inputSchema(SchemaDefinition.builder()
.type(SchemaDefinitionType.OBJECT)
.properties(Map.of())
.build())
.build()));
// Create a custom Lambda configuration
LambdaTargetConfiguration customConfig = LambdaTargetConfiguration.create(myLambdaFunction, myToolSchema);
// Use the GatewayTarget constructor directly
GatewayTarget target = GatewayTarget.Builder.create(this, "AdvancedTarget")
.gateway(gateway)
.gatewayTargetName("advanced-target")
.targetConfiguration(customConfig) // Manually created configuration
.credentialProviderConfigurations(List.of(GatewayCredentialProvider.fromIamRole()))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forGatewayTargetPropsstatic final classAn implementation forGatewayTargetProps -
Method Summary
Modifier and TypeMethodDescriptionstatic GatewayTargetProps.Builderbuilder()default List<ICredentialProviderConfig> Credential providers for authentication.The gateway this target belongs to.The target configuration (Lambda, OpenAPI, or Smithy) Use one of the configuration helper classes: - LambdaTargetConfiguration.create() - OpenApiTargetConfiguration.create() - SmithyTargetConfiguration.create().Methods inherited from interface software.amazon.awscdk.services.bedrockagentcore.GatewayTargetCommonProps
getDescription, getGatewayTargetNameMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getGateway
The gateway this target belongs to. -
getTargetConfiguration
The target configuration (Lambda, OpenAPI, or Smithy) Use one of the configuration helper classes: - LambdaTargetConfiguration.create() - OpenApiTargetConfiguration.create() - SmithyTargetConfiguration.create(). -
getCredentialProviderConfigurations
@Stability(Stable) @Nullable default List<ICredentialProviderConfig> getCredentialProviderConfigurations()Credential providers for authentication.Default: - [GatewayCredentialProvider.fromIamRole()]
-
builder
- Returns:
- a
GatewayTargetProps.BuilderofGatewayTargetProps
-