listTransactions method
Returns metadata about transactions and their status. To prevent the response from growing indefinitely, only uncommitted transactions and those available for time-travel queries are returned.
This operation can help you identify uncommitted transactions or to get information about transactions.
May throw InternalServiceException.
May throw InvalidInputException.
May throw OperationTimeoutException.
Parameter catalogId :
The catalog for which to list transactions. Defaults to the account ID of
the caller.
Parameter maxResults :
The maximum number of transactions to return in a single call.
Parameter nextToken :
A continuation token if this is not the first call to retrieve
transactions.
Parameter statusFilter :
A filter indicating the status of transactions to return. Options are ALL
| COMPLETED | COMMITTED | ABORTED | ACTIVE. The default is
ALL.
Implementation
Future<ListTransactionsResponse> listTransactions({
String? catalogId,
int? maxResults,
String? nextToken,
TransactionStatusFilter? statusFilter,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
1000,
);
final $payload = <String, dynamic>{
if (catalogId != null) 'CatalogId': catalogId,
if (maxResults != null) 'MaxResults': maxResults,
if (nextToken != null) 'NextToken': nextToken,
if (statusFilter != null) 'StatusFilter': statusFilter.value,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/ListTransactions',
exceptionFnMap: _exceptionFns,
);
return ListTransactionsResponse.fromJson(response);
}