http_client 1.5.1
http_client: ^1.5.1 copied to clipboard
A platform-independent HTTP client API supporting browser, console, and curl (for SOCKS proxy).
Changelog #
1.5.1 #
- Removed
package:metaas direct dependency. - Fixed null-aware operator.
1.5.0 #
- Migrated to null safety.
1.4.2 #
- Support POST method in
CurlClient. (#9 by rbandres98)
1.4.1 #
- Support all SOCKS type with
curl. (#6 by utopicnarwhal)
1.4.0 #
- Updated code to use latest Dart style guide.
- Support to ignore bad certificates with
ConsoleClient(ignoreBadCertificates: true).
1.3.1 #
- Fixed header handling in
PkgHttpAdapter.
1.3.0 #
PkgHttpAdapterto enable drop-in replacement forpackage:httpClientuses.
1.2.2+2 #
- Fix NPE in
UpdatingClient.
1.2.2+1 #
- Fix NPE.
1.2.2 #
- Simplify timeout code in
ConsoleClientandBrowserClient. - Separate cleanup with Timer in
UpdatingClient.
1.2.1 #
- Fix timeout handling in
ConsoleClient.
1.2.0 #
BEHAVIOUR CHANGES
Headersforces keys to be lowercase (part of the HTTP/2 spec).Requestvalidates arguments differently, may not throw exception where previously thrown (e.g. allowsStream<List<int>>as body).
New features:
Requestconstructor now accepts:form(url-encoded body and also setscontent-typeheader)json(json-encoded body and also setscontent-typeheader)cookies(setscookieheader)
1.1.0 #
- Updated sources: removed
newkeyword. Request.timeoutfor limiting the timeout at the lowest level of the network, other framework-related operations do not count against it.
1.0.4 #
Request.changeto overrideurl,headersorbody.addHeaderto extend current headers.
1.0.3 #
CloseClientFninUpdatingClient.
1.0.2 #
- Class-level
invalidateOnErrorandforceCloseOnErrorforUpdatingClient. TrackingClient.toString()forwards to delegate client.
1.0.1 #
- Automatic
Content-Lengthheader when body is specified (inConsoleClient).
1.0.0+1 #
- Fix: cleanup of past clients in
UpdatingClient.
1.0.0 #
BREAKING CHANGES
Request.bodyis used instead ofbodyStreamandbodyBytes.Stream<List<int>>inputs are no longer supported, use restartableFutureOr<Stream<List<int>>> StreamFn()instead.- Single
Responseconstructor,bodybecome an untyped holder (usebodyAsStreamif migrating uses).
Other updates
- Explicit expiration, and optional on-exception expiration in
UpdatingClient. - Support form-encoded values as request body.
- Support
FilewithRequest.bodyonConsoleClient. - Support native request types with
Request.bodyandResponse.bodyonBrowserClient.
0.6.0 #
- Support
close({bool force})on the API (and on console). - Support
Response.doneto indicate when the underlying input stream has been read and completed. TrackingClientto keep track of ongoing and completed request count (with content read support).UpdatingClientto automatically recreate client resources (or rotate proxies) after some use.
0.5.1 #
- Code update: Dart 2.1(-dev) lints.
0.5.0 #
- Dart 2
0.4.4+1 #
- Fix header override bug.
0.4.3 #
- Record redirect info (when available).
Response.requestAddressto have the address where the request was opened at.- BREAKING:
Response.remoteAddressrenamed toresponseAddress.
0.4.2 #
- Better
Headershandling. - Request properties:
persistentConnection,followRedirects,maxRedirects. - ConsoleClient properties:
idleTimeout,maxConnectionsPerHost,autoUncompress,userAgent. Response.remoteAddress(in ConsoleClient).
0.4.1 #
- Enabled Dart2 Preview for analysis.
0.4.0 #
- Fix deprecated API use.
- Fix header wrapping in requests.
- Default header values in
ConsoleClient.
0.3.1 #
- Added http proxy option to the console client.
0.3.0 #
- Removed dependency on
httppackage.
0.2.2 #
- Add executor support to rate-limit the clients.
0.2.1 #
- Add curl support.
0.2.0 #
Breaking changes:
-
instead of exporting the
httppackage,http_clientprovides its own API- console and browser clients continue to use the
httppackage - preparation to support node_io
for apps that want to be packaged as a single binary (e.g.
.exe) - preparation to support the Fetch API (e.g. in service workers)
- console and browser clients continue to use the
-
removed the awkward
newHttpClient()methods.
0.1.0 #
- Exporting classes from the
httppackage (version:^0.1.13).
0.1.0+1 #
- Exporting streaming request and response.