virak library
Functions
-
deleteData(
{required String endpoint}) → Future< void> - Generic DELETE request
-
getData<
T> ({required String endpoint, T fromJson(dynamic json)?}) → Future< T> - Generic GET request
-
postData<
T> ({required String endpoint, required Map< String, dynamic> body, T fromJson(dynamic json)?}) → Future<T> - Generic POST request
-
putData<
T> ({required String endpoint, required Map< String, dynamic> body, T fromJson(dynamic json)?}) → Future<T> - Generic PUT request
-
setAuthToken(
String? token) → void - Set or clear the authentication token
-
setBaseUrl(
String url) → void - Set the base API URL