getApi<T> method
Implementation
Future<T> getApi<T>(
Uri uri,
T Function(dynamic value) mapperFunction, {
Map<String, String>? headers,
bool sendHeaders = true,
}) async {
headers = getHeaders(headers ?? {});
var caller = client
.get(
uri,
headers: sendHeaders ? headers : null,
)
.timeout(timeout);
return _callApi(caller, mapperFunction);
}