getForJson static method
Sends a HTTP GET request to the given url
with the given queryParameters
and headers
.
Returns the response as a map using json.decode.
Implementation
static Future<Map<String, dynamic>> getForJson(String url,
{Map<String, dynamic>? queryParameters,
Map<String, String>? headers}) async {
return await _get(url,
queryParameters: queryParameters,
headers: headers,
returnType: HttpRequestReturnType.JSON) as Map<String, dynamic>;
}