get static method
Sends an HTTP GET request.
Implementation
static Future<Map<String, dynamic>> get(
{required String method, bool isAuth = false, bool testMode = false, Map<String, dynamic>? query}) async {
if (ApiST.instance.baseUrl == null) {
throw EticonApiError(error: 'Base url not set, use Api.init()');
}
if (isAuth) {
if (Token.instance.token.isEmpty) {
throw EticonApiError(error: 'Authentication token is empty, use Api.setToken (String url)');
}
}
return await ApiST.instance
.request(type: TYPE.GET, method: method, isAuth: isAuth, testMode: testMode, query: query);
}