listUniqueProblems method

Future<ListUniqueProblemsResult> listUniqueProblems({
  1. required String arn,
  2. String? nextToken,
})

Gets information about unique problems, such as exceptions or crashes.

Unique problems are defined as a single instance of an error across a run, job, or suite. For example, if a call in your application consistently raises an exception (OutOfBoundsException in MyActivity.java:386), ListUniqueProblems returns a single entry instead of many individual entries for that exception.

May throw ArgumentException. May throw NotFoundException. May throw LimitExceededException. May throw ServiceAccountException.

Parameter arn : The unique problems' ARNs.

Parameter nextToken : An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.

Implementation

Future<ListUniqueProblemsResult> listUniqueProblems({
  required String arn,
  String? nextToken,
}) async {
  ArgumentError.checkNotNull(arn, 'arn');
  _s.validateStringLength(
    'arn',
    arn,
    32,
    1011,
    isRequired: true,
  );
  _s.validateStringLength(
    'nextToken',
    nextToken,
    4,
    1024,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'DeviceFarm_20150623.ListUniqueProblems'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'arn': arn,
      if (nextToken != null) 'nextToken': nextToken,
    },
  );

  return ListUniqueProblemsResult.fromJson(jsonResponse.body);
}