getUsersWithHttpInfo method

Future<Response> getUsersWithHttpInfo({
  1. String? zapTraceSpan,
  2. int? offset,
  3. int? limit,
  4. String? after,
  5. String? name,
  6. String? id,
})

List all users

Note: This method returns the HTTP Response.

Parameters:

  • String zapTraceSpan: OpenTracing span context

  • int offset:

  • int limit:

  • String after: The last resource ID from which to seek from (but not including). This is to be used instead of offset.

  • String name:

  • String id:

Implementation

Future<Response> getUsersWithHttpInfo({
  String? zapTraceSpan,
  int? offset,
  int? limit,
  String? after,
  String? name,
  String? id,
}) async {
  final path = r'/users';

  // ignore: prefer_final_locals
  Object? postBody;

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

  if (offset != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'offset', offset));
  }
  if (limit != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'limit', limit));
  }
  if (after != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'after', after));
  }
  if (name != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'name', name));
  }
  if (id != null) {
    queryParams.addAll(_convertParametersForCollectionFormat('', 'id', id));
  }

  if (zapTraceSpan != null) {
    headerParams[r'Zap-Trace-Span'] = parameterToString(zapTraceSpan);
  }

  const authNames = <String>[
    'BasicAuthentication',
    'QuerystringAuthentication',
    'TokenAuthentication'
  ];
  const contentTypes = <String>[];

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