TransmitHttpClient class
HTTP client for communicating with the Transmit server.
Constructors
- TransmitHttpClient({required String baseUrl, required String uid, Dio? dio})
Properties
Methods
-
createRequest(
String path, Map< String, dynamic> body) → Request - Create a request for subscribing or unsubscribing.
-
getHeaders(
) → Map< String, String> - Get the current headers that are set via setHeaders.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
retrieveXsrfToken(
) → String? - Retrieve XSRF token from cookies (platform-specific).
-
send(
Request request) → Future< Response> - Send an HTTP request using Dio under the hood while returning an http.Response for compatibility with existing hooks/tests.
-
setHeaders(
Map< String, String> ? headers) → void -
Set headers that will be included in all HTTP requests.
Useful for setting authentication headers when user logs in/out.
headers- Map with header key-value pairs, or null to clear headers -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited