Class HttpRoute.Builder

java.lang.Object
software.amazon.awscdk.services.apigatewayv2.HttpRoute.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<HttpRoute>
Enclosing class:
HttpRoute

@Stability(Stable) public static final class HttpRoute.Builder extends Object implements software.amazon.jsii.Builder<HttpRoute>
A fluent builder for HttpRoute.
  • Method Details

    • create

      @Stability(Stable) public static HttpRoute.Builder create(software.constructs.Construct scope, String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      Returns:
      a new instance of HttpRoute.Builder.
    • integration

      @Stability(Stable) public HttpRoute.Builder integration(HttpRouteIntegration integration)
      The integration to be configured on this route.

      Parameters:
      integration - The integration to be configured on this route. This parameter is required.
      Returns:
      this
    • httpApi

      @Stability(Stable) public HttpRoute.Builder httpApi(IHttpApi httpApi)
      the API the route is associated with.

      Parameters:
      httpApi - the API the route is associated with. This parameter is required.
      Returns:
      this
    • routeKey

      @Stability(Stable) public HttpRoute.Builder routeKey(HttpRouteKey routeKey)
      The key to this route.

      This is a combination of an HTTP method and an HTTP path.

      Parameters:
      routeKey - The key to this route. This parameter is required.
      Returns:
      this
    • authorizationScopes

      @Stability(Stable) public HttpRoute.Builder authorizationScopes(List<String> authorizationScopes)
      The list of OIDC scopes to include in the authorization.

      These scopes will be merged with the scopes from the attached authorizer

      Default: - no additional authorization scopes

      Parameters:
      authorizationScopes - The list of OIDC scopes to include in the authorization. This parameter is required.
      Returns:
      this
    • authorizer

      @Stability(Stable) public HttpRoute.Builder authorizer(IHttpRouteAuthorizer authorizer)
      Authorizer for a WebSocket API or an HTTP API.

      Default: - No authorizer

      Parameters:
      authorizer - Authorizer for a WebSocket API or an HTTP API. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public HttpRoute build()
      Specified by:
      build in interface software.amazon.jsii.Builder<HttpRoute>
      Returns:
      a newly built instance of HttpRoute.