Interface GatewayTargetApiGatewayProps

All Superinterfaces:
GatewayTargetCommonProps, software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
GatewayTargetApiGatewayProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.129.0 (build eaca441)", date="2026-05-19T08:18:44.413Z") @Stability(Stable) public interface GatewayTargetApiGatewayProps extends software.amazon.jsii.JsiiSerializable, GatewayTargetCommonProps
Properties for creating an API Gateway-based Gateway Target.

Example:

 Gateway gateway = Gateway.Builder.create(this, "MyGateway")
         .gatewayName("my-gateway")
         .build();
 RestApi api = RestApi.Builder.create(this, "MyApi")
         .restApiName("my-api")
         .build();
 // Create a gateway target using the static factory method
 GatewayTarget apiGatewayTarget = GatewayTarget.forApiGateway(this, "MyApiGatewayTarget", GatewayTargetApiGatewayProps.builder()
         .gatewayTargetName("my-api-gateway-target")
         .description("Target for API Gateway REST API integration")
         .gateway(gateway)
         .restApi(api)
         .apiGatewayToolConfiguration(ApiGatewayToolConfiguration.builder()
                 .toolFilters(List.of(ApiGatewayToolFilter.builder()
                         .filterPath("/pets/*")
                         .methods(List.of(ApiGatewayHttpMethod.GET, ApiGatewayHttpMethod.POST))
                         .build()))
                 .build())
         .metadataConfiguration(MetadataConfiguration.builder()
                 .allowedRequestHeaders(List.of("X-User-Id"))
                 .allowedQueryParameters(List.of("limit"))
                 .build())
         .build());
 
  • Method Details

    • getApiGatewayToolConfiguration

      @Stability(Stable) @NotNull ApiGatewayToolConfiguration getApiGatewayToolConfiguration()
      Tool configuration defining which operations to expose.
    • getGateway

      @Stability(Stable) @NotNull IGateway getGateway()
      The gateway this target belongs to [disable-awslint:prefer-ref-interface].
    • getRestApi

      @Stability(Stable) @NotNull IRestApi getRestApi()
      The REST API to integrate with Must be in the same account and region as the gateway [disable-awslint:prefer-ref-interface].
    • getCredentialProviderConfigurations

      @Stability(Stable) @Nullable default List<ICredentialProviderConfig> getCredentialProviderConfigurations()
      Credential providers for authentication API Gateway targets support IAM and API key authentication.

      Default: - Empty array (service handles IAM automatically)

    • getMetadataConfiguration

      @Stability(Stable) @Nullable default MetadataConfiguration getMetadataConfiguration()
      Metadata configuration for passing headers and query parameters Allows you to pass additional context through headers and query parameters.

      Default: - No metadata configuration

    • getStage

      @Stability(Stable) @Nullable default String getStage()
      The stage name of the REST API.

      Default: - Uses the deployment stage from the RestApi (restApi.deploymentStage.stageName)

    • builder

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