Class: AWSCDK::APIGatewayv2::HttpRouteProps
- Inherits:
-
BatchHttpRouteOptions
- Object
- BatchHttpRouteOptions
- AWSCDK::APIGatewayv2::HttpRouteProps
- Defined in:
- api_gatewayv2/http_route_props.rb
Overview
Properties to initialize a new Route.
Instance Attribute Summary collapse
-
#authorization_scopes ⇒ Array<String>?
readonly
The list of OIDC scopes to include in the authorization.
-
#authorizer ⇒ AWSCDK::APIGatewayv2::IHttpRouteAuthorizer?
readonly
Authorizer for a WebSocket API or an HTTP API.
-
#http_api ⇒ AWSCDK::APIGatewayv2::IHttpAPIRef
readonly
the API the route is associated with.
-
#integration ⇒ AWSCDK::APIGatewayv2::HttpRouteIntegration
readonly
The integration to be configured on this route.
-
#route_key ⇒ AWSCDK::APIGatewayv2::HttpRouteKey
readonly
The key to this route.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(integration:, http_api:, route_key:, authorization_scopes: nil, authorizer: nil) ⇒ HttpRouteProps
constructor
A new instance of HttpRouteProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(integration:, http_api:, route_key:, authorization_scopes: nil, authorizer: nil) ⇒ HttpRouteProps
Returns a new instance of HttpRouteProps.
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'api_gatewayv2/http_route_props.rb', line 12 def initialize(integration:, http_api:, route_key:, authorization_scopes: nil, authorizer: nil) @integration = integration Jsii::Type.check_type(@integration, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLkh0dHBSb3V0ZUludGVncmF0aW9uIn0=")), "integration") @http_api = http_api Jsii::Type.check_type(@http_api, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLklIdHRwQXBpUmVmIn0=")), "httpApi") @route_key = route_key Jsii::Type.check_type(@route_key, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLkh0dHBSb3V0ZUtleSJ9")), "routeKey") @authorization_scopes = Jsii::Type.check_type(@authorization_scopes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "authorizationScopes") unless @authorization_scopes.nil? @authorizer = Jsii::Type.check_type(@authorizer, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLklIdHRwUm91dGVBdXRob3JpemVyIn0=")), "authorizer") unless @authorizer.nil? end |
Instance Attribute Details
#authorization_scopes ⇒ Array<String>? (readonly)
Note:
Default: - no additional authorization scopes
The list of OIDC scopes to include in the authorization.
These scopes will be merged with the scopes from the attached authorizer
45 46 47 |
# File 'api_gatewayv2/http_route_props.rb', line 45 def @authorization_scopes end |
#authorizer ⇒ AWSCDK::APIGatewayv2::IHttpRouteAuthorizer? (readonly)
Note:
Default: - No authorizer
Authorizer for a WebSocket API or an HTTP API.
50 51 52 |
# File 'api_gatewayv2/http_route_props.rb', line 50 def @authorizer end |
#http_api ⇒ AWSCDK::APIGatewayv2::IHttpAPIRef (readonly)
the API the route is associated with.
32 33 34 |
# File 'api_gatewayv2/http_route_props.rb', line 32 def http_api @http_api end |
#integration ⇒ AWSCDK::APIGatewayv2::HttpRouteIntegration (readonly)
The integration to be configured on this route.
28 29 30 |
# File 'api_gatewayv2/http_route_props.rb', line 28 def integration @integration end |
#route_key ⇒ AWSCDK::APIGatewayv2::HttpRouteKey (readonly)
The key to this route.
This is a combination of an HTTP method and an HTTP path.
38 39 40 |
# File 'api_gatewayv2/http_route_props.rb', line 38 def route_key @route_key end |
Class Method Details
.jsii_properties ⇒ Object
52 53 54 55 56 57 58 59 60 |
# File 'api_gatewayv2/http_route_props.rb', line 52 def self.jsii_properties { :integration => "integration", :http_api => "httpApi", :route_key => "routeKey", :authorization_scopes => "authorizationScopes", :authorizer => "authorizer", } end |
Instance Method Details
#to_jsii ⇒ Object
62 63 64 65 66 67 68 69 70 71 72 73 |
# File 'api_gatewayv2/http_route_props.rb', line 62 def to_jsii result = {} result.merge!(super) result.merge!({ "integration" => @integration, "httpApi" => @http_api, "routeKey" => @route_key, "authorizationScopes" => @authorization_scopes, "authorizer" => @authorizer, }) result.compact end |