Skip to content

amondnet/fresh_grpc

Repository files navigation

fresh_grpc 🍋

coverage


A grpc authenticator for built-in token refresh. Built to be used with fresh.

Usage

import 'package:fresh_grpc/fresh_grpc.dart';

main() async {
  final channel = ClientChannel(
    'localhost',
    port: 50051,
    options: ChannelOptions(
      credentials: ChannelCredentials.insecure(),
      codecRegistry:
      CodecRegistry(codecs: const [GzipCodec(), IdentityCodec()]),
    ),
  );
  final fresh = FreshGrpc.oAuth2();
  final stub = GreeterClient(channel,options:fresh.toCallOptions());
  
  await fresh.retryUnary(stub.sayHello, HelloRequest()..name = 'world');
}

Features and bugs

Please file feature requests and bugs at the issue tracker.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages