getClientListWithHttpInfo method

Future<Response> getClientListWithHttpInfo({
  1. bool? paginated,
  2. int? limit,
  3. int? offset,
})

List all clients

Returns a list of all clients. The clients are returned sorted by creation date, with the newest clients appearing first. Warning: the endpoint is being deprecated and will be removed in future versions.

Note: This method returns the HTTP Response.

Parameters:

  • bool paginated: Whether to paginate the results. If true, the results will be paginated. If false, the results will not be paginated.

  • int limit: Applies a limit to the number of results returned. Can be used for paginating the results together with offset.

  • int offset: Skip the first offset results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with limit.

Implementation

Future<http.Response> getClientListWithHttpInfo({
  bool? paginated,
  int? limit,
  int? offset,
}) async {
  // ignore: prefer_const_declarations
  final path = r'/clients';

  // ignore: prefer_final_locals
  Object? postBody;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  if (paginated != null) {
    queryParams.addAll(_queryParams('', 'paginated', paginated));
  }
  if (limit != null) {
    queryParams.addAll(_queryParams('', 'limit', limit));
  }
  if (offset != null) {
    queryParams.addAll(_queryParams('', 'offset', offset));
  }

  const contentTypes = <String>[];

  return apiClient.invokeAPI(
    path,
    'GET',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
  );
}