ApiCookies class

Cookie jar configuration for a request.

// Enable automatic cookie management
ApiCookies(enableCookieJar: true)

// Send extra cookies manually
ApiCookies(extraCookies: {'session_id': 'abc123'})

Constructors

ApiCookies({bool enableCookieJar = false, Map<String, String>? extraCookies, bool disableCookiePersistence = false})
Creates an ApiCookies configuration.
const

Properties

disableCookiePersistence → bool
When true, cookies received in this response are not stored in the jar.
final
enableCookieJar → bool
When true, the package automatically stores cookies from Set-Cookie response headers and re-sends them as Cookie headers on subsequent requests to the same domain.
final
extraCookies → Map<String, String>?
Extra cookies to send on this specific request, regardless of the jar.
final
hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

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