Method: Authzed::GrpcUtil::BearerToken#request_response

Defined in:
lib/grpcutil/bearer_token.rb

#request_response(request: nil, call: nil, method: nil, metadata: nil) ⇒ Object

Intercept a unary request response call

Parameters:

  • request (Object) (defaults to: nil)
  • call (GRPC::ActiveCall) (defaults to: nil)
  • method (String) (defaults to: nil)
  • metadata (Hash) (defaults to: nil)


24
25
26
27
# File 'lib/grpcutil/bearer_token.rb', line 24

def request_response(request: nil, call: nil, method: nil, metadata: nil)
  [AUTHORIZATION_HEADER] = bearer_token_header
  yield
end