updateDocumentDefaultVersion method
Set the default version of a document.
May throw InternalServerError.
May throw InvalidDocument.
May throw InvalidDocumentSchemaVersion.
May throw InvalidDocumentVersion.
Parameter documentVersion :
The version of a custom document that you want to set as the default
version.
Parameter name :
The name of a custom document that you want to set as the default version.
Implementation
Future<UpdateDocumentDefaultVersionResult> updateDocumentDefaultVersion({
required String documentVersion,
required String name,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'AmazonSSM.UpdateDocumentDefaultVersion'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'DocumentVersion': documentVersion,
'Name': name,
},
);
return UpdateDocumentDefaultVersionResult.fromJson(jsonResponse.body);
}