listStreams method
Returns a list of all data capture streams associated with your Amazon Keyspaces account or for a specific keyspace or table. The response includes information such as stream ARNs, table associations, creation timestamps, and current status. This operation helps you discover and manage all active data streams in your Amazon Keyspaces environment.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter keyspaceName :
The name of the keyspace for which to list streams. If specified, only
streams associated with tables in this keyspace are returned. If omitted,
streams from all keyspaces are included in the results.
Parameter maxResults :
The maximum number of streams to return in a single
ListStreams request. The default value is 100. The minimum
value is 1 and the maximum value is 100.
Parameter nextToken :
An optional pagination token provided by a previous
ListStreams operation. If this parameter is specified, the
response includes only records beyond the token, up to the value specified
by maxResults.
Parameter tableName :
The name of the table for which to list streams. Must be used together
with keyspaceName. If specified, only streams associated with
this specific table are returned.
Implementation
Future<ListStreamsOutput> listStreams({
String? keyspaceName,
int? maxResults,
String? nextToken,
String? tableName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'KeyspacesStreams.ListStreams'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (keyspaceName != null) 'keyspaceName': keyspaceName,
if (maxResults != null) 'maxResults': maxResults,
if (nextToken != null) 'nextToken': nextToken,
if (tableName != null) 'tableName': tableName,
},
);
return ListStreamsOutput.fromJson(jsonResponse.body);
}