HttpRequest constructor

HttpRequest(
  1. HttpRoute route,
  2. {String method = 'GET',
  3. Map<String, String> queryParameters = const {},
  4. Map<String, String> headers = const {},
  5. String? auditLogReason,
  6. bool authenticated = true,
  7. bool applyGlobalRateLimit = true}
)

Create a new HttpRequest.

This class is a wrapper around the BaseRequest class from package:http, providing rate limit, audit log and authentication support.

Implementation

HttpRequest(
  this.route, {
  this.method = 'GET',
  this.queryParameters = const {},
  this.headers = const {},
  this.auditLogReason,
  this.authenticated = true,
  this.applyGlobalRateLimit = true,
});