HttpRequestModel constructor
- @JsonSerializable(explicitToJson: true, anyMap: true)
const
HttpRequestModel(
{ - @Default(HTTPVerb.get) HTTPVerb method,
- @Default("") String url,
- List<NameValueModel>? params,
- @Default(AuthModel(type: APIAuthType.none)) AuthModel? authModel,
- List<bool>? isParamEnabledList,
- @Default(ContentType.json) ContentType bodyContentType,
- String? body,
- String? query,
- List<FormDataModel>? formData,
})
Implementation
@JsonSerializable(explicitToJson: true, anyMap: true)
const factory HttpRequestModel({
@Default(HTTPVerb.get) HTTPVerb method,
@Default("") String url,
List<NameValueModel>? headers,
List<NameValueModel>? params,
@Default(AuthModel(type: APIAuthType.none)) AuthModel? authModel,
List<bool>? isHeaderEnabledList,
List<bool>? isParamEnabledList,
@Default(ContentType.json) ContentType bodyContentType,
String? body,
String? query,
List<FormDataModel>? formData,
}) = _HttpRequestModel;