book method
Future<SearchEnvelope<Book> >
book(
- String query, {
- Order? sort,
- int? page,
- int? size,
- BookTarget? target,
Implementation
Future<SearchEnvelope<Book>> book(String query,
{Order? sort, int? page, int? size, BookTarget? target}) async {
return ApiFactory.handleApiError(() async {
final response = await _dio.get("/v3/search/book", queryParameters: {
..._getParams(query, sort, page, size),
"target": target == null ? null : describeEnum(target).toLowerCase()
});
return SearchEnvelope<Book>.fromJson(response.data);
});
}