registerDefaultPatchBaseline method

Future<RegisterDefaultPatchBaselineResult> registerDefaultPatchBaseline({
  1. required String baselineId,
})

Defines the default patch baseline for the relevant operating system.

To reset the Amazon Web Services-predefined patch baseline as the default, specify the full patch baseline Amazon Resource Name (ARN) as the baseline ID value. For example, for CentOS, specify arn:aws:ssm:us-east-2:733109147000:patchbaseline/pb-0574b43a65ea646ed instead of pb-0574b43a65ea646ed.

May throw DoesNotExistException. May throw InternalServerError. May throw InvalidResourceId.

Parameter baselineId : The ID of the patch baseline that should be the default patch baseline.

Implementation

Future<RegisterDefaultPatchBaselineResult> registerDefaultPatchBaseline({
  required String baselineId,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AmazonSSM.RegisterDefaultPatchBaseline'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'BaselineId': baselineId,
    },
  );

  return RegisterDefaultPatchBaselineResult.fromJson(jsonResponse.body);
}