AuthClient constructor

AuthClient({
  1. required String baseUrl,
  2. required TokenStorage tokenStorage,
  3. Client? httpClient,
  4. Duration timeout = const Duration(seconds: 30),
  5. Map<String, String>? headers,
})

Creates a new AuthClient instance

Implementation

AuthClient({
  required this.baseUrl,
  required this.tokenStorage,
  http.Client? httpClient,
  this.timeout = const Duration(seconds: 30),
  Map<String, String>? headers,
})  : _client = httpClient ?? http.Client(),
      _customHeaders = headers ?? const {};