networkTransactions method
Query the network to list the transaction on the type.
type
: The type of transactionpage
: The pagerequest
: List of informations to retrieve in the GraphQL Query
Returns the content scalar type represents transaction content List<Transaction>. Depending if the content can displayed it will be rendered as plain text otherwise in hexadecimal
Implementation
Future<List<Transaction>> networkTransactions(
String type,
int page, {
String request = Transaction.kTransactionQueryAllFields,
}) async {
final body =
'query { networkTransactions(type: "$type", page: $page) { $request } }';
final result = await _client
.withLogger(
'networkTransactions',
)
.query(
QueryOptions(
document: gql(body),
parserFn: (json) {
return TransactionsResponseData.fromJson(json)
.networkTransactions!;
},
),
);
manageLinkException(result);
return result.parsedData ?? [];
}