deleteType method
The DeleteType operation deletes a user-defined type (UDT).
You can only delete a type that is not used in a table or another UDT.
To configure the required permissions, see Permissions to delete a UDT in the Amazon Keyspaces Developer Guide.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ValidationException.
Parameter keyspaceName :
The name of the keyspace of the to be deleted type.
Parameter typeName :
The name of the type to be deleted.
Implementation
Future<DeleteTypeResponse> deleteType({
required String keyspaceName,
required String typeName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'KeyspacesService.DeleteType'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'keyspaceName': keyspaceName,
'typeName': typeName,
},
);
return DeleteTypeResponse.fromJson(jsonResponse.body);
}