request method
Perform an API request based on the provided APIRequestRepresentable.
Implementation
Future<dynamic> request(APIRequestRepresentable request) async {
final response = await _dio.request(
request.urls,
data: request.bodies,
queryParameters: request.queries,
options: Options(
method: request.methods.string,
headers: request.headers,
receiveTimeout: const Duration(seconds: 60),
sendTimeout: const Duration(seconds: 60),
),
);
return response.data;
}