Class: AWSCDK::APIGatewayv2Authorizers::WebSocketLambdaAuthorizer
- Inherits:
-
Jsii::Object
- Object
- Jsii::Object
- AWSCDK::APIGatewayv2Authorizers::WebSocketLambdaAuthorizer
- Includes:
- AWSCDK::APIGatewayv2::IWebSocketRouteAuthorizer
- Defined in:
- api_gatewayv2_authorizers/web_socket_lambda_authorizer.rb
Overview
Authorize WebSocket Api routes via a lambda function.
Class Method Summary collapse
Instance Method Summary collapse
-
#bind(options) ⇒ AWSCDK::APIGatewayv2::WebSocketRouteAuthorizerConfig
Bind this authorizer to a specified WebSocket route.
-
#initialize(id, handler, props = nil) ⇒ WebSocketLambdaAuthorizer
constructor
A new instance of WebSocketLambdaAuthorizer.
Constructor Details
#initialize(id, handler, props = nil) ⇒ WebSocketLambdaAuthorizer
Returns a new instance of WebSocketLambdaAuthorizer.
12 13 14 15 16 17 18 |
# File 'api_gatewayv2_authorizers/web_socket_lambda_authorizer.rb', line 12 def initialize(id, handler, props = nil) props = props.is_a?(Hash) ? ::AWSCDK::APIGatewayv2Authorizers::WebSocketLambdaAuthorizerProps.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "id") Jsii::Type.check_type(handler, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfbGFtYmRhLklGdW5jdGlvbiJ9")), "handler") Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyX2F1dGhvcml6ZXJzLldlYlNvY2tldExhbWJkYUF1dGhvcml6ZXJQcm9wcyJ9")), "props") unless props.nil? Jsii::Object.instance_method(:initialize).bind(self).call(id, handler, props) end |
Class Method Details
.jsii_overridable_methods ⇒ Object
20 21 22 23 24 |
# File 'api_gatewayv2_authorizers/web_socket_lambda_authorizer.rb', line 20 def self.jsii_overridable_methods { :bind => { kind: :method, name: "bind", is_optional: false }, } end |
Instance Method Details
#bind(options) ⇒ AWSCDK::APIGatewayv2::WebSocketRouteAuthorizerConfig
Bind this authorizer to a specified WebSocket route.
30 31 32 33 34 |
# File 'api_gatewayv2_authorizers/web_socket_lambda_authorizer.rb', line 30 def bind() = .is_a?(Hash) ? ::AWSCDK::APIGatewayv2::WebSocketRouteAuthorizerBindOptions.new(**.transform_keys(&:to_sym)) : Jsii::Type.check_type(, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLldlYlNvY2tldFJvdXRlQXV0aG9yaXplckJpbmRPcHRpb25zIn0=")), "options") jsii_call_method("bind", []) end |