getNode method

Future<GetNodeOutput> getNode({
  1. required String networkId,
  2. required String nodeId,
  3. String? memberId,
})

Returns detailed information about a node.

Applies to Hyperledger Fabric and Ethereum.

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

Parameter networkId : The unique identifier of the network that the node is on.

Parameter nodeId : The unique identifier of the node.

Parameter memberId : The unique identifier of the member that owns the node.

Applies only to Hyperledger Fabric and is required for Hyperledger Fabric.

Implementation

Future<GetNodeOutput> getNode({
  required String networkId,
  required String nodeId,
  String? memberId,
}) async {
  final $query = <String, List<String>>{
    if (memberId != null) 'memberId': [memberId],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/networks/${Uri.encodeComponent(networkId)}/nodes/${Uri.encodeComponent(nodeId)}',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return GetNodeOutput.fromJson(response);
}