listSchemaVersions method
Provides a list of the schema versions and related information.
May throw BadRequestException. May throw UnauthorizedException. May throw InternalServerErrorException. May throw ForbiddenException. May throw NotFoundException. May throw ServiceUnavailableException.
Parameter registryName
:
The name of the registry.
Parameter schemaName
:
The name of the schema.
Parameter nextToken
:
The token that specifies the next page of results to return. To request
the first page, leave NextToken empty. The token will expire in 24 hours,
and cannot be shared with other accounts.
Implementation
Future<ListSchemaVersionsResponse> listSchemaVersions({
required String registryName,
required String schemaName,
int? limit,
String? nextToken,
}) async {
ArgumentError.checkNotNull(registryName, 'registryName');
ArgumentError.checkNotNull(schemaName, 'schemaName');
final $query = <String, List<String>>{
if (limit != null) 'limit': [limit.toString()],
if (nextToken != null) 'nextToken': [nextToken],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/v1/registries/name/${Uri.encodeComponent(registryName)}/schemas/name/${Uri.encodeComponent(schemaName)}/versions',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return ListSchemaVersionsResponse.fromJson(response);
}