describeInsight method

Future<DescribeInsightResponse> describeInsight({
  1. required String id,
  2. String? accountId,
})

Returns details about an insight that you specify using its ID.

May throw AccessDeniedException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter id : The ID of the insight.

Parameter accountId : The ID of the member account in the organization.

Implementation

Future<DescribeInsightResponse> describeInsight({
  required String id,
  String? accountId,
}) async {
  final $query = <String, List<String>>{
    if (accountId != null) 'AccountId': [accountId],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/insights/${Uri.encodeComponent(id)}',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return DescribeInsightResponse.fromJson(response);
}