getEnrollmentStatus method

Future<GetEnrollmentStatusResponse> getEnrollmentStatus()

Returns the enrollment (opt in) status of an account to the AWS Compute Optimizer service.

If the account is the management account of an organization, this action also confirms the enrollment status of member accounts within the organization.

May throw InternalServerException. May throw ServiceUnavailableException. May throw AccessDeniedException. May throw InvalidParameterValueException. May throw MissingAuthenticationToken. May throw ThrottlingException.

Implementation

Future<GetEnrollmentStatusResponse> getEnrollmentStatus() async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'ComputeOptimizerService.GetEnrollmentStatus'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
  );

  return GetEnrollmentStatusResponse.fromJson(jsonResponse.body);
}