SuiGrpcClient constructor

SuiGrpcClient({
  1. required SuiNetwork network,
  2. Dio? dio,
  3. String? endpoint,
  4. Map<String, String> headers = const {},
  5. GrpcWebTransport? transport,
})

endpoint overrides the gRPC-web base URL (a custom / self-hosted full node); when null the public endpoint for network is used. network still selects the MVR endpoint.

Implementation

SuiGrpcClient({
  required this.network,
  Dio? dio,
  String? endpoint,
  Map<String, String> headers = const {},
  GrpcWebTransport? transport,
}) : core = GrpcCoreClient(
       network: network,
       dio: dio,
       endpoint: endpoint,
       headers: headers,
       transport: transport,
     ),
     mvr = MvrClient.forNetwork(network, dio: dio);