APIRequest<T> constructor
const
APIRequest<T> (
- String url, {
- RequestType type = RequestType.get,
- Map<
String, String> headers = const {}, - Map<
String, dynamic> ? data, - List<
MultipartFile> files = const [], - dynamic onFilesUpload()?,
- bool log = false,
- String errorsField = 'errors',
- Map<
String, String> decodeErrors(- Map errors
- Encoding? encoding,
- T parseResponse(
- dynamic value
Implementation
const APIRequest(
this.url, {
this.type = RequestType.get,
this.headers = const {},
this.data,
this.files = const [],
this.onFilesUpload,
this.log = false,
this.errorsField = 'errors',
this.decodeErrors,
this.encoding,
this.parseResponse,
});