ApiSettings class

Low-level HTTP settings that mirror Postman's Settings tab.

ApiSettings(
  followRedirects: true,
  maxRedirects: 5,
  connectTimeout: Duration(seconds: 10),
  receiveTimeout: Duration(seconds: 30),
  verifySslCertificate: true,
)

Constructors

ApiSettings({bool followRedirects = true, int maxRedirects = 10, Duration connectTimeout = const Duration(seconds: 30), Duration receiveTimeout = const Duration(seconds: 30), bool verifySslCertificate = true})
Creates an ApiSettings instance.
const

Properties

connectTimeout → Duration
How long to wait for the connection to be established.
final
followRedirects → bool
Follow HTTP 3xx redirects automatically. Defaults to true.
final
hashCode → int
The hash code for this object.
no setterinherited
maxRedirects → int
Maximum number of redirects to follow. Defaults to 10.
final
receiveTimeout → Duration
How long to wait for the full response to arrive.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
verifySslCertificate → bool
Verify SSL/TLS certificates. Defaults to true.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited