getNetwork method

Future<GetNetworkOutput> getNetwork({
  1. required String networkId,
})

Returns detailed information about a network.

Applies to Hyperledger Fabric and Ethereum.

May throw InvalidRequestException. May throw AccessDeniedException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw InternalServiceErrorException.

Parameter networkId : The unique identifier of the network to get information about.

Implementation

Future<GetNetworkOutput> getNetwork({
  required String networkId,
}) async {
  ArgumentError.checkNotNull(networkId, 'networkId');
  _s.validateStringLength(
    'networkId',
    networkId,
    1,
    32,
    isRequired: true,
  );
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/networks/${Uri.encodeComponent(networkId)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetNetworkOutput.fromJson(response);
}