createRegistry method
Creates a new registry which may be used to hold a collection of schemas.
May throw AccessDeniedException.
May throw AlreadyExistsException.
May throw ConcurrentModificationException.
May throw InternalServiceException.
May throw InvalidInputException.
May throw ResourceNumberLimitExceededException.
Parameter registryName :
Name of the registry to be created of max length of 255, and may only
contain letters, numbers, hyphen, underscore, dollar sign, or hash mark.
No whitespace.
Parameter description :
A description of the registry. If description is not provided, there will
not be any default value for this.
Parameter tags :
Amazon Web Services tags that contain a key value pair and may be searched
by console, command line, or API.
Implementation
Future<CreateRegistryResponse> createRegistry({
required String registryName,
String? description,
Map<String, String>? tags,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'AWSGlue.CreateRegistry'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'RegistryName': registryName,
if (description != null) 'Description': description,
if (tags != null) 'Tags': tags,
},
);
return CreateRegistryResponse.fromJson(jsonResponse.body);
}