listLineageGroups method

Future<ListLineageGroupsResponse> listLineageGroups({
  1. DateTime? createdAfter,
  2. DateTime? createdBefore,
  3. int? maxResults,
  4. String? nextToken,
  5. SortLineageGroupsBy? sortBy,
  6. SortOrder? sortOrder,
})

A list of lineage groups shared with your Amazon Web Services account. For more information, see Cross-Account Lineage Tracking in the Amazon SageMaker Developer Guide.

Parameter createdAfter : A timestamp to filter against lineage groups created after a certain point in time.

Parameter createdBefore : A timestamp to filter against lineage groups created before a certain point in time.

Parameter maxResults : The maximum number of endpoints to return in the response. This value defaults to 10.

Parameter nextToken : If the response is truncated, SageMaker returns this token. To retrieve the next set of algorithms, use it in the subsequent request.

Parameter sortBy : The parameter by which to sort the results. The default is CreationTime.

Parameter sortOrder : The sort order for the results. The default is Ascending.

Implementation

Future<ListLineageGroupsResponse> listLineageGroups({
  DateTime? createdAfter,
  DateTime? createdBefore,
  int? maxResults,
  String? nextToken,
  SortLineageGroupsBy? sortBy,
  SortOrder? sortOrder,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    100,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SageMaker.ListLineageGroups'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      if (createdAfter != null)
        'CreatedAfter': unixTimestampToJson(createdAfter),
      if (createdBefore != null)
        'CreatedBefore': unixTimestampToJson(createdBefore),
      if (maxResults != null) 'MaxResults': maxResults,
      if (nextToken != null) 'NextToken': nextToken,
      if (sortBy != null) 'SortBy': sortBy.value,
      if (sortOrder != null) 'SortOrder': sortOrder.value,
    },
  );

  return ListLineageGroupsResponse.fromJson(jsonResponse.body);
}